/* Florida Education News
   Palette and type follow the logo: #ff1506 red, black, and a Helvetica-class
   grotesque. Corners stay tight and edges stay plain — it should read like a
   news masthead, not a software product. */

:root {
  --red: #ff1506;          /* logo red — marks and rules only */
  --red-ink: #d10d00;      /* red text on the page background (AA on white) */
  --red-ink-hover: #a80a00;
  /* Kept separate from --red-ink: this one carries white text, so it has to
     stay dark even in dark mode, where red *text* has to go lighter. */
  --red-fill: #d10d00;
  --red-fill-hover: #a80a00;

  --ink: #0b0b0c;
  --ink-soft: #33383e;
  --ink-muted: #545a61;
  --page: #ffffff;
  --surface: #ffffff;
  --wash: #f5f5f6;
  --line: #dcdee1;
  --line-strong: #8b9199;   /* form control borders: 3:1 vs white, per WCAG 1.4.11 */

  --focus: #0b57d0;

  --radius: 3px;

  --gutter: clamp(1.25rem, 4vw, 3.5rem);
  --shell: 76rem;

  --font: "Helvetica Neue", Helvetica, ui-sans-serif, system-ui, -apple-system,
          "Segoe UI", Roboto, Arial, sans-serif;
}

@media (prefers-color-scheme: dark) {
  :root {
    --red-ink: #ff5548;
    --red-ink-hover: #ff7a70;
    --red-fill: #d10d00;
    --red-fill-hover: #e81100;
    --ink: #f4f5f6;
    --ink-soft: #c9ced4;
    --ink-muted: #a2a9b1;
    --page: #0c0d0f;
    --surface: #141618;
    --wash: #141618;
    --line: #2a2e33;
    --line-strong: #626973;
    --focus: #8ab4f8;
  }
}

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

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  font-size: clamp(1rem, 0.96rem + 0.2vw, 1.0625rem);
  line-height: 1.6;
  color: var(--ink);
  background: var(--page);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, p, ul { margin: 0; }
ul { padding: 0; list-style: none; }

/* Must outrank the display values set on .form and friends below. */
[hidden] { display: none !important; }

a { color: var(--red-ink); }
a:hover { color: var(--red-ink-hover); }

img { max-width: 100%; height: auto; display: block; }

:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
  border-radius: 2px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.skip-link {
  position: absolute;
  left: 0.5rem;
  top: -100%;
  z-index: 20;
  padding: 0.6rem 1rem;
  background: var(--surface);
  color: var(--ink);
  border: 2px solid var(--red);
  font-weight: 700;
  text-decoration: none;
}
.skip-link:focus { top: 0.5rem; }

.textlink {
  color: var(--red-ink);
  font-weight: 700;
  text-decoration: none;
  border-bottom: 2px solid currentColor;
  padding-bottom: 1px;
}
.textlink:hover { color: var(--red-ink-hover); }

/* --------------------------------------------------------------- masthead */

.brand-rule { height: 6px; background: var(--red); }

.masthead {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  max-width: var(--shell);
  margin: 0 auto;
  padding: 1.35rem var(--gutter);
}

.masthead__logo { display: block; line-height: 0; }

.logo { width: auto; height: clamp(2.75rem, 5vw, 3.5rem); }
.logo--light { display: none; }

@media (prefers-color-scheme: dark) {
  .logo--dark { display: none; }
  .logo--light { display: block; }
}

.yt-link {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  flex: none;
  color: var(--ink);
  font-size: 0.9375rem;
  font-weight: 700;
  text-decoration: none;
}
.yt-link:hover { color: var(--red-ink); }
.yt-link__glyph { width: 1.5rem; height: 1.5rem; color: var(--red); flex: none; }
.yt-link:hover .yt-link__glyph { color: var(--red-ink-hover); }

/* Narrow screens show the glyph alone, but the label stays in the accessibility
   tree — display:none would leave the link with no name at all. */
@media (max-width: 32rem) {
  .yt-link span {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
  }
  .yt-link__glyph { width: 1.85rem; height: 1.85rem; }
}

/* ------------------------------------------------------------------ intro */

.intro {
  position: relative;
  overflow: clip;
  border-bottom: 1px solid var(--line);
}

/* Sized and centred to sit whole in the empty half of the intro — the state
   should read as the whole state, not a cropped edge of one. */
.intro__watermark {
  position: absolute;
  top: 50%;
  right: clamp(0.5rem, 3vw, 3rem);
  transform: translateY(-50%);
  width: min(40%, 30rem);
  height: auto;
  opacity: 0.07;
  pointer-events: none;
  z-index: 0;
}

@media (prefers-color-scheme: dark) {
  .intro__watermark { opacity: 0.13; }
}

