/* =========================================================
   LCA 2.0 PARTICIPANT PORTAL — STYLES
   Design tokens, layout, components, states, responsive.
   ========================================================= */

/* ---------- 1. DESIGN TOKENS ---------- */
:root {
  /* Brand colors */
  --navy: #053270;
  --navy-dark: #021E46;
  --royal-blue: #0B4DA2;
  --gold: #FFC60B;
  --gold-soft: #FFE38A;
  --white: #FEFEFE;

  --bg: #F4F7FC;
  --bg-alt: #EDF3FB;
  --text-main: #172033;
  --text-secondary: #5C667A;
  --success: #16835D;
  --warning: #B77900;
  --danger: #C63C3C;

  --gradient-main: linear-gradient(135deg, #021E46 0%, #053270 48%, #0B4DA2 100%);
  --gradient-gold: linear-gradient(135deg, #FFC60B 0%, #FFE38A 100%);

  --surface: #FFFFFF;
  --surface-alt: #F8FAFD;
  --border-soft: rgba(5, 50, 112, 0.10);
  --border-strong: rgba(5, 50, 112, 0.18);
  --shadow-sm: 0 2px 8px rgba(5, 50, 112, 0.06);
  --shadow-md: 0 8px 24px rgba(5, 50, 112, 0.10);
  --shadow-lg: 0 16px 48px rgba(5, 50, 112, 0.16);
  --glow: radial-gradient(circle, rgba(11,77,162,0.16) 0%, rgba(11,77,162,0) 70%);

  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 24px;

  --font-main: 'Inter', 'Public Sans', -apple-system, BlinkMacSystemFont, sans-serif;

  --fs-body: 16px;
  --fs-sm: 14px;
  --fs-lg: 18px;
  --fs-xl: 22px;
  --fs-2xl: 28px;
  --fs-3xl: 36px;

  --transition: 220ms cubic-bezier(.4,0,.2,1);

  --sidebar-w: 272px;
  --sidebar-w-collapsed: 84px;
  --topbar-h: 72px;
  --bottom-nav-h: 68px;

  color-scheme: light;
}

/* High contrast (works layered on top of light or dark) */
html[data-contrast="high"] {
  --text-main: #000000;
  --text-secondary: #1a1a1a;
  --border-soft: rgba(0,0,0,0.45);
  --border-strong: rgba(0,0,0,0.65);
  --bg: #FFFFFF;
  --surface: #FFFFFF;
}

/* Compact density */
html[data-density="compact"] { --density-gap: 12px; --density-pad: 14px; }
html[data-density="comfortable"] { --density-gap: 20px; --density-pad: 22px; }
:root { --density-gap: 20px; --density-pad: 22px; }

/* Font size preference */
html[data-fontsize="large"] { font-size: 18px; }
html[data-fontsize="normal"] { font-size: 16px; }

/* Reduced motion */
html[data-motion="reduced"] * {
  animation-duration: 0.001ms !important;
  animation-iteration-count: 1 !important;
  transition-duration: 0.001ms !important;
  scroll-behavior: auto !important;
}
@media (prefers-reduced-motion: reduce) {
  * { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
}

/* ---------- 2. RESET / BASE ---------- */
* { box-sizing: border-box; }
html, body {
  margin: 0; padding: 0;
  background: var(--bg);
  color: var(--text-main);
  font-family: var(--font-main);
  font-size: var(--fs-body);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
button { font-family: inherit; cursor: pointer; }
a { color: inherit; }
h1, h2, h3, h4 { margin: 0; font-weight: 700; letter-spacing: -0.01em; }
p { margin: 0; }
ul { list-style: none; margin: 0; padding: 0; }
.hidden { display: none !important; }
.wide-layout .content { max-width: 1600px; }

.skip-link {
  position: absolute; left: -999px; top: 0;
  background: var(--navy); color: #fff; padding: 12px 20px;
  z-index: 999; border-radius: 0 0 8px 0;
}
.skip-link:focus { left: 0; }

:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 2px;
  border-radius: 4px;
}

/* ---------- 3. BUTTONS ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-size: 16px; font-weight: 600; font-family: inherit;
  padding: 13px 22px; border-radius: 12px; border: none;
  transition: transform var(--transition), box-shadow var(--transition), background var(--transition);
  min-height: 44px;
}
.btn:active { transform: translateY(1px); }
.btn-primary {
  background: var(--gradient-main); color: #fff;
  box-shadow: var(--shadow-sm);
}
.btn-primary:hover { box-shadow: var(--shadow-md); transform: translateY(-1px); }
.btn-gold {
  background: var(--gradient-gold); color: var(--navy-dark);
  box-shadow: var(--shadow-sm);
}
.btn-gold:hover { box-shadow: var(--shadow-md); transform: translateY(-1px); }
.btn-outline {
  background: transparent; color: var(--navy); border: 1.5px solid var(--border-strong);
}
.btn-outline:hover { background: var(--surface-alt); }
.btn-ghost { background: transparent; color: var(--text-secondary); }
.btn-ghost:hover { background: var(--surface-alt); color: var(--text-main); }
.btn-danger { background: var(--danger); color: #fff; }
.btn-block { width: 100%; }
.btn-sm { padding: 9px 16px; font-size: 14px; min-height: 38px; }
.btn:disabled { opacity: 0.5; cursor: not-allowed; transform: none !important; }

.icon-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 44px; height: 44px; border-radius: 12px; border: none;
  background: transparent; color: var(--text-main); position: relative;
  transition: background var(--transition);
}
.icon-btn:hover { background: var(--surface-alt); }

.text-btn {
  display: inline-flex; align-items: center; gap: 8px;
  background: transparent; border: none; color: var(--text-secondary);
  font-size: 15px; font-weight: 500; padding: 8px;
}
.text-btn:hover { color: var(--text-main); }

/* ---------- 4. CARDS ---------- */
.card {
  background: var(--surface);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  padding: var(--density-pad);
  transition: box-shadow var(--transition), transform var(--transition);
}
.card.hoverable:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); }
.card-gradient-border {
  position: relative; border: 1px solid transparent; background-clip: padding-box;
}
.card-gradient-border::before {
  content: ""; position: absolute; inset: 0; border-radius: inherit; padding: 1.5px;
  background: var(--gradient-main);
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  pointer-events: none; z-index: 0;
}
.card-gradient-border > * { position: relative; z-index: 1; }

.glass {
  background: rgba(255,255,255,0.72);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(255,255,255,0.4);
}

/* ---------- 5. BADGES ---------- */
.badge {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 13px; font-weight: 600; padding: 5px 12px; border-radius: 999px;
  border: 1px solid transparent;
}
.badge::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.badge-success { background: rgba(22,131,93,0.12); color: var(--success); }
.badge-warning { background: rgba(183,121,0,0.12); color: var(--warning); }
.badge-danger { background: rgba(198,60,60,0.12); color: var(--danger); }
.badge-info { background: color-mix(in srgb, var(--theme-c3) 14%, transparent); color: var(--theme-c3); }
.badge-gold { background: rgba(255,198,11,0.18); color: #8a6400; }

.badge-count {
  position: absolute; top: 4px; right: 4px;
  background: var(--danger); color: #fff; font-size: 11px; font-weight: 700;
  min-width: 18px; height: 18px; border-radius: 999px;
  display: flex; align-items: center; justify-content: center; padding: 0 4px;
}

/* ---------- 6. APP SHELL / LAYOUT ---------- */
.app-shell { display: flex; min-height: 100vh; }

.sidebar {
  width: var(--sidebar-w);
  background: var(--gradient-main);
  color: #fff;
  display: flex; flex-direction: column;
  position: fixed; top: 0; left: 0; bottom: 0; z-index: 40;
  transition: width var(--transition), transform var(--transition);
  padding: 20px 16px;
}
.app-shell.sidebar-collapsed .sidebar { width: var(--sidebar-w-collapsed); }
.app-shell.sidebar-collapsed .brand-text,
.app-shell.sidebar-collapsed .nav-label,
.app-shell.sidebar-collapsed .sidebar-user,
.app-shell.sidebar-collapsed .demo-badge span,
.app-shell.sidebar-collapsed .logout-btn span { display: none; }
.app-shell.sidebar-collapsed .sidebar-collapse-btn i { transform: rotate(180deg); }

.sidebar-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 28px; }
.sidebar-collapse-btn { flex-shrink: 0; position: relative; z-index: 2; }
.brand { display: flex; align-items: center; gap: 12px; min-width: 0; }
.brand-logo { width: 40px; height: 40px; flex-shrink: 0; border-radius: 12px; object-fit: cover; }
.brand-text { display: flex; flex-direction: column; min-width: 0; }
.brand-name { font-weight: 800; font-size: 16px; }
.brand-sub { font-size: 12px; color: var(--gold-soft); }
.sidebar-collapse-btn { color: #fff; }
.sidebar-collapse-btn:hover { background: rgba(255,255,255,0.12); }

.sidebar-nav { flex: 1; min-height: 0; overflow-y: auto; scrollbar-width: none; -ms-overflow-style: none; }
.sidebar-nav::-webkit-scrollbar { display: none; width: 0; height: 0; }
.sidebar-nav ul { display: flex; flex-direction: column; gap: 4px; }
.nav-item {
  display: flex; align-items: center; gap: 14px;
  padding: 13px 14px; border-radius: 12px; color: rgba(255,255,255,0.78);
  font-weight: 500; font-size: 15px; transition: background var(--transition), color var(--transition);
  border: none; background: transparent; width: 100%; text-align: left;
}
.nav-item i { font-size: 20px; width: 22px; text-align: center; flex-shrink: 0; }
.nav-item:hover { background: rgba(255,255,255,0.08); color: #fff; }
.nav-item.active {
  background: rgba(255,198,11,0.16); color: #fff;
  box-shadow: inset 3px 0 0 var(--gold);
}

.sidebar-bottom { border-top: 1px solid rgba(255,255,255,0.14); padding-top: 16px; margin-top: 12px; flex-shrink: 0; }
.demo-badge {
  display: inline-flex; align-items: center; gap: 6px;
  background: rgba(255,198,11,0.18); color: var(--gold-soft);
  font-size: 12px; font-weight: 700; padding: 5px 10px; border-radius: 999px; margin-bottom: 12px;
}
.sidebar-user { font-size: 13px; color: rgba(255,255,255,0.85); margin-bottom: 8px; line-height: 1.5; }
.sidebar-user strong { display: block; color: #fff; font-size: 15px; }
.logout-btn { color: rgba(255,255,255,0.75); width: 100%; }
.logout-btn:hover { color: #fff; background: rgba(255,255,255,0.08); }

.main-col { flex: 1; min-width: 0; margin-left: var(--sidebar-w); display: flex; flex-direction: column; min-height: 100vh; transition: margin-left var(--transition); }
.app-shell.sidebar-collapsed .main-col { margin-left: var(--sidebar-w-collapsed); }

.topbar {
  height: var(--topbar-h);
  display: flex; align-items: center; gap: 12px;
  padding: 0 28px;
  background: var(--surface);
  border-bottom: 1px solid var(--border-soft);
  position: sticky; top: 0; z-index: 30;
}
.hamburger-btn { display: none; }
.topbar-title { flex: 1; min-width: 0; }
.topbar-title h1 { font-size: 20px; }
.topbar-actions { display: flex; align-items: center; gap: 8px; }
.notif-btn i { font-size: 20px; }

.account-switcher select {
  border: 1px solid var(--border-soft); background: var(--surface-alt);
  color: var(--text-main); border-radius: 10px; padding: 8px 12px; font-size: 13px; font-weight: 600;
  max-width: 190px;
}

.content { flex: 1; min-width: 0; padding: 28px; max-width: 1280px; width: 100%; margin: 0 auto; }

.notif-panel {
  position: fixed; top: 78px; right: 28px; width: 380px; max-width: 92vw;
  background: var(--surface); border: 1px solid var(--border-soft);
  border-radius: var(--radius-md); box-shadow: var(--shadow-lg); z-index: 60;
  max-height: 70vh; overflow-y: auto; scrollbar-width: none; -ms-overflow-style: none;
}
.notif-panel::-webkit-scrollbar { display: none; width: 0; height: 0; }
.notif-panel-header { display: flex; align-items: center; justify-content: space-between; padding: 16px 18px; border-bottom: 1px solid var(--border-soft); }
.notif-item { display: flex; gap: 12px; padding: 14px 18px; border-bottom: 1px solid var(--border-soft); cursor: pointer; }
.notif-item:hover { background: var(--surface-alt); }
.notif-item.unread { background: rgba(11,77,162,0.05); }
.notif-item i { color: var(--theme-c3); font-size: 18px; margin-top: 2px; }
.notif-item-title { font-weight: 600; font-size: 14px; }
.notif-item-meta { font-size: 12px; color: var(--text-secondary); margin-top: 2px; }

.drawer-overlay { position: fixed; inset: 0; background: rgba(2,30,70,0.5); z-index: 39; }

.bottom-nav {
  display: none;
  position: fixed; bottom: 0; left: 0; right: 0; height: var(--bottom-nav-h);
  background: var(--surface); border-top: 1px solid var(--border-soft);
  z-index: 45; padding: 6px 4px;
}
.bottom-nav-inner { display: flex; height: 100%; }
.bottom-nav-item {
  flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
  background: none; border: none; color: var(--text-secondary); font-size: 11px; font-weight: 600;
  min-height: 44px;
}
.bottom-nav-item i { font-size: 20px; }
.bottom-nav-item.active { color: var(--theme-c3); }

/* ---------- 7. AUTH SCREENS ---------- */
.auth-screen {
  min-height: 100vh; display: flex; align-items: center; justify-content: center;
  background: var(--gradient-main); position: relative; overflow: hidden; padding: 24px;
}
.auth-screen::before, .auth-screen::after {
  content: ""; position: absolute; width: 480px; height: 480px; border-radius: 50%;
  background: var(--glow); pointer-events: none;
}
.auth-screen::before { top: -160px; left: -160px; }
.auth-screen::after { bottom: -180px; right: -140px; background: radial-gradient(circle, rgba(255,198,11,0.18) 0%, rgba(255,198,11,0) 70%); }

.auth-card {
  position: relative; z-index: 1;
  background: var(--surface); border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg); padding: 44px 40px;
  max-width: 460px; width: 100%;
}
.auth-logo { width: 64px; height: 64px; margin: 0 auto 20px; border-radius: 18px; object-fit: cover; }
.auth-title { text-align: center; font-size: var(--fs-2xl); margin-bottom: 6px; }
.auth-subtitle { text-align: center; color: var(--text-secondary); font-size: 15px; margin-bottom: 24px; }
.program-mini-info {
  background: var(--bg-alt); border-radius: var(--radius-md); padding: 18px 20px; margin-bottom: 24px;
}
.program-mini-info dl { display: grid; grid-template-columns: auto 1fr; gap: 8px 14px; font-size: 14px; }
.program-mini-info dt { color: var(--text-secondary); }
.program-mini-info dd { margin: 0; font-weight: 600; }

.demo-notice {
  display: flex; gap: 10px; align-items: flex-start;
  background: rgba(255,198,11,0.14); border: 1px solid rgba(255,198,11,0.4);
  border-radius: 12px; padding: 12px 14px; font-size: 13px; color: #7a5900; margin-top: 16px;
}
.demo-notice i { flex-shrink: 0; margin-top: 1px; }

.auth-tabs { display: flex; gap: 8px; margin-bottom: 20px; background: var(--bg-alt); padding: 4px; border-radius: 12px; }
.auth-tab { flex: 1; padding: 10px; border: none; background: transparent; border-radius: 9px; font-weight: 600; font-size: 14px; color: var(--text-secondary); }
.auth-tab.active { background: var(--surface); color: var(--navy); box-shadow: var(--shadow-sm); }

.form-group { margin-bottom: 16px; }
.form-label { display: block; font-weight: 600; font-size: 14px; margin-bottom: 6px; }
.form-input, .form-select, .form-textarea {
  width: 100%; padding: 13px 14px; border-radius: 10px; border: 1.5px solid var(--border-soft);
  background: var(--surface); color: var(--text-main); font-size: 16px; font-family: inherit;
  transition: border-color var(--transition);
}
.form-input:focus, .form-select:focus, .form-textarea:focus { border-color: var(--theme-c3); }
.form-textarea { min-height: 100px; resize: vertical; }
.form-error { color: var(--danger); font-size: 13px; margin-top: 6px; display: flex; gap: 6px; align-items: center; }
.form-hint { color: var(--text-secondary); font-size: 13px; margin-top: 6px; }
.otp-inputs { display: flex; gap: 10px; justify-content: center; margin: 8px 0 4px; }
.otp-inputs input {
  width: 48px; height: 56px; text-align: center; font-size: 24px; font-weight: 700;
  border-radius: 10px; border: 1.5px solid var(--border-soft); background: var(--surface); color: var(--text-main);
}
.otp-inputs input:focus { border-color: var(--theme-c3); }

.account-switch-demo { margin-top: 22px; border-top: 1px dashed var(--border-soft); padding-top: 18px; }
.account-switch-demo p { font-size: 13px; color: var(--text-secondary); margin-bottom: 10px; }
.demo-account-btn {
  display: flex; align-items: center; justify-content: space-between; width: 100%;
  padding: 10px 14px; border-radius: 10px; border: 1px solid var(--border-soft);
  background: var(--surface-alt); margin-bottom: 8px; font-size: 13px; font-weight: 600;
}
.demo-account-btn:hover { border-color: var(--theme-c3); }

/* ---------- 8. HERO / DASHBOARD ---------- */
.hero {
  background: var(--gradient-main); border-radius: var(--radius-lg); color: #fff;
  padding: 36px; position: relative; overflow: hidden; margin-bottom: var(--density-gap);
  box-shadow: var(--shadow-lg);
}
.hero::before {
  content: ""; position: absolute; top: -120px; right: -100px; width: 360px; height: 360px;
  border-radius: 50%; background: var(--glow);
}
.hero-grid { display: grid; grid-template-columns: 1.3fr 1fr; gap: 32px; position: relative; z-index: 1; }
.hero-eyebrow { color: var(--gold-soft); font-weight: 700; font-size: 13px; letter-spacing: 0.06em; text-transform: uppercase; margin-bottom: 10px; }
.hero h2 { font-size: var(--fs-3xl); margin-bottom: 6px; }
.hero-subtitle { font-size: var(--fs-lg); color: rgba(255,255,255,0.85); margin-bottom: 20px; }
.hero-meta { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px 24px; margin-bottom: 24px; }
.hero-meta-item { display: flex; gap: 10px; align-items: center; font-size: 14px; }
.hero-meta-item i { color: var(--gold); font-size: 18px; }
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; }

.countdown-card {
  background: rgba(255,255,255,0.14); border: 1px solid rgba(255,255,255,0.22);
  border-radius: var(--radius-md); padding: 24px; backdrop-filter: blur(6px);
}
.countdown-label { font-size: 13px; color: var(--gold-soft); font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; margin-bottom: 14px; }
.countdown-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.countdown-unit { text-align: center; }
.countdown-num {
  font-size: 30px; font-weight: 800; font-variant-numeric: tabular-nums;
  color: #fff; text-shadow: 0 1px 3px rgba(0,0,0,0.35);
}
.countdown-unit-label { font-size: 11px; color: rgba(255,255,255,0.85); text-transform: uppercase; font-weight: 600; }

/* ---------- 9. READINESS CARD ---------- */
.readiness-card { margin-bottom: var(--density-gap); }
.readiness-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px; flex-wrap: wrap; gap: 10px; }
.readiness-progress-track { width: 100%; height: 10px; background: var(--bg-alt); border-radius: 999px; overflow: hidden; margin-bottom: 20px; }
.readiness-progress-fill { height: 100%; background: var(--gradient-gold); border-radius: 999px; transition: width var(--transition); }
.readiness-list { display: flex; flex-direction: column; gap: 10px; }
.readiness-item {
  display: flex; align-items: center; gap: 14px; padding: 12px 14px; border-radius: 12px; background: var(--surface-alt);
}
.readiness-item .check-icon { width: 26px; height: 26px; border-radius: 50%; display: flex; align-items: center; justify-content: center; flex-shrink: 0; font-size: 14px; }
.readiness-item.done .check-icon { background: var(--success); color: #fff; }
.readiness-item.pending .check-icon { background: var(--border-strong); color: var(--text-secondary); }
.readiness-item-text { flex: 1; min-width: 0; }
.readiness-item-title { font-weight: 600; font-size: 15px; }
.readiness-item.done .readiness-item-title { text-decoration: line-through; color: var(--text-secondary); }

/* ---------- 10. GRID / QUICK ACTIONS ---------- */
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--density-gap); }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: var(--density-gap); }
.section { margin-bottom: 32px; }
.section-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.section-head h3 { font-size: var(--fs-xl); }
.section-head .link-more { font-size: 14px; font-weight: 600; color: var(--theme-c3); }

