/* 
 * The Canada Guardian
 * Sovereign & Clean Design System
 */

:root {
    /* Premium Cinematic Palette */
    --color-bg: #050816;
    --color-surface: #09111F;
    --color-navy-light: #0B1020;
    
    --color-text: #F8F9FA;
    --color-text-muted: #A0ABC0;
    --color-border: rgba(255, 255, 255, 0.08);

    --color-safety-green: #39D98A;
    --color-transit-blue: #5DA9FF;
    --color-warning-amber: #FFB547;
    --color-danger-coral: #FF6B6B;
    --color-premium-gold: #F4C542;
    --color-accent: var(--color-premium-gold);
    --color-accent-hover: #FFDF80; /* High-visibility hover state for Dark Theme */

    /* Typography Hierarchy */
    --font-heading: 'Outfit', 'Space Grotesk', sans-serif;
    --font-body: 'Inter', 'Plus Jakarta Sans', sans-serif;

    /* Spacing & Layout */
    --spacing-xs: 0.25rem;
    --spacing-sm: 0.5rem;
    --spacing-md: 0.75rem;
    --spacing-lg: 1.5rem;
    --spacing-xl: 3rem;
    --container-max: 1200px;

    /* Glassmorphism System */
    --glass-bg: rgba(255, 255, 255, 0.04);
    --glass-border: rgba(255, 255, 255, 0.08);
    --glass-blur: blur(18px);
    --glass-radius: 24px;
    --glass-shadow: 0 20px 50px rgba(0, 0, 0, 0.3);
    
    /* Transitions */
    --transition-fast: 0.2s ease;
    --transition-premium: 0.4s cubic-bezier(0.2, 0.8, 0.2, 1);
}

@keyframes goldShimmer {
    0% { color: #F4C542; text-shadow: 0 0 0px rgba(244, 197, 66, 0); }
    50% { color: #FFD700; text-shadow: 0 0 12px rgba(244, 197, 66, 0.4); }
    100% { color: #F4C542; text-shadow: 0 0 0px rgba(244, 197, 66, 0); }
}

.gold-shimmer {
    animation: goldShimmer 3s infinite ease-in-out !important;
}

/* Premium Card Component */
.premium-glass-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    backdrop-filter: var(--glass-blur);
    border-radius: var(--glass-radius);
    padding: 2.5rem;
    box-shadow: var(--glass-shadow);
    transition: transform var(--transition-premium), 
                box-shadow var(--transition-premium),
                background var(--transition-premium);
}

.premium-glass-card:hover {
    transform: translateY(-8px);
    background: rgba(255, 255, 255, 0.06);
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.5);
}

/* First Money Wins Button Style */
.btn-first-money {
    color: #ffffff !important;
}
.btn-first-money:hover {
    transform: translateY(-4px) scale(1.02);
    border-color: #ffffff !important;
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.25) 0%, rgba(10,17,40,0.85) 100%) !important;
    box-shadow: 0 12px 30px rgba(255, 215, 0, 0.3) !important;
    color: #ffffff !important;
}
.btn-first-money:active {
    transform: translateY(-1px) scale(0.98);
}

/* Unified Tactical Command Console Styling */
.command-console-wrapper {
    background: rgba(10, 15, 30, 0.8);
    backdrop-filter: blur(25px);
}

.segmented-province-control {
    display: flex;
    gap: 0.2rem;
}

.seg-btn {
    background: transparent;
    border: none;
    color: rgba(255,255,255,0.75);
    padding: 0.5rem 1.25rem;
    border-radius: 100px;
    font-size: 0.75rem;
    font-weight: 800;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.seg-btn.active {
    background: var(--color-premium-gold);
    color: #000;
    box-shadow: 0 4px 15px rgba(244, 197, 66, 0.3);
}

.seg-btn:hover:not(.active) {
    color: #fff;
    background: rgba(255,255,255,0.05);
}

.seg-btn:active {
    opacity: 1 !important;
    transform: scale(0.95);
}

#area-search {
    border: 1px solid rgba(255,255,255,0.05) !important;
}

#area-search:focus {
    border-color: var(--color-premium-gold) !important;
    background: rgba(255,255,255,0.05) !important;
    box-shadow: 0 0 30px rgba(244, 197, 66, 0.1);
}

.live-status-pill {
    background: rgba(57, 217, 138, 0.1);
    color: var(--color-safety-green);
    font-size: 0.6rem;
    font-weight: 900;
    letter-spacing: 1px;
    padding: 0.4rem 0.8rem;
    border-radius: 4px;
    border: 1px solid rgba(57, 217, 138, 0.2);
}

.btn-console-action {
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.08);
    color: rgba(255,255,255,0.8);
    padding: 1.25rem;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 800;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.btn-console-action:hover {
    background: rgba(255,255,255,0.08);
    color: #fff;
    border-color: rgba(255,255,255,0.2);
    transform: translateY(-2px);
}

@media (max-width: 992px) {
    .console-body {
        grid-template-columns: 1fr !important;
    }
    .console-panel.safety-module {
        border-right: none !important;
        border-bottom: 1px solid rgba(255,255,255,0.05);
    }
}

/* Clean Light Theme Override */
html[data-theme="light"] {
    --color-bg: #F8F9FA; /* Soft White */
    --color-surface: #FFFFFF;
    --color-text: #1A202C;
    --color-text-muted: #4A5568;
    --color-accent: #0033A0; /* Classic Blue */
    --color-accent-hover: #002277;
    --color-border: rgba(0, 0, 0, 0.1);
}

/* Reset & Base */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

html, body {
    overflow-x: clip !important;
    width: 100%;
    max-width: 100vw;
}

body {
    font-family: var(--font-body);
    background-color: var(--color-bg);
    color: var(--color-text);
    line-height: 1.6;
    transition: background-color var(--transition-smooth), color var(--transition-smooth);
    position: relative;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1.2;
    color: var(--color-text);
}

a {
    color: var(--color-accent);
    text-decoration: none;
    transition: color var(--transition-fast);
}

ul {
    list-style: none;
}

.container {
    width: 100%;
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 var(--spacing-md);
}

@media (max-width: 768px) {
    .container {
        padding: 0 var(--spacing-sm);
    }
}

/* Global Header */
.global-header {
    background-color: var(--color-surface);
    border-bottom: 1px solid var(--color-border);
    padding: var(--spacing-md) 0;
    position: sticky;
    top: 0;
    z-index: 100;
    backdrop-filter: blur(10px);
    background-color: color-mix(in srgb, var(--color-surface) 90%, transparent);
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.brand-logo {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--color-text);
    letter-spacing: -0.5px;
}

.brand-accent {
    color: var(--color-accent);
    font-weight: 500;
}

/* Navigation */
/* Guardian Safety Navigator Layout */
.console-layout {
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 3rem;
}

@media (max-width: 992px) {
    .console-layout {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
}

.main-nav {
    display: flex;
    align-items: center;
}

.nav-links {
    display: flex;
    gap: var(--spacing-md);
}

.nav-links a {
    color: var(--color-text);
    font-weight: 500;
    font-size: 0.95rem;
    position: relative;
}

.nav-links a:hover, .nav-links a.active {
    color: var(--color-accent);
}

@media (max-width: 992px) {
    .mobile-menu-toggle {
        display: flex;
    }

    .nav-links {
        position: fixed;
        top: 70px;
        left: 0;
        width: 100%;
        height: auto;
        max-height: 80vh;
        background-color: var(--color-surface);
        flex-direction: column;
        padding: 2rem;
        gap: 1.5rem;
        border-bottom: 2px solid var(--color-accent);
        transform: translateY(-200%);
        transition: transform var(--transition-premium);
        z-index: 999;
        overflow-y: auto;
        box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    }

    .nav-links.active {
        transform: translateY(0);
    }
    
    .header-actions {
        display: none; /* Hide actions in main header on mobile */
    }
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--color-accent);
    transition: width var(--transition-fast);
}

.nav-links a:hover::after, .nav-links a.active::after {
    width: 100%;
}

/* Header Actions & Theme Toggle */
.header-actions {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
}

.language-select {
    background-color: transparent;
    color: var(--color-text);
    border: 1px solid var(--color-border);
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-family: var(--font-body);
    font-size: 0.85rem;
    cursor: pointer;
    outline: none;
}

.language-select option {
    background-color: var(--color-surface);
    color: var(--color-text);
}

.theme-btn {
    background: transparent;
    border: none;
    color: var(--color-text);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem;
    border-radius: 50%;
    transition: background-color var(--transition-fast), color var(--transition-fast);
}

.theme-btn:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

html[data-theme="light"] .theme-btn:hover {
    background-color: rgba(0, 0, 0, 0.05);
}

.theme-btn .moon-icon { display: none; }
.theme-btn .sun-icon { display: block; }

html[data-theme="light"] .theme-btn .moon-icon { display: block; }
html[data-theme="light"] .theme-btn .sun-icon { display: none; }

/* Buttons */
.btn {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    font-family: var(--font-heading);
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition-fast);
    border: none;
    font-size: 1rem;
}

.btn:active {
    opacity: 1 !important;
    transform: scale(0.98);
}

.btn-primary {
    background-color: var(--color-accent);
    color: #000; /* Ensure high contrast on gold */
}

html[data-theme="light"] .btn-primary {
    background-color: var(--color-accent);
    color: #FFF; /* High contrast on classic blue */
}

.btn-primary:hover {
    background-color: var(--color-accent-hover) !important;
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(244, 197, 66, 0.4);
    opacity: 1 !important;
}

.btn-primary:active {
    transform: translateY(0);
    background-color: var(--color-accent) !important;
    opacity: 1 !important;
    box-shadow: none;
}

.btn-secondary {
    background-color: transparent;
    color: var(--color-text);
    border: 2px solid var(--color-border);
}

.btn-secondary:hover {
    border-color: var(--color-accent);
    color: var(--color-accent);
}

.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.8rem;
}

.full-width {
    width: 100%;
}

/* Hero Section */
.hero-section {
    padding: var(--spacing-xl) 0;
    min-height: 80vh;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
}

