/* ==========================================================================
   Rotaract Business Connect - Design System (Modern Welcoming Light Mode)
   Inspired by Rotaract brand colors (Royal Navy, Rotary Gold & Cranberry)
   ========================================================================== */

:root {
  /* Brand Colors */
  --color-primary: #1e3a8a;          /* Rotaract Royal Navy */
  --color-primary-hover: #1d4ed8;    /* Bright Navy Blue */
  --color-primary-light: #eff6ff;    /* Soft blue tint */
  --color-primary-subtle: #dbeafe;   /* Light accent background */
  
  --color-secondary: #059669;        /* Success Emerald */
  --color-secondary-hover: #047857;
  --color-secondary-light: #ecfdf5;

  --color-accent-gold: #d97706;      /* Rotary Gold / Amber */
  --color-accent-gold-light: #fef3c7;
  --color-accent-cranberry: #be185d; /* Rotaract Cranberry */
  --color-accent-cranberry-light: #fdf2f8;
  
  --color-accent-orange: #f97316;
  --color-accent-red: #dc2626;
  --color-danger: #ef4444;
  --color-danger-light: #fef2f2;

  /* Neutrals - Welcoming Light Mode */
  --color-white: #ffffff;
  --color-bg: #f8fafc;               /* Slate-50 ultra-clean background */
  --color-surface: #ffffff;          /* Pure white card surface */
  --color-surface-subtle: #f1f5f9;   /* Slate-100 hover / active surface */
  --color-surface-muted: #e2e8f0;    /* Slate-200 dividers */

  --color-border: #e2e8f0;           /* Clean subtle border */
  --color-border-hover: #cbd5e1;     /* Slate-300 */
  --color-border-focus: #1e3a8a;     /* Navy focus ring */

  --color-text-primary: #0f172a;     /* Slate-900 high contrast */
  --color-text-secondary: #334155;   /* Slate-700 body text */
  --color-text-muted: #64748b;       /* Slate-500 hints & guides */
  --color-text-light: #94a3b8;       /* Slate-400 placeholder */

  /* Modern Design Tokens */
  --radius-xs: 6px;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 20px;
  --radius-2xl: 24px;
  --radius-full: 9999px;

  /* Shadows - Layered Elevation for Light Mode */
  --shadow-xs: 0 1px 2px 0 rgba(15, 23, 42, 0.04);
  --shadow-sm: 0 1px 3px 0 rgba(15, 23, 42, 0.06), 0 1px 2px -1px rgba(15, 23, 42, 0.04);
  --shadow-md: 0 4px 12px -2px rgba(15, 23, 42, 0.06), 0 2px 6px -2px rgba(15, 23, 42, 0.04);
  --shadow-lg: 0 12px 24px -4px rgba(15, 23, 42, 0.08), 0 4px 8px -4px rgba(15, 23, 42, 0.04);
  --shadow-xl: 0 20px 32px -6px rgba(15, 23, 42, 0.1), 0 8px 16px -6px rgba(15, 23, 42, 0.06);
  --shadow-2xl: 0 25px 50px -12px rgba(15, 23, 42, 0.18);
  --shadow-primary-glow: 0 0 24px rgba(30, 58, 138, 0.15);

  /* Animation Timings */
  --t-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
  --t-normal: 250ms cubic-bezier(0.4, 0, 0.2, 1);
  --t-slow: 400ms cubic-bezier(0.4, 0, 0.2, 1);
}

* {
  box-sizing: border-box;
}

html, body {
  height: 100%;
}

body {
  margin: 0;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  color: var(--color-text-secondary);
  background-color: var(--color-bg);
  overflow-x: hidden;
  position: relative;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Subtle ambient background glow */
body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: 
    radial-gradient(circle at 12% 15%, rgba(30, 58, 138, 0.04) 0%, transparent 45%),
    radial-gradient(circle at 88% 85%, rgba(217, 119, 6, 0.03) 0%, transparent 45%);
  z-index: -1;
  pointer-events: none;
}

.skip-link {
  position: absolute;
  left: -9999px;
  z-index: 1000;
}

