/* =========================================
   COMPONENTS · navbar, buttons, badges, toast, chatbot
   ========================================= */

/* NAVBAR · Header mejorado 2026 */
.navbar {
    background: linear-gradient(
        180deg,
        rgba(15, 23, 42, 0.98) 0%,
        rgba(15, 23, 42, 0.92) 100%
    );
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    padding: 14px 5%;
    position: sticky; top: 0; z-index: 1000;
    display: flex; align-items: center; gap: 14px;
    border-bottom: 1px solid rgba(255,255,255,0.12);
    flex-wrap: wrap;
    box-shadow: 
        0 4px 24px rgba(0,0,0,0.3),
        inset 0 -1px 0 rgba(255,255,255,0.05);
    transition: all 0.3s ease;
}

/* Efecto de línea de colores Colombia en el top */
.navbar::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(
        90deg,
        var(--co-yellow) 0%,
        var(--co-yellow) 33%,
        var(--co-blue) 33%,
        var(--co-blue) 66%,
        var(--co-red) 66%,
        var(--co-red) 100%
    );
    box-shadow: 0 2px 8px rgba(252,209,22,0.4);
}

/* Navbar se eleva al hacer scroll */
.navbar.scrolled {
    padding: 10px 5%;
    box-shadow: 
        0 8px 32px rgba(0,0,0,0.4),
        inset 0 -1px 0 rgba(255,255,255,0.05);
}

.navbar .brand {
    display: inline-flex; align-items: center; gap: 10px;
    color: #fff; text-decoration: none;
    font-family: 'Outfit', sans-serif; font-weight: 800;
    font-size: 14px; letter-spacing: -0.2px;
    position: relative;
    transition: all 0.3s ease;
}

.navbar .brand svg { 
    width: 130px; height: 32px; color: #fff; flex-shrink: 0;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.3));
}

.navbar .brand:hover {
    transform: scale(1.02);
}

.navbar .nav-links {
    display: flex; gap: 4px; flex-wrap: wrap; flex: 1;
    justify-content: center;
}

.navbar .nav-links a {
    font-family: 'Outfit', sans-serif; color: rgba(255,255,255,0.85);
    text-decoration: none; font-weight: 600; font-size: 13px;
    padding: 8px 14px; border-radius: 20px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    white-space: nowrap;
    position: relative;
    overflow: hidden;
}

/* Efecto de brillo en hover */
.navbar .nav-links a::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255,255,255,0.15),
        transparent
    );
    transition: left 0.5s ease;
}

.navbar .nav-links a:hover::before {
    left: 100%;
}

.navbar .nav-links a:hover,
.navbar .nav-links a:focus-visible {
    color: #fff; background: rgba(59,130,246,0.25);
    transform: translateY(-2px);
    box-shadow: 
        0 4px 16px rgba(59,130,246,0.4),
        inset 0 0 0 1px rgba(59,130,246,0.3);
    outline: none;
}

/* Estado activo más visible */
.navbar .nav-links a.active {
    background: rgba(59,130,246,0.3);
    color: #fff;
    box-shadow: 
        0 2px 12px rgba(59,130,246,0.3),
        inset 0 0 0 1px rgba(59,130,246,0.5);
}

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

.theme-toggle {
    background: rgba(255,255,255,0.12); 
    border: 1px solid rgba(255,255,255,0.2);
    color: #fff; width: 38px; height: 38px; border-radius: 50%;
    cursor: pointer; display: inline-flex; align-items: center; justify-content: center;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.theme-toggle::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(
        circle,
        rgba(255,255,255,0.2) 0%,
        transparent 70%
    );
    opacity: 0;
    transition: opacity 0.3s ease;
}

.theme-toggle:hover::before {
    opacity: 1;
}

.theme-toggle:hover { 
    background: rgba(255,255,255,0.25); 
    transform: scale(1.1) rotate(15deg);
    box-shadow: 0 4px 16px rgba(255,255,255,0.2);
    border-color: rgba(255,255,255,0.3);
}