/* LCP hero image — positioned absolute behind all content */
.hero-section .hero-bg-img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    z-index: 0;
}

/* Gradient overlay (dark theme) */
.hero-section::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(rgba(10, 17, 40, 0.6), rgba(10, 17, 40, 0.35));
    z-index: 1;
    pointer-events: none;
}

/* Bottom fade-to-background */
.hero-section::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 220px;
    background: linear-gradient(to top, var(--color-bg) 0%, transparent 100%);
    pointer-events: none;
    z-index: 2;
}

.hero-section > * {
    position: relative;
    z-index: 3;
}

html[data-theme="light"] .hero-section::before {
    background: linear-gradient(rgba(248, 249, 250, 0.6), rgba(248, 249, 250, 0.35));
}

html[data-theme="light"] .hero-section::after {
    background: linear-gradient(to top, var(--color-bg) 0%, transparent 100%);
}

.hero-content {
    max-width: 800px;
}

.hero-title {
    font-size: clamp(2rem, 4.5vw, 3.8rem);
    margin-bottom: var(--spacing-md);
    letter-spacing: -1px;
}

.hero-subtitle {
    font-size: clamp(1.1rem, 2vw, 1.25rem);
    color: var(--color-text-muted);
    margin-bottom: var(--spacing-lg);
    max-width: 600px;
}

.hero-actions {
    display: flex;
    gap: var(--spacing-md);
}

/* Mobile Menu Toggle */
.mobile-menu-toggle {
    display: none;
    background: transparent;
    border: none;
    cursor: pointer;
    flex-direction: column;
    gap: 6px;
    padding: 0.5rem;
    transition: transform 0.3s ease;
}

.mobile-menu-toggle:hover {
    transform: scale(1.1);
}

.hamburger-line {
    width: 28px;
    height: 2px;
    background-color: var(--color-premium-gold);
    transition: all var(--transition-fast);
    border-radius: 2px;
}


/* Hero Layout Updates */
.hero-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--spacing-xl);
    align-items: center;
}

/* Quiz Card */
.hero-quiz-container {
    perspective: 1000px;
}

.quiz-card {
    background-color: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: 16px;
    padding: var(--spacing-lg);
    box-shadow: 0 20px 40px rgba(0,0,0,0.2);
    transition: transform var(--transition-smooth);
    position: relative;
    overflow: hidden;
}

html[data-theme="light"] .quiz-card {
    box-shadow: 0 20px 40px rgba(0,0,0,0.05);
}

.quiz-header {
    margin-bottom: var(--spacing-md);
}

.quiz-progress-bar {
    width: 100%;
    height: 4px;
    background-color: var(--color-border);
    border-radius: 2px;
    overflow: hidden;
    margin-bottom: var(--spacing-sm);
}

.quiz-progress-fill {
    height: 100%;
    background-color: var(--color-accent);
    transition: width 0.5s ease-in-out;
}

.quiz-status {
    font-size: 0.8rem;
    color: var(--color-text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    text-align: center !important;
    width: 100% !important;
    display: block !important;
}

.quiz-body {
    min-height: 180px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    opacity: 1;
    transition: opacity var(--transition-fast);
}

.quiz-body.fade-out {
    opacity: 0;
}

.quiz-question {
    font-size: 1.5rem;
    margin-bottom: var(--spacing-sm);
    color: var(--color-text);
}

.quiz-context {
    color: var(--color-text-muted);
    margin-bottom: var(--spacing-lg);
    font-size: 0.95rem;
}

.quiz-options {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
}

.quiz-option-btn {
    background-color: transparent;
    border: 1px solid var(--color-border);
    color: var(--color-text);
    padding: 1rem;
    border-radius: 8px;
    text-align: left;
    cursor: pointer;
    transition: all var(--transition-fast);
    font-family: var(--font-body);
    font-size: 1rem;
}

.quiz-option-btn:hover {
    border-color: var(--color-accent);
    background-color: rgba(255, 215, 0, 0.05);
}

html[data-theme="light"] .quiz-option-btn:hover {
    background-color: rgba(0, 51, 160, 0.05);
}

/* Resource Center */
.resource-section {
    padding: var(--spacing-xl) 0;
    background-color: var(--color-bg);
}

.section-header {
    text-align: center;
    margin-bottom: var(--spacing-lg);
}

.section-title {
    font-size: 2.5rem;
    margin-bottom: var(--spacing-sm);
}

.section-subtitle {
    color: var(--color-text-muted);
    font-size: 1.1rem;
    max-width: 600px;
    margin: 0 auto;
}

.resource-grid {
    display: flex;
    flex-wrap: wrap;
    gap: var(--spacing-lg);
    margin-top: var(--spacing-lg);
}

.resource-card {
    flex: 1;
    min-width: 300px;
    background-color: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: 12px;
    padding: var(--spacing-lg);
    display: flex;
    flex-direction: column;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    min-height: auto; /* Removed fixed height */
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--spacing-sm);
}

.card-header h3 {
    font-size: 1.25rem;
}

.badge {
    background-color: rgba(255, 215, 0, 0.1);
    color: var(--color-accent);
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
}

.badge.badge-live {
    background-color: #EF4444; /* Vivid Red */
    color: white;
    font-weight: 800;
}

/* Transit Map Overlay Refinement */
.map-view {
    position: relative;
    overflow: hidden;
    border-radius: 12px;
}

.map-actions-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none; /* Let clicks pass through to map if needed, except buttons */
}

.map-link-top-left {
    position: absolute;
    top: 12px;
    left: 12px;
    background: rgba(255, 255, 255, 0.9);
    color: #1A365D;
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 700;
    text-decoration: none;
    pointer-events: auto;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.map-btn-bottom-right {
    position: absolute;
    bottom: 12px;
    right: 12px;
    background: #FFD700; /* Regal Gold */
    color: #000;
    padding: 10px 18px;
    border-radius: 50px;
    font-size: 0.8rem;
    font-weight: 800;
    text-decoration: none;
    pointer-events: auto;
    box-shadow: 0 4px 10px rgba(0,0,0,0.3);
    transition: transform 0.2s ease;
}

.map-btn-bottom-right:hover {
    transform: scale(1.05);
}

.badge.warning {
    background-color: rgba(255, 0, 0, 0.1);
    color: #ff4d4d;
}

.card-desc {
    color: var(--color-text-muted);
    font-size: 0.9rem;
    margin-bottom: var(--spacing-lg);
}

/* Calculator Form */
.calc-form {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
    flex: 1;
}

.calc-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 0.5rem;
    border-bottom: 1px dashed var(--color-border);
}

.calc-item label {
    flex: 1;
    font-weight: 500;
}

.qty-control {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-right: 1rem;
}

.qty-btn {
    background-color: var(--color-border);
    border: none;
    color: var(--color-text);
    width: 24px;
    height: 24px;
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
}

.qty-btn:hover {
    background-color: var(--color-accent);
    color: #000;
}

.qty-val {
    width: 20px;
    text-align: center;
    font-weight: 600;
}

.item-price {
    font-weight: 600;
    color: var(--color-text-muted);
    width: 50px;
    text-align: right;
}

.calc-total {
    margin-top: auto;
    padding-top: var(--spacing-md);
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--color-accent);
}

/* Legacy Hub Styles Removed in favor of Premium Refinement */

/* Chronicles Section */
.chronicles-section {
    padding: var(--spacing-xl) 0;
    background-color: var(--color-surface);
}

.chronicles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: var(--spacing-lg);
}

.chronicle-card {
    background-color: var(--color-bg);
    border: 1px solid var(--color-border);
    border-radius: 12px;
    overflow: hidden;
    transition: transform var(--transition-fast);
}

.chronicle-card:hover {
    transform: translateY(-5px);
}

.chronicle-img {
    height: 220px;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    transition: transform var(--transition-slow);
}

.chronicle-card:hover .chronicle-img {
    transform: scale(1.05);
}

.chronicle-content {
    padding: var(--spacing-md);
}

.chronicle-content h4 {
    margin: 0.5rem 0;
    font-size: 1.2rem;
}

.chronicle-content h4 a {
    color: var(--color-text);
}

.chronicle-content h4 a:hover {
    color: var(--color-accent);
}

.chronicle-content p {
    color: var(--color-text-muted);
    font-size: 0.9rem;
}

/* Parent's Portal */
.parents-portal-section {
    padding: var(--spacing-xl) 0;
    background-color: var(--color-bg);
    border-top: 1px solid var(--color-border);
}

.portal-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--spacing-xl);
    align-items: center;
}

.portal-features {
    margin-bottom: var(--spacing-lg);
}

.portal-features li {
    margin-bottom: 0.75rem;
    padding-left: 1.5rem;
    position: relative;
    color: var(--color-text-muted);
}

.portal-features li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--color-accent);
    font-weight: bold;
}

.portal-card {
    background-color: var(--color-surface);
    padding: var(--spacing-xl);
    border-radius: 16px;
    text-align: center;
    border: 1px solid var(--color-accent);
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
}

.heart-icon {
    color: var(--color-accent);
    margin-bottom: var(--spacing-md);
}

/* Roommate Contract Checklist */
.contract-checklist {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    background-color: rgba(255, 255, 255, 0.03);
    padding: var(--spacing-md);
    border-radius: 8px;
    border: 1px solid var(--color-border);
}

.check-item {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    cursor: pointer;
    font-size: 0.9rem;
    color: var(--color-text-muted);
    transition: color var(--transition-fast);
}

.check-item:hover {
    color: var(--color-text);
}

.check-item input[type="checkbox"] {
    margin-top: 0.2rem;
    accent-color: var(--color-accent);
}

/* Parent's Portal Styling */
.portal-letter {
    font-style: italic;
    line-height: 1.8;
    color: var(--color-text);
    margin-bottom: var(--spacing-lg);
    padding: var(--spacing-md);
    border-left: 3px solid var(--color-accent);
    background-color: rgba(255, 215, 0, 0.05);
}

.checklist-title {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    margin-bottom: var(--spacing-sm);
    color: var(--color-accent);
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: var(--spacing-lg);
    padding: var(--spacing-xl) 0;
    align-items: stretch;
}

