/* ==========================================================================
   QuickCare Design System & Clinical Tokens
   ========================================================================== */
:root {
    --brand: #0D9488;              /* Primary Clinical Teal */
    --brand-dark: #042F2E;         /* Deep Spruce / Dark Accent */
    --brand-hover: #0F766E;
    --brand-light: #CCFBF1;

    --navy: #0F172A;               /* Dominant High-Contrast Navy */
    --slate: #334155;              /* Body Text */
    --muted: #64748B;              /* Meta & Subtitles */
    --border: #E2E8F0;             /* Crisp Slate 200 Border */
    --light-bg: #F8FAFC;           /* Card & Module Background */

    --blue: #0284C7;               /* SDG 3.8 Medical Blue */
    --purple: #7E22CE;             /* SDG 10.2 Inclusion Violet */
    --cyan: #0891B2;               /* WHO Standards Cyan */
    --green: #059669;              /* Live Queue Active State */
    --emergency: #E11D48;          /* Emergency Preemption Red */

    --font: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
}

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

body {
    font-family: var(--font);
    color: var(--slate);
    background-color: #FFFFFF;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

.container {
    max-width: 1140px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* ==========================================================================
   Navigation Bar & Brand Identity
   ========================================================================== */
.navbar {
    height: 74px;
    display: flex;
    align-items: center;
    background: #FFFFFF;
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 50;
}

.nav-container {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
}

.brand-symbol svg {
    width: 38px;
    height: 38px;
    box-shadow: 0 4px 14px rgba(13, 148, 136, 0.35);
    border-radius: 10px;
    display: block;
}

.brand-text {
    font-size: 1.45rem;
    font-weight: 800;
    letter-spacing: -0.04em;
    color: var(--navy);
}

.brand-text span {
    color: var(--brand);
}

.nav-links a {
    text-decoration: none;
    color: var(--muted);
    font-weight: 500;
    margin-right: 1.75rem;
    transition: color 0.2s ease;
}

.nav-links a:hover {
    color: var(--brand);
}

/* ==========================================================================
   Buttons & Micro-Badges
   ========================================================================== */
.btn {
    display: inline-flex;
    align-items: center;
    padding: 0.65rem 1.3rem;
    border-radius: 8px;
    font-weight: 600;
    text-decoration: none;
    font-size: 0.95rem;
    transition: all 0.2s ease;
}

.btn-primary {
    background-color: var(--navy);
    color: #FFFFFF;
}

.btn-primary:hover {
    background-color: #1E293B;
    transform: translateY(-1px);
}

.btn-secondary {
    background-color: #FFFFFF;
    color: var(--navy);
    border: 1px solid var(--border);
}

.btn-secondary:hover {
    background-color: var(--light-bg);
}

.badge {
    display: inline-block;
    padding: 0.35rem 0.85rem;
    background-color: var(--brand-light);
    color: var(--brand);
    border-radius: 999px;
    font-size: 0.82rem;
    font-weight: 700;
    margin-bottom: 1.25rem;
}

/* ==========================================================================
   Hero Section & Live Clinical Status Pill
   ========================================================================== */
.hero {
    padding: 4.5rem 0 5rem;
    background: #FFFFFF;
}

.hero-container {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 3.5rem;
    align-items: center;
}

/* Redesigned Clinical Status Pill */
.clinical-status-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.4rem 1rem 0.4rem 0.85rem;
    background: #FFFFFF;
    border: 1px solid var(--border);
    border-radius: 999px;
    text-decoration: none;
    box-shadow: 0 2px 8px -2px rgba(15, 23, 42, 0.05);
    margin-bottom: 1.5rem;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
}

.clinical-status-pill:hover {
    border-color: var(--brand);
    box-shadow: 0 4px 16px -2px rgba(13, 148, 136, 0.15);
    transform: translateY(-1px);
}

.pill-ping {
    position: relative;
    width: 10px;
    height: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.ping-core {
    width: 8px;
    height: 8px;
    background-color: #10B981;
    border-radius: 50%;
    z-index: 2;
}

.ping-wave {
    position: absolute;
    width: 100%;
    height: 100%;
    background-color: #10B981;
    border-radius: 50%;
    animation: live-ping 2s cubic-bezier(0, 0, 0.2, 1) infinite;
    opacity: 0.75;
}

@keyframes live-ping {
    75%, 100% {
        transform: scale(2.4);
        opacity: 0;
    }
}

.pill-title {
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: -0.01em;
    color: var(--navy);
}

.pill-separator {
    width: 1px;
    height: 12px;
    background-color: #CBD5E1;
}

.pill-meta {
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--muted);
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
}

.pill-arrow {
    stroke: var(--muted);
    transition: transform 0.2s ease, stroke 0.2s ease;
}

.clinical-status-pill:hover .pill-arrow {
    transform: translateX(3px);
    stroke: var(--brand);
}

.clinical-status-pill:hover .pill-title {
    color: var(--brand);
}

.hero-content h1 {
    font-size: 3rem;
    line-height: 1.15;
    font-weight: 800;
    color: var(--navy);
    letter-spacing: -0.04em;
    margin-bottom: 1.25rem;
}

.hero-content p {
    font-size: 1.15rem;
    color: var(--muted);
    margin-bottom: 2rem;
    max-width: 520px;
}

.hero-actions {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    flex-wrap: wrap;
}

.ussd-badge {
    background: #FFFFFF;
    border: 2px solid var(--navy);
    padding: 0.5rem 1.1rem;
    border-radius: 10px;
    display: flex;
    flex-direction: column;
}

.ussd-label {
    font-size: 0.68rem;
    color: var(--muted);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.ussd-code {
    font-size: 1.35rem;
    font-weight: 800;
    color: var(--navy);
    letter-spacing: 0.5px;
}

/* ==========================================================================
   Hero Visual: Live Patient Ticket Deck
   ========================================================================== */
.hero-card-stack {
    position: relative;
}

.floating-alert {
    position: absolute;
    top: -14px;
    right: 12px;
    z-index: 10;
    background: #FFF1F2;
    border: 1px solid #FFE4E6;
    color: var(--emergency);
    font-size: 0.75rem;
    font-weight: 700;
    padding: 0.35rem 0.8rem;
    border-radius: 999px;
    display: flex;
    align-items: center;
    gap: 0.45rem;
    box-shadow: 0 4px 12px rgba(225, 29, 72, 0.12);
}

.pulse-dot {
    width: 8px;
    height: 8px;
    background-color: var(--emergency);
    border-radius: 50%;
    animation: alert-pulse 1.8s infinite;
}

@keyframes alert-pulse {
    0% { transform: scale(0.95); opacity: 0.8; }
    50% { transform: scale(1.15); opacity: 1; }
    100% { transform: scale(0.95); opacity: 0.8; }
}

.ticket-preview {
    background: #FFFFFF;
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 2rem;
    box-shadow: 0 20px 45px -10px rgba(15, 23, 42, 0.08);
}

.ticket-top {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1.5rem;
}

.live-pill {
    display: inline-block;
    background: #ECFDF5;
    color: var(--green);
    font-size: 0.7rem;
    font-weight: 700;
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    margin-bottom: 0.2rem;
    text-transform: uppercase;
}

.dept-name {
    display: block;
    font-size: 0.85rem;
    color: var(--muted);
    font-weight: 600;
}

.ticket-badge {
    background: var(--brand-dark);
    color: #2DD4BF;
    font-size: 0.95rem;
    font-weight: 800;
    padding: 0.35rem 0.75rem;
    border-radius: 8px;
    letter-spacing: 0.05em;
}

.metric-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-bottom: 1.25rem;
}

.metric-title {
    display: block;
    font-size: 0.68rem;
    font-weight: 800;
    color: var(--muted);
}

.metric-val {
    font-size: 1.65rem;
    font-weight: 800;
    color: var(--navy);
}

.metric-val small {
    font-size: 0.85rem;
    color: var(--muted);
}

.text-green {
    color: var(--green);
}

.progress-bar-wrap {
    height: 6px;
    background: #F1F5F9;
    border-radius: 999px;
    overflow: hidden;
    margin-bottom: 1.25rem;
}

.progress-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--brand), #10B981);
}

