:root {
  --ink: #18313f;
  --muted: #607480;
  --navy: #123e58;
  --navy-deep: #0a2c40;
  --teal: #1d8a8a;
  --teal-dark: #126d70;
  --aqua: #dff2ef;
  --cream: #f7f4ed;
  --paper: #fff;
  --line: #dce5e6;
  --shadow: 0 24px 70px rgba(24, 49, 63, .13);
  --radius: 24px;
}

* { box-sizing: border-box; }

[hidden] { display: none !important; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background:
    radial-gradient(circle at 10% 0%, rgba(29,138,138,.10), transparent 29rem),
    radial-gradient(circle at 100% 10%, rgba(18,62,88,.08), transparent 34rem),
    var(--cream);
  color: var(--ink);
  font-family: "DM Sans", system-ui, sans-serif;
  line-height: 1.5;
}

button, textarea, input { font: inherit; }

button { color: inherit; }

.skip-link {
  position: fixed;
  left: 1rem;
  top: -5rem;
  z-index: 10;
  padding: .75rem 1rem;
  border-radius: .75rem;
  background: var(--navy-deep);
  color: white;
}

.skip-link:focus { top: 1rem; }

.page-shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 44px 0 36px;
}

.accreditation-bar {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 44px;
  align-items: end;
  padding: 22px 28px 18px;
  border: 1px solid rgba(18,62,88,.12);
  border-bottom: 3px solid #173f9c;
  border-radius: var(--radius) var(--radius) 0 0;
  background: #fff;
}

.accreditation-mark {
  display: grid;
  justify-items: center;
  min-width: 0;
  color: #001c96;
  text-align: center;
}

.accreditation-mark img {
  display: block;
  width: auto;
  object-fit: contain;
}

.accreditation-mark-uems img { height: 104px; }
.accreditation-mark-pis img { height: 112px; }
.accreditation-mark div { width: 100%; margin-top: 11px; }
.accreditation-mark p { margin: 0; font-size: .66rem; font-weight: 800; letter-spacing: .15em; line-height: 1.45; }
.accreditation-mark p + p { margin-top: 6px; }

.event-header {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 185px;
  gap: 36px;
  align-items: center;
  min-height: 265px;
  padding: 38px 42px;
  overflow: hidden;
  border-radius: 0;
  background:
    linear-gradient(112deg, rgba(8,39,58,.98), rgba(19,79,99,.93)),
    var(--navy);
  color: white;
}

.event-header::before,
.event-header::after {
  content: "";
  position: absolute;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 50%;
  pointer-events: none;
}

.event-header::before { width: 290px; height: 290px; right: 92px; top: -150px; }
.event-header::after { width: 175px; height: 175px; left: 48%; bottom: -135px; }

.event-copy, .poster-link { position: relative; z-index: 1; }

.eyebrow, .kicker, .section-number {
  margin: 0 0 10px;
  color: #73d4cc;
  font-size: .76rem;
  font-weight: 800;
  letter-spacing: .14em;
  text-transform: uppercase;
}

h1, h2, h3 { font-family: "Libre Franklin", system-ui, sans-serif; }

h1 {
  max-width: 760px;
  margin: 0;
  font-size: clamp(2rem, 4vw, 3.6rem);
  line-height: 1.04;
  letter-spacing: -.045em;
}

.event-details { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 24px; }

.detail-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border: 1px solid rgba(255,255,255,.18);
  border-radius: 999px;
  background: rgba(255,255,255,.08);
  color: rgba(255,255,255,.92);
  font-size: .86rem;
  font-weight: 600;
}

.detail-pill svg, .completion-note svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.poster-link {
  justify-self: end;
  display: block;
  width: 165px;
  padding: 7px 7px 10px;
  border: 1px solid rgba(255,255,255,.28);
  border-radius: 14px;
  background: rgba(255,255,255,.10);
  color: white;
  font-size: .74rem;
  font-weight: 700;
  text-align: center;
  text-decoration: none;
  transform: rotate(1.5deg);
  transition: transform .2s ease, background .2s ease;
}

