/* ============================================================ */
/* BASE / RESET / VARIABLES                                       */
/* ============================================================ */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');

* { box-sizing: border-box; margin: 0; padding: 0; font-family: 'Inter', system-ui, -apple-system, sans-serif; }

:root {
    --bg: #f0f4f8;
    --bg-light: #ffffff;
    --card-bg: rgba(255, 255, 255, 0.95);
    --border: rgba(0, 0, 0, 0.06);
    --primary: #4f46e5;
    --primary-hover: #4338ca;
    --primary-glow: rgba(79, 70, 229, 0.15);
    --primary-light: rgba(79, 70, 229, 0.06);
    --secondary: #7c3aed;
    --accent-pink: #ec4899;
    --accent-green: #10b981;
    --accent-amber: #f59e0b;
    --accent-sky: #0ea5e9;
    --accent-red: #ef4444;
    --text-main: #1e293b;
    --text-secondary: #64748b;
    --text-muted: #94a3b8;
    --emergency: #ef4444;
    --success: #10b981;
    --warning: #f59e0b;
    --radius: 12px;
    --radius-lg: 16px;
    --radius-xl: 20px;
    --shadow-sm: 0 1px 3px rgba(0,0,0,0.05);
    --shadow: 0 4px 16px rgba(0,0,0,0.08);
    --shadow-lg: 0 12px 40px rgba(0,0,0,0.12);
    --glass-border: 1px solid rgba(255,255,255,0.6);
    --transition: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

[data-theme="dark"] {
    --bg: #0a0e1a;
    --bg-light: #131825;
    --card-bg: rgba(19, 24, 37, 0.9);
    --border: rgba(255, 255, 255, 0.07);
    --primary: #818cf8;
    --primary-hover: #6366f1;
    --primary-glow: rgba(129, 140, 248, 0.2);
    --primary-light: rgba(129, 140, 248, 0.1);
    --secondary: #a78bfa;
    --text-main: #f1f5f9;
    --text-secondary: #cbd5e1;
    --text-muted: #64748b;
    --emergency: #f87171;
    --success: #34d399;
    --warning: #fbbf24;
    --shadow-sm: 0 1px 3px rgba(0,0,0,0.3);
    --shadow: 0 4px 16px rgba(0,0,0,0.4);
    --shadow-lg: 0 12px 40px rgba(0,0,0,0.6);
    --glass-border: 1px solid rgba(255,255,255,0.08);
}

body { 
    background: var(--bg); 
    background-image: 
        radial-gradient(ellipse 80% 50% at 20% 0%, rgba(79,70,229,0.06) 0%, transparent 60%),
        radial-gradient(ellipse 60% 40% at 80% 100%, rgba(236,72,153,0.05) 0%, transparent 60%),
        radial-gradient(ellipse 50% 30% at 50% 50%, rgba(16,185,129,0.03) 0%, transparent 60%);
    background-attachment: fixed;
    color: var(--text-main); 
    min-height: 100vh; 
    transition: background var(--transition), color var(--transition); 
}

::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--text-muted); border-radius: 3px; }

@keyframes fadeIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
@keyframes slideIn { from { opacity: 0; transform: translateX(-10px); } to { opacity: 1; transform: translateX(0); } }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.5; } }
@keyframes shimmer { 0% { background-position: -200% 0; } 100% { background-position: 200% 0; } }

/* ============================================================ */
/* AUTH SCREEN                                                    */
/* ============================================================ */
.auth-screen {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 50%, #f093fb 100%);
    background-size: 200% 200%;
    animation: shimmer 12s ease infinite;
}

.auth-card {
    background: rgba(255,255,255,0.98);
    border: none;
    border-radius: var(--radius-xl);
    box-shadow: 0 25px 60px rgba(0,0,0,0.3);
    padding: 1.25rem;
    width: 100%;
    max-width: 880px;
    animation: fadeIn 0.4s ease;
}