.ticket-bottom {
    display: flex;
    justify-content: space-between;
    font-size: 0.8rem;
    color: var(--muted);
    font-weight: 600;
}

.status-indicator {
    color: var(--green);
    font-weight: 700;
}

/* ==========================================================================
   Centered SDG Radar Console Section
   ========================================================================== */
.sdg-showcase {
    padding: 5rem 0;
    background: #F8FAFC;
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}

.sdg-header {
    text-align: center;
    max-width: 620px;
    margin: 0 auto 3.5rem;
}

.section-tag {
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.12em;
    color: var(--brand);
    margin-bottom: 0.5rem;
    display: inline-block;
}

.sdg-header h2 {
    font-size: 2.2rem;
    font-weight: 800;
    color: var(--navy);
    letter-spacing: -0.03em;
    margin-bottom: 0.5rem;
}

.sdg-header p {
    color: var(--muted);
    font-size: 1.05rem;
}

.sdg-console-card {
    background: #FFFFFF;
    border: 1px solid var(--border);
    border-radius: 24px;
    padding: 3.5rem 3rem;
    max-width: 860px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 260px 1fr;
    gap: 3.5rem;
    align-items: center;
    box-shadow: 0 15px 35px -5px rgba(15, 23, 42, 0.04);
}

/* Center Radial Dial */
.console-dial-wrapper {
    display: flex;
    justify-content: center;
}

