/* ═══════════════════════════════════════════════════════════════════
   SAFE-X Fire & Safety Service And Training Institute
   Shared Legal & Policy Pages Design System (2026 Trending Standards)
   Full Light & Dark Theme Support | Fully Mobile & Desktop Responsive
   ═══════════════════════════════════════════════════════════════════ */

/* ─── DESIGN TOKENS & CSS CUSTOM PROPERTIES ─── */
:root {
    /* Base Light Palette (Modern Warm Organic Cream - Latest Trending) */
    --bg-primary: #faf8f5;
    --bg-secondary: #f5f1ec;
    --bg-card: #ffffff;
    --bg-card-hover: #fffdfb;
    --bg-surface: rgba(255, 255, 255, 0.85);

    /* Text & Neutral Tokens */
    --text-main: #0f172a;
    --text-body: #1e293b;
    --text-muted: #475569;
    --text-light: #64748b;

    /* Primary Brand Accents */
    --red: #ef2028;
    --red-bright: #ff333a;
    --red-glow: rgba(239, 32, 40, 0.16);
    --red-dark: #b8141a;

    /* Secondary Accents */
    --green: #10b981;
    --green-muted: #059669;
    --green-glow: rgba(16, 185, 129, 0.16);

    --gold: #d97706;
    --gold-bright: #b45309;
    --gold-glow: rgba(217, 119, 6, 0.16);
    --amber: #f59e0b;

    /* Grayscale & Borders */
    --white: #ffffff;
    --gray-50: #f8fafc;
    --gray-100: #f1f5f9;
    --gray-200: #e2e8f0;
    --gray-300: #cbd5e1;
    --gray-400: #94a3b8;
    --gray-500: #64748b;
    --gray-600: #475569;
    --gray-700: #334155;
    --gray-800: #1e293b;
    --gray-900: #0f172a;

    --border: #e2dcd3;
    --border-light: #d4cdc3;

    /* Typography */
    --font-heading: 'Outfit', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    --font-body: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;

    /* Sizing & Spacing */
    --radius-sm: 6px;
    --radius-md: 12px;
    --radius-lg: 18px;
    --radius-xl: 24px;
    --radius-pill: 9999px;

    --container: 1280px;
    --gap: clamp(16px, 3vw, 24px);

    /* Transitions & Shadows */
    --transition: 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    --transition-fast: 0.15s ease;
    --shadow-subtle: 0 1px 3px rgba(0, 0, 0, 0.04), 0 1px 2px -1px rgba(0, 0, 0, 0.03);
    --shadow-card: 0 4px 20px -2px rgba(15, 23, 42, 0.05), 0 1px 3px rgba(0, 0, 0, 0.03);
    --shadow-hover: 0 20px 35px -10px rgba(15, 23, 42, 0.1), 0 0 20px rgba(239, 32, 40, 0.06);
    --shadow-floating: 0 16px 40px -10px rgba(15, 23, 42, 0.12), 0 0 1px rgba(15, 23, 42, 0.1);
}

/* ─── DARK THEME OVERRIDES (SWITCHABLE) ─── */
[data-theme="dark"] {
    --bg-primary: #090b10;
    --bg-secondary: #0f131a;
    --bg-card: #131720;
    --bg-card-hover: #191f2c;
    --bg-surface: rgba(19, 23, 32, 0.88);

    --text-main: #ffffff;
    --text-body: #f1f5f9;
    --text-muted: #cbd5e1;
    --text-light: #94a3b8;

    --border: #222836;
    --border-light: #2c3345;

    --gray-50: #0f131a;
    --gray-100: #131720;
    --gray-200: #191f2c;
    --gray-300: #222836;
    --gray-400: #64748b;
    --gray-500: #94a3b8;
    --gray-600: #cbd5e1;
    --gray-700: #e2e8f0;
    --gray-800: #f1f5f9;
    --gray-900: #ffffff;

    --shadow-card: 0 8px 30px rgba(0, 0, 0, 0.45);
    --shadow-hover: 0 20px 45px rgba(0, 0, 0, 0.65), 0 0 25px rgba(239, 32, 40, 0.15);
}

/* ─── RESET & BASE ─── */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
    width: 100%;
}

