@import url('https://fonts.googleapis.com/css2?family=Nunito:wght@400;600;700;800&family=Poppins:wght@400;600;700&display=swap');

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --red:        #c0272d;
  --red-dark:   #8f1a1f;
  --red-light:  #fdecea;
  --gold:       #e8a020;
  --gold-light: #fef6e4;
  --navy:       #1a1a2e;
  --teal:       #0f7b6c;
  --teal-light: #e0f5f2;
  --purple:     #5c3d9e;
  --purple-light:#f0ebff;
  --green:      #2e7d32;
  --green-light:#e8f5e9;
  --white:      #ffffff;
  --bg:         #f4f6fb;
  --card-bg:    #ffffff;
  --text:       #1a1a2e;
  --muted:      #6b7280;
  --border:     #e2e8f0;
  --radius-sm:  6px;
  --radius-md:  12px;
  --radius-lg:  20px;
  --shadow-sm:  0 1px 4px rgba(0,0,0,.08);
  --shadow-md:  0 4px 16px rgba(0,0,0,.10);
  --shadow-lg:  0 8px 32px rgba(0,0,0,.12);
  --font-head:  'Poppins', sans-serif;
  --font-body:  'Nunito', sans-serif;
}

html { font-size: 16px; }
body { font-family: var(--font-body); background: var(--bg); color: var(--text); line-height: 1.6; min-height: 100vh; }

/* ── Page ── */
.page-wrap { max-width: 820px; margin: 0 auto; padding: 0 1rem 4rem; }

/* ── HEADER ── */
.site-header {
  background: var(--navy);
  color: var(--white);
  padding: 0;
  margin-bottom: 2rem;
  border-radius: 0 0 var(--radius-lg) var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}
.header-top {
  background: var(--red);
  padding: .45rem 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.brand-logo {
  font-family: var(--font-head);
  font-size: .82rem;
  font-weight: 700;
  letter-spacing: .18em;
  color: var(--white);
}
.header-badge {
  background: rgba(255,255,255,.2);
  color: var(--white);
  font-size: .72rem;
  font-weight: 700;
  padding: .2rem .75rem;
  border-radius: 20px;
  letter-spacing: .06em;
}
.header-body { padding: 1.75rem 2rem 2rem; text-align: center; }
.school-tag {
  display: inline-block;
  background: var(--gold);
  color: var(--navy);
  font-family: var(--font-head);
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  padding: .25rem 1rem;
  border-radius: 20px;
  margin-bottom: .75rem;
}
.form-title {
  font-family: var(--font-head);
  font-size: 2rem;
  font-weight: 700;
  color: var(--white);
  margin-bottom: .4rem;
  line-height: 1.2;
}
.form-objective { font-size: .92rem; color: #94a3b8; }
.form-objective strong { color: var(--gold); }

/* ── PROGRESS BAR ── */
.progress-bar-wrap {
  background: rgba(255,255,255,.1);
  height: 6px;
  margin: 1.25rem 2rem 0;
  border-radius: 3px;
  overflow: hidden;
}
.progress-bar-fill {
  height: 100%;
  background: var(--gold);
  border-radius: 3px;
  width: 0%;
  transition: width .4s ease;
}

/* ── LANDING ── */
.landing-main { display: flex; justify-content: center; padding: 1rem 0 2rem; }
.school-picker-card {
  background: var(--card-bg);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  padding: 2.5rem 2rem 2rem;
  width: 100%;
  max-width: 500px;
  text-align: center;
  border-top: 5px solid var(--red);
}
.picker-icon {
  width: 72px; height: 72px;
  background: var(--red-light);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 1.25rem;
  font-size: 2rem;
}
.picker-heading {
  font-family: var(--font-head);
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: .4rem;
}
.picker-sub { font-size: .88rem; color: var(--muted); margin-bottom: 1.5rem; }
.picker-form { display: flex; flex-direction: column; gap: .85rem; text-align: left; }
.picker-label { font-weight: 700; font-size: .9rem; color: var(--navy); margin-bottom: .2rem; display: block; }

/* ── SECTIONS ── */
.form-section {
  background: var(--card-bg);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  padding: 1.75rem 2rem;
  margin-bottom: 1.25rem;
  border: 1px solid var(--border);
  position: relative;
  overflow: hidden;
}
.form-section::before {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 5px;
  background: var(--red);
  border-radius: 5px 0 0 5px;
}
.section-heading {
  font-family: var(--font-head);
  font-size: 1rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 1.25rem;
  display: flex;
  align-items: center;
  gap: .5rem;
  padding-left: .25rem;
}
.section-icon {
  width: 30px; height: 30px;
  background: var(--red-light);
  border-radius: var(--radius-sm);
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 1rem;
  flex-shrink: 0;
}

/* ── QUESTIONS ── */
.question-block { margin-bottom: 1.5rem; border: none; padding: 0; }
.question-block:last-child { margin-bottom: 0; }
.question-label {
  display: block;
  font-weight: 700;
  font-size: .93rem;
  color: var(--navy);
  margin-bottom: .75rem;
}
.q-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px; height: 24px;
  background: var(--red);
  color: var(--white);
  border-radius: 50%;
  font-size: .75rem;
  font-weight: 800;
  margin-right: .4rem;
  flex-shrink: 0;
  vertical-align: middle;
}

/* ── STAGE YEAR GRID ── */
.stage-group { display: flex; flex-direction: column; gap: .5rem; }
.stage-row {
  display: flex; align-items: center; flex-wrap: wrap;
  gap: .5rem;
  background: var(--bg);
  border-radius: var(--radius-sm);
  padding: .6rem .85rem;
  border: 1.5px solid transparent;
  transition: border-color .15s, background .15s;
  cursor: pointer;
}
.stage-row:hover { border-color: var(--red); background: var(--red-light); }
.stage-radio { min-width: 220px; font-weight: 600; font-size: .9rem; cursor: pointer; }
.year-boxes { display: flex; flex-wrap: wrap; gap: .3rem; margin-left: auto; }
.year-cb { display: flex; align-items: center; gap: .2rem; }
.year-cb input[type=checkbox] { accent-color: var(--red); width: 1rem; height: 1rem; cursor: pointer; }
.year-cb label { font-size: .8rem; color: var(--muted); cursor: pointer; font-weight: 600; }

/* ── RADIO / CHECK LISTS ── */
.radio-list, .check-list {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(185px, 1fr));
  gap: .4rem;
  padding: 0;
}
.radio-list li, .check-list li {
  display: flex; align-items: center; gap: .5rem;
  padding: .55rem .85rem;
  border-radius: var(--radius-sm);
  background: var(--bg);
  border: 1.5px solid transparent;
  font-size: .9rem;
  font-weight: 600;
  cursor: pointer;
  transition: all .15s;
}
.radio-list li:hover, .check-list li:hover {
  border-color: var(--red);
  background: var(--red-light);
  color: var(--red-dark);
}
.radio-list input, .check-list input {
  accent-color: var(--red);
  width: 1rem; height: 1rem;
  cursor: pointer;
  flex-shrink: 0;
}