.auth-panel { display: grid; grid-template-columns: 1.2fr 1fr; gap: 1.5rem; align-items: stretch; }
.auth-preview, .auth-form-panel { background: #ffffff; border-radius: var(--radius-lg); padding: 1.5rem; }
.auth-preview { display: flex; flex-direction: column; gap: 1rem; }
.auth-logo { display: flex; align-items: center; gap: 0.6rem; font-size: 1.5rem; font-weight: 800; background: linear-gradient(135deg, #4f46e5, #7c3aed, #ec4899); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.auth-logo i { font-size: 1.6rem; -webkit-text-fill-color: var(--primary); }
.auth-tagline, .auth-note { color: var(--text-secondary); font-size: 0.88rem; line-height: 1.6; }
.feature-list { display: grid; grid-template-columns: 1fr 1fr; gap: 0.6rem; }
.feature-item { display: flex; align-items: center; gap: 0.55rem; font-size: 0.82rem; color: var(--text-main); padding: 0.5rem 0.6rem; border-radius: 10px; background: var(--bg); transition: all var(--transition); }
.feature-item:hover { background: var(--primary-light); transform: translateX(3px); }
.feature-item:nth-child(1) i { background: linear-gradient(135deg, #4f46e5, #7c3aed); }
.feature-item:nth-child(2) i { background: linear-gradient(135deg, #10b981, #059669); }
.feature-item:nth-child(3) i { background: linear-gradient(135deg, #ef4444, #dc2626); }
.feature-item:nth-child(4) i { background: linear-gradient(135deg, #f59e0b, #d97706); }
.feature-item i { min-width: 28px; min-height: 28px; display: grid; place-items: center; border-radius: 8px; color: white; font-size: 0.75rem; flex-shrink: 0; }
.auth-note { margin-top: auto; font-size: 0.78rem; color: var(--text-muted); }

.auth-form-panel { display: flex; flex-direction: column; gap: 0.75rem; }
.auth-tabs { display: flex; gap: 0.3rem; background: var(--bg); border-radius: var(--radius); padding: 0.2rem; }
.auth-tab { flex: 1; background: transparent; border: none; color: var(--text-muted); padding: 0.65rem; border-radius: 8px; cursor: pointer; font-weight: 600; font-size: 0.88rem; transition: all var(--transition); }
.auth-tab.active { background: var(--primary); color: white; box-shadow: 0 2px 8px var(--primary-glow); }
.auth-form { display: none; }
.auth-form.active { display: block; animation: fadeIn 0.25s ease; }
.auth-submit { width: 100%; justify-content: center; margin-top: 0.3rem; }
.auth-error { background: rgba(239,68,68,0.08); border: 1px solid rgba(239,68,68,0.2); color: var(--emergency); padding: 0.55rem 0.85rem; border-radius: 8px; font-size: 0.8rem; }
.auth-disclaimer { text-align: center; color: var(--text-muted); font-size: 0.72rem; margin-top: 0.5rem; }
.auth-success { background: rgba(16,185,129,0.08); border: 1px solid rgba(16,185,129,0.2); color: var(--success); padding: 0.55rem 0.85rem; border-radius: 8px; font-size: 0.8rem; }

@media (max-width: 980px) { .auth-panel { grid-template-columns: 1fr; } }
@media (max-width: 768px) { .auth-card { padding: 0.75rem; } .auth-preview { display: none; } }

/* ——— Social Login Buttons ——— */
.auth-social { display: flex; flex-direction: column; gap: 0.55rem; margin-bottom: 0.8rem; }
.social-btn {
    display: flex; align-items: center; justify-content: center; gap: 0.65rem;
    width: 100%; padding: 0.6rem 1rem; border-radius: var(--radius);
    font-size: 0.85rem; font-weight: 600; cursor: pointer; transition: all 0.2s ease;
    border: 1px solid var(--border); background: var(--card-bg); color: var(--text-primary);
}
.social-btn:hover { transform: translateY(-1px); box-shadow: 0 4px 12px rgba(0,0,0,0.1); }
.social-btn:active { transform: translateY(0); }
.social-icon { width: 20px; height: 20px; flex-shrink: 0; }
.social-google:hover { border-color: #4285F4; background: rgba(66,133,244,0.04); }
.social-github:hover { border-color: #333; background: rgba(51,51,51,0.04); }
.social-github svg { width: 20px; height: 20px; }
.social-apple:hover { border-color: #000; background: rgba(0,0,0,0.04); }
.social-apple svg { width: 20px; height: 20px; }
.social-phone:hover { border-color: #10b981; background: rgba(16,185,129,0.04); }
.social-phone .social-icon { color: #10b981; font-size: 1.1rem; }

/* ——— Divider ——— */
.auth-divider {
    display: flex; align-items: center; gap: 0.75rem; margin-bottom: 0.8rem; color: var(--text-muted); font-size: 0.78rem;
}
.auth-divider::before, .auth-divider::after { content: ""; flex: 1; height: 1px; background: var(--border); }

/* ——— Input Wrapper ——— */
.input-wrapper {
    position: relative; display: flex; align-items: center;
}
.input-wrapper input { width: 100%; padding-left: 2.2rem; }
.input-icon { position: absolute; left: 0.75rem; color: var(--text-muted); font-size: 0.85rem; pointer-events: none; z-index: 1; }
.input-wrapper input:focus + .password-toggle,
.input-wrapper input:focus ~ .password-toggle { color: var(--primary); }

/* ——— Password Toggle ——— */
.password-toggle {
    position: absolute; right: 0.6rem; background: none; border: none; cursor: pointer;
    color: var(--text-muted); font-size: 0.85rem; padding: 0.25rem; transition: color 0.2s;
}
.password-toggle:hover { color: var(--primary); }

/* ——— Auth Options Row ——— */
.auth-options {
    display: flex; align-items: center; justify-content: space-between; margin-bottom: 0.4rem; font-size: 0.8rem;
}
.auth-checkbox {
    display: flex; align-items: center; gap: 0.4rem; cursor: pointer; color: var(--text-secondary); user-select: none;
}
.auth-checkbox input { display: none; }
.auth-checkbox .checkmark {
    width: 16px; height: 16px; border-radius: 4px; border: 1.5px solid var(--border); background: var(--card-bg);
    display: flex; align-items: center; justify-content: center; transition: all 0.2s; flex-shrink: 0;
}
.auth-checkbox input:checked + .checkmark { background: var(--primary); border-color: var(--primary); }
.auth-checkbox input:checked + .checkmark::after { content: "\f00c"; font-family: "Font Awesome 6 Free"; font-weight: 900; font-size: 0.55rem; color: white; }
.auth-forgot { color: var(--primary); text-decoration: none; font-weight: 600; }
.auth-forgot:hover { text-decoration: underline; }

/* ——— Password Strength ——— */
.password-strength { display: flex; align-items: center; gap: 0.5rem; margin-top: 0.3rem; min-height: 1.2rem; }
.strength-bar { flex: 1; height: 4px; border-radius: 2px; background: var(--border); overflow: hidden; }
.strength-fill { height: 100%; width: 0%; border-radius: 2px; transition: all 0.3s ease; }
.strength-text { font-size: 0.7rem; font-weight: 600; white-space: nowrap; min-width: 60px; text-align: right; }
.strength-weak .strength-fill { width: 33%; background: #ef4444; }
.strength-weak .strength-text { color: #ef4444; }
.strength-fair .strength-fill { width: 66%; background: #f59e0b; }
.strength-fair .strength-text { color: #f59e0b; }
.strength-strong .strength-fill { width: 100%; background: #10b981; }
.strength-strong .strength-text { color: #10b981; }

/* ——— Multi-Step Auth ——— */
.auth-step { display: none; }
.auth-step.active { display: block; animation: fadeIn 0.25s ease; }

/* Step Header with back button */
.step-header {
    display: flex; align-items: center; gap: 0.65rem; margin-bottom: 0.75rem; padding: 0.5rem 0.6rem;
    background: var(--bg); border-radius: var(--radius); border: 1px solid var(--border);
}
.step-back {
    background: none; border: none; cursor: pointer; color: var(--text-muted); font-size: 0.9rem;
    width: 28px; height: 28px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
    transition: all 0.2s; flex-shrink: 0;
}
.step-back:hover { background: var(--border); color: var(--primary); }
.step-header-info { display: flex; flex-direction: column; }
.step-email-label { font-weight: 700; color: var(--text-primary); font-size: 0.82rem; }
.step-hint { color: var(--text-muted); font-size: 0.72rem; }

/* OTP Input Boxes */
.otp-input-group { display: flex; gap: 0.45rem; justify-content: center; margin: 0.5rem 0; }
.otp-box {
    width: 44px; height: 50px; text-align: center; font-size: 1.25rem; font-weight: 700;
    border: 2px solid var(--border); border-radius: var(--radius); background: var(--card-bg);
    color: var(--text-primary); transition: border-color 0.2s; outline: none;
}
.otp-box:focus { border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-glow); }
.otp-box.filled { border-color: var(--primary); background: rgba(79,70,229,0.04); }

/* Alt action link */
.auth-alt-action { text-align: center; margin-top: 0.65rem; }
.link-btn {
    background: none; border: none; cursor: pointer; color: var(--primary);
    font-size: 0.8rem; font-weight: 600; padding: 0.3rem 0.5rem; border-radius: 6px; transition: all 0.2s;
}
.link-btn:hover { background: rgba(79,70,229,0.08); }
.otp-timer { font-size: 0.75rem; color: var(--text-muted); margin-left: 0.4rem; }

/* Dev OTP hint */
.dev-otp-hint {
    background: linear-gradient(135deg, #fef3c7, #fde68a); border: 1px solid #f59e0b;
    border-radius: 8px; padding: 0.6rem 0.85rem; margin-bottom: 0.75rem;
    font-size: 0.8rem; color: #92400e; display: flex; align-items: center; gap: 0.5rem;
}
.dev-otp-hint i { color: #f59e0b; }
.dev-otp-hint strong { font-size: 1.1rem; letter-spacing: 3px; color: #78350f; }

/* ============================================================ */
/* APP SHELL / LAYOUT                                              */
/* ============================================================ */
.app-root { display: flex; flex-direction: column; min-height: 100vh; }

/* ============================================================ */
/* TOP NAVBAR                                                     */
/* ============================================================ */
.topnav {
    position: fixed;
    top: 0; left: 0; right: 0;
    z-index: 100;
    background: linear-gradient(135deg, #1e1b4b, #312e81);
    height: 56px;
    display: flex;
    align-items: center;
}
.topnav-inner {
    width: 100%;
    max-width: 1600px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 100%;
    padding: 0 1rem;
}
.topnav-left { flex-shrink: 0; }
.topnav-logo {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    font-size: 1.1rem;
    font-weight: 800;
    color: white;
    white-space: nowrap;
}
.topnav-logo .logo-img { height: 32px; filter: brightness(0) invert(1); }

.topnav-links {
    display: flex;
    align-items: center;
    gap: 2px;
    overflow-x: auto;
    scrollbar-width: none;
    flex: 1;
    margin: 0 1rem;
    padding: 0.25rem 0;
}
.topnav-links::-webkit-scrollbar { display: none; }

.topnav-link {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.4rem 0.7rem;
    color: rgba(255,255,255,0.55);
    border-radius: 8px;
    cursor: pointer;
    font-weight: 500;
    font-size: 0.78rem;
    white-space: nowrap;
    transition: all var(--transition);
    flex-shrink: 0;
}
.topnav-link:hover { background: rgba(255,255,255,0.1); color: white; }
.topnav-link.active {
    background: rgba(255,255,255,0.15);
    color: white;
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}
.topnav-link i { font-size: 0.8rem; width: 16px; text-align: center; }

.topnav-right {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-shrink: 0;
}
.topnav-theme-btn {
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.15);
    color: rgba(255,255,255,0.7);
    width: 36px; height: 36px;
    display: grid; place-items: center;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all var(--transition);
}
.topnav-theme-btn:hover { background: rgba(255,255,255,0.2); color: white; }

.topnav-user {
    display: flex;
    align-items: center;
    gap: 0.4rem;
}
.topnav-avatar {
    width: 30px; height: 30px;
    border-radius: 8px;
    background: linear-gradient(135deg, #4f46e5, #7c3aed);
    color: white;
    display: flex; align-items: center; justify-content: center;
    font-weight: 700; font-size: 0.72rem;
    flex-shrink: 0;
}
.topnav-username {
    font-size: 0.78rem;
    font-weight: 600;
    color: rgba(255,255,255,0.85);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100px;
}
.topnav-logout-btn {
    background: none;
    border: none;
    color: rgba(255,255,255,0.4);
    cursor: pointer;
    padding: 0.3rem;
    border-radius: 6px;
    font-size: 0.85rem;
    transition: all var(--transition);
    flex-shrink: 0;
}
.topnav-logout-btn:hover { color: #f87171; background: rgba(248,113,113,0.15); }

.topnav-hamburger {
    display: none;
    background: none;
    border: none;
    color: rgba(255,255,255,0.8);
    font-size: 1.1rem;
    cursor: pointer;
    padding: 0.35rem;
    border-radius: 8px;
    transition: all var(--transition);
}
.topnav-hamburger:hover { background: rgba(255,255,255,0.1); }

/* ============================================================ */
/* MOBILE DROPDOWN MENU                                           */
/* ============================================================ */
.mobile-menu-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    z-index: 90;
    backdrop-filter: blur(4px);
}
.mobile-menu-overlay.open { display: block; }

.mobile-dropdown {
    display: none;
    position: fixed;
    top: 56px;
    left: 0; right: 0;
    background: #1e1b4b;
    z-index: 95;
    max-height: calc(100vh - 56px);
    overflow-y: auto;
    border-bottom: 2px solid rgba(167,139,250,0.2);
    box-shadow: 0 10px 40px rgba(0,0,0,0.4);
}
.mobile-dropdown.open { display: block; animation: slideDown 0.25s ease; }
@keyframes slideDown { from { opacity: 0; transform: translateY(-10px); } to { opacity: 1; transform: translateY(0); } }

.mobile-dropdown-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem;
    border-bottom: 1px solid rgba(255,255,255,0.08);
}
.mobile-dropdown-user {
    display: flex;
    align-items: center;
    gap: 0.6rem;
}
.mobile-dropdown-avatar {
    width: 36px; height: 36px;
    border-radius: 10px;
    background: linear-gradient(135deg, #4f46e5, #7c3aed);
    color: white;
    display: flex; align-items: center; justify-content: center;
    font-weight: 700; font-size: 0.8rem;
}
.mobile-dropdown-name { font-weight: 600; font-size: 0.88rem; color: white; }
.mobile-dropdown-email { font-size: 0.72rem; color: rgba(255,255,255,0.4); }
.mobile-dropdown-close {
    background: none; border: none;
    color: rgba(255,255,255,0.5);
    font-size: 1.2rem; cursor: pointer;
    padding: 0.3rem; border-radius: 6px;
    transition: all var(--transition);
}
.mobile-dropdown-close:hover { color: white; background: rgba(255,255,255,0.1); }

.mobile-dropdown-links { padding: 0.5rem; }
.mobile-dropdown-link {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.65rem 0.8rem;
    color: rgba(255,255,255,0.6);
    border-radius: 10px;
    cursor: pointer;
    font-weight: 500;
    font-size: 0.84rem;
    transition: all var(--transition);
}
.mobile-dropdown-link:hover { background: rgba(255,255,255,0.08); color: white; }
.mobile-dropdown-link.active {
    background: linear-gradient(135deg, #4f46e5, #7c3aed);
    color: white; font-weight: 600;
    box-shadow: 0 4px 12px rgba(79,70,229,0.3);
}
.mobile-dropdown-link i { width: 20px; text-align: center; font-size: 0.88rem; }

.mobile-dropdown-footer {
    padding: 0.5rem;
    border-top: 1px solid rgba(255,255,255,0.08);
    display: flex;
    gap: 0.5rem;
}
.mobile-dropdown-theme,
.mobile-dropdown-logout {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    padding: 0.55rem;
    border-radius: 10px;
    border: none;
    cursor: pointer;
    font-weight: 500;
    font-size: 0.8rem;
    transition: all var(--transition);
}
.mobile-dropdown-theme {
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.1);
    color: rgba(255,255,255,0.7);
}
.mobile-dropdown-theme:hover { background: rgba(255,255,255,0.15); color: white; }
.mobile-dropdown-logout {
    background: rgba(248,113,113,0.1);
    border: 1px solid rgba(248,113,113,0.2);
    color: rgba(248,113,113,0.8);
}
.mobile-dropdown-logout:hover { background: rgba(248,113,113,0.2); color: #f87171; }

/* ============================================================ */
/* MOBILE BOTTOM NAV                                              */
/* ============================================================ */
.mobile-nav { display: none; position: fixed; bottom: 0; left: 0; width: 100%; background: var(--bg-light); border-top: 1px solid var(--border); padding: 0.3rem 0; justify-content: space-around; z-index: 40; box-shadow: 0 -4px 20px rgba(0,0,0,0.08); }
.mobile-nav-item { display: flex; flex-direction: column; align-items: center; color: var(--text-muted); font-size: 0.6rem; cursor: pointer; padding: 0.25rem 0.4rem; gap: 2px; transition: color var(--transition); }
.mobile-nav-item i { font-size: 1.05rem; }
.mobile-nav-item.active { color: var(--primary); }
.mobile-nav-orb { background: linear-gradient(135deg, #4f46e5, #7c3aed); width: 46px; height: 46px; border-radius: 50%; display: flex; align-items: center; justify-content: center; color: white; margin-top: -18px; border: 3px solid var(--bg-light); box-shadow: 0 4px 16px rgba(79,70,229,0.4); }
.mobile-nav-orb i { font-size: 1.15rem; }

/* ============================================================ */
/* MAIN CONTENT                                                   */
/* ============================================================ */
.main-content { margin-left: 0; padding: 72px 1.75rem 1.25rem; flex: 1; min-height: 100vh; }

.page-shell { min-width: 0; }

.topbar { 
    display: flex; 
    align-items: center; 
    justify-content: space-between; 
    gap: 0.8rem; 
    padding: 0.75rem 1rem; 
    background: linear-gradient(135deg, rgba(79,70,229,0.04), rgba(124,58,237,0.03)); 
    border: 1px solid rgba(79,70,229,0.08); 
    border-radius: var(--radius-lg); 
    margin-bottom: 1.25rem; 
}
.topbar-title { font-size: 1.25rem; font-weight: 800; background: linear-gradient(135deg, #4f46e5, #7c3aed); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.topbar-actions { display: flex; gap: 0.5rem; align-items: center; flex-wrap: wrap; }
.topbar-location { font-size: 0.78rem; color: var(--text-muted); display: flex; align-items: center; gap: 0.35rem; background: rgba(79,70,229,0.06); padding: 0.35rem 0.7rem; border-radius: 20px; }

.view-section { display: none; }
.view-section.active { display: block; animation: fadeIn 0.3s ease; }

/* ============================================================ */
/* CARDS / GLASS                                                   */
/* ============================================================ */
.glass-card {
    background: linear-gradient(135deg, rgba(255,255,255,0.98), rgba(255,255,255,0.92));
    border: 1px solid rgba(255,255,255,0.8);
    border-radius: var(--radius-lg);
    padding: 1.3rem;
    margin-bottom: 1rem;
    box-shadow: 0 2px 12px rgba(0,0,0,0.04);
    backdrop-filter: blur(16px);
    transition: all var(--transition);
    position: relative;
    overflow: hidden;
}
.glass-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: linear-gradient(180deg, #4f46e5, #7c3aed, #ec4899);
    border-radius: 4px 0 0 4px;
    opacity: 0;
    transition: opacity var(--transition);
}
.glass-card:hover { box-shadow: 0 8px 24px rgba(0,0,0,0.08); transform: translateY(-1px); }
.glass-card:hover::before { opacity: 1; }
.glass-card-title { font-size: 0.95rem; font-weight: 700; margin-bottom: 0.65rem; display: flex; align-items: center; gap: 0.45rem; color: var(--text-main); }

/* Section-specific card accents */
#view-dashboard .glass-card::before { background: linear-gradient(180deg, #4f46e5, #3b82f6); }
#view-chatbot .glass-card::before,
#view-chatbot .chat-container::before { background: linear-gradient(180deg, #10b981, #059669); }
#view-medicines .glass-card::before { background: linear-gradient(180deg, #ec4899, #d946ef); }
#view-conditions .glass-card::before { background: linear-gradient(180deg, #f59e0b, #d97706); }
#view-interactions .glass-card::before { background: linear-gradient(180deg, #ef4444, #dc2626); }
#view-hospitals .glass-card::before { background: linear-gradient(180deg, #0ea5e9, #0284c7); }
#view-pharmacies .glass-card::before { background: linear-gradient(180deg, #10b981, #059669); }
#view-emergency .glass-card::before { background: linear-gradient(180deg, #ef4444, #b91c1c); }
#view-saved .glass-card::before { background: linear-gradient(180deg, #f59e0b, #ea580c); }
#view-account .glass-card::before { background: linear-gradient(180deg, #8b5cf6, #7c3aed); }
#view-activity .glass-card::before { background: linear-gradient(180deg, #06b6d4, #0891b2); }

/* Hero Banners - each section gets unique vibrant colors */
.hero-banner {
    padding: 1.5rem 1.3rem;
    border-radius: var(--radius-lg);
    margin-bottom: 1.25rem;
    border: 1px solid transparent;
    position: relative;
    overflow: hidden;
}
.hero-banner h1 { font-size: 1.6rem; margin-bottom: 0.25rem; font-weight: 800; line-height: 1.15; }
.hero-banner p { font-size: 0.88rem; margin-top: 0.2rem; }

#view-dashboard .hero-banner { 
    background: linear-gradient(135deg, rgba(79,70,229,0.12), rgba(59,130,246,0.08), rgba(139,92,246,0.06)); 
    border-color: rgba(79,70,229,0.12);
}
#view-dashboard .hero-banner h1 { color: #4f46e5; }
#view-dashboard .hero-banner p { color: rgba(79,70,229,0.7); }

#view-chatbot .hero-banner { 
    background: linear-gradient(135deg, rgba(16,185,129,0.12), rgba(6,182,212,0.08), rgba(5,150,105,0.06)); 
    border-color: rgba(16,185,129,0.12);
}
#view-chatbot .hero-banner h1 { color: #e84393; }
#view-chatbot .hero-banner p { color: rgba(5,150,105,0.7); }

#view-medicines .hero-banner { 
    background: linear-gradient(135deg, rgba(236,72,153,0.12), rgba(217,70,239,0.08), rgba(244,114,182,0.06)); 
    border-color: rgba(236,72,153,0.12);
}
#view-medicines .hero-banner h1 { color: #db2777; }
#view-medicines .hero-banner p { color: rgba(219,39,119,0.7); }

#view-conditions .hero-banner { 
    background: linear-gradient(135deg, rgba(245,158,11,0.12), rgba(234,88,12,0.08), rgba(251,191,36,0.06)); 
    border-color: rgba(245,158,11,0.12);
}
#view-conditions .hero-banner h1 { color: #d97706; }
#view-conditions .hero-banner p { color: rgba(217,119,6,0.7); }

#view-interactions .hero-banner { 
    background: linear-gradient(135deg, rgba(239,68,68,0.12), rgba(220,38,38,0.08), rgba(248,113,113,0.06)); 
    border-color: rgba(239,68,68,0.12);
}
#view-interactions .hero-banner h1 { color: #dc2626; }
#view-interactions .hero-banner p { color: rgba(220,38,38,0.7); }

#view-hospitals .hero-banner { 
    background: linear-gradient(135deg, rgba(14,165,233,0.12), rgba(2,132,199,0.08), rgba(56,189,248,0.06)); 
    border-color: rgba(14,165,233,0.12);
}
#view-hospitals .hero-banner h1 { color: #0284c7; }
#view-hospitals .hero-banner p { color: rgba(2,132,199,0.7); }

#view-pharmacies .hero-banner { 
    background: linear-gradient(135deg, rgba(16,185,129,0.12), rgba(5,150,105,0.08), rgba(52,211,153,0.06)); 
    border-color: rgba(16,185,129,0.12);
}
#view-pharmacies .hero-banner h1 { color: #059669; }
#view-pharmacies .hero-banner p { color: rgba(5,150,105,0.7); }

#view-emergency .hero-banner { 
    background: linear-gradient(135deg, rgba(239,68,68,0.15), rgba(185,28,28,0.1), rgba(248,113,113,0.08)); 
    border: 2px solid rgba(239,68,68,0.2);
}
#view-emergency .hero-banner h1 { color: #dc2626; }
#view-emergency .hero-banner p { color: rgba(220,38,38,0.7); }

#view-saved .hero-banner { 
    background: linear-gradient(135deg, rgba(245,158,11,0.12), rgba(234,88,12,0.08), rgba(251,191,36,0.06)); 
    border-color: rgba(245,158,11,0.12);
}
#view-saved .hero-banner h1 { color: #d97706; }
#view-saved .hero-banner p { color: rgba(217,119,6,0.7); }

#view-account .hero-banner { 
    background: linear-gradient(135deg, rgba(139,92,246,0.12), rgba(124,58,237,0.08), rgba(167,139,250,0.06)); 
    border-color: rgba(139,92,246,0.12);
}
#view-account .hero-banner h1 { color: #7c3aed; }
#view-account .hero-banner p { color: rgba(124,58,237,0.7); }

#view-activity .hero-banner { 
    background: linear-gradient(135deg, rgba(6,182,212,0.12), rgba(8,145,178,0.08), rgba(34,211,238,0.06)); 
    border-color: rgba(6,182,212,0.12);
}
#view-activity .hero-banner h1 { color: #0891b2; }
#view-activity .hero-banner p { color: rgba(8,145,178,0.7); }

.stat-label { color: var(--text-muted); font-size: 0.72rem; display: block; margin-bottom: 0.15rem; text-transform: uppercase; font-weight: 600; letter-spacing: 0.03em; }
.stat-number { font-size: 1.35rem; font-weight: 800; color: var(--text-main); }
.stat-card { 
    padding: 1.1rem; 
    background: linear-gradient(135deg, rgba(255,255,255,0.95), rgba(255,255,255,0.85));
    border: 1px solid rgba(255,255,255,0.8);
    position: relative;
    overflow: hidden;
}
.stat-card::after {
    content: '';
    position: absolute;
    top: -30%;
    right: -30%;
    width: 80px;
    height: 80px;
    border-radius: 50%;
    opacity: 0.1;
    transition: opacity var(--transition);
}
.stat-card:hover { transform: translateY(-3px); box-shadow: 0 8px 24px rgba(0,0,0,0.1); }
.stat-card:hover::after { opacity: 0.2; }
.stat-card:nth-child(1)::after { background: #6c63ff; }
.stat-card:nth-child(2)::after { background: #3b82f6; }
.stat-card:nth-child(3)::after { background: #10b981; }
.stat-card:nth-child(4)::after { background: #ec4899; }
.stat-card:nth-child(5)::after { background: #f59e0b; }
.stat-icon-wrapper { display: flex; align-items: center; gap: 0.75rem; }
.stat-icon { width: 40px; height: 40px; border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 1rem; color: white; flex-shrink: 0; }
.stat-purple { background: linear-gradient(135deg, #6c63ff, #4834d4); }
.stat-blue { background: linear-gradient(135deg, #3b82f6, #2563eb); }
.stat-green { background: linear-gradient(135deg, #10b981, #059669); }
.stat-pink { background: linear-gradient(135deg, #ec4899, #d946ef); }
.stat-orange { background: linear-gradient(135deg, #f59e0b, #d97706); }

.section-heading { 
    font-size: 1rem; 
    margin-bottom: 0.65rem; 
    font-weight: 700; 
    color: var(--text-main);
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

/* ============================================================ */
/* BUTTONS                                                         */
/* ============================================================ */
.btn-primary {
    background: linear-gradient(135deg, #4f46e5, #7c3aed);
    color: white;
    border: none;
    padding: 0.65rem 1.2rem;
    border-radius: var(--radius);
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.85rem;
    box-shadow: 0 2px 8px var(--primary-glow);
}
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 4px 16px var(--primary-glow); }
.btn-primary:active { transform: translateY(0); }
.btn-primary:disabled { opacity: 0.5; cursor: not-allowed; transform: none; }

.btn-secondary {
    background: var(--bg);
    border: 1px solid var(--border);
    color: var(--text-main);
    padding: 0.55rem 1rem;
    border-radius: var(--radius);
    cursor: pointer;
    transition: all var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.82rem;
    font-weight: 500;
}
.btn-secondary:hover { background: var(--primary-light); color: var(--primary); border-color: var(--primary); }

.btn-danger {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: white;
    border: none;
    padding: 0.65rem 1.2rem;
    border-radius: var(--radius);
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.85rem;
}
.btn-danger:hover { opacity: 0.9; transform: translateY(-1px); }

.full-width { width: 100%; justify-content: center; }

/* ============================================================ */
/* FORMS                                                           */
/* ============================================================ */
input, textarea, select {
    background: var(--bg);
    border: 1px solid var(--border);
    padding: 0.65rem 0.85rem;
    border-radius: var(--radius);
    color: var(--text-main);
    width: 100%;
    font-size: 0.88rem;
    transition: all var(--transition);
}
input:focus, textarea:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-glow); background: var(--bg-light); }
textarea { resize: vertical; min-height: 56px; }
.form-group { margin-bottom: 0.75rem; }
.form-group label { display: block; margin-bottom: 0.25rem; font-weight: 600; color: var(--text-secondary); font-size: 0.8rem; }

.search-bar { display: flex; gap: 0.5rem; flex-wrap: wrap; }
.search-bar input { flex: 1; min-width: 180px; }
.search-note { color: var(--text-muted); font-size: 0.74rem; margin-top: 0.4rem; }

/* ============================================================ */
/* GRID                                                            */
/* ============================================================ */
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0.9rem; }
.grid-5 { display: grid; grid-template-columns: repeat(5, 1fr); gap: 0.8rem; }

/* ============================================================ */
/* QUICK ACTIONS                                                   */
/* ============================================================ */
.quick-action {
    background: linear-gradient(135deg, rgba(255,255,255,0.98), rgba(255,255,255,0.92));
    border: 1px solid rgba(255,255,255,0.8);
    border-radius: var(--radius-lg);
    padding: 1.1rem;
    cursor: pointer;
    transition: all var(--transition);
    display: flex;
    align-items: center;
    gap: 0.75rem;
    border-left: 4px solid transparent;
    box-shadow: 0 2px 12px rgba(0,0,0,0.04);
}
.quick-action:nth-child(1) { border-left-color: #4f46e5; background: linear-gradient(135deg, rgba(79,70,229,0.04), rgba(255,255,255,0.98)); }
.quick-action:nth-child(2) { border-left-color: #ec4899; background: linear-gradient(135deg, rgba(236,72,153,0.04), rgba(255,255,255,0.98)); }
.quick-action:nth-child(3) { border-left-color: #ef4444; background: linear-gradient(135deg, rgba(239,68,68,0.04), rgba(255,255,255,0.98)); }
.quick-action:hover { transform: translateY(-4px); box-shadow: 0 8px 24px rgba(0,0,0,0.1); }
.quick-action-icon { width: 42px; height: 42px; border-radius: 12px; display: flex; align-items: center; justify-content: center; color: white; font-size: 1rem; flex-shrink: 0; box-shadow: 0 4px 12px rgba(0,0,0,0.15); }
.quick-action-content h3 { font-size: 0.88rem; margin-bottom: 0.1rem; font-weight: 700; }
.quick-action-content p { color: var(--text-muted); font-size: 0.76rem; }

/* ============================================================ */
/* FILTERS                                                         */
/* ============================================================ */
.filter-row { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-bottom: 0.9rem; }
.filter-btn { background: var(--bg); border: 1px solid var(--border); padding: 0.35rem 0.8rem; border-radius: 20px; color: var(--text-secondary); cursor: pointer; transition: all var(--transition); font-size: 0.78rem; font-weight: 500; white-space: nowrap; }
.filter-btn:nth-child(1):hover, .filter-btn:nth-child(1).active { background: linear-gradient(135deg, #4f46e5, #6366f1); color: white; border-color: #4f46e5; box-shadow: 0 2px 8px rgba(79,70,229,0.3); }
.filter-btn:nth-child(2):hover, .filter-btn:nth-child(2).active { background: linear-gradient(135deg, #ec4899, #f472b6); color: white; border-color: #ec4899; box-shadow: 0 2px 8px rgba(236,72,153,0.3); }
.filter-btn:nth-child(3):hover, .filter-btn:nth-child(3).active { background: linear-gradient(135deg, #10b981, #34d399); color: white; border-color: #10b981; box-shadow: 0 2px 8px rgba(16,185,129,0.3); }
.filter-btn:nth-child(4):hover, .filter-btn:nth-child(4).active { background: linear-gradient(135deg, #f59e0b, #fbbf24); color: white; border-color: #f59e0b; box-shadow: 0 2px 8px rgba(245,158,11,0.3); }
.filter-btn:nth-child(5):hover, .filter-btn:nth-child(5).active { background: linear-gradient(135deg, #0ea5e9, #38bdf8); color: white; border-color: #0ea5e9; box-shadow: 0 2px 8px rgba(14,165,233,0.3); }

/* ============================================================ */
/* MEDICINE CARDS                                                   */
/* ============================================================ */
.medicine-card { 
    background: linear-gradient(135deg, rgba(255,255,255,0.98), rgba(255,255,255,0.92)); 
    border: 1px solid rgba(255,255,255,0.8); 
    border-radius: var(--radius); 
    padding: 1rem; 
    cursor: pointer; 
    transition: all var(--transition); 
    border-top: 3px solid transparent; 
    box-shadow: 0 2px 12px rgba(0,0,0,0.04);
}
.medicine-card:nth-child(3n+1) { border-top-color: #4f46e5; background: linear-gradient(135deg, rgba(79,70,229,0.03), rgba(255,255,255,0.98)); }
.medicine-card:nth-child(3n+2) { border-top-color: #ec4899; background: linear-gradient(135deg, rgba(236,72,153,0.03), rgba(255,255,255,0.98)); }
.medicine-card:nth-child(3n+3) { border-top-color: #10b981; background: linear-gradient(135deg, rgba(16,185,129,0.03), rgba(255,255,255,0.98)); }
.medicine-card:hover { transform: translateY(-3px); box-shadow: 0 8px 24px rgba(0,0,0,0.1); }
.medicine-card h4 { font-weight: 600; font-size: 0.9rem; }
.medicine-card .brand { color: var(--text-muted); font-size: 0.76rem; }
.medicine-card .category { display: inline-block; color: white; padding: 0.1rem 0.45rem; border-radius: 10px; font-size: 0.64rem; margin-top: 0.2rem; font-weight: 600; }
.medicine-card:nth-child(3n+1) .category { background: linear-gradient(135deg, #4f46e5, #7c3aed); }
.medicine-card:nth-child(3n+2) .category { background: linear-gradient(135deg, #ec4899, #d946ef); }
.medicine-card:nth-child(3n+3) .category { background: linear-gradient(135deg, #10b981, #059669); }
.medicine-card .uses { color: var(--text-muted); font-size: 0.78rem; margin-top: 0.35rem; }

/* ============================================================ */
/* CHAT                                                            */
/* ============================================================ */
.chat-hero { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 0.8rem; }
.chat-container { 
    height: calc(100vh - 310px); 
    display: flex; 
    flex-direction: column;
    background: linear-gradient(135deg, rgba(16,185,129,0.02), rgba(6,182,212,0.02));
    border: 1px solid rgba(16,185,129,0.08);
    border-radius: var(--radius-lg);
    padding: 0.5rem;
}
.chat-messages { flex: 1; overflow-y: auto; padding: 0.85rem; border: 1px solid var(--border); border-radius: var(--radius-lg); background: var(--bg); margin-bottom: 0.6rem; display: flex; flex-direction: column; gap: 0.65rem; }

.chat-bubble-wrap { display: flex; animation: fadeIn 0.3s ease; }
.chat-bubble-wrap.user { justify-content: flex-end; }

.chat-bubble { max-width: 78%; padding: 0.7rem 0.9rem; border-radius: var(--radius); line-height: 1.6; font-size: 0.88rem; }
.chat-bubble.bot { background: var(--card-bg); border: 1px solid var(--border); border-bottom-left-radius: 4px; color: var(--text-main); display: flex; gap: 0.5rem; }
.chat-bubble.user { background: linear-gradient(135deg, #4f46e5, #7c3aed); color: white; border-bottom-right-radius: 4px; box-shadow: 0 2px 10px var(--primary-glow); }
.chat-bubble.bot ul, .chat-bubble.bot li { list-style: none; }
.chat-bubble.bot ul { margin: 0.3rem 0 0 0.85rem; line-height: 1.5; }
.chat-bubble.user code { background: rgba(255,255,255,0.2); padding: 0.1rem 0.3rem; border-radius: 3px; }

.bubble-content { flex: 1; min-width: 0; }
.bubble-text { word-wrap: break-word; }
.bubble-meta { display: flex; justify-content: space-between; align-items: center; margin-top: 0.35rem; }
.bubble-time { font-size: 0.64rem; opacity: 0.5; }

.copy-btn { background: none; border: none; cursor: pointer; font-size: 0.7rem; opacity: 0.5; transition: opacity 0.2s; padding: 2px; }
.copy-btn:hover { opacity: 1; }

.chat-orb { width: 20px; height: 20px; border-radius: 8px; background: linear-gradient(135deg, #e84393, #fd79a8); flex-shrink: 0; display: flex; align-items: center; justify-content: center; color: white; font-size: 0.6rem; }

.chat-input-area { display: flex; gap: 0.5rem; align-items: center; }
.chat-input-area input { flex: 1; }

.chat-suggestions { display: flex; gap: 0.35rem; flex-wrap: wrap; margin-top: 0.4rem; }
.chat-suggestions button { background: var(--bg-light); border: 1px solid var(--border); padding: 0.3rem 0.65rem; border-radius: 16px; color: var(--text-secondary); cursor: pointer; font-size: 0.7rem; font-weight: 500; transition: all var(--transition); }
.chat-suggestions button:hover { background: var(--primary); color: white; border-color: var(--primary); }

.typing-dot { display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--text-muted); margin: 0 2px; animation: typingBounce 1.4s infinite ease-in-out; }
.typing-dot:nth-child(2) { animation-delay: 0.2s; }
.typing-dot:nth-child(3) { animation-delay: 0.4s; }
@keyframes typingBounce { 0%, 60%, 100% { transform: translateY(0); } 30% { transform: translateY(-5px); } }

/* ============================================================ */
/* CHAT STATUS BADGE                                               */
/* ============================================================ */
.chat-status-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.74rem;
    font-weight: 600;
    padding: 0.3rem 0.65rem;
    border-radius: 20px;
    background: var(--card-bg);
    border: 1px solid var(--border);
    color: var(--text-main);
    white-space: nowrap;
}
.chat-status-badge.online { border-color: rgba(16,185,129,0.3); background: rgba(16,185,129,0.08); color: var(--success); }
.chat-status-badge.offline { border-color: rgba(245,158,11,0.3); background: rgba(245,158,11,0.08); color: var(--warning); }
.status-dot { width: 6px; height: 6px; border-radius: 50%; display: inline-block; }
.status-dot.online { background-color: var(--success); box-shadow: 0 0 6px var(--success); }
.status-dot.offline { background-color: var(--warning); box-shadow: 0 0 6px var(--warning); }

/* ============================================================ */
/* LOCATIONS / EMERGENCY / INTERACTIONS                           */
/* ============================================================ */
.location-card { 
    background: linear-gradient(135deg, rgba(255,255,255,0.98), rgba(255,255,255,0.92)); 
    border: 1px solid rgba(255,255,255,0.8); 
    border-radius: var(--radius); 
    padding: 1rem; 
    transition: all var(--transition); 
    border-top: 3px solid var(--accent-sky);
    box-shadow: 0 2px 12px rgba(0,0,0,0.04);
}
.location-card:hover { border-color: var(--accent-sky); transform: translateY(-3px); box-shadow: 0 8px 24px rgba(0,0,0,0.1); }
.location-card h4 { font-weight: 600; font-size: 0.9rem; }
.location-card .address { color: var(--text-muted); font-size: 0.78rem; margin: 0.15rem 0; }
.location-card .phone { color: var(--accent-sky); font-size: 0.85rem; font-weight: 500; }
.location-card .badge { display: inline-block; padding: 0.1rem 0.45rem; border-radius: 10px; font-size: 0.64rem; font-weight: 600; margin-right: 0.2rem; }
.badge.available { background: rgba(16,185,129,0.12); color: var(--success); }

.emergency-contact { 
    display: flex; 
    justify-content: space-between; 
    align-items: center; 
    padding: 0.6rem 0.85rem; 
    background: linear-gradient(135deg, rgba(239,68,68,0.04), rgba(255,255,255,0.98)); 
    border: 1px solid rgba(239,68,68,0.12); 
    border-radius: 10px; 
    margin-bottom: 0.35rem; 
    transition: all var(--transition); 
}
.emergency-contact:hover { border-color: var(--accent-red); background: linear-gradient(135deg, rgba(239,68,68,0.08), rgba(239,68,68,0.04)); transform: translateX(4px); }
.emergency-contact .number { font-weight: 700; color: var(--accent-red); font-size: 0.9rem; }

.interaction-result { padding: 0.65rem 0.9rem; border-radius: 10px; margin-bottom: 0.35rem; border-left: 4px solid; font-size: 0.85rem; transition: all var(--transition); }
.interaction-result.warning { background: linear-gradient(135deg, rgba(239,68,68,0.06), rgba(239,68,68,0.03)); border-color: var(--accent-red); color: var(--emergency); }
.interaction-result.info { background: linear-gradient(135deg, rgba(79,70,229,0.06), rgba(79,70,229,0.03)); border-color: var(--primary); color: var(--text-main); }
.interaction-result.success { background: linear-gradient(135deg, rgba(16,185,129,0.06), rgba(16,185,129,0.03)); border-color: var(--accent-green); color: var(--success); }

.emergency-hero { border: 2px solid rgba(239,68,68,0.2); background: linear-gradient(135deg, rgba(239,68,68,0.08), rgba(239,68,68,0.04)); }

/* ============================================================ */
/* DETAIL SECTIONS                                                 */
/* ============================================================ */
.detail-section { margin-bottom: 0.9rem; }
.detail-section h4 { color: var(--primary); margin-bottom: 0.2rem; font-size: 0.88rem; }
.detail-section ul { padding-left: 1.2rem; color: var(--text-secondary); line-height: 1.7; font-size: 0.85rem; }
.detail-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 0.8rem; }
.detail-header h2 { font-size: 1.3rem; }
.detail-actions { display: flex; gap: 0.35rem; }

.disclaimer-box { background: rgba(239,68,68,0.04); border: 1px solid rgba(239,68,68,0.12); border-radius: 8px; padding: 0.8rem; }
.disclaimer-box p { color: var(--emergency); font-size: 0.82rem; line-height: 1.5; }

.empty-state { text-align: center; padding: 1.5rem 0; color: var(--text-muted); }
.empty-state i { font-size: 1.8rem; margin-bottom: 0.4rem; display: inline-block; opacity: 0.4; }

.warning-text { color: var(--emergency); }
.success-text { color: var(--success); }

/* ============================================================ */
/* ACCOUNT / PROFILE                                               */
/* ============================================================ */
.profile-avatar-section { 
    display: flex; 
    align-items: center; 
    gap: 1.1rem; 
    margin-bottom: 1.1rem; 
    padding-bottom: 1.1rem; 
    border-bottom: 1px solid var(--border); 
    background: linear-gradient(135deg, rgba(139,92,246,0.04), rgba(124,58,237,0.03)); 
    padding: 1.1rem; 
    border-radius: var(--radius-lg); 
    border: 1px solid rgba(139,92,246,0.08); 
}
.profile-avatar-large { width: 60px; height: 60px; border-radius: 14px; background: linear-gradient(135deg, #4f46e5, #7c3aed); color: white; display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 1.4rem; flex-shrink: 0; object-fit: cover; }
.profile-avatar-large img { width: 100%; height: 100%; border-radius: 14px; object-fit: cover; }

.avatar-upload-area { display: flex; flex-direction: column; gap: 0.4rem; }
.avatar-upload-btn { background: linear-gradient(135deg, #8b5cf6, #7c3aed); color: white; border: none; padding: 0.45rem 0.9rem; border-radius: 8px; font-size: 0.8rem; font-weight: 600; cursor: pointer; display: flex; align-items: center; gap: 0.4rem; transition: all var(--transition); }
.avatar-upload-btn:hover { transform: translateY(-1px); box-shadow: 0 4px 12px rgba(139,92,246,0.3); }
.avatar-remove-btn { background: transparent; color: var(--emergency); border: 1px solid rgba(239,68,68,0.3); padding: 0.35rem 0.7rem; border-radius: 8px; font-size: 0.75rem; font-weight: 500; cursor: pointer; display: flex; align-items: center; gap: 0.3rem; transition: all var(--transition); }
.avatar-remove-btn:hover { background: rgba(239,68,68,0.08); }
.avatar-hint { font-size: 0.7rem; color: var(--text-muted); }

.form-row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
@media (max-width: 600px) { .form-row-2 { grid-template-columns: 1fr; } }

.divider { height: 1px; background: var(--border); margin: 1.1rem 0; }

/* ============================================================ */
/* ACTIVITY LOG                                                    */
/* ============================================================ */
.activity-item { 
    display: flex; 
    align-items: flex-start; 
    gap: 0.65rem; 
    padding: 0.7rem; 
    border-bottom: 1px solid var(--border); 
    border-radius: 8px; 
    transition: all var(--transition); 
}
.activity-item:hover { background: rgba(6,182,212,0.04); }
.activity-item:last-child { border-bottom: none; }
.activity-icon { width: 30px; height: 30px; border-radius: 8px; display: flex; align-items: center; justify-content: center; font-size: 0.72rem; color: white; flex-shrink: 0; }
.activity-icon.chat { background: linear-gradient(135deg, #4f46e5, #7c3aed); }
.activity-icon.auth { background: linear-gradient(135deg, #10b981, #059669); }
.activity-icon.bookmark { background: linear-gradient(135deg, #f59e0b, #d97706); }
.activity-icon.profile { background: linear-gradient(135deg, #8b5cf6, #7c3aed); }
.activity-icon.system { background: linear-gradient(135deg, #64748b, #475569); }
.activity-info { flex: 1; min-width: 0; }
.activity-action { font-weight: 600; font-size: 0.84rem; color: var(--text-main); }
.activity-detail { font-size: 0.76rem; color: var(--text-muted); margin-top: 0.1rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.activity-time { font-size: 0.68rem; color: var(--text-muted); flex-shrink: 0; white-space: nowrap; }

/* ============================================================ */
/* MODAL                                                            */
/* ============================================================ */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    backdrop-filter: blur(6px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 200;
    padding: 1rem;
}
.modal-card {
    background: var(--bg-light);
    border-radius: var(--radius-xl);
    padding: 1.75rem;
    max-width: 400px;
    width: 100%;
    text-align: center;
    box-shadow: var(--shadow-lg);
    animation: fadeIn 0.3s ease;
}
.modal-icon { width: 52px; height: 52px; border-radius: 50%; display: flex; align-items: center; justify-content: center; margin: 0 auto 0.85rem; font-size: 1.4rem; }
.modal-icon.danger { background: rgba(239,68,68,0.1); color: var(--emergency); }
.modal-card h3 { font-size: 1.1rem; margin-bottom: 0.4rem; }
.modal-card p { color: var(--text-secondary); font-size: 0.85rem; line-height: 1.5; margin-bottom: 1.1rem; }
.modal-actions { display: flex; gap: 0.5rem; justify-content: center; }

/* ============================================================ */
/* RESPONSIVE — DESKTOP & MOBILE                                     */
/* ============================================================ */

/* Large desktop */
@media (min-width: 1400px) {
    .main-content { padding: 72px 2.5rem 1.5rem; }
    .grid-5 { gap: 1rem; }
    .stat-card { padding: 1.2rem; }
    .stat-number { font-size: 1.5rem; }
}

/* Medium desktop */
@media (max-width: 1200px) {
    .grid-5 { grid-template-columns: repeat(4, 1fr); }
    .topnav-link span { display: none; }
    .topnav-link { padding: 0.4rem 0.5rem; }
    .topnav-link i { font-size: 0.9rem; }
}

@media (max-width: 1100px) {
    .grid-4 { grid-template-columns: repeat(3, 1fr); }
}

/* Tablet landscape */
@media (max-width: 1024px) {
    .grid-2 { grid-template-columns: 1fr 1fr; }
    .grid-3 { grid-template-columns: repeat(3, 1fr); }
}

/* Tablet portrait */
@media (max-width: 980px) {
    .grid-3 { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 860px) {
    .grid-5 { grid-template-columns: repeat(3, 1fr); }
    .grid-4 { grid-template-columns: repeat(2, 1fr); }
    .filter-btn { font-size: 0.7rem; padding: 0.28rem 0.55rem; }
}

/* Mobile — top navbar collapses, hamburger + dropdown */
@media (max-width: 768px) {
    .topnav-links { display: none; }
    .topnav-user { display: none; }
    .topnav-logout-btn { display: none; }
    .topnav-hamburger { display: flex; }
    .mobile-nav { display: flex; }
    .main-content { padding: 62px 0.85rem 80px 0.85rem; }
    .topbar { display: flex; padding: 0.65rem 0.85rem; }
    .topbar .topbar-actions .btn-primary,
    .topbar .topbar-location { display: none; }
    .topbar .topbar-hamburger { display: flex; }
    .hero-banner { padding: 1rem 0.85rem; margin-bottom: 1rem; }
    .hero-banner h1 { font-size: 1.15rem; }
    .hero-banner p { font-size: 0.8rem; }
    .chat-container { height: calc(100vh - 260px); }
    .chat-bubble { max-width: 88%; font-size: 0.84rem; padding: 0.6rem 0.8rem; }
    .auth-card { padding: 0.65rem; }
    .auth-panel { grid-template-columns: 1fr; }
    .auth-preview { display: none; }
    .grid-5 { grid-template-columns: repeat(2, 1fr); gap: 0.55rem; }
    .grid-4 { grid-template-columns: repeat(2, 1fr); gap: 0.55rem; }
    .grid-3 { grid-template-columns: 1fr; gap: 0.55rem; }
    .grid-2 { grid-template-columns: 1fr; gap: 0.55rem; }
    .glass-card { padding: 0.95rem; margin-bottom: 0.7rem; border-radius: 12px; }
    .glass-card::before { width: 3px; }
    .stat-card { padding: 0.75rem; }
    .stat-number { font-size: 1.15rem; }
    .stat-label { font-size: 0.65rem; }
    .stat-icon { width: 34px; height: 34px; font-size: 0.85rem; border-radius: 8px; }
    .quick-action { padding: 0.75rem; gap: 0.6rem; }
    .quick-action-icon { width: 36px; height: 36px; font-size: 0.9rem; }
    .quick-action-content h3 { font-size: 0.8rem; }
    .quick-action-content p { font-size: 0.7rem; }
    .medicine-card { padding: 0.85rem; }
    .medicine-card h4 { font-size: 0.84rem; }
    .location-card { padding: 0.85rem; }
    .search-bar { gap: 0.4rem; }
    .search-bar input { min-width: 0; font-size: 0.84rem; padding: 0.55rem 0.75rem; }
    .btn-primary { padding: 0.55rem 1rem; font-size: 0.8rem; }
    .btn-secondary { padding: 0.45rem 0.8rem; font-size: 0.76rem; }
    .filter-row { gap: 0.3rem; margin-bottom: 0.7rem; }
    .chat-input-area input { font-size: 0.84rem; padding: 0.55rem 0.75rem; }
    .chat-suggestions button { font-size: 0.65rem; padding: 0.25rem 0.55rem; }
    .detail-header h2 { font-size: 1.1rem; }
    .modal-card { padding: 1.25rem; margin: 0.5rem; }
}

/* Small mobile */
@media (max-width: 480px) {
    .grid-5, .grid-4 { grid-template-columns: repeat(2, 1fr); gap: 0.45rem; }
    .hero-banner { padding: 0.85rem 0.7rem; }
    .hero-banner h1 { font-size: 1.05rem; }
    .stat-card { padding: 0.6rem; }
    .stat-number { font-size: 1.05rem; }
    .stat-icon { width: 30px; height: 30px; font-size: 0.8rem; }
    .glass-card { padding: 0.8rem; }
    .main-content { padding: 58px 0.65rem 76px 0.65rem; }
    .chat-container { height: calc(100vh - 240px); }
    .chat-bubble { max-width: 92%; }
    .topnav-logo span { display: none; }
    .topnav-logo { gap: 0.3rem; }
    .topnav-theme-btn { width: 32px; height: 32px; font-size: 0.82rem; }
}

/* Very small mobile */
@media (max-width: 360px) {
    .grid-5, .grid-4, .grid-3, .grid-2 { grid-template-columns: 1fr; }
    .mobile-nav { padding: 0.2rem 0; }
    .mobile-nav-orb { width: 42px; height: 42px; margin-top: -16px; }
}

/* ============================================================ */
/* DARK MODE OVERRIDES                                              */
/* ============================================================ */
[data-theme="dark"] .topnav { background: linear-gradient(135deg, #0a0e1a, #111827); }
[data-theme="dark"] .mobile-dropdown { background: #0a0e1a; }
[data-theme="dark"] .glass-card { background: linear-gradient(135deg, rgba(19,24,37,0.95), rgba(19,24,37,0.88)); border-color: rgba(255,255,255,0.06); }
[data-theme="dark"] .glass-card::before { opacity: 0.3; }
[data-theme="dark"] .glass-card:hover::before { opacity: 1; }
[data-theme="dark"] .stat-card { background: linear-gradient(135deg, rgba(19,24,37,0.95), rgba(19,24,37,0.88)); border-color: rgba(255,255,255,0.06); }
[data-theme="dark"] .quick-action { background: linear-gradient(135deg, rgba(19,24,37,0.95), rgba(19,24,37,0.88)); border-color: rgba(255,255,255,0.06); }
[data-theme="dark"] .quick-action:nth-child(1) { background: linear-gradient(135deg, rgba(79,70,229,0.08), rgba(19,24,37,0.95)); }
[data-theme="dark"] .quick-action:nth-child(2) { background: linear-gradient(135deg, rgba(236,72,153,0.08), rgba(19,24,37,0.95)); }
[data-theme="dark"] .quick-action:nth-child(3) { background: linear-gradient(135deg, rgba(239,68,68,0.08), rgba(19,24,37,0.95)); }
[data-theme="dark"] .topbar { background: linear-gradient(135deg, rgba(79,70,229,0.08), rgba(124,58,237,0.06)); border-color: rgba(79,70,229,0.15); }
[data-theme="dark"] body { background-image: radial-gradient(ellipse 80% 50% at 20% 0%, rgba(79,70,229,0.08) 0%, transparent 60%), radial-gradient(ellipse 60% 40% at 80% 100%, rgba(236,72,153,0.06) 0%, transparent 60%); }

/* ============================================================ */
/* MARKDOWN INSIDE CHAT                                              */
/* ============================================================ */
.chat-bubble.bot strong { font-weight: 700; }
.chat-bubble.bot h2, .chat-bubble.bot h3, .chat-bubble.bot h4 { margin: 0.4rem 0 0.2rem; color: var(--primary); }
.chat-bubble.bot table { border-collapse: collapse; width: 100%; margin: 0.4rem 0; font-size: 0.78rem; }
.chat-bubble.bot th, .chat-bubble.bot td { border: 1px solid var(--border); padding: 0.3rem 0.4rem; text-align: left; }
.chat-bubble.bot th { background: var(--primary-light); font-weight: 600; }
.chat-bubble.bot code { background: var(--primary-light); padding: 0.1rem 0.25rem; border-radius: 3px; font-size: 0.82em; }
.disclaimer { color: var(--text-muted); font-size: 0.78rem; font-style: italic; margin-top: 0.4rem; display: block; }

/* ============================================================ */
/* LANDING PAGE                                                    */
/* ============================================================ */
.landing-page {
    display: block;
    min-height: 100vh;
    background: var(--bg);
}

/* ---- Landing Nav ---- */
.landing-nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    background: rgba(255,255,255,0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border);
    padding: 0 1.5rem;
}
[data-theme="dark"] .landing-nav { background: rgba(10,14,26,0.85); }
.landing-nav-inner {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
    min-width: 0;
    overflow: hidden;
    gap: 0.5rem;
}
.landing-logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.3rem;
    font-weight: 800;
    color: var(--primary);
    flex-shrink: 0;
    min-width: 0;
}
.logo-img { height: 36px; width: auto; flex-shrink: 0; }
.logo-img-lg { height: 44px; }
.logo-img-sm { height: 30px; }
.logo-img-nav { height: 32px; filter: brightness(0) invert(1); }
.landing-nav-links {
    display: flex;
    gap: 2rem;
}
.landing-nav-links a {
    text-decoration: none;
    color: var(--text-secondary);
    font-weight: 500;
    font-size: 0.9rem;
    transition: color var(--transition);
}
.landing-nav-links a:hover { color: var(--primary); }
.landing-nav-right {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-shrink: 1;
    overflow: hidden;
    min-width: 0;
}
.landing-nav-actions { display: flex; gap: 0.75rem; }
.landing-login-btn {
    background: linear-gradient(135deg, #4f46e5, #7c3aed);
    color: #fff;
    border: none;
    border-radius: 10px;
    padding: 0.5rem 1.2rem;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    transition: all 0.2s;
    box-shadow: 0 2px 8px rgba(79,70,229,0.3);
}
.landing-login-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(79,70,229,0.4);
}
.landing-mobile-menu-btn {
    display: none;
    background: var(--primary);
    color: #fff;
    border: none;
    border-radius: 10px;
    padding: 0.55rem 1.1rem;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: background var(--transition), transform var(--transition);
    white-space: nowrap;
}
.landing-mobile-menu-btn:hover { background: var(--primary-hover); transform: translateY(-1px); }

/* ---- Hero Section ---- */
.landing-hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 80px 1.5rem 4rem;
    overflow: visible;
}
.landing-hero-bg {
    position: absolute;
    inset: 0;
    overflow: hidden;
    z-index: 0;
}
.hero-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.35;
    animation: float 20s ease-in-out infinite;
}
.hero-orb-1 {
    width: 500px;
    height: 500px;
    background: linear-gradient(135deg, #6c63ff, #4834d4);
    top: -10%;
    right: -5%;
    animation-delay: 0s;
}
.hero-orb-2 {
    width: 400px;
    height: 400px;
    background: linear-gradient(135deg, #fd79a8, #e84393);
    bottom: -10%;
    left: -5%;
    animation-delay: -7s;
}
.hero-orb-3 {
    width: 300px;
    height: 300px;
    background: linear-gradient(135deg, #00b894, #00a152);
    top: 40%;
    left: 50%;
    animation-delay: -14s;
}
@keyframes float {
    0%, 100% { transform: translate(0, 0) scale(1); }
    33% { transform: translate(30px, -30px) scale(1.05); }
    66% { transform: translate(-20px, 20px) scale(0.95); }
}
.landing-hero-content {
    position: relative;
    z-index: 1;
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: center;
    width: 100%;
}
.landing-hero-text h1 {
    font-size: 3rem;
    font-weight: 800;
    line-height: 1.15;
    color: var(--text-main);
    margin-bottom: 1rem;
}
.gradient-text {
    background: linear-gradient(135deg, #6c63ff, #e84393, #ff4757);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}
.landing-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: var(--primary-light);
    color: var(--primary);
    padding: 0.4rem 1rem;
    border-radius: 50px;
    font-size: 0.82rem;
    font-weight: 600;
    margin-bottom: 1.2rem;
    border: 1px solid var(--primary-glow);
}
.landing-hero-subtitle {
    font-size: 1.1rem;
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 1.5rem;
}
.landing-hero-stats {
    display: flex;
    gap: 1.5rem;
}
.hero-stat {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.85rem;
    color: var(--text-muted);
    font-weight: 500;
}
.hero-stat i {
    color: var(--primary);
    font-size: 1rem;
}

/* ---- Hero Form Card ---- */
.landing-form-card {
    background: var(--card-bg);
    border: var(--glass-border);
    border-radius: var(--radius-xl);
    padding: 2rem;
    box-shadow: var(--shadow-lg);
    backdrop-filter: blur(20px);
}
.landing-form-header {
    text-align: center;
    margin-bottom: 1.5rem;
}
.landing-form-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--primary);
    margin-bottom: 0.3rem;
}
.landing-form-logo .logo-img { height: 44px; }
.landing-form-subtitle {
    color: var(--text-muted);
    font-size: 0.9rem;
}
.landing-form-disclaimer {
    text-align: center;
    color: var(--text-muted);
    font-size: 0.75rem;
    margin-top: 1rem;
    font-style: italic;
}

/* ---- Features Section ---- */
.landing-features {
    padding: 5rem 1.5rem;
    max-width: 1200px;
    margin: 0 auto;
}
.landing-section-header {
    text-align: center;
    margin-bottom: 3rem;
}
.landing-section-header h2 {
    font-size: 2.2rem;
    font-weight: 800;
    color: var(--text-main);
    margin-bottom: 0.5rem;
}
.landing-section-header p {
    color: var(--text-secondary);
    font-size: 1.05rem;
}
.landing-features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}
.landing-feature-card {
    background: var(--card-bg);
    border: var(--glass-border);
    border-radius: var(--radius-lg);
    padding: 2rem;
    box-shadow: var(--shadow-sm);
    transition: transform var(--transition), box-shadow var(--transition);
    position: relative;
    overflow: hidden;
}
.landing-feature-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(108,99,255,0.03), rgba(232,67,147,0.03));
    opacity: 0;
    transition: opacity var(--transition);
}
.landing-feature-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}
.landing-feature-card:hover::before { opacity: 1; }
.feature-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 1.2rem;
    margin-bottom: 1.2rem;
}
.landing-feature-card h3 {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-main);
    margin-bottom: 0.5rem;
}
.landing-feature-card p {
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 1.6;
}

/* ---- About Section ---- */
.landing-about {
    padding: 5rem 1.5rem;
    background: var(--primary-light);
}
.landing-about-inner {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 3rem;
    align-items: center;
}
.landing-about-text h2 {
    font-size: 2rem;
    font-weight: 800;
    color: var(--text-main);
    margin-bottom: 1rem;
}
.landing-about-text p {
    color: var(--text-secondary);
    font-size: 1rem;
    line-height: 1.7;
    margin-bottom: 1.5rem;
}
.landing-about-list {
    list-style: none;
    padding: 0;
}
.landing-about-list li {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.5rem 0;
    color: var(--text-main);
    font-size: 0.95rem;
    font-weight: 500;
}
.landing-about-list li i {
    color: var(--success);
    font-size: 0.9rem;
}
.about-stat-card {
    display: flex;
    align-items: center;
    gap: 1rem;
    background: var(--card-bg);
    border: var(--glass-border);
    border-radius: var(--radius);
    padding: 1.2rem 1.5rem;
    margin-bottom: 1rem;
    box-shadow: var(--shadow-sm);
}
.about-stat-card i { font-size: 1.5rem; flex-shrink: 0; }
.about-stat-card strong { display: block; color: var(--text-main); font-size: 0.95rem; }
.about-stat-card p { color: var(--text-muted); font-size: 0.82rem; margin: 0.15rem 0 0; }

/* ---- CTA Section ---- */
.landing-cta {
    text-align: center;
    padding: 5rem 1.5rem;
    max-width: 700px;
    margin: 0 auto;
}
.landing-cta h2 {
    font-size: 2rem;
    font-weight: 800;
    color: var(--text-main);
    margin-bottom: 0.75rem;
}
.landing-cta p {
    color: var(--text-secondary);
    font-size: 1.05rem;
    margin-bottom: 2rem;
}
.landing-cta-btn {
    padding: 0.9rem 2.5rem;
    font-size: 1.05rem;
    border-radius: 50px;
    font-weight: 700;
    box-shadow: 0 4px 20px rgba(79,70,229,0.3);
    transition: transform var(--transition), box-shadow var(--transition);
}
.landing-cta-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(79,70,229,0.4);
}

/* ---- Footer ---- */
.landing-footer {
    background: var(--bg-light);
    border-top: 1px solid var(--border);
    padding: 3rem 1.5rem 1.5rem;
}
.landing-footer-inner {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 1fr;
    gap: 2rem;
    margin-bottom: 2rem;
}
.landing-footer-brand p {
    color: var(--text-muted);
    font-size: 0.85rem;
    margin-top: 0.5rem;
    line-height: 1.6;
}
.landing-footer-links h4 {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--text-main);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.75rem;
}
.landing-footer-links a {
    display: block;
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.85rem;
    padding: 0.3rem 0;
    transition: color var(--transition);
}
.landing-footer-links a:hover { color: var(--primary); }
.landing-footer-bottom {
    text-align: center;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border);
    max-width: 1200px;
    margin: 0 auto;
}
.landing-footer-bottom p {
    color: var(--text-muted);
    font-size: 0.78rem;
}

/* ---- Landing Responsive ---- */
@media (max-width: 1024px) {
    .landing-hero-content { grid-template-columns: 1fr; text-align: center; }
    .landing-hero-text h1 { font-size: 2.4rem; }
    .landing-hero-stats { justify-content: center; }
    .landing-hero-form { max-width: 440px; margin: 0 auto; }
    .landing-features-grid { grid-template-columns: repeat(2, 1fr); }
    .landing-about-inner { grid-template-columns: 1fr; }
    .landing-footer-inner { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 768px) {
    .landing-nav { padding: 0 1rem; }
    .landing-nav-inner { height: 56px; }
    .landing-nav-links { display: none; }
    .landing-nav-actions { display: none; }
    .landing-nav-right { gap: 0.4rem; }
    .landing-nav-right .theme-toggle-btn { width: 36px; height: 36px; padding: 0; display: grid; place-items: center; border-radius: 10px; flex-shrink: 0; }
    .landing-nav-right .theme-toggle-btn i { font-size: 1rem; }
    .landing-logo { font-size: 1.15rem; gap: 0.35rem; flex-shrink: 0; }
    .landing-logo .logo-img { height: 30px; }
    .landing-hero { padding: 70px 1rem 2rem; min-height: auto; }
    .landing-hero-text h1 { font-size: 1.6rem; }
    .landing-hero-subtitle { font-size: 0.88rem; }
    .landing-hero-stats { flex-direction: row; justify-content: center; gap: 0.8rem; }
    .landing-hero-stats span { font-size: 0.75rem; }
    .landing-features { padding: 2rem 1rem; }
    .landing-features-grid { grid-template-columns: 1fr; }
    .landing-section-header h2 { font-size: 1.4rem; }
    .landing-about { padding: 2rem 1rem; }
    .landing-about-text h2 { font-size: 1.3rem; }
    .landing-footer-inner { grid-template-columns: 1fr; gap: 1.5rem; }
    .landing-cta { padding: 2rem 1rem; }
    .landing-cta h2 { font-size: 1.3rem; }
}
@media (max-width: 480px) {
    .landing-nav { padding: 0 0.75rem; }
    .landing-nav-inner { height: 52px; }
    .landing-logo { font-size: 1.05rem; gap: 0.3rem; }
    .landing-logo .logo-img { height: 26px; }
    .landing-nav-links { display: none; }
    .landing-nav-actions { display: none; }
    .landing-nav-right { gap: 0.35rem; }
    .landing-nav-right .theme-toggle-btn { width: 34px; height: 34px; border-radius: 8px; }
    .landing-hero-text { display: none; }
    .landing-hero { padding: 60px 0.75rem 1.5rem; }
    .landing-form-card { padding: 1.5rem; }
    .landing-features { padding: 1.5rem 0.75rem; }
    .landing-features-grid { gap: 0.75rem; }
    .landing-about { padding: 1.5rem 0.75rem; }
    .landing-about-text h2 { font-size: 1.2rem; }
    .landing-cta { padding: 1.5rem 0.75rem; }
    .landing-cta h2 { font-size: 1.2rem; }
    .landing-footer { padding: 1.5rem 0.75rem 1rem; }
}
@media (max-width: 360px) {
    .landing-logo span { font-size: 0.95rem; }
    .landing-nav-links { display: none; }
    .landing-nav-actions { display: none; }
    .landing-nav-right .theme-toggle-btn { width: 32px; height: 32px; }
    .landing-hero-text { display: none; }
    .landing-hero { padding-top: 55px; padding-bottom: 1rem; }
    .landing-form-card { padding: 1.25rem; }
}

/* ============================================================ */
/* LANGUAGE SWITCHER                                             */
/* ============================================================ */
.lang-switcher {
    position: relative;
    display: inline-block;
}
.lang-switcher-btn {
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.15);
    color: rgba(255,255,255,0.8);
    padding: 0.35rem 0.6rem;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.78rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.35rem;
    transition: all var(--transition);
    white-space: nowrap;
}
.lang-switcher-btn:hover { background: rgba(255,255,255,0.2); color: #fff; }
.lang-switcher-btn i { font-size: 0.7rem; transition: transform 0.2s; }
.lang-switcher.open .lang-switcher-btn i.fa-chevron-down { transform: rotate(180deg); }
.lang-dropdown {
    display: none;
    position: absolute;
    top: calc(100% + 6px);
    right: 0;
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 0.4rem;
    min-width: 160px;
    max-height: 320px;
    overflow-y: auto;
    z-index: 1000;
    box-shadow: var(--shadow-lg);
    backdrop-filter: blur(20px);
}
.lang-switcher.open .lang-dropdown { display: block; }
.lang-option {
    display: block;
    width: 100%;
    text-align: left;
    padding: 0.5rem 0.75rem;
    border: none;
    background: transparent;
    color: var(--text-main);
    font-size: 0.82rem;
    border-radius: 6px;
    cursor: pointer;
    transition: background 0.15s;
    font-weight: 400;
}
.lang-option:hover { background: var(--primary-light); }
.lang-option.active {
    background: var(--primary);
    color: #fff;
    font-weight: 600;
}
.landing-lang-btn {
    background: rgba(0,0,0,0.04);
    border: 1px solid rgba(0,0,0,0.08);
    color: var(--text-secondary);
    padding: 0.35rem 0.6rem;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.78rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.35rem;
    transition: all var(--transition);
    white-space: nowrap;
}
.landing-lang-btn:hover { background: rgba(0,0,0,0.08); color: var(--text-main); }
.landing-lang-btn i { font-size: 0.7rem; transition: transform 0.2s; }
.lang-switcher.open .landing-lang-btn i.fa-chevron-down { transform: rotate(180deg); }
[data-theme="dark"] .lang-switcher-btn,
[data-theme="dark"] .landing-lang-btn {
    background: rgba(255,255,255,0.08);
    border-color: rgba(255,255,255,0.12);
    color: rgba(255,255,255,0.7);
}
[data-theme="dark"] .lang-switcher-btn:hover,
[data-theme="dark"] .landing-lang-btn:hover {
    background: rgba(255,255,255,0.15);
    color: #fff;
}

/* ============================================================ */
/* LANDING MOBILE SIDEBAR                                        */
/* ============================================================ */
.landing-hamburger {
    display: none;
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 1.1rem;
    cursor: pointer;
    padding: 0.4rem;
    border-radius: 8px;
    transition: all 0.2s;
}
.landing-hamburger:hover { color: var(--text-main); background: var(--primary-light); }
.landing-sidebar-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    z-index: 2000;
    backdrop-filter: blur(4px);
}
.landing-sidebar-overlay.active { display: block; }
.landing-sidebar {
    position: fixed;
    top: 0;
    right: -280px;
    width: 280px;
    height: 100vh;
    background: var(--card-bg);
    border-left: 1px solid var(--border);
    z-index: 2001;
    display: flex;
    flex-direction: column;
    transition: right 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: var(--shadow-lg);
}
.landing-sidebar.active { right: 0; }
.landing-sidebar-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--border);
}
.landing-sidebar-header .landing-logo { font-size: 1.1rem; }
.landing-sidebar-close {
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 1.1rem;
    cursor: pointer;
    padding: 0.4rem;
    border-radius: 8px;
    transition: all 0.2s;
}
.landing-sidebar-close:hover { color: var(--text-main); background: var(--primary-light); }
.landing-sidebar-links {
    flex: 1;
    padding: 0.75rem 0;
    overflow-y: auto;
}
.landing-sidebar-links a {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.85rem 1.25rem;
    color: var(--text-main);
    text-decoration: none;
    font-size: 0.92rem;
    font-weight: 500;
    transition: background 0.15s;
}
.landing-sidebar-links a:hover { background: var(--primary-light); color: var(--primary); }
.landing-sidebar-divider {
    height: 1px;
    background: var(--border);
    margin: 0.5rem 1.25rem;
}
.landing-sidebar-login {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    width: 100%;
    padding: 0.85rem 1.25rem;
    background: none;
    border: none;
    color: var(--primary);
    font-size: 0.92rem;
    font-weight: 600;
    cursor: pointer;
    text-align: left;
    transition: background 0.15s;
}
.landing-sidebar-login:hover { background: var(--primary-light); }
.landing-sidebar-footer {
    padding: 0.75rem 1.25rem;
    border-top: 1px solid var(--border);
}
.landing-sidebar-theme {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    width: 100%;
    padding: 0.7rem 0;
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 0.88rem;
    cursor: pointer;
    transition: color 0.15s;
}
.landing-sidebar-theme:hover { color: var(--text-main); }
@media (max-width: 768px) {
    .landing-hamburger { display: flex; align-items: center; justify-content: center; }
}
[data-theme="dark"] .landing-sidebar { background: var(--bg-light); }
