/* ============================================================
   CAPSI Survey — Main Stylesheet
   Aesthetic: refined academic · navy + gold · editorial
   Fonts: Playfair Display (headings) + Source Serif 4 (body)
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@500;600;700&family=Source+Serif+4:ital,wght@0,300;0,400;0,600;1,300;1,400&family=JetBrains+Mono:wght@400;500&display=swap');

/* ── Variables ───────────────────────────────────────────── */
:root {
  --navy:       #1a3a5c;
  --navy-dark:  #0f2238;
  --navy-light: #2a5080;
  --gold:       #c9a84c;
  --gold-light: #e8c876;
  --cream:      #f8f6f0;
  --cream-dark: #ede9df;
  --text:       #1e1e1e;
  --text-mid:   #4a4a4a;
  --text-muted: #888;
  --border:     #d6d0c4;
  --white:      #ffffff;
  --success:    #2d7a4f;
  --danger:     #c0392b;
  --shadow-sm:  0 1px 4px rgba(0,0,0,.06);
  --shadow-md:  0 4px 20px rgba(0,0,0,.10);
  --shadow-lg:  0 8px 40px rgba(0,0,0,.14);
  --radius:     8px;
  --radius-lg:  14px;
  --transition: 200ms ease;
}

/* ── Reset ───────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; scroll-behavior: smooth; }
body {
  font-family: 'Source Serif 4', Georgia, serif;
  color: var(--text);
  background: var(--cream);
  line-height: 1.75;
  min-height: 100vh;
}

/* ── Typography ──────────────────────────────────────────── */
h1, h2, h3, h4 {
  font-family: 'Playfair Display', Georgia, serif;
  line-height: 1.25;
  color: var(--navy);
}
h1 { font-size: clamp(1.6rem, 4vw, 2.4rem); font-weight: 700; }
h2 { font-size: clamp(1.2rem, 3vw, 1.7rem); font-weight: 600; }
h3 { font-size: 1.15rem; font-weight: 500; }
p  { margin-bottom: .9rem; }
a  { color: var(--navy); }
a:hover { color: var(--gold); }

/* ── Layout ──────────────────────────────────────────────── */
.page-wrap {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
.container {
  width: 100%;
  max-width: 860px;
  margin: 0 auto;
  padding: 0 24px;
}
.container--wide { max-width: 1200px; }

/* ── Header / Banner ─────────────────────────────────────── */
.site-header {
  background: var(--navy);
  padding: 0;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: var(--shadow-md);
}
.site-header .banner-img {
  display: block;
  height: 71px;
  width: auto;
  max-width: 100%;
  object-fit: contain;
  object-position: center center;
  margin: 0 auto;
}
.site-header .banner-wrap {
  padding: 8px 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  min-height: 88px;
  position: relative;
}
.lang-switcher {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
  position: absolute;
  right: 20px;
  top: 50%;
  transform: translateY(-50%);
}
.lang-switcher a {
  color: rgba(255,255,255,.65);
  text-decoration: none;
  font-size: .8rem;
  letter-spacing: .06em;
  font-family: 'JetBrains Mono', monospace;
  padding: 3px 8px;
  border: 1px solid rgba(255,255,255,.25);
  border-radius: 4px;
  transition: var(--transition);
}
.lang-switcher a.active,
.lang-switcher a:hover { color: var(--gold); border-color: var(--gold); }

/* ── Progress bar ────────────────────────────────────────── */
.progress-outer {
  background: var(--navy-dark);
  padding: 8px 24px;
  display: flex;
  align-items: center;
  gap: 16px;
}
.progress-label {
  color: rgba(255,255,255,.7);
  font-size: .78rem;
  font-family: 'JetBrains Mono', monospace;
  white-space: nowrap;
  min-width: 110px;
}
.progress-bar-track {
  flex: 1;
  height: 4px;
  background: rgba(255,255,255,.15);
  border-radius: 4px;
  overflow: hidden;
}
.progress-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--gold), var(--gold-light));
  border-radius: 4px;
  transition: width .5s ease;
}
.progress-pct {
  color: var(--gold);
  font-size: .78rem;
  font-family: 'JetBrains Mono', monospace;
  min-width: 36px;
  text-align: right;
}

/* ── Main content ────────────────────────────────────────── */
.main-content {
  flex: 1;
  padding: 40px 0 60px;
}