.portal-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--spacing-xl);
    align-items: flex-start;
}

.info-card {
    display: flex;
    flex-direction: column;
    height: 100%;
}

/* Survival Toolkit Tiles */
.survival-toolkit {
    margin-bottom: var(--spacing-xl);
}

.toolkit-title {
    font-size: 1.5rem;
    margin-bottom: var(--spacing-md);
    color: var(--color-accent);
}

.toolkit-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: var(--spacing-md);
}

.toolkit-tile {
    height: 200px;
    border-radius: 12px;
    overflow: hidden;
    position: relative;
    background-size: cover;
    background-position: center;
    border: 1px solid var(--color-border);
    cursor: pointer;
    transition: transform var(--transition-smooth);
}

.toolkit-tile:hover {
    transform: translateY(-5px);
}

.tile-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(10, 17, 40, 0.9), rgba(10, 17, 40, 0.4));
    padding: var(--spacing-md);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    transition: background var(--transition-fast);
}

.toolkit-tile:hover .tile-overlay {
    background: linear-gradient(to top, rgba(10, 17, 40, 0.95), rgba(10, 17, 40, 0.8));
}

.toolkit-tile h4 {
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
    color: var(--color-accent);
}

.guardian-secret {
    font-size: 0.8rem;
    color: var(--color-text-muted);
    opacity: 0.7;
    transition: all var(--transition-smooth);
    margin-top: 0.25rem;
}

.toolkit-tile:hover .guardian-secret {
    opacity: 1;
    color: var(--color-text);
}

/* Parent's Dashboard */
.portal-dashboard {
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: var(--spacing-lg);
}

.portal-main-card {
    background-color: var(--color-surface);
    padding: var(--spacing-xl);
    border-radius: 16px;
    border: 1px solid var(--color-border);
}

.portal-stats {
    display: flex;
    gap: var(--spacing-xl);
    margin-top: var(--spacing-lg);
}

.stat-item {
    display: flex;
    flex-direction: column;
}

.stat-value {
    font-size: 2rem;
    font-weight: 800;
    color: var(--color-accent);
    font-family: var(--font-heading);
}