.qa-card { display: flex; flex-direction: column; gap: 10px; }
.qa-icon {
  width: 46px; height: 46px; border-radius: 12px; display: flex; align-items: center; justify-content: center;
  background: var(--gradient-main); color: #fff; font-size: 20px;
}
.qa-title { font-weight: 700; font-size: 16px; }
.qa-desc { color: var(--text-secondary); font-size: 14px; }
.qa-footer { margin-top: 6px; display: flex; align-items: center; justify-content: space-between; gap: 10px; }

/* ---------- 11. ANNOUNCEMENTS ---------- */
.announcement-item { display: flex; gap: 14px; padding: 16px; border-radius: 14px; border: 1px solid var(--border-soft); margin-bottom: 12px; background: var(--surface); }
.announcement-item.unread { border-left: 4px solid var(--theme-c3); }
.announcement-icon { width: 40px; height: 40px; border-radius: 10px; background: color-mix(in srgb, var(--theme-c3) 12%, var(--bg-alt)); display: flex; align-items: center; justify-content: center; color: var(--theme-c3); flex-shrink: 0; }
.announcement-body { flex: 1; min-width: 0; }
.announcement-title-row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 4px; }
.announcement-title { font-weight: 700; font-size: 15px; }
.announcement-content { color: var(--text-secondary); font-size: 14px; margin-bottom: 8px; }
.announcement-meta { display: flex; gap: 14px; font-size: 12px; color: var(--text-secondary); align-items: center; flex-wrap: wrap; }