/* ── Card ────────────────────────────────────────────────── */
.card {
  background: var(--white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  padding: 40px 48px;
  margin-bottom: 24px;
  border: 1px solid var(--border);
}
@media (max-width: 600px) {
  .card { padding: 24px 20px; }
}

/* ── Welcome card ────────────────────────────────────────── */
.welcome-card {
  border-top: 4px solid var(--gold);
}
.welcome-card .purpose-list {
  list-style: none;
  margin: 16px 0 0;
}
.welcome-card .purpose-list li {
  padding: 6px 0 6px 24px;
  position: relative;
  color: var(--text-mid);
  font-size: .95rem;
}
.welcome-card .purpose-list li::before {
  content: '';
  position: absolute;
  left: 0; top: 14px;
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--gold);
}

/* ── Section header ──────────────────────────────────────── */
.section-header {
  border-bottom: 2px solid var(--cream-dark);
  padding-bottom: 16px;
  margin-bottom: 32px;
}
.section-header .section-tag {
  font-family: 'JetBrains Mono', monospace;
  font-size: .72rem;
  text-transform: uppercase;
  letter-spacing: .12em;
  color: var(--gold);
  display: block;
  margin-bottom: 6px;
}
.section-header .section-sub {
  font-size: .88rem;
  color: var(--text-muted);
  font-style: italic;
  margin-top: 4px;
  margin-bottom: 0;
}

/* ── Question block ──────────────────────────────────────── */
.question-block {
  margin-bottom: 36px;
  padding-bottom: 32px;
  border-bottom: 1px solid var(--cream-dark);
}
.question-block:last-child { border-bottom: none; margin-bottom: 0; }

.question-num {
  font-family: 'JetBrains Mono', monospace;
  font-size: .72rem;
  color: var(--gold);
  letter-spacing: .08em;
  display: block;
  margin-bottom: 6px;
}
.question-text {
  font-size: 1rem;
  font-weight: 400;
  color: var(--text);
  margin-bottom: 18px;
  line-height: 1.6;
}

/* ── Likert scale ────────────────────────────────────────── */
.likert-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.likert-option {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  cursor: pointer;
  transition: var(--transition);
  background: var(--white);
}
.likert-option:hover { background: var(--cream); border-color: var(--navy); }
.likert-option input[type="radio"] { display: none; }
.likert-option .radio-dot {
  width: 18px; height: 18px; flex-shrink: 0;
  border: 2px solid var(--border);
  border-radius: 50%;
  transition: var(--transition);
  position: relative;
}
.likert-option .radio-dot::after {
  content: '';
  position: absolute;
  top: 3px; left: 3px;
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--navy);
  opacity: 0;
  transition: var(--transition);
}
.likert-option.selected,
.likert-option:has(input:checked) {
  background: #eef3f9;
  border-color: var(--navy);
}
.likert-option.selected .radio-dot,
.likert-option:has(input:checked) .radio-dot {
  border-color: var(--navy);
}
.likert-option.selected .radio-dot::after,
.likert-option:has(input:checked) .radio-dot::after {
  opacity: 1;
}
.likert-label { font-size: .95rem; color: var(--text); }
.likert-value {
  margin-left: auto;
  font-family: 'JetBrains Mono', monospace;
  font-size: .72rem;
  color: var(--text-muted);
}

/* ── Likert horizontal (desktop) ─────────────────────────── */
@media (min-width: 640px) {
  .likert-group.horizontal {
    flex-direction: row;
    gap: 4px;
  }
  .likert-group.horizontal .likert-option {
    flex: 1;
    flex-direction: column;
    text-align: center;
    padding: 14px 8px;
    gap: 8px;
  }
  .likert-group.horizontal .likert-option .radio-dot { margin: 0 auto; }
  .likert-group.horizontal .likert-value { display: none; }
  .likert-group.horizontal .likert-label { font-size: .78rem; line-height: 1.3; }
}