.stat-label {
    font-size: 0.8rem;
    color: var(--color-text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.portal-downloads {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
}

.download-card {
    background-color: var(--color-surface);
    padding: var(--spacing-md);
    border-radius: 12px;
    border: 1px solid var(--color-border);
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    transition: border-color var(--transition-fast);
}

.download-card:hover {
    border-color: var(--color-accent);
}

.card-icon {
    font-size: 1.5rem;
    background-color: rgba(255, 215, 0, 0.1);
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
}

.card-info h3 {
    font-size: 1rem;
    margin-bottom: 0.25rem;
}

.card-info p {
    font-size: 0.8rem;
    color: var(--color-text-muted);
}

.download-card .btn {
    margin-left: auto;
}

/* Modal Styling */
.modal {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 99999;
    background-color: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(8px);
    align-items: center;
    justify-content: center;
    pointer-events: auto;
}

.modal.active {
    display: flex !important;
}

.modal-content {
    background-color: var(--color-surface);
    width: 90%;
    max-width: 500px;
    padding: var(--spacing-xl);
    border-radius: 20px;
    border: 1px solid var(--color-accent);
    position: relative;
}

.modal-close {
    position: absolute;
    top: 1rem;
    right: 1.5rem;
    font-size: 2rem;
    cursor: pointer;
    color: var(--color-text-muted);
}

.modal-header h2 {
    color: var(--color-accent);
    margin-bottom: 0.5rem;
}

.modal-header p {
    color: var(--color-text-muted);
    font-size: 0.9rem;
    margin-bottom: var(--spacing-lg);
}

.checklist-items {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-bottom: var(--spacing-xl);
}

/* Guardian Action Dashboard */
.guardian-dashboard {
    padding: var(--spacing-xl) 0;
    background-color: #080E21; /* Rich Sovereign Navy */
    transition: background-color var(--transition-smooth);
}

html[data-theme="light"] .guardian-dashboard {
    background-color: #F0F4F8; /* Soft Light Navy/White */
}

.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: var(--spacing-lg);
    margin-top: var(--spacing-lg);
}

.dashboard-tile {
    height: auto;
    min-height: auto; /* Removed fixed height */
    background-color: var(--color-surface);
    border-radius: 20px;
    border: 1px solid var(--color-border);
    overflow: hidden;
    position: relative;
    transition: transform var(--transition-fast), border-color var(--transition-fast);
    display: flex;
    flex-direction: column;
}

.dashboard-tile:hover {
    border-color: #FFD700 !important;
    box-shadow: 0 0 30px rgba(255, 215, 0, 0.25) !important;
    transform: translateY(-5px);
}

.dashboard-tile:hover .tile-content {
    transform: scale(0.97);
}

.tile-content {
    padding: var(--spacing-lg);
    flex: 1;
    display: flex;
    flex-direction: column;
    transition: transform var(--transition-premium);
}

/* 1. Sovereign Shared Tile System (2026 Core) */
.sovereign-tile-v2 {
    background-color: var(--color-surface) !important;
    position: relative !important;
    overflow: hidden !important;
    border: none !important;
    box-shadow: 0 0 0 2px #FFD700, 
                0 0 25px rgba(255, 215, 0, 0.4), 
                0 15px 35px rgba(0,0,0,0.6) !important;
    cursor: default !important;
    border-radius: 20px !important;
    transition: all var(--transition-premium) !important;
}

.sovereign-tile-v2::before {
    content: '' !important;
    position: absolute !important;
    inset: 0 !important;
    background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg opacity='0.05' stroke='%23FFD700' stroke-width='0.5'%3E%3Cpath d='M30 0l30 30-30 30L0 30z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E") !important;
    opacity: 0.15 !important;
    pointer-events: none !important;
    z-index: 0 !important;
}

.sovereign-tile-v2:hover {
    border-color: #FFD700 !important;
    box-shadow: 0 0 40px rgba(255, 215, 0, 0.4) !important;
    transform: translateY(-8px) !important;
}

.sovereign-tile-v2:hover .tile-content, 
.sovereign-tile-v2:hover .sin-tile-content-v2 {
    transform: scale(0.96) !important;
}

.sin-glass-overlay {
    position: absolute;
    inset: 0;
    backdrop-filter: blur(8px);
    background: rgba(10, 17, 40, 0.4);
    z-index: 1;
}

html[data-theme="light"] .sin-glass-overlay {
    background: rgba(255, 255, 255, 0.05);
}

.sin-tile-content-v2 {
    position: relative;
    z-index: 2;
    padding: var(--spacing-lg);
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    height: 100%;
}

.sin-brand-foil {
    font-family: var(--font-heading);
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-size: 0.75rem;
    margin-bottom: 0.5rem;
    background: linear-gradient(to right, #bf953f, #fcf6ba, #b38728, #fbf5b7, #aa771c);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 2px 2px rgba(0,0,0,0.3));
}

.sin-tile-heading {
    align-self: flex-start;
    font-size: 1.1rem;
    color: var(--color-text);
    margin-bottom: 1.5rem;
}

.sin-asset-wrap {
    width: 100%;
    display: flex;
    justify-content: center;
    margin: 1rem 0 2rem;
}

.sin-asset-embossed {
    max-width: 140px;
    height: auto;
    filter: drop-shadow(2px 2px 2px rgba(255, 255, 255, 0.1)) 
            drop-shadow(-2px -2px 2px rgba(0, 0, 0, 0.5));
    border-radius: 12px;
    transition: transform 0.3s ease;
}

.sin-tile-sovereign:hover .sin-asset-embossed {
    transform: scale(1.05) translateY(-5px);
}

.sin-main-title {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 700;
    color: #F8F9FA;
    margin-bottom: 1rem;
}

html[data-theme="light"] .sin-main-title {
    color: #0A1128;
}

.sin-procedural-badge {
    background: rgba(255, 215, 0, 0.1);
    border: 1px solid rgba(255, 215, 0, 0.3);
    color: var(--color-accent);
    font-size: 0.7rem;
    padding: 0.25rem 0.75rem;
    border-radius: 50px;
    margin-bottom: 1rem;
    font-weight: 700;
}

.sin-day1-hack {
    font-size: 0.8rem;
    color: var(--color-text-muted);
    line-height: 1.4;
    margin-bottom: 1.5rem;
    max-width: 220px;
}

html[data-theme="light"] .sin-day1-hack {
    color: #4A5568;
}

.sin-footer-signature {
    margin-top: auto;
    font-size: 0.65rem;
    opacity: 0.6;
    font-style: italic;
    border-top: 1px solid rgba(255, 215, 0, 0.1);
    padding-top: 0.75rem;
    width: 100%;
}

/* Modal Enhancements for SIN */
.sin-checklist-modal .modal-content {
    background: #0A1128;
    border: 2px solid #D4AF37;
    box-shadow: 0 0 50px rgba(212, 175, 55, 0.2);
}

.sin-doc-item {
    background: rgba(255, 255, 255, 0.03);
    border-left: 3px solid #D4AF37;
    padding: 1rem;
    margin-bottom: 0.75rem;
    border-radius: 0 8px 8px 0;
}

.sin-doc-item strong {
    color: #D4AF37;
    display: block;
    margin-bottom: 0.25rem;
}

.sin-doc-item p {
    font-size: 0.85rem;
    color: var(--color-text-muted);
    margin: 0;
}

/* 2. Banking Toggle */
.banking-toggle-container {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    margin: 1rem 0;
}

.toggle-label {
    font-weight: 700;
    opacity: 0.7;
    transition: all 0.3s;
    color: var(--color-text-muted);
}

.toggle-label.active {
    opacity: 1;
    color: var(--color-accent);
}

/* Switch UI */
.switch {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 24px;
}

.switch input { opacity: 0; width: 0; height: 0; }

.slider {
    position: absolute;
    cursor: pointer;
    inset: 0;
    background-color: rgba(255, 215, 0, 0.1) !important;
    border: 1px solid rgba(255, 215, 0, 0.3) !important;
    transition: .4s;
}

.slider:before {
    position: absolute;
    content: "";
    height: 16px;
    width: 16px;
    left: 3px;
    bottom: 3px;
    background-color: var(--color-accent) !important;
    transition: .4s;
    box-shadow: 0 0 10px rgba(255, 215, 0, 0.5);
}

input:checked + .slider { background-color: rgba(255, 215, 0, 0.3) !important; border-color: var(--color-accent) !important; }
input:checked + .slider:before { transform: translateX(26px); background-color: #FFFFFF !important; }
.slider.round { border-radius: 34px; }
.slider.round:before { border-radius: 50%; }

.bank-info-box {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.bank-logo-wrap img {
    height: 110px;
    width: 110px;
    object-fit: contain;
    border-radius: 20px;
    filter: drop-shadow(0 4px 10px rgba(0,0,0,0.3));
}

.gold-border { border: 2px solid var(--color-accent); }

.bonus-amount {
    font-size: 2rem;
    font-weight: 800;
    margin-top: 1rem;
    color: var(--color-text);
}

.tiny-info {
    font-size: 0.75rem;
    color: var(--color-text-muted);
    background: rgba(255, 215, 0, 0.05);
    padding: 0.75rem;
    border-radius: 8px;
    margin-top: auto;
}

/* SIM Card Overhaul - Screenshot Style */
.sim-tile-refined {
    min-height: auto; /* Removed fixed height */
}

.sim-smart-choice-label {
    text-align: center;
    color: #fff;
    font-weight: 700;
    margin-top: 1rem; /* Brings wording down slightly */
    margin-bottom: 3.5rem; /* Brings Lucky row down further */
    font-size: 0.9rem;
}

.sim-brand-list {
    display: flex;
    flex-direction: column;
    gap: 2.5rem; /* Reduced from 3.5rem to keep Chatr in place while Lucky moved down */
    margin-bottom: 2rem;
    padding: 0 1rem;
}

.sim-brand-row {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.sim-logo-link {
    background: #fff;
    padding: 12px;
    border-radius: 20px; /* More rounded/circular feel */
    width: 110px; /* More square-like */
    height: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 2px solid transparent;
}

.sim-logo-link.chatr-brand {
    background: #5B2D82; /* Chatr Purple */
    border: 2px solid #fff;
}

.sim-logo-link:hover {
    transform: scale(1.08);
    box-shadow: 0 0 20px rgba(255, 215, 0, 0.4);
}

.sim-logo-link img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.sim-price {
    font-size: 1.1rem;
    font-weight: 700;
    white-space: nowrap;
}

.sim-price .currency {
    color: var(--color-accent);
    font-size: 1.5rem;
    margin-right: 0.25rem;
}

.sim-price .value {
    color: var(--color-accent);
    font-size: 2.2rem;
    font-weight: 800;
}

.sim-price .unit {
    color: #fff;
    font-size: 0.9rem;
    font-weight: 500;
}

.sim-info-box {
    background: rgba(10, 17, 40, 0.6);
    border-radius: 12px;
    padding: 1.25rem;
    margin-top: auto;
}

.sim-info-box p {
    color: #94A3B8; /* Light blue/gray */
    font-size: 0.8rem;
    line-height: 1.5;
    text-align: center;
    margin: 0;
}

.pulse-icon {
    font-size: 3.5rem;
    margin: 1.5rem 0;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); }
}

.click-hint { font-size: 0.8rem; color: var(--color-accent); font-weight: 700; }

/* Intelligence Modules */
.intelligence-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: var(--spacing-lg);
    margin-top: var(--spacing-xl);
}

.intel-card {
    background-color: var(--color-surface);
    padding: var(--spacing-lg);
    border-radius: 20px;
    border: 1px solid var(--color-border);
}

.intel-card h4 { margin-bottom: 1.5rem; color: var(--color-accent); }

.brand-row {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.brand-btn {
    flex: 1;
    background: rgba(255, 255, 255, 0.05);
    padding: 0.75rem;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    font-weight: 600;
    transition: background 0.3s;
}

.brand-btn:hover { background: rgba(255, 215, 0, 0.1); border: 1px solid var(--color-accent); }

.intel-tip {
    font-size: 0.85rem;
    color: var(--color-text-muted);
    padding-top: 1rem;
    border-top: 1px solid var(--color-border);
}

/* Compass Display */
.compass-display {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 12px;
    padding: 1rem;
    min-height: 100px;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.zone-tag {
    padding: 0.5rem 0.75rem;
    border-radius: 6px;
    font-size: 0.8rem;
    font-weight: 700;
}

.zone-tag.green { background: rgba(16, 185, 129, 0.1); color: #10B981; border: 1px solid #10B981; }
.zone-tag.red { background: rgba(239, 68, 68, 0.1); color: #EF4444; border: 1px solid #EF4444; }

/* GIC Modal Specifics */
.gic-checklist h3 { color: var(--color-accent); margin-bottom: 1.5rem; }
.check-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.75rem;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 8px;
    cursor: pointer;
}

.check-item input[type="checkbox"] {
    accent-color: var(--color-accent);
    width: 20px;
    height: 20px;
}

.check-item span { font-size: 0.9rem; }

/* Global Header Active Link Fix */
.nav-links a.active {
    color: var(--color-accent);
}

.full-width { width: 100% !important; }

/* Dashboard Refinement */
.portal-downloads {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
}

/* Responsive Dashboard */
@media (max-width: 992px) {
    .portal-dashboard {
        grid-template-columns: 1fr;
    }
}

/* Responsive Design */
@media (max-width: 768px) {
    .hero-layout {
        grid-template-columns: 1fr;
        gap: var(--spacing-lg);
    }
    
    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background-color: var(--color-surface);
        flex-direction: column;
        padding: var(--spacing-md);
        border-bottom: 1px solid var(--color-border);
        box-shadow: 0 10px 20px rgba(0,0,0,0.1);
    }
    
    .nav-links.active {
        display: flex;
    }
    
    .mobile-menu-toggle {
        display: flex;
    }

    .hero-actions {
        flex-direction: column;
        width: 100%;
    }

    .btn {
        width: 100%;
        text-align: center;
    }
}
/* Premium Hub Architecture (Restored) */
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.hub-selector-container {
    margin-bottom: 1.5rem;
}

.premium-select {
    width: 100%;
    background-color: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--color-border);
    color: var(--color-text);
    padding: 0.8rem 1rem;
    border-radius: 12px;
    font-family: inherit;
    font-size: 1rem;
    outline: none;
    transition: border-color 0.3s;
}

.premium-select:focus {
    border-color: var(--color-accent);
}

.safety-data-display {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    min-height: 220px;
    background-color: rgba(10, 17, 40, 0.3);
    border-radius: 12px;
    padding: 1rem;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.zone-item {
    background-color: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.03);
    border-radius: 8px;
    padding: 1rem 1.25rem;
    display: flex;
    align-items: center;
    gap: 1.25rem;
    transition: all 0.3s ease;
    border-left: 6px solid transparent;
}

.zone-item:hover {
    background-color: rgba(255, 255, 255, 0.04);
    transform: translateX(4px);
}

.zone-indicator {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    flex-shrink: 0;
    box-shadow: 0 0 10px rgba(0,0,0,0.3);
}

/* Zone Color States */
.zone-item.green { border-left-color: #10B981; }
.zone-item.green .zone-indicator { background-color: #10B981; }

.zone-item.yellow { border-left-color: #F59E0B; }
.zone-item.yellow .zone-indicator { background-color: #F59E0B; }

.zone-item.red { border-left-color: #EF4444; }
.zone-item.red .zone-indicator { background-color: #EF4444; }

.zone-item strong {
    display: block;
    color: var(--color-text);
    font-size: 1rem;
    margin-bottom: 0.2rem;
}

.zone-item p {
    font-size: 0.8rem;
    color: var(--color-text-muted);
    margin: 0;
}

.premium-select {
    width: 100%;
    background-color: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--color-border);
    color: var(--color-text);
    padding: 0.8rem 1rem;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23FFD700' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    transition: all 0.2s ease;
}

.premium-select:focus {
    outline: none;
    border-color: var(--color-accent);
    box-shadow: 0 0 0 2px rgba(255, 215, 0, 0.1);
}

.transit-pills {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin: 1.5rem 0;
}

.transit-pill {
    flex: 1;
    background: none;
    border: none;
    color: var(--color-text-muted);
    padding: 0.5rem 0.4rem;
    border-radius: 100px;
    cursor: pointer;
    font-weight: 700;
    font-size: 0.75rem;
    transition: all 0.3s ease;
    font-family: var(--font-heading);
}

.transit-pill.active {
    background-color: var(--color-accent);
    color: #000;
    box-shadow: 0 4px 12px rgba(255, 215, 0, 0.3);
}

.map-view {
    position: relative;
    margin-bottom: 1.5rem;
}

.map-action-btn {
    position: absolute;
    bottom: 1rem;
    right: 1rem;
    background-color: var(--color-accent);
    color: #000;
    padding: 0.6rem 1.2rem;
    border-radius: 50px;
    font-weight: 700;
    font-size: 0.8rem;
}

.card-header-label {
    font-size: 0.75rem;
    font-weight: 800;
    color: var(--color-text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 0.5rem;
}

.transit-pills {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin: 1.5rem 0;
}

.transit-pill {
    background: transparent;
    border: none;
    color: var(--color-text-muted);
    font-weight: 700;
    font-size: 0.85rem;
    cursor: pointer;
    padding: 6px 12px;
    transition: all 0.2s ease;
}

.transit-pill.active {
    background: #FFD700;
    color: #000;
    border-radius: 50px;
    padding: 6px 18px;
}




.hub-actions-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-top: auto;
}

.zone-item {
    background-color: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    padding: 1rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
    border-left: 6px solid transparent;
}

.zone-item.green { border-left-color: #00C853; }
.zone-item.yellow { border-left-color: #FFD600; }
.zone-item.red { border-left-color: #FF1744; }

.zone-indicator {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

.zone-item.green .zone-indicator { background-color: #00C853; }
.zone-item.yellow .zone-indicator { background-color: #FFD600; }
.zone-item.red .zone-indicator { background-color: #FF1744; }

.mastery-box {
    background-color: rgba(255, 215, 0, 0.03);
    border-left: 4px solid #FFD700;
    padding: var(--spacing-md);
    border-radius: 4px;
    margin-bottom: var(--spacing-md);
}

.mastery-content strong, 
.guardian-mastery-block strong {
    color: #FFD700;
    margin-bottom: 0.5rem;
}

.full-width { width: 100% !important; margin-top: auto; }


/* SIM Card Smart Choice Tag */
.tag-smart-choice {
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--color-text);
    margin-bottom: 1rem;
}

/* 5. Weather Survival Module (Sovereign Design) */
.weather-survival-module {
    background: rgba(10, 17, 40, 0.4);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 215, 0, 0.15);
    border-radius: 20px;
    padding: 1.5rem;
    margin-bottom: 2.5rem;
}

.weather-alert-banner {
    background: linear-gradient(90deg, #b91c1c, #7f1d1d);
    border-left: 4px solid #FFD700;
    padding: 1rem;
    border-radius: 12px;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.alert-pulse { font-size: 1.5rem; animation: weatherAlertPulse 2s infinite; }

@keyframes weatherAlertPulse {
    0% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.8; transform: scale(1.05); }
    100% { opacity: 1; transform: scale(1); }
}

.weather-main-grid {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.weather-reality-card {
    background: rgba(255, 255, 255, 0.03);
    border-radius: 16px;
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.reality-header {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    margin-bottom: 1rem;
}

.reality-icon {
    font-size: 3rem;
    color: #FFD700;
}

.temp-big {
    font-size: 3rem;
    font-weight: 800;
    line-height: 1;
}

.temp-sub {
    font-size: 0.8rem;
    color: #94A3B8;
    text-transform: uppercase;
}

.reality-summary p {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.actual-label {
    font-size: 0.85rem;
    color: #94A3B8;
}

.weather-forecast-scroll {
    display: flex;
    gap: 1rem;
    overflow-x: auto;
    padding-bottom: 10px;
    scrollbar-width: thin;
    scrollbar-color: #FFD700 transparent;
}

.forecast-day {
    min-width: 90px;
    background: rgba(255, 255, 255, 0.05);
    padding: 1rem 0.5rem;
    border-radius: 12px;
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.forecast-name { font-size: 0.75rem; font-weight: 700; opacity: 0.8; text-transform: uppercase; }
.forecast-icon { font-size: 1.25rem; color: #FFD700; }
.forecast-temps { font-size: 0.85rem; font-weight: 700; }

.weather-details-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.clothing-protocol-card, .newcomer-tip-card {
    background: rgba(255, 255, 255, 0.03);
    border-radius: 16px;
    padding: 1.25rem;
}

.clothing-protocol-card h5, .newcomer-tip-card h5 {
    color: #FFD700;
    font-size: 0.9rem;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.clothing-list {
    list-style: none;
    padding: 0;
}

.clothing-list li {
    font-size: 0.85rem;
    margin-bottom: 0.5rem;
    padding-left: 1.5rem;
    position: relative;
    color: #E2E8F0;
}

.clothing-list li::before {
    content: "•";
    color: #FFD700;
    position: absolute;
    left: 0;
    font-weight: 800;
}

.newcomer-tip-card p {
    font-size: 0.85rem;
    line-height: 1.6;
    color: #94A3B8;
    font-style: italic;
}

@media (max-width: 1024px) {
    .weather-main-grid, .weather-details-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 600px) {
    .search-input-wrap {
        flex-direction: column !important;
    }
    
    .search-input-wrap button {
        width: 100% !important;
        margin-top: 0.5rem !important;
    }

    .quick-hubs {
        justify-content: center !important;
    }
}

/* Weather Search UI */
.weather-search-container {
    margin-bottom: 2rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.search-input-wrap {
    display: flex;
    gap: 0.5rem;
    background: rgba(255, 255, 255, 0.05);
    padding: 0.5rem;
    border-radius: 12px;
    border: 1px solid rgba(255, 215, 0, 0.1);
}

.search-icon {
    padding: 0.75rem;
    color: #FFD700;
}

#weather-city-search {
    flex: 1;
    background: transparent;
    border: none;
    color: #fff;
    padding: 0.5rem;
    font-size: 1rem;
    outline: none;
}

#weather-city-search::placeholder {
    color: rgba(255, 255, 255, 0.55);
}

.quick-hubs {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.quick-label {
    font-size: 0.8rem;
    font-weight: 700;
    color: #94A3B8;
    text-transform: uppercase;
}

.hub-pill {
    background: rgba(255, 215, 0, 0.05);
    border: 1px solid rgba(255, 215, 0, 0.1);
    color: #fff;
    padding: 0.35rem 0.75rem;
    border-radius: 50px;
    font-size: 0.75rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
}

.hub-pill:hover, .hub-pill.active {
    background: #FFD700;
    color: #000;
    border-color: #FFD700;
    opacity: 1 !important;
}

.hub-pill:active {
    transform: scale(0.95);
    opacity: 1 !important;
}

/* Search Suggestions */
.search-input-wrap { position: relative; }

.search-suggestions {
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background: #0A1128;
    border: 1px solid rgba(255, 215, 0, 0.2);
    border-top: none;
    border-radius: 0 0 12px 12px;
    z-index: 1000;
    max-height: 250px;
    overflow-y: auto;
    display: none;
    box-shadow: 0 10px 25px rgba(0,0,0,0.5);
}

.suggestion-item {
    padding: 0.75rem 1.25rem;
    cursor: pointer;
    font-size: 0.9rem;
    color: #fff;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    transition: background 0.2s;
}

.suggestion-item:last-child { border-bottom: none; }

.suggestion-item:hover {
    background: rgba(255, 215, 0, 0.1);
    color: #FFD700;
}


.suggestion-item span {
    font-size: 0.75rem;
    opacity: 0.6;
    margin-left: 0.5rem;
}


/* ==========================================================================
   THE SANCTUARY: MENTAL HEALTH CORNER (SOVEREIGN THEME)
   ========================================================================== */
.sanctuary-section {
    padding: 6rem 0;
    background: #0a192f; /* Deep Navy Blue */
    position: relative;
    overflow: hidden;
}

[data-theme="light"] .sanctuary-section {
    background: #102a43; /* Keep dark enough for stars to remain visible in light mode */
}

/* Keep content above the star layers */
.relative-z {
    position: relative;
    z-index: 10;
}

/* ==========================================================================
   ADVANCED STARFIELD & COMET
   ========================================================================== */
.sanctuary-star-layer {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    width: 100%; height: 100%;
    pointer-events: none;
    z-index: 1;
}

/* Layer 1: Small, dense, static backdrop stars */
.sanctuary-star-layer.layer-1 {
    background-image: 
        radial-gradient(1px 1px at 20px 30px, rgba(255,255,255,0.5), rgba(0,0,0,0)),
        radial-gradient(1px 1px at 40px 70px, rgba(255,255,255,0.4), rgba(0,0,0,0)),
        radial-gradient(1px 1px at 90px 40px, rgba(255,255,255,0.6), rgba(0,0,0,0)),
        radial-gradient(1.5px 1.5px at 160px 120px, rgba(255,255,255,0.5), rgba(0,0,0,0));
    background-size: 200px 200px;
    opacity: 0.8;
}

/* Layer 2: Medium, slow twinkling stars */
.sanctuary-star-layer.layer-2 {
    background-image: 
        radial-gradient(2px 2px at 50px 160px, rgba(255,255,255,0.8), rgba(0,0,0,0)),
        radial-gradient(2px 2px at 130px 80px, rgba(255,255,255,0.9), rgba(0,0,0,0)),
        radial-gradient(2.5px 2.5px at 10px 190px, rgba(255,255,255,0.7), rgba(0,0,0,0));
    background-size: 250px 250px;
    animation: twinkleSlow 5s ease-in-out infinite alternate;
}

/* Layer 3: Large, bright, fast twinkling stars with "glow" */
.sanctuary-star-layer.layer-3 {
    background-image: 
        radial-gradient(3px 3px at 80px 50px, #fff, rgba(255,255,255,0.2) 20%, rgba(0,0,0,0) 50%),
        radial-gradient(4px 4px at 190px 10px, #fff, rgba(255,255,255,0.3) 20%, rgba(0,0,0,0) 50%),
        radial-gradient(3.5px 3.5px at 220px 200px, #fff, rgba(255,255,255,0.1) 20%, rgba(0,0,0,0) 50%);
    background-size: 300px 300px;
    animation: twinkleFast 3s ease-in-out infinite alternate;
}

@keyframes twinkleSlow {
    0% { opacity: 0.3; }
    100% { opacity: 1; }
}

@keyframes twinkleFast {
    0% { opacity: 0.5; transform: scale(0.9); }
    100% { opacity: 1; transform: scale(1.1); }
}

/* Animated Comet */
.sanctuary-comet {
    position: absolute;
    top: 5%;
    right: -10%;
    width: 2px;
    height: 2px;
    background: #fff;
    border-radius: 50%;
    box-shadow: 0 0 10px 2px rgba(255, 255, 255, 1);
    animation: cometFly 12s linear infinite;
    opacity: 0;
    pointer-events: none;
    z-index: 1;
}

.sanctuary-comet::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 100%;
    width: 180px;
    height: 1px;
    background: linear-gradient(to right, rgba(255,255,255,0.9), rgba(255,255,255,0));
    transform: translateY(-50%);
}

@keyframes cometFly {
    0% {
        transform: translate(0, 0) rotate(215deg);
        opacity: 0;
    }
    3% {
        opacity: 1;
    }
    15% {
        transform: translate(-1500px, 1050px) rotate(215deg); /* Continues off screen */
        opacity: 0;
    }
    100% {
        transform: translate(-1500px, 1050px) rotate(215deg);
        opacity: 0;
    }
}

.sanctuary-wrapper {
    max-width: 800px;
    margin: 0 auto;
    position: relative;
    min-height: 600px;
}

.sanctuary-view {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.5s ease, transform 0.5s ease;
    transform: translateY(10px);
}

.sanctuary-view.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    position: relative;
    z-index: 2;
}

/* Hero */
.sanctuary-hero {
    text-align: center;
    margin-bottom: 3rem;
}

@keyframes sanctuaryBreathe {
    0% { transform: translateY(0) scale(1); }
    50% { transform: translateY(-8px) scale(1.01); }
    100% { transform: translateY(0) scale(1); }
}

.hero-image-wrapper {
    position: relative;
    display: inline-block;
    max-width: 800px;
    width: 100%;
    margin: 0 auto 2rem auto;
    animation: sanctuaryBreathe 8s ease-in-out infinite;
}

.hero-image-wrapper::after {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    box-shadow: inset 0 0 60px 40px #0a192f;
    pointer-events: none;
}

.hero-image {
    width: 100%;
    height: auto;
    display: block;
    border: none;
    box-shadow: none;
}

.sanctuary-title {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    color: var(--color-text);
}

.sanctuary-subtitle {
    font-size: 1.25rem;
    color: var(--color-text-muted);
    max-width: 500px;
    margin: 0 auto;
    line-height: 1.6;
}

/* Emotion Gateways */
.emotion-gateways {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 3rem;
}

.emotion-btn {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 1.5rem;
    border-radius: 20px;
    color: var(--color-text);
    font-size: 1.2rem;
    display: flex;
    align-items: center;
    gap: 1.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

[data-theme="light"] .emotion-btn {
    background: rgba(0, 0, 0, 0.02);
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.emotion-btn i {
    font-size: 1.5rem;
    color: var(--color-accent);
}

.emotion-btn:hover {
    background: rgba(255, 255, 255, 0.08);
    transform: translateY(-2px);
    border-color: rgba(255, 255, 255, 0.2);
}

[data-theme="light"] .emotion-btn:hover {
    background: rgba(0, 0, 0, 0.05);
    border-color: rgba(0, 0, 0, 0.1);
}

/* Daily Calm Card */
.daily-calm-card {
    background: rgba(20, 184, 166, 0.1);
    border: 1px solid rgba(20, 184, 166, 0.2);
    padding: 2rem;
    border-radius: 24px;
    text-align: center;
}

.daily-calm-card i {
    color: #14B8A6;
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.daily-calm-card p {
    font-size: 1.2rem;
    font-style: italic;
    color: var(--color-text);
}

/* Flow Views */
.flow-view {
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 32px;
    padding: 3rem;
}

[data-theme="light"] .flow-view {
    background: #ffffff;
    border: 1px solid rgba(0, 0, 0, 0.05);
    box-shadow: 0 20px 40px rgba(0,0,0,0.02);
}

.back-btn {
    background: none;
    border: none;
    color: var(--color-text-muted);
    font-size: 1rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 2rem;
    transition: color 0.3s;
}

.back-btn:hover {
    color: var(--color-text);
}

.flow-header {
    text-align: center;
    margin-bottom: 3rem;
}

.flow-icon {
    font-size: 3rem;
    color: var(--color-accent);
    margin-bottom: 1.5rem;
}

.validation-msg {
    font-size: 1.2rem;
    color: var(--color-text-muted);
    line-height: 1.6;
    margin-top: 1rem;
}

.coping-actions h4 {
    font-size: 1.2rem;
    margin-bottom: 1.5rem;
    color: var(--color-text);
}

.coping-actions ul {
    list-style: none;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.coping-actions li {
    background: rgba(255, 255, 255, 0.03);
    padding: 1.2rem 1.5rem;
    border-radius: 16px;
    display: flex;
    align-items: center;
    gap: 1rem;
    font-size: 1.1rem;
    color: var(--color-text);
}

[data-theme="light"] .coping-actions li {
    background: rgba(0, 0, 0, 0.02);
}

.coping-actions li i {
    color: var(--color-accent);
}

/* Footer Section */
.sanctuary-footer {
    margin-top: 4rem;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    padding-top: 3rem;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
}

[data-theme="light"] .sanctuary-footer {
    border-top: 1px solid rgba(0, 0, 0, 0.05);
}

.quick-calm-tool h4, .support-actions h4 {
    font-size: 1.1rem;
    margin-bottom: 1rem;
    color: var(--color-text);
}

.breathing-steps {
    display: flex;
    align-items: center;
    gap: 1rem;
    font-size: 1rem;
    color: var(--color-text-muted);
    background: rgba(255, 255, 255, 0.03);
    padding: 1rem;
    border-radius: 12px;
}

[data-theme="light"] .breathing-steps {
    background: rgba(0, 0, 0, 0.02);
}

.divider {
    color: var(--color-accent);
}

.support-actions p {
    font-size: 0.95rem;
    color: var(--color-text-muted);
    line-height: 1.5;
    margin-bottom: 0.5rem;
}

.support-actions .disclaimer {
    font-size: 0.8rem;
    opacity: 0.7;
}

@media (max-width: 768px) {
    .sanctuary-footer {
        grid-template-columns: 1fr;
    }
    .flow-view {
        padding: 2rem 1.5rem;
    }
    .emotion-btn {
        padding: 1.2rem;
    }
}

/* Crisis Support Block */
.crisis-support-block {
    margin-top: 3rem;
    background: rgba(239, 68, 68, 0.05);
    border: 1px solid rgba(239, 68, 68, 0.2);
    border-radius: 24px;
    padding: 2.5rem;
}

[data-theme="light"] .crisis-support-block {
    background: rgba(239, 68, 68, 0.03);
    border: 1px solid rgba(239, 68, 68, 0.15);
}

.crisis-lines {
    margin-top: 2rem;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.crisis-line-item {
    background: rgba(255, 255, 255, 0.03);
    padding: 1.5rem;
    border-radius: 16px;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    border-left: 4px solid #FB923C;
}

[data-theme="light"] .crisis-line-item {
    background: #ffffff;
    box-shadow: 0 4px 15px rgba(0,0,0,0.02);
}

.crisis-line-item strong {
    font-size: 1.2rem;
    color: var(--color-text);
}

.crisis-line-item span {
    color: var(--color-text-muted);
    font-size: 1rem;
}

.crisis-line-item a {
    color: #FB923C; /* Soft orange */
    font-weight: bold;
    text-decoration: underline;
    text-underline-offset: 4px;
}

.crisis-line-item a:hover {
    color: #F97316;
}

.hidden {
    display: none !important;
}

/* ==========================================================================
   PROVINCE INFORMATION SYSTEM (2025-2026)
   ========================================================================== */

#province-system-view {
    max-width: 900px;
    margin: 0 auto;
    padding: 2rem 1rem 6rem;
}

/* Header & Tabs */
.province-header-area {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.province-selector-tabs {
    display: flex;
    gap: 0.5rem;
    background: var(--color-surface);
    padding: 0.5rem;
    border-radius: 12px;
    border: 1px solid var(--color-border);
}

.prov-tab {
    padding: 0.5rem 1rem;
    border-radius: 8px;
    border: none;
    background: transparent;
    color: var(--color-text-muted);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.prov-tab.active {
    background: var(--color-accent);
    color: #ffffff;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

/* Hero Card */
.prov-hero {
    text-align: center;
    padding: 3rem 2rem;
    margin-bottom: 2rem;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-top: none;
    border-radius: 0;
}

.prov-title {
    font-size: 3rem;
    margin-bottom: 0.5rem;
    color: var(--color-text);
}

.prov-cities {
    font-size: 1.2rem;
    color: var(--color-text-muted);
    margin-bottom: 1.5rem;
}

.prov-emotional-summary {
    font-size: 1.4rem;
    font-style: italic;
    color: var(--color-accent);
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.4;
}

/* Content Cards */
.prov-card {
    background: var(--color-surface);
    border-radius: 16px;
    padding: 2rem;
    margin-bottom: 1.5rem;
    border: 1px solid var(--color-border);
}

.prov-card h2 {
    font-size: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: var(--color-text);
    margin-bottom: 1.5rem;
}

.prov-card h2 i {
    color: var(--color-accent);
}

/* Collapsible */
.collapsible .prov-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    margin-bottom: 0;
}

.collapsible .prov-card-header h2 {
    margin-bottom: 0;
}

.prov-card-body {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease, margin-top 0.4s ease, opacity 0.4s ease;
    opacity: 0;
}

.prov-card-body.expanded {
    max-height: 1000px; /* Arbitrary large number */
    margin-top: 1.5rem;
    opacity: 1;
}

.toggle-icon {
    transition: transform 0.3s ease;
    color: var(--color-text-muted);
}

/* Grids */
.prov-grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.prov-grid-2 .prov-card {
    margin-bottom: 0;
}

/* Lists & Text */
.cost-list {
    list-style: none;
    padding: 0;
    margin-bottom: 1.5rem;
}

.cost-list li {
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--color-border);
    color: var(--color-text-muted);
}

.cost-list li strong {
    color: var(--color-text);
    display: inline-block;
    width: 200px;
}

.cost-list .total-survival {
    font-size: 1.2rem;
    color: var(--color-accent);
    border-bottom: none;
    margin-top: 0.5rem;
}

.prov-details {
    color: var(--color-text-muted);
    line-height: 1.6;
    background: rgba(255, 255, 255, 0.02);
    padding: 1rem;
    border-radius: 8px;
    border-left: 3px solid var(--color-accent);
}

[data-theme="light"] .prov-details {
    background: #f9fafb;
}

/* Ratings & Badges */
.rating-badge {
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 1px;
}

.rating-high, .rating-extreme, .rating-very\ high {
    background: rgba(239, 68, 68, 0.1);
    color: #EF4444;
}

.rating-medium {
    background: rgba(245, 158, 11, 0.1);
    color: #F59E0B;
}

.rating-low {
    background: rgba(16, 185, 129, 0.1);
    color: #10B981;
}

/* Challenge Box */
.challenge-box {
    background: rgba(239, 68, 68, 0.05);
    border: 1px solid rgba(239, 68, 68, 0.2);
    border-radius: 8px;
    padding: 1.5rem;
    margin-top: 1.5rem;
}

.challenge-box strong {
    color: #EF4444;
    display: block;
    margin-bottom: 0.5rem;
}

.challenge-box p {
    color: var(--color-text-muted);
    margin: 0;
}

/* Reality Notes */
.reality-notes-section {
    background: linear-gradient(135deg, rgba(56, 189, 248, 0.05), rgba(52, 211, 153, 0.05));
    border-color: rgba(56, 189, 248, 0.2);
}

.reality-list {
    padding-left: 1.5rem;
    color: var(--color-text-muted);
    line-height: 1.8;
}

.reality-list li {
    margin-bottom: 0.5rem;
}

.reality-list li em {
    color: var(--color-accent);
}

/* Ideal Profile */
.ideal-profile-box {
    text-align: center;
    background: var(--color-bg);
}

.ideal-profile-box h2 {
    justify-content: center;
}

.ideal-profile-box p {
    font-size: 1.2rem;
    color: var(--color-text-muted);
}

/* Comparison Table */
.table-responsive {
    overflow-x: auto;
}

.prov-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 1rem;
}

.prov-table th, .prov-table td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid var(--color-border);
}

.prov-table th {
    font-weight: 600;
    color: var(--color-text);
    background: rgba(255, 255, 255, 0.02);
}

.prov-table td {
    color: var(--color-text-muted);
}

[data-theme="light"] .prov-table th {
    background: #f9fafb;
}

/* FAQ Accordion */
.faq-accordion {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.faq-item {
    border: 1px solid var(--color-border);
    border-radius: 8px;
    padding: 1rem;
}

.faq-q {
    color: var(--color-text);
    margin-bottom: 0.5rem;
}

.faq-a {
    color: var(--color-text-muted);
    line-height: 1.6;
}

/* Responsive adjustments */

@media (max-width: 768px) {
    .prov-grid-2 {
        grid-template-columns: 1fr;
    }
    
    .province-header-area {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .prov-title {
        font-size: 2rem;
    }
    
    .cost-list li strong {
        display: block;
        width: 100%;
        margin-bottom: 0.25rem;
    }
    
    .collapsible .prov-card-header {
        flex-wrap: wrap;
        gap: 0.5rem;
    }
}

/* ==========================================================================
   PROVINCE MATCHER QUIZ
   ========================================================================== */
.hero-quiz-container {
    width: 100%;
    max-width: 500px;
    margin: 0 auto;
}

.quiz-card {
    background: var(--color-surface);
    border-radius: 16px;
    border: 1px solid var(--color-border);
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
}

.quiz-header {
    background: rgba(0,0,0,0.2);
    padding: 1rem;
    border-bottom: 1px solid var(--color-border);
}

.quiz-progress-bar {
    height: 4px;
    background: var(--color-border);
    border-radius: 4px;
    margin-bottom: 0.5rem;
    overflow: hidden;
}

.quiz-progress-fill {
    height: 100%;
    background-color: var(--color-accent);
    transition: width 0.3s ease;
}

.quiz-status {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--color-text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    text-align: center !important;
    width: 100% !important;
    display: block !important;
}

.quiz-body {
    padding: var(--spacing-lg);
    text-align: center;
}

.quiz-question {
    font-size: 1.5rem;
    margin-bottom: var(--spacing-sm);
    color: var(--color-text);
}

.quiz-context {
    color: var(--color-text-muted);
    margin-bottom: var(--spacing-lg);
}

.quiz-options {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.quiz-opt-btn {
    width: 100%;
    text-align: left;
    padding: 1rem;
    font-size: 1rem;
    justify-content: flex-start;
    border: 1px solid var(--color-border);
    border-radius: 8px;
    background: transparent;
    color: var(--color-text);
    cursor: pointer;
    transition: all 0.2s ease;
}

.quiz-opt-btn:hover {
    border-color: var(--color-accent);
    background: rgba(255, 215, 0, 0.05);
}

.quiz-start-btn {
    width: 100%;
}

/* 
 * 2026 Budget Hub System - Moved to index.html for rendering stability.
 */

@media (max-width: 768px) {
    .dashboard-grid, .resource-grid, .info-grid, .chronicles-grid {
        grid-template-columns: 1fr !important;
        gap: var(--spacing-md) !important;
    }
    .container {
        padding: 0 var(--spacing-sm) !important;
    }
    section {
        padding: var(--spacing-md) 0 !important;
    }
    .section-header {
        margin-bottom: var(--spacing-md) !important;
    }
    .section-title {
        font-size: 1.5rem !important;
    }
    .hero-title {
        font-size: 2rem !important;
    }
}


/* About This Platform Section Styling */
.about-platform-section {
    padding: 3rem 0 !important;
    position: relative;
    background: radial-gradient(circle at 50% 30%, rgba(244, 197, 66, 0.02), transparent);
}

html[data-theme="light"] .about-platform-section {
    background: radial-gradient(circle at 50% 30%, rgba(0, 51, 160, 0.01), transparent);
}

.about-glass-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    backdrop-filter: var(--glass-blur);
    border-radius: var(--glass-radius);
    padding: 2.5rem !important;
    box-shadow: var(--glass-shadow);
}

.about-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 4rem;
    align-items: center;
}

.about-label {
    display: inline-block;
    font-family: var(--font-heading);
    font-size: 0.8rem;
    font-weight: 800;
    color: var(--color-accent);
    text-transform: uppercase;
    letter-spacing: 1.5px;
    margin-bottom: 0.75rem;
}

.about-headline {
    font-family: var(--font-heading);
    font-size: clamp(1.4rem, 2.2vw, 2rem);
    font-weight: 700;
    line-height: 1.35;
    color: var(--color-text);
    margin-bottom: 1rem;
}

.about-paragraph {
    font-family: var(--font-body);
    font-size: 0.95rem;
    line-height: 1.6;
    color: var(--color-text-muted);
    margin-bottom: 1.5rem;
    max-width: 580px;
}

.about-learn-btn {
    border-radius: 50px !important;
    padding: 0.6rem 1.25rem !important;
    font-size: 0.8rem !important;
}

.about-features-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.about-feature-mini-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 1rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    transition: all var(--transition-fast);
}

html[data-theme="light"] .about-feature-mini-card {
    background: rgba(0, 0, 0, 0.015);
}

.about-feature-mini-card:hover {
    border-color: var(--color-accent);
    background: rgba(255, 215, 0, 0.03);
    transform: translateY(-2px);
}

html[data-theme="light"] .about-feature-mini-card:hover {
    background: rgba(0, 51, 160, 0.025);
}

.about-feature-mini-card.span-full-width {
    grid-column: span 2;
}

.feature-icon {
    font-size: 1.2rem;
}

.feature-text {
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 0.85rem;
    color: var(--color-text);
}

/* Responsive Realignment for Small Devices */
@media (max-width: 992px) {
    .about-grid {
        grid-template-columns: 1fr;
        gap: 2.5rem;
    }
}

@media (max-width: 576px) {
    .about-features-grid {
        grid-template-columns: 1fr;
    }
    
    .about-feature-mini-card.span-full-width {
        grid-column: span 1;
    }
    
    .about-glass-card {
        padding: 1.5rem !important;
    }
    
    .about-headline {
        font-size: 1.35rem;
    }
}

/* Global Visibility Helper */
.hidden {
    display: none !important;
}

/* ==========================================================================
   Newcomer Intelligence Top Bar System
   ========================================================================== */
.newcomer-top-bar {
    background: rgba(5, 8, 22, 0.6);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    padding: 0.6rem var(--spacing-md);
    color: #E6EAF2;
    font-size: 0.85rem;
    position: relative;
    z-index: 90;
    display: flex;
    justify-content: space-between;
    align-items: center;
    overflow: hidden;
    height: 40px;
    box-sizing: border-box;
}

html[data-theme="light"] .newcomer-top-bar {
    background: rgba(240, 244, 248, 0.75);
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
    color: #1A202C;
}

.top-bar-left {
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.top-bar-badge-pill {
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.15) 0%, rgba(255, 215, 0, 0.05) 100%);
    border: 1px solid rgba(255, 215, 0, 0.3);
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 700;
    font-family: var(--font-heading);
    color: var(--color-premium-gold);
    display: flex;
    align-items: center;
    gap: 0.4rem;
    box-shadow: 0 0 10px rgba(255, 215, 0, 0.1);
    white-space: nowrap;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

html[data-theme="light"] .top-bar-badge-pill {
    background: linear-gradient(135deg, rgba(0, 51, 160, 0.1) 0%, rgba(0, 51, 160, 0.05) 100%);
    border-color: rgba(0, 51, 160, 0.2);
    color: #0033A0;
    box-shadow: 0 2px 8px rgba(0, 51, 160, 0.05);
}

.pulse-beacon {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background-color: var(--color-premium-gold);
    box-shadow: 0 0 6px var(--color-premium-gold);
    animation: beaconPulse 1.5s infinite ease-in-out;
}

html[data-theme="light"] .pulse-beacon {
    background-color: #0033A0;
    box-shadow: 0 0 6px #0033A0;
}

@keyframes beaconPulse {
    0% { transform: scale(0.9); opacity: 0.6; }
    50% { transform: scale(1.2); opacity: 1; }
    100% { transform: scale(0.9); opacity: 0.6; }
}

.top-bar-insight-link {
    color: #E6EAF2;
    text-decoration: none;
    font-family: var(--font-body);
    font-size: 0.85rem;
    font-weight: 500;
    transition: all 0.2s ease;
    cursor: pointer;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 90%;
    display: inline-block;
}

.top-bar-insight-link:hover {
    color: var(--color-premium-gold);
    text-shadow: 0 0 8px rgba(255, 215, 0, 0.5);
    text-decoration: underline;
}

html[data-theme="light"] .top-bar-insight-link {
    color: #1A202C;
}

html[data-theme="light"] .top-bar-insight-link:hover {
    color: #0033A0;
    text-shadow: 0 2px 4px rgba(0, 51, 160, 0.1);
}

.top-bar-center {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    overflow: hidden;
    height: 100%;
}

.top-bar-card-wrapper {
    position: absolute;
    width: 100%;
    text-align: center;
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.4s ease, transform 0.4s ease;
    pointer-events: none;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.top-bar-card-wrapper.active {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

.top-bar-insight {
    font-family: var(--font-body);
    font-size: 0.85rem;
    font-weight: 500;
}

.top-bar-badge {
    padding: 0.15rem 0.5rem;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.badge-visa { background: rgba(93, 169, 255, 0.15); border: 1px solid rgba(93, 169, 255, 0.3); color: #5DA9FF; }
.badge-study { background: rgba(244, 197, 66, 0.15); border: 1px solid rgba(244, 197, 66, 0.3); color: var(--color-premium-gold); }
.badge-work { background: rgba(57, 217, 138, 0.15); border: 1px solid rgba(57, 217, 138, 0.3); color: #39D98A; }
.badge-finance { background: rgba(255, 181, 71, 0.15); border: 1px solid rgba(255, 181, 71, 0.3); color: #FFB547; }
.badge-province { background: rgba(168, 85, 247, 0.15); border: 1px solid rgba(168, 85, 247, 0.3); color: #C084FC; }

.top-bar-right {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 0.75rem;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    white-space: nowrap;
}

.live-pulse-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background-color: var(--color-safety-green);
    box-shadow: 0 0 8px var(--color-safety-green);
    animation: livePulse 2s infinite ease-in-out;
}

@keyframes livePulse {
    0% { transform: scale(0.9); opacity: 0.6; box-shadow: 0 0 0 0 rgba(57, 217, 138, 0.7); }
    50% { transform: scale(1.1); opacity: 1; box-shadow: 0 0 10px 4px rgba(57, 217, 138, 0.3); }
    100% { transform: scale(0.9); opacity: 0.6; box-shadow: 0 0 0 0 rgba(57, 217, 138, 0); }
}

@media (max-width: 992px) {
    .newcomer-top-bar {
        padding: 0.5rem 1rem;
    }
    .top-bar-left {
        font-size: 0.75rem;
    }
    .top-bar-right {
        display: none;
    }
}

@media (max-width: 768px) {
    .top-bar-left {
        display: none;
    }
    .newcomer-top-bar {
        justify-content: center;
    }
    .top-bar-center {
        width: 100%;
    }
}

/* ==========================================================================
   Trust + Orientation Quick Access Section (Redesign)
   ========================================================================== */
.about-grid {
    grid-template-columns: 1fr 1.3fr !important;
}

@media (max-width: 992px) {
    .about-grid {
        grid-template-columns: 1fr !important;
    }
}

.about-subtle-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-family: var(--font-heading);
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--color-accent);
    text-decoration: none;
    transition: all var(--transition-fast);
    border-bottom: 1px solid transparent;
    padding-bottom: 2px;
    margin-top: 1.5rem;
}
.about-subtle-link:hover {
    border-color: var(--color-accent);
    gap: 0.75rem;
}
.about-subtle-link i {
    font-size: 0.75rem;
    transition: transform var(--transition-fast);
}
.about-subtle-link:hover i {
    transform: translateX(2px);
}

.quick-access-panel {
    display: flex;
    flex-direction: column;
    min-width: 0;
    max-width: 100%;
}

.quick-access-title {
    font-family: var(--font-heading);
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--color-text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 1.5rem;
    text-align: left;
}

.quick-entry-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.quick-entry-card {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--glass-border);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border-radius: 16px;
    padding: 1.25rem;
    text-decoration: none;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    height: 100%;
}

html[data-theme="light"] .quick-entry-card {
    background: rgba(0, 0, 0, 0.015);
}

.quick-entry-card:hover {
    transform: translateY(-4px);
    border-color: var(--color-accent);
    background: rgba(244, 197, 66, 0.04);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.15);
}

html[data-theme="light"] .quick-entry-card:hover {
    background: rgba(0, 51, 160, 0.03);
}

.quick-entry-card .card-icon {
    font-size: 1.5rem;
    line-height: 1;
    transition: transform 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    flex-shrink: 0;
}

html[data-theme="light"] .quick-entry-card .card-icon {
    background: rgba(0, 0, 0, 0.02);
    border-color: rgba(0, 0, 0, 0.03);
}

.quick-entry-card:hover .card-icon {
    transform: scale(1.15) rotate(5deg);
    background: rgba(244, 197, 66, 0.1);
    border-color: rgba(244, 197, 66, 0.2);
}

html[data-theme="light"] .quick-entry-card:hover .card-icon {
    background: rgba(0, 51, 160, 0.08);
    border-color: rgba(0, 51, 160, 0.15);
}

.quick-entry-card .card-info {
    display: flex;
    flex-direction: column;
    text-align: left;
}

.quick-entry-card .card-title {
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 0.95rem;
    color: var(--color-text);
    line-height: 1.2;
}

.quick-entry-card .card-desc {
    font-family: var(--font-body);
    font-size: 0.78rem;
    color: var(--color-text-muted);
    margin-top: 0.35rem;
    line-height: 1.4;
}

.quick-entry-card.span-full-width {
    grid-column: span 2;
}

/* swipe row on mobile */
@media (max-width: 768px) {
    .quick-entry-grid {
        display: flex !important;
        flex-direction: row !important;
        overflow-x: auto !important;
        flex-wrap: nowrap !important;
        scroll-snap-type: x mandatory !important;
        gap: 1rem !important;
        padding: 0.5rem 0.25rem 1.5rem !important;
        -webkit-overflow-scrolling: touch !important;
        scrollbar-width: none !important;
        width: 100%;
        max-width: 100%;
    }
    
    .quick-entry-grid::-webkit-scrollbar {
        display: none !important;
    }
    
    .quick-entry-card {
        min-width: 260px !important;
        max-width: 280px !important;
        flex: 0 0 auto !important;
        scroll-snap-align: start !important;
        height: 100% !important;
    }
    
    .quick-entry-card.span-full-width {
        grid-column: auto !important;
    }
}

/* ==========================================================================
   GLOBAL SITE FOOTER — PREMIUM SOVEREIGN
   ========================================================================== */
.site-footer {
    text-align: center;
    position: relative;
    z-index: 10;
    background: #070d1f;
    padding: 0;
}

/* Gold gradient top border line */
.site-footer::before {
    content: '';
    display: block;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, transparent 0%, rgba(255, 215, 0, 0.6) 30%, #FFD700 50%, rgba(255, 215, 0, 0.6) 70%, transparent 100%);
}

[data-theme="light"] .site-footer {
    background: #f0f2f8;
}

[data-theme="light"] .site-footer::before {
    background: linear-gradient(90deg, transparent 0%, rgba(0, 51, 160, 0.4) 30%, #0033A0 50%, rgba(0, 51, 160, 0.4) 70%, transparent 100%);
}

/* Main footer body */
.footer-body {
    padding: 3rem 1.5rem 2.5rem;
}

/* Brand name */
.site-footer-brand {
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 1.1rem;
    color: #FFD700;
    letter-spacing: 0.5px;
    margin: 0 0 0.35rem 0;
}

[data-theme="light"] .site-footer-brand {
    color: #0033A0;
}

/* Tagline */
.site-footer-tagline {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.65);
    margin: 0 0 2rem 0;
    letter-spacing: 0.2px;
}

[data-theme="light"] .site-footer-tagline {
    color: rgba(0, 0, 0, 0.65);
}

/* Navigation links */
.site-footer-nav {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.2rem 0;
    list-style: none;
    margin: 0;
    padding: 0;
}

.site-footer-nav a {
    display: inline-block;
    color: rgba(255, 255, 255, 0.6);
    text-decoration: none;
    font-size: 0.82rem;
    font-weight: 500;
    letter-spacing: 0.3px;
    padding: 0.3rem 0.9rem;
    border-right: 1px solid rgba(255, 255, 255, 0.12);
    transition: color 0.2s ease;
    line-height: 1;
}

.site-footer-nav a:last-child {
    border-right: none;
}

.site-footer-nav a:hover {
    color: #FFD700;
}

[data-theme="light"] .site-footer-nav a {
    color: rgba(0, 0, 0, 0.5);
    border-right-color: rgba(0, 0, 0, 0.12);
}

[data-theme="light"] .site-footer-nav a:hover {
    color: #0033A0;
}

/* Bottom copyright meta strip */
.site-footer-meta {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.4rem 0.8rem;
    font-size: 0.72rem;
    color: rgba(255, 255, 255, 0.6);
    padding: 1rem 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

[data-theme="light"] .site-footer-meta {
    color: rgba(0, 0, 0, 0.6);
    border-top-color: rgba(0, 0, 0, 0.06);
}

.site-footer-meta a {
    color: inherit;
    text-decoration: none;
    transition: color 0.2s ease;
}

.site-footer-meta a:hover {
    color: #FFD700;
}

[data-theme="light"] .site-footer-meta a:hover {
    color: #0033A0;
}

.site-footer-meta .meta-divider {
    opacity: 0.3;
}

.site-footer-email {
    color: rgba(255, 215, 0, 0.7) !important;
    font-weight: 600;
    transition: color 0.2s ease !important;
}

.site-footer-email:hover {
    color: #FFD700 !important;
}

[data-theme="light"] .site-footer-email {
    color: rgba(0, 51, 160, 0.7) !important;
}

[data-theme="light"] .site-footer-email:hover {
    color: #0033A0 !important;
}

/* Mobile */
@media (max-width: 600px) {
    .footer-body {
        padding: 2.5rem 1rem 2rem;
    }

    .site-footer-nav a {
        padding: 0.35rem 0.65rem;
        font-size: 0.78rem;
    }

    .site-footer-meta {
        font-size: 0.68rem;
        gap: 0.35rem 0.6rem;
    }
}


/* UI Polish: Center Align Hero and Header content on Mobile */
@media (max-width: 768px) {
    .hero-content, .section-header {
        text-align: center !important;
        margin-left: auto !important;
        margin-right: auto !important;
        display: flex;
        flex-direction: column;
        align-items: center;
        padding-top: 2.5rem !important;
    }
    .hero-subtitle, .section-subtitle {
        text-align: center !important;
        margin-left: auto !important;
        margin-right: auto !important;
    }
    .hero-actions {
        justify-content: center !important;
        width: 100%;
        flex-wrap: wrap;
    }
}