body {
    font-family: var(--font-body);
    font-size: 16px;
    font-weight: 450;
    line-height: 1.8;
    color: var(--text-body);
    background: var(--bg-primary);
    overflow-x: hidden;
    width: 100%;
    position: relative;
    text-rendering: optimizeLegibility;
    transition: background-color var(--transition), color var(--transition);
}

/* Helper Tokens for Text Highlight */
.text-highlight {
    color: var(--text-main);
    font-weight: 600;
}
.motto-highlight {
    color: var(--text-main);
    font-weight: 700;
}
[data-theme="dark"] .text-highlight {
    color: #ffffff;
}
[data-theme="dark"] .motto-highlight {
    color: var(--gold-bright);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    color: inherit;
    text-decoration: none;
    transition: color var(--transition);
}

button {
    cursor: pointer;
    border: none;
    background: none;
    font-family: inherit;
    color: inherit;
}

ul, ol { list-style: none; }

.container {
    width: 100%;
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 var(--gap);
}

/* ─── PRELOADER ─── */
#preloader {
    position: fixed;
    inset: 0;
    background: #090b10;
    z-index: 999999;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    transition: opacity 0.4s ease, visibility 0.4s ease;
}
#preloader.loaded {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}
.loader-content {
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
}
.loader-logo {
    width: 58px;
    height: auto;
    filter: drop-shadow(0 0 25px rgba(239, 32, 40, 0.4));
    animation: loaderPulse 1.6s infinite ease-in-out;
}
.loader-bar {
    width: 220px;
    height: 3px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 999px;
    overflow: hidden;
    position: relative;
}
.loader-progress {
    width: 0%;
    height: 100%;
    background: linear-gradient(90deg, var(--red), var(--gold));
    border-radius: 999px;
    transition: width 0.3s ease;
}
.loader-text {
    font-size: 11px;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: var(--gray-400);
    font-weight: 600;
}
@keyframes loaderPulse {
    0%, 100% { transform: scale(1); opacity: 0.9; }
    50% { transform: scale(1.08); opacity: 1; }
}

/* ═══════════════════════════════════════════════════════════════════
   1. TOP UTILITY STATUS BAR
   ═══════════════════════════════════════════════════════════════════ */
.topbar {
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border);
    padding: 7px 0;
    font-size: 12.5px;
    color: var(--text-muted);
    transition: background var(--transition), border-color var(--transition);
}
.topbar-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 10px;
}
.topbar-status-chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
    color: var(--text-main);
    font-size: 12px;
    letter-spacing: 0.2px;
}
.topbar-pulse-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--green);
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7);
    animation: topbarDotPulse 2s infinite;
}
@keyframes topbarDotPulse {
    0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7); }
    70% { transform: scale(1); box-shadow: 0 0 0 6px rgba(16, 185, 129, 0); }
    100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}
.topbar-contacts {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}
.topbar-item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    color: var(--text-body);
    text-decoration: none;
    padding: 3px 12px;
    border-radius: var(--radius-pill);
    background: var(--bg-card);
    border: 1px solid var(--border);
    font-weight: 500;
    transition: all 0.2s ease;
}
.topbar-item:hover {
    color: var(--text-main);
    background: var(--bg-secondary);
    border-color: rgba(239, 32, 40, 0.4);
    transform: translateY(-1px);
}
.topbar-item strong {
    color: var(--text-main);
    font-weight: 700;
}
.topbar-item svg {
    width: 13px;
    height: 13px;
    color: var(--red);
    flex-shrink: 0;
}

/* ═══════════════════════════════════════════════════════════════════
   2. FLOATING ISLAND NAVBAR
   ═══════════════════════════════════════════════════════════════════ */
.navbar-wrapper {
    position: sticky;
    top: 0;
    z-index: 1000;
    width: 100%;
    pointer-events: none;
    padding: 12px 16px 0;
}
.navbar {
    pointer-events: auto;
    max-width: var(--container);
    margin: 0 auto;
    padding: 8px 20px;
    background: rgba(255, 255, 255, 0.94);
    backdrop-filter: blur(24px) saturate(190%);
    -webkit-backdrop-filter: blur(24px) saturate(190%);
    border: 1px solid var(--border);
    border-radius: var(--radius-pill);
    box-shadow: 0 10px 30px -5px rgba(15, 23, 42, 0.08), 0 0 1px rgba(15, 23, 42, 0.1);
    transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}
