:root {
  --ink: #233047;
  --muted: #667085;
  --paper: #fffdf8;
  --panel: #ffffff;
  --line: #dde4ec;
  --sky: #54b8d0;
  --rose: #e8657a;
  --gold: #f2bd49;
  --leaf: #6abf8e;
  --shadow: 0 14px 34px rgba(35, 48, 71, 0.14);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background:
    linear-gradient(135deg, rgba(84, 184, 208, 0.18), rgba(242, 189, 73, 0.16)),
    var(--paper);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.registration-admin-bar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-bottom: 3px solid #35acd2;
  background: #111827;
  color: #fff;
  box-shadow: 0 6px 18px rgba(17, 24, 39, .22);
}

.registration-admin-bar[hidden] {
  display: none;
}

.registration-admin-bar strong {
  margin-right: 6px;
  color: #fff;
  font-size: .82rem;
  font-weight: 950;
  letter-spacing: .02em;
  text-transform: uppercase;
}

.registration-admin-bar button {
  min-height: 34px;
  border: 2px solid rgba(255, 255, 255, .22);
  border-radius: 999px;
  background: rgba(255, 255, 255, .1);
  color: #fff;
  padding: 0 13px;
  font: inherit;
  font-size: .82rem;
  font-weight: 950;
  cursor: pointer;
}

.registration-admin-bar button.is-active,
.registration-admin-bar button:hover {
  border-color: #35acd2;
  background: #35acd2;
}

.registration-admin-bar [data-registration-admin-normal] {
  margin-left: auto;
  background: #fff;
  color: #111827;
}

.registration-admin-bar span {
  color: rgba(255, 255, 255, .76);
  font-size: .82rem;
  font-weight: 800;
}

@keyframes panelIn {
  from {
    opacity: 0;
    transform: translateY(14px) scale(0.99);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes studentIn {
  from {
    opacity: 0;
    transform: translateY(12px) rotate(-0.6deg);
  }
  to {
    opacity: 1;
    transform: translateY(0) rotate(0);
  }
}

@keyframes oamieFloat {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-5px);
  }
}

@keyframes oamieSwap {
  from {
    opacity: 0;
    transform: translateX(10px) scale(.92);
  }
  to {
    opacity: 1;
    transform: translateX(0) scale(1);
  }
}

@keyframes daySelectedWobble {
  0%, 100% { transform: rotate(-1.5deg) scale(1.02); }
  50% { transform: rotate(1.5deg) scale(1.02); }
}

@keyframes classChoicesIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.aq-shell {
  width: min(1320px, calc(100% - 28px));
  margin: 0 auto;
  padding: 28px 0 40px;
}

.aq-hero {
  position: relative;
  display: block;
  align-items: center;
  min-height: clamp(320px, 26vw, 430px);
  padding: 32px;
  border: 3px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: #fff;
  box-shadow: var(--shadow);
  --hero-bg-image: url("../images/attendance/artQuestAttendance-trialClass.png");
  --hero-bg-opacity: 1;
}

.aq-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  background-image: var(--hero-bg-image);
  background-size: cover;
  background-position: center;
  opacity: var(--hero-bg-opacity);
}

.aq-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(115deg, rgba(255,255,255,0.72), rgba(255,255,255,0.22));
  pointer-events: none;
}

.aq-hero-copy {
  position: relative;
  z-index: 2;
}

.aq-hero.is-confirmation-hero .aq-kicker {
  color: #fff;
  -webkit-text-stroke: 0.8px #152137;
  paint-order: stroke fill;
  text-shadow:
    -1px -1px 0 #152137,
    1px -1px 0 #152137,
    -1px 1px 0 #152137,
    1px 1px 0 #152137,
    0 4px 14px rgba(0, 0, 0, .32);
}

.aq-kicker {
  margin: 0 0 8px;
  color: var(--rose);
  font-weight: 800;
  text-transform: uppercase;
  font-size: 0.78rem;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 12px;
  max-width: 720px;
  font-size: clamp(2.2rem, 5vw, 4.6rem);
  line-height: 0.96;
}

.aq-intro {
  max-width: 620px;
  color: #45556f;
  font-size: 1.05rem;
  line-height: 1.6;
}

.aq-location-confirmation {
  display: inline-flex;
  align-items: center;
  margin: 2px 0 0;
  padding: 8px 14px;
  border: 2px solid rgba(255, 39, 51, 0.16);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.82);
  color: var(--ink);
  font-size: clamp(1.1rem, 2.4vw, 1.72rem);
  font-weight: 900;
  line-height: 1.05;
  box-shadow: 0 5px 0 rgba(31, 42, 68, 0.1);
}