.intro__inner {
  position: relative;
  z-index: 1;
  max-width: var(--shell);
  margin: 0 auto;
  padding: clamp(1rem, 3vw, 2.25rem) var(--gutter) clamp(3rem, 6vw, 4.5rem);
}

.intro__title {
  max-width: 20ch;
  font-size: clamp(2.15rem, 1.3rem + 3.5vw, 3.9rem);
  line-height: 1.04;
  letter-spacing: -0.03em;
  font-weight: 700;
}

.intro__lead {
  max-width: 56ch;
  margin-top: 1.4rem;
  color: var(--ink-soft);
  font-size: clamp(1.0625rem, 1rem + 0.3vw, 1.1875rem);
  line-height: 1.65;
}

.intro__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1.5rem;
  margin-top: 2.25rem;
}

/* ------------------------------------------------------------- interviews */

.interviews {
  max-width: var(--shell);
  margin: 0 auto;
  padding: clamp(2.5rem, 5vw, 3.75rem) var(--gutter);
}

.section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.75rem 1.5rem;
  padding-bottom: 0.75rem;
  border-bottom: 2px solid var(--ink);
}

.section-head__title {
  font-size: clamp(1.35rem, 1.2rem + 0.6vw, 1.75rem);
  font-weight: 700;
  letter-spacing: -0.02em;
}

/* Two up even on phones — six stacked full-width thumbnails would bury
   everything below them. Two and three both divide the six cards evenly, so
   every row is full at any width. */
.reel {
  display: grid;
  gap: 1.75rem 1.25rem;
  margin-top: 2rem;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

@media (min-width: 48rem) {
  .reel { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2rem 1.75rem; }
}

.reel__status {
  grid-column: 1 / -1;
  color: var(--ink-muted);
  font-size: 0.9375rem;
}

/* Same note, outside the grid: the noscript copy sits under an empty reel. */
.reel__status--block { margin-top: 2rem; }

.reel__more {
  margin-top: clamp(1.75rem, 3vw, 2.5rem);
  text-align: center;
}

.card__stage {
  position: relative;
  aspect-ratio: 16 / 9;
  background: var(--wash);
  border: 1px solid var(--line);
  overflow: hidden;
}

.card__play {
  display: block;
  width: 100%;
  height: 100%;
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
}

.card__thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;   /* trims the letterbox bars off 4:3 fallbacks */
}

/* Bottom right: these thumbnails carry a name strap along the bottom left
   and the FEN bug in the top right corner. */
.card__badge {
  position: absolute;
  inset: auto 0.5rem 0.5rem auto;
  display: grid;
  place-items: center;
  width: 2.4rem;
  height: 1.7rem;
  color: var(--red);
  background: #fff;
  border-radius: var(--radius);
  transition: transform 0.15s ease;
}
.card__badge svg { width: 1.5rem; height: 1.5rem; }

.card__play:hover .card__badge { transform: scale(1.08); }
.card__play:hover .card__thumb { opacity: 0.92; }

.card__frame { width: 100%; height: 100%; border: 0; display: block; }

.card__title {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;   /* keeps rows aligned when a name runs long */
  overflow: hidden;
  margin-top: 0.7rem;
  font-size: 0.9375rem;
  font-weight: 700;
  line-height: 1.4;
  letter-spacing: -0.005em;
}

.card__title a {
  color: var(--ink);
  text-decoration: none;
}
.card__title a:hover { color: var(--red-ink); text-decoration: underline; }

.card__date {
  display: block;
  margin-top: 0.2rem;
  color: var(--ink-muted);
  font-size: 0.8125rem;
}

/* -------------------------------------------------------------------- ask */

.ask {
  border-top: 1px solid var(--line);
  background: var(--wash);
}

.ask__grid {
  display: grid;
  gap: clamp(2rem, 4vw, 3.5rem);
  align-items: start;
  max-width: var(--shell);
  margin: 0 auto;
  padding: clamp(2.5rem, 5vw, 4rem) var(--gutter);
}

@media (min-width: 60rem) {
  .ask__grid { grid-template-columns: minmax(0, 1fr) minmax(0, 34rem); }
}

.ask__copy { max-width: 44ch; color: var(--ink-soft); }

.ask__title {
  margin-bottom: 1rem;
  font-size: clamp(1.75rem, 1.4rem + 1.4vw, 2.5rem);
  line-height: 1.1;
  letter-spacing: -0.025em;
  font-weight: 700;
  color: var(--ink);
}


.panel {
  background: var(--surface);
  border: 1px solid var(--line-strong);
  scroll-margin-top: 1.5rem;
}

/* ------------------------------------------------------------------- form */

.form {
  display: grid;
  gap: 1.1rem;
  padding: clamp(1.35rem, 3vw, 1.85rem);
}

.field { display: grid; gap: 0.35rem; align-content: start; }

