/* =====================================================
   Syntro Health — Precision Clinical Design System
   Architecture: High-Taste Minimalist & Clinical MNT
   Typography: Plus Jakarta Sans + Geist Mono (Tabular Data)
   Palette: Zinc / Slate Foundation + Clinical Emerald Accent
   ===================================================== */

:root {
    /* ── Typography Stacks ── */
    --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-mono: 'Geist Mono', 'SF Mono', 'Roboto Mono', Menlo, monospace;

    /* ── Neutral Slate / Zinc Foundation ── */
    --zinc-950: #090d14;
    --zinc-900: #0f172a;
    --zinc-850: #141f36;
    --zinc-800: #1e293b;
    --zinc-700: #334155;
    --zinc-500: #64748b;
    --zinc-400: #94a3b8;
    --zinc-300: #cbd5e1;
    --zinc-200: #e2e8f0;
    --zinc-100: #f1f5f9;
    --zinc-50:  #f8fafc;
    --white:    #ffffff;

    /* ── Disciplined Clinical Emerald Accent ── */
    --emerald-900: #064e3b;
    --emerald-800: #065f46;
    --emerald-700: #047857;
    --emerald-600: #059669;
    --emerald-500: #10b981;
    --emerald-400: #34d399;
    --emerald-100: #d1fae5;
    --emerald-50:  #ecfdf5;

    /* ── Diagnostic Semantics ── */
    --amber-500: #f59e0b;
    --red-500:   #ef4444;
    --blue-500:  #3b82f6;

    /* ── Default Theme Tokens (Clinical Dark Master Canvas) ── */
    --bg-page:        #090d14;
    --bg-surface:     #0f172a;
    --bg-elevated:    #141f36;
    --bg-glass:       rgba(9, 13, 20, 0.85);

    --border-subtle:  rgba(255, 255, 255, 0.08);
    --border-medium:  rgba(255, 255, 255, 0.15);
    --border-accent:  rgba(16, 185, 129, 0.3);

    --text-primary:   #f8fafc;
    --text-secondary: #94a3b8;
    --text-muted:     #64748b;

    --accent-solid:   #10b981;
    --accent-hover:   #059669;
    --accent-tint:    rgba(16, 185, 129, 0.12);
    --accent-text:    #34d399;

    /* ── Compatibility Aliases for Cards & Badges ── */
    --card-bg:        rgba(15, 23, 42, 0.75);
    --border-color:   rgba(255, 255, 255, 0.08);
    --primary-green:  #22c55e;
    --text:           var(--text-primary);
    --text-subtle:    var(--text-secondary);

    /* ── Shadows & Radii ── */
    --shadow-sm: 0 1px 2px rgba(0,0,0,0.4);
    --shadow:    0 4px 12px -2px rgba(0,0,0,0.5);
    --shadow-md: 0 12px 24px -4px rgba(0,0,0,0.6);
    --shadow-lg: 0 24px 48px -12px rgba(0,0,0,0.7);

    --radius-xs: 4px;
    --radius-sm: 8px;
    --radius:    12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --transition: all 0.18s cubic-bezier(0.16, 1, 0.3, 1);
}

/* ── Light Mode Token Overrides ── */
[data-theme="light"], body.theme-light {
    --bg-page:        #f8fafc;
    --bg-surface:     #ffffff;
    --bg-elevated:    #f1f5f9;
    --bg-glass:       rgba(255, 255, 255, 0.88);

    --border-subtle:  #e2e8f0;
    --border-medium:  #cbd5e1;
    --border-accent:  rgba(5, 150, 105, 0.3);

    --text-primary:   #0f172a;
    --text-secondary: #475569;
    --text-muted:     #64748b;

    --accent-solid:   #059669;
    --accent-hover:   #047857;
    --accent-tint:    #ecfdf5;
    --accent-text:    #065f46;

    --card-bg:        #ffffff;
    --border-color:   #e2e8f0;
    --primary-green:  #059669;
    --text:           var(--text-primary);
    --text-subtle:    var(--text-secondary);

    --shadow-sm: 0 1px 2px rgba(15,23,42,0.04);
    --shadow:    0 4px 12px -2px rgba(15,23,42,0.06);
    --shadow-md: 0 12px 24px -4px rgba(15,23,42,0.08);
}

/* ── Global Typography & Resets ── */
* { box-sizing: border-box; }

body {
    font-family: var(--font-sans);
    font-size: 15px;
    line-height: 1.6;
    color: var(--text-primary);
    background-color: var(--bg-page);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4, h5, h6, .brand-name {
    font-family: var(--font-sans);
    font-weight: 700;
    line-height: 1.25;
    letter-spacing: -0.025em;
    color: var(--text-primary);
}

/* Tabular Figures for Clinical & Metabolic Metrics */
.tabular-nums, .stat-num, .sb-num, .dash-stat-value, .metric-result-value, .macro-val {
    font-variant-numeric: tabular-nums lining-nums;
    letter-spacing: -0.01em;
}

a { text-decoration: none; color: var(--accent-text); transition: var(--transition); }
a:hover { color: var(--accent-solid); }

/* ── Unified Navbar ── */
.navbar-custom {
    background: var(--bg-glass);
    border-bottom: 1px solid var(--border-subtle);
    padding: 12px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
}

.navbar-brand {
    text-decoration: none;
    transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}
.navbar-brand:hover {
    transform: translateY(-0.5px);
}
.brand-logo {
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.3s ease;
    box-shadow: 0 2px 8px rgba(16, 185, 129, 0.2);
}
.navbar-brand:hover .brand-logo,
.mobile-brand:hover .mobile-brand-logo {
    transform: rotate(3deg) scale(1.04);
    box-shadow: 0 4px 14px rgba(16, 185, 129, 0.35);
}

.brand-name {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-primary);
    letter-spacing: -0.025em;
    display: inline-flex;
    align-items: baseline;
    gap: 4px;
}
.brand-name-light {
    font-weight: 300;
    color: #94A3B8;
    background: linear-gradient(135deg, #CBD5E1 0%, #38BDF8 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.badge-brand-dot {
    display: inline-block;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #10B981;
    box-shadow: 0 0 8px rgba(16, 185, 129, 0.8);
    margin-right: 6px;
    vertical-align: middle;
    animation: brandDotPulse 2s infinite ease-in-out;
}

@keyframes brandDotPulse {
    0%, 100% {
        transform: scale(1);
        opacity: 0.9;
        box-shadow: 0 0 6px rgba(16, 185, 129, 0.6);
    }
    50% {
        transform: scale(1.25);
        opacity: 1;
        box-shadow: 0 0 12px rgba(16, 185, 129, 1), 0 0 18px rgba(56, 189, 248, 0.5);
    }
}

.navbar-custom .nav-link {
    color: var(--text-secondary);
    font-weight: 500;
    font-size: 0.9rem;
    padding: 6px 14px;
    border-radius: var(--radius-sm);
    transition: var(--transition);
}
.navbar-custom .nav-link:hover {
    color: var(--text-primary);
    background: var(--border-subtle);
}

.btn-nav-cta {
    background: var(--accent-solid) !important;
    color: #ffffff !important;
    padding: 8px 18px !important;
    border-radius: var(--radius-sm) !important;
    font-weight: 600;
    font-size: 0.875rem;
    border: 1px solid rgba(255,255,255,0.15) !important;
    transition: var(--transition);
}
.btn-nav-cta:hover {
    background: var(--accent-hover) !important;
    transform: translateY(-1px);
}

/* ── Tactile Mechanical Buttons ── */
.btn-primary-custom, .btn-clinical-primary {
    background: var(--accent-solid);
    color: #ffffff !important;
    border: 1px solid rgba(255,255,255,0.15);
    border-radius: 10px;
    padding: 11px 24px;
    font-weight: 600;
    font-size: 0.95rem;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    box-shadow: var(--shadow-sm);
}
.btn-primary-custom:hover, .btn-clinical-primary:hover {
    background: var(--accent-hover);
    box-shadow: 0 4px 16px -2px rgba(16, 185, 129, 0.4);
    transform: translateY(-1px);
}
.btn-primary-custom:active, .btn-clinical-primary:active, .touch-card-option:active, .day-pill-btn:active {
    transform: translateY(1px) scale(0.985);
    box-shadow: none;
}

.btn-outline-secondary {
    background: transparent;
    color: var(--text-secondary);
    border: 1px solid var(--border-medium);
    border-radius: 10px;
    padding: 10px 20px;
    font-weight: 500;
    font-size: 0.9rem;
    transition: var(--transition);
}
.btn-outline-secondary:hover {
    background: var(--border-subtle);
    color: var(--text-primary);
    border-color: var(--text-secondary);
}
.btn-success-custom {
    background: var(--accent-solid);
    color: var(--white);
    border: none;
    border-radius: 10px;
    padding: 12px 28px;
    font-weight: 600;
    font-size: 1rem;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    box-shadow: 0 4px 15px rgba(34, 197, 94, 0.3);
}
.btn-success-custom:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(34, 197, 94, 0.4);
    color: var(--white);
}

.btn-outline-primary-custom {
    background: transparent;
    color: var(--green-600);
    border: 2px solid var(--green-600);
    border-radius: 100px;
    padding: 10px 24px;
    font-weight: 600;
    transition: var(--transition);
}
.btn-outline-primary-custom:hover {
    background: var(--green-600);
    color: var(--white);
    transform: translateY(-1px);
}

.btn-cta-white {
    background: var(--white);
    color: var(--green-700);
    border: none;
    border-radius: 100px;
    padding: 14px 36px;
    font-weight: 700;
    font-size: 1rem;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
}
.btn-cta-white:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
    color: var(--green-700);
}

/* ── Section Common ── */
.section-tag {
    display: inline-block;
    background: var(--green-100);
    color: var(--green-700);
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 1px;
    text-transform: uppercase;
    padding: 5px 14px;
    border-radius: 100px;
    margin-bottom: 12px;
}

.section-title {
    font-size: clamp(1.8rem, 3vw, 2.4rem);
    color: var(--slate-900);
    margin-bottom: 10px;
}

.section-sub {
    color: var(--slate-600);
    font-size: 1.05rem;
    max-width: 580px;
    margin: 0 auto;
}

/* ── Hero ── */
.hero-section {
    background: var(--slate-50);
    padding: 80px 0 80px;
    position: relative;
    overflow: hidden;
    min-height: 85vh;
    display: flex;
    align-items: center;
}

.hero-bg-decor {
    position: absolute;
    top: -200px;
    right: -300px;
    width: 700px;
    height: 700px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(34,197,94,0.07) 0%, transparent 70%);
    pointer-events: none;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: var(--green-100);
    color: var(--green-700);
    font-size: 0.8rem;
    font-weight: 600;
    padding: 6px 14px;
    border-radius: 100px;
    margin-bottom: 20px;
}

/* Trust badges row beneath Hero CTA */
.trust-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 16px;
}

.trust-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: var(--white);
    color: var(--slate-800) !important;
    font-size: 0.82rem;
    font-weight: 600;
    padding: 6px 14px;
    border-radius: 100px;
    border: 1.5px solid var(--slate-200);
    box-shadow: var(--shadow-sm);
}

.hero-title {
    font-size: clamp(2rem, 4.5vw, 3.2rem);
    color: var(--slate-900);
    margin-bottom: 20px;
    letter-spacing: -1px;
}

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

.hero-subtitle {
    font-size: 1.1rem;
    color: var(--slate-600);
    max-width: 500px;
    margin-bottom: 36px;
    line-height: 1.7;
}

.hero-stats {
    display: flex;
    align-items: center;
    gap: 24px;
    margin-top: 28px;
}

.stat { display: flex; flex-direction: column; }
.stat-num { font-size: 1.3rem; font-weight: 700; color: var(--slate-900); font-family: 'Plus Jakarta Sans', sans-serif; }
.stat-label { font-size: 0.75rem; color: var(--slate-500); }
.stat-divider { width: 1px; height: 36px; background: var(--slate-300); }

/* ── Hero Visual Cards (3D Glassmorphism) ── */
.hero-graphic-col {
    position: relative;
    min-height: 500px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

/* ── Interactive Clinical Intake & Metabolic Bento Grid ── */
.hero-bento-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
    width: 100%;
    max-width: 520px;
    margin: 0 auto;
}

.bento-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg);
    padding: 20px;
    box-shadow: var(--shadow);
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.bento-card:hover {
    border-color: var(--border-medium);
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.bento-card-wide {
    grid-column: span 2;
}

.bento-header-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: var(--text-xs);
    font-weight: 600;
    color: var(--emerald-400);
    background: var(--accent-tint);
    padding: 4px 10px;
    border-radius: var(--radius-xs);
    border: 1px solid var(--border-accent);
}

.bento-title {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 10px 0 6px 0;
}

.bento-sub {
    font-size: 0.825rem;
    color: var(--text-secondary);
    line-height: 1.4;
    margin-bottom: 0;
}

/* Macro Rings & Tabular Bars */
.macro-ring-container {
    position: relative;
    width: 72px;
    height: 72px;
    flex-shrink: 0;
}
.circular-chart { display: block; width: 100%; height: 100%; }
.circular-chart path { fill: none !important; }
.circle-bg { stroke: rgba(255, 255, 255, 0.08) !important; stroke-width: 3.5; }
.circle { stroke-width: 3.5; stroke-linecap: round; stroke: var(--accent-solid); stroke-dasharray: 82, 100; }
.macro-val {
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    font-weight: 800;
    font-size: 0.85rem;
    line-height: 1.1;
    color: var(--text-primary);
}
.macro-val small { font-size: 0.65rem; color: var(--text-muted); display: block; }

.macro-bars { display: flex; flex-direction: column; gap: 8px; flex: 1; }
.m-bar { display: flex; align-items: center; gap: 8px; font-size: 0.8rem; font-weight: 600; }
.m-bar .label { color: var(--text-secondary); width: 16px; font-family: var(--font-mono); }
.m-bar .track { flex: 1; height: 6px; background: var(--border-subtle); border-radius: 4px; overflow: hidden; }
.m-bar .fill { height: 100%; border-radius: 4px; }
.fill-p { background: #3b82f6; }
.fill-c { background: #f59e0b; }
.fill-f { background: #10b981; }
.m-bar .val { color: var(--text-primary); width: 34px; text-align: right; font-family: var(--font-mono); }

/* Biomarker Mini Matrix */
.biomarker-matrix-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid var(--border-subtle);
    font-size: 0.825rem;
}
.biomarker-matrix-row:last-child { border-bottom: none; }
.biomarker-name { color: var(--text-secondary); }
.biomarker-val { font-weight: 600; color: var(--emerald-400); font-family: var(--font-mono); }

/* Recipe Snippet */
.recipe-snippet {
    display: flex;
    align-items: center;
    gap: 12px;
}
.recipe-icon-box {
    width: 44px;
    height: 44px;
    border-radius: 10px;
    background: var(--border-subtle);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--emerald-400);
    font-size: 1.25rem;
    flex-shrink: 0;
}

@media (max-width: 576px) {
    .hero-bento-grid {
        grid-template-columns: 1fr;
    }
    .bento-card-wide {
        grid-column: span 1;
    }
}

/* ── How It Works ── */
.section-how {
    padding: 90px 0;
    background: var(--white);
}

.section-header { margin-bottom: 20px; }

.how-card {
    background: var(--slate-50);
    border-radius: var(--radius-lg);
    padding: 36px 30px;
    text-align: center;
    border: 2px solid transparent;
    transition: var(--transition);
    height: 100%;
}

.how-card:hover {
    border-color: var(--green-300);
    background: var(--white);
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
}

.how-card-featured {
    background: var(--green-600);
    color: var(--white);
}
.how-card-featured h4, .how-card-featured p { color: var(--white); }
.how-card-featured:hover { background: var(--green-700); border-color: transparent; }

.how-step {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--green-200);
    font-family: 'Plus Jakarta Sans', sans-serif;
    line-height: 1;
    margin-bottom: 12px;
}
.how-card-featured .how-step { color: rgba(255,255,255,0.3); }

.how-icon { font-size: 2rem; margin-bottom: 12px; }
.how-card h4 { font-size: 1.2rem; margin-bottom: 10px; color: var(--slate-900); }
.how-card p { color: var(--slate-600); font-size: 0.9rem; margin: 0; }

/* ── Benefits ── */
.section-benefits {
    padding: 90px 0;
    background: var(--slate-50);
}

.benefits-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.benefit-item {
    background: var(--white);
    border-radius: var(--radius);
    padding: 20px;
    display: flex;
    align-items: flex-start;
    gap: 14px;
    transition: var(--transition);
    border: 1px solid var(--slate-200);
}

.benefit-item:hover { border-color: var(--green-300); box-shadow: var(--shadow); }
.benefit-icon { font-size: 1.5rem; flex-shrink: 0; }
.benefit-item h5 { font-size: 0.95rem; margin-bottom: 4px; color: var(--slate-900); }
.benefit-item p { font-size: 0.82rem; color: var(--slate-500); margin: 0; }

/* ── Metrics Grid ── */
.section-metrics { padding: 80px 0; background: var(--white); }