/* HERO */
.hero {
    position: relative;
    padding: 64px 5% 50px 5%;
    overflow: hidden;
    background:
        radial-gradient(circle at 20% 0%, rgba(252,209,22,0.18), transparent 50%),
        radial-gradient(circle at 80% 100%, rgba(206,17,38,0.18), transparent 55%),
        linear-gradient(180deg, transparent 0%, rgba(0,56,147,0.05) 100%);
}
/* Patrón de fondo sutil para dar textura */
.hero::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image:
        repeating-linear-gradient(45deg, rgba(0,56,147,0.02) 0px, rgba(0,56,147,0.02) 2px, transparent 2px, transparent 12px);
    pointer-events: none;
    opacity: 0.5;
}
body.dark .hero {
    background:
        radial-gradient(circle at 20% 0%, rgba(252,209,22,0.12), transparent 50%),
        radial-gradient(circle at 80% 100%, rgba(206,17,38,0.18), transparent 55%),
        linear-gradient(180deg, transparent 0%, rgba(0,56,147,0.1) 100%);
}
.hero::before {
    content: '';
    position: absolute; top: 0; left: 0; right: 0; height: 6px;
    background: linear-gradient(to right,
        var(--co-yellow) 0%, var(--co-yellow) 50%,
        var(--co-blue) 50%, var(--co-blue) 75%,
        var(--co-red) 75%, var(--co-red) 100%);
}

.hero-inner {
    max-width: 1400px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1.3fr 1fr;
    gap: 48px;
    align-items: center;
}
.hero-content {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}
.hero-logo-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
    margin-bottom: 8px;
}
.hero-logo {
    width: 104px;
    height: 104px;
    background: linear-gradient(
        135deg,
        #fff 0%,
        rgba(255,255,255,0.95) 100%
    );
    border-radius: 50%;
    box-shadow: 
        0 18px 40px rgba(0,56,147,0.25),
        0 0 0 8px rgba(255,255,255,0.1),
        inset 0 2px 8px rgba(255,255,255,0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    position: relative;
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.hero-logo::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(
        circle,
        rgba(252,209,22,0.15) 0%,
        transparent 70%
    );
    animation: rotate 20s linear infinite;
}

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

.hero-logo:hover {
    transform: scale(1.05);
    box-shadow: 
        0 24px 56px rgba(0,56,147,0.35),
        0 0 0 12px rgba(255,255,255,0.15),
        inset 0 2px 8px rgba(255,255,255,0.8);
}

.hero-logo svg { 
    width: 88px; height: 88px;
    position: relative;
    z-index: 1;
    filter: drop-shadow(0 2px 8px rgba(0,0,0,0.15));
}
.hero-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-family: 'Outfit', sans-serif;
    font-size: 13px;
    font-weight: 700;
    color: var(--co-blue);
    background: rgba(0,56,147,0.08);
    padding: 6px 14px;
    border-radius: 20px;
    letter-spacing: 0.8px;
    text-transform: uppercase;
}
body.dark .hero-eyebrow { color: #93c5fd; background: rgba(59,130,246,0.15); }
.hero h1 {
    font-family: 'Outfit', sans-serif;
    font-size: clamp(34px, 5vw, 56px);
    font-weight: 800;
    line-height: 1.05;
    letter-spacing: -1.5px;
    color: var(--primary);
    margin: 0 0 18px 0;
}
.hero h1 .accent {
    background: linear-gradient(90deg, var(--co-yellow), var(--co-red));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}
.hero-lead {
    font-size: 16px;
    line-height: 1.7;
    color: var(--text-light);
    max-width: 620px;
    margin: 0 0 26px 0;
    font-weight: 400;
}
.hero-cta {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

/* CANDIDATE SLIDER */
.candidate-slider {
    margin-bottom: 20px;
    position: relative;
}
.candidate-slide {
    display: none;
    animation: fadeIn 0.4s ease;
}
.candidate-slide.active { display: block; }
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(4px); }
    to { opacity: 1; transform: translateY(0); }
}
.candidate-card-mini {
    background: var(--card-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--card-border);
    border-radius: 18px;
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 16px;
    box-shadow: 0 14px 40px rgba(0,0,0,0.05);
    position: relative;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.candidate-card-mini:hover {
    transform: translateY(-3px);
    box-shadow: 0 18px 48px rgba(0,0,0,0.08);
}
.candidate-card-mini::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    width: 4px;
    height: 100%;
    background: var(--ccolor);
}
.candidate-avatar {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--ccolor) 0%, color-mix(in srgb, var(--ccolor) 60%, #000) 100%);
    box-shadow: 0 6px 16px rgba(0,0,0,0.15);
    flex-shrink: 0;
    overflow: hidden;
    border: 2px solid rgba(255,255,255,0.2);
}
.candidate-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.candidate-initials {
    font-family: 'Outfit', sans-serif;
    font-weight: 800;
    font-size: 22px;
    color: #fff;
    letter-spacing: -1px;
}
.candidate-mini-info { flex: 1; min-width: 0; }
.candidate-party {
    display: inline-block;
    font-family: 'Outfit', sans-serif;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    color: var(--ccolor);
    background: color-mix(in srgb, var(--ccolor) 14%, transparent);
    padding: 3px 10px;
    border-radius: 12px;
    margin-bottom: 6px;
}
.candidate-mini-name {
    font-family: 'Outfit', sans-serif;
    font-size: 17px;
    font-weight: 700;
    color: var(--primary);
    margin: 0 0 4px 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.candidate-slogan {
    font-size: 13px;
    font-style: italic;
    color: var(--text-light);
    margin: 0;
    line-height: 1.4;
}
.candidate-slider-controls {
    display: flex;
    gap: 8px;
    justify-content: center;
    margin-top: 14px;
}
.slider-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    border: 2px solid rgba(15, 23, 42, 0.35);
    background: rgba(15, 23, 42, 0.12);
    cursor: pointer;
    padding: 0;
    transition: all 0.25s ease;
}
.slider-dot.active {
    background: var(--highlight);
    border-color: var(--highlight);
    transform: scale(1.25);
    box-shadow: 0 0 0 3px rgba(59,130,246,0.18);
}
.slider-dot:hover {
    border-color: var(--highlight);
    background: rgba(59,130,246,0.25);
}
body.dark .slider-dot {
    border-color: rgba(255,255,255,0.45);
    background: rgba(255,255,255,0.12);
}