/* ── OTHER ROW ── */
.other-row { margin-top: .75rem; display: flex; align-items: center; gap: .6rem; flex-wrap: wrap; }
.other-label { font-size: .85rem; color: var(--muted); font-weight: 600; }

/* ── INPUTS ── */
.input-short, .input-wide, .input-other, .input-textarea, .input-select {
  font-family: var(--font-body);
  font-size: .93rem;
  color: var(--text);
  background: var(--bg);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  padding: .55rem .85rem;
  transition: border-color .15s, box-shadow .15s;
}
.input-short    { width: 90px; }
.input-wide     { width: 100%; }
.input-other    { flex: 1; min-width: 200px; max-width: 480px; }
.input-textarea { width: 100%; resize: vertical; line-height: 1.6; }
.input-select   { width: 100%; appearance: none; cursor: pointer;
                  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%236b7280' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
                  background-repeat: no-repeat; background-position: right .75rem center; padding-right: 2.5rem; }

.input-short:focus, .input-wide:focus, .input-other:focus,
.input-textarea:focus, .input-select:focus {
  outline: none;
  border-color: var(--red);
  box-shadow: 0 0 0 3px rgba(192,39,45,.12);
  background: var(--white);
}

/* ── SUBMIT ── */
.submit-row { text-align: center; margin-top: 2rem; }
.btn-submit {
  background: var(--red);
  color: var(--white);
  border: none;
  padding: .9rem 3rem;
  font-family: var(--font-head);
  font-size: 1.05rem;
  font-weight: 700;
  border-radius: 50px;
  cursor: pointer;
  letter-spacing: .03em;
  box-shadow: 0 4px 15px rgba(192,39,45,.35);
  transition: all .2s;
}
.btn-submit:hover  { background: var(--red-dark); transform: translateY(-2px); box-shadow: 0 6px 20px rgba(192,39,45,.4); }
.btn-submit:active { transform: translateY(0); }
.btn-sm { padding: .6rem 1.75rem; font-size: .92rem; }

/* ── BANNERS ── */
.success-banner {
  display: block;
  background: var(--green-light);
  border: 1.5px solid #a5d6a7;
  color: var(--green);
  padding: 1.25rem 1.5rem;
  border-radius: var(--radius-md);
  margin-bottom: 1.5rem;
  font-weight: 700;
  text-align: center;
  font-size: 1rem;
}
.error-banner {
  background: var(--red-light) !important;
  border-color: #f5aaaa !important;
  color: var(--red-dark) !important;
}
.validation-summary {
  background: #fff8e1;
  border: 1.5px solid var(--gold);
  color: #7c5700;
  padding: 1rem 1.25rem;
  border-radius: var(--radius-md);
  margin-bottom: 1.2rem;
  font-size: .9rem;
  font-weight: 600;
}
.validation-summary ul { padding-left: 1.2rem; }
.field-error { color: var(--red); font-size: .82rem; font-weight: 600; }
.req  { color: var(--red); }
.hint { font-weight: 400; color: var(--muted); font-size: .8rem; }

/* ── FOOTER ── */
.site-footer {
  text-align: center;
  font-size: .82rem;
  color: var(--muted);
  padding: 1.5rem 0;
  border-top: 1px solid var(--border);
  margin-top: 2rem;
  font-weight: 600;
}

/* ── RESPONSIVE ── */
@media (max-width: 600px) {
  .form-section   { padding: 1.25rem 1.1rem; }
  .header-body    { padding: 1.25rem 1rem 1.5rem; }
  .form-title     { font-size: 1.5rem; }
  .stage-radio    { min-width: 100%; }
  .radio-list, .check-list { grid-template-columns: 1fr; }
  .school-picker-card { padding: 1.75rem 1.1rem; }
  .year-boxes     { margin-left: 0; }
}