/* ── Multi-select / checkbox ─────────────────────────────── */
.checkbox-group { display: flex; flex-direction: column; gap: 8px; }
.check-option {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  cursor: pointer;
  transition: var(--transition);
  background: var(--white);
}
.check-option:hover { background: var(--cream); border-color: var(--navy); }
.check-option input[type="checkbox"] { display: none; }
.check-box {
  width: 18px; height: 18px; flex-shrink: 0;
  border: 2px solid var(--border-dark);
  border-radius: 4px;
  transition: var(--transition);
  position: relative;
  background: var(--white);
}
.check-box::after {
  content: '';
  position: absolute;
  top: 2px; left: 5px;
  width: 6px; height: 10px;
  border: 2px solid #fff;
  border-top: none; border-left: none;
  transform: rotate(45deg);
  opacity: 0;
  transition: opacity .15s;
}
.check-option.selected,
.check-option:has(input:checked) { background: #eef3f9; border-color: var(--navy); }
.check-option.selected .check-box,
.check-option:has(input:checked) .check-box {
  background: var(--navy); border-color: var(--navy);
}
.check-option.selected .check-box::after,
.check-option:has(input:checked) .check-box::after { opacity: 1; }
.check-label { font-size: .95rem; color: var(--text-dark); line-height: 1.4; }

/* ── Textarea ────────────────────────────────────────────── */
.open-text-wrap { position: relative; }
textarea.survey-textarea {
  width: 100%;
  min-height: 130px;
  padding: 14px 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-family: 'Source Serif 4', serif;
  font-size: .95rem;
  color: var(--text);
  background: var(--white);
  resize: vertical;
  transition: var(--transition);
  line-height: 1.6;
}
textarea.survey-textarea:focus {
  outline: none;
  border-color: var(--navy);
  box-shadow: 0 0 0 3px rgba(26,58,92,.1);
}
.word-count {
  font-family: 'JetBrains Mono', monospace;
  font-size: .7rem;
  color: var(--text-muted);
  text-align: right;
  margin-top: 4px;
}
.word-count.over { color: var(--danger); }

/* ── Dropdown ────────────────────────────────────────────── */
select.survey-select {
  width: 100%;
  max-width: 360px;
  padding: 11px 40px 11px 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-family: 'Source Serif 4', serif;
  font-size: .95rem;
  color: var(--text);
  background: var(--white) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%231a3a5c' d='M1 1l5 5 5-5'/%3E%3C/svg%3E") no-repeat right 14px center;
  appearance: none;
  cursor: pointer;
  transition: var(--transition);
}
select.survey-select:focus {
  outline: none;
  border-color: var(--navy);
  box-shadow: 0 0 0 3px rgba(26,58,92,.1);
}

/* ── Buttons ─────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 28px;
  border-radius: var(--radius);
  border: none;
  cursor: pointer;
  font-family: 'Source Serif 4', serif;
  font-size: .95rem;
  font-weight: 600;
  transition: var(--transition);
  text-decoration: none;
}
.btn-primary {
  background: var(--navy);
  color: var(--white);
  box-shadow: var(--shadow-sm);
}
.btn-primary:hover { background: var(--navy-light); color: var(--white); }
.btn-secondary {
  background: transparent;
  color: var(--navy);
  border: 1.5px solid var(--navy);
}
.btn-secondary:hover { background: var(--cream-dark); }
.btn-gold {
  background: var(--gold);
  color: var(--navy-dark);
}
.btn-gold:hover { background: var(--gold-light); }
.btn-draft {
  background: transparent;
  color: var(--navy);
  border: 1.5px dashed var(--navy);
  font-size: .88rem;
  padding: 10px 20px;
}
.btn-draft:hover { background: var(--cream-dark); border-style: solid; }
.btn:disabled { opacity: .5; cursor: not-allowed; }

/* ── Vertical radio list (Q2, Q3, Q4) ───────────────────── */
.radio-list { display: flex; flex-direction: column; gap: 8px; }
.radio-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 16px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  cursor: pointer;
  transition: var(--transition);
  background: var(--white);
}
.radio-item:hover { background: var(--cream); border-color: var(--navy); }
.radio-item input[type="radio"] { display: none; }
.radio-circle {
  width: 18px; height: 18px;
  border-radius: 50%;
  border: 2px solid var(--border-dark);
  flex-shrink: 0;
  position: relative;
  transition: var(--transition);
}
.radio-circle::after {
  content: '';
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%,-50%) scale(0);
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--navy);
  transition: transform .15s ease;
}
.radio-item.selected,
.radio-item:has(input:checked) {
  background: #eef3f9;
  border-color: var(--navy);
}
.radio-item.selected .radio-circle,
.radio-item:has(input:checked) .radio-circle {
  border-color: var(--navy);
}
.radio-item.selected .radio-circle::after,
.radio-item:has(input:checked) .radio-circle::after { transform: translate(-50%,-50%) scale(1); }
.radio-text { font-size: .92rem; color: var(--text-dark); }

/* ── Draft note banner ───────────────────────────────────── */
.draft-note {
  margin: 24px 0 0;
  padding: 12px 18px;
  background: #f0f4f9;
  border-left: 4px solid var(--navy);
  border-radius: 0 var(--radius) var(--radius) 0;
  font-size: .83rem;
  color: var(--text-mid);
  line-height: 1.6;
}
.draft-note strong { color: var(--navy); }
.draft-icon { margin-right: 6px; }