/* HERO STATS */
.hero-aside {
    display: flex;
    flex-direction: column;
    gap: 16px;
}
.live-badge {
    background: linear-gradient(90deg, #f43f5e, #e11d48);
    color: white;
    padding: 8px 16px;
    border-radius: 24px;
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
    font-size: 11px;
    letter-spacing: 1px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 15px rgba(244,63,94,0.3);
    width: fit-content;
}
.pulse-dot {
    width: 8px;
    height: 8px;
    background: #fff;
    border-radius: 50%;
    animation: pulse 2s infinite;
}
@keyframes pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(1.2); }
}
.hero-stat {
    background: var(--card-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--card-border);
    border-radius: 18px;
    padding: 20px;
    box-shadow: 0 14px 40px rgba(0,0,0,0.05);
}
.hero-stat-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}
.hero-stat .label {
    font-family: 'Outfit', sans-serif;
    font-size: 10px;
    font-weight: 600;
    color: var(--text-light);
    text-transform: uppercase;
    letter-spacing: 0.6px;
    margin-bottom: 4px;
}
.hero-stat .value {
    font-family: 'Outfit', sans-serif;
    font-size: 26px;
    font-weight: 800;
    color: var(--primary);
    line-height: 1;
}
.hero-stat .sub {
    font-size: 11px;
    color: var(--text-light);
    margin-top: 4px;
    line-height: 1.3;
}
.hero-logo {
    width: 96px; height: 96px;
    background: #fff; border-radius: 50%;
    box-shadow: 0 18px 40px rgba(0,56,147,0.25);
    margin-bottom: 22px;
    display: inline-flex; align-items: center; justify-content: center;
    overflow: hidden;
}
.hero-logo svg { width: 80px; height: 80px; }
.hero-eyebrow {
    display: inline-flex; align-items: center; gap: 8px;
    font-family: 'Outfit', sans-serif; font-size: 13px; font-weight: 700;
    color: var(--co-blue); background: rgba(0,56,147,0.08);
    padding: 6px 14px; border-radius: 20px;
    letter-spacing: 0.8px; text-transform: uppercase;
    margin-bottom: 16px;
}
body.dark .hero-eyebrow { color: #93c5fd; background: rgba(59,130,246,0.15); }
.hero h1 {
    font-family: 'Outfit', sans-serif;
    font-size: clamp(34px, 5vw, 56px);
    font-weight: 800; line-height: 1.05; letter-spacing: -1.5px;
    color: var(--primary); margin: 0 0 18px 0;
}
.hero h1 .accent {
    background: linear-gradient(90deg, var(--co-yellow), var(--co-red));
    -webkit-background-clip: text; background-clip: text;
    -webkit-text-fill-color: transparent;
}
.hero-lead {
    font-size: 17px; line-height: 1.6; color: var(--text-light);
    max-width: 580px; margin: 0 0 24px 0; font-weight: 400;
}
.hero-cta { display: flex; gap: 12px; flex-wrap: wrap; }
.btn-primary, .btn-ghost {
    display: inline-flex; align-items: center; gap: 8px;
    font-family: 'Outfit', sans-serif; font-weight: 700; font-size: 14px;
    padding: 13px 22px; border-radius: 12px;
    text-decoration: none; cursor: pointer; border: none;
    transition: all 0.25s ease;
}
.btn-primary {
    background: linear-gradient(135deg, var(--co-blue), #1e40af);
    color: #fff;
    box-shadow: 0 8px 20px rgba(0,56,147,0.28);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 12px 26px rgba(0,56,147,0.4); }
.btn-ghost {
    background: transparent; color: var(--primary);
    border: 1.5px solid var(--divider);
}
.btn-ghost:hover { background: var(--bar-bg); border-color: var(--text-light); }

.hero-aside { position: relative; }
.live-badge {
    background: linear-gradient(90deg, #f43f5e, #e11d48); color: white;
    padding: 9px 20px; border-radius: 30px;
    font-family: 'Outfit', sans-serif; font-weight: 700; font-size: 12.5px;
    letter-spacing: 1px; display: inline-flex; align-items: center; gap: 10px;
    box-shadow: 0 4px 15px rgba(244, 63, 94, 0.3);
    animation: pulse-glow 2s infinite;
    margin-bottom: 18px;
}
.live-badge::before {
    content: ''; display: block; width: 8px; height: 8px;
    background: white; border-radius: 50%;
}
@keyframes pulse-glow {
    0%   { box-shadow: 0 0 0 0 rgba(244,63,94,0.45); }
    70%  { box-shadow: 0 0 0 14px rgba(244,63,94,0); }
    100% { box-shadow: 0 0 0 0 rgba(244,63,94,0); }
}
.hero-stat {
    background: var(--card-bg); backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--card-border);
    border-radius: 18px; padding: 20px 22px;
    box-shadow: 0 14px 40px rgba(0,0,0,0.05);
}
.hero-stat-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.hero-stat .label {
    font-family: 'Outfit', sans-serif; font-size: 11px; font-weight: 600;
    color: var(--text-light); text-transform: uppercase; letter-spacing: 0.7px;
    margin-bottom: 6px;
}
.hero-stat .value {
    font-family: 'Outfit', sans-serif; font-size: 28px; font-weight: 800;
    color: var(--primary); line-height: 1;
}
.hero-stat .sub { font-size: 12px; color: var(--text-light); margin-top: 4px; }

/* DISCLAIMER BAR */
.disclaimer {
    background: rgba(252,209,22,0.10);
    border-top: 1px solid rgba(252,209,22,0.35);
    border-bottom: 1px solid rgba(252,209,22,0.35);
    padding: 14px 5%;
    font-size: 13.5px; line-height: 1.55;
    color: var(--text); text-align: center;
}
body.dark .disclaimer {
    background: rgba(252,209,22,0.06);
    border-color: rgba(252,209,22,0.2);
}
.disclaimer strong { color: var(--co-blue); font-weight: 700; }
body.dark .disclaimer strong { color: #fcd116; }
.disclaimer-icon {
    display: inline-block; vertical-align: -3px; margin-right: 6px;
}

/* TOAST */
.toast {
    position: fixed; bottom: 24px; right: 24px;
    background: var(--primary); color: #fff;
    padding: 12px 18px; border-radius: 12px;
    font-size: 13px; font-weight: 500;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    opacity: 0; transform: translateY(20px);
    transition: opacity 0.3s ease, transform 0.3s ease;
    z-index: 2000; pointer-events: none;
}
body.dark .toast { color: #0f172a; background: #f1f5f9; }
.toast.show { opacity: 1; transform: translateY(0); }

/* BACK TO TOP · aparece tras 600px de scroll, debajo del chat FAB */
.back-to-top {
    position: fixed; bottom: 96px; right: 24px;
    width: 44px; height: 44px; border-radius: 50%;
    background: var(--card-bg);
    color: var(--primary);
    border: 1px solid var(--card-border);
    box-shadow: 0 10px 24px rgba(0,0,0,0.12);
    display: inline-flex; align-items: center; justify-content: center;
    cursor: pointer;
    opacity: 0; pointer-events: none;
    transform: translateY(8px);
    transition: opacity .25s ease, transform .25s ease, background .2s, color .2s;
    z-index: 1490;
}
.back-to-top.visible { opacity: 1; pointer-events: auto; transform: translateY(0); }
/* Cuando un CTA o footer entra al viewport, baja los FABs para no taparlo. */
.back-to-top.fab-tucked, .chat-fab.fab-tucked {
    transform: translateY(120%);
    opacity: 0;
    pointer-events: none;
}
.back-to-top:hover { background: var(--highlight); color: #fff; border-color: var(--highlight); }
body.dark .back-to-top { background: rgba(30,41,59,0.9); color: #e2e8f0; }
@media (max-width: 640px) {
    .back-to-top { bottom: 86px; right: 18px; width: 40px; height: 40px; }
}

/* A11y · focus visible global consistente con la paleta */
:focus-visible {
    outline: 2px solid var(--highlight);
    outline-offset: 2px;
    border-radius: 4px;
}
button:focus-visible, a:focus-visible, .chip:focus-visible {
    outline: 2px solid var(--highlight);
    outline-offset: 3px;
}
input:focus-visible, textarea:focus-visible, select:focus-visible {
    outline: 2px solid var(--highlight);
    outline-offset: 1px;
}

/* CHATBOT WIDGET */
.chat-fab {
    position: fixed; bottom: 24px; right: 24px;
    width: 60px; height: 60px; border-radius: 50%;
    background: linear-gradient(135deg, var(--co-blue), var(--highlight));
    color: #fff; border: none; cursor: pointer;
    box-shadow: 0 12px 28px rgba(0,56,147,0.4);
    display: inline-flex; align-items: center; justify-content: center;
    z-index: 1500;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.chat-fab:hover { transform: scale(1.08); box-shadow: 0 16px 34px rgba(0,56,147,0.5); }
.chat-fab .dot {
    position: absolute; top: 8px; right: 8px;
    width: 12px; height: 12px; border-radius: 50%;
    background: var(--co-yellow); border: 2px solid #fff;
}
.chat-panel {
    position: fixed; bottom: 96px; right: 24px;
    width: 380px; max-width: calc(100vw - 32px);
    height: 540px; max-height: calc(100vh - 130px);
    background: var(--card-bg); backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--card-border);
    border-radius: 18px; overflow: hidden;
    box-shadow: 0 24px 60px rgba(0,0,0,0.25);
    display: flex; flex-direction: column;
    z-index: 1500;
    transform: translateY(20px) scale(0.96); opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease, transform 0.25s ease;
}
.chat-panel.open { opacity: 1; transform: translateY(0) scale(1); pointer-events: auto; }
.chat-header {
    padding: 16px 18px;
    background: linear-gradient(135deg, var(--co-blue), var(--highlight));
    color: #fff; display: flex; align-items: center; justify-content: space-between;
}
.chat-header .title {
    font-family: 'Outfit', sans-serif; font-weight: 700; font-size: 15px;
    display: flex; align-items: center; gap: 10px;
}
.chat-header .close-btn {
    background: rgba(255,255,255,0.15); border: none; color: #fff;
    width: 28px; height: 28px; border-radius: 50%; cursor: pointer;
    display: inline-flex; align-items: center; justify-content: center;
}
.chat-header .close-btn:hover { background: rgba(255,255,255,0.3); }
.chat-body {
    flex: 1; overflow-y: auto; padding: 16px;
    display: flex; flex-direction: column; gap: 10px;
    background: var(--bar-bg);
}
.chat-msg {
    max-width: 88%;
    padding: 10px 14px; border-radius: 14px;
    font-size: 13.5px; line-height: 1.5; word-wrap: break-word;
}
.chat-msg.bot {
    background: var(--card-bg); color: var(--text);
    border-bottom-left-radius: 4px; align-self: flex-start;
    border: 1px solid var(--divider);
}
.chat-msg.user {
    background: var(--highlight); color: #fff;
    border-bottom-right-radius: 4px; align-self: flex-end;
}
.chat-msg .src {
    display: block; margin-top: 6px; font-size: 11px;
    color: var(--text-light); font-style: italic;
}
.chat-msg.bot { white-space: pre-wrap; }
.chat-typing { display: flex; gap: 4px; align-items: center; padding: 14px 16px; }
.chat-typing .dot {
    width: 6px; height: 6px; border-radius: 50%;
    background: var(--text-light);
    animation: chat-bounce 1.2s infinite ease-in-out;
}
.chat-typing .dot:nth-child(2) { animation-delay: 0.15s; }
.chat-typing .dot:nth-child(3) { animation-delay: 0.30s; }
@keyframes chat-bounce {
    0%, 80%, 100% { transform: scale(0.7); opacity: 0.5; }
    40%           { transform: scale(1);    opacity: 1; }
}
.chat-suggestions {
    display: flex; flex-wrap: wrap; gap: 6px; padding: 0 16px 10px;
}
.chat-suggestions .sg {
    background: var(--bar-bg); color: var(--text);
    border: 1px solid var(--divider);
    font-family: 'Inter', sans-serif; font-size: 12px;
    padding: 6px 10px; border-radius: 14px; cursor: pointer;
    transition: all 0.2s ease;
}
.chat-suggestions .sg:hover { background: var(--highlight); color: #fff; border-color: var(--highlight); }
.chat-input-row {
    display: flex; gap: 8px; padding: 12px 14px;
    background: var(--card-bg); border-top: 1px solid var(--divider);
}
.chat-input-row input {
    flex: 1; background: var(--bar-bg); border: 1px solid var(--divider);
    border-radius: 12px; padding: 10px 14px;
    color: var(--text); font-family: 'Inter', sans-serif; font-size: 13.5px;
    outline: none; transition: border-color 0.2s ease;
}
.chat-input-row input:focus { border-color: var(--highlight); }
.chat-input-row button {
    background: var(--highlight); color: #fff; border: none;
    border-radius: 12px; padding: 0 16px; font-weight: 700; cursor: pointer;
    font-family: 'Outfit', sans-serif;
}
.chat-input-row button:hover { background: var(--co-blue); }

/* NAVBAR ACTIVE STATE */
.navbar .nav-links a.active {
    background: rgba(255,255,255,0.15);
    color: #fff;
    box-shadow: inset 0 0 0 1px rgba(252,209,22,0.4);
}

/* HAMBURGER (hidden on desktop, shown < 900px) */
.nav-burger {
    display: none;
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.15);
    border-radius: 10px;
    width: 42px; height: 42px;
    cursor: pointer;
    padding: 0;
    align-items: center; justify-content: center;
    flex-direction: column; gap: 4px;
    position: relative;
    transition: background 0.2s ease;
}
.nav-burger:hover { background: rgba(255,255,255,0.18); }
.nav-burger span {
    display: block;
    width: 20px; height: 2px;
    background: #fff;
    border-radius: 1px;
    transition: transform 0.3s ease, opacity 0.25s ease;
    transform-origin: center;
}
.nav-burger.open span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.nav-burger.open span:nth-child(2) { opacity: 0; }
.nav-burger.open span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

.nav-backdrop {
    position: fixed; inset: 0;
    background: rgba(0,0,0,0.55);
    backdrop-filter: blur(2px);
    opacity: 0; pointer-events: none;
    transition: opacity 0.25s ease;
    z-index: 998;
}
.nav-backdrop.open { opacity: 1; pointer-events: auto; }

/* FOOTER RICH */
.footer { padding: 0; text-align: left; }
.footer-grid {
    max-width: 1400px;
    margin: 0 auto;
    padding: 44px 5% 28px 5%;
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr 1fr;
    gap: 36px;
}
.footer-col h4 {
    font-family: 'Outfit', sans-serif;
    font-size: 12px; font-weight: 700;
    color: #fff; text-transform: uppercase; letter-spacing: 0.8px;
    margin: 0 0 14px 0;
}
.footer-col ul { list-style: none; padding: 0; margin: 0; }
.footer-col li { font-size: 13px; padding: 4px 0; }
.footer-col a {
    color: #94a3b8; text-decoration: none;
    transition: color 0.2s ease;
}
.footer-col a:hover { color: #fff; }
.footer-brand {
    font-family: 'Outfit', sans-serif; font-weight: 800;
    font-size: 15px; color: #fff;
    margin-bottom: 10px;
    display: flex; align-items: center; gap: 8px;
}
.footer-mission {
    font-size: 13px; line-height: 1.6; color: #94a3b8;
    margin: 0; max-width: 360px;
}
.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.08);
    padding: 18px 5%;
    font-size: 12px; color: #64748b;
    text-align: center;
}

/* PAGE HERO · for inner pages (shorter than landing hero) */
.page-hero {
    position: relative;
    padding: 56px 5% 36px 5%;
    overflow: hidden;
    background:
        radial-gradient(circle at 100% 0%, rgba(0,56,147,0.10), transparent 50%),
        radial-gradient(circle at 0% 100%, rgba(252,209,22,0.10), transparent 55%);
}
.page-hero::before {
    content: '';
    position: absolute; top: 0; left: 0; right: 0; height: 4px;
    background: linear-gradient(to right,
        var(--co-yellow) 0%, var(--co-yellow) 50%,
        var(--co-blue) 50%, var(--co-blue) 75%,
        var(--co-red) 75%, var(--co-red) 100%);
}
.page-hero-inner {
    max-width: 1400px; margin: 0 auto;
    display: flex; flex-direction: column; gap: 14px;
}
.breadcrumb {
    display: flex; align-items: center; gap: 8px;
    font-size: 12.5px; color: var(--text-light);
    font-family: 'Outfit', sans-serif; font-weight: 600;
    text-transform: uppercase; letter-spacing: 0.5px;
}
.breadcrumb a { color: var(--text-light); text-decoration: none; transition: color 0.2s; }
.breadcrumb a:hover { color: var(--highlight); }
.breadcrumb .sep { opacity: 0.5; }
.breadcrumb .current { color: var(--primary); }
.page-hero h1 {
    font-family: 'Outfit', sans-serif;
    font-size: clamp(28px, 4vw, 42px);
    font-weight: 800; letter-spacing: -1px; line-height: 1.1;
    margin: 0; color: var(--primary);
}
.page-hero .lead {
    font-size: 16px; line-height: 1.6; color: var(--text-light);
    max-width: 720px; margin: 0;
}

/* PROSE · article-style content */
.prose {
    max-width: 780px;
    font-size: 15.5px;
    line-height: 1.75;
    color: var(--text);
}
.prose h2 {
    font-family: 'Outfit', sans-serif;
    font-size: 26px; font-weight: 700;
    color: var(--primary);
    margin: 44px 0 14px 0;
    letter-spacing: -0.5px;
    line-height: 1.2;
}
.prose h2:first-child { margin-top: 0; }
.prose h3 {
    font-family: 'Outfit', sans-serif;
    font-size: 18px; font-weight: 700;
    color: var(--primary);
    margin: 28px 0 10px 0;
}
.prose p { margin: 0 0 14px 0; }
.prose ul, .prose ol { padding-left: 22px; margin: 0 0 16px 0; }
.prose li { margin-bottom: 6px; }
.prose strong { color: var(--primary); }
.prose a { color: var(--highlight); text-decoration: underline; text-underline-offset: 3px; }
.prose a:hover { color: var(--co-blue); }
.prose hr {
    border: none; height: 1px;
    background: var(--divider); margin: 32px 0;
}

/* CALLOUTS */
.callout {
    display: flex; gap: 14px;
    padding: 18px 22px;
    background: var(--bar-bg);
    border-left: 4px solid var(--highlight);
    border-radius: 0 12px 12px 0;
    margin: 22px 0;
    font-size: 14px; line-height: 1.6;
}
.callout.warn { border-left-color: var(--warning); background: rgba(245,158,11,0.06); }
.callout.success { border-left-color: var(--success); background: rgba(16,185,129,0.06); }
.callout.info { border-left-color: var(--co-blue); background: rgba(0,56,147,0.06); }
.callout-icon {
    flex-shrink: 0;
    width: 26px; height: 26px;
    display: inline-flex; align-items: center; justify-content: center;
    border-radius: 50%;
    background: rgba(0,0,0,0.05);
}
.callout strong { display: block; margin-bottom: 4px; color: var(--primary); }

/* CARD GRID (for landing page sections) */
.feature-grid {
    display: grid; grid-template-columns: repeat(3, 1fr);
    gap: 18px;
    max-width: 1400px; margin: 0 auto;
    padding: 0 5%;
}
.feature-card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 16px;
    padding: 26px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    text-decoration: none; color: inherit;
    display: flex; flex-direction: column; gap: 8px;
    position: relative;
    overflow: hidden;
}
/* Gradient top border effect */
.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--co-yellow), var(--co-blue), var(--co-red));
    opacity: 0;
    transition: opacity 0.3s ease;
}
.feature-card:hover::before {
    opacity: 1;
}
.feature-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 18px 40px rgba(0,0,0,0.08);
}
.feature-icon {
    width: 44px; height: 44px;
    border-radius: 12px;
    display: inline-flex; align-items: center; justify-content: center;
    background: rgba(0,56,147,0.08);
    color: var(--co-blue);
    margin-bottom: 6px;
}
.feature-card h3 {
    font-family: 'Outfit', sans-serif; font-weight: 700;
    font-size: 17px; color: var(--primary);
    margin: 0;
}
.feature-card p {
    font-size: 13.5px; line-height: 1.55;
    color: var(--text-light); margin: 0;
}
.feature-card .arrow {
    margin-top: 8px;
    font-family: 'Outfit', sans-serif; font-weight: 700;
    font-size: 13px; color: var(--highlight);
    display: inline-flex; align-items: center; gap: 6px;
}
.feature-card:hover .arrow { color: var(--co-blue); }