.metric-card {
    background: var(--slate-50);
    border: 1px solid var(--slate-200);
    border-radius: var(--radius);
    padding: 24px 20px;
    text-align: center;
    transition: var(--transition);
}
.metric-card:hover { border-color: var(--green-400); background: var(--green-50); transform: translateY(-2px); }
.metric-icon { font-size: 1.8rem; display: block; margin-bottom: 8px; }
.metric-card h6 { font-size: 0.95rem; font-weight: 600; margin-bottom: 4px; }
.metric-card small { color: var(--slate-500); font-size: 0.78rem; }

/* ── CTA Banner ── */
.section-cta {
    background: linear-gradient(135deg, var(--green-700), var(--green-500));
    padding: 80px 0;
    color: var(--white);
}
.section-cta h2 { color: var(--white); font-size: 2.2rem; margin-bottom: 12px; }
.section-cta p { color: rgba(255,255,255,0.85); font-size: 1.1rem; margin-bottom: 30px; }

/* ── Footer ── */
.site-footer {
    background: var(--slate-900);
    color: var(--slate-300);
    padding: 60px 0 20px;
}
.footer-brand .brand-name { color: var(--white); }
.footer-desc { font-size: 0.875rem; color: var(--slate-400); line-height: 1.7; }
.footer-heading { color: var(--white); font-size: 0.85rem; font-weight: 600; letter-spacing: 0.5px; text-transform: uppercase; margin-bottom: 14px; }
.footer-links { list-style: none; padding: 0; margin: 0; }
.footer-links li { margin-bottom: 8px; }
.footer-links a { color: var(--slate-400); font-size: 0.875rem; transition: var(--transition); }
.footer-links a:hover { color: var(--green-400); }
.footer-small { font-size: 0.8rem; color: var(--slate-400); line-height: 1.7; }
.footer-bottom { border-top: 1px solid var(--slate-800); padding-top: 20px; margin-top: 20px; text-align: center; font-size: 0.8rem; color: var(--slate-500); }

/* ── Questionnaire ── */
.questionnaire-page { background: var(--slate-50); min-height: 100vh; }
.page-title { font-size: 2rem; color: var(--slate-900); }
.page-sub { color: var(--slate-500); font-size: 1rem; }

.q-progress-container { max-width: 600px; margin: 0 auto; }
.q-progress-bar { height: 6px; background: var(--slate-200); border-radius: 10px; overflow: hidden; }
.q-progress-fill { height: 100%; background: linear-gradient(90deg, var(--green-500), var(--green-400)); border-radius: 10px; transition: width 0.4s ease; }
.q-progress-text { display: flex; justify-content: space-between; font-size: 0.8rem; color: var(--slate-500); margin-top: 6px; }

.step-indicators {
    justify-content: center;
    gap: 6px;
    flex-wrap: wrap;
}

.step-dot {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    background: var(--slate-200);
    color: var(--slate-500);
    border: 2px solid transparent;
}
.step-dot.active { background: var(--green-600); color: var(--white); transform: scale(1.1); }
.step-dot.done { background: var(--green-100); color: var(--green-600); border-color: var(--green-300); }

.mode-switch {
    display: flex;
    background: var(--bg-elevated);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-sm);
    padding: 3px;
    margin-bottom: 24px;
}
.mode-btn {
    flex: 1;
    text-align: center;
    padding: 8px 12px;
    border-radius: var(--radius-xs);
    font-size: 0.825rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    color: var(--text-secondary);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
.mode-btn.active {
    background: var(--accent-solid);
    color: #ffffff;
}
.mode-btn:hover:not(.active) {
    color: var(--text-primary);
}

.q-section { display: none !important; }
.q-section.active { display: block !important; animation: fadeIn 0.35s ease; }

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

.q-card {
    background: var(--bg-surface);
    border-radius: var(--radius-xl);
    padding: 36px 40px;
    box-shadow: var(--shadow);
    border: 1px solid var(--border-subtle);
    max-width: 800px;
    margin: 0 auto;
    color: var(--text-primary);
}

.q-card label, .q-card .form-label {
    color: var(--text-primary);
    font-weight: 600;
}

.q-section-header {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 28px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--border-subtle);
}

.q-section-icon {
    width: 50px;
    height: 50px;
    background: var(--accent-tint);
    color: var(--accent-solid);
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
    flex-shrink: 0;
}

.q-section-header h4 { margin-bottom: 4px; font-size: 1.2rem; color: var(--text-primary); }
.q-section-header p { margin: 0; color: var(--text-secondary); font-size: 0.875rem; }

.q-input {
    background: var(--bg-elevated);
    border: 1.5px solid var(--border-medium);
    border-radius: var(--radius-sm);
    padding: 10px 14px;
    font-size: 0.9rem;
    color: var(--text-primary);
    transition: var(--transition);
}
.q-input:focus {
    border-color: var(--accent-solid);
    box-shadow: 0 0 0 3px var(--accent-tint);
    outline: none;
}

/* Goal Cards */
.goal-cards { display: flex; gap: 16px; flex-wrap: wrap; }
.goal-card { cursor: pointer; flex: 1; min-width: 150px; }
.goal-card input { display: none; }
.goal-card-inner {
    background: var(--bg-elevated);
    border: 2px solid var(--border-subtle);
    border-radius: var(--radius);
    padding: 22px 18px;
    text-align: center;
    transition: var(--transition);
}
.goal-card input:checked + .goal-card-inner {
    border-color: var(--accent-solid);
    background: var(--accent-tint);
}
.goal-card:hover .goal-card-inner { border-color: var(--border-accent); }
.goal-icon { font-size: 1.8rem; display: block; margin-bottom: 8px; }
.goal-card h5 { font-size: 0.95rem; margin-bottom: 4px; color: var(--text-primary); }
.goal-card p { font-size: 0.78rem; color: var(--text-secondary); margin: 0; }

/* Radio/Checkbox Pills */
.radio-pills, .checkbox-pills { display: flex; flex-wrap: wrap; gap: 10px 8px; align-items: center; }
.radio-pill, .checkbox-pill { cursor: pointer; display: inline-flex; align-items: center; margin: 0; }
.radio-pill input, .checkbox-pill input { display: none; }
.radio-pill span, .checkbox-pill span {
    display: inline-block;
    padding: 8px 18px;
    background: var(--bg-elevated);
    border: 1.5px solid var(--border-subtle);
    border-radius: 100px;
    font-size: 0.85rem;
    font-weight: 500;
    line-height: 1.35;
    transition: var(--transition);
    color: var(--text-secondary);
}
.radio-pill input:checked + span,
.checkbox-pill input:checked + span {
    background: var(--accent-solid);
    border-color: var(--accent-solid);
    color: #ffffff;
}
.radio-pill:hover span, .checkbox-pill:hover span {
    border-color: var(--border-accent);
}

/* Stress Cards */
.stress-cards { display: flex; gap: 12px; flex-wrap: wrap; }
.stress-card { cursor: pointer; flex: 1; min-width: 100px; }
.stress-card input { display: none; }
.stress-card > div {
    background: var(--bg-elevated);
    border: 1.5px solid var(--border-subtle);
    border-radius: var(--radius);
    padding: 18px;
    text-align: center;
    transition: var(--transition);
    font-size: 0.85rem;
    color: var(--text-primary);
}
.stress-card input:checked + div { border-color: var(--accent-solid); background: var(--accent-tint); }
.stress-low input:checked + div { border-color: #22c55e; background: rgba(34, 197, 94, 0.15); color: #4ade80; }
.stress-mod input:checked + div { border-color: #f59e0b; background: rgba(245, 158, 11, 0.15); color: #fbbf24; }
.stress-high input:checked + div { border-color: #ef4444; background: rgba(239, 68, 68, 0.15); color: #f87171; }

/* Work Cards */
.work-cards { display: flex; gap: 12px; flex-wrap: wrap; }
.work-card { cursor: pointer; flex: 1; min-width: 120px; }
.work-card input { display: none; }
.work-card-inner {
    background: var(--bg-elevated);
    border: 1.5px solid var(--border-subtle);
    border-radius: var(--radius);
    padding: 18px;
    text-align: center;
    transition: var(--transition);
    font-size: 0.85rem;
    color: var(--text-primary);
}
.work-card-inner span { font-size: 1.6rem; display: block; margin-bottom: 6px; }
.work-card-inner strong { display: block; margin-bottom: 4px; color: var(--text-primary); }
.work-card-inner small { color: var(--text-secondary); font-size: 0.75rem; }
.work-card input:checked + .work-card-inner { border-color: var(--accent-solid); background: var(--accent-tint); }

/* Water Cards */
.water-cards { display: flex; gap: 12px; flex-wrap: wrap; }
.water-card { cursor: pointer; flex: 1; min-width: 130px; }
.water-card input { display: none; }
.water-card-inner {
    background: var(--bg-elevated);
    border: 1.5px solid var(--border-subtle);
    border-radius: var(--radius);
    padding: 20px 14px;
    text-align: center;
    transition: var(--transition);
    font-size: 0.85rem;
    color: var(--text-primary);
}
.water-icon { font-size: 1.4rem; display: block; margin-bottom: 8px; }
.water-card-inner strong { display: block; font-size: 0.9rem; margin-bottom: 4px; color: var(--text-primary); }
.water-card-inner small { color: var(--text-secondary); font-size: 0.75rem; }
.water-card input:checked + .water-card-inner { border-color: var(--blue-500); background: rgba(59, 130, 246, 0.15); }

/* BMI Preview */
.bmi-preview {
    background: var(--slate-50);
    border: 1.5px solid var(--slate-200);
    border-radius: var(--radius);
    padding: 16px 20px;
    text-align: center;
}
.bmi-preview-label { font-size: 0.75rem; color: var(--slate-500); margin-bottom: 4px; }
.bmi-value-large { font-size: 2.5rem; font-weight: 800; font-family: 'Plus Jakarta Sans', sans-serif; color: var(--slate-900); }
.bmi-category { font-size: 0.85rem; font-weight: 600; }
.bmi-normal { color: var(--green-600); }
.bmi-low { color: var(--blue-500); }
.bmi-over { color: var(--amber-500); }
.bmi-obese { color: var(--red-500); }

.final-review {
    background: var(--green-50);
    border: 1.5px solid var(--green-200);
    border-radius: var(--radius);
    padding: 20px 24px;
}
.final-review h5 { color: var(--green-700); }
.final-review p { color: var(--slate-600); margin: 0; font-size: 0.9rem; }

.q-nav-buttons {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 14px;
    max-width: 800px;
    margin: 30px auto;
    padding: 0 16px;
    flex-wrap: nowrap;
}
.q-nav-buttons .btn {
    white-space: nowrap;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
}

/* ── AI Loading Overlay ── */
.ai-loading-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.85);
    z-index: 9999;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(4px);
}

.ai-loading-content {
    text-align: center;
    color: var(--white);
    max-width: 400px;
    padding: 40px;
}

.ai-spinner {
    position: relative;
    width: 80px;
    height: 80px;
    margin: 0 auto 24px;
}

.spinner-ring {
    position: absolute;
    width: 100%;
    height: 100%;
    border: 3px solid transparent;
    border-radius: 50%;
}
.spinner-ring:nth-child(1) { border-top-color: var(--green-400); animation: spin 1.2s linear infinite; }
.spinner-ring:nth-child(2) { width: 70%; height: 70%; top: 15%; left: 15%; border-top-color: var(--amber-400); animation: spin 0.9s linear infinite reverse; }
.spinner-ring:nth-child(3) { width: 40%; height: 40%; top: 30%; left: 30%; border-top-color: var(--white); animation: spin 0.6s linear infinite; }

@keyframes spin { to { transform: rotate(360deg); } }

.ai-loading-icon { font-size: 2.5rem; position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); }
.ai-spinner { position: relative; }

.ai-loading-title { font-size: 1.4rem; margin-bottom: 8px; }
.ai-loading-sub { color: rgba(255,255,255,0.7); font-size: 0.9rem; margin-bottom: 24px; }

.loading-steps { display: flex; flex-direction: column; gap: 8px; text-align: left; }
.loading-step {
    background: rgba(255,255,255,0.1);
    border-radius: var(--radius-sm);
    padding: 8px 14px;
    font-size: 0.85rem;
    color: rgba(255,255,255,0.5);
    transition: var(--transition);
}
.loading-step.active {
    background: var(--green-600);
    color: var(--white);
}
.loading-step.done {
    color: var(--green-400);
    background: rgba(34,197,94,0.1);
}

/* ── Results Page ── */
.results-page { background: transparent; min-height: 100vh; }