.btn-row {
  display: flex;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
  margin-top: 32px;
  flex-wrap: wrap;
}

/* ── Login card ──────────────────────────────────────────── */
.login-wrap {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: var(--cream);
  padding: 40px 24px;
}
.login-card {
  width: 100%;
  max-width: 480px;
  background: var(--white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  padding: 48px 48px 40px;
  border-top: 4px solid var(--gold);
}
.login-card .banner-img { max-width: 100%; height: auto; margin-bottom: 28px; display: block; }
.login-card h1 { font-size: 1.5rem; margin-bottom: 8px; }
.login-card .subtitle { color: var(--text-muted); font-size: .9rem; margin-bottom: 28px; font-style: italic; }

.form-group { margin-bottom: 20px; }
.form-group label {
  display: block;
  font-size: .85rem;
  font-weight: 600;
  color: var(--text-mid);
  margin-bottom: 8px;
  letter-spacing: .04em;
  font-family: 'Source Serif 4', serif;
}
.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="password"] {
  width: 100%;
  padding: 12px 16px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  font-family: 'JetBrains Mono', monospace;
  font-size: 1rem;
  letter-spacing: .1em;
  color: var(--text);
  transition: var(--transition);
  background: var(--white);
}
.form-group input:focus {
  outline: none;
  border-color: var(--navy);
  box-shadow: 0 0 0 3px rgba(26,58,92,.1);
}
.error-msg {
  background: #fdf0ee;
  border: 1px solid #f5c6c0;
  border-radius: var(--radius);
  padding: 12px 16px;
  color: var(--danger);
  font-size: .88rem;
  margin-bottom: 16px;
}
.success-msg {
  background: #edf7f1;
  border: 1px solid #b8dfca;
  border-radius: var(--radius);
  padding: 12px 16px;
  color: var(--success);
  font-size: .88rem;
  margin-bottom: 16px;
}

/* ── Validation indicator ─────────────────────────────────── */
.question-block.has-error .question-text { color: var(--danger); }
.question-block.has-error .likert-option,
.question-block.has-error .radio-item,
.question-block.has-error .check-option,
.question-block.has-error textarea,
.question-block.has-error select { border-color: var(--danger); }
.inline-error {
  font-size: .8rem;
  color: var(--danger);
  margin-top: 6px;
  font-style: italic;
}

/* ── Thank-you screen ────────────────────────────────────── */
.thankyou-card {
  text-align: center;
  padding: 60px 48px;
}
.thankyou-card .check-circle {
  width: 72px; height: 72px;
  background: var(--success);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 24px;
}
.thankyou-card .check-circle svg { width: 36px; color: #fff; }
.anon-ref-badge {
  display: inline-block;
  font-family: 'JetBrains Mono', monospace;
  font-size: 1.6rem;
  letter-spacing: .15em;
  color: var(--navy);
  background: var(--cream-dark);
  padding: 14px 32px;
  border-radius: var(--radius);
  border: 2px dashed var(--border);
  margin: 16px 0 24px;
}

/* ── Survey closed ───────────────────────────────────────── */
.closed-banner {
  background: var(--navy);
  color: rgba(255,255,255,.9);
  text-align: center;
  padding: 14px 24px;
  font-size: .9rem;
}

/* ── Footer ──────────────────────────────────────────────── */
.site-footer {
  background: var(--navy-dark);
  color: rgba(255,255,255,.45);
  padding: 16px 24px;
  font-size: .75rem;
  text-align: center;
  font-family: 'JetBrains Mono', monospace;
  letter-spacing: .04em;
}

/* ── Admin layout ────────────────────────────────────────── */
.admin-layout { display: flex; min-height: 100vh; }
.admin-sidebar {
  width: 240px;
  flex-shrink: 0;
  background: var(--navy-dark);
  display: flex;
  flex-direction: column;
  padding: 0;
}
.admin-sidebar .sidebar-logo {
  padding: 20px 20px 16px;
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.admin-sidebar .sidebar-logo img { max-width: 100%; height: auto; max-height: 48px; }
.admin-sidebar .sidebar-title {
  font-family: 'JetBrains Mono', monospace;
  font-size: .65rem;
  color: var(--gold);
  letter-spacing: .12em;
  text-transform: uppercase;
  padding: 16px 20px 8px;
}
.admin-nav { flex: 1; padding: 0 12px 20px; }
.admin-nav a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 6px;
  color: rgba(255,255,255,.65);
  text-decoration: none;
  font-size: .875rem;
  transition: var(--transition);
  margin-bottom: 2px;
}
.admin-nav a:hover, .admin-nav a.active {
  background: rgba(255,255,255,.08);
  color: #fff;
}
.admin-nav a.active { color: var(--gold); }
.admin-nav .nav-icon { width: 16px; opacity: .7; flex-shrink: 0; }
.admin-main {
  flex: 1;
  background: #f0ede6;
  overflow-x: hidden;
  display: flex;
  flex-direction: column;
}
.admin-topbar {
  background: var(--white);
  border-bottom: 1px solid var(--border);
  padding: 14px 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-shadow: var(--shadow-sm);
}
.admin-topbar h1 { font-size: 1.2rem; font-weight: 600; }
.admin-content { flex: 1; padding: 28px 32px; }

/* ── Stats cards ─────────────────────────────────────────── */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 16px;
  margin-bottom: 28px;
}
.stat-card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 20px 24px;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border);
}
.stat-card .stat-label {
  font-size: .75rem;
  text-transform: uppercase;
  letter-spacing: .1em;
  color: var(--text-muted);
  font-family: 'JetBrains Mono', monospace;
  margin-bottom: 6px;
}
.stat-card .stat-value {
  font-family: 'Playfair Display', serif;
  font-size: 2rem;
  color: var(--navy);
  font-weight: 700;
  line-height: 1;
}
.stat-card .stat-sub {
  font-size: .78rem;
  color: var(--text-muted);
  margin-top: 4px;
}