.skip-link:focus {
  left: 16px;
  top: 16px;
  background: var(--color-primary);
  color: #fff;
  padding: 10px 16px;
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-lg);
  font-weight: 600;
}

/* ==========================================================================
   Main Layout Structure
   ========================================================================== */

.layout {
  display: flex;
  gap: 28px;
  padding: 28px;
  min-height: 100vh;
  max-width: 1360px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

/* --------------------------------------------------------------------------
   Sidebar Navigation (Desktop)
   -------------------------------------------------------------------------- */

.sidebar {
  width: 340px;
  background: var(--color-surface);
  border-radius: var(--radius-2xl);
  padding: 0;
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow-md);
  height: calc(100vh - 56px);
  position: sticky;
  top: 28px;
  align-self: flex-start;
  display: flex;
  flex-direction: column;
  overflow: hidden; /* Header remains fixed; content scrolls */
  transition: box-shadow var(--t-fast);
}

.sidebar:hover {
  box-shadow: var(--shadow-lg);
}

.sidebar__header {
  padding: 24px 24px 18px;
  border-bottom: 1px solid var(--color-border);
  text-align: center;
  flex-shrink: 0;
  background: var(--color-surface);
  z-index: 2;
  box-shadow: 0 4px 12px -4px rgba(15, 23, 42, 0.03);
}

.sidebar__content {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding: 18px 20px 24px;
  scrollbar-width: thin;
  scrollbar-color: var(--color-border) transparent;
}

.sidebar__content::-webkit-scrollbar {
  width: 5px;
}

.sidebar__content::-webkit-scrollbar-thumb {
  background-color: var(--color-border);
  border-radius: var(--radius-full);
}

.sidebar__logo-wrap {
  display: flex;
  justify-content: center;
  align-items: center;
  margin-bottom: 10px;
}

.sidebar__logo {
  height: auto;
  max-height: 46px;
  max-width: 175px;
  width: auto;
  object-fit: contain;
  transition: transform var(--t-fast);
}

.sidebar__logo:hover {
  transform: scale(1.02);
}

.sidebar__brand-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  border-radius: var(--radius-full);
  background: var(--color-primary-light);
  color: var(--color-primary);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin-bottom: 8px;
}

.sidebar__title {
  margin: 0;
  font-weight: 800;
  font-size: 20px;
  color: var(--color-text-primary);
  letter-spacing: -0.02em;
}

.sidebar__subtitle {
  margin: 6px 0 0;
  font-size: 13px;
  line-height: 1.45;
  color: var(--color-text-muted);
}

.question-nav {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.question-nav__item {
  display: flex;
  gap: 12px;
  align-items: center;
  padding: 12px 14px;
  border-radius: var(--radius-md);
  text-decoration: none;
  color: var(--color-text-secondary);
  border: 1px solid transparent;
  background: transparent;
  transition: all var(--t-fast);
  font-size: 14px;
}

.question-nav__item:hover {
  background: var(--color-surface-subtle);
  color: var(--color-text-primary);
  border-color: var(--color-border);
}

.question-nav__item--current {
  border-color: #bfdbfe;
  background: var(--color-primary-light);
  color: var(--color-primary);
  font-weight: 600;
  box-shadow: var(--shadow-xs);
}

.question-nav__item--completed {
  color: var(--color-secondary);
}

.question-nav__item--completed:hover {
  background: var(--color-secondary-light);
}

.question-nav__number {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--color-surface-subtle);
  border: 1px solid var(--color-border);
  color: var(--color-text-muted);
  font-size: 12px;
  font-weight: 700;
  transition: all var(--t-fast);
  flex-shrink: 0;
}

.question-nav__item--current .question-nav__number {
  background: var(--color-primary);
  color: #fff;
  border-color: var(--color-primary);
  box-shadow: 0 2px 6px rgba(30, 58, 138, 0.25);
}

.question-nav__item--completed .question-nav__number {
  background: var(--color-secondary);
  color: #fff;
  border-color: var(--color-secondary);
}