.toolbar { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin-bottom: 18px; }
.toolbar .form-input { max-width: 260px; }

/* ---------- 12. SCHEDULE ---------- */
.event-detail-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px 24px; margin: 20px 0; }
.event-detail-item { display: flex; gap: 10px; align-items: flex-start; }
.event-detail-item i { color: var(--theme-c3); margin-top: 3px; }
.event-detail-label { font-size: 12px; color: var(--text-secondary); text-transform: uppercase; letter-spacing: 0.03em; }
.event-detail-value { font-weight: 600; }

.timeline { position: relative; padding-left: 28px; }
.timeline::before { content: ""; position: absolute; left: 8px; top: 6px; bottom: 6px; width: 2px; background: var(--border-strong); }
.timeline-item { position: relative; padding-bottom: 22px; }
.timeline-dot { position: absolute; left: -28px; top: 2px; width: 18px; height: 18px; border-radius: 50%; background: var(--gradient-main); border: 3px solid var(--surface); }

/* ---------- 13. CLASS JOIN ---------- */
.join-hero { text-align: center; padding: 40px 24px; }
.join-hero .countdown-grid { max-width: 420px; margin: 0 auto 24px; }
.join-status-badge { margin-bottom: 16px; }
.meet-link-box {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  background: var(--bg-alt); border-radius: 12px; padding: 14px 16px; margin: 16px 0; flex-wrap: wrap;
}
.meet-link-box code { font-size: 14px; word-break: break-all; }
.checklist { display: flex; flex-direction: column; gap: 10px; text-align: left; max-width: 420px; margin: 0 auto; }
.checklist-item { display: flex; gap: 10px; align-items: center; font-size: 14px; }
.checklist-item i { color: var(--success); }