[hidden].aq-location-confirmation {
  display: none;
}

.aq-steps {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 8px;
  margin: 18px 0;
}

.aq-steps.is-confirmation {
  display: none;
}

.aq-step,
.aq-button,
.icon-button {
  min-height: 44px;
  border: 0;
  border-radius: 8px;
  font: inherit;
  font-weight: 800;
  cursor: pointer;
}

.aq-step {
  min-width: 0;
  background: rgba(255, 255, 255, 0.78);
  color: var(--muted);
  border: 1px solid var(--line);
  box-shadow: 0 4px 0 rgba(35, 48, 71, 0.1);
  transition: transform .18s ease, background .18s ease, color .18s ease, box-shadow .18s ease;
}

.aq-step.is-active {
  background: var(--rose);
  color: #fff;
  box-shadow: 0 5px 0 rgba(138, 26, 45, 0.2);
}

.aq-step:hover,
.aq-button:hover,
.plan-choice-button:hover {
  transform: translateY(-1px);
}

.location-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 14px;
  margin-top: 18px;
}

.location-choice-field {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.location-card {
  display: grid;
  gap: 8px;
  align-content: start;
  min-height: 310px;
  border: 3px solid var(--line);
  border-radius: 14px;
  background: #fff;
  padding: 12px;
  color: var(--ink);
  font: inherit;
  text-align: left;
  cursor: pointer;
  box-shadow: 0 6px 0 rgba(35, 48, 71, .12);
  transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease, background .18s ease;
}

.location-card:hover,
.location-card:focus-visible {
  border-color: var(--gold);
  background: #fffdf4;
  transform: translateY(-3px);
  box-shadow: 0 10px 0 rgba(35, 48, 71, .14);
  outline: none;
}

.location-card.is-selected {
  border-color: var(--rose);
  background: #fff6f8;
  box-shadow: 0 0 0 5px rgba(232, 101, 122, .13), 0 6px 0 rgba(35, 48, 71, .12);
}

.location-card.is-secondary-choice,
.class-option.is-secondary-choice {
  opacity: .48;
  filter: grayscale(.55);
}

.location-card.is-secondary-choice:hover,
.location-card.is-secondary-choice:focus-visible,
.class-option.is-secondary-choice:hover,
.class-option.is-secondary-choice:focus-within {
  opacity: .82;
  filter: grayscale(.15);
}

.location-image-placeholder {
  display: grid;
  place-items: center;
  width: 100%;
  aspect-ratio: 4 / 3;
  border-radius: 12px;
  overflow: hidden;
  background:
    radial-gradient(circle at 50% 36%, rgba(84, 184, 208, .22), transparent 34%),
    linear-gradient(135deg, #f8fbfd, #fff9df);
}

.location-image-placeholder img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center bottom;
  opacity: 0.75;
  filter: saturate(0.9) brightness(1.08);
}

.location-image-placeholder i {
  display: grid;
  place-items: center;
  width: 64px;
  height: 64px;
  border-radius: 50%;
  color: #257c95;
  background: #fff;
  font-style: normal;
  font-weight: 950;
  box-shadow: 0 5px 0 rgba(35, 48, 71, .1);
}

.location-card strong {
  font-size: 1.35rem;
  line-height: 1.05;
}

.location-card small {
  color: var(--muted);
  font-size: .88rem;
  font-weight: 800;
}

.location-square-chip {
  width: fit-content;
  margin-top: auto;
  border-radius: 999px;
  padding: 6px 9px;
  color: #257c95;
  background: rgba(84, 184, 208, .14);
  font-size: .72rem;
  font-weight: 950;
  text-transform: uppercase;
}

.aq-form,
.aq-panel {
  display: block;
}

.aq-honeypot {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.aq-panel {
  display: none;
  padding: 26px;
  border: 3px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: var(--shadow);
}

.aq-panel.is-active {
  display: block;
  animation: panelIn .26s ease both;
}

.panel-action-row {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 18px;
}

.aq-panel-head {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: center;
  margin-bottom: 22px;
  padding-bottom: 12px;
  border-bottom: 2px solid rgba(221, 228, 236, 0.72);
}

.aq-panel-head.inline,
.student-row header {
  display: flex;
  gap: 14px;
  align-items: center;
}

.aq-panel-head.inline {
  justify-content: space-between;
}

.student-row header {
  justify-content: flex-start;
  margin-bottom: 18px;
}

.student-row header .icon-button {
  margin-left: auto;
}

.guardian-photo-panel {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 18px;
  border: 2px solid #d7e2ec;
  border-radius: 16px;
  background: linear-gradient(135deg, #fff 0%, #f5fbff 100%);
  padding: 14px;
  box-shadow: 0 5px 0 rgba(35, 48, 71, .1);
}

.guardian-photo-panel h2,
.guardian-photo-panel p {
  margin: 0;
}

.guardian-photo-panel h2 {
  font-size: 1.45rem;
}

.guardian-photo-panel .aq-kicker {
  margin-bottom: 4px;
}

.guardian-photo-panel p:last-child {
  color: var(--muted);
  font-weight: 800;
}

.guardian-photo-button {
  width: 88px;
  height: 88px;
}

.student-photo-button {
  position: relative;
  display: grid;
  place-items: center;
  width: 76px;
  height: 76px;
  flex: 0 0 auto;
  border: 3px dashed #cdd6e1;
  border-radius: 50%;
  background: #f8fbfd;
  cursor: pointer;
  overflow: hidden;
  box-shadow: 0 5px 0 rgba(35, 48, 71, .12);
  transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}

.student-photo-button:hover,
.student-photo-button:focus-visible {
  border-color: var(--sky);
  transform: translateY(-2px) rotate(-2deg);
  outline: none;
  box-shadow: 0 8px 0 rgba(35, 48, 71, .14);
}

.student-photo-button img,
.class-student-photo img {
  display: none;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  overflow: hidden;
}

.student-photo-button.has-photo {
  border-style: solid;
  border-color: var(--leaf);
}

.student-photo-button.has-photo img,
.class-student-photo.has-photo img {
  display: block;
}

.student-photo-button.has-photo .student-photo-fallback,
.class-student-photo.has-photo .student-photo-fallback {
  display: none;
}

.student-photo-fallback {
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
  color: #257c95;
  background: radial-gradient(circle, #ffffff 0 35%, #eafaff 36% 100%);
  font-size: 1rem;
  font-weight: 950;
}

.student-photo-hint {
  margin: 3px 0 0;
  color: var(--muted);
  font-size: .78rem;
  font-weight: 850;
}

.aq-panel-head h2 {
  margin-bottom: 6px;
  font-size: 1.8rem;
}

.aq-panel-head p {
  color: var(--muted);
}

.aq-grid {
  display: grid;
  gap: 16px;
}

.aq-grid.two {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.aq-grid.three {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.guardian-notes-field {
  margin-top: 18px;
}

label {
  display: grid;
  gap: 7px;
  color: #40516a;
  font-size: 0.92rem;
  font-weight: 800;
}

#usernameHelp {
  display: block !important;
  visibility: visible !important;
  opacity: 1 !important;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 700;
  line-height: 1.35;
}

.username-help {
  display: block !important;
  color: #68758a;
  font-size: 0.78rem;
  font-weight: 700;
  line-height: 1.35;
}

.field-label {
  color: #40516a;
  font-size: 0.92rem;
  font-weight: 800;
}

input,
select,
textarea {
  width: 100%;
  min-height: 46px;
  border: 1px solid #cdd6e1;
  border-radius: 8px;
  padding: 10px 12px;
  color: var(--ink);
  background: #fff;
  font: inherit;
}

select {
  appearance: none;
  -webkit-appearance: none;
  padding-right: 44px;
  background-color: #fff;
  background-image:
    linear-gradient(45deg, transparent 50%, var(--ink) 50%),
    linear-gradient(135deg, var(--ink) 50%, transparent 50%),
    linear-gradient(to right, #edf2f7, #edf2f7);
  background-position:
    calc(100% - 24px) 52%,
    calc(100% - 17px) 52%,
    calc(100% - 42px) 50%;
  background-size:
    7px 7px,
    7px 7px,
    1px 24px;
  background-repeat: no-repeat;
  cursor: pointer;
}

select:hover {
  border-color: #9fb0c2;
  background-color: #fbfdff;
}

textarea {
  resize: vertical;
}

input:focus,
select:focus,
textarea:focus {
  outline: 3px solid rgba(84, 184, 208, 0.26);
  border-color: var(--sky);
}

.student-list {
  display: grid;
  gap: 14px;
}

#classPickers .class-options,
#classPickers .home-day-picker,
#classPickers .trial-start-week-field {
  transition: opacity .15s ease, transform .15s ease;
}

#classPickers.is-switching .class-options,
#classPickers.is-switching .home-day-picker,
#classPickers.is-switching .trial-start-week-field {
  opacity: 0;
  transform: translateY(8px);
}

#classPickers.is-settling .class-card {
  animation: classChoicesIn .24s ease both;
}

.empty-students-card {
  display: grid;
  place-items: center;
  min-height: 150px;
  padding: 22px;
  border: 3px dashed rgba(255, 31, 45, .55);
  border-radius: 10px;
  background: rgba(255, 240, 242, .72);
  color: var(--ink);
  text-align: center;
}

.empty-students-card strong {
  color: var(--rose);
  font-size: 1.35rem;
  font-weight: 950;
}

.empty-students-card span {
  color: #687789;
  font-weight: 850;
}

.student-row,
.class-card,
.review-card {
  padding: 18px;
  border: 2px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, .96), rgba(255, 255, 255, .9)),
    radial-gradient(circle at top right, rgba(84, 184, 208, .16), transparent 42%);
  box-shadow: 0 5px 0 rgba(35, 48, 71, 0.1);
}

.student-row.is-entering {
  animation: studentIn .28s ease both;
}

.student-row h3,
.class-card h3,
.review-card h3 {
  margin-bottom: 0;
}

.support-field {
  transition: opacity .18s ease, transform .18s ease;
}

.support-field.is-hidden {
  display: none;
}

.student-path-grid {
  display: grid;
  grid-template-columns: minmax(240px, 390px) minmax(240px, 1fr);
  gap: 16px;
  margin-top: 20px;
}

.plan-choice-field {
  display: grid;
  gap: 7px;
  max-width: 620px;
  margin-top: 18px;
}

.plan-choice-buttons {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.plan-choice-button {
  min-height: 46px;
  border: 2px solid #d8e0ea;
  border-radius: 999px;
  background: #fff;
  color: var(--ink);
  font: inherit;
  font-weight: 900;
  cursor: pointer;
  box-shadow: 0 4px 0 rgba(35, 48, 71, 0.12);
}

.plan-choice-button.is-selected {
  border-color: var(--sky);
  background: var(--sky);
  color: #fff;
}

.plan-choice-field small {
  color: var(--muted);
  font-weight: 750;
}

.plan-price-preview {
  display: grid;
  gap: 2px;
  min-height: 54px;
  border: 2px solid rgba(84, 184, 208, .38);
  border-radius: 10px;
  background: #f3fbff;
  padding: 9px 11px;
  color: var(--ink);
}

.plan-price-preview strong {
  color: var(--rose);
  font-size: 1.35rem;
  line-height: 1;
}

.plan-price-preview span {
  color: var(--muted);
  font-size: .78rem;
  font-weight: 900;
  text-transform: uppercase;
}

.plan-choice-field.is-single-class .plan-choice-buttons {
  display: none;
}

.plan-choice-field.is-single-class {
  border: 1px solid #d8e0ea;
  border-radius: 8px;
  background: #f8fbfd;
  padding: 11px;
}

.private-billing-panel {
  display: grid;
  grid-template-columns: repeat(2, minmax(220px, 1fr));
  gap: 14px;
  margin-top: 18px;
  padding: 14px;
  border: 2px solid rgba(84, 184, 208, .42);
  border-radius: 10px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, .96), rgba(237, 249, 255, .9)),
    radial-gradient(circle at top right, rgba(106, 191, 142, .16), transparent 42%);
  animation: studentIn .24s ease both;
}

.private-billing-panel.is-hidden {
  display: none;
}

.private-choice-buttons {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-top: 6px;
}

.private-choice-button {
  min-height: 44px;
  border: 2px solid #d8e0ea;
  border-radius: 999px;
  background: #fff;
  color: var(--ink);
  font: inherit;
  font-weight: 950;
  cursor: pointer;
  box-shadow: 0 4px 0 rgba(35, 48, 71, 0.12);
}

.private-choice-button:hover {
  border-color: var(--sky);
}

.private-choice-button.is-selected {
  border-color: var(--leaf);
  background: var(--leaf);
  color: #fff;
}

.private-provider-other {
  display: grid;
  grid-template-columns: repeat(2, minmax(180px, 1fr));
  gap: 10px;
}

.private-provider-field.is-hidden,
.private-provider-other.is-hidden {
  display: none;
}

.private-hold-note-field,
.private-policy-note {
  grid-column: 1 / -1;
}

.private-policy-note {
  display: grid;
  gap: 4px;
  padding: 11px 12px;
  border: 2px solid rgba(245, 197, 66, .65);
  border-radius: 10px;
  background: #fff9df;
}

.private-policy-note strong,
.private-policy-note span {
  display: block;
}

.private-policy-note span {
  color: var(--muted);
  font-weight: 800;
}

.icon-button {
  width: 40px;
  min-height: 40px;
  color: #fff;
  background: var(--rose);
}

.aq-actions {
  display: flex;
  justify-content: flex-start;
  align-items: center;
  gap: 10px;
  margin: 22px 0 0;
  padding-top: 16px;
  border-top: 2px solid rgba(221, 228, 236, .7);
}

.aq-button {
  padding: 0 18px;
  color: #fff;
  background: var(--sky);
}

.aq-button.secondary {
  color: var(--ink);
  background: #fff;
  border: 1px solid var(--line);
}

.aq-button.submit {
  display: none;
  background: var(--leaf);
}

.aq-button.submit.is-visible {
  display: inline-block;
}

.aq-alert {
  display: none;
  margin-top: 14px;
  padding: 14px 16px;
  border-radius: 8px;
  border: 1px solid transparent;
  font-weight: 800;
}

.aq-alert.is-error {
  display: block;
  color: #8f1e2f;
  background: #fff0f2;
  border-color: #ffc8d0;
}

.aq-alert.is-success {
  display: block;
  color: #13583a;
  background: #ecfff5;
  border-color: #b9efd3;
}

.class-card {
  display: grid;
  gap: 14px;
}

.class-card-header {
  display: flex;
  align-items: center;
  gap: 12px;
}

.class-card-header h3 {
  margin-bottom: 2px;
}

.class-card-header p {
  margin: 0;
  color: var(--muted);
  font-size: .84rem;
  font-weight: 850;
}

.class-student-photo {
  display: grid;
  place-items: center;
  width: 58px;
  height: 58px;
  flex: 0 0 auto;
  border: 2px dashed #cdd6e1;
  border-radius: 50%;
  overflow: hidden;
  background: #f8fbfd;
}

.home-day-picker {
  max-width: 100%;
  padding: 12px;
  border: 2px solid #d8e0ea;
  border-radius: 12px;
  background: #f8fbfd;
}

.trial-start-week-field {
  display: grid;
  gap: 10px;
  max-width: 520px;
  padding: 12px;
  border: 2px solid rgba(242, 189, 73, .72);
  border-radius: 12px;
  background: #fff9df;
}

.trial-start-week-field > strong,
.home-day-picker > strong {
  display: block;
  margin-bottom: 10px;
  color: #40516a;
  font-size: .82rem;
  font-weight: 950;
  text-transform: uppercase;
}

.day-bubble-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.week-bubble-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.day-bubble {
  display: grid;
  place-items: center;
  width: 66px;
  height: 66px;
  border: 3px solid #d8e0ea;
  border-radius: 999px;
  background: #fff;
  color: var(--ink);
  font: inherit;
  cursor: pointer;
  box-shadow: 0 5px 0 rgba(35, 48, 71, .12);
  transition: transform .18s ease, border-color .18s ease, background .18s ease, color .18s ease, box-shadow .18s ease;
}

.day-bubble span {
  font-size: .92rem;
  font-weight: 950;
}

.day-bubble:hover,
.day-bubble:focus-visible {
  border-color: var(--gold);
  background: #fff9df;
  box-shadow: 0 8px 0 rgba(35, 48, 71, .14);
  outline: none;
}

.day-bubble.is-selected {
  border-color: var(--rose);
  background: var(--rose);
  color: #fff;
  animation: daySelectedWobble .9s ease-in-out infinite;
}

.day-bubble:disabled,
.day-bubble.is-disabled {
  border-color: #d8e0ea;
  background: #edf1f5;
  color: #9aa6b4;
  cursor: not-allowed;
  box-shadow: none;
  opacity: .72;
}

.day-bubble:disabled:hover,
.day-bubble.is-disabled:hover {
  border-color: #d8e0ea;
  background: #edf1f5;
  box-shadow: none;
}

.week-bubble {
  min-height: 48px;
  border: 3px solid #d8e0ea;
  border-radius: 999px;
  padding: 0 16px;
  background: #fff;
  color: var(--ink);
  font: inherit;
  font-weight: 950;
  cursor: pointer;
  box-shadow: 0 5px 0 rgba(35, 48, 71, .12);
  transition: border-color .18s ease, background .18s ease, color .18s ease, box-shadow .18s ease;
}

.week-bubble:hover,
.week-bubble:focus-visible {
  border-color: var(--gold);
  background: #fffdf4;
  box-shadow: 0 8px 0 rgba(35, 48, 71, .14);
  outline: none;
}

.week-bubble.is-selected {
  border-color: var(--rose);
  background: var(--rose);
  color: #fff;
  animation: daySelectedWobble .9s ease-in-out infinite;
}

.class-options {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  gap: 10px;
}

.class-option {
  position: relative;
  display: grid;
  gap: 8px;
  padding: 12px;
  border: 2px solid #d8e0ea;
  border-radius: 8px;
  cursor: pointer;
  transition: border-color .16s ease, box-shadow .16s ease, transform .16s ease;
}

.class-option input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.class-option:has(input:checked) {
  border-color: var(--rose);
  background: #f3fbff;
  box-shadow: 0 0 0 4px rgba(232, 101, 122, 0.12), 0 5px 0 rgba(35, 48, 71, 0.1);
}

.class-option:hover,
.class-option:focus-within {
  border-color: var(--sky);
  transform: translateY(-1px);
}

.class-age-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin: -12px -12px 2px;
  border-radius: 6px 6px 0 0;
  padding: 8px 10px;
  background: #35b7d4;
  color: #fff;
  font-weight: 950;
}

.class-age-header strong,
.class-age-header small {
  display: block;
  min-width: 0;
  line-height: 1.05;
}

.class-age-header strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 1rem;
}

.class-age-header small {
  flex: 0 0 auto;
  border-radius: 999px;
  background: rgba(255, 255, 255, .22);
  padding: 4px 7px;
  font-size: .7rem;
  text-transform: uppercase;
}

.class-age-foundations {
  background: #ff2d35;
}

.class-age-creatives,
.class-age-creatives-skills,
.class-age-skills {
  background: #0f7890;
}

.class-age-private-class,
.class-age-private {
  background: #27344f;
}

.class-age-special-support,
.class-age-specialneeds {
  background: #8f4ec9;
}

.teacher-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: fit-content;
  max-width: 100%;
  margin-top: 8px;
  border: 1px solid #d8e0ea;
  border-radius: 999px;
  padding: 4px 10px 4px 4px;
  background: #fff;
}

.teacher-chip img {
  width: 30px;
  height: 30px;
  flex: 0 0 auto;
  border-radius: 50%;
  object-fit: cover;
}

.teacher-chip span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.class-age-chip {
  display: inline-flex;
  width: fit-content;
  max-width: 100%;
  border: 2px solid rgba(53, 183, 212, .24);
  border-radius: 999px;
  background: #eaf8fd;
  color: #0f6d83;
  font-size: .78rem;
  font-weight: 950;
  line-height: 1.1;
  padding: 6px 9px;
  text-transform: uppercase;
}

.class-meta {
  display: block;
  color: var(--muted);
  font-size: 0.88rem;
}

.trial-date-chip {
  display: inline-flex;
  width: fit-content;
  max-width: 100%;
  margin-top: 2px;
  border-radius: 999px;
  padding: 6px 9px;
  background: rgba(106, 191, 142, 0.14);
  color: #27764a;
  font-size: 0.78rem;
  font-weight: 900;
}

.trial-date-chip.is-delayed {
  background: rgba(242, 189, 73, 0.18);
  color: #8a5a00;
}

.trial-date-field {
  display: grid;
  gap: 5px;
  margin-top: 2px;
}

.trial-date-field > span {
  color: var(--muted);
  font-size: 0.74rem;
  font-weight: 900;
  text-transform: uppercase;
}

.trial-date-field select {
  min-height: 40px;
  border-width: 2px;
  border-color: #d8e0ea;
  border-radius: 999px;
  background-color: #f8fbfd;
  font-size: 0.88rem;
  font-weight: 850;
}

.review-summary {
  display: grid;
  gap: 12px;
}

.review-tools {
  display: grid;
  grid-template-columns: 1fr auto auto;
  gap: 12px;
  align-items: end;
  margin: 18px 0;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: var(--shadow);
}

.review-tools form {
  display: grid;
  grid-template-columns: 1fr minmax(180px, 240px) auto;
  gap: 12px;
  align-items: end;
}

.review-board {
  display: grid;
  gap: 12px;
}

.review-filters {
  display: grid;
  grid-template-columns: minmax(180px, 260px) 1fr;
  gap: 12px;
  align-items: end;
}

.review-stats {
  display: grid;
  grid-template-columns: repeat(6, minmax(80px, 1fr));
  gap: 8px;
}

.review-stats article {
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.review-stats strong,
.review-stats span {
  display: block;
}

.review-stats span {
  color: var(--muted);
  font-size: 0.74rem;
  font-weight: 900;
  text-transform: uppercase;
}

.settings-panel {
  display: grid;
  gap: 18px;
  margin-top: 18px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: var(--shadow);
}

.settings-panel h2 {
  margin-bottom: 12px;
}

.settings-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  gap: 10px;
}

.setting-toggle {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 9px;
  align-items: center;
  min-height: 48px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.setting-toggle input {
  width: 18px;
  min-height: 18px;
}

.review-count {
  color: var(--muted);
  font-weight: 900;
}

.registration-card {
  display: grid;
  gap: 12px;
}

.registration-card header {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
}

.registration-card header strong {
  color: var(--rose);
}

.review-status-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.review-status-row span {
  padding: 7px 10px;
  border: 1px solid rgba(232, 101, 122, 0.36);
  border-radius: 999px;
  color: var(--rose);
  background: rgba(232, 101, 122, 0.08);
  font-size: 0.82rem;
  font-weight: 900;
}

.review-status-row span.is-reviewed {
  border-color: rgba(106, 191, 142, 0.5);
  color: #2f8b55;
  background: rgba(106, 191, 142, 0.12);
}

.review-status-row span.is-warning {
  border-color: rgba(242, 189, 73, 0.65);
  color: #8a5a00;
  background: rgba(242, 189, 73, 0.16);
}

.duplicate-warning-list {
  display: grid;
  gap: 6px;
  padding: 10px 12px;
  border: 1px solid rgba(242, 189, 73, 0.55);
  border-radius: 8px;
  background: rgba(242, 189, 73, 0.12);
}

.duplicate-warning-list span {
  color: #694700;
  font-size: .9rem;
  font-weight: 800;
}

.registration-students {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 10px;
}

.registration-students div {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.registration-students strong,
.registration-students span {
  display: block;
}

.registration-students span {
  margin-top: 4px;
  color: var(--muted);
}

.review-actions {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
}

.review-actions div {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.review-actions small {
  color: var(--muted);
  overflow-wrap: anywhere;
}

.review-card p {
  margin-bottom: 6px;
  color: var(--muted);
}

.review-student-card,
.confirmation-details article {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 14px;
  align-items: start;
}

.next-step-card {
  border-color: rgba(106, 191, 142, 0.6);
  background: #f1fff7;
}

.confirmation-screen {
  display: grid;
  gap: 18px;
  padding: 28px;
  border: 3px solid var(--gold);
  border-radius: 12px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, .94), rgba(255, 249, 223, .9)),
    radial-gradient(circle at top right, rgba(84, 184, 208, .18), transparent 36%);
  box-shadow: var(--shadow);
}

.confirmation-screen h2 {
  font-size: clamp(2.3rem, 5vw, 5rem);
  line-height: .95;
}

.confirmation-lede {
  max-width: 780px;
  color: #40516a;
  font-size: 1.12rem;
  font-weight: 800;
}

.registration-email-status {
  width: max-content;
  max-width: 100%;
  margin: 0;
  border: 2px solid #bfeefa;
  border-radius: 999px;
  background: #e8f8ff;
  color: #0f6d83;
  padding: 10px 14px;
  font-weight: 950;
}

.registration-email-status.is-sent {
  border-color: #b9efd3;
  background: #ecfff5;
  color: #13583a;
}

.confirmation-screen.is-preview {
  border-color: var(--sky);
}

.comic-start-card {
  display: grid;
  grid-template-columns: minmax(220px, 360px) 1fr;
  gap: 20px;
  align-items: center;
  padding: 18px;
  border: 2px solid var(--line);
  border-radius: 10px;
  background: #fff;
}

.comic-start-card img {
  display: block;
  width: 100%;
  border-radius: 8px;
}

.comic-start-card h3 {
  margin-bottom: 8px;
  color: var(--rose);
  font-size: clamp(1.4rem, 2.2vw, 2.1rem);
}

.comic-start-card p,
.confirmation-details span {
  color: var(--muted);
}

.confirmation-details {
  display: grid;
  gap: 10px;
}

.confirmation-details article {
  padding: 12px;
  border: 2px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, .92);
}

.confirmation-details strong,
.confirmation-details span {
  display: block;
}

.confirmation-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.email-preview-modal {
  width: min(860px, calc(100vw - 28px));
  max-height: min(880px, calc(100vh - 32px));
  border: 0;
  border-radius: 14px;
  padding: 0;
  box-shadow: 0 24px 80px rgba(35, 48, 71, .34);
}

.email-preview-modal::backdrop {
  background: rgba(23, 32, 51, .62);
}

.email-preview-modal form {
  display: grid;
  gap: 16px;
  max-height: min(880px, calc(100vh - 32px));
  padding: 20px;
  background: #f3f6fa;
  overflow: auto;
}

.email-preview-modal header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.email-preview-frame {
  display: grid;
  place-items: center;
}

.email-preview-shell {
  display: grid;
  gap: 12px;
  width: min(680px, 100%);
}

.email-preview-subject {
  display: grid;
  gap: 4px;
  padding: 12px 14px;
  border: 2px solid #dde4ec;
  border-radius: 10px;
  background: #fff;
}

.email-preview-subject strong {
  color: #ff1f2d;
  font-size: .78rem;
  font-weight: 950;
  text-transform: uppercase;
}

.email-preview-subject span {
  color: var(--ink);
  font-weight: 900;
}

.email-template {
  width: min(680px, 100%);
  overflow: hidden;
  border-radius: 12px;
  background: #ffffff;
  color: #233047;
  box-shadow: 0 12px 32px rgba(35, 48, 71, .14);
}

.email-template-header,
.email-template-footer,
.email-section,
.email-story-card {
  padding: 22px;
}

.email-template-header {
  display: flex;
  gap: 14px;
  align-items: center;
  border-bottom: 4px solid var(--gold);
}

.email-template-header img {
  width: 86px;
  height: 86px;
  object-fit: contain;
  border-radius: 14px;
}

.email-template-header div {
  display: grid;
  gap: 3px;
}

.email-template-header strong {
  color: var(--ink);
  font-size: 1.2rem;
}

.email-template-header span,
.email-template-footer span,
.email-student-row span {
  color: #667085;
}

.email-hero {
  padding: 28px 22px;
  background: linear-gradient(135deg, rgba(232, 101, 122, .96), rgba(84, 184, 208, .92));
  color: #fff;
}

.email-hero p {
  margin: 0 0 6px;
  font-size: .82rem;
  font-weight: 950;
  text-transform: uppercase;
}

.email-hero h2 {
  margin: 0 0 8px;
  color: #fff;
  font-size: clamp(2rem, 5vw, 3.4rem);
  line-height: .94;
}

.email-section {
  border-bottom: 1px solid #dde4ec;
}

.email-section h3,
.email-story-card h3 {
  margin-bottom: 10px;
  color: #ff1f2d;
}

.email-student-row {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 12px;
  align-items: start;
  padding: 12px;
  border: 1px solid #dde4ec;
  border-radius: 10px;
  background: #f8fbfd;
}

.email-student-avatar {
  display: grid;
  place-items: center;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  object-fit: cover;
  background: #eafaff;
  color: #257c95;
  font-weight: 950;
}

.email-story-card {
  display: grid;
  grid-template-columns: minmax(170px, 260px) 1fr;
  gap: 16px;
  align-items: center;
  border-bottom: 1px solid #dde4ec;
  background: #fff9df;
}

.email-story-card img {
  width: 100%;
  border-radius: 10px;
}

.email-template-footer {
  display: grid;
  gap: 6px;
  background: #233047;
  color: #fff;
}

.photo-modal {
  width: min(520px, calc(100vw - 28px));
  border: 0;
  border-radius: 14px;
  padding: 0;
  box-shadow: 0 24px 80px rgba(35, 48, 71, .34);
}

.photo-modal::backdrop {
  background: rgba(23, 32, 51, .62);
}

.photo-modal form {
  display: grid;
  gap: 14px;
  padding: 20px;
}

.photo-modal header,
.photo-modal footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.photo-modal h2 {
  margin-bottom: 0;
}

#studentPhotoInput {
  display: none;
}

.photo-crop-stage {
  position: relative;
  width: min(320px, 78vw);
  height: min(320px, 78vw);
  margin: 0 auto;
  border: 4px solid var(--rose);
  border-radius: 50%;
  background: #f8fbfd;
  overflow: hidden;
  cursor: grab;
  box-shadow: inset 0 0 0 8px rgba(255, 255, 255, .72), 0 8px 0 rgba(35, 48, 71, .12);
  touch-action: none;
}

.photo-crop-stage:active {
  cursor: grabbing;
}

.photo-crop-stage img {
  position: absolute;
  top: 50%;
  left: 50%;
  max-width: none;
  transform-origin: center;
  user-select: none;
  -webkit-user-drag: none;
}

.photo-crop-stage img:not([src]) {
  display: none;
}

.photo-crop-stage .student-photo-fallback {
  position: absolute;
  inset: 0;
  font-size: 2.4rem;
}

.photo-crop-stage.has-image .student-photo-fallback {
  display: none;
}

.photo-help {
  margin: -4px 0 0;
  color: var(--muted);
  font-size: .84rem;
  font-weight: 850;
  text-align: center;
}

@media (max-width: 760px) {
  .aq-hero,
  .aq-grid.two,
  .aq-grid.three,
  .student-path-grid,
  .private-billing-panel,
  .private-provider-other,
  .review-tools,
  .review-tools form,
  .review-filters,
  .review-stats {
    grid-template-columns: 1fr;
  }

  .aq-steps {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .aq-hero {
    min-height: 360px;
    padding: 24px;
  }

  .aq-panel-head,
  .aq-panel-head.inline {
    align-items: flex-start;
  }

  .aq-steps {
    grid-template-columns: repeat(2, 1fr);
  }

  .aq-panel-head.inline,
  .student-row header,
  .registration-card header,
  .review-actions,
  .aq-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .review-actions div {
    justify-content: stretch;
  }
}