.question-nav__text {
  flex: 1;
  line-height: 1.35;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.question-nav__status {
  font-size: 10px;
  color: var(--color-text-muted);
  text-transform: uppercase;
  font-weight: 700;
  letter-spacing: 0.05em;
  padding: 2px 6px;
  border-radius: var(--radius-xs);
  background: var(--color-surface-subtle);
}

.question-nav__item--completed .question-nav__status {
  background: var(--color-secondary-light);
  color: var(--color-secondary);
}

.question-nav__item--current .question-nav__status {
  background: #bfdbfe;
  color: var(--color-primary);
}

.question-nav__status:empty {
  display: none;
}

/* --------------------------------------------------------------------------
   Main Content Area
   -------------------------------------------------------------------------- */

.main {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 24px;
  min-height: 0;
  max-height: calc(100vh - 56px);
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--color-border) transparent;
  box-sizing: border-box;
  padding-bottom: 70px;
}

/* Hidden by default; shown on small screens */
.question-nav--mobile {
  display: none;
}

/* Header & Progress */
.header {
  display: flex;
  align-items: center;
  gap: 16px;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  padding: 18px 28px;
  box-shadow: var(--shadow-sm);
  position: relative;
  height: 76px;
  min-height: 76px;
  flex-shrink: 0;
}

.header__progress {
  flex: 1;
  width: 100%;
}

.progress-info {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
  font-size: 13px;
  font-weight: 600;
  color: var(--color-text-secondary);
}

.progress-bar {
  width: 100%;
  height: 8px;
  background: var(--color-surface-subtle);
  border-radius: var(--radius-full);
  overflow: hidden;
  border: 1px solid var(--color-border);
}

.progress-bar__fill {
  height: 100%;
  width: 0%;
  background: var(--color-primary);
  transition: width 0.35s ease-out;
  border-radius: var(--radius-full);
}

/* --------------------------------------------------------------------------
   Question Card Container
   -------------------------------------------------------------------------- */

.question-container {
  flex: 1;
  display: flex;
  flex-direction: column;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-2xl);
  padding: 36px 40px;
  box-shadow: var(--shadow-sm);
  position: relative;
  overflow: visible;
  min-height: 0;
  transition: box-shadow var(--t-fast);
}

.question-container:hover {
  box-shadow: var(--shadow-md);
}

.question {
  display: flex;
  flex-direction: column;
  gap: 20px;
  min-height: 0;
  flex: 1;
}

.question__logos {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  margin-bottom: 4px;
  flex-shrink: 0;
  width: 100%;
}

.question__logo--rzi {
  height: auto;
  max-height: 90px;
  max-width: 320px;
  width: auto;
  object-fit: contain;
  transition: transform var(--t-normal);
}

.question__header {
  min-height: 100px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 8px 0;
  gap: 6px;
  flex-shrink: 0;
}

.question__category-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  border-radius: var(--radius-full);
  background: var(--color-primary-light);
  color: var(--color-primary);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-bottom: 4px;
}

.question__title {
  font-size: 26px;
  font-weight: 800;
  text-align: center;
  color: var(--color-text-primary);
  letter-spacing: -0.025em;
  line-height: 1.3;
  margin: 0;
}

.question__required {
  color: var(--color-accent-cranberry);
  margin-left: 4px;
  font-weight: 700;
}

.question__subtitle {
  text-align: center;
  color: var(--color-text-secondary);
  font-size: 15px;
  line-height: 1.5;
  margin: 4px 0 0 0;
  max-width: 580px;
}

.question__subtitle a {
  color: var(--color-primary);
  text-decoration: underline;
  font-weight: 600;
}

.question__subtitle a:hover {
  color: var(--color-primary-hover);
}

.question__hint {
  text-align: center;
  color: var(--color-text-muted);
  font-size: 13px;
  line-height: 1.4;
  margin: 4px 0 0 0;
  max-width: 520px;
}

.question__subtitle:empty,
.question__hint:empty {
  display: none;
}

/* --------------------------------------------------------------------------
   Question Input Controls (Light Mode Form Elements)
   -------------------------------------------------------------------------- */