/* SECTION TITLE for landing strips */
.section-strip {
    max-width: 1400px; margin: 0 auto;
    padding: 50px 5% 16px 5%;
}
.section-strip h2 {
    font-family: 'Outfit', sans-serif; font-weight: 800;
    font-size: clamp(22px, 3vw, 30px);
    letter-spacing: -0.5px;
    color: var(--primary);
    margin: 0 0 6px 0;
}
.section-strip .section-strip-lead {
    font-size: 14.5px;
    color: var(--text-light); margin: 0 0 22px 0;
    max-width: 720px;
}

/* CTA BAND */
.cta-band {
    margin: 60px 5%;
    max-width: 1400px;
    margin-left: auto; margin-right: auto;
    padding: 36px 40px;
    background:
        linear-gradient(135deg, rgba(0,56,147,0.95), rgba(59,130,246,0.95)),
        linear-gradient(45deg, rgba(252,209,22,0.3), transparent);
    color: #fff;
    border-radius: 24px;
    display: flex; align-items: center; justify-content: space-between;
    gap: 24px; flex-wrap: wrap;
    box-shadow: 0 18px 50px rgba(0,56,147,0.3);
}
.cta-band .cta-text h3 {
    font-family: 'Outfit', sans-serif; font-weight: 800;
    font-size: 24px; margin: 0 0 6px 0; letter-spacing: -0.5px;
}
.cta-band .cta-text p { margin: 0; font-size: 14.5px; opacity: 0.9; line-height: 1.5; }
.cta-band .btn-primary {
    background: #fff; color: var(--co-blue);
    box-shadow: 0 8px 20px rgba(0,0,0,0.2);
}
.cta-band .btn-primary:hover { background: #fcd116; color: var(--co-blue); }

/* 404 SPECIFIC */
.notfound {
    min-height: 60vh;
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    padding: 60px 5%; text-align: center;
}
.notfound-code {
    font-family: 'Outfit', sans-serif; font-weight: 800;
    font-size: clamp(80px, 14vw, 160px);
    line-height: 1;
    background: linear-gradient(135deg, var(--co-yellow), var(--co-blue), var(--co-red));
    -webkit-background-clip: text; background-clip: text;
    -webkit-text-fill-color: transparent;
    margin: 0 0 14px 0;
}
.notfound h1 {
    font-family: 'Outfit', sans-serif; font-weight: 800;
    font-size: clamp(24px, 3vw, 32px);
    margin: 0 0 10px 0; color: var(--primary);
}
.notfound p { font-size: 15px; color: var(--text-light); max-width: 480px; line-height: 1.6; }

/* SKELETONS */
.skeleton {
    background: linear-gradient(90deg, var(--bar-bg) 0%,
        color-mix(in srgb, var(--bar-bg) 70%, #fff) 50%,
        var(--bar-bg) 100%);
    background-size: 200% 100%;
    animation: shimmer 1.4s infinite linear;
    border-radius: 6px;
}
@keyframes shimmer {
    0%   { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}
.skel-line { height: 10px; margin: 6px 0; }
.skel-line.w80 { width: 80%; }
.skel-line.w60 { width: 60%; }
.skel-line.w40 { width: 40%; }
.skel-item {
    padding-left: 22px; padding-bottom: 22px;
    border-left: 2px solid var(--divider); margin-bottom: 8px;
}