[data-theme="dark"] .navbar {
    background: rgba(13, 17, 24, 0.92);
    border-color: rgba(255, 255, 255, 0.1);
    box-shadow: 0 16px 45px rgba(0, 0, 0, 0.55), 0 0 25px rgba(239, 32, 40, 0.1);
}
.navbar.scrolled {
    padding: 6px 18px;
    box-shadow: 0 16px 40px -10px rgba(15, 23, 42, 0.14);
}
.nav-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
}
.nav-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    flex-shrink: 0;
}
.nav-logo-emblem-wrap {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}
.nav-logo img {
    height: 38px;
    width: auto;
    max-width: 58px;
    object-fit: contain;
    filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.2));
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.nav-logo:hover img {
    transform: scale(1.08) rotate(-2deg);
}
.nav-logo-text {
    display: flex;
    flex-direction: column;
}
.nav-logo-tagline {
    font-size: 8px;
    font-weight: 700;
    letter-spacing: 0.8px;
    text-transform: uppercase;
    color: var(--gold);
    line-height: 1;
    margin-bottom: 2px;
}
.nav-logo-brand {
    font-family: var(--font-heading);
    font-size: clamp(16px, 2vw, 19px);
    color: var(--text-main);
    line-height: 1.1;
    letter-spacing: 0.4px;
    display: flex;
    align-items: center;
}
.brand-accent {
    background: linear-gradient(135deg, #ef2028 0%, #ff4d54 50%, #d4a72c 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}
.nav-logo-sub {
    font-size: 7.5px;
    letter-spacing: 1.2px;
    text-transform: uppercase;
    color: var(--text-muted);
    font-weight: 800;
    line-height: 1.2;
}

/* Nav Links */
.nav-links {
    display: flex;
    align-items: center;
    gap: 3px;
    list-style: none;
}
.nav-link {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 7px 14px;
    font-size: 13.5px;
    font-weight: 500;
    color: var(--text-body);
    border-radius: var(--radius-pill);
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
    position: relative;
    text-decoration: none;
}
.nav-link:hover {
    color: var(--text-main);
    background: var(--bg-secondary);
    transform: translateY(-1px);
}
.nav-link.active {
    color: var(--red);
    background: rgba(239, 32, 40, 0.08);
    border: 1px solid rgba(239, 32, 40, 0.2);
    font-weight: 600;
}
[data-theme="dark"] .nav-link.active {
    color: #ffffff;
    background: rgba(239, 32, 40, 0.22);
    border-color: rgba(239, 32, 40, 0.45);
}

/* Nav Actions */
.nav-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}


/* Theme Toggle Button */
.theme-toggle-btn {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    color: var(--amber);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.25s ease;
    flex-shrink: 0;
}
.theme-toggle-btn:hover {
    transform: rotate(20deg) scale(1.08);
    background: rgba(245, 158, 11, 0.15);
    border-color: var(--amber);
    box-shadow: 0 0 14px rgba(245, 158, 11, 0.3);
}
.theme-icon-sun {
    width: 18px;
    height: 18px;
    display: none;
}
.theme-icon-moon {
    width: 18px;
    height: 18px;
    display: block;
}
[data-theme="dark"] .theme-icon-sun { display: block; color: var(--gold-bright); }
[data-theme="dark"] .theme-icon-moon { display: none; }
[data-theme="dark"] .theme-toggle-btn {
    background: rgba(255, 255, 255, 0.08);
    border-color: var(--border);
}

/* CTA Return to Home */
.btn-nav-cta {
    position: relative;
    overflow: hidden;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 18px;
    border-radius: var(--radius-pill);
    background: linear-gradient(135deg, #ef2028 0%, #d8141b 100%);
    color: #ffffff !important;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.3px;
    text-decoration: none;
    box-shadow: 0 4px 18px rgba(239, 32, 40, 0.35);
    transition: all 0.25s ease;
    flex-shrink: 0;
}
.btn-nav-cta:hover {
    transform: translateY(-1px) scale(1.02);
    box-shadow: 0 6px 24px rgba(239, 32, 40, 0.55);
}

/* Mobile Hamburger */
.nav-hamburger {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px;
    width: 40px;
    height: 40px;
    border-radius: 8px;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    cursor: pointer;
}
.nav-hamburger span {
    display: block;
    width: 20px;
    height: 2px;
    background: var(--text-main);
    border-radius: 2px;
    transition: all 0.3s ease;
}
.nav-hamburger.open span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.nav-hamburger.open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.nav-hamburger.open span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }

/* ─── MOBILE NAV DRAWER ─── */
.mobile-nav-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    z-index: 9998;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}
.mobile-nav-overlay.open {
    opacity: 1;
    visibility: visible;
}
.mobile-nav {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    width: min(340px, 86vw);
    background: var(--bg-card);
    z-index: 9999;
    padding: 24px 20px 40px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    box-shadow: -10px 0 40px rgba(0, 0, 0, 0.3);
    transform: translateX(100%);
    transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
    overflow-y: auto;
    border-left: 1px solid var(--border);
}
.mobile-nav.open {
    transform: translateX(0);
}
.mobile-nav-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--border);
    margin-bottom: 10px;
}
.mobile-nav-brand {
    display: flex;
    align-items: center;
    gap: 10px;
}
.mobile-brand-name {
    font-family: var(--font-heading);
    font-size: 16px;
    color: var(--text-main);
}
.mobile-brand-name span { color: var(--red); }
.mobile-brand-sub {
    font-size: 8px;
    letter-spacing: 1px;
    color: var(--text-muted);
    display: block;
    font-weight: 700;
}
.mobile-nav-close {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    color: var(--text-main);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
}
.mobile-nav-link {
    font-size: 14.5px;
    font-weight: 600;
    color: var(--text-body);
    padding: 10px 14px;
    border-radius: var(--radius-sm);
    transition: all 0.2s ease;
}
.mobile-nav-link:hover, .mobile-nav-link.active {
    background: rgba(239, 32, 40, 0.08);
    color: var(--red);
}
.mobile-nav-group-title {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 1.2px;
    color: var(--text-muted);
    font-weight: 700;
    margin-top: 14px;
    padding-left: 14px;
}
.mobile-nav-sub {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding-left: 14px;
}
.mobile-nav-sub a {
    font-size: 13px;
    color: var(--text-body);
    padding: 7px 10px;
    border-radius: var(--radius-sm);
    transition: all 0.2s ease;
}
.mobile-nav-sub a:hover, .mobile-nav-sub a.active {
    color: var(--red);
    background: var(--bg-secondary);
}
.mobile-nav-actions {
    margin-top: auto;
    padding-top: 20px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    border-top: 1px solid var(--border);
}
.btn-mobile-theme {
    width: 100%;
    justify-content: center;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    padding: 11px 18px;
    border-radius: 12px;
    font-weight: 600;
    font-size: 13px;
    gap: 8px;
    display: inline-flex;
    align-items: center;
    color: var(--text-main);
}
.btn-mobile-wa {
    background: #25D366;
    color: #ffffff;
    padding: 11px 18px;
    border-radius: 12px;
    font-weight: 700;
    font-size: 13.5px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

/* ═══════════════════════════════════════════════════════════════════
   3. HERO SECTION & BREADCRUMBS
   ═══════════════════════════════════════════════════════════════════ */
.policy-hero {
    padding: clamp(50px, 8vw, 85px) 0 clamp(35px, 5vw, 55px);
    background: linear-gradient(180deg, var(--bg-secondary) 0%, var(--bg-primary) 100%);
    border-bottom: 1px solid var(--border);
    position: relative;
    overflow: hidden;
}
.policy-hero::before {
    content: '';
    position: absolute;
    top: -100px;
    right: -100px;
    width: 450px;
    height: 450px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(239, 32, 40, 0.08) 0%, transparent 70%);
    pointer-events: none;
}
.breadcrumbs {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: var(--text-muted);
    margin-bottom: 18px;
    flex-wrap: wrap;
}
.breadcrumbs a {
    color: var(--text-body);
    transition: color 0.2s ease;
}
.breadcrumbs a:hover {
    color: var(--red);
}
.breadcrumbs .crumb-sep {
    color: var(--gray-400);
    font-size: 11px;
}
.breadcrumbs .crumb-current {
    color: var(--red);
    font-weight: 600;
}