.question__options {
  display: flex;
  flex-direction: column;
  gap: 16px;
  align-items: center;
  width: 100%;
  max-width: 580px;
  margin: 0 auto;
}

.intro-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  text-align: center;
  max-width: 600px;
  margin: 0 auto;
}

.intro-highlights {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin: 12px 0 20px;
  width: 100%;
}

.intro-highlight-card {
  background: var(--color-surface-subtle);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 16px 12px;
  text-align: center;
}

.intro-highlight-card__icon {
  font-size: 24px;
  margin-bottom: 8px;
}

.intro-highlight-card__title {
  font-size: 13px;
  font-weight: 700;
  color: var(--color-text-primary);
  margin-bottom: 4px;
}

.intro-highlight-card__desc {
  font-size: 11px;
  color: var(--color-text-muted);
  line-height: 1.3;
}

/* Form Inputs */
.text-input,
.textarea-input,
select.text-input {
  width: 100%;
  padding: 16px 20px;
  border: 1.5px solid var(--color-border);
  border-radius: var(--radius-lg);
  font: inherit;
  font-size: 16px;
  background: var(--color-white);
  color: var(--color-text-primary);
  transition: all var(--t-fast);
  box-shadow: var(--shadow-xs);
  text-align: left;
}

.text-input:hover,
.textarea-input:hover,
select.text-input:hover {
  border-color: var(--color-border-hover);
}

.text-input:focus,
.textarea-input:focus,
select.text-input:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 4px rgba(30, 58, 138, 0.12);
  background: var(--color-white);
}

.text-input::placeholder,
.textarea-input::placeholder {
  color: var(--color-text-light);
}

/* Auto-Expanding Textarea */
.textarea-input {
  min-height: 120px;
  line-height: 1.6;
  resize: none; /* Dynamically auto-expands on input */
  overflow-y: hidden;
  transition: border-color var(--t-fast), box-shadow var(--t-fast);
}

/* ==========================================================================
   Custom Searchable Combobox / Dropdown Component
   ========================================================================== */

.custom-select {
  position: relative;
  width: 100%;
  z-index: 30;
}

.custom-select.is-open {
  z-index: 1000;
}

.custom-select__trigger {
  width: 100%;
  padding: 16px 20px;
  border: 1.5px solid var(--color-border);
  border-radius: var(--radius-lg);
  background: var(--color-white);
  color: var(--color-text-primary);
  font: inherit;
  font-size: 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  box-shadow: var(--shadow-xs);
  transition: all var(--t-fast);
  text-align: left;
}

.custom-select__trigger:hover {
  border-color: var(--color-border-hover);
  background: var(--color-surface-subtle);
}

.custom-select.is-open .custom-select__trigger,
.custom-select__trigger:focus-visible {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 4px rgba(30, 58, 138, 0.12);
  background: var(--color-white);
}

.custom-select__value {
  flex: 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-weight: 500;
}

.custom-select__value.is-placeholder {
  color: var(--color-text-light);
  font-weight: 400;
}

.custom-select__chevron {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  color: var(--color-text-muted);
  transition: transform var(--t-fast);
}

.custom-select.is-open .custom-select__chevron {
  transform: rotate(180deg);
  color: var(--color-primary);
}

/* Dropdown Menu Popover */
.custom-select__dropdown {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  background: var(--color-white);
  border: 1.5px solid var(--color-border);
  border-radius: var(--radius-xl);
  box-shadow: 0 20px 50px -10px rgba(15, 23, 42, 0.28), 0 0 0 1px rgba(15, 23, 42, 0.08);
  z-index: 9999;
  display: none;
  flex-direction: column;
  overflow: hidden;
  animation: dropdownPop 0.18s cubic-bezier(0.16, 1, 0.3, 1);
  max-height: 360px;
}

.custom-select__dropdown.is-dropup {
  top: auto;
  bottom: calc(100% + 8px);
  box-shadow: 0 -20px 50px -10px rgba(15, 23, 42, 0.28), 0 0 0 1px rgba(15, 23, 42, 0.08);
}