.poster-link:hover, .poster-link:focus-visible { transform: rotate(0) translateY(-3px); background: rgba(255,255,255,.17); }
.poster-link img { display: block; width: 100%; aspect-ratio: 3 / 4; object-fit: cover; object-position: top; border-radius: 9px; background: #fff; }
.poster-link span { display: block; margin-top: 7px; }

.form-card {
  padding: 42px;
  border: 1px solid rgba(18,62,88,.09);
  border-top: 0;
  border-radius: 0 0 var(--radius) var(--radius);
  background: rgba(255,255,255,.96);
  box-shadow: var(--shadow);
}

.form-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; }
.form-heading .kicker { color: var(--teal-dark); }
.form-heading h2 { margin: 0; font-size: clamp(1.65rem, 3vw, 2.35rem); letter-spacing: -.035em; }
.step-counter { flex: 0 0 auto; margin: 0; color: var(--muted); font-weight: 700; white-space: nowrap; }
.step-counter span { color: var(--navy); font-size: 1.45rem; }

.progress { margin: 34px 0 46px; }
.progress-track { height: 4px; overflow: hidden; border-radius: 99px; background: #e7edef; }
.progress-track span { display: block; width: 0; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--teal), #5cc8b7); transition: width .35s ease; }
.progress-steps { display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px; margin: 12px 0 0; padding: 0; list-style: none; }
.progress-steps button { width: 100%; padding: 0; border: 0; background: transparent; cursor: pointer; text-align: left; }
.progress-steps button:disabled { cursor: default; }
.progress-steps span { display: inline-grid; width: 25px; height: 25px; place-items: center; margin-right: 5px; border: 1px solid var(--line); border-radius: 50%; color: var(--muted); font-size: .72rem; font-style: normal; font-weight: 800; }
.progress-steps em { color: var(--muted); font-size: .72rem; font-style: normal; font-weight: 700; }
.progress-steps .active span, .progress-steps .complete span { border-color: var(--teal); background: var(--teal); color: white; }
.progress-steps .active em, .progress-steps .complete em { color: var(--ink); }

.form-step { animation: reveal .28s ease; }
.form-step[hidden], .success-state[hidden] { display: none; }
@keyframes reveal { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

.section-intro { margin-bottom: 26px; }
.section-intro h3 { margin: 0; font-size: 1.55rem; letter-spacing: -.025em; }
.section-number { color: var(--teal-dark); }
.subsection { margin-top: 48px; padding-top: 38px; border-top: 1px solid var(--line); }

.participant-details { margin: 0 0 38px; padding: 20px; border: 1px solid #b9dcda; border-radius: 14px; background: #f4fbfa; }
.email-field { display: block; }
.email-field > span { display: block; margin-bottom: 8px; color: var(--ink); font-weight: 800; }
.email-field strong { color: #a93636; }
.email-field input { width: 100%; padding: 13px 15px; border: 1px solid var(--line); border-radius: 10px; background: #fff; color: var(--ink); outline: none; transition: border .18s ease, box-shadow .18s ease; }
.email-field input:focus { border-color: var(--teal); box-shadow: 0 0 0 3px rgba(29,138,138,.12); }
.email-field input[aria-invalid="true"] { border-color: #a93636; box-shadow: 0 0 0 3px rgba(169,54,54,.1); }
.email-field input[aria-invalid="false"] { border-color: var(--teal) !important; box-shadow: 0 0 0 3px rgba(29,138,138,.08) !important; }
.field-help { margin: 8px 0 0; color: var(--muted); font-size: .82rem; }
.input-error { margin: 7px 0 0; color: #a93636; font-size: .84rem; font-weight: 700; }
.input-error[hidden] { display: none; }

.question-block, .text-question { display: block; min-width: 0; margin: 0 0 34px; padding: 0; border: 0; }
.question-block legend, .text-question > span { display: block; width: 100%; margin-bottom: 14px; color: var(--ink); font-size: 1rem; font-weight: 700; }

.option-grid { display: grid; gap: 10px; }
.option-grid.four { grid-template-columns: repeat(4, 1fr); }
.option-grid.five { grid-template-columns: repeat(5, 1fr); }
.option-card { position: relative; display: flex; min-height: 62px; align-items: center; justify-content: center; padding: 10px 8px; border: 1px solid var(--line); border-radius: 12px; background: #fbfcfc; color: var(--muted); cursor: pointer; font-size: .85rem; font-weight: 600; text-align: center; transition: .18s ease; }
.option-card input { position: absolute; opacity: 0; }
.option-card:hover { border-color: #8dc8c4; background: #f5fbfa; color: var(--ink); }
.option-card:has(input:checked) { border-color: var(--teal); background: var(--aqua); color: var(--navy-deep); box-shadow: 0 0 0 2px rgba(29,138,138,.08); }
.option-card:has(input:focus-visible) { outline: 3px solid rgba(29,138,138,.22); outline-offset: 2px; }

textarea { width: 100%; resize: vertical; min-height: 110px; padding: 15px 16px; border: 1px solid var(--line); border-radius: 12px; background: #fbfcfc; color: var(--ink); outline: none; transition: border .18s ease, box-shadow .18s ease; }
textarea:focus { border-color: var(--teal); box-shadow: 0 0 0 3px rgba(29,138,138,.12); }

.matrix-card { max-width: 100%; overflow: hidden; border: 1px solid var(--line); border-radius: 14px; }
.matrix-scroll { width: 100%; overflow-x: auto; }
.rating-table { width: 100%; border-collapse: collapse; table-layout: fixed; }
.rating-table th, .rating-table td { padding: 15px 10px; border-bottom: 1px solid var(--line); text-align: center; }
.rating-table tr:last-child th, .rating-table tr:last-child td { border-bottom: 0; }
.rating-table thead th { background: #f0f5f5; color: var(--muted); font-size: .74rem; font-weight: 700; }
.rating-table th:first-child { width: 28%; text-align: left; }
.rating-table tbody th { color: var(--ink); font-size: .9rem; }
.rating-table input[type="radio"], .session-option input { width: 19px; height: 19px; accent-color: var(--teal); }

.session-legend { position: sticky; top: 0; z-index: 3; display: grid; grid-template-columns: repeat(5, 1fr); gap: 4px; margin: 0 0 12px 42%; padding: 9px 10px; border-radius: 10px; background: var(--navy); color: white; font-size: .66rem; font-weight: 700; line-height: 1.15; text-align: center; }
.day-heading { margin: 34px 0 12px; padding: 10px 14px; border-radius: 10px; background: var(--navy); color: white; font-size: .84rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; }
.day-heading:first-child { margin-top: 0; }
.topic-heading { margin: 18px 0 8px; color: var(--teal-dark); font-size: .8rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; }
.session-row { display: grid; grid-template-columns: minmax(0, 42%) repeat(5, 1fr); align-items: stretch; margin-bottom: 6px; border: 1px solid var(--line); border-radius: 10px; background: #fff; }
.session-title { display: flex; align-items: center; padding: 11px 14px; border-right: 1px solid var(--line); font-size: .79rem; line-height: 1.35; }
.session-option { display: grid; place-items: center; min-height: 54px; border-right: 1px solid var(--line); cursor: pointer; }
.session-option:last-child { border-right: 0; }
.session-option:hover { background: #f2faf8; }
.session-option:has(input:checked) { background: var(--aqua); }

.completion-note { display: flex; gap: 13px; align-items: flex-start; margin-top: 42px; padding: 17px 18px; border: 1px solid #b7ddd7; border-radius: 13px; background: #f2faf8; color: var(--navy-deep); }
.completion-note svg { flex: 0 0 auto; margin-top: 2px; color: var(--teal-dark); }
.completion-note p { margin: 0; }

.form-actions { display: flex; justify-content: flex-end; gap: 12px; margin-top: 46px; padding-top: 26px; border-top: 1px solid var(--line); }
.submit-status { flex: 1 1 100%; align-self: center; margin: 0 auto 0 0; color: var(--teal-dark); font-size: .86rem; font-weight: 700; }
.submit-status.error { color: #a93636; }
.button { display: inline-flex; min-height: 48px; align-items: center; justify-content: center; gap: 9px; padding: 12px 22px; border-radius: 12px; font-weight: 800; cursor: pointer; transition: transform .18s ease, box-shadow .18s ease, background .18s ease; }
.button:hover { transform: translateY(-1px); }
.button.primary { border: 1px solid var(--navy); background: var(--navy); color: white; box-shadow: 0 10px 24px rgba(18,62,88,.18); }
.button.primary:hover { background: var(--navy-deep); }
.button.submit { border-color: var(--teal-dark); background: var(--teal-dark); }
.button.secondary { border: 1px solid var(--line); background: white; color: var(--navy); }

.success-state { padding: 70px 20px 46px; text-align: center; }
.success-icon { display: grid; width: 76px; height: 76px; place-items: center; margin: 0 auto 22px; border-radius: 50%; background: var(--aqua); color: var(--teal-dark); font-size: 2rem; font-weight: 800; }
.success-state .kicker { color: var(--teal-dark); }
.success-state h3 { margin: 0 0 8px; font-size: 2rem; }
.success-state p:not(.kicker) { margin: 0 0 28px; color: var(--muted); }

footer { display: flex; justify-content: space-between; gap: 20px; padding: 22px 4px 0; color: var(--muted); font-size: .78rem; }
footer a { color: var(--navy); font-weight: 700; text-decoration: none; }
.footer-links { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 18px; }

@media (max-width: 820px) {
  .page-shell { width: min(100% - 20px, 720px); padding-top: 10px; }
  .accreditation-bar { gap: 20px; padding: 18px 18px 14px; }
  .accreditation-mark-uems img { height: 88px; }
  .accreditation-mark-pis img { height: 94px; }
  .accreditation-mark p { font-size: .56rem; letter-spacing: .1em; }
  .event-header { grid-template-columns: 1fr 130px; min-height: 230px; padding: 28px; gap: 22px; }
  .poster-link { width: 126px; }
  .form-card { padding: 28px; }
  .option-grid.four, .option-grid.five { grid-template-columns: repeat(2, 1fr); }
  .option-grid.five .option-card:last-child { grid-column: 1 / -1; }
  .progress-steps em { display: none; }
  .progress-steps button { text-align: center; }
  .progress-steps span { margin-right: 0; }
  .session-legend { display: none; }
  .session-row { grid-template-columns: repeat(5, 1fr); }
  .session-title { grid-column: 1 / -1; min-height: auto; border-right: 0; border-bottom: 1px solid var(--line); font-weight: 600; }
  .session-option { position: relative; min-height: 70px; padding-top: 24px; }
  .session-option::before { content: attr(data-short); position: absolute; top: 7px; color: var(--muted); font-size: .54rem; font-weight: 700; }
}

@media (max-width: 560px) {
  .accreditation-bar { gap: 12px; padding: 14px 10px 11px; }
  .accreditation-mark-uems img { height: 68px; }
  .accreditation-mark-pis img { height: 74px; }
  .accreditation-mark div { margin-top: 8px; }
  .accreditation-mark p { font-size: .43rem; letter-spacing: .055em; line-height: 1.4; }
  .accreditation-mark p + p { margin-top: 4px; }
  .event-header { grid-template-columns: minmax(0, 1fr) 92px; align-items: start; padding: 24px 20px; gap: 14px; }
  .eyebrow { margin-bottom: 7px; font-size: .64rem; }
  h1 { font-size: clamp(1.55rem, 7.5vw, 2.15rem); }
  .event-details { margin-top: 18px; }
  .detail-pill { font-size: .72rem; }
  .poster-link { width: 90px; padding: 5px 5px 7px; font-size: .62rem; transform: none; }
  .form-card { padding: 24px 18px; }
  .form-heading { align-items: center; }
  .form-heading h2 { font-size: 1.42rem; }
  .progress { margin: 26px 0 36px; }
  .option-grid.four, .option-grid.five { grid-template-columns: 1fr; }
  .option-grid.five .option-card:last-child { grid-column: auto; }
  .matrix-card { margin-right: -4px; }
  .rating-table { min-width: 590px; }
  .session-row { grid-template-columns: repeat(5, 1fr); }
  .session-option { min-width: 0; }
  .session-option::before { transform: scale(.9); }
  .form-actions { display: grid; grid-template-columns: 1fr; }
  .submit-status { margin-bottom: 4px; text-align: center; }
  .form-actions .button { width: 100%; }
  .form-actions #previous-button { order: 2; }
  footer, .footer-links { flex-direction: column; text-align: center; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
