* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen,
        Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f5f7fa;
    padding: 12px;
}

.container {
    max-width: 800px;
    margin: 0 auto;
    background-color: white;
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

h1 {
    color: #2c3e50;
    margin-bottom: 16px;
    text-align: center;
    font-size: 28px;
    padding-bottom: 12px;
    border-bottom: 2px solid #3498db;
}

h3 {
    margin-bottom: 12px;
    color: #2c3e50;
    font-size: 18px;
}

.patient-header {
    margin-bottom: 16px;
    text-align: center;
}

.patient-name {
    font-size: 24px;
    font-weight: bold;
    color: #2c3e50;
}

/* Emergency contacts styling */
.emergency-contacts {
    display: flex;
    gap: 12px;
    margin-bottom: 20px;
}

.contact-button {
    display: flex;
    flex-direction: column;
    padding: 14px;
    border-radius: 10px;
    text-decoration: none;
    color: white;
    font-weight: bold;
    text-align: center;
    flex: 1;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

.contact-button:hover,
.contact-button:active {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

.contact-label {
    font-size: 14px;
    margin-bottom: 4px;
    opacity: 0.9;
}

.contact-number {
    font-size: 18px;
}

.veli-1 {
    background-color: #e74c3c;
}

.veli-2 {
    background-color: #e67e22;
}

/* Notes area styling */
.notes-area {
    background-color: #f8f9fa;
    padding: 16px;
    border-radius: 10px;
    margin-bottom: 20px;
    border-left: 4px solid #3498db;
    font-size: 16px;
}

.notes-area p {
    margin-bottom: 8px;
}

.notes-area p:last-child {
    margin-bottom: 0;
}

/* Medical info styling */
.medical-info {
    margin-bottom: 20px;
}

table {
    width: 100%;
    border-collapse: collapse;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

td {
    padding: 14px;
    text-align: left;
    border-bottom: 1px solid #eee;
}

tr:last-child td {
    border-bottom: none;
}

tr:nth-child(odd) {
    background-color: #f9f9f9;
}

td:first-child {
    font-weight: bold;
    width: 40%;
    color: #2c3e50;
}

.warning {
    color: #e74c3c;
    font-weight: bold;
}

/* Print button styling */
.action-button {
    background-color: #3498db;
    color: white;
    border: none;
    width: 100%;
    padding: 14px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 16px;
    font-weight: bold;
    transition: background-color 0.2s ease;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

.action-button:hover {
    background-color: #2980b9;
}

/* Mobile optimizations */
@media (max-width: 600px) {
    body {
        padding: 0;
    }

    .container {
        border-radius: 0;
        padding: 16px;
        box-shadow: none;
    }

    h1 {
        font-size: 24px;
    }

    .patient-name {
        font-size: 20px;
    }

    .emergency-contacts {
        flex-direction: column;
        gap: 10px;
    }

    .contact-button {
        padding: 12px;
    }

    .notes-area {
        padding: 12px;
        font-size: 15px;
    }

    td {
        padding: 12px 10px;
        font-size: 15px;
    }

    .action-button {
        padding: 12px;
    }
}

/* Print styling */
@media print {
    body {
        background-color: white;
        padding: 0;
    }

    .container {
        box-shadow: none;
        max-width: 100%;
        padding: 0;
    }

    .emergency-contacts {
        display: flex;
        flex-direction: row;
    }

    .action-button {
        display: none;
    }
}