@keyframes dropdownPop {
  0% {
    opacity: 0;
    transform: translateY(-6px) scale(0.98);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.custom-select.is-open .custom-select__dropdown {
  display: flex;
}

/* Search Bar Inside Dropdown */
.custom-select__search-box {
  position: relative;
  display: flex;
  align-items: center;
  padding: 12px 16px;
  border-bottom: 1px solid var(--color-border);
  background: var(--color-surface-subtle);
  flex-shrink: 0;
}

.custom-select__search-icon {
  position: absolute;
  left: 28px;
  width: 16px;
  height: 16px;
  color: var(--color-text-muted);
  pointer-events: none;
}

.custom-select__search-input {
  width: 100%;
  padding: 10px 32px 10px 36px;
  border: 1.5px solid var(--color-border);
  border-radius: var(--radius-md);
  font: inherit;
  font-size: 14px;
  background: var(--color-white);
  color: var(--color-text-primary);
  outline: none;
  transition: border-color var(--t-fast), box-shadow var(--t-fast);
}

.custom-select__search-input:focus {
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(30, 58, 138, 0.1);
}

.custom-select__search-clear {
  position: absolute;
  right: 24px;
  background: none;
  border: none;
  color: var(--color-text-muted);
  cursor: pointer;
  padding: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
}

.custom-select__search-clear:hover {
  color: var(--color-text-primary);
}

/* Options Scroller List */
.custom-select__options {
  list-style: none;
  margin: 0;
  padding: 8px;
  overflow-y: auto;
  max-height: 280px;
  scrollbar-width: thin;
  scrollbar-color: var(--color-border) transparent;
}

.custom-select__options::-webkit-scrollbar {
  width: 6px;
}

.custom-select__options::-webkit-scrollbar-thumb {
  background-color: var(--color-border);
  border-radius: var(--radius-full);
}

.custom-select__option {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 16px;
  border-radius: var(--radius-md);
  font-size: 14px;
  color: var(--color-text-secondary);
  cursor: pointer;
  transition: all var(--t-fast);
}

.custom-select__option:hover,
.custom-select__option.is-highlighted {
  background: var(--color-primary-light);
  color: var(--color-primary);
}

.custom-select__option.is-selected {
  background: var(--color-primary);
  color: #ffffff;
  font-weight: 700;
}

.custom-select__option.is-selected:hover {
  background: var(--color-primary-hover);
  color: #ffffff;
}

.custom-select__check {
  font-size: 14px;
  font-weight: 800;
  color: #ffffff;
}

.custom-select__no-results {
  padding: 24px 16px;
  text-align: center;
  color: var(--color-text-muted);
  font-size: 14px;
  font-style: italic;
}

/* Club Option Details & Badges */
.club-option__content {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1;
}

.club-option__name {
  font-size: 14px;
  font-weight: 600;
  color: inherit;
  line-height: 1.35;
}

.club-option__meta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 11px;
}

.club-badge {
  display: inline-block;
  padding: 1px 7px;
  border-radius: var(--radius-full);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.club-badge--community {
  background: #ecfdf5;
  color: #059669;
  border: 1px solid rgba(5, 150, 105, 0.2);
}

.club-badge--university {
  background: #eff6ff;
  color: #2563eb;
  border: 1px solid rgba(37, 99, 235, 0.2);
}

.custom-select__option.is-selected .club-badge {
  background: rgba(255, 255, 255, 0.25);
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.4);
}

.club-id-tag {
  color: var(--color-text-muted);
  font-family: monospace;
  font-size: 10px;
}

.custom-select__option.is-selected .club-id-tag {
  color: rgba(255, 255, 255, 0.8);
}

/* Prompt Card when District is not selected yet */
.district-prompt-card {
  padding: 32px 24px;
  border-radius: var(--radius-lg);
  background: var(--color-primary-light);
  border: 1.5px dashed rgba(30, 58, 138, 0.25);
  text-align: center;
  margin-top: 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.district-prompt-icon {
  font-size: 32px;
  line-height: 1;
}

.district-prompt-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--color-primary);
  margin: 0;
}

.district-prompt-desc {
  font-size: 14px;
  color: var(--color-text-secondary);
  max-width: 440px;
  line-height: 1.5;
  margin: 0;
}

