/* ── BASE RESET ── */
* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: 'Segoe UI', 'Helvetica Neue', Helvetica, Arial, sans-serif;
    background: #e8ecf1;
    color: #1a1a1a;
    line-height: 1.6;
    font-size: 15px;
}

/* ── INDEX PAGE ── */
.index-wrapper {
    max-width: 920px;
    margin: 30px auto;
    padding: 0 20px;
}

.index-wrapper .hospital-header {
    margin-bottom: 30px;
    border-radius: 8px;
    overflow: hidden;
}

.index-intro {
    background: #ffffff;
    border-radius: 8px;
    padding: 24px 30px;
    margin-bottom: 24px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.index-intro p {
    color: #444;
    margin-bottom: 8px;
    font-size: 15px;
}

.index-intro p:last-child { margin-bottom: 0; }

.confidential-banner {
    background: #fef3cd;
    border: 1px solid #f0d878;
    border-left: 5px solid #e0b020;
    padding: 10px 16px;
    border-radius: 4px;
    font-size: 13px;
    font-weight: 700;
    color: #7a5a00;
    margin-bottom: 24px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.memo-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 16px;
    margin-bottom: 30px;
}

.memo-card {
    background: #ffffff;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    transition: transform 0.15s, box-shadow 0.15s;
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
}

.memo-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.14);
}

.memo-card .card-number {
    font-size: 11px;
    font-weight: 700;
    color: #1d5f8a;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 8px;
}

.memo-card .card-icon {
    font-size: 28px;
    margin-bottom: 8px;
}

.memo-card .card-acronym {
    font-size: 20px;
    font-weight: 800;
    color: #0b3c5d;
    letter-spacing: 2px;
    margin-bottom: 4px;
}

.memo-card .card-title {
    font-size: 16px;
    font-weight: 700;
    color: #0b3c5d;
    margin-bottom: 8px;
}

.memo-card .card-summary {
    font-size: 13px;
    color: #555;
    line-height: 1.5;
    flex: 1;
}

.memo-card .card-footer {
    margin-top: 12px;
    padding-top: 10px;
    border-top: 1px solid #e0e0e0;
    font-size: 11px;
    color: #888;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.memo-card .priority-flag {
    display: inline-block;
    background: #d93025;
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 3px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.memo-card .priority-flag.standard {
    background: #1d5f8a;
}

/* ── EMAIL WRAPPER (memo pages) ── */
.email-wrapper {
    max-width: 920px;
    margin: 30px auto;
    background: #ffffff;
    border-radius: 8px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.12);
    overflow: hidden;
}

/* ── EMAIL META BAR ── */
.email-meta-bar {
    background: #f2f4f7;
    border-bottom: 1px solid #d0d4d9;
    padding: 18px 30px 14px 30px;
}

.email-meta-bar .meta-row {
    display: flex;
    margin-bottom: 6px;
    font-size: 13px;
    color: #444;
}

.email-meta-bar .meta-label {
    font-weight: 700;
    color: #2a2a2a;
    width: 80px;
    flex-shrink: 0;
}

.email-meta-bar .meta-value {
    color: #555;
}