/* ---------- 14. GROUP ---------- */
.group-hero-icon { width: 64px; height: 64px; border-radius: 16px; background: var(--gradient-main); display: flex; align-items: center; justify-content: center; color: #fff; font-size: 28px; margin: 0 auto 16px; }

/* ---------- 15. RECORDINGS ---------- */
.video-frame {
  position: relative; width: 100%; aspect-ratio: 16/9; background: var(--navy-dark);
  border-radius: var(--radius-md); overflow: hidden; display: flex; align-items: center; justify-content: center; color: #fff; margin-bottom: 16px;
}
.video-play-btn { width: 72px; height: 72px; border-radius: 50%; background: rgba(255,255,255,0.16); border: 2px solid rgba(255,255,255,0.4); display: flex; align-items: center; justify-content: center; font-size: 28px; }
.progress-track { height: 8px; background: var(--bg-alt); border-radius: 999px; overflow: hidden; }
.progress-fill { height: 100%; background: var(--gradient-main); }

/* ---------- 16. RESOURCES ---------- */
.resource-item { display: flex; align-items: center; gap: 14px; padding: 14px 16px; border-radius: 14px; border: 1px solid var(--border-soft); margin-bottom: 10px; background: var(--surface); }
.resource-icon { width: 44px; height: 44px; border-radius: 10px; background: color-mix(in srgb, var(--theme-c3) 12%, var(--bg-alt)); display: flex; align-items: center; justify-content: center; color: var(--theme-c3); flex-shrink: 0; }
.resource-info { flex: 1; min-width: 0; }
.resource-title { font-weight: 700; font-size: 15px; }
.resource-meta { font-size: 12px; color: var(--text-secondary); }
.resource-actions { display: flex; gap: 8px; flex-shrink: 0; }

.tab-bar { display: flex; gap: 6px; border-bottom: 1px solid var(--border-soft); margin-bottom: 18px; overflow-x: auto; scrollbar-width: none; -ms-overflow-style: none; }
.tab-bar::-webkit-scrollbar { display: none; width: 0; height: 0; }
.tab-bar button { padding: 10px 16px; background: none; border: none; font-weight: 600; color: var(--text-secondary); border-bottom: 2px solid transparent; white-space: nowrap; }
.tab-bar button.active { color: var(--theme-c3); border-color: var(--theme-accent); }

/* ---------- 17. HELP ---------- */
.help-category-btn {
  display: flex; align-items: center; gap: 12px; padding: 14px 16px; border-radius: 14px;
  border: 1px solid var(--border-soft); background: var(--surface); width: 100%; text-align: left; margin-bottom: 10px;
}
.help-category-btn.selected { border-color: var(--theme-c3); background: color-mix(in srgb, var(--theme-c3) 8%, transparent); }
.ticket-item { padding: 14px 16px; border-radius: 12px; border: 1px solid var(--border-soft); margin-bottom: 10px; }

/* ---------- 18. PROFILE ---------- */
.profile-header { display: flex; align-items: center; gap: 18px; margin-bottom: 24px; }
.profile-avatar { width: 72px; height: 72px; border-radius: 50%; background: var(--gradient-main); color: #fff; display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 24px; }
.info-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
.info-item { padding: 4px 0; }
.info-label { font-size: 12px; color: var(--text-secondary); text-transform: uppercase; letter-spacing: 0.03em; margin-bottom: 3px; }
.info-value { font-weight: 600; }
.activity-row { display: flex; justify-content: space-between; padding: 12px 0; border-bottom: 1px solid var(--border-soft); font-size: 14px; gap: 10px; }
.activity-row:last-child { border-bottom: none; }

/* ---------- 19. SETTINGS PANEL ---------- */
.settings-panel {
  position: fixed; top: 0; right: 0; bottom: 0; width: 400px; max-width: 92vw;
  background: var(--surface); box-shadow: var(--shadow-lg); z-index: 80;
  display: flex; flex-direction: column; transform: translateX(0); transition: transform var(--transition);
}
.settings-header { display: flex; align-items: center; justify-content: space-between; padding: 20px 22px; border-bottom: 1px solid var(--border-soft); }
.settings-body { flex: 1; overflow-y: auto; padding: 20px 22px; scrollbar-width: none; -ms-overflow-style: none; }
.settings-body::-webkit-scrollbar { display: none; width: 0; height: 0; }
.settings-group { margin-bottom: 26px; }
.settings-group-title { font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; color: var(--text-secondary); margin-bottom: 12px; }
.settings-options { display: flex; gap: 8px; flex-wrap: wrap; }
.settings-option-btn {
  padding: 9px 14px; border-radius: 10px; border: 1.5px solid var(--border-soft); background: var(--surface-alt);
  font-size: 13px; font-weight: 600; color: var(--text-main);
}
.settings-option-btn.active { border-color: var(--theme-c3); background: color-mix(in srgb, var(--theme-c3) 10%, transparent); color: var(--theme-c3); }
.settings-overlay { position: fixed; inset: 0; background: rgba(2,30,70,0.45); z-index: 79; }
.toggle-row { display: flex; align-items: center; justify-content: space-between; padding: 10px 0; }
.switch { position: relative; width: 46px; height: 26px; border-radius: 999px; background: var(--border-strong); border: none; flex-shrink: 0; }
.switch::after { content: ""; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; transition: transform var(--transition); }
.switch.on { background: var(--theme-c3); }
.switch.on::after { transform: translateX(20px); }

/* ---------- 20. TOASTS ---------- */
.toast-container { position: fixed; bottom: 24px; right: 24px; z-index: 200; display: flex; flex-direction: column; gap: 10px; max-width: 360px; }
.toast {
  display: flex; align-items: flex-start; gap: 10px; padding: 14px 16px; border-radius: 12px;
  background: var(--surface); box-shadow: var(--shadow-lg); border-left: 4px solid var(--theme-c3);
  animation: toast-in 220ms ease;
}
.toast.success { border-color: var(--success); }
.toast.warning { border-color: var(--warning); }
.toast.error { border-color: var(--danger); }
.toast i { margin-top: 2px; }
@keyframes toast-in { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }

/* ---------- 21. MODALS ---------- */
.modal-overlay { position: fixed; inset: 0; background: rgba(2,30,70,0.5); z-index: 90; display: flex; align-items: center; justify-content: center; padding: 20px; }
.modal-box { background: var(--surface); border-radius: var(--radius-lg); box-shadow: var(--shadow-lg); max-width: 460px; width: 100%; padding: 28px; }
.modal-title { font-size: var(--fs-xl); margin-bottom: 10px; }
.modal-body { color: var(--text-secondary); margin-bottom: 22px; }
.modal-actions { display: flex; gap: 10px; justify-content: flex-end; flex-wrap: wrap; }

/* ---------- 22. EMPTY / ERROR STATES ---------- */
.empty-state { text-align: center; padding: 48px 24px; }
.empty-state-icon { width: 64px; height: 64px; border-radius: 50%; background: var(--bg-alt); display: flex; align-items: center; justify-content: center; margin: 0 auto 16px; font-size: 28px; color: var(--text-secondary); }
.empty-state h3 { margin-bottom: 8px; }
.empty-state p { color: var(--text-secondary); margin-bottom: 18px; }

.skeleton { background: linear-gradient(90deg, var(--bg-alt) 25%, var(--surface-alt) 50%, var(--bg-alt) 75%); background-size: 200% 100%; animation: skeleton-shimmer 1.4s infinite; border-radius: 10px; }
@keyframes skeleton-shimmer { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }
.skeleton-card { height: 120px; margin-bottom: 14px; }

.offline-banner { background: var(--warning); color: #fff; text-align: center; padding: 10px; font-size: 14px; font-weight: 600; }

/* ---------- 23. LOADING OVERLAY ---------- */
.loading-overlay { position: fixed; inset: 0; background: rgba(244,247,252,0.85); z-index: 300; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px; }
.spinner { width: 44px; height: 44px; border-radius: 50%; border: 4px solid var(--border-strong); border-top-color: var(--theme-c3); animation: spin 0.8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- 24. STICKY MOBILE CTA ---------- */
.sticky-cta { position: fixed; left: 0; right: 0; bottom: calc(var(--bottom-nav-h) + 10px); padding: 0 16px; z-index: 44; display: none; }

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

@media (max-width: 900px) {
  .sidebar {
    transform: translateX(-100%);
    padding-bottom: calc(20px + var(--bottom-nav-h));
  }
  .app-shell.mobile-drawer-open .sidebar { transform: translateX(0); z-index: 46; }
  .app-shell.mobile-drawer-open .bottom-nav { display: none; }
  .main-col { margin-left: 0; }
  .app-shell.sidebar-collapsed .main-col { margin-left: 0; }
  .hamburger-btn { display: inline-flex; }
  .sidebar-collapse-btn { display: none; }
  .bottom-nav { display: block; }
  .content { padding: 18px 16px calc(var(--bottom-nav-h) + 88px); }
  .grid-3, .grid-2 { grid-template-columns: 1fr; }
  .info-grid, .event-detail-grid { grid-template-columns: 1fr; }
  .account-switcher { display: none; }
  .modal-box { max-width: 100%; width: 100%; max-height: 92vh; overflow-y: auto; scrollbar-width: none; -ms-overflow-style: none; border-radius: var(--radius-lg) var(--radius-lg) 0 0; position: fixed; bottom: 0; left: 0; }
  .modal-box::-webkit-scrollbar { display: none; width: 0; height: 0; }
  .modal-overlay { align-items: flex-end; padding: 0; }
  .hero { padding: 24px 20px; }
  .hero h2 { font-size: 26px; }
  .hero-subtitle { font-size: 15px; }
  .hero-eyebrow { font-size: 12px; }
  .hero-actions .btn { font-size: 14px; padding: 11px 16px; }
  .countdown-card-corner { padding: 16px; }
  .countdown-num { font-size: 26px; }
}

@media (max-width: 480px) {
  .otp-inputs input { width: 40px; height: 48px; font-size: 20px; }
  .auth-card { padding: 30px 22px; }
  .countdown-num { font-size: 26px; }
  .topbar { padding: 0 16px; }
  .hero h2 { font-size: 22px; }
  .hero { padding: 20px 16px; }
  .readiness-progress-track, .readiness-list { margin-left: 0; margin-right: 0; }
  .qa-card, .card { padding: 16px; }
}

/* =========================================================
   26. PROGRAM THEME SYSTEM
   Each program supplies --theme-c1/c2/c3 (gradient stops),
   --theme-accent, --theme-accent-soft and --theme-glow via
   applyProgramTheme() in app.js. Every "themed" surface below
   reads these variables instead of the fixed navy/gold tokens,
   so the whole portal re-skins itself per program automatically.
   ========================================================= */
:root {
  --theme-gradient: var(--gradient-main);
  --theme-c1: var(--navy-dark);
  --theme-c2: var(--navy);
  --theme-c3: var(--royal-blue);
  --theme-accent: var(--gold);
  --theme-accent-soft: var(--gold-soft);
  --theme-glow: rgba(255, 198, 11, 0.28);
}

/* Sidebar + auth screens follow the active program theme */
.sidebar { background: var(--theme-gradient); }
.auth-screen { background: var(--theme-gradient); }
.auth-screen::after { background: radial-gradient(circle, var(--theme-glow) 0%, rgba(255,198,11,0) 70%); }
.brand-sub, .demo-badge, .countdown-label { color: var(--theme-accent-soft); }
.nav-item.active { background: color-mix(in srgb, var(--theme-accent) 18%, transparent); box-shadow: inset 3px 0 0 var(--theme-accent); }
.auth-tab.active { color: var(--theme-c2); }

.btn-theme-gold {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-size: 16px; font-weight: 700; font-family: inherit;
  padding: 13px 24px; border-radius: 12px; border: none; min-height: 44px;
  color: var(--theme-c1);
  background: linear-gradient(135deg, var(--theme-accent) 0%, var(--theme-accent-soft) 100%);
  box-shadow: 0 8px 22px var(--theme-glow);
  transition: transform var(--transition), box-shadow var(--transition);
}
.btn-theme-gold:hover { transform: translateY(-2px); box-shadow: 0 12px 30px var(--theme-glow); }
.btn-theme-gold:active { transform: translateY(0); }

.badge-theme {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 13px; font-weight: 700; padding: 5px 14px; border-radius: 999px;
  background: color-mix(in srgb, var(--theme-accent) 22%, transparent);
  color: var(--theme-c2);
}
.badge-theme::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--theme-accent); }

/* ---------- Themed hero on dashboard home ---------- */
.theme-hero {
  background: var(--theme-gradient);
  position: relative; overflow: hidden;
}
.theme-hero::before { background: radial-gradient(circle, var(--theme-glow) 0%, rgba(0,0,0,0) 70%); }
.hero-grid-single { grid-template-columns: 1fr; max-width: 640px; }
.hero-grid-single .hero-actions { margin-top: 4px; }

.countdown-card-corner {
  position: absolute; right: 28px; bottom: 28px; z-index: 2;
  min-width: 260px;
}
@media (max-width: 900px) {
  .countdown-card-corner { position: static; margin-top: 22px; width: 100%; background: rgba(0,0,0,0.4); border-color: rgba(255,255,255,0.32); }
}

/* ---------- Ambient signature animation per theme ---------- */
/* Pink theme ("blink"): a slow, soft double-pulse of light sweeping the hero,
   evoking a gentle heartbeat / blooming flower. */
@keyframes theme-blink-sweep {
  0%, 100% { opacity: 0.22; }
  8%  { opacity: 0.55; }
  14% { opacity: 0.22; }
  20% { opacity: 0.5; }
  28%, 60% { opacity: 0.22; }
}
html.theme-anim-blink .theme-hero::after {
  content: ""; position: absolute; inset: 0; pointer-events: none; z-index: 1;
  background: radial-gradient(circle at 25% 20%, var(--theme-accent-soft) 0%, transparent 45%);
  animation: theme-blink-sweep 6s ease-in-out infinite;
}

/* Gold theme ("wave"): a slow horizontal shimmer, like light moving across silk. */
@keyframes theme-wave-shimmer {
  0% { transform: translateX(-30%) skewX(-8deg); opacity: 0; }
  15% { opacity: 0.35; }
  50% { transform: translateX(10%) skewX(-8deg); opacity: 0.2; }
  85% { opacity: 0.35; }
  100% { transform: translateX(60%) skewX(-8deg); opacity: 0; }
}
html.theme-anim-wave .theme-hero::after {
  content: ""; position: absolute; top: -20%; bottom: -20%; width: 40%; z-index: 1; pointer-events: none;
  background: linear-gradient(90deg, transparent 0%, var(--theme-accent-soft) 50%, transparent 100%);
  filter: blur(18px);
  animation: theme-wave-shimmer 7s ease-in-out infinite;
}
html[data-motion="reduced"] .theme-hero::after { animation: none !important; opacity: 0.18; }

/* ---------- Program access screen (post "Gunakan Pautan Akses Saya") ----------
   Pure theme gradient + ambient animation (no poster imagery), matching the
   dashboard hero's look for visual consistency. */
.program-access-screen { background: var(--theme-gradient); position: relative; overflow: hidden; }
.program-access-screen::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(circle, var(--theme-glow) 0%, rgba(0,0,0,0) 70%);
}
html.theme-anim-blink .program-access-screen::after {
  content: ""; position: absolute; inset: 0; pointer-events: none; z-index: 1;
  background: radial-gradient(circle at 25% 20%, var(--theme-accent-soft) 0%, transparent 45%);
  animation: theme-blink-sweep 6s ease-in-out infinite;
}
html.theme-anim-wave .program-access-screen::after {
  content: ""; position: absolute; top: -20%; bottom: -20%; width: 40%; z-index: 1; pointer-events: none;
  background: linear-gradient(90deg, transparent 0%, var(--theme-accent-soft) 50%, transparent 100%);
  filter: blur(18px);
  animation: theme-wave-shimmer 7s ease-in-out infinite;
}
.program-access-card {
  position: relative; z-index: 2; overflow: hidden; padding: 0; max-width: 480px;
  border-radius: var(--radius-lg); box-shadow: var(--shadow-lg);
  background: color-mix(in srgb, var(--theme-c1) 78%, black 10%);
  border: 1px solid rgba(255,255,255,0.10);
}
.program-access-content { position: relative; z-index: 1; padding: 44px 36px 40px; }
.program-access-content .auth-logo { filter: drop-shadow(0 4px 14px rgba(0,0,0,0.35)); }
.glass-dark {
  background: rgba(255,255,255,0.08); border: 1px solid rgba(255,255,255,0.16);
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
}
.glass-dark dt { color: rgba(255,255,255,0.65); }
.glass-dark dd { color: #fff; }

/* ---------- Status pill (top bar) — plain status + avatar, no dropdown ---------- */
.status-pill { display: flex; align-items: center; gap: 10px; }
.status-pill-badge { white-space: nowrap; }
.status-avatar-btn {
  width: 38px; height: 38px; border-radius: 50%; overflow: hidden;
  border: 2px solid var(--border-strong); background: var(--surface-alt);
  display: flex; align-items: center; justify-content: center; color: var(--text-secondary);
  flex-shrink: 0; transition: border-color var(--transition), transform var(--transition);
}
.status-avatar-btn:hover { border-color: var(--theme-accent); transform: scale(1.05); }
.status-avatar-btn img { width: 100%; height: 100%; object-fit: cover; }
@media (max-width: 900px) { .status-pill-badge { display: none; } }

/* ---------- Hover float + themed illumination on cards / tiles ---------- */
.card.hoverable, .qa-card, .resource-item, .announcement-item, .ticket-item, .help-category-btn, .demo-account-btn {
  transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
}
.card.hoverable:hover, .qa-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 18px 40px -8px var(--theme-glow), var(--shadow-md);
  border-color: color-mix(in srgb, var(--theme-accent) 40%, var(--border-soft));
}
.resource-item:hover, .announcement-item:hover, .help-category-btn:hover, .demo-account-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 26px -6px var(--theme-glow);
  border-color: color-mix(in srgb, var(--theme-accent) 35%, var(--border-soft));
}
.demo-account-btn.selected { border-color: var(--theme-accent); background: color-mix(in srgb, var(--theme-accent) 10%, var(--surface-alt)); }