/* Once the panel is wide enough, the four short fields pair off two to a row.
   Keeps the form roughly the height of the copy beside it. */
@media (min-width: 60rem) {
  .form { grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 1rem; }
  .form > :not(.field--pair) { grid-column: 1 / -1; }
}

.field__label {
  font-size: 0.875rem;
  font-weight: 700;
}

.req { color: var(--red-ink); text-decoration: none; border: 0; }

.field__input {
  width: 100%;
  padding: 0.65rem 0.75rem;
  font: inherit;
  font-size: 1rem;   /* keeps iOS from zooming on focus */
  color: var(--ink);
  background: var(--page);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  transition: border-color 0.15s ease;
}

textarea.field__input { resize: vertical; min-height: 3rem; line-height: 1.55; }

.field__input::placeholder { color: var(--ink-muted); opacity: 1; }
.field__input:hover { border-color: var(--ink-muted); }

.field__input:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 0;
  border-color: var(--focus);
}

.field__input[aria-invalid="true"] { border-color: var(--red-ink); }

.select { position: relative; }

.select::after {
  content: "";
  position: absolute;
  right: 0.9rem;
  top: 50%;
  width: 0.5rem;
  height: 0.5rem;
  border-right: 2px solid var(--ink-muted);
  border-bottom: 2px solid var(--ink-muted);
  transform: translateY(-70%) rotate(45deg);
  pointer-events: none;
}

.select .field__input { appearance: none; padding-right: 2.4rem; }

.field__hint {
  color: var(--ink-muted);
  font-size: 0.8125rem;
  line-height: 1.45;
}

.field__error {
  color: var(--red-ink);
  font-size: 0.8125rem;
  font-weight: 600;
  line-height: 1.45;
}

.decoy {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.form__fine {
  color: var(--ink-muted);
  font-size: 0.8125rem;
  line-height: 1.5;
}

.form__alert {
  padding: 0.65rem 0.8rem;
  color: var(--red-ink);
  background: var(--page);
  border: 1px solid var(--red-ink);
  border-radius: var(--radius);
  font-size: 0.875rem;
  font-weight: 600;
}

/* ---------------------------------------------------------------- buttons */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  padding: 0.8rem 1.35rem;
  font: inherit;
  font-size: 0.9375rem;
  font-weight: 700;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  border: 1px solid transparent;
  border-radius: var(--radius);
  cursor: pointer;
  transition: background-color 0.15s ease, border-color 0.15s ease;
}

.btn__glyph { width: 1.3rem; height: 1.3rem; flex: none; }

.btn--primary { color: #fff; background: var(--red-fill); }
.btn--primary:hover { background: var(--red-fill-hover); color: #fff; }

.btn--quiet {
  color: var(--ink);
  background: transparent;
  border-color: var(--line-strong);
}
.btn--quiet:hover { color: var(--ink); border-color: var(--ink); }

.btn:disabled { opacity: 0.6; cursor: progress; }

.form__submit { width: 100%; padding-block: 0.85rem; font-size: 1rem; }

@media (min-width: 30rem) {
  .form__submit { justify-self: start; width: auto; padding-inline: 2rem; }
}

/* --------------------------------------------------------- success state */

.done { padding: clamp(2rem, 4vw, 2.75rem) clamp(1.35rem, 3vw, 1.85rem); }

.done__title {
  margin-bottom: 0.6rem;
  padding-left: 0.85rem;
  border-left: 4px solid var(--red);
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.25;
}

.done__body { color: var(--ink-muted); }

/* ------------------------------------------------------------------ footer */

.footer {
  padding: clamp(2.5rem, 5vw, 3.5rem) var(--gutter) 2rem;
  color: #e8e9ea;
  background: #0b0b0c;
  border-top: 6px solid var(--red);
}

.footer__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  max-width: var(--shell);
  margin: 0 auto;
}

.footer__logo { width: auto; height: clamp(3rem, 6vw, 3.75rem); }

.footer__links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 1.75rem;
  font-size: 0.9375rem;
}

.footer__links a { color: #fff; text-decoration: none; border-bottom: 1px solid #4a4d51; }
.footer__links a:hover { color: #ff9d95; border-bottom-color: currentColor; }

.footer__legal {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.4rem 1.5rem;
  max-width: var(--shell);
  margin: 2.5rem auto 0;
  padding-top: 1.25rem;
  border-top: 1px solid #26282b;
  color: #9aa0a6;
  font-size: 0.8125rem;
}

/* The footer stays dark in both schemes, so the credit can't take the
   page's link colour. */
.footer__credit a { color: #e8e9ea; text-decoration: none; border-bottom: 1px solid #4a4d51; }
.footer__credit a:hover { color: #ff9d95; border-bottom-color: currentColor; }

/* ------------------------------------------------------------- preferences */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