.policy-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px;
    background: rgba(239, 32, 40, 0.1);
    border: 1px solid rgba(239, 32, 40, 0.25);
    border-radius: var(--radius-pill);
    color: var(--red);
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 16px;
}
.policy-badge svg {
    width: 14px;
    height: 14px;
}
.policy-title {
    font-family: var(--font-heading);
    font-size: clamp(32px, 5vw, 52px);
    color: var(--text-main);
    line-height: 1.15;
    margin-bottom: 14px;
    letter-spacing: -0.5px;
}
.policy-subtitle {
    font-size: clamp(15.5px, 1.8vw, 17.5px);
    font-weight: 450;
    color: var(--text-body);
    max-width: 820px;
    line-height: 1.7;
    margin-bottom: 22px;
}
.policy-meta-wrap {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    align-items: center;
}
.policy-meta-pill {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 5px 14px;
    border-radius: var(--radius-pill);
    background: var(--bg-card);
    border: 1px solid var(--border);
    font-size: 12.5px;
    color: var(--text-muted);
    font-weight: 500;
}
.policy-meta-pill strong {
    color: var(--text-main);
}
.meta-status-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--green);
    box-shadow: 0 0 6px var(--green);
}

/* Legal Hub Quick Switcher Tabs */
.legal-hub-switcher {
    margin-top: 32px;
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 4px;
    scrollbar-width: none;
    -ms-overflow-style: none;
}
.legal-hub-switcher::-webkit-scrollbar { display: none; }
.legal-hub-tab {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 9px 18px;
    border-radius: var(--radius-pill);
    font-size: 13.5px;
    font-weight: 600;
    background: var(--bg-card);
    border: 1px solid var(--border);
    color: var(--text-body);
    white-space: nowrap;
    transition: all 0.25s ease;
}
.legal-hub-tab:hover {
    color: var(--text-main);
    border-color: rgba(239, 32, 40, 0.4);
    transform: translateY(-1px);
}
.legal-hub-tab.active {
    background: linear-gradient(135deg, #ef2028 0%, #b8141a 100%);
    color: #ffffff;
    border-color: var(--red);
    box-shadow: 0 4px 15px rgba(239, 32, 40, 0.35);
}

/* ═══════════════════════════════════════════════════════════════════
   4. POLICY BODY LAYOUT & MOBILE COLLAPSIBLE TOC
   ═══════════════════════════════════════════════════════════════════ */
.policy-content {
    padding: clamp(40px, 6vw, 80px) 0 clamp(60px, 8vw, 110px);
}
.policy-grid {
    display: grid;
    grid-template-columns: 290px 1fr;
    gap: clamp(24px, 4vw, 50px);
    align-items: start;
}

/* Mobile Collapsible TOC Trigger Bar */
.mobile-toc-bar {
    display: none;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    margin-bottom: 24px;
    overflow: hidden;
    box-shadow: var(--shadow-subtle);
}
.mobile-toc-toggle {
    width: 100%;
    padding: 14px 18px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 14px;
    font-weight: 700;
    color: var(--text-main);
    text-align: left;
}
.mobile-toc-toggle svg {
    width: 18px;
    height: 18px;
    color: var(--red);
    transition: transform 0.3s ease;
}
.mobile-toc-toggle.expanded svg {
    transform: rotate(180deg);
}
.mobile-toc-drawer {
    display: none;
    padding: 0 16px 16px;
    border-top: 1px solid var(--border);
}
.mobile-toc-drawer.open {
    display: block;
}
.mobile-toc-drawer a {
    display: block;
    padding: 9px 12px;
    font-size: 13.5px;
    color: var(--text-body);
    border-radius: var(--radius-sm);
    transition: all 0.2s ease;
}
.mobile-toc-drawer a:hover, .mobile-toc-drawer a.active {
    color: var(--red);
    background: rgba(239, 32, 40, 0.08);
    font-weight: 600;
}

/* Desktop Sticky Sidebar */
.policy-sidebar {
    position: sticky;
    top: 90px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 22px;
    box-shadow: var(--shadow-card);
    max-height: calc(100vh - 120px);
    overflow-y: auto;
}
.policy-sidebar-title {
    font-family: var(--font-heading);
    font-size: 13px;
    color: var(--text-main);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 14px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    gap: 8px;
}
.policy-sidebar-title svg {
    width: 14px;
    height: 14px;
    color: var(--red);
}
.policy-toc {
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.policy-toc a {
    font-size: 13px;
    color: var(--text-body);
    text-decoration: none;
    padding: 8px 12px;
    border-radius: var(--radius-sm);
    transition: all 0.2s ease;
    line-height: 1.4;
    display: flex;
    align-items: center;
}
.policy-toc a:hover {
    color: var(--red);
    background: rgba(239, 32, 40, 0.08);
    padding-left: 16px;
}
.policy-toc a.active {
    color: var(--red);
    background: rgba(239, 32, 40, 0.12);
    font-weight: 700;
    border-left: 3px solid var(--red);
    padding-left: 14px;
}

/* Policy Article Card */
.policy-article {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: clamp(24px, 4vw, 48px);
    box-shadow: var(--shadow-card);
}
.policy-highlight {
    background: rgba(239, 32, 40, 0.08);
    border-left: 4px solid var(--red);
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
    padding: 18px 22px;
    margin: 24px 0;
    font-size: 15.5px;
    font-weight: 500;
    color: var(--text-main);
    line-height: 1.75;
    box-shadow: 0 2px 8px rgba(239, 32, 40, 0.06);
}
[data-theme="dark"] .policy-highlight {
    background: rgba(239, 32, 40, 0.15);
    color: #ffffff;
}
.policy-highlight a {
    color: var(--red);
    font-weight: 700;
    text-decoration: underline;
}

.policy-article h2 {
    font-family: var(--font-heading);
    font-size: clamp(20px, 2.5vw, 25px);
    color: var(--text-main);
    margin: 44px 0 16px;
    padding-top: 24px;
    border-top: 1px solid var(--border);
    display: flex;
    align-items: center;
    gap: 12px;
    line-height: 1.25;
}
.policy-article h2:first-of-type {
    margin-top: 0;
    padding-top: 0;
    border-top: none;
}
.policy-article h2 span.sec-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 34px;
    height: 34px;
    padding: 0 8px;
    border-radius: 8px;
    background: rgba(239, 32, 40, 0.1);
    color: var(--red);
    font-size: 15px;
    font-weight: 800;
}
.policy-article h3 {
    font-size: 17px;
    color: var(--gold);
    margin: 26px 0 10px;
    font-weight: 700;
}
[data-theme="dark"] .policy-article h3 {
    color: #f59e0b;
}
.policy-article p {
    margin-bottom: 16px;
    color: var(--text-body);
    font-size: 16px;
    font-weight: 450;
    line-height: 1.8;
}
.policy-article ul {
    margin: 14px 0 22px 20px;
    list-style: disc;
}
.policy-article li {
    margin-bottom: 10px;
    color: var(--text-body);
    font-size: 15.5px;
    font-weight: 450;
    line-height: 1.75;
}
.policy-article li strong {
    color: var(--text-main);
    font-weight: 700;
}

/* Contact Officer Box */
.policy-contact-box {
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 24px;
    margin-top: 24px;
}
.policy-contact-box h4 {
    font-family: var(--font-heading);
    font-size: 16px;
    color: var(--text-main);
    margin-bottom: 12px;
}
.policy-contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 16px;
    margin-top: 14px;
}
.policy-contact-item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: 14px;
    color: var(--text-body);
}
.policy-contact-item svg {
    width: 18px;
    height: 18px;
    color: var(--red);
    flex-shrink: 0;
    margin-top: 3px;
}
.policy-contact-item a {
    color: var(--red);
    font-weight: 600;
}
.policy-contact-item a:hover {
    text-decoration: underline;
}