.email-meta-bar .priority-flag {
    display: inline-block;
    background: #d93025;
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    padding: 2px 10px;
    border-radius: 3px;
    margin-left: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.email-meta-bar .priority-flag.priority-critical {
    background: #b71c1c;
    animation: pulse-critical 1.5s ease-in-out infinite;
}

@keyframes pulse-critical {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

.email-meta-bar .subject-line {
    font-size: 16px;
    font-weight: 700;
    color: #1a1a1a;
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px solid #d0d4d9;
}

/* ── HOSPITAL BRANDING HEADER ── */
.hospital-header {
    background: linear-gradient(135deg, #0b3c5d 0%, #1d5f8a 100%);
    color: #ffffff;
    padding: 30px 40px;
    text-align: center;
}

.hospital-header .logo-mark {
    font-size: 42px;
    display: inline-block;
    margin-bottom: 6px;
}

.hospital-header h1 {
    font-size: 22px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    margin-bottom: 2px;
}

.hospital-header h1 a {
    color: #ffffff;
    text-decoration: none;
}

.hospital-header h1 a:hover {
    color: #a8cfe8;
}

.hospital-header .subtitle {
    font-size: 13px;
    font-weight: 400;
    color: #a8cfe8;
    letter-spacing: 0.5px;
}

/* ── MEMO NAV ── */
.memo-nav {
    display: flex;
    gap: 12px;
    padding: 16px 40px;
    background: #f2f4f7;
    border-bottom: 1px solid #d0d4d9;
    align-items: center;
    flex-wrap: wrap;
}

.nav-btn {
    display: inline-block;
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    transition: background 0.15s, transform 0.1s;
}

.nav-btn.nav-home {
    background: #0b3c5d;
    color: #fff;
}

.nav-btn.nav-home:hover { background: #1d5f8a; }

.nav-btn.nav-prev {
    background: #e0e4e8;
    color: #333;
}

.nav-btn.nav-prev:hover { background: #d0d4d9; }

.nav-btn.nav-next {
    background: #0b3c5d;
    color: #fff;
    margin-left: auto;
}

.nav-btn.nav-next:hover { background: #1d5f8a; }

/* ── DOCUMENT BODY ── */
.document-body {
    padding: 40px 50px;
}

.document-body .confidential-banner {
    margin-bottom: 30px;
}

.document-body .section-divider {
    text-align: center;
    margin: 28px 0;
    color: #b0b0b0;
    font-size: 13px;
    letter-spacing: 1px;
}

/* ── HEADINGS ── */
.document-body h2 {
    font-size: 17px;
    font-weight: 700;
    color: #0b3c5d;
    margin-bottom: 14px;
    padding-bottom: 8px;
    border-bottom: 2px solid #0b3c5d;
}

.document-body h3 {
    font-size: 15px;
    font-weight: 700;
    color: #1d5f8a;
    margin-top: 22px;
    margin-bottom: 10px;
}

.document-body p {
    margin-bottom: 14px;
    color: #2a2a2a;
}

.document-body strong { color: #1a1a1a; }
.document-body em { color: #444; }

/* ── ACRONYM BOXES ── */
.acronym-box {
    background: #f0f6fb;
    border: 1px solid #c5d9e8;
    border-left: 5px solid #1d5f8a;
    border-radius: 6px;
    padding: 20px 24px;
    margin: 20px 0 24px 0;
}

.acronym-box .acronym-title {
    font-size: 20px;
    font-weight: 800;
    color: #0b3c5d;
    letter-spacing: 2px;
    margin-bottom: 4px;
}

.acronym-box .acronym-expansion {
    font-size: 14px;
    font-weight: 600;
    color: #1d5f8a;
    margin-bottom: 12px;
    line-height: 1.4;
}

/* ── DEFINITION CALLOUT ── */
.definition-box {
    background: #eef6ff;
    border: 1px solid #a8cfe8;
    border-radius: 4px;
    padding: 14px 20px;
    margin: 12px 0 16px 0;
    font-size: 14px;
    color: #0b3c5d;
    font-style: italic;
    font-weight: 600;
    text-align: center;
}

/* ── TABLES ── */
.data-table {
    width: 100%;
    border-collapse: collapse;
    margin: 16px 0 22px 0;
    font-size: 13px;
}

.data-table th {
    background: #0b3c5d;
    color: #ffffff;
    font-weight: 700;
    padding: 10px 14px;
    text-align: left;
    border: 1px solid #0b3c5d;
}

.data-table td {
    padding: 9px 14px;
    border: 1px solid #d0d4d9;
    background: #fff;
    color: #333;
    vertical-align: top;
}

.data-table tr:nth-child(even) td { background: #f7f9fb; }

/* ── CHECKBOX LIST ── */
.checklist {
    list-style: none;
    margin: 12px 0 18px 0;
    padding: 0;
}

.checklist li {
    padding: 6px 0 6px 28px;
    position: relative;
    font-size: 14px;
    color: #2a2a2a;
}

.checklist li::before {
    content: "☐";
    position: absolute;
    left: 0;
    font-size: 18px;
    color: #1d5f8a;
}

/* ── SCRIPT BLOCK ── */
.script-block {
    background: #f5f7fa;
    border-left: 4px solid #6c8cb5;
    padding: 14px 18px;
    margin: 10px 0 16px 0;
    font-size: 14px;
    color: #333;
    font-style: italic;
    border-radius: 0 4px 4px 0;
}

.script-block .script-label {
    font-style: normal;
    font-weight: 700;
    color: #1d5f8a;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    display: block;
    margin-bottom: 4px;
}

/* ── BILLING NOTE ── */
.billing-note {
    background: #fff8e1;
    border: 1px solid #ffe082;
    border-left: 5px solid #f0b020;
    border-radius: 4px;
    padding: 14px 18px;
    margin: 14px 0 20px 0;
    font-size: 13px;
    color: #5a4400;
}

.billing-note .billing-label {
    font-weight: 800;
    text-transform: uppercase;
    color: #7a5a00;
    font-size: 11px;
    letter-spacing: 1px;
    display: block;
    margin-bottom: 6px;
}

/* ── WARNING BANNER ── */
.warning-banner {
    background: #d93025;
    color: #ffffff;
    text-align: center;
    padding: 14px 20px;
    margin: 20px 0;
    border-radius: 4px;
    font-weight: 700;
    font-size: 14px;
    letter-spacing: 0.5px;
}

.warning-banner .warning-icon {
    font-size: 18px;
    margin-right: 6px;
}

/* ── FINAL STATEMENT ── */
.final-statement {
    background: #0b3c5d;
    color: #ffffff;
    padding: 22px 28px;
    border-radius: 6px;
    margin: 24px 0;
    text-align: center;
    font-size: 15px;
    font-weight: 600;
    line-height: 1.8;
}

.final-statement .highlight {
    color: #f0b020;
    font-weight: 800;
}

/* ── SIGNATURE BLOCK ── */
.signature-block {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #d0d4d9;
    font-size: 14px;
    color: #333;
}

.signature-block .sig-name {
    font-weight: 800;
    color: #0b3c5d;
    font-size: 16px;
}

.signature-block .sig-title {
    color: #555;
    font-size: 13px;
    font-style: italic;
    margin-top: 2px;
}

.signature-block .sig-contact {
    font-size: 12px;
    color: #777;
    margin-top: 6px;
}

/* ── TAGLINE ── */
.tagline {
    text-align: center;
    padding: 20px 40px;
    background: #f2f4f7;
    border-top: 1px solid #d0d4d9;
    font-size: 13px;
    font-weight: 700;
    color: #0b3c5d;
    letter-spacing: 0.5px;
}

.tagline .tagline-icons {
    font-size: 18px;
    margin-bottom: 4px;
}

/* ── CONFIDENTIALITY FOOTER ── */
.confidentiality-footer {
    background: #fafafa;
    padding: 16px 40px;
    font-size: 11px;
    color: #999;
    line-height: 1.5;
    border-top: 1px solid #e0e0e0;
}

/* ── RESPONSIVE ── */
@media (max-width: 768px) {
    .email-wrapper, .index-wrapper { margin: 0; border-radius: 0; }
    .hospital-header { padding: 20px 20px; }
    .hospital-header h1 { font-size: 17px; }
    .document-body { padding: 25px 20px; }
    .email-meta-bar { padding: 14px 20px 10px 20px; }
    .email-meta-bar .meta-label { width: 60px; }
    .data-table { font-size: 12px; }
    .data-table th, .data-table td { padding: 7px 8px; }
    .acronym-box { padding: 14px 16px; }
    .acronym-box .acronym-title { font-size: 17px; }
    .memo-grid { grid-template-columns: 1fr; }
    .memo-nav { padding: 12px 20px; }
}