/* ── Admin table ─────────────────────────────────────────── */
.admin-table-wrap { overflow-x: auto; }
table.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: .875rem;
  background: var(--white);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}
.admin-table th {
  background: var(--navy);
  color: rgba(255,255,255,.85);
  font-family: 'JetBrains Mono', monospace;
  font-size: .7rem;
  letter-spacing: .08em;
  text-transform: uppercase;
  padding: 10px 16px;
  text-align: left;
  white-space: nowrap;
}
.admin-table td {
  padding: 10px 16px;
  border-bottom: 1px solid var(--cream-dark);
  color: var(--text-mid);
  vertical-align: middle;
}
.admin-table tr:last-child td { border-bottom: none; }
.admin-table tr:hover td { background: #faf9f5; }
.badge {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 20px;
  font-size: .7rem;
  font-family: 'JetBrains Mono', monospace;
  font-weight: 500;
  letter-spacing: .04em;
}
.badge-pending   { background: #f5e9c9; color: #7a5200; }
.badge-invited   { background: #d0e8f7; color: #0a4070; }
.badge-started   { background: #fde8cc; color: #7a3800; }
.badge-completed { background: #d0eedd; color: #0d5228; }

/* ── Chart container ─────────────────────────────────────── */
.chart-card {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border);
  padding: 24px;
  margin-bottom: 24px;
}
.chart-card h3 {
  font-size: .9rem;
  color: var(--text-muted);
  font-weight: 400;
  font-style: italic;
  margin-bottom: 4px;
}
.chart-card h2 {
  font-size: 1.1rem;
  color: var(--navy);
  margin-bottom: 20px;
}
.chart-wrap { position: relative; width: 100%; }

/* ── Filter bar ──────────────────────────────────────────── */
.filter-bar {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 20px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  margin-bottom: 24px;
  box-shadow: var(--shadow-sm);
}
.filter-bar label {
  font-size: .78rem;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--text-muted);
  font-family: 'JetBrains Mono', monospace;
}
.filter-bar select {
  padding: 7px 32px 7px 10px;
  border: 1px solid var(--border);
  border-radius: 6px;
  font-size: .875rem;
  color: var(--text);
  background: var(--cream) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='7' viewBox='0 0 10 7'%3E%3Cpath fill='%231a3a5c' d='M1 1l4 4 4-4'/%3E%3C/svg%3E") no-repeat right 10px center;
  appearance: none;
  cursor: pointer;
}

/* ── Responsive ──────────────────────────────────────────── */
@media (max-width: 768px) {
  .admin-layout { flex-direction: column; }
  .admin-sidebar { width: 100%; }
  .admin-content { padding: 16px; }
  .stats-grid { grid-template-columns: 1fr 1fr; }
}

/* ── Print ───────────────────────────────────────────────── */
@media print {
  .site-header, .progress-outer, .btn-row, .site-footer { display: none; }
  .card { box-shadow: none; border: 1px solid #ccc; page-break-inside: avoid; }
}

/* ── Animations ──────────────────────────────────────────── */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}
.section-pane { animation: fadeInUp .3s ease both; }
