/* ============ Tokens, dark mode ============ */
:root {
  --blue: #2563eb; --gold-2: #ffd45c;
  --page: #f4f7fb; --card: #fff; --surface-2: #eef2f9; --text: #1b2437; --heading: #0b1f3a; --line: #e3e8f2;
  --shadow: 0 12px 34px rgba(11, 31, 58, .09); --radius: 1.25rem;
  --grad: linear-gradient(135deg, #081a33 0%, #12305c 55%, #2150c9 100%);
}
[data-bs-theme=dark] {
  --page: #0a1020; --card: #111a2e; --surface: #18233b; --surface-2: #18233b; --text: #e6ebf5;
  --heading: #fff; --muted: #9aa7bf; --line: #22304d; --shadow: 0 12px 34px rgba(0, 0, 0, .45);
}
body { background: var(--page); color: var(--text); overflow-x: hidden; }
::selection { background: var(--gold); color: #111; }
.quick-card, .stat-card, .feature-card, .section-card, .member-card, .auth-card, .vote-option, .device-row,
.media-card, .leader-card, .quote-card { background: var(--card); color: var(--text); }
.bg-white { background: var(--card) !important; }
[data-bs-theme=dark] .text-navy, [data-bs-theme=dark] .section-title, [data-bs-theme=dark] .stat-number,
[data-bs-theme=dark] .price-tag, [data-bs-theme=dark] .stat-value { color: var(--heading) !important; }
[data-bs-theme=dark] .text-muted { color: var(--muted) !important; }
[data-bs-theme=dark] .receipt-code { background: #2a2410; color: #fff; }
[data-bs-theme=dark] .todo-item { background: rgba(245, 179, 1, .12); color: var(--text); }
[data-bs-theme=dark] .result-bar { background: #223050; }
[data-bs-theme=dark] .side-link.active { color: #8db8ff; }

/* ============ Loader & progress ============ */
.preloader { position: fixed; inset: 0; z-index: 3000; display: none; place-items: center; background: #081a33; transition: opacity .5s, visibility .5s; }
html.js .preloader { display: grid; }
.preloader.hide { opacity: 0; visibility: hidden; }
.pl-mark { width: 66px; height: 66px; border-radius: 1.3rem; display: grid; place-items: center; font-size: 2rem; color: var(--navy); background: linear-gradient(135deg, var(--gold), var(--gold-2)); animation: plPulse 1.1s ease-in-out infinite; }
@keyframes plPulse { 50% { transform: scale(1.15) rotate(-6deg); } }
.scroll-progress { position: fixed; top: 0; left: 0; height: 3px; width: 0; z-index: 2500; background: linear-gradient(90deg, var(--gold), var(--blue)); }

/* ============ Public navbar ============ */
.site-nav.nav-overlay { background: transparent; backdrop-filter: none; box-shadow: none; padding: 1.1rem 0; }
.site-nav.nav-overlay.scrolled { background: rgba(8, 26, 51, .92); backdrop-filter: blur(12px); padding: .5rem 0; box-shadow: 0 8px 28px rgba(0, 0, 0, .25); }
@media (max-width: 991.98px) { .site-nav.nav-overlay .navbar-collapse { background: rgba(8, 26, 51, .96); border-radius: 1rem; padding: 1rem; margin-top: .6rem; } }
.theme-toggle, .icon-btn { width: 40px; height: 40px; border-radius: 50%; display: inline-grid; place-items: center; border: 1px solid rgba(255, 255, 255, .3); background: rgba(255, 255, 255, .08); color: #fff; transition: transform .3s, background .3s; }
.theme-toggle:hover, .icon-btn:hover { background: rgba(255, 255, 255, .2); transform: rotate(18deg); }
[data-bs-theme=light] .theme-toggle .bi-sun-fill, [data-bs-theme=dark] .theme-toggle .bi-moon-stars-fill { display: none; }

/* ============ Hero slider ============ */
.hero2 { position: relative; min-height: 100svh; display: flex; align-items: center; color: #fff; overflow: hidden; background: var(--grad); }
.hero-slides { position: absolute; inset: 0; }
.hero-slide { position: absolute; inset: 0; display: flex; align-items: center; opacity: 0; visibility: hidden; transition: opacity 1.2s ease, visibility 1.2s; }
.hero-slide.active { opacity: 1; visibility: visible; }
.hero-bg { position: absolute; inset: 0; background-size: cover; background-position: center; }
.hero-slide.active .hero-bg { animation: kenburns 14s ease-out forwards; }
@keyframes kenburns { from { transform: scale(1.02); } to { transform: scale(1.14) translate(-1.5%, -1%); } }
.hero-overlay { position: absolute; inset: 0; background: linear-gradient(100deg, rgba(7, 18, 38, .92) 0%, rgba(11, 31, 58, .72) 48%, rgba(11, 31, 58, .3) 100%); }
.hero-content { position: relative; z-index: 2; max-width: 760px; padding-top: 5rem; }
.hero-content > * { opacity: 0; transform: translateY(26px); }
.hero-slide.active .hero-content > * { animation: riseIn .9s cubic-bezier(.2, .7, .2, 1) forwards; }
.hero-slide.active .hero-content > :nth-child(2) { animation-delay: .15s; }
.hero-slide.active .hero-content > :nth-child(3) { animation-delay: .3s; }
.hero-slide.active .hero-content > :nth-child(4) { animation-delay: .45s; }
@keyframes riseIn { to { opacity: 1; transform: none; } }
.hero-title { font-size: clamp(2.2rem, 6vw, 4.3rem); font-weight: 700; line-height: 1.08; margin: .9rem 0 1rem; }
.gradient-text { background: linear-gradient(90deg, var(--gold), #fff, var(--gold-2)); background-size: 200% auto; -webkit-background-clip: text; background-clip: text; color: transparent; animation: shine 5s linear infinite; }
@keyframes shine { to { background-position: 200% center; } }
.hero-ui { position: absolute; left: 0; right: 0; bottom: 1.6rem; z-index: 5; }
.hero-dots { display: flex; gap: .5rem; }
.hero-dots button { width: 12px; height: 12px; border-radius: 99px; border: 0; background: rgba(255, 255, 255, .4); padding: 0; transition: width .3s, background .3s; }
.hero-dots button.active { width: 34px; background: var(--gold); }
.hero-arrow { width: 44px; height: 44px; border-radius: 50%; border: 1px solid rgba(255, 255, 255, .35); background: rgba(255, 255, 255, .1); color: #fff; backdrop-filter: blur(6px); transition: background .25s; }
.hero-arrow:hover { background: var(--gold); color: var(--navy); }
.hero-card { max-width: 380px; margin-left: auto; padding: 1rem 1.2rem; border-radius: 1.2rem; background: rgba(255, 255, 255, .12); border: 1px solid rgba(255, 255, 255, .22); backdrop-filter: blur(14px); }
.scroll-hint { position: absolute; left: 50%; bottom: 5.2rem; transform: translateX(-50%); z-index: 4; color: rgba(255, 255, 255, .7); animation: floatY 2.4s ease-in-out infinite; }

.cd-grid { display: flex; gap: .6rem; flex-wrap: wrap; }
.cd-box { min-width: 66px; padding: .55rem .4rem; text-align: center; border-radius: 1rem; background: rgba(255, 255, 255, .12); border: 1px solid rgba(255, 255, 255, .22); }
.cd-box b { display: block; font-family: 'Playfair Display', serif; font-size: 1.6rem; line-height: 1.1; }
.cd-box small { font-size: .68rem; text-transform: uppercase; letter-spacing: .08em; opacity: .75; }

/* ============ Sections ============ */
.section2 { padding: 5.5rem 0; }
.eyebrow { display: inline-block; letter-spacing: .14em; text-transform: uppercase; font-size: .72rem; font-weight: 700; color: var(--blue); padding: .35rem .85rem; border-radius: 99px; background: rgba(37, 99, 235, .1); margin-bottom: .8rem; }
[data-bs-theme=dark] .eyebrow { color: #8db8ff; background: rgba(141, 184, 255, .12); }
.stats-band { margin-top: -3.2rem; position: relative; z-index: 6; }
.stats-card { background: var(--card); border-radius: 1.5rem; box-shadow: var(--shadow); padding: 2rem 1rem; }
.feature-card { position: relative; overflow: hidden; border: 1px solid var(--line); }
.feature-card::after { content: ""; position: absolute; inset: auto -40% -60% auto; width: 180px; height: 180px; border-radius: 50%; background: radial-gradient(var(--gold), transparent 70%); opacity: 0; transition: opacity .4s; }
.feature-card:hover::after { opacity: .25; }
.about-img { border-radius: 1.75rem; box-shadow: var(--shadow); width: 100%; aspect-ratio: 4 / 3; object-fit: cover; background: var(--grad); }
.about-badge { position: absolute; right: -10px; bottom: -22px; padding: 1rem 1.4rem; border-radius: 1.2rem; background: var(--gold); color: var(--navy); font-weight: 700; box-shadow: var(--shadow); text-align: center; }

/* cards for news / events / campaigns */
.media-card { border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); transition: transform .3s, box-shadow .3s; }
.media-card:hover { transform: translateY(-8px); box-shadow: 0 22px 46px rgba(11, 31, 58, .16); }
.media-thumb { position: relative; display: block; aspect-ratio: 16 / 10; overflow: hidden; background: var(--grad); }
.media-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s; }
.media-card:hover .media-thumb img { transform: scale(1.08); }
.thumb-fallback { position: absolute; inset: 0; display: grid; place-items: center; font-size: 3rem; color: rgba(255, 255, 255, .55); }
.thumb-tag { position: absolute; left: 1rem; top: 1rem; padding: .25rem .7rem; border-radius: 99px; font-size: .72rem; font-weight: 600; background: rgba(255, 255, 255, .92); color: var(--navy); }
.date-badge { flex: 0 0 64px; text-align: center; border-radius: 1rem; padding: .5rem 0; background: var(--grad); color: #fff; line-height: 1.1; }
.date-badge b { display: block; font-family: 'Playfair Display', serif; font-size: 1.6rem; }
.date-badge small { text-transform: uppercase; letter-spacing: .08em; font-size: .7rem; opacity: .85; }
.filter-chip { border: 1px solid var(--line); background: var(--card); color: var(--text); border-radius: 99px; padding: .4rem 1rem; font-weight: 600; font-size: .88rem; transition: .25s; }
.filter-chip.active, .filter-chip:hover { background: var(--blue); border-color: var(--blue); color: #fff; }

.marquee { overflow: hidden; -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent); mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent); }
.marquee-track { display: flex; gap: .8rem; width: max-content; animation: marquee 45s linear infinite; }
.marquee:hover .marquee-track { animation-play-state: paused; }
@keyframes marquee { to { transform: translateX(-50%); } }
.chapter-pill { display: inline-flex; align-items: center; gap: .5rem; padding: .7rem 1.2rem; border-radius: 99px; background: var(--card); border: 1px solid var(--line); box-shadow: var(--shadow); font-weight: 600; white-space: nowrap; color: var(--text); text-decoration: none; }
.chapter-pill i { color: var(--gold); }

.leader-card { border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; text-align: center; box-shadow: var(--shadow); transition: transform .3s; }
.leader-card:hover { transform: translateY(-6px); }
.leader-photo { position: relative; aspect-ratio: 1; background: var(--grad); display: grid; place-items: center; font-size: 3rem; font-weight: 700; color: rgba(255, 255, 255, .8); overflow: hidden; }
.leader-photo img { width: 100%; height: 100%; object-fit: cover; }
.leader-photo a { position: absolute; inset: auto 0 0 0; padding: .6rem; background: rgba(8, 26, 51, .8); color: #fff; font-size: .85rem; transform: translateY(100%); transition: transform .3s; text-decoration: none; }
.leader-card:hover .leader-photo a { transform: none; }
.quote-card { border: 1px solid var(--line); border-radius: 1.5rem; padding: 2rem; box-shadow: var(--shadow); }
.quote-mark { font-size: 3rem; line-height: 1; color: var(--gold); font-family: 'Playfair Display', serif; }
.accordion { --bs-accordion-bg: var(--card); --bs-accordion-border-color: var(--line); }
.accordion-button:not(.collapsed) { color: var(--blue); background: rgba(37, 99, 235, .07); }

/* ============ Page header, footer, cookie ============ */
.page-hero { position: relative; overflow: hidden; color: #fff; padding: 3.5rem 0 3rem; background: var(--grad); }
.page-hero .breadcrumb { --bs-breadcrumb-divider-color: rgba(255, 255, 255, .5); }
.page-hero .breadcrumb a { color: var(--gold-2); text-decoration: none; }
.page-hero .breadcrumb-item.active { color: rgba(255, 255, 255, .8); }
.prose { font-size: 1.08rem; line-height: 1.85; }
.footer2 { background: linear-gradient(180deg, #0b1f3a, #06122a); color: rgba(255, 255, 255, .72); padding: 4rem 0 1.5rem; }
.footer2 a { color: inherit; text-decoration: none; }
.footer2 a:hover { color: var(--gold); }
.footer2 h6 { color: #fff; text-transform: uppercase; letter-spacing: .1em; font-size: .78rem; margin-bottom: 1rem; }
.social a { width: 40px; height: 40px; border-radius: 50%; display: inline-grid; place-items: center; background: rgba(255, 255, 255, .08); margin-right: .4rem; transition: .25s; }
.social a:hover { background: var(--gold); color: var(--navy); transform: translateY(-3px); }
.cookie { position: fixed; left: 1rem; bottom: 1rem; z-index: 2000; max-width: 360px; padding: 1rem 1.2rem; border-radius: 1.1rem; background: var(--card); border: 1px solid var(--line); box-shadow: 0 18px 44px rgba(0, 0, 0, .25); display: none; }
.cookie.show { display: block; animation: slideUp .5s ease both; }

/* ============ App shell ============ */
.app-shell2 { display: flex; min-height: 100vh; }
.sidebar { position: fixed; inset: 0 auto 0 0; width: 272px; z-index: 1040; display: flex; flex-direction: column; background: var(--card); border-right: 1px solid var(--line); transition: transform .3s ease, width .3s ease; }
.sidebar-brand { display: flex; align-items: center; gap: .7rem; padding: 1rem 1.1rem; color: var(--heading); text-decoration: none; font-weight: 700; border-bottom: 1px solid var(--line); }
.sidebar-nav { flex: 1; overflow-y: auto; padding: .4rem .8rem 1rem; }
.side-link { color: var(--text); }
.side-link i { width: 1.25rem; text-align: center; font-size: 1.1rem; }
.side-link.active { background: rgba(37, 99, 235, .12); color: var(--blue); }
.app-col { flex: 1; min-width: 0; margin-left: 272px; transition: margin .3s ease; }
.topbar { position: sticky; top: 0; z-index: 1030; display: flex; align-items: center; gap: .6rem; padding: .7rem 1.25rem; background: color-mix(in srgb, var(--card) 85%, transparent); backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); }
.topbar .icon-btn { border-color: var(--line); background: var(--card); color: var(--text); }
.topbar .icon-btn:hover { background: var(--surface-2); }
.search-btn { display: flex; align-items: center; gap: .6rem; min-width: 0; flex: 0 1 340px; padding: .55rem .9rem; border-radius: .9rem; border: 1px solid var(--line); background: var(--surface-2); color: var(--muted, #667085); }
.search-btn kbd { margin-left: auto; font-size: .7rem; }
.notif-dot { position: absolute; top: -4px; right: -4px; min-width: 18px; height: 18px; padding: 0 4px; border-radius: 99px; background: #dc3545; color: #fff; font-size: .68rem; display: grid; place-items: center; }
.app-main2 { padding: 1.5rem; }
.sidebar-backdrop { display: none; }
body.sidebar-collapsed .sidebar { width: 78px; }
body.sidebar-collapsed .app-col { margin-left: 78px; }
body.sidebar-collapsed .side-text, body.sidebar-collapsed .side-label, body.sidebar-collapsed .brand-text, body.sidebar-collapsed .side-link .badge { display: none; }
body.sidebar-collapsed .side-link { justify-content: center; }
@media (min-width: 992px) { .app-main2 { padding: 2rem; } }
@media (max-width: 991.98px) {
  .sidebar { transform: translateX(-100%); width: 280px !important; }
  .app-col { margin-left: 0 !important; }
  body.sidebar-open .sidebar { transform: none; box-shadow: 0 0 60px rgba(0, 0, 0, .4); }
  body.sidebar-open .sidebar-backdrop { display: block; position: fixed; inset: 0; z-index: 1035; background: rgba(0, 0, 0, .45); }
  body.sidebar-collapsed .side-text, body.sidebar-collapsed .side-label, body.sidebar-collapsed .brand-text { display: inline; }
  .search-btn span, .search-btn kbd { display: none; } .search-btn { flex: 0 0 auto; }
}
.palette-item { display: flex; align-items: center; gap: .7rem; padding: .65rem .85rem; border-radius: .8rem; color: var(--text); text-decoration: none; cursor: pointer; }
.palette-item.active, .palette-item:hover { background: var(--surface-2); color: var(--text); }