.console-dial {
    width: 210px;
    height: 210px;
    border: 2px dashed #CBD5E1;
    border-radius: 50%;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.dial-center {
    width: 105px;
    height: 105px;
    background: var(--navy);
    border-radius: 50%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: #FFFFFF;
    box-shadow: 0 10px 25px rgba(15, 23, 42, 0.25);
}

.dial-sup {
    font-size: 0.6rem;
    font-weight: 800;
    letter-spacing: 0.1em;
    color: #38BDF8;
}

.dial-val {
    font-size: 1.6rem;
    font-weight: 800;
    line-height: 1.1;
}

.dial-node {
    position: absolute;
    background: #FFFFFF;
    border: 1px solid #CBD5E1;
    color: var(--slate);
    font-size: 0.72rem;
    font-weight: 700;
    padding: 0.35rem 0.65rem;
    border-radius: 999px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.dial-node:hover {
    border-color: var(--navy);
}

.dial-node.active {
    background: var(--navy);
    color: #FFFFFF;
    border-color: var(--navy);
    box-shadow: 0 4px 10px rgba(15, 23, 42, 0.2);
}

.n-1 { top: -12px; left: 50%; transform: translateX(-50%); }
.n-2 { bottom: 15px; left: 0; }
.n-3 { bottom: 15px; right: 0; }

/* Panel Content */
.sdg-panel {
    display: none;
    animation: slideUp 0.3s ease forwards;
}

.sdg-panel.active {
    display: block;
}

@keyframes slideUp {
    from { opacity: 0; transform: translateY(6px); }
    to { opacity: 1; transform: translateY(0); }
}

.panel-badge {
    display: inline-block;
    padding: 0.3rem 0.65rem;
    border-radius: 6px;
    font-size: 0.72rem;
    font-weight: 800;
    text-transform: uppercase;
    margin-bottom: 0.75rem;
}

.badge-blue { background: #EFF6FF; color: var(--blue); }
.badge-purple { background: #FAF5FF; color: var(--purple); }
.badge-cyan { background: #ECFEFF; color: var(--cyan); }

.sdg-panel h3 {
    font-size: 1.6rem;
    font-weight: 800;
    color: var(--navy);
    margin-bottom: 0.75rem;
    letter-spacing: -0.02em;
}

.sdg-panel p {
    color: var(--slate);
    font-size: 1rem;
    line-height: 1.7;
    margin-bottom: 1.25rem;
}

.panel-stat {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    background: var(--light-bg);
    border: 1px solid var(--border);
    padding: 0.5rem 0.9rem;
    border-radius: 8px;
    font-size: 0.85rem;
}

.panel-stat strong {
    color: var(--navy);
    font-size: 1rem;
}

/* Nav Indicators */
.console-nav {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-top: 1.75rem;
    padding-top: 1.25rem;
    border-top: 1px solid var(--border);
}

.nav-arr {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 1px solid var(--border);
    background: #FFFFFF;
    color: var(--navy);
    font-weight: 800;
    cursor: pointer;
    transition: all 0.2s ease;
}

.nav-arr:hover {
    background: var(--light-bg);
    border-color: var(--brand);
    color: var(--brand);
}

.nav-indicators {
    display: flex;
    gap: 0.4rem;
}

.bar-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #CBD5E1;
    cursor: pointer;
    transition: all 0.2s ease;
}

.bar-dot.active {
    background: var(--navy);
    width: 20px;
    border-radius: 999px;
}

/* ==========================================================================
   Features Section & Duotone Vectors
   ========================================================================== */
.features {
    padding: 5.5rem 0;
    background: #FFFFFF;
}

.section-heading {
    text-align: center;
    margin-bottom: 3.5rem;
}

.section-heading h2 {
    font-size: 2.15rem;
    font-weight: 800;
    color: var(--navy);
    margin-bottom: 0.6rem;
    letter-spacing: -0.02em;
}

.section-heading p {
    color: var(--muted);
    font-size: 1.05rem;
    max-width: 650px;
    margin: 0 auto;
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.feature-card {
    background: #FFFFFF;
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 2.25rem 2rem;
    transition: all 0.25s ease;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.02);
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 25px -5px rgba(15, 23, 42, 0.06);
    border-color: var(--brand);
}

.feature-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.25rem;
}

.icon-teal { background: var(--brand-light); color: var(--brand); }
.icon-blue { background: #E0F2FE; color: var(--blue); }
.icon-red  { background: #FFE4E6; color: var(--emergency); }

.feature-card h3 {
    font-size: 1.2rem;
    font-weight: 800;
    color: var(--navy);
    margin-bottom: 0.6rem;
}

.feature-card p {
    color: var(--muted);
    font-size: 0.95rem;
}

/* ==========================================================================
   Footer
   ========================================================================== */
.footer {
    border-top: 1px solid var(--border);
    padding: 2.5rem 0;
    background: #FFFFFF;
}

.footer-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--muted);
    font-size: 0.9rem;
}

.footer-links a {
    color: var(--muted);
    text-decoration: none;
    margin-left: 1.5rem;
    transition: color 0.2s ease;
}

.footer-links a:hover {
    color: var(--brand);
}

/* ==========================================================================
   Responsive Adaptations
   ========================================================================== */
@media (max-width: 960px) {
    .hero-container {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hero-content p {
        margin: 0 auto 2rem;
    }

    .hero-actions {
        justify-content: center;
    }

    .hero-card-stack {
        max-width: 380px;
        margin: 0 auto;
    }

    .sdg-console-card {
        grid-template-columns: 1fr;
        padding: 2.5rem 1.75rem;
        gap: 2.5rem;
    }
}

@media (max-width: 768px) {
    .nav-links {
        display: none;
    }

    .footer-container {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }

    .footer-links a {
        margin: 0 0.75rem;
    }
}