/* Themed quick-action icon tiles */
.qa-icon {
  background: linear-gradient(135deg, var(--theme-c2) 0%, var(--theme-c3) 100%);
  box-shadow: 0 6px 16px var(--theme-glow);
}

/* Readiness / countdown accents follow theme */
.readiness-progress-fill { background: linear-gradient(90deg, var(--theme-accent), var(--theme-accent-soft)); }
.countdown-card { background: rgba(0,0,0,0.28); border: 1px solid rgba(255,255,255,0.28); box-shadow: 0 10px 30px var(--theme-glow); }

/* Logout button reads clearly on the themed sidebar */
.logout-btn.btn-outline {
  color: #fff; border-color: rgba(255,255,255,0.35); background: rgba(255,255,255,0.06);
}
.logout-btn.btn-outline:hover { background: rgba(255,255,255,0.14); border-color: rgba(255,255,255,0.55); }

/* Sidebar collapsed: hide status text bits that no longer fit */
.app-shell.sidebar-collapsed .status-pill-badge { display: none; }

/* ---------------------------------------------------------
   27. ICON SYSTEM
--------------------------------------------------------- */
.icon-svg-wrap { display: inline-flex; align-items: center; justify-content: center; line-height: 0; }
.icon-svg-wrap svg { display: block; }
i[data-lucide] { display: inline-flex; }

/* ---------------------------------------------------------
   28. LOGO GLOW (behind logo, tinted to the active program theme)
--------------------------------------------------------- */
.brand-logo-wrap, .auth-logo-wrap {
  position: relative; display: inline-flex; align-items: center; justify-content: center;
}
.brand-logo-wrap::before {
  content: ""; position: absolute; inset: -8px; border-radius: 50%;
  background: radial-gradient(circle, var(--theme-accent, var(--gold)) 0%, transparent 70%);
  opacity: 0.55; filter: blur(6px); z-index: 0; pointer-events: none;
}
.brand-logo-wrap .brand-logo { position: relative; z-index: 1; }

.auth-logo-wrap {
  display: flex; margin: 0 auto 20px;
}
.auth-logo-wrap::before {
  content: ""; position: absolute; inset: -14px; border-radius: 50%;
  background: radial-gradient(circle, var(--gold) 0%, transparent 70%);
  opacity: 0.45; filter: blur(14px); z-index: 0; pointer-events: none;
}
.auth-logo-wrap-themed::before {
  background: radial-gradient(circle, var(--theme-accent) 0%, transparent 70%);
  opacity: 0.6; filter: blur(18px);
}
.auth-logo-wrap .auth-logo { position: relative; z-index: 1; margin: 0; }