/* ─── COOKIE INVENTORY TABLE ─── */
.cookie-table-wrapper {
    width: 100%;
    overflow-x: auto;
    margin: 24px 0 32px;
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
    background: var(--bg-card);
}
.cookie-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13.5px;
    text-align: left;
}
.cookie-table th {
    background: var(--bg-secondary);
    color: var(--text-main);
    font-weight: 700;
    padding: 14px 16px;
    border-bottom: 2px solid var(--border);
    white-space: nowrap;
}
.cookie-table td {
    padding: 13px 16px;
    border-bottom: 1px solid var(--border);
    color: var(--text-body);
    vertical-align: middle;
}
.cookie-table tr:last-child td {
    border-bottom: none;
}
.cookie-table tr:hover td {
    background: var(--bg-secondary);
}
.cookie-table code {
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    font-size: 12.5px;
    color: var(--red);
    background: rgba(239, 32, 40, 0.08);
    padding: 2px 7px;
    border-radius: 4px;
    font-weight: 600;
}
.badge-cookie-type {
    display: inline-block;
    padding: 3px 8px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.badge-essential { background: rgba(16, 185, 129, 0.14); color: #059669; }
.badge-analytics { background: rgba(59, 130, 246, 0.14); color: #2563eb; }
.badge-functional { background: rgba(245, 158, 11, 0.14); color: #d97706; }
[data-theme="dark"] .badge-essential { color: #34d399; }
[data-theme="dark"] .badge-analytics { color: #60a5fa; }
[data-theme="dark"] .badge-functional { color: #fbbf24; }

/* ═══════════════════════════════════════════════════════════════════
   5. COMPREHENSIVE 5-COLUMN FOOTER
   ═══════════════════════════════════════════════════════════════════ */
.footer {
    background: #090b10;
    border-top: 1px solid #1a202c;
    color: #94a3b8;
    padding: clamp(50px, 8vw, 80px) 0 24px;
    position: relative;
    font-size: 14px;
}
.footer-top {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr 1fr;
    gap: clamp(24px, 3.5vw, 44px);
    margin-bottom: 48px;
}
.footer-col {
    display: flex;
    flex-direction: column;
}
.footer-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}
.footer-brand img {
    height: 44px;
    width: auto;
}
.footer-brand-name {
    font-family: var(--font-heading);
    font-size: 18px;
    color: #ffffff;
    line-height: 1.1;
    display: block;
}
.footer-brand-sub {
    font-size: 7.5px;
    letter-spacing: 1.2px;
    text-transform: uppercase;
    color: #cbd5e1;
    font-weight: 700;
}
.footer-about-text {
    font-size: 13.5px;
    line-height: 1.7;
    color: #cbd5e1;
    font-weight: 450;
    margin-bottom: 22px;
    max-width: 320px;
}
.footer-social-heading {
    font-size: 11.5px;
    letter-spacing: 1px;
    text-transform: uppercase;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 12px;
}
.footer-socials {
    display: flex;
    align-items: center;
    gap: 10px;
}
.footer-social-link {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.12);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.25s ease;
    color: #cbd5e1;
}
.footer-social-link svg {
    width: 17px;
    height: 17px;
    fill: currentColor;
}
.footer-social-link.social-fb:hover { background: #1877F2; border-color: #1877F2; color: #ffffff; box-shadow: 0 4px 16px rgba(24, 119, 242, 0.5); }
.footer-social-link.social-wa:hover { background: #25D366; border-color: #25D366; color: #ffffff; box-shadow: 0 4px 16px rgba(37, 211, 102, 0.5); }
.footer-social-link.social-ig:hover { background: #E1306C; border-color: #E1306C; color: #ffffff; box-shadow: 0 4px 16px rgba(225, 48, 108, 0.5); }
.footer-social-link.social-yt:hover { background: #FF0000; border-color: #FF0000; color: #ffffff; box-shadow: 0 4px 16px rgba(255, 0, 0, 0.5); }
.footer-social-link.social-li:hover { background: #0A66C2; border-color: #0A66C2; color: #ffffff; box-shadow: 0 4px 16px rgba(10, 102, 194, 0.5); }

.footer-col-title {
    font-family: var(--font-heading);
    font-size: 14.5px;
    color: #ffffff;
    margin-bottom: 18px;
    letter-spacing: 0.3px;
}
.footer-nav a {
    display: block;
    font-size: 13.5px;
    font-weight: 500;
    color: #cbd5e1;
    padding: 5px 0;
    transition: all 0.2s ease;
}
.footer-nav a:hover {
    color: #ff4d54;
    transform: translateX(3px);
}
.footer-nav a.active {
    color: #ef2028;
    font-weight: 700;
}

.footer-bottom {
    padding-top: 24px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
}
.footer-copyright {
    font-size: 13px;
    color: #94a3b8;
    font-weight: 500;
    line-height: 1.6;
}
.footer-credit-link {
    color: #fbbf24;
    font-weight: 800;
    text-decoration: none;
    letter-spacing: 0.6px;
    padding: 0;
    background: none;
    border: none;
    border-radius: 0;
    transition: all 0.25s ease;
    display: inline;
    text-shadow: 0 0 10px rgba(251, 191, 36, 0.65), 0 0 20px rgba(245, 158, 11, 0.4), 0 0 30px rgba(217, 119, 6, 0.25);
}
.footer-credit-link:hover {
    color: #fde047;
    text-shadow: 0 0 14px rgba(253, 224, 71, 0.85), 0 0 25px rgba(251, 191, 36, 0.6), 0 0 40px rgba(245, 158, 11, 0.4);
    transform: none;
}
.heart-pulse {
    display: inline-block;
    animation: heartBeat 1.4s infinite ease-in-out;
}
@keyframes heartBeat {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.25); }
}
.footer-hours {
    font-size: 13px;
    color: #cbd5e1;
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 500;
}

/* ═══════════════════════════════════════════════════════════════════
   6. FLOATING ACTIONS & SCROLL CONTROLS
   ═══════════════════════════════════════════════════════════════════ */
.float-whatsapp {
    position: fixed;
    bottom: 22px;
    right: 22px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: #25D366;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 990;
    box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4);
    transition: all 0.3s ease;
    color: #ffffff;
}
.float-whatsapp:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 28px rgba(37, 211, 102, 0.6);
}
.float-whatsapp svg {
    width: 26px;
    height: 26px;
}

.back-to-top {
    position: fixed;
    bottom: 82px;
    right: 22px;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--bg-card);
    border: 1px solid var(--border);
    color: var(--text-main);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 989;
    opacity: 0;
    visibility: hidden;
    transition: all 0.25s ease;
    box-shadow: var(--shadow-card);
}
.back-to-top.visible {
    opacity: 1;
    visibility: visible;
}
.back-to-top:hover {
    background: var(--red);
    border-color: var(--red);
    color: #ffffff;
    transform: translateY(-3px);
}
.back-to-top svg {
    width: 20px;
    height: 20px;
}

/* ═══════════════════════════════════════════════════════════════════
   7. RESPONSIVE BREAKPOINTS (MOBILE & TABLET OPTIMIZATIONS)
   ═══════════════════════════════════════════════════════════════════ */
@media (max-width: 1024px) {
    .footer-top {
        grid-template-columns: 1fr 1fr 1fr;
    }
    .footer-col:first-child {
        grid-column: span 3;
        margin-bottom: 10px;
    }
    .nav-links {
        display: none;
    }
    .nav-hamburger {
        display: flex;
    }
    .btn-nav-cta {
        display: none;
    }
}

@media (max-width: 880px) {
    .policy-grid {
        grid-template-columns: 1fr;
    }
    .policy-sidebar {
        display: none;
    }
    .mobile-toc-bar {
        display: block;
    }
    .footer-top {
        grid-template-columns: 1fr 1fr;
    }
    .footer-col:first-child {
        grid-column: span 2;
    }
}

@media (max-width: 640px) {
    .topbar-container {
        justify-content: center;
        text-align: center;
    }
    .topbar-status-chip {
        display: none;
    }
    .topbar-contacts {
        justify-content: center;
        width: 100%;
    }
    .policy-hero {
        padding: 40px 0 30px;
    }
    .policy-article {
        padding: 20px 16px;
    }
    .policy-article h2 {
        font-size: 19px;
        gap: 8px;
    }
    .policy-article h2 span.sec-num {
        min-width: 28px;
        height: 28px;
        font-size: 13px;
    }
    .footer-top {
        grid-template-columns: 1fr;
    }
    .footer-col:first-child {
        grid-column: span 1;
    }
    .footer-bottom {
        flex-direction: column;
        text-align: center;
        align-items: center;
    }
    .footer-socials {
        justify-content: flex-start;
    }
}