.results-header h1 { font-size: clamp(1.6rem, 3vw, 2.2rem); color: #ffffff; }
.results-sub { color: #94a3b8; margin-bottom: 24px; }
.results-celebration { font-size: 3rem; margin-bottom: 12px; }
.results-cta-row { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

.metric-result-card {
    background: rgba(15, 23, 42, 0.45);
    border-radius: var(--radius-lg);
    padding: 24px 16px;
    text-align: center;
    border: 1px solid rgba(255, 255, 255, 0.08);
    transition: var(--transition);
}
.metric-result-card.featured { border-color: rgba(34, 197, 94, 0.3); background: rgba(34, 197, 94, 0.08); }
.metric-result-card:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.metric-result-icon { font-size: 1.8rem; margin-bottom: 8px; }
.metric-result-value { font-size: 1.9rem; font-weight: 800; color: #ffffff; font-family: 'Plus Jakarta Sans', sans-serif; }
.metric-result-label { font-size: 0.75rem; color: #94a3b8; margin-bottom: 8px; }
.metric-result-badge { font-size: 0.72rem; font-weight: 600; padding: 3px 10px; border-radius: 100px; }
.badge-success { background: var(--green-100); color: var(--green-700); }
.badge-warning { background: #fffbeb; color: #92400e; }
.badge-danger { background: #fef2f2; color: #991b1b; }
.badge-info { background: #eff6ff; color: #1d4ed8; }

.results-card {
    background: rgba(15, 23, 42, 0.45);
    border-radius: var(--radius-xl);
    padding: 28px 30px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.37);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    color: #cbd5e1;
}

.card-section-title {
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-size: 1.05rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
}

/* Macros Display */
.macros-display { display: flex; gap: 16px; justify-content: center; margin-bottom: 20px; }
.macro-item { text-align: center; }
.macro-circle {
    position: relative;
    width: 72px;
    height: 72px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 6px;
    font-weight: 700;
    font-size: 0.9rem;
}
.macro-protein .macro-circle { background: #dcfce7; color: #166534; }
.macro-carbs .macro-circle { background: #fef3c7; color: #92400e; }
.macro-fats .macro-circle { background: #fee2e2; color: #991b1b; }
.macro-name { font-size: 0.75rem; font-weight: 600; color: var(--slate-700); }
.macro-cal { font-size: 0.7rem; color: var(--slate-400); }

/* Health Score */
.health-score-circle {
    width: 110px;
    height: 110px;
    border-radius: 50%;
    border: 8px solid;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
    flex-direction: column;
}
.score-success { border-color: var(--green-500); }
.score-info { border-color: var(--blue-500); }
.score-warning { border-color: var(--amber-500); }
.score-danger { border-color: var(--red-500); }
.health-score-num { font-size: 2rem; font-weight: 800; font-family: 'Plus Jakarta Sans', sans-serif; }
.health-score-100 { font-size: 0.7rem; color: var(--slate-400); }
.health-score-label { font-size: 0.9rem; font-weight: 600; }

.health-insights { display: flex; flex-direction: column; gap: 8px; }
.insight-item { font-size: 0.82rem; padding: 8px 12px; border-radius: var(--radius-sm); }
.insight-positive { background: var(--green-50); color: var(--green-700); }
.insight-warning { background: #fffbeb; color: #92400e; }

/* Meal Cards */
.meal-day-tabs { gap: 4px; }
.meal-day-tabs .nav-link {
    background: var(--slate-100);
    color: var(--slate-600);
    border-radius: var(--radius-sm);
    font-size: 0.85rem;
    padding: 6px 14px;
    font-weight: 500;
    white-space: nowrap;
}
.meal-day-tabs .nav-link.active { background: var(--green-600); color: var(--white); }

.meal-card {
    background: var(--slate-50);
    border: 1.5px solid var(--slate-200);
    border-radius: var(--radius);
    overflow: hidden;
    transition: var(--transition);
    height: 100%;
}
.meal-card:hover { border-color: var(--green-300); box-shadow: var(--shadow); }
.meal-card-header {
    background: var(--white);
    padding: 10px 14px;
    display: flex;
    align-items: center;
    gap: 8px;
    border-bottom: 1px solid var(--slate-200);
}
.meal-icon { font-size: 1rem; }
.meal-type { font-size: 0.75rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.5px; color: var(--slate-600); flex: 1; }
.meal-calories { font-size: 0.72rem; font-weight: 700; color: var(--green-600); }
.meal-card-body { padding: 14px; }
.meal-name { font-size: 0.9rem; font-weight: 700; color: var(--slate-900); margin-bottom: 4px; }
.meal-desc { font-size: 0.78rem; color: var(--slate-500); margin-bottom: 10px; line-height: 1.4; }
.meal-macros { display: flex; gap: 6px; flex-wrap: wrap; }
.macro-tag { font-size: 0.7rem; padding: 2px 8px; border-radius: 100px; font-weight: 600; }
.protein-tag { background: #dcfce7; color: #166534; }
.carb-tag { background: #fef3c7; color: #92400e; }
.fat-tag { background: #fee2e2; color: #991b1b; }

/* Lifestyle Tips */
.tips-list { display: flex; flex-direction: column; gap: 10px; }
.tip-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 12px 14px;
    background: var(--bg-elevated);
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-subtle);
    border-left: 3px solid var(--accent-solid);
}
.tip-number {
    width: 24px;
    height: 24px;
    background: var(--accent-solid);
    color: #ffffff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    font-weight: 700;
    flex-shrink: 0;
}
.tip-item p { margin: 0; font-size: 0.875rem; color: var(--text-secondary); }

/* User Summary Grid */
.user-summary-grid { display: flex; flex-direction: column; gap: 10px; }
.summary-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid var(--border-subtle);
    font-size: 0.85rem;
}
.summary-label { color: var(--text-secondary); font-weight: 500; }
.summary-value { font-weight: 600; color: var(--text-primary); }

/* ── Dashboard ── */
.dashboard-page { background: var(--bg-page); min-height: 100vh; color: var(--text-primary); }

.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 16px;
}
.dashboard-greeting { font-size: 1.8rem; color: var(--text-primary); margin-bottom: 4px; }
.dashboard-header-actions { display: flex; gap: 8px; flex-wrap: wrap; }

.dash-stat-card {
    background: var(--bg-surface);
    border-radius: var(--radius-lg);
    padding: 20px 16px;
    text-align: center;
    border: 1px solid var(--border-subtle);
    transition: var(--transition);
}
.dash-stat-card:hover { transform: translateY(-2px); box-shadow: var(--shadow); border-color: var(--border-medium); }
.dash-stat-icon { font-size: 1.5rem; margin-bottom: 6px; }
.dash-stat-value { font-size: 1.7rem; font-weight: 800; color: var(--text-primary); font-family: 'Plus Jakarta Sans', sans-serif; }
.dash-stat-label { font-size: 0.75rem; color: var(--text-secondary); }
.dash-stat-sub { font-size: 0.75rem; font-weight: 500; margin-top: 2px; }

.dash-card {
    background: var(--bg-surface);
    border-radius: var(--radius-xl);
    border: 1px solid var(--border-subtle);
    overflow: hidden;
    color: var(--text-primary);
}
.dash-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px 24px;
    border-bottom: 1px solid var(--border-subtle);
}
.dash-card-header h5 { margin: 0; font-size: 0.95rem; font-family: 'Plus Jakarta Sans', sans-serif; font-weight: 700; color: var(--text-primary); }
.dash-card-body { padding: 20px 24px; }

.empty-chart-state { text-align: center; padding: 40px; color: var(--text-muted); }
.empty-icon { font-size: 2.5rem; margin-bottom: 12px; }

.macro-legend { display: flex; flex-direction: column; gap: 4px; }
.macro-leg-item { display: flex; align-items: center; gap: 8px; font-size: 0.8rem; color: var(--text-secondary); }
.macro-leg-dot { width: 10px; height: 10px; border-radius: 50%; display: inline-block; }
.protein-dot { background: var(--accent-solid); }
.carb-dot { background: var(--amber-500); }
.fat-dot { background: var(--red-500); }

.goal-tracker-item { font-size: 0.85rem; }
.goal-tracker-label { display: flex; justify-content: space-between; align-items: center; margin-bottom: 4px; color: var(--text-primary); }
.goal-progress { height: 6px; border-radius: 10px; }

.dash-meal-card {
    background: var(--bg-elevated);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-sm);
    padding: 12px;
}
.dash-meal-header { font-size: 0.72rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.5px; color: var(--slate-500); margin-bottom: 4px; }
.dash-meal-name { font-size: 0.85rem; font-weight: 600; color: var(--slate-800); margin-bottom: 4px; }
.dash-meal-cal { font-size: 0.75rem; color: var(--green-600); font-weight: 600; }

.dash-tip-item {
    padding: 10px 12px;
    background: var(--slate-50);
    border-radius: var(--radius-sm);
    font-size: 0.85rem;
    color: var(--slate-700);
    border-left: 3px solid var(--green-400);
}

/* Modal */
.modal-custom { border-radius: var(--radius-xl); border: none; box-shadow: var(--shadow-lg); }
.modal-custom .modal-header { border-bottom: 1px solid var(--slate-100); padding: 20px 24px; }
.modal-custom .modal-body { padding: 20px 24px; }
.modal-custom .modal-footer { border-top: 1px solid var(--slate-100); padding: 16px 24px; }

/* ── Responsive ── */
@media (max-width: 768px) {
    .q-card { padding: 24px 20px; }
    .goal-cards { flex-direction: column; }
    .hero-stats { flex-direction: column; gap: 12px; }
    .stat-divider { display: none; }
    .q-nav-buttons { flex-direction: column; align-items: stretch; }
    .results-cta-row { flex-direction: column; }
    .dashboard-header { flex-direction: column; }
    .benefits-grid { grid-template-columns: 1fr; }
    .macros-display { justify-content: space-around; }
    .water-cards { flex-direction: column; }
    .work-cards { flex-direction: column; }
    .stress-cards { flex-direction: column; }
}

@media (max-width: 480px) {
    .hero-section { padding: 50px 0; }
    .section-how, .section-benefits, .section-metrics { padding: 60px 0; }
}

/* ── Print Styles ── */
@media print {
    .navbar-custom, .site-footer, .btn, nav { display: none !important; }
    .results-page { background: white; }
    .results-card { box-shadow: none; border: 1px solid #ccc; }
}

/* ═══════════════════════════════════════════════════════
   EATWELL + HARVARD PLATE ENHANCEMENTS
   ═══════════════════════════════════════════════════════ */

/* Eatwell section card */
.eatwell-section {
    background: rgba(15, 23, 42, 0.55);
    border: 1px solid rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.37);
}

/* Plate Visual */
.plate-visual-container {
    position: relative;
    display: inline-block;
}
.plate-center-label {
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1.2;
    pointer-events: none;
}
.plate-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
}
.plate-legend-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.8rem;
    color: var(--text-secondary);
    font-weight: 500;
}
.legend-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    flex-shrink: 0;
}

/* Plate Rules Grid */
.plate-rules-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}
.plate-rule-card {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 14px;
    border-radius: var(--radius-lg, 12px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(15, 23, 42, 0.45);
    transition: var(--transition);
}
.plate-rule-card:hover { transform: translateY(-1px); border-color: rgba(34, 197, 94, 0.25); }
.plate-rule-icon { font-size: 1.4rem; flex-shrink: 0; }
.plate-rule-content strong { display: block; font-size: 0.85rem; margin-bottom: 4px; color: #ffffff; }
.plate-rule-content p { font-size: 0.78rem; color: #94a3b8; margin: 0; line-height: 1.5; }

.veg-card     { background: rgba(34, 197, 94, 0.08); border-color: rgba(34, 197, 94, 0.25); }
.grain-card   { background: rgba(245, 158, 11, 0.08); border-color: rgba(245, 158, 11, 0.25); }
.protein-card { background: rgba(239, 68, 68, 0.08); border-color: rgba(239, 68, 68, 0.25); }
.fruit-card   { background: rgba(249, 115, 22, 0.08); border-color: rgba(249, 115, 22, 0.25); }
.oil-card     { background: rgba(132, 204, 22, 0.08); border-color: rgba(132, 204, 22, 0.25); }
.water-card   { background: rgba(6, 182, 212, 0.08); border-color: rgba(6, 182, 212, 0.25); }

/* Eatwell Traffic Light */
.eatwell-traffic-light {
    background: rgba(15, 23, 42, 0.45);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-lg, 12px);
    padding: 16px 20px;
}
.eatwell-traffic-light h6 { font-size: 0.9rem; font-weight: 700; color: #ffffff; }
.traffic-lights-row {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}
.traffic-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    text-align: center;
    padding: 10px 16px;
    border-radius: var(--radius-sm);
    min-width: 80px;
}
.traffic-item strong { font-size: 0.85rem; }
.traffic-item small { font-size: 0.7rem; color: var(--slate-500); }
.traffic-low { background: #f0fdf4; }
.traffic-high { background: #fef2f2; }
.traffic-dot {
    width: 20px; height: 20px;
    background: var(--green-500);
    border-radius: 50%;
    box-shadow: 0 0 8px rgba(34,197,94,0.4);
}
.traffic-dot-red {
    background: var(--red-500);
    box-shadow: 0 0 8px rgba(239,68,68,0.4);
}
.traffic-ref-text {
    font-size: 0.73rem;
    color: var(--slate-400);
    margin: 8px 0 0;
    font-style: italic;
}

/* Eatwell segment tags on meal cards */
.eatwell-tags { display: flex; flex-wrap: wrap; gap: 4px; }
.eatwell-tag {
    font-size: 0.62rem;
    padding: 2px 7px;
    border-radius: 100px;
    font-weight: 600;
    border: 1px solid;
}
.eatwell-vegetables  { background: #dcfce7; color: #166534; border-color: #86efac; }
.eatwell-whole-grains { background: #fef9c3; color: #713f12; border-color: #fde047; }
.eatwell-protein     { background: #ffe4e6; color: #9f1239; border-color: #fca5a5; }
.eatwell-fruits      { background: #ffedd5; color: #9a3412; border-color: #fdba74; }
.eatwell-dairy       { background: #eff6ff; color: #1e40af; border-color: #93c5fd; }
.eatwell-oils, .eatwell-healthy-oils { background: #f7fee7; color: #365314; border-color: #a3e635; }

/* Foods to Limit card */
.limit-card { border-left: 4px solid var(--red-400); }
.limit-pills { display: flex; flex-wrap: wrap; gap: 8px; }
.limit-pill {
    background: #fef2f2;
    border: 1px solid #fca5a5;
    color: #991b1b;
    font-size: 0.8rem;
    padding: 6px 12px;
    border-radius: 100px;
    font-weight: 500;
}

/* Source attribution */
.source-attribution {
    background: var(--slate-100);
    border: 1px solid var(--slate-200);
    border-radius: var(--radius);
    padding: 12px 18px;
    font-size: 0.78rem;
    color: var(--slate-500);
    margin-top: 8px;
    line-height: 1.6;
}

/* Responsive plate rules */
@media (max-width: 576px) {
    .plate-rules-grid { grid-template-columns: 1fr; }
    .traffic-lights-row { justify-content: center; }
}

/* ══════════════════════════════════════════════════════════════════════════
   FLASH MESSAGES (global)
════════════════════════════════════════════════════════════════════════════ */
.flash-global {
  position: fixed; top: 72px; right: 20px; z-index: 9999;
  display: flex; flex-direction: column; gap: 8px; max-width: 360px;
}
.flash-item {
  display: flex; align-items: center;
  background: #fff; border-radius: 12px;
  padding: 12px 16px; font-size: 0.85rem; font-weight: 500;
  box-shadow: 0 4px 20px rgba(0,0,0,0.12);
  border-left: 4px solid;
  animation: slideInRight 0.3s ease;
}
.flash-success { border-color: #22c55e; color: #166534; }
.flash-danger  { border-color: #ef4444; color: #991b1b; }
.flash-warning { border-color: #f59e0b; color: #92400e; }
.flash-info    { border-color: #3b82f6; color: #1e40af; }
.flash-close {
  background: none; border: none; margin-left: auto;
  font-size: 1.1rem; cursor: pointer; opacity: 0.5; line-height: 1;
}
.flash-close:hover { opacity: 1; }
@keyframes slideInRight {
  from { transform: translateX(100%); opacity: 0; }
  to   { transform: translateX(0);    opacity: 1; }
}

/* ══════════════════════════════════════════════════════════════════════════
   NAVBAR AUTH ELEMENTS
════════════════════════════════════════════════════════════════════════════ */
.btn-nav-cta {
  background: linear-gradient(135deg, #16a34a, #15803d) !important;
  color: #fff !important;
  border-radius: 100px !important;
  padding: 8px 18px !important;
  font-weight: 600 !important;
  font-size: 0.85rem !important;
  transition: all 0.2s !important;
}
.btn-nav-cta:hover { transform: translateY(-2px); box-shadow: 0 6px 18px rgba(22,163,74,0.35) !important; }
.nav-user-btn {
  display: flex !important; align-items: center; gap: 8px;
  background: #f0fdf4; border-radius: 100px;
  padding: 6px 14px 6px 6px !important;
  font-weight: 600; font-size: 0.85rem;
}
.nav-avatar {
  width: 28px; height: 28px; border-radius: 50%;
  background: #16a34a; color: #fff;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 0.75rem; font-weight: 700;
}
.user-dropdown { border-radius: 16px !important; border: 1px solid #e2e8f0 !important; padding: 6px !important; box-shadow: 0 10px 40px rgba(0,0,0,0.12) !important; min-width: 220px !important; }
.dropdown-header-info { display: flex; align-items: center; gap: 10px; padding: 8px 12px; }
.dh-avatar { width: 38px; height: 38px; border-radius: 50%; background: #16a34a; color: #fff; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 0.9rem; }
.dh-name  { font-weight: 700; font-size: 0.85rem; color: #0f172a; }
.dh-email { font-size: 0.73rem; color: #64748b; }
.user-dropdown .dropdown-item { border-radius: 10px; font-size: 0.85rem; font-weight: 500; padding: 8px 12px; }
.user-dropdown .dropdown-item:hover { background: #f0fdf4; color: #16a34a; }

/* ══════════════════════════════════════════════════════════════════════════
   AUTH PAGES (login / register)
════════════════════════════════════════════════════════════════════════════ */
.auth-page { min-height: 100vh; background: #f8fafc; }
.auth-split { display: flex; min-height: calc(100vh - 72px); }

/* Left decorative panel */
.auth-left {
  flex: 0 0 42%;
  background: linear-gradient(155deg, #0f172a 0%, #14532d 60%, #166534 100%);
  display: flex; align-items: center; justify-content: center;
  padding: 36px 32px;
  overflow-y: auto;
}
.auth-left-content { max-width: 390px; width: 100%; }
.auth-logo-mark { font-size: 2.5rem; margin-bottom: 16px; display: block; }
.auth-left-title { font-family: 'Plus Jakarta Sans', sans-serif; font-weight: 700; font-size: 1.75rem; color: #fff; margin-bottom: 8px; line-height: 1.25; }
.auth-left-sub   { color: #94a3b8; font-size: 0.88rem; margin-bottom: 20px; line-height: 1.6; }
.auth-perks      { margin-bottom: 20px; }
.auth-perk       { display: flex; align-items: center; gap: 10px; color: #e2e8f0; font-size: 0.85rem; margin-bottom: 8px; }
.perk-icon       { font-size: 1rem; }
.auth-quote {
  background: rgba(255,255,255,0.06);
  border-left: 3px solid #4ade80;
  border-radius: 0 10px 10px 0;
  padding: 14px 18px;
}
.quote-text   { color: #d1fae5; font-style: italic; font-size: 0.88rem; line-height: 1.6; }
.quote-author { color: #86efac; font-size: 0.78rem; margin-top: 6px; font-weight: 600; }

/* Right form panel */
.auth-right {
  flex: 1;
  display: flex; align-items: center; justify-content: center;
  padding: 48px 40px;
}
.auth-form-wrap { width: 100%; max-width: 420px; }
.auth-form-header { margin-bottom: 28px; }
.auth-form-header h3 { font-family: 'Plus Jakarta Sans', sans-serif; font-weight: 700; font-size: 1.6rem; color: #0f172a; margin-bottom: 6px; }
.auth-form-header p  { font-size: 0.85rem; color: #64748b; }
.auth-form-header a  { color: #16a34a; font-weight: 600; }

.auth-error {
  background: #fef2f2; border: 1px solid #fca5a5; color: #991b1b;
  border-radius: 12px; padding: 11px 14px; font-size: 0.85rem; margin-bottom: 20px;
  display: flex; align-items: center;
}
.auth-field { margin-bottom: 18px; }
.auth-field label { font-size: 0.83rem; font-weight: 700; color: #334155; display: block; margin-bottom: 6px; }
.auth-input-wrap { position: relative; }
.auth-input-icon { position: absolute; left: 13px; top: 50%; transform: translateY(-50%); color: #94a3b8; font-size: 0.9rem; pointer-events: none; }
.auth-input {
  width: 100%; border: 1.5px solid #e2e8f0; border-radius: 12px;
  padding: 11px 40px 11px 38px; font-size: 0.9rem; font-family: 'Plus Jakarta Sans', sans-serif;
  transition: all 0.2s; background: #fff; color: #0f172a;
}
.auth-input:focus { outline: none; border-color: #16a34a; box-shadow: 0 0 0 3px rgba(22,163,74,0.1); }
.auth-eye {
  position: absolute; right: 12px; top: 50%; transform: translateY(-50%);
  background: none; border: none; color: #94a3b8; cursor: pointer; font-size: 1rem; padding: 0;
}
.auth-eye:hover { color: #475569; }
.pw-strength-bar { height: 4px; background: #e2e8f0; border-radius: 2px; overflow: hidden; }
.pw-strength-bar div { height: 100%; border-radius: 2px; transition: all 0.3s; width: 0; }
.pw-strength-label { font-size: 0.73rem; font-weight: 600; margin-top: 3px; min-height: 16px; }
.match-msg { font-size: 0.78rem; font-weight: 600; margin-top: 4px; min-height: 16px; }
.auth-terms { margin-bottom: 20px; }
.auth-check-label { display: flex; align-items: flex-start; gap: 10px; font-size: 0.82rem; color: #475569; cursor: pointer; }
.auth-check-label input { margin-top: 4px; accent-color: #16a34a; flex-shrink: 0; }
.auth-check-label span { display: inline; line-height: 1.4; }
.auth-check-label a { color: #16a34a; font-weight: 600; display: inline; text-decoration: underline; }
.auth-btn {
  width: 100%; background: linear-gradient(135deg, #16a34a, #15803d);
  color: #fff; border: none; border-radius: 12px;
  padding: 13px; font-size: 0.95rem; font-weight: 700; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: all 0.2s;
}
.auth-btn:hover { transform: translateY(-2px); box-shadow: 0 8px 22px rgba(22,163,74,0.35); }
.auth-btn:disabled { opacity: 0.7; transform: none; }
.auth-divider { text-align: center; color: #94a3b8; font-size: 0.78rem; margin: 16px 0; position: relative; }
.auth-divider::before { content: ''; position: absolute; left: 0; right: 0; top: 50%; height: 1px; background: #e2e8f0; }
.auth-divider span { background: #f8fafc; padding: 0 12px; position: relative; }
.auth-btn-ghost {
  width: 100%; background: transparent;
  color: #475569; border: 1.5px solid #e2e8f0; border-radius: 12px;
  padding: 11px; font-size: 0.88rem; font-weight: 600; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  text-decoration: none; transition: all 0.2s;
}
.auth-btn-ghost:hover { border-color: #94a3b8; color: #0f172a; background: #f1f5f9; }

.google-auth-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 100%;
  padding: 12px;
  background: #ffffff;
  border: 1.5px solid #e2e8f0;
  border-radius: 12px;
  color: #334155;
  font-weight: 700;
  font-size: 0.9rem;
  text-decoration: none;
  transition: all 0.2s ease;
  margin-top: 10px;
  cursor: pointer;
  box-sizing: border-box;
}
.google-auth-btn:hover {
  background: #f8fafc;
  border-color: #cbd5e1;
  color: #0f172a;
}
.google-icon {
  width: 18px;
  height: 18px;
}

@media (max-width: 768px) {
  .auth-left { display: none; }
  .auth-right { padding: 32px 20px; }
}

/* ══════════════════════════════════════════════════════════════════════════
   MY DASHBOARD PAGE
════════════════════════════════════════════════════════════════════════════ */
.mydb-page { background: #f8fafc; min-height: 100vh; }
.mydb-hero {
  background: linear-gradient(135deg, #0f172a 0%, #14532d 100%);
  padding: 40px 0 36px;
}
.mydb-hero-inner { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; }
.mydb-avatar {
  width: 64px; height: 64px; border-radius: 50%;
  background: linear-gradient(135deg, #22c55e, #16a34a);
  color: #fff; font-size: 1.6rem; font-weight: 800;
  display: flex; align-items: center; justify-content: center;
  border: 3px solid rgba(255,255,255,0.2); flex-shrink: 0;
}
.mydb-greeting { font-family: 'Plus Jakarta Sans', sans-serif; font-weight: 700; font-size: 1.6rem; color: #fff; margin: 0; }
.mydb-sub      { color: #94a3b8; font-size: 0.82rem; margin: 4px 0 0; }
.mydb-hero-actions { margin-left: auto; display: flex; gap: 10px; }
.btn-mydb-primary {
  background: linear-gradient(135deg,#22c55e,#16a34a); color:#fff;
  border:none; border-radius:100px; padding:10px 22px;
  font-size:0.88rem; font-weight:700; text-decoration:none;
  display:inline-flex; align-items:center; transition:all 0.2s;
}
.btn-mydb-primary:hover { color:#fff; transform:translateY(-2px); box-shadow:0 6px 18px rgba(34,197,94,0.35); }
.btn-mydb-outline {
  background:rgba(255,255,255,0.08); color:#e2e8f0;
  border:1.5px solid rgba(255,255,255,0.2); border-radius:100px;
  padding:9px 18px; font-size:0.85rem; font-weight:600;
  text-decoration:none; display:inline-flex; align-items:center; gap:6px; transition:all 0.2s;
}
.btn-mydb-outline:hover { background:rgba(255,255,255,0.15); color:#fff; }

.mydb-content { padding: 32px 0 60px; }

/* Stats row */
.mydb-stats-row { display:grid; grid-template-columns:repeat(4,1fr); gap:14px; margin-bottom:28px; }
.mydb-stat-card { background:#fff; border-radius:16px; padding:20px 18px; border:1.5px solid #e2e8f0; display:flex; flex-direction:column; align-items:center; text-align:center; }
.mydb-stat-icon { width:44px; height:44px; border-radius:12px; display:flex; align-items:center; justify-content:center; font-size:1.3rem; margin-bottom:10px; }
.mydb-stat-val  { font-family:'Plus Jakarta Sans',sans-serif; font-size:1.8rem; font-weight:800; color:#0f172a; line-height:1; }
.mydb-stat-label{ font-size:0.75rem; color:#64748b; margin-top:4px; }

/* Section title */
.mydb-section-title { display:flex; justify-content:space-between; align-items:center; margin-bottom:18px; }
.mydb-section-title h2 { font-family:'Plus Jakarta Sans',sans-serif; font-weight:700; font-size:1.3rem; color:#0f172a; margin:0; }
.mydb-add-btn {
  background:#f0fdf4; color:#16a34a; border:1.5px solid #86efac;
  border-radius:100px; padding:7px 16px; font-size:0.82rem; font-weight:700;
  text-decoration:none; display:flex; align-items:center; gap:6px; transition:all 0.15s;
}
.mydb-add-btn:hover { background:#16a34a; color:#fff; }

/* Plans grid */
.mydb-plans-grid { display:grid; grid-template-columns:repeat(auto-fill,minmax(320px,1fr)); gap:20px; }
.mydb-plan-card  { background:#fff; border-radius:18px; border:1.5px solid #e2e8f0; overflow:hidden; transition:all 0.2s; }
.mydb-plan-card:hover { transform:translateY(-3px); box-shadow:0 10px 30px rgba(0,0,0,0.08); }
.mydb-plan-card-header { display:flex; align-items:center; gap:12px; padding:18px 18px 14px; }
.mydb-plan-avatar { width:42px; height:42px; border-radius:50%; color:#fff; display:flex; align-items:center; justify-content:center; font-size:1.1rem; font-weight:800; flex-shrink:0; }
.mydb-plan-name  { font-weight:700; font-size:0.95rem; color:#0f172a; }
.mydb-plan-meta  { font-size:0.75rem; color:#64748b; }
.mydb-goal-badge { font-size:0.68rem; padding:3px 10px; border-radius:100px; font-weight:700; margin-left:auto; white-space:nowrap; }
.goal-weight_loss{ background:#fee2e2;color:#991b1b; }
.goal-muscle_gain{ background:#dcfce7;color:#166534; }
.goal-maintain   { background:#eff6ff;color:#1e40af; }

/* Metrics */
.mydb-plan-metrics { display:grid; grid-template-columns:repeat(4,1fr); gap:0; padding:10px 18px; background:#f8fafc; border-top:1px solid #f1f5f9; border-bottom:1px solid #f1f5f9; }
.mpmetric { text-align:center; padding:8px 4px; }
.mpmetric-val   { font-size:1.1rem; font-weight:800; color:#0f172a; font-family:'Plus Jakarta Sans',sans-serif; }
.mpmetric-label { font-size:0.65rem; color:#94a3b8; margin-top:2px; }
.mpmetric-cat   { font-size:0.62rem; font-weight:700; margin-top:2px; }
.val-green { color:#16a34a; }
.val-amber { color:#d97706; }
.val-red   { color:#dc2626; }

/* Macro bar */
.mydb-macro-bar { display:flex; height:6px; margin:12px 18px 4px; border-radius:3px; overflow:hidden; gap:2px; }
.mydb-macro-bar div { border-radius:2px; }
.mydb-macro-labels { display:flex; justify-content:space-between; padding:0 18px; font-size:0.72rem; font-weight:700; margin-bottom:8px; }

.mydb-weight-row { padding:6px 18px 10px; font-size:0.8rem; color:#475569; display:flex; align-items:center; gap:6px; flex-wrap:wrap; }
.mydb-plan-card-footer { display:flex; align-items:center; justify-content:space-between; padding:12px 18px; border-top:1px solid #f1f5f9; }
.mydb-date { font-size:0.72rem; color:#94a3b8; }
.mydb-card-actions { display:flex; gap:8px; }
.btn-card-view {
  background:#f0fdf4; color:#16a34a; border:1px solid #86efac;
  border-radius:8px; padding:5px 12px; font-size:0.78rem; font-weight:700;
  text-decoration:none; display:inline-flex; align-items:center; gap:5px; transition:all 0.15s;
}
.btn-card-view:hover { background:#16a34a; color:#fff; }
.btn-card-track {
  background:#eff6ff; color:#2563eb; border:1px solid #bfdbfe;
  border-radius:8px; padding:5px 12px; font-size:0.78rem; font-weight:700;
  text-decoration:none; display:inline-flex; align-items:center; gap:5px; transition:all 0.15s;
}
.btn-card-track:hover { background:#2563eb; color:#fff; }
.mydb-no-plan { text-align:center; padding:24px; color:#94a3b8; font-size:0.85rem; }

/* Empty state */
.mydb-empty { text-align:center; padding:80px 20px; }
.mydb-empty-icon { font-size:4rem; margin-bottom:16px; }
.mydb-empty h3   { font-family:'Plus Jakarta Sans',sans-serif; font-weight:700; font-size:1.5rem; color:#0f172a; margin-bottom:8px; }
.mydb-empty p    { color:#64748b; font-size:0.9rem; }

/* ══════════════════════════════════════════════════════════════════════════
   SETTINGS PAGE
════════════════════════════════════════════════════════════════════════════ */
.settings-page { background:#f8fafc; min-height:100vh; }
.settings-header { margin-bottom:28px; }
.settings-back { font-size:0.82rem; color:#64748b; text-decoration:none; display:inline-flex; align-items:center; gap:4px; margin-bottom:10px; }
.settings-back:hover { color:#16a34a; }
.settings-title { font-family:'Plus Jakarta Sans',sans-serif; font-weight:700; font-size:1.8rem; color:#0f172a; margin:0; }
.settings-card  { background:#fff; border-radius:18px; border:1.5px solid #e2e8f0; padding:24px 28px; margin-bottom:20px; }
.settings-card-header { display:flex; align-items:center; gap:16px; }
.settings-avatar { width:64px; height:64px; border-radius:50%; background:linear-gradient(135deg,#22c55e,#16a34a); color:#fff; display:flex; align-items:center; justify-content:center; font-size:1.6rem; font-weight:800; flex-shrink:0; }
.settings-name     { font-weight:700; font-size:1.05rem; color:#0f172a; }
.settings-email-tag{ font-size:0.82rem; color:#64748b; }
.settings-member   { font-size:0.75rem; color:#94a3b8; margin-top:2px; }
.settings-card-title { font-size:0.9rem; font-weight:700; color:#334155; margin-bottom:18px; display:flex; align-items:center; }
.settings-form-row { display:grid; grid-template-columns:1fr 1fr; gap:16px; margin-bottom:18px; }
.settings-field label { font-size:0.82rem; font-weight:700; color:#334155; display:block; margin-bottom:6px; }
.settings-input {
  width:100%; border:1.5px solid #e2e8f0; border-radius:12px;
  padding:10px 40px 10px 14px; font-size:0.88rem; font-family:'Plus Jakarta Sans',sans-serif;
  transition:all 0.2s; background:#fff; color:#0f172a;
}
.settings-input:focus { outline:none; border-color:#16a34a; box-shadow:0 0 0 3px rgba(22,163,74,0.1); }
.settings-btn-save {
  background:linear-gradient(135deg,#16a34a,#15803d); color:#fff;
  border:none; border-radius:100px; padding:10px 22px;
  font-size:0.88rem; font-weight:700; cursor:pointer;
  display:inline-flex; align-items:center; transition:all 0.2s;
}
.settings-btn-save:hover { transform:translateY(-1px); box-shadow:0 5px 15px rgba(22,163,74,0.3); }
.settings-danger-card { border-color:#fca5a5; }
.settings-btn-danger {
  background:#fef2f2; color:#dc2626; border:1.5px solid #fca5a5;
  border-radius:100px; padding:9px 20px; font-size:0.85rem; font-weight:700;
  text-decoration:none; display:inline-flex; align-items:center; transition:all 0.2s;
}
.settings-btn-danger:hover { background:#dc2626; color:#fff; }

@media (max-width: 640px) {
  .mydb-stats-row     { grid-template-columns: 1fr 1fr; }
  .mydb-hero-actions  { width:100%; }
  .settings-form-row  { grid-template-columns: 1fr; }
  .mydb-plans-grid    { grid-template-columns: 1fr; }
}

/* Diet type notice banners */
.diet-notice {
  background: #f0fdf4; border: 1.5px solid #86efac; color: #166534;
  border-radius: 12px; padding: 12px 16px; margin-top: 14px;
  font-size: 0.88rem; font-weight: 600; display: flex; align-items: center; gap: 8px;
}
.diet-notice-blue { background: #eff6ff; border-color: #93c5fd; color: #1e40af; }
.diet-notice i { font-size: 1.1rem; }

/* Work card 4-col variant */
.work-cards { display: grid; grid-template-columns: repeat(4,1fr); gap: 12px; }
@media (max-width: 768px) { .work-cards { grid-template-columns: repeat(2,1fr); } }

/* Final review grid */
.final-review-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 10px; }
.review-item { background: #f8fafc; border: 1px solid #e2e8f0; border-radius: 10px; padding: 10px 14px; }
.review-key  { display: block; font-size: 0.72rem; color: #64748b; font-weight: 600; text-transform: uppercase; letter-spacing: 0.4px; }
.review-val  { display: block; font-size: 0.9rem; font-weight: 700; color: #0f172a; margin-top: 2px; }
@media (max-width: 640px) { .final-review-grid { grid-template-columns: 1fr 1fr; } }

/* Admin extra detail panels */
.admin-detail-section { margin-bottom: 20px; }
.admin-detail-section .section-label {
  font-size: 0.7rem; font-weight: 800; text-transform: uppercase; letter-spacing: 1px;
  color: #64748b; margin-bottom: 10px; display: flex; align-items: center; gap: 6px;
}
.detail-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 8px; }
.detail-item { background: #f8fafc; border: 1px solid #e2e8f0; border-radius: 10px; padding: 10px 13px; }
.detail-item .dk { font-size: 0.7rem; color: #94a3b8; font-weight: 700; text-transform: uppercase; }
.detail-item .dv { font-size: 0.85rem; font-weight: 700; color: #0f172a; margin-top: 2px; word-break: break-word; }
@media (max-width: 900px) { .detail-grid { grid-template-columns: 1fr 1fr; } }

/* ══════════════════════════════════════════════════════════════════════
   STATS BANNER (live user counts)
══════════════════════════════════════════════════════════════════════ */
.stats-banner {
  background: linear-gradient(135deg, #0f172a, #14532d);
  padding: 18px 0; border-bottom: 1px solid rgba(255,255,255,0.06);
}
.stats-banner-inner {
  display: flex; justify-content: center; align-items: center;
  gap: 0; flex-wrap: wrap;
}
.sb-stat { text-align: center; padding: 8px 32px; }
.sb-num  { display: block; font-family: 'Plus Jakarta Sans', sans-serif; font-size: 1.6rem; font-weight: 800; color: #4ade80; line-height: 1; }
.sb-label{ display: block; font-size: 0.72rem; color: #94a3b8; margin-top: 3px; font-weight: 500; }
.sb-divider { width: 1px; height: 40px; background: rgba(255,255,255,0.1); }

/* Trust badges */
.trust-row { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 14px; }
.trust-badge {
  background: rgba(34,197,94,0.1); border: 1px solid rgba(34,197,94,0.2);
  color: #d1fae5; padding: 5px 12px; border-radius: 100px;
  font-size: 0.78rem; font-weight: 500;
}

/* ══════════════════════════════════════════════════════════════════════
   DIET TYPE CARDS
══════════════════════════════════════════════════════════════════════ */
.section-diet-types { background: #f8fafc; padding: 72px 0; }
.diet-type-card {
  background: #fff; border-radius: 18px; padding: 28px 24px;
  border: 2px solid; text-align: center; height: 100%;
  transition: transform 0.2s;
}
.diet-type-card:hover { transform: translateY(-4px); }
.diet-veg   { border-color: #86efac; }
.diet-vegan { border-color: #6ee7b7; }
.diet-nonveg{ border-color: #fcd34d; }
.dtc-icon { font-size: 2.5rem; margin-bottom: 12px; display: block; }
.diet-type-card h5 { font-family: 'Plus Jakarta Sans', sans-serif; font-weight: 700; font-size: 1.2rem; margin-bottom: 8px; }
.diet-type-card p  { font-size: 0.85rem; color: #64748b; line-height: 1.6; margin-bottom: 14px; }
.dtc-badge {
  display: inline-block; font-size: 0.72rem; font-weight: 700;
  padding: 4px 12px; border-radius: 100px;
  background: #dcfce7; color: #166534;
}

/* ══════════════════════════════════════════════════════════════════════
   MEDICAL CONDITIONS GRID
══════════════════════════════════════════════════════════════════════ */
.section-medical { padding: 80px 0; }
.medical-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.medical-item {
  display: flex; align-items: flex-start; gap: 12px;
  background: #fff; border-radius: 14px; padding: 14px 16px;
  border: 1.5px solid #e2e8f0; transition: all 0.15s;
}
.medical-item:hover { border-color: #86efac; box-shadow: 0 4px 12px rgba(22,163,74,0.08); }
.medical-icon { font-size: 1.4rem; flex-shrink: 0; margin-top: 1px; }
.medical-name { font-weight: 700; font-size: 0.88rem; color: #0f172a; }
.medical-tip  { font-size: 0.75rem; color: #64748b; margin-top: 2px; }

/* CTA outline button */
.btn-cta-outline {
  background: transparent; color: #fff;
  border: 2px solid rgba(255,255,255,0.4); border-radius: 100px;
  padding: 12px 28px; font-weight: 700; font-size: 1rem;
  text-decoration: none; display: inline-flex; align-items: center;
  transition: all 0.2s;
}
.btn-cta-outline:hover { background: rgba(255,255,255,0.1); color: #fff; }

/* ══════════════════════════════════════════════════════════════════════
   FOOD DIARY (dashboard)
══════════════════════════════════════════════════════════════════════ */
.diary-section { background: #fff; border-radius: 18px; border: 1.5px solid #e2e8f0; margin-bottom: 24px; overflow: hidden; }
.diary-header  { padding: 18px 22px 14px; border-bottom: 1px solid #f1f5f9; display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 10px; }
.diary-header h5 { margin: 0; font-size: 0.95rem; font-weight: 700; }
.diary-totals  { display: flex; gap: 16px; font-size: 0.78rem; flex-wrap: wrap; }
.dt-item { text-align: center; }
.dt-val  { font-weight: 800; font-size: 1rem; color: #0f172a; display: block; }
.dt-lbl  { color: #94a3b8; font-size: 0.68rem; }
.diary-add-form { padding: 16px 22px; background: #f8fafc; border-bottom: 1px solid #f1f5f9; }
.diary-add-form .row { gap: 0; }
.diary-form-input { border: 1.5px solid #e2e8f0; border-radius: 10px; padding: 8px 12px; font-size: 0.85rem; width: 100%; }
.diary-form-input:focus { outline: none; border-color: #16a34a; box-shadow: 0 0 0 3px rgba(22,163,74,0.1); }
.btn-diary-add { background: #16a34a; color: #fff; border: none; border-radius: 10px; padding: 9px 20px; font-size: 0.85rem; font-weight: 700; cursor: pointer; white-space: nowrap; }
.btn-diary-add:hover { background: #15803d; }
.diary-entries { padding: 12px 22px; }
.diary-entry { display: flex; align-items: center; gap: 12px; padding: 8px 0; border-bottom: 1px solid #f1f5f9; font-size: 0.83rem; }
.diary-entry:last-child { border-bottom: none; }
.de-type { font-size: 0.65rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px; padding: 2px 8px; border-radius: 100px; flex-shrink: 0; }
.de-breakfast { background: #fef3c7; color: #92400e; }
.de-lunch     { background: #dcfce7; color: #166534; }
.de-dinner    { background: #eff6ff; color: #1e40af; }
.de-snack     { background: #fdf4ff; color: #7e22ce; }
.de-name { flex: 1; font-weight: 600; color: #0f172a; }
.de-cal  { font-size: 0.78rem; color: #16a34a; font-weight: 700; margin-left: auto; }
.de-del  { background: none; border: none; color: #94a3b8; cursor: pointer; font-size: 0.85rem; padding: 0 4px; }
.de-del:hover { color: #ef4444; }
.diary-empty { text-align: center; padding: 28px; color: #94a3b8; font-size: 0.85rem; }

/* ══════════════════════════════════════════════════════════════
   MEAL SWAP BUTTON
══════════════════════════════════════════════════════════════ */
.btn-swap-meal {
  width: 100%; margin-top: 10px;
  background: #f8fafc; color: #475569;
  border: 1.5px solid #e2e8f0; border-radius: 100px;
  padding: 7px; font-size: 0.78rem; font-weight: 600;
  cursor: pointer; transition: all 0.15s;
  display: flex; align-items: center; justify-content: center;
}
.btn-swap-meal:hover { background: #16a34a; color: #fff; border-color: #16a34a; }

/* ══════════════════════════════════════════════════════════════
   GROCERY LIST
══════════════════════════════════════════════════════════════ */
.grocery-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
.grocery-category { background: #f8fafc; border-radius: 12px; padding: 12px 14px; border: 1px solid #e2e8f0; }
.grocery-cat-header { font-size: 0.82rem; font-weight: 700; color: #334155; margin-bottom: 8px; }
.grocery-item { font-size: 0.82rem; color: #475569; padding: 4px 0; border-bottom: 1px solid #f1f5f9; display: flex; align-items: center; }
.grocery-item:last-child { border-bottom: none; }

/* ══════════════════════════════════════════════════════════════
   FOOD SCAN & VOICE ZONES
══════════════════════════════════════════════════════════════ */
.scan-zone {
  background: #f8fafc; border: 2px dashed #e2e8f0; border-radius: 16px;
  padding: 16px; cursor: pointer; transition: all 0.2s; min-height: 160px;
  display: flex; flex-direction: column; justify-content: center;
}
.scan-zone:hover { border-color: #16a34a; background: #f0fdf4; }
.scan-placeholder { text-align: center; }
.btn-voice {
  width: 100%; background: linear-gradient(135deg, #16a34a, #15803d);
  color: #fff; border: none; border-radius: 100px;
  padding: 10px; font-size: 0.85rem; font-weight: 700;
  cursor: pointer; display: flex; align-items: center; justify-content: center;
  transition: all 0.2s;
}
.btn-voice:hover { transform: translateY(-1px); box-shadow: 0 5px 15px rgba(22,163,74,0.35); }

@media (max-width: 640px) {
  .grocery-grid { grid-template-columns: 1fr 1fr; }
  .scan-zone { min-height: 120px; }
}

/* ══════════════════════════════════════════════════════════════════════════
   PREMIUM UI ENHANCEMENTS — Bio-Luminescent Precision
════════════════════════════════════════════════════════════════════════════ */

/* ── Enhanced Hero Image ─────────────────────────────────────────── */
.hero-image-container {
    position: relative;
    margin-top: 2rem;
}
.hero-image-container img {
    width: 100%;
    max-width: 500px;
    border-radius: var(--radius-lg);
    box-shadow: 0 0 60px rgba(34, 197, 94, 0.15),
                0 20px 40px rgba(0, 0, 0, 0.3);
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}
.hero-image-container img:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 0 80px rgba(34, 197, 94, 0.25),
                0 30px 60px rgba(0, 0, 0, 0.4);
}

/* ── Section Images ──────────────────────────────────────────────── */
.section-illustration {
    width: 100%;
    max-width: 600px;
    margin: 0 auto 2rem;
    display: block;
    border-radius: var(--radius);
    opacity: 0.9;
}

/* ── Animated Gradient Border Cards ──────────────────────────────── */
.glow-card {
    position: relative;
    background: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius);
    overflow: hidden;
    transition: all 0.3s ease;
}
.glow-card::before {
    content: '';
    position: absolute;
    top: -1px;
    left: -1px;
    right: -1px;
    bottom: -1px;
    background: linear-gradient(135deg, rgba(34, 197, 94, 0.3), transparent 50%, rgba(6, 182, 212, 0.2));
    border-radius: inherit;
    z-index: -1;
    opacity: 0;
    transition: opacity 0.3s ease;
}
.glow-card:hover::before {
    opacity: 1;
}
.glow-card:hover {
    transform: translateY(-4px);
    border-color: rgba(34, 197, 94, 0.2);
    box-shadow: 0 0 30px rgba(34, 197, 94, 0.1);
}

/* ── Floating animation for decorative elements ──────────────────── */
@keyframes float-gentle {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-12px); }
}
.float-animate {
    animation: float-gentle 4s ease-in-out infinite;
}

/* ── Pulse glow for CTA buttons ──────────────────────────────────── */
@keyframes pulse-glow {
    0%, 100% { box-shadow: 0 0 20px rgba(34, 197, 94, 0.3); }
    50% { box-shadow: 0 0 40px rgba(34, 197, 94, 0.6), 0 0 60px rgba(34, 197, 94, 0.2); }
}
.pulse-glow-btn {
    animation: pulse-glow 2s ease-in-out infinite;
}

/* ── Improved section headings ───────────────────────────────────── */
.section-heading-enhanced {
    position: relative;
    display: inline-block;
}
.section-heading-enhanced::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, #22c55e, #06b6d4);
    border-radius: 2px;
}

/* ── Stats counter animation ─────────────────────────────────────── */
.stat-number {
    font-family: 'Manrope', sans-serif;
    font-weight: 800;
    background: linear-gradient(135deg, #22c55e, #4ade80);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ── Auth page illustration ──────────────────────────────────────── */
.auth-illustration {
    width: 100%;
    max-width: 400px;
    margin: 2rem auto;
    display: block;
    border-radius: var(--radius-lg);
    filter: drop-shadow(0 0 30px rgba(34, 197, 94, 0.15));
}

/* ── Google Translate Custom Styling ── */
#google_translate_element {
    display: inline-flex;
    align-items: center;
}
.goog-logo-link {
    display: none !important;
}
.goog-te-gadget {
    color: transparent !important;
    font-size: 0px !important;
}
.goog-te-gadget .goog-te-combo {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%2316a34a' class='bi bi-translate' viewBox='0 0 16 16'%3E%3Cpath d='M4.545 6.714 4.11 8H3l1.862-5h1.284L8 8H6.833l-.408-1.286H4.545zm.341-1.02h1.503L5.617 3.185z'/%3E%3Cpath d='M11.5 7.5a.5.5 0 0 1 .5-.5h3.9a.5.5 0 0 1 0 1H14.8c-.2.726-.646 1.41-1.284 2.036 1.002.733 2.19 1.1 3.584 1.1a.5.5 0 0 1-.778.63C15 11.7 13.9 11.3 13 10.6c-.9.7-2 1.1-3.3 1.1a.5.5 0 0 1-.5-.5c0-1.2.9-2.2 2-3a5.4 5.4 0 0 1-1.2-1.7H11.5a.5.5 0 0 1 0-1zm1.2 2.6c.5-.4.9-.9 1.2-1.4h-2.4c.3.5.7 1 1.2 1.4z'/%3E%3C/svg%3E"),
                      url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%2364748b' class='bi bi-chevron-down' viewBox='0 0 16 16'%3E%3Cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3E%3C/svg%3E");
    background-repeat: no-repeat, no-repeat;
    background-position: 12px center, calc(100% - 14px) center;
    background-size: 16px, 10px;
    background-color: var(--white) !important;
    border: 1.5px solid var(--slate-200) !important;
    color: var(--slate-700) !important;
    font-family: 'Plus Jakarta Sans', sans-serif !important;
    font-size: 0.85rem !important;
    font-weight: 600 !important;
    padding: 8px 32px 8px 36px !important;
    border-radius: 100px !important;
    outline: none !important;
    cursor: pointer !important;
    transition: var(--transition) !important;
    box-shadow: var(--shadow-sm);
}
.goog-te-gadget .goog-te-combo:hover {
    background-color: var(--green-50) !important;
    border-color: var(--green-500) !important;
    color: var(--green-700) !important;
    transform: translateY(-1px);
    box-shadow: var(--shadow);
}
/* Hide the Google Translate banner on top of the page */
iframe.goog-te-banner-frame {
    display: none !important;
}
body {
    top: 0px !important;
}
.goog-tooltip {
    display: none !important;
}
.goog-tooltip:hover {
    display: none !important;
}
.goog-text-highlight {
    background-color: transparent !important;
    border: none !important;
    box-shadow: none !important;
}

/* ══════════════════════════════════════════════════════════════════════════════
   LAB REPORT FEATURE STYLES
   ══════════════════════════════════════════════════════════════════════════════ */

/* ── Page Layout ── */
.lab-reports-page { min-height: 100vh; }
.lab-page-header {
    display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px;
}
.lab-page-title {
    font-size: 1.6rem; font-weight: 800; display: flex; align-items: center; gap: 8px;
}
.lab-page-actions { display: flex; gap: 8px; }

/* ── Beta Badge ── */
.beta-badge {
    display: inline-block; font-size: 0.55rem; font-weight: 900; letter-spacing: 1.5px;
    padding: 3px 10px; border-radius: 20px; vertical-align: middle;
    background: linear-gradient(135deg, #f59e0b, #ef4444);
    color: #fff; animation: beta-pulse 2s ease-in-out infinite;
    text-transform: uppercase;
}
@keyframes beta-pulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(245,158,11,0.4); }
    50%      { box-shadow: 0 0 0 8px rgba(245,158,11,0); }
}

/* ── Disclaimer Banner ── */
.lab-disclaimer-banner {
    background: rgba(245,158,11,0.12); border: 1px solid rgba(245,158,11,0.25);
    border-radius: 12px; padding: 12px 18px; font-size: 0.82rem; color: #d97706;
    display: flex; align-items: center; gap: 4px;
}
.dark-theme .lab-disclaimer-banner,
[data-theme="dark"] .lab-disclaimer-banner {
    background: rgba(245, 158, 11, 0.1) !important;
    border: 1px solid rgba(245, 158, 11, 0.3) !important;
    color: #fde68a !important;
}
.dark-theme .lab-disclaimer-banner strong,
[data-theme="dark"] .lab-disclaimer-banner strong {
    color: #ffffff !important;
}

/* ── Upload Zone ── */
.lab-upload-card .dash-card-body { padding: 0; }
.lab-upload-zone {
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    border: 2.5px dashed rgba(22,163,106,0.3); border-radius: 16px;
    padding: 48px 24px; margin: 20px; cursor: pointer;
    transition: all 0.3s ease; background: rgba(22,163,106,0.03);
    min-height: 220px;
}
.lab-upload-zone:hover, .lab-upload-zone.lab-upload-dragover {
    border-color: #16a34a; background: rgba(22,163,106,0.08);
    transform: translateY(-2px); box-shadow: 0 8px 30px rgba(22,163,106,0.15);
}
.lab-upload-icon {
    font-size: 3rem; margin-bottom: 12px; color: #16a34a; opacity: 0.7;
    transition: transform 0.3s ease;
}
.lab-upload-zone:hover .lab-upload-icon { transform: scale(1.1); opacity: 1; }
.lab-upload-title { font-size: 1rem; font-weight: 700; color: var(--text); margin-bottom: 4px; }
.lab-upload-subtitle { font-size: 0.85rem; color: #94a3b8; margin-bottom: 8px; }
.lab-upload-formats { font-size: 0.72rem; color: #64748b; background: rgba(100,116,139,0.1); padding: 4px 12px; border-radius: 20px; }
.lab-file-hidden { display: none; }

/* ── Upload Progress ── */
.lab-upload-progress {
    padding: 24px 20px; margin: 20px;
    background: rgba(22,163,106,0.04); border-radius: 12px;
}
.lab-progress-header {
    display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px;
}
.lab-progress-filename { font-weight: 700; font-size: 0.9rem; color: var(--text); }
.lab-progress-status { font-size: 0.8rem; color: #16a34a; font-weight: 600; }
.lab-progress-bar-wrap { height: 8px; border-radius: 4px; background: rgba(22,163,106,0.15); overflow: hidden; }
.lab-progress-bar {
    background: linear-gradient(90deg, #16a34a, #22c55e); border-radius: 4px;
    transition: width 0.5s ease;
}
.lab-progress-steps {
    display: flex; justify-content: space-between; margin-top: 16px; gap: 4px;
}
.lab-step {
    display: flex; align-items: center; gap: 6px; font-size: 0.72rem;
    color: #64748b; font-weight: 600; opacity: 0.5; transition: all 0.3s ease;
    padding: 4px 8px; border-radius: 6px;
}
.lab-step.active {
    opacity: 1; color: #16a34a; background: rgba(22,163,106,0.1);
}

/* ── Error Message ── */
.lab-error-msg {
    display: flex; align-items: center; padding: 12px 18px; margin: 12px 20px;
    background: rgba(239,68,68,0.1); border: 1px solid rgba(239,68,68,0.25);
    border-radius: 10px; color: #dc2626; font-size: 0.85rem; font-weight: 500;
}

/* ── Manual Entry ── */
.lab-manual-card .dash-card-header { display: flex; justify-content: space-between; align-items: center; }
.lab-manual-body { padding: 20px; }
.lab-manual-grid {
    display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 20px;
}
.lab-manual-section {
    background: rgba(22,163,106,0.03); border-radius: 12px; padding: 16px;
    border: 1px solid rgba(22,163,106,0.08);
}
.lab-manual-section-title {
    font-size: 0.82rem; font-weight: 800; margin-bottom: 12px; color: var(--text);
}
.lab-manual-field { margin-bottom: 10px; }
.lab-manual-field label {
    display: block; font-size: 0.72rem; font-weight: 700; color: #64748b; margin-bottom: 3px;
}
.manual-bio-input {
    width: 100%; padding: 8px 12px; border: 1px solid rgba(100,116,139,0.2);
    border-radius: 8px; background: var(--bg); color: var(--text);
    font-size: 0.85rem; transition: border-color 0.2s ease;
}
.manual-bio-input:focus {
    outline: none; border-color: #16a34a;
    box-shadow: 0 0 0 3px rgba(22,163,106,0.15);
}

/* ── Report History ── */
.lab-history-card .dash-card-header { display: flex; justify-content: space-between; align-items: center; }
.lab-history-list { display: flex; flex-direction: column; gap: 8px; }
.lab-history-item {
    display: flex; align-items: center; gap: 14px; padding: 12px 14px;
    border-radius: 10px; cursor: pointer; transition: all 0.2s ease;
    background: rgba(22,163,106,0.03); border: 1px solid rgba(22,163,106,0.06);
}
.lab-history-item:hover {
    background: rgba(22,163,106,0.08); transform: translateX(4px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.06);
}
.lab-history-info { flex: 1; min-width: 0; }
.lab-history-lab { font-weight: 700; font-size: 0.88rem; color: var(--text); }
.lab-history-date { font-size: 0.75rem; color: #94a3b8; margin-top: 2px; }
.lab-history-delete {
    background: none; border: none; color: #94a3b8; cursor: pointer;
    padding: 4px 6px; border-radius: 6px; transition: all 0.2s ease;
}
.lab-history-delete:hover { color: #ef4444; background: rgba(239,68,68,0.1); }
.lab-history-empty { text-align: center; padding: 40px 20px; color: #94a3b8; }

/* ── Score Circles ── */
.lab-score-circle {
    width: 44px; height: 44px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
    font-weight: 900; font-size: 0.85rem; color: #fff; flex-shrink: 0;
}
.lab-score-circle.score-good { background: linear-gradient(135deg, #16a34a, #22c55e); }
.lab-score-circle.score-fair { background: linear-gradient(135deg, #d97706, #f59e0b); }
.lab-score-circle.score-poor { background: linear-gradient(135deg, #dc2626, #ef4444); }

/* ── Results Section ── */
.lab-results-section { animation: fadeSlideUp 0.5s ease-out; }
@keyframes fadeSlideUp {
    from { opacity: 0; transform: translateY(20px); }
    to   { opacity: 1; transform: translateY(0); }
}

.lab-results-summary {
    display: flex; align-items: center; gap: 32px; padding: 24px;
    background: linear-gradient(135deg, rgba(22,163,106,0.06), rgba(34,197,94,0.04));
    border-radius: 16px; border: 1px solid rgba(22,163,106,0.12);
    flex-wrap: wrap;
}
.lab-score-display { text-align: center; }
.lab-score-big {
    font-size: 3rem; font-weight: 900; line-height: 1;
}
.score-good-text { color: #16a34a; }
.score-fair-text { color: #d97706; }
.score-poor-text { color: #dc2626; }
.lab-score-label { font-size: 0.75rem; font-weight: 700; color: #64748b; margin-top: 4px; text-transform: uppercase; letter-spacing: 1px; }
.lab-summary-stats { display: flex; gap: 24px; flex-wrap: wrap; }
.lab-summary-stat { text-align: center; min-width: 70px; }
.lab-ss-value { font-size: 1.5rem; font-weight: 900; color: var(--text); }
.lab-ss-normal { color: #16a34a; }
.lab-ss-abnormal { color: #d97706; }
.lab-ss-critical { color: #dc2626; }
.lab-ss-label { font-size: 0.7rem; font-weight: 600; color: #94a3b8; text-transform: uppercase; letter-spacing: 0.5px; }

/* ── Biomarker Table ── */
.lab-biomarker-table {
    width: 100%; border-collapse: separate; border-spacing: 0;
    font-size: 0.85rem;
}
.lab-biomarker-table thead th {
    background: rgba(22,163,106,0.08); font-weight: 800; font-size: 0.72rem;
    text-transform: uppercase; letter-spacing: 0.5px; color: #64748b;
    padding: 10px 14px; border: none;
}
.lab-biomarker-table thead th:first-child { border-radius: 10px 0 0 0; }
.lab-biomarker-table thead th:last-child { border-radius: 0 10px 0 0; }
.lab-biomarker-table tbody td {
    padding: 10px 14px; border-bottom: 1px solid rgba(100,116,139,0.08);
    vertical-align: middle;
}
.lab-biomarker-table tbody tr:hover { background: rgba(22,163,106,0.04); }
.bio-name { font-weight: 700; color: var(--text); font-size: 0.85rem; }
.bio-category { font-size: 0.68rem; color: #94a3b8; }
.bio-value { font-weight: 900; font-size: 0.95rem; }
.bio-unit { font-size: 0.72rem; color: #94a3b8; }
.bio-ref { font-size: 0.78rem; color: #64748b; }

/* ── Status Badges ── */
.bio-status-badge {
    display: inline-flex; align-items: center; gap: 4px;
    padding: 3px 10px; border-radius: 20px; font-size: 0.72rem; font-weight: 700;
}
.bio-status-normal { background: rgba(22,163,106,0.1); color: #16a34a; }
.bio-status-low { background: rgba(59,130,246,0.1); color: #3b82f6; }
.bio-status-high { background: rgba(245,158,11,0.15); color: #d97706; }
.bio-status-critical { background: rgba(239,68,68,0.15); color: #dc2626; font-weight: 900; }
.bio-status-unknown { background: rgba(100,116,139,0.1); color: #94a3b8; }

/* Row tinting for abnormal */
tr.bio-status-low td { background: rgba(59,130,246,0.03); }
tr.bio-status-high td { background: rgba(245,158,11,0.03); }
tr.bio-status-critical td { background: rgba(239,68,68,0.05); }

/* ── Recommendations ── */
.lab-recs-list { display: flex; flex-direction: column; gap: 8px; }
.lab-rec-item {
    padding: 12px 16px; border-radius: 10px;
    background: rgba(22,163,106,0.04); border: 1px solid rgba(22,163,106,0.08);
    transition: transform 0.2s ease;
}
.lab-rec-item:hover { transform: translateX(4px); }
.lab-rec-biomarker { margin-bottom: 6px; }
.lab-rec-text { font-size: 0.85rem; color: var(--text); line-height: 1.5; }

/* ── Confidence & Provider ── */
.lab-confidence {
    padding: 8px 14px; background: rgba(100,116,139,0.06);
    border-radius: 8px; text-align: center;
}

/* ── Result Header ── */
.lab-result-lab-name {
    font-weight: 700; font-size: 0.82rem; color: var(--text);
    background: rgba(22,163,106,0.1); padding: 3px 10px; border-radius: 6px;
}
.lab-result-date { font-size: 0.75rem; color: #94a3b8; margin-left: 8px; }

/* ── Modal header info ── */
.lab-modal-header-info {
    display: flex; align-items: center; gap: 16px;
    padding: 12px; background: rgba(22,163,106,0.04); border-radius: 10px;
}

/* ── Dashboard Lab Card ── */
.dash-lab-card {
    background: linear-gradient(135deg, rgba(139,92,246,0.08), rgba(22,163,106,0.06));
    border: 1px solid rgba(139,92,246,0.15);
    border-radius: 16px; padding: 20px; text-align: center; cursor: pointer;
    transition: all 0.3s ease;
}
.dash-lab-card:hover {
    transform: translateY(-4px); box-shadow: 0 12px 32px rgba(139,92,246,0.15);
    border-color: rgba(139,92,246,0.3);
}
.dash-lab-icon { font-size: 2.2rem; margin-bottom: 8px; }
.dash-lab-title { font-weight: 800; font-size: 0.95rem; color: var(--text); }
.dash-lab-subtitle { font-size: 0.78rem; color: #94a3b8; margin-top: 4px; }

/* ── Responsive ── */
@media (max-width: 768px) {
    .lab-page-header { flex-direction: column; align-items: flex-start; }
    .lab-results-summary { flex-direction: column; align-items: center; text-align: center; }
    .lab-summary-stats { justify-content: center; }
    .lab-manual-grid { grid-template-columns: 1fr; }
    .lab-progress-steps { flex-wrap: wrap; gap: 6px; }
    .lab-upload-zone { padding: 32px 16px; min-height: 180px; }
}

/* ── Nav Beta Badge (small inline) ── */
.nav-beta-badge {
    display: inline-block; font-size: 0.5rem; font-weight: 900; letter-spacing: 1px;
    padding: 1px 6px; border-radius: 8px; vertical-align: super;
    background: linear-gradient(135deg, #f59e0b, #ef4444); color: #fff;
    margin-left: 4px;
}

/* ══════════════════════════════════════════════════════════════════════════
   PREMIUM STITCH REDESIGN — Dark-Mode Glassmorphism
   ════════════════════════════════════════════════════════════════════════════ */

/* Premium dark mode theme for Lab Reports */
.lab-reports-page.dark-theme {
    background-color: #020617 !important;
    color: #cbd5e1 !important;
    font-family: 'Inter', sans-serif !important;
    padding: 2rem 0;
    margin-top: -8px; /* offset standard padding if any */
}
.lab-reports-page.dark-theme h1,
.lab-reports-page.dark-theme h2,
.lab-reports-page.dark-theme h3,
.lab-reports-page.dark-theme h4,
.lab-reports-page.dark-theme h5,
.lab-reports-page.dark-theme h6 {
    font-family: 'Plus Jakarta Sans', sans-serif !important;
    color: #ffffff !important;
    font-weight: 700;
}
.lab-reports-page.dark-theme .text-muted {
    color: #94a3b8 !important;
}

/* Glassmorphic Cards */
.lab-reports-page.dark-theme .dash-card {
    background: rgba(15, 23, 42, 0.45) !important;
    backdrop-filter: blur(20px) !important;
    -webkit-backdrop-filter: blur(20px) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    border-radius: 16px !important;
    color: #cbd5e1 !important;
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37) !important;
    transition: all 0.3s ease;
}
.lab-reports-page.dark-theme .dash-card:hover {
    border-color: rgba(34, 197, 94, 0.25) !important;
    box-shadow: 0 0 30px rgba(34, 197, 94, 0.15) !important;
    transform: translateY(-2px);
}
.lab-reports-page.dark-theme .dash-card-header {
    border-bottom: 1px solid rgba(255, 255, 255, 0.05) !important;
    background: transparent !important;
    padding: 16px 20px !important;
}
.lab-reports-page.dark-theme .dash-card-header h5 {
    color: #ffffff !important;
    margin: 0;
}

/* Upload Zone */
.lab-reports-page.dark-theme .lab-upload-zone {
    border: 2px dashed rgba(34, 197, 94, 0.3) !important;
    background: rgba(15, 23, 42, 0.25) !important;
    border-radius: 14px !important;
    transition: all 0.3s ease !important;
    margin: 16px !important;
}
.lab-reports-page.dark-theme .lab-upload-zone:hover {
    border-color: #22c55e !important;
    background: rgba(34, 197, 94, 0.08) !important;
    box-shadow: 0 0 25px rgba(34, 197, 94, 0.1) !important;
}
.lab-reports-page.dark-theme .lab-upload-title {
    color: #ffffff !important;
}
.lab-reports-page.dark-theme .lab-upload-formats {
    background: rgba(255, 255, 255, 0.05) !important;
    color: #94a3b8 !important;
}

/* Manual Entry Accordion */
.lab-reports-page.dark-theme .lab-manual-section {
    background: rgba(255, 255, 255, 0.02) !important;
    border: 1px solid rgba(255, 255, 255, 0.05) !important;
}
.lab-reports-page.dark-theme .manual-bio-input {
    background: rgba(15, 23, 42, 0.6) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    color: #ffffff !important;
}
.lab-reports-page.dark-theme .manual-bio-input:focus {
    border-color: #22c55e !important;
    box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.2) !important;
}

/* Biomarker Table */
.lab-reports-page.dark-theme .lab-biomarker-table thead th {
    background: rgba(255, 255, 255, 0.03) !important;
    color: #94a3b8 !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05) !important;
}
.lab-reports-page.dark-theme .lab-biomarker-table tbody td {
    border-bottom: 1px solid rgba(255, 255, 255, 0.05) !important;
}
.lab-reports-page.dark-theme .bio-name {
    color: #ffffff !important;
}
.lab-reports-page.dark-theme .bio-value {
    color: #ffffff !important;
}

/* Table Row Highlights */
.lab-reports-page.dark-theme tr.bio-status-normal td { background: transparent !important; }
.lab-reports-page.dark-theme tr.bio-status-low td { background: rgba(59, 130, 246, 0.05) !important; }
.lab-reports-page.dark-theme tr.bio-status-high td { background: rgba(245, 158, 11, 0.05) !important; }
.lab-reports-page.dark-theme tr.bio-status-critical td { background: rgba(239, 68, 68, 0.08) !important; }

/* Status Badges */
.lab-reports-page.dark-theme .bio-status-normal { background: rgba(34, 197, 94, 0.15) !important; color: #4ade80 !important; }
.lab-reports-page.dark-theme .bio-status-low { background: rgba(59, 130, 246, 0.15) !important; color: #60a5fa !important; }
.lab-reports-page.dark-theme .bio-status-high { background: rgba(245, 158, 11, 0.18) !important; color: #fbbf24 !important; }
.lab-reports-page.dark-theme .bio-status-critical { background: rgba(239, 68, 68, 0.2) !important; color: #f87171 !important; }

/* Recommendations */
.lab-reports-page.dark-theme .lab-rec-item {
    background: rgba(255, 255, 255, 0.02) !important;
    border: 1px solid rgba(255, 255, 255, 0.05) !important;
    border-left: 4px solid #22c55e !important;
}
.lab-reports-page.dark-theme .lab-rec-item:hover {
    background: rgba(34, 197, 94, 0.04) !important;
    border-left-color: #4ade80 !important;
}
.lab-reports-page.dark-theme .lab-rec-text {
    color: #e2e8f0 !important;
}

/* History */
.lab-reports-page.dark-theme .lab-history-item {
    background: rgba(255, 255, 255, 0.02) !important;
    border: 1px solid rgba(255, 255, 255, 0.05) !important;
}
.lab-reports-page.dark-theme .lab-history-item:hover {
    background: rgba(34, 197, 94, 0.06) !important;
    border-color: rgba(34, 197, 94, 0.2) !important;
}

/* Modals */
.lab-reports-page.dark-theme .modal-custom {
    background: #0f172a !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5) !important;
    color: #cbd5e1 !important;
}
.lab-reports-page.dark-theme .modal-header,
.lab-reports-page.dark-theme .modal-footer {
    border-color: rgba(255, 255, 255, 0.05) !important;
}
.lab-reports-page.dark-theme .modal-title {
    color: #ffffff !important;
}
.lab-reports-page.dark-theme .btn-close {
    filter: invert(1) !important;
}

/* ── Results Page Custom Alerts & Disclaimers ── */
.alert-review-verified {
    background: #f0fdf4;
    border: 1.5px solid #22c55e;
    border-radius: 14px;
    padding: 16px 20px;
    margin-bottom: 20px;
    display: flex;
    align-items: flex-start;
    gap: 14px;
    font-size: 0.88rem;
    color: #166534;
}
.alert-review-verified .alert-title {
    font-size: 0.95rem;
    display: block;
    margin-bottom: 4px;
    color: #166534;
}
.alert-review-verified .review-notes-box {
    background: rgba(34,197,94,0.1);
    border-radius: 8px;
    font-style: italic;
}
.alert-review-pending {
    background: #fef2f2;
    border: 1.5px solid #ef4444;
    border-radius: 14px;
    padding: 16px 20px;
    margin-bottom: 20px;
    display: flex;
    align-items: flex-start;
    gap: 14px;
    font-size: 0.88rem;
    color: #991b1b;
}
.alert-review-pending .alert-title {
    font-size: 0.95rem;
    display: block;
    margin-bottom: 4px;
    color: #991b1b;
}
.alert-medical-disclaimer {
    background: #fffbeb;
    border: 1.5px solid #fbbf24;
    border-radius: 14px;
    padding: 14px 18px;
    margin-bottom: 20px;
    display: flex;
    align-items: flex-start;
    gap: 12px;
    font-size: 0.85rem;
    color: #78350f;
}
.alert-fallback-plan {
    background: rgba(59,130,246,0.08);
    border: 1.5px solid rgba(59,130,246,0.3);
    border-radius: 14px;
    padding: 14px 18px;
    margin-bottom: 20px;
    display: flex;
    align-items: flex-start;
    gap: 12px;
    font-size: 0.85rem;
    color: #1e40af;
}
.clinical-disclaimer-box {
    border: 1px dashed rgba(220, 38, 38, 0.3);
    background: rgba(220, 38, 38, 0.02);
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 20px;
}
.clinical-disclaimer-box .disclaimer-title {
    color: #dc2626;
    font-size: 0.9rem;
    display: block;
    margin-bottom: 4px;
}
.alert-icon-wrap {
    font-size: 1.5rem;
    flex-shrink: 0;
    line-height: 1;
}
.alert-medical-disclaimer .alert-icon-wrap,
.alert-fallback-plan .alert-icon-wrap {
    font-size: 1.25rem;
}

.pes-statement-box {
    background: var(--slate-50);
    border: 1.5px solid var(--slate-200);
    border-radius: 10px;
    padding: 16px;
    margin-bottom: 8px;
}
.pes-problem-text {
    color: var(--slate-800);
    font-weight: 700;
}
.pes-etiology-text, .pes-signs-text {
    color: var(--slate-600);
}
.gap-card {
    background: var(--slate-50);
    border: 1.5px solid var(--slate-200);
}
.gap-card-dose {
    color: #16a34a;
}
.alert-supplement-note {
    background: #f0f9ff;
    border: 1px solid #bae6fd;
    color: #0369a1;
    font-size: 0.8rem;
    border-radius: 10px;
    padding: 14px 18px;
}

/* ══════════════════════════════════════════════════════════════════════════ */

/* ══════════════════════════════════════════════════════════════════════════
   GLOBAL DARK THEME OVERRIDES — Syntro Health Premium Redesign (Stitch Spec)
   ════════════════════════════════════════════════════════════════════════════ */

/* Apply global dark background when dark-theme wrapper is active */
.dark-theme {
    background-color: #020617 !important;
    background-image: radial-gradient(circle at 80% 20%, rgba(34, 197, 94, 0.07) 0%, transparent 50%),
                      radial-gradient(circle at 10% 80%, rgba(6, 182, 212, 0.05) 0%, transparent 50%) !important;
    background-attachment: fixed !important;
    color: #cbd5e1 !important;
    font-family: 'Inter', sans-serif !important;
    min-height: 100vh;
}

.dark-theme h1,
.dark-theme h2,
.dark-theme h3,
.dark-theme h4,
.dark-theme h5,
.dark-theme h6 {
    font-family: 'Plus Jakarta Sans', sans-serif !important;
    color: #ffffff !important;
    font-weight: 700;
}

.dark-theme .text-muted {
    color: #94a3b8 !important;
}

/* Glassmorphic Cards */
.dark-theme .dash-card,
.dark-theme .results-card,
.dark-theme .settings-card,
.dark-theme .mydb-plan-card,
.dark-theme .mydb-stat-card {
    background: rgba(15, 23, 42, 0.45) !important;
    backdrop-filter: blur(20px) !important;
    -webkit-backdrop-filter: blur(20px) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    border-radius: 16px !important;
    color: #cbd5e1 !important;
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37) !important;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.dark-theme .dash-card:hover,
.dark-theme .results-card:hover,
.dark-theme .mydb-plan-card:hover,
.dark-theme .mydb-stat-card:hover {
    border-color: rgba(34, 197, 94, 0.25) !important;
    box-shadow: 0 0 30px rgba(34, 197, 94, 0.15) !important;
    transform: translateY(-2px);
}

.dark-theme .dash-card-header,
.dark-theme .results-card-header {
    border-bottom: 1px solid rgba(255, 255, 255, 0.05) !important;
    background: transparent !important;
}

/* ── Dashboard Stats Cards ── */
.dark-theme .dash-stat-card {
    background: rgba(15, 23, 42, 0.3) !important;
    border: 1px solid rgba(255, 255, 255, 0.06) !important;
    border-radius: 16px !important;
    padding: 20px !important;
    backdrop-filter: blur(10px) !important;
    box-shadow: 0 4px 20px rgba(0,0,0,0.2) !important;
    transition: all 0.3s ease;
}
.dark-theme .dash-stat-card:hover {
    border-color: rgba(6, 182, 212, 0.2) !important;
    background: rgba(15, 23, 42, 0.45) !important;
    transform: translateY(-2px);
}
.dark-theme .dash-stat-value {
    color: #ffffff !important;
    font-size: 1.6rem !important;
    font-weight: 800 !important;
}
.dark-theme .dash-stat-label {
    color: #94a3b8 !important;
    font-size: 0.85rem !important;
}

/* ── Dashboard Meal Cards ── */
.dark-theme .dash-meal-card {
    background: rgba(255, 255, 255, 0.02) !important;
    border: 1px solid rgba(255, 255, 255, 0.05) !important;
    border-radius: 12px !important;
    padding: 16px !important;
    transition: all 0.3s ease;
}
.dark-theme .dash-meal-card:hover {
    background: rgba(34, 197, 94, 0.04) !important;
    border-color: rgba(34, 197, 94, 0.2) !important;
}
.dark-theme .dash-meal-header {
    color: #94a3b8 !important;
    font-weight: 600 !important;
    font-size: 0.8rem !important;
    border-bottom: 1px dashed rgba(255,255,255,0.08) !important;
    padding-bottom: 8px !important;
    margin-bottom: 8px !important;
}
.dark-theme .dash-meal-name {
    color: #ffffff !important;
    font-weight: 700 !important;
    font-size: 0.95rem !important;
}
.dark-theme .dash-meal-cal {
    color: #22c55e !important;
    font-weight: 600 !important;
}

/* ── Dashboard Tips ── */
.dark-theme .dash-tip-item {
    background: rgba(255, 255, 255, 0.02) !important;
    border: 1px solid rgba(255, 255, 255, 0.05) !important;
    border-radius: 10px !important;
    padding: 12px 16px !important;
    color: #e2e8f0 !important;
}

/* ── Diary Section ── */
.dark-theme .diary-section {
    background: rgba(15, 23, 42, 0.45) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    border-radius: 16px !important;
    backdrop-filter: blur(20px) !important;
    padding: 24px !important;
    box-shadow: 0 8px 32px rgba(0,0,0,0.37) !important;
}
.dark-theme .diary-header h5 {
    color: #ffffff !important;
}
.dark-theme .dt-val {
    color: #ffffff !important;
}
.dark-theme .dt-lbl {
    color: #94a3b8 !important;
}
.dark-theme .diary-add-form {
    background: rgba(255, 255, 255, 0.02) !important;
    border: 1px solid rgba(255, 255, 255, 0.05) !important;
    border-radius: 12px !important;
    padding: 16px !important;
}
.dark-theme .diary-form-input {
    background: rgba(15, 23, 42, 0.6) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    color: #ffffff !important;
    border-radius: 8px !important;
    padding: 8px 12px !important;
}
.dark-theme .diary-form-input:focus {
    border-color: #22c55e !important;
    outline: none !important;
    box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.2) !important;
}
.dark-theme .diary-entry {
    background: rgba(255, 255, 255, 0.02) !important;
    border: 1px solid rgba(255, 255, 255, 0.05) !important;
    border-radius: 10px !important;
    color: #e2e8f0 !important;
}
.dark-theme .de-name {
    color: #ffffff !important;
}
.dark-theme .de-cal {
    color: #22c55e !important;
}
.dark-theme .de-del {
    color: #ef4444 !important;
    background: transparent !important;
    border: none !important;
}

/* ── Results Metrics Row ── */
.dark-theme .metric-result-card {
    background: rgba(15, 23, 42, 0.35) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    border-radius: 16px !important;
    padding: 24px 20px !important;
    box-shadow: 0 4px 20px rgba(0,0,0,0.2) !important;
    transition: all 0.3s ease;
}
.dark-theme .metric-result-card.featured {
    background: linear-gradient(135deg, rgba(34, 197, 94, 0.12), rgba(15, 23, 42, 0.45)) !important;
    border-color: rgba(34, 197, 94, 0.3) !important;
}
.dark-theme .metric-result-value {
    color: #ffffff !important;
    font-weight: 800 !important;
    font-family: 'Plus Jakarta Sans', sans-serif !important;
}
.dark-theme .metric-result-label {
    color: #94a3b8 !important;
}

/* ── Results Plate Blueprints ── */
.dark-theme .plate-rule-card {
    background: rgba(255, 255, 255, 0.02) !important;
    border: 1px solid rgba(255, 255, 255, 0.05) !important;
    border-radius: 12px !important;
    padding: 16px !important;
    transition: all 0.3s ease;
}
.dark-theme .plate-rule-card:hover {
    background: rgba(255, 255, 255, 0.04) !important;
}
.dark-theme .plate-rule-content strong {
    color: #ffffff !important;
}
.dark-theme .plate-rule-content p {
    color: #94a3b8 !important;
}

/* ── Traffic Lights ── */
.dark-theme .eatwell-traffic-light {
    background: rgba(255, 255, 255, 0.02) !important;
    border: 1px solid rgba(255, 255, 255, 0.05) !important;
    border-radius: 14px !important;
}
.dark-theme .traffic-item {
    background: rgba(15, 23, 42, 0.45) !important;
    border: 1px solid rgba(255, 255, 255, 0.05) !important;
    border-radius: 10px !important;
    color: #ffffff !important;
}

/* ── Macros Display in Results ── */
.dark-theme .macro-item {
    background: rgba(255, 255, 255, 0.02) !important;
    border: 1px solid rgba(255, 255, 255, 0.05) !important;
    border-radius: 12px !important;
}
.dark-theme .macro-circle {
    border-color: rgba(255, 255, 255, 0.08) !important;
}
.dark-theme .macro-val {
    color: #ffffff !important;
}
.dark-theme .macro-name {
    color: #94a3b8 !important;
}
.dark-theme .macro-cal {
    color: #cbd5e1 !important;
}

/* ── Health Score Circle ── */
.dark-theme .health-score-circle {
    box-shadow: 0 0 30px rgba(34, 197, 94, 0.1) !important;
}
.dark-theme .health-score-num {
    color: #ffffff !important;
}
.dark-theme .health-score-100 {
    color: #94a3b8 !important;
}
.dark-theme.results-page,
.dark-theme .results-page {
    background: transparent !important;
}

.dark-theme .insight-item {
    color: #e2e8f0 !important;
}

.dark-theme .insight-item.insight-positive {
    background: rgba(34, 197, 94, 0.15) !important;
    color: #4ade80 !important;
}

.dark-theme .insight-item.insight-warning {
    background: rgba(245, 158, 11, 0.15) !important;
    color: #fbbf24 !important;
}

/* ── Results 7-Day Meal Plan ── */
.dark-theme .meal-card {
    background: rgba(15, 23, 42, 0.45) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    border-radius: 16px !important;
    box-shadow: 0 4px 20px rgba(0,0,0,0.2) !important;
    transition: all 0.3s ease;
}
.dark-theme .meal-card:hover {
    border-color: rgba(34, 197, 94, 0.25) !important;
    transform: translateY(-2px);
}
.dark-theme .meal-card-header {
    border-bottom: 1px solid rgba(255,255,255,0.06) !important;
    padding-bottom: 12px !important;
}
.dark-theme .meal-type {
    color: #ffffff !important;
    font-weight: 700 !important;
}
.dark-theme .meal-calories {
    color: #22c55e !important;
    font-weight: 700 !important;
}
.dark-theme .meal-name {
    color: #ffffff !important;
}
.dark-theme .meal-desc {
    color: #94a3b8 !important;
}
.dark-theme .dish-title {
    color: #ffffff !important;
}
.dark-theme .dish-desc {
    color: #94a3b8 !important;
}
.dark-theme .tile-label {
    color: #f1f5f9 !important;
}
.dark-theme .mobile-meal-tile {
    background: rgba(15, 23, 42, 0.55) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.25) !important;
}
.dark-theme .btn-swap-meal,
.dark-theme .btn-quick-swap {
    background: rgba(34, 197, 94, 0.15) !important;
    color: #4ade80 !important;
    border: 1px solid rgba(34, 197, 94, 0.3) !important;
    border-radius: 100px !important;
    padding: 6px 16px !important;
    transition: all 0.2s ease !important;
}
.dark-theme .btn-swap-meal:hover,
.dark-theme .btn-quick-swap:hover {
    background: #22c55e !important;
    color: #ffffff !important;
}
.dark-theme .macro-cal {
    background: rgba(255, 255, 255, 0.05) !important;
    color: #cbd5e1 !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
}
.dark-theme .macro-p {
    background: rgba(59, 130, 246, 0.12) !important;
    color: #93c5fd !important;
    border: 1px solid rgba(59, 130, 246, 0.25) !important;
}
.dark-theme .macro-c {
    background: rgba(245, 158, 11, 0.12) !important;
    color: #fcd34d !important;
    border: 1px solid rgba(245, 158, 11, 0.25) !important;
}
.dark-theme .macro-f {
    background: rgba(239, 68, 68, 0.12) !important;
    color: #fca5a5 !important;
    border: 1px solid rgba(239, 68, 68, 0.25) !important;
}

/* ── Supplement Gaps ── */
.dark-theme .gap-card {
    background: rgba(15, 23, 42, 0.45) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    box-shadow: 0 4px 20px rgba(0,0,0,0.2) !important;
}
.dark-theme .gap-card strong {
    color: #ffffff !important;
}
.dark-theme .pes-statement-box {
    background: rgba(255, 255, 255, 0.02) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
}
.dark-theme .pes-problem-text {
    color: var(--slate-200) !important;
}
.dark-theme .pes-etiology-text,
.dark-theme .pes-signs-text {
    color: var(--slate-300) !important;
}
.dark-theme .gap-card-dose {
    color: #4ade80 !important;
}
.dark-theme .alert-supplement-note {
    background: rgba(3, 105, 161, 0.12) !important;
    border-color: rgba(3, 105, 161, 0.25) !important;
    color: #bae6fd !important;
}

/* ── Grocery list & attribution ── */
.dark-theme .grocery-item {
    background: rgba(34, 197, 94, 0.08) !important;
    color: #4ade80 !important;
    border: 1px solid rgba(34, 197, 94, 0.15) !important;
}
.dark-theme .source-attribution {
    color: #64748b !important;
    border-top-color: rgba(255, 255, 255, 0.05) !important;
}

/* ── Foods to Limit ── */
.dark-theme .limit-card {
    background: rgba(15, 23, 42, 0.45) !important;
    border: 1px solid rgba(239, 68, 68, 0.25) !important;
}
.dark-theme .limit-pill {
    background: rgba(239, 68, 68, 0.08) !important;
    border: 1px solid rgba(239, 68, 68, 0.2) !important;
    color: #fca5a5 !important;
    border-radius: 8px !important;
    padding: 8px 12px !important;
}

/* ── User summary grid ── */
.dark-theme .summary-row {
    border-bottom: 1px solid rgba(255, 255, 255, 0.05) !important;
}
.dark-theme .summary-label {
    color: #94a3b8 !important;
}
.dark-theme .summary-value {
    color: #ffffff !important;
}

/* ── Tabs and Pills styling for Dark theme ── */
.dark-theme .nav-pills .nav-link {
    color: #94a3b8 !important;
    background: rgba(255, 255, 255, 0.02) !important;
    border: 1px solid rgba(255, 255, 255, 0.05) !important;
}
.dark-theme .nav-pills .nav-link.active {
    color: #ffffff !important;
    background: #22c55e !important;
    border-color: #22c55e !important;
}

/* ── Alerts in Dark Mode ── */
.dark-theme .alert {
    background: rgba(15, 23, 42, 0.6) !important;
    color: #cbd5e1 !important;
}
.dark-theme .alert-review-verified {
    background: rgba(34, 197, 94, 0.1) !important;
    border-color: rgba(34, 197, 94, 0.25) !important;
    color: #cbd5e1 !important;
}
.dark-theme .alert-review-verified .alert-title {
    color: #4ade80 !important;
}
.dark-theme .alert-review-verified .review-notes-box {
    background: rgba(34,197,94,0.15) !important;
    color: #cbd5e1 !important;
}
.dark-theme .alert-review-pending {
    background: rgba(239, 68, 68, 0.1) !important;
    border-color: rgba(239, 68, 68, 0.25) !important;
    color: #cbd5e1 !important;
}
.dark-theme .alert-review-pending .alert-title {
    color: #f87171 !important;
}
.dark-theme .alert-medical-disclaimer {
    background: rgba(245, 158, 11, 0.1) !important;
    border-color: rgba(245, 158, 11, 0.25) !important;
    color: #cbd5e1 !important;
}
.dark-theme .alert-medical-disclaimer strong {
    color: #fbbf24 !important;
}
.dark-theme .alert-fallback-plan {
    background: rgba(59, 130, 246, 0.1) !important;
    border-color: rgba(59, 130, 246, 0.25) !important;
    color: #cbd5e1 !important;
}
.dark-theme .alert-fallback-plan strong {
    color: #60a5fa !important;
}
.dark-theme .clinical-disclaimer-box {
    background: rgba(239, 68, 68, 0.03) !important;
    border: 1px dashed rgba(239, 68, 68, 0.35) !important;
}
.dark-theme .clinical-disclaimer-box .disclaimer-title {
    color: #f87171 !important;
}

/* ── Settings page specific ── */
.dark-theme .settings-title {
    color: #ffffff !important;
}
.dark-theme .settings-back {
    color: #22c55e !important;
}
.dark-theme .settings-avatar {
    background: #22c55e !important;
    color: #ffffff !important;
}
.dark-theme .settings-name {
    color: #ffffff !important;
}
.dark-theme .settings-email-tag {
    color: #94a3b8 !important;
}
.dark-theme .settings-card-title {
    color: #ffffff !important;
    border-bottom-color: rgba(255,255,255,0.05) !important;
}
.dark-theme .settings-input {
    background: rgba(15, 23, 42, 0.6) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    color: #ffffff !important;
}
.dark-theme .settings-input:focus {
    border-color: #22c55e !important;
    box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.2) !important;
}

/* ── My Dashboard selector page specific ── */
.dark-theme.mydb-page {
    background: transparent !important;
}
.dark-theme .mydb-hero {
    background: linear-gradient(135deg, rgba(15, 23, 42, 0.8), rgba(2, 6, 23, 0.9)) !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05) !important;
}
.dark-theme .mydb-greeting {
    color: #ffffff !important;
}
.dark-theme .mydb-sub {
    color: #94a3b8 !important;
}
.dark-theme .mydb-stat-card {
    background: rgba(15, 23, 42, 0.45) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
}
.dark-theme .mydb-stat-val {
    color: #ffffff !important;
}
.dark-theme .mydb-stat-label {
    color: #94a3b8 !important;
}
.dark-theme .mydb-section-title h2 {
    color: #ffffff !important;
}
.dark-theme .mydb-plan-name {
    color: #ffffff !important;
}
.dark-theme .mydb-plan-meta {
    color: #94a3b8 !important;
}
.dark-theme .mpmetric-val {
    color: #ffffff !important;
}
.dark-theme .mpmetric-label {
    color: #94a3b8 !important;
}
.dark-theme .mydb-plan-metrics {
    background: rgba(30, 41, 59, 0.4) !important;
    border-top: 1px solid rgba(255, 255, 255, 0.06) !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06) !important;
}
.dark-theme .mydb-weight-row {
    background: rgba(255,255,255,0.02) !important;
    color: #cbd5e1 !important;
    border: 1px solid rgba(255,255,255,0.05) !important;
}
.dark-theme .mydb-weight-row strong {
    color: #f8fafc !important;
}
.dark-theme .mydb-plan-card-footer {
    border-top: 1px solid rgba(255, 255, 255, 0.06) !important;
}
.dark-theme .btn-card-view {
    background: rgba(34, 197, 94, 0.12) !important;
    color: #4ade80 !important;
    border: 1px solid rgba(34, 197, 94, 0.25) !important;
}
.dark-theme .btn-card-view:hover {
    background: rgba(34, 197, 94, 0.25) !important;
    color: #ffffff !important;
}
.dark-theme .btn-card-track {
    background: rgba(59, 130, 246, 0.12) !important;
    color: #93c5fd !important;
    border: 1px solid rgba(59, 130, 246, 0.25) !important;
}
.dark-theme .btn-card-track:hover {
    background: rgba(59, 130, 246, 0.25) !important;
    color: #ffffff !important;
}

/* ── Auth login/register specific ── */
.dark-theme .auth-left {
    background: linear-gradient(135deg, rgba(15, 23, 42, 0.9), rgba(2, 6, 23, 0.95)) !important;
}
.dark-theme .auth-left-title {
    color: #ffffff !important;
}
.dark-theme .auth-left-sub {
    color: #cbd5e1 !important;
}
.dark-theme .auth-perk {
    color: #cbd5e1 !important;
}
.dark-theme .quote-text {
    color: #94a3b8 !important;
}
.dark-theme .auth-right {
    background: #020617 !important;
}
.dark-theme .auth-form-header h3 {
    color: #ffffff !important;
}
.dark-theme .auth-field label {
    color: #94a3b8 !important;
}
.dark-theme .auth-input {
    background: rgba(15, 23, 42, 0.6) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    color: #ffffff !important;
}
.dark-theme .auth-input:focus {
    border-color: #22c55e !important;
    box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.2) !important;
}
.dark-theme .google-auth-btn {
    background: rgba(255, 255, 255, 0.05) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    color: #ffffff !important;
}
.dark-theme .google-auth-btn:hover {
    background: rgba(255, 255, 255, 0.08) !important;
}
.dark-theme .auth-btn-ghost {
    color: #94a3b8 !important;
    border-color: rgba(255, 255, 255, 0.08) !important;
}
.dark-theme .auth-btn-ghost:hover {
    background: rgba(255, 255, 255, 0.05) !important;
    color: #ffffff !important;
}

/* ── PREMIUM DARK THEME NAVIGATION OVERRIDES ── */
.dark-theme .navbar-custom {
    background: rgba(15, 23, 42, 0.7) !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08) !important;
    backdrop-filter: blur(12px) !important;
    -webkit-backdrop-filter: blur(12px) !important;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.25) !important;
    transition: all 0.3s ease;
}
.dark-theme .navbar-custom .brand-name {
    color: #ffffff !important;
}
.dark-theme .navbar-custom .nav-link {
    color: #94a3b8 !important;
    transition: color 0.2s ease, background-color 0.2s ease !important;
}
.dark-theme .navbar-custom .nav-link:hover {
    color: #22c55e !important;
    background: rgba(255, 255, 255, 0.03) !important;
}
.dark-theme .navbar-custom .nav-link.active {
    color: #22c55e !important;
    font-weight: 600 !important;
}
.dark-theme .navbar-toggler {
    border-color: rgba(255, 255, 255, 0.15) !important;
}
.dark-theme .navbar-toggler-icon {
    filter: invert(1) !important;
}
.dark-theme .nav-user-btn {
    background: rgba(255, 255, 255, 0.04) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    color: #cbd5e1 !important;
}
.dark-theme .nav-user-btn:hover {
    background: rgba(255, 255, 255, 0.08) !important;
    border-color: rgba(34, 197, 94, 0.3) !important;
    color: #ffffff !important;
}

/* ── USER DROPDOWN CARD IN NAV ── */
.dark-theme .user-dropdown {
    background: rgba(15, 23, 42, 0.95) !important;
    backdrop-filter: blur(20px) !important;
    -webkit-backdrop-filter: blur(20px) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.45) !important;
}
.dark-theme .dh-name {
    color: #ffffff !important;
}
.dark-theme .dh-email {
    color: #94a3b8 !important;
}
.dark-theme .dh-avatar {
    background: linear-gradient(135deg, #22c55e, #16a34a) !important;
    color: #ffffff !important;
}
.dark-theme .dropdown-divider {
    border-top: 1px solid rgba(255, 255, 255, 0.08) !important;
}
.dark-theme .user-dropdown .dropdown-item {
    color: #cbd5e1 !important;
}
.dark-theme .user-dropdown .dropdown-item:hover {
    background: rgba(34, 197, 94, 0.15) !important;
    color: #4ade80 !important;
}
.dark-theme .user-dropdown .dropdown-item.text-danger:hover {
    background: rgba(239, 68, 68, 0.15) !important;
    color: #f87171 !important;
}

/* ── PREMIUM DARK THEME FOOTER OVERRIDES ── */
.dark-theme .site-footer {
    background: #090d16 !important;
    border-top: 1px solid rgba(255, 255, 255, 0.08) !important;
    color: #94a3b8 !important;
}
.dark-theme .site-footer .brand-name {
    color: #ffffff !important;
}
.dark-theme .site-footer .footer-desc {
    color: #64748b !important;
}
.dark-theme .site-footer .footer-heading {
    color: #ffffff !important;
}
.dark-theme .site-footer .footer-links a {
    color: #94a3b8 !important;
}
.dark-theme .site-footer .footer-links a:hover {
    color: #22c55e !important;
}
.dark-theme .site-footer .footer-small {
    color: #64748b !important;
}
.dark-theme .site-footer .footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.05) !important;
    color: #64748b !important;
}

/* ── PREMIUM GLOWING ACCENTS & BUTTONS ── */
.dark-theme .btn-primary-custom,
.dark-theme .btn-mydb-primary,
.dark-theme .auth-btn,
.dark-theme .settings-btn-save {
    background: linear-gradient(135deg, #22c55e, #16a34a) !important;
    border: none !important;
    box-shadow: 0 4px 14px rgba(34, 197, 94, 0.35) !important;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
}
.dark-theme .btn-primary-custom:hover,
.dark-theme .btn-mydb-primary:hover,
.dark-theme .auth-btn:hover,
.dark-theme .settings-btn-save:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 6px 20px rgba(34, 197, 94, 0.55) !important;
}

.dark-theme .btn-outline-primary-custom,
.dark-theme .btn-mydb-outline,
.dark-theme .auth-btn-ghost,
.dark-theme .google-auth-btn {
    background: rgba(255, 255, 255, 0.03) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    color: #cbd5e1 !important;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
}
.dark-theme .btn-outline-primary-custom:hover,
.dark-theme .btn-mydb-outline:hover,
.dark-theme .auth-btn-ghost:hover,
.dark-theme .google-auth-btn:hover {
    background: rgba(255, 255, 255, 0.06) !important;
    border-color: rgba(34, 197, 94, 0.3) !important;
    color: #ffffff !important;
}

/* ── SCROLLBAR FOR PREMIUM AESTHETIC ── */
.dark-theme::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}
.dark-theme::-webkit-scrollbar-track {
    background: #020617;
}
.dark-theme::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    border: 2px solid #020617;
}
.dark-theme::-webkit-scrollbar-thumb:hover {
    background: rgba(34, 197, 94, 0.3);
}

/* Password Strength Bar for Dark Mode Reset Password */
.dark-theme .pw-strength-bar {
    height: 6px;
    background: rgba(255, 255, 255, 0.08) !important;
    border-radius: 4px;
    overflow: hidden;
}

/* Premium Glassmorphic Info Card for Alerts */
.dark-theme .glass-info-card {
    background: rgba(59, 130, 246, 0.08) !important;
    border: 1px solid rgba(59, 130, 246, 0.2) !important;
    border-radius: 12px;
    padding: 12px 16px;
    margin-bottom: 20px;
    font-size: 0.83rem;
    color: #93c5fd !important;
    backdrop-filter: blur(10px);
}
.dark-theme .glass-info-card i {
    color: #60a5fa !important;
}

/* Mindful Eating Checkbox Cards */
.dark-theme .mindful-check-card {
    background: rgba(255, 255, 255, 0.01) !important;
    border: 1px solid rgba(255, 255, 255, 0.05) !important;
    padding: 8px 12px !important;
    padding-left: 2.5rem !important;
    transition: all 0.2s ease;
    cursor: pointer;
}
.dark-theme .mindful-check-card:hover {
    background: rgba(34, 197, 94, 0.04) !important;
    border-color: rgba(34, 197, 94, 0.2) !important;
}
.dark-theme .mindful-check-card input:checked + label {
    color: #4ade80 !important;
    font-weight: 600;
}

/* ── Dark Theme Questionnaire Elements ── */
.dark-theme .q-card {
    background: rgba(15, 23, 42, 0.65) !important;
    backdrop-filter: blur(24px) !important;
    -webkit-backdrop-filter: blur(24px) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4) !important;
    color: #cbd5e1 !important;
}

.dark-theme .q-section-header {
    border-bottom: 1px solid rgba(255, 255, 255, 0.06) !important;
}

.dark-theme .q-section-icon {
    background: rgba(34, 197, 94, 0.12) !important;
    color: #4ade80 !important;
}

.dark-theme .q-section-header h4 {
    color: #ffffff !important;
}

.dark-theme .q-section-header p {
    color: #94a3b8 !important;
}

.dark-theme .q-input,
.dark-theme .form-control,
.dark-theme .form-select,
.dark-theme select,
.dark-theme input[type="time"],
.dark-theme input[type="date"],
.dark-theme .form-control.q-input,
.dark-theme .form-select.q-input {
    background: rgba(15, 23, 42, 0.6) !important;
    border: 1px solid rgba(255, 255, 255, 0.12) !important;
    color: #ffffff !important;
}

.dark-theme .q-input:focus,
.dark-theme .form-control:focus,
.dark-theme .form-select:focus,
.dark-theme select:focus,
.dark-theme input[type="time"]:focus,
.dark-theme input[type="date"]:focus,
.dark-theme .form-control.q-input:focus,
.dark-theme .form-select.q-input:focus {
    background: rgba(15, 23, 42, 0.85) !important;
    border-color: #22c55e !important;
    color: #ffffff !important;
    box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.2) !important;
}

.dark-theme .q-input::placeholder,
.dark-theme .form-control::placeholder {
    color: #64748b !important;
}

.dark-theme .form-label {
    color: #e2e8f0 !important;
    font-weight: 500;
}

.dark-theme .goal-card-inner,
.dark-theme .work-card-inner,
.dark-theme .water-card-inner,
.dark-theme .stress-card > div {
    background: rgba(255, 255, 255, 0.02) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    color: #cbd5e1 !important;
}

.dark-theme .goal-card-inner:hover,
.dark-theme .work-card-inner:hover,
.dark-theme .water-card-inner:hover,
.dark-theme .stress-card > div:hover {
    background: rgba(255, 255, 255, 0.04) !important;
    border-color: rgba(34, 197, 94, 0.3) !important;
}

.dark-theme .goal-card input:checked + .goal-card-inner,
.dark-theme .work-card input:checked + .work-card-inner {
    border-color: #22c55e !important;
    background: rgba(34, 197, 94, 0.1) !important;
    color: #ffffff !important;
}

.dark-theme .water-card input:checked + .water-card-inner {
    border-color: #06b6d4 !important;
    background: rgba(6, 182, 212, 0.1) !important;
    color: #ffffff !important;
}

.dark-theme .stress-low input:checked + div {
    border-color: #22c55e !important;
    background: rgba(34, 197, 94, 0.1) !important;
    color: #ffffff !important;
}

.dark-theme .stress-mod input:checked + div {
    border-color: #f59e0b !important;
    background: rgba(245, 158, 11, 0.1) !important;
    color: #ffffff !important;
}

.dark-theme .stress-high input:checked + div {
    border-color: #ef4444 !important;
    background: rgba(239, 68, 68, 0.1) !important;
    color: #ffffff !important;
}

.dark-theme .radio-pill span,
.dark-theme .checkbox-pill span {
    background: rgba(255, 255, 255, 0.03) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    color: #94a3b8 !important;
}

.dark-theme .radio-pill:hover span,
.dark-theme .checkbox-pill:hover span {
    border-color: rgba(34, 197, 94, 0.3) !important;
    color: #ffffff !important;
}

.dark-theme .radio-pill input:checked + span,
.dark-theme .checkbox-pill input:checked + span {
    background: #16a34a !important;
    border-color: #16a34a !important;
    color: #ffffff !important;
}

.dark-theme .bmi-preview {
    background: rgba(255, 255, 255, 0.02) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    color: #cbd5e1 !important;
}

.dark-theme .q-progress-bar {
    background: rgba(255, 255, 255, 0.08) !important;
}

.dark-theme .step-dot {
    background: rgba(255, 255, 255, 0.05) !important;
    border-color: rgba(255, 255, 255, 0.1) !important;
    color: #94a3b8 !important;
}

.dark-theme .step-dot.active {
    background: #16a34a !important;
    border-color: #16a34a !important;
    color: #ffffff !important;
}

.dark-theme .step-dot.completed {
    background: rgba(34, 197, 94, 0.2) !important;
    border-color: #22c55e !important;
    color: #4ade80 !important;
}

/* ── Bootstrap Card & Legal Document High-Contrast Engine ── */
[data-theme="dark"] .card,
.dark-theme .card,
.legal-card {
    background: rgba(15, 23, 42, 0.75) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    color: #cbd5e1 !important;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.35) !important;
    backdrop-filter: blur(16px) !important;
    -webkit-backdrop-filter: blur(16px) !important;
}

[data-theme="dark"] .card h1,
[data-theme="dark"] .card h2,
[data-theme="dark"] .card h3,
[data-theme="dark"] .card h4,
[data-theme="dark"] .card h5,
[data-theme="dark"] .card h6,
.dark-theme .card h1,
.dark-theme .card h2,
.dark-theme .card h3,
.dark-theme .card h4,
.dark-theme .card h5,
.dark-theme .card h6,
.legal-card h1,
.legal-card h2,
.legal-card h3,
.legal-card h4,
.legal-card h5,
.legal-card h6 {
    color: #ffffff !important;
    font-family: 'Plus Jakarta Sans', sans-serif !important;
}

.legal-card h2 {
    color: #4ade80 !important;
}

[data-theme="dark"] .card p,
[data-theme="dark"] .card li,
[data-theme="dark"] .card td,
[data-theme="dark"] .card th,
[data-theme="dark"] .card div,
[data-theme="dark"] .card span:not(.badge),
.dark-theme .card p,
.dark-theme .card li,
.dark-theme .card td,
.dark-theme .card th,
.dark-theme .card div,
.dark-theme .card span:not(.badge),
.legal-card p,
.legal-card li,
.legal-card span:not(.badge) {
    color: #cbd5e1 !important;
    line-height: 1.65;
}

[data-theme="dark"] .card strong,
[data-theme="dark"] .card b,
.dark-theme .card strong,
.dark-theme .card b,
.legal-card strong,
.legal-card b {
    color: #ffffff !important;
}

[data-theme="dark"] .card .text-muted,
.dark-theme .card .text-muted,
.legal-card .text-muted {
    color: #94a3b8 !important;
}

[data-theme="dark"] .card a:not(.btn),
.dark-theme .card a:not(.btn),
.legal-card a:not(.btn) {
    color: #4ade80 !important;
}

[data-theme="dark"] .card a:not(.btn):hover,
.dark-theme .card a:not(.btn):hover,
.legal-card a:not(.btn):hover {
    color: #22c55e !important;
    text-decoration: underline !important;
}

/* ── Desktop Hide Enforcement (>= 992px) ── */
@media (min-width: 992px) {
    .mobile-bottom-bar,
    .mobile-bottom-nav,
    .mobile-top-header,
    .sticky-action-tray {
        display: none !important;
    }
}