/* Option Cards (Radio & Checkbox) */
.option {
  position: relative;
  width: 100%;
}

.option__input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.option__label {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 14px;
  padding: 16px 20px;
  border: 1.5px solid var(--color-border);
  border-radius: var(--radius-lg);
  background: var(--color-white);
  cursor: pointer;
  transition: all var(--t-fast);
  color: var(--color-text-secondary);
  font-weight: 500;
  box-shadow: var(--shadow-xs);
}

.option__label:hover {
  border-color: var(--color-primary);
  background: var(--color-surface-subtle);
  color: var(--color-text-primary);
}

.option__input:checked + .option__label {
  border-color: var(--color-primary);
  background: var(--color-primary-light);
  color: var(--color-primary);
  font-weight: 600;
  box-shadow: 0 2px 8px rgba(30, 58, 138, 0.12);
}

/* Custom indicator dot */
.option__label::before {
  content: '';
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 2px solid var(--color-border-hover);
  background: var(--color-white);
  flex-shrink: 0;
  transition: all var(--t-fast);
}

.option__input:checked + .option__label::before {
  border-color: var(--color-primary);
  background: radial-gradient(circle, var(--color-primary) 40%, #ffffff 45%);
}

/* --------------------------------------------------------------------------
   Review Screen Styles
   -------------------------------------------------------------------------- */

.review-container {
  width: 100%;
  max-width: 100%;
}

.review-header-note {
  background: var(--color-primary-light);
  border: 1px solid #bfdbfe;
  border-radius: var(--radius-md);
  padding: 12px 18px;
  font-size: 14px;
  color: var(--color-primary);
  margin-bottom: 20px;
  text-align: center;
  font-weight: 500;
}

.review-list {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  width: 100%;
}

.review-item {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 18px 20px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  background: var(--color-surface-subtle);
  transition: all var(--t-fast);
  box-shadow: var(--shadow-xs);
}

.review-item:hover {
  background: var(--color-white);
  border-color: var(--color-border-hover);
  box-shadow: var(--shadow-sm);
}

.review-item--full {
  grid-column: 1 / -1;
}

.review-key {
  color: var(--color-text-muted);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.review-value {
  color: var(--color-text-primary);
  font-size: 15px;
  line-height: 1.5;
  font-weight: 600;
  word-break: break-word;
}

.review-value--textarea {
  font-weight: 400;
  white-space: pre-wrap;
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: 12px 16px;
  margin-top: 4px;
  max-height: 180px;
  overflow-y: auto;
}

/* --------------------------------------------------------------------------
   Footer & Buttons
   -------------------------------------------------------------------------- */

.footer {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  padding: 18px 28px;
  box-shadow: var(--shadow-sm);
}

.footer__content {
  display: flex;
  align-items: center;
  gap: 16px;
  justify-content: space-between;
}

.footer__content .btn {
  min-width: 140px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 26px;
  border-radius: var(--radius-md);
  border: 1.5px solid transparent;
  font-weight: 600;
  font-size: 15px;
  cursor: pointer;
  transition: all var(--t-fast);
  text-align: center;
  text-decoration: none;
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none !important;
}

.btn--secondary {
  background: var(--color-white);
  border-color: var(--color-border);
  color: var(--color-text-secondary);
}

.btn--secondary:hover:not(:disabled) {
  background: var(--color-surface-subtle);
  border-color: var(--color-border-hover);
  color: var(--color-text-primary);
  transform: translateY(-1px);
}

.btn--primary {
  background: linear-gradient(135deg, var(--color-primary), var(--color-primary-hover));
  color: #fff;
  border-color: transparent;
  box-shadow: 0 4px 12px rgba(30, 58, 138, 0.2);
}

.btn--primary:hover:not(:disabled) {
  background: linear-gradient(135deg, var(--color-primary-hover), #2563eb);
  box-shadow: 0 6px 16px rgba(30, 58, 138, 0.3);
  transform: translateY(-1px);
}

.btn--success {
  background: linear-gradient(135deg, var(--color-secondary), #10b981);
  color: #fff;
  font-weight: 700;
  font-size: 16px;
  padding: 16px 32px;
  letter-spacing: 0.02em;
  box-shadow: 0 4px 14px rgba(5, 150, 105, 0.25);
}

.btn--success:hover:not(:disabled) {
  background: linear-gradient(135deg, var(--color-secondary-hover), #059669);
  box-shadow: 0 6px 18px rgba(5, 150, 105, 0.35);
  transform: translateY(-1px);
}

.btn--muted {
  background: var(--color-surface-subtle);
  color: var(--color-text-secondary);
  border-color: var(--color-border);
}

.btn--muted:hover {
  background: #e2e8f0;
  color: var(--color-text-primary);
}

.btn__icon {
  width: 18px;
  height: 18px;
}

.hidden {
  display: none !important;
}

/* --------------------------------------------------------------------------
   Modal & Feedback Overlays (Light Mode)
   -------------------------------------------------------------------------- */

.modal {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  z-index: 50;
}

.modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.55);
  backdrop-filter: blur(4px);
}

.modal__content {
  position: relative;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-2xl);
  padding: 40px;
  width: 100%;
  max-width: 520px;
  box-shadow: var(--shadow-2xl);
  text-align: center;
  animation: modalEntrance 0.25s ease-out;
}

@keyframes modalEntrance {
  0% {
    opacity: 0;
    transform: scale(0.96) translateY(8px);
  }
  100% {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

.success-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
}

.success-logos {
  display: flex;
  justify-content: center;
  align-items: center;
  margin-bottom: 2px;
}

.success-logo {
  height: auto;
  max-height: 55px;
  max-width: 180px;
  width: auto;
  object-fit: contain;
}

.success-icon {
  width: 68px;
  height: 68px;
  animation: successPulse 0.5s ease-out;
}

.success-icon__circle {
  stroke: var(--color-secondary);
  stroke-width: 3;
  fill: var(--color-secondary-light);
}

.success-icon__check {
  stroke: var(--color-secondary);
  stroke-width: 3.5;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
}

@keyframes successPulse {
  0% { transform: scale(0.8); opacity: 0.6; }
  50% { transform: scale(1.08); opacity: 1; }
  100% { transform: scale(1); opacity: 1; }
}

.success-title {
  font-size: 26px;
  font-weight: 800;
  color: var(--color-text-primary);
  margin: 0;
}

.success-id-badge {
  display: inline-block;
  padding: 4px 14px;
  background: var(--color-surface-hover);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-full);
  font-size: 13px;
  font-weight: 700;
  color: var(--color-primary);
  letter-spacing: 0.04em;
  margin: -6px 0 4px;
}

.success-message {
  color: var(--color-text-secondary);
  margin: 0;
  line-height: 1.6;
  font-size: 15px;
}

.success-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  margin-top: 12px;
}

/* Loading Overlay */
.loading-overlay {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 16px;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(4px);
  z-index: 60;
}

.loading-spinner {
  width: 48px;
  height: 48px;
  border: 4px solid var(--color-surface-subtle);
  border-top: 4px solid var(--color-primary);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

.loading-text {
  color: var(--color-text-primary);
  font-size: 16px;
  font-weight: 600;
}

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

/* --------------------------------------------------------------------------
   Toast Notifications
   -------------------------------------------------------------------------- */

.toast-container {
  position: fixed;
  top: 24px;
  right: 24px;
  z-index: 1100;
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-width: 400px;
  pointer-events: none;
}

.toast {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 16px 18px;
  box-shadow: var(--shadow-lg);
  display: flex;
  align-items: flex-start;
  gap: 12px;
  opacity: 0;
  transform: translateX(100%);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  pointer-events: auto;
  position: relative;
  overflow: hidden;
}

.toast--show {
  opacity: 1;
  transform: translateX(0);
}

.toast__icon {
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  margin-top: 2px;
}

.toast--error .toast__icon { color: var(--color-danger); }
.toast--success .toast__icon { color: var(--color-secondary); }
.toast--warning .toast__icon { color: var(--color-accent-gold); }
.toast--info .toast__icon { color: var(--color-primary); }

.toast__content {
  flex: 1;
  min-width: 0;
}

.toast__title {
  font-size: 14px;
  font-weight: 700;
  color: var(--color-text-primary);
  margin: 0 0 2px 0;
}

.toast__message {
  font-size: 13px;
  color: var(--color-text-secondary);
  margin: 0;
  line-height: 1.4;
}

.toast__close {
  flex-shrink: 0;
  background: none;
  border: none;
  color: var(--color-text-muted);
  cursor: pointer;
  padding: 4px;
  border-radius: var(--radius-xs);
  transition: all var(--t-fast);
}

.toast__close:hover {
  color: var(--color-text-primary);
  background: var(--color-surface-subtle);
}

.toast__progress {
  position: absolute;
  bottom: 0;
  left: 0;
  height: 3px;
  background: var(--color-primary);
  transition: width linear;
}

.toast--error .toast__progress { background: var(--color-danger); }
.toast--success .toast__progress { background: var(--color-secondary); }
.toast--warning .toast__progress { background: var(--color-accent-gold); }

/* --------------------------------------------------------------------------
   Responsive Breakpoints
   -------------------------------------------------------------------------- */

@media (max-width: 1024px) {
  .layout {
    padding: 16px;
    gap: 16px;
  }
  .sidebar {
    width: 280px;
    padding: 20px 16px;
  }
  .question-container {
    padding: 28px 24px;
  }
}

@media (max-width: 860px) {
  .layout {
    flex-direction: column;
    padding: 14px;
    gap: 14px;
  }

  .sidebar {
    display: none;
  }

  .main {
    max-height: none;
    overflow-y: visible;
  }

  /* Horizontal Mobile Nav */
  .question-nav--mobile {
    display: flex !important;
    flex-direction: row;
    align-items: center;
    gap: 8px;
    overflow-x: auto;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-xl);
    padding: 10px 14px;
    padding-right: calc(100% - 170px);
    box-shadow: var(--shadow-sm);
    scrollbar-width: none;
    position: relative;
    -webkit-overflow-scrolling: touch;
    scroll-behavior: smooth;
  }

  .question-nav--mobile::-webkit-scrollbar {
    display: none;
  }

  .question-nav--mobile .question-nav__item {
    flex-shrink: 0;
    padding: 8px 12px;
    border-radius: var(--radius-md);
    background: var(--color-surface-subtle);
    border: 1px solid var(--color-border);
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  }

  .question-nav--mobile .question-nav__item--current {
    background: #eff6ff;
    border-color: var(--color-primary);
    box-shadow: 0 2px 8px rgba(37, 99, 235, 0.16);
    color: var(--color-primary);
    transform: scale(1.02);
  }

  .question-nav--mobile .question-nav__item--current .question-nav__number {
    background: var(--color-primary);
    color: #ffffff;
    font-weight: 700;
  }

  .question-nav--mobile .question-nav__item--completed {
    border-color: rgba(16, 185, 129, 0.35);
  }

  .question-nav--mobile .question-nav__item--completed .question-nav__number {
    background: var(--color-secondary);
    color: #ffffff;
    font-weight: 700;
  }

  .question-nav--mobile .question-nav__number {
    width: 22px;
    height: 22px;
    font-size: 11px;
  }

  .question-nav--mobile .question-nav__text {
    font-size: 13px;
    max-width: 150px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .question-nav--mobile .question-nav__item--current .question-nav__text {
    font-weight: 700;
    color: var(--color-primary);
  }

  .question-container {
    padding: 24px 18px;
  }

  .question__title {
    font-size: 22px;
  }

  .review-list {
    grid-template-columns: 1fr;
  }

  .footer__content {
    flex-direction: row;
  }
}

@media (max-width: 480px) {
  .header {
    padding: 12px 16px;
    height: auto;
    min-height: 64px;
  }

  .footer__content .btn {
    flex: 1;
    min-width: 0;
    padding: 12px 16px;
    font-size: 14px;
  }

  .intro-highlights {
    grid-template-columns: 1fr;
  }
}
