/* ===================================================================
   Tide Hoops Insider Experience
   ------------------------------------------------------------------
   1.  Tokens
   2.  Reset & base
   3.  Typography primitives
   4.  Buttons
   5.  Header & menu
   6.  Hero
   7.  Introduction
   8.  Selling-point blocks
   9.  Statement band
   10. Agenda
   11. Participation
   12. Registration form
   13. Footer
   14. Motion
   =================================================================== */


/* ------------------------------------------------------------------
   1. TOKENS
   ------------------------------------------------------------------ */
:root {
  /* Brand */
  --crimson:      #a32036;
  --charcoal:     #3a3a3a;
  --light-grey:   #a5a5a5;
  --white:        #ffffff;

  /* Derived — supporting tones (see brief §3) */
  --crimson-deep: #8a1a2d;
  --ink:          #1f1f1f;
  --bone:         #f7f6f4;
  --rule:         #e3e1de;
  --rule-dark:    rgba(255, 255, 255, .18);
  --muted:        #6f6f6f;   /* AA on white; light-grey is decorative only */

  /* Type */
  --serif: "charter-bt-pro", Charter, "Bitstream Charter", "Sitka Text",
           Cambria, Georgia, "Times New Roman", serif;
  --script: "Fenway Park JF", "Snell Roundhand", "Apple Chancery", cursive;

  --t-12: .75rem;
  --t-14: .875rem;
  --t-16: 1rem;
  --t-18: 1.125rem;
  --t-20: 1.25rem;
  --t-28: clamp(1.375rem, 1.15rem + .9vw,  1.75rem);
  --t-40: clamp(1.75rem,  1.35rem + 1.7vw, 2.5rem);
  --t-64: clamp(2.25rem,  1.5rem  + 3.2vw, 4rem);
  --t-96: clamp(3rem,     1.6rem  + 6vw,   6rem);

  /* Rhythm */
  --gutter: clamp(1.5rem, 5vw, 4rem);
  --section-y: clamp(5rem, 11vh, 9.5rem);
  --header-h: 82px;

  --ease: cubic-bezier(.22, .61, .36, 1);
}

@media (max-width: 700px) {
  :root { --header-h: 64px; }
}

@font-face {
  font-family: "Fenway Park JF";
  src: url("media/fonts/FenwayParkJF.woff2") format("woff2"),
       url("media/fonts/FenwayParkJF.otf")   format("opentype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}


/* ------------------------------------------------------------------
   2. RESET & BASE
   ------------------------------------------------------------------ */
*, *::before, *::after { box-sizing: border-box; }

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

body {
  margin: 0;
  background: var(--white);
  color: var(--charcoal);
  font-family: var(--serif);
  font-size: var(--t-18);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

body.is-locked { overflow: hidden; }

img, picture, svg { display: block; max-width: 100%; }

h1, h2, h3, h4, p, dl, dd, figure, fieldset, legend, ul, ol { margin: 0; padding: 0; }
fieldset { border: 0; min-width: 0; }
ul, ol { list-style: none; }

a { color: inherit; }

button, input, select, textarea {
  font: inherit;
  color: inherit;
}

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

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 200;
  background: var(--ink);
  color: var(--white);
  padding: .75rem 1.25rem;
  font-size: var(--t-14);
  letter-spacing: .08em;
  text-transform: uppercase;
  text-decoration: none;
}
.skip-link:focus { left: 1rem; top: 1rem; }

.wrap {
  width: 100%;
  max-width: 1240px;
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.wrap--narrow { max-width: 760px; }
.wrap--form   { max-width: 800px; }

[id] { scroll-margin-top: calc(var(--header-h) + 2rem); }


/* ------------------------------------------------------------------
   3. TYPOGRAPHY PRIMITIVES
   ------------------------------------------------------------------ */
.script { font-family: var(--script); font-weight: 400; }

.kicker {
  font-family: var(--script);
  font-size: clamp(1.5rem, 1.2rem + 1.2vw, 2.125rem);
  line-height: 1;
  color: var(--crimson);
  margin-bottom: .85rem;
}
.kicker--light { color: var(--white); }

.section-head { margin-bottom: clamp(2.5rem, 6vh, 4.5rem); }
.section-head--center { text-align: center; }
.section-head--center .section-note { margin-inline: auto; }

.section-title {
  font-size: var(--t-64);
  font-weight: 400;
  line-height: 1.08;
  letter-spacing: -.01em;
  color: var(--ink);
}

.section-note {
  max-width: 60ch;
  margin-top: 1.5rem;
  font-size: var(--t-18);
  color: var(--muted);
}


/* ------------------------------------------------------------------
   4. BUTTONS
   ------------------------------------------------------------------ */
.btn {
  --btn-bg: var(--crimson);
  --btn-fg: var(--white);
  --btn-bd: var(--crimson);

  display: inline-block;
  border: 1px solid var(--btn-bd);
  background: var(--btn-bg);
  color: var(--btn-fg);
  padding: 1.05rem 2.4rem;
  font-size: var(--t-14);
  font-weight: 700;
  letter-spacing: .13em;
  text-transform: uppercase;
  text-decoration: none;
  text-align: center;
  cursor: pointer;
  transition: background-color .3s var(--ease), color .3s var(--ease),
              border-color .3s var(--ease), opacity .3s var(--ease);
}
.btn:hover { --btn-bg: var(--crimson-deep); --btn-bd: var(--crimson-deep); }

.btn--small { padding: .72rem 1.5rem; font-size: var(--t-12); }

/* The hero's primary call to action — wider than the header's. */
.hero__cta .btn { padding-inline: 3.25rem; }

.btn[disabled] { opacity: .55; cursor: default; }


/* ------------------------------------------------------------------
   5. HEADER & MENU
   ------------------------------------------------------------------ */
.masthead {
  position: fixed;
  inset: 0 0 auto;
  z-index: 100;
  height: var(--header-h);
  transition: background-color .4s var(--ease), border-color .4s var(--ease);
  border-bottom: 1px solid transparent;
}

.masthead__inner {
  height: 100%;
  max-width: 1400px;
  margin-inline: auto;
  padding-inline: var(--gutter);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.masthead__logo {
  position: relative;
  display: block;
  flex: 0 0 auto;
  line-height: 0;
}
.masthead__logo-img {
  width: auto;
  height: 34px;
  transition: opacity .4s var(--ease);
}
.masthead__logo-img--white { position: absolute; inset: 0; opacity: 0; }

.masthead__nav {
  display: flex;
  align-items: center;
  gap: clamp(1.25rem, 2.4vw, 2.5rem);
  font-size: var(--t-12);
  letter-spacing: .14em;
  text-transform: uppercase;
}
.masthead__nav a:not(.btn) { text-decoration: none; color: var(--charcoal); transition: color .3s var(--ease); }
.masthead__nav a.btn { text-decoration: none; }
.masthead__nav a:not(.btn) { position: relative; padding-block: .35rem; }
.masthead__nav a:not(.btn)::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .35s var(--ease);
}
.masthead__nav a:not(.btn):hover::after,
.masthead__nav a:not(.btn).is-active::after { transform: scaleX(1); }

/* Solid state — the hero is already light, so this only adds the surface
   and the hairline that separates the header from what scrolls under it. */
.masthead[data-state="solid"] {
  background: var(--white);
  border-bottom-color: var(--rule);
}

/* Mobile toggle */
.masthead__toggle {
  display: none;
  align-items: center;
  gap: .65rem;
  background: none;
  border: 0;
  padding: .5rem 0;
  color: var(--charcoal);
  cursor: pointer;
  font-size: var(--t-12);
  letter-spacing: .14em;
  text-transform: uppercase;
}
.masthead__toggle-rules { display: block; width: 22px; }
.masthead__toggle-rules i {
  display: block;
  height: 1px;
  background: currentColor;
  transition: transform .35s var(--ease), opacity .3s var(--ease);
}
.masthead__toggle-rules i + i { margin-top: 5px; }
.masthead__toggle[aria-expanded="true"] { color: var(--white); }
.masthead__toggle[aria-expanded="true"] .masthead__toggle-rules i:first-child { transform: translateY(3px) rotate(45deg); }
.masthead__toggle[aria-expanded="true"] .masthead__toggle-rules i:last-child  { transform: translateY(-3px) rotate(-45deg); }

@media (max-width: 900px) {
  .masthead__nav { display: none; }
  .masthead__toggle { display: flex; }
  .masthead__logo-img { height: 26px; }
}

/* Full-screen overlay menu */
.menu {
  position: fixed;
  inset: 0;
  z-index: 90;
  background: var(--ink);
  display: grid;
  place-items: center;
  opacity: 0;
  transition: opacity .45s var(--ease);
}
.menu[hidden] { display: none; }
.menu.is-open { opacity: 1; }

.menu__inner { text-align: center; padding: var(--gutter); }
.menu__logo { width: min(260px, 60vw); height: auto; margin: 0 auto 3.5rem; }

.menu__nav { display: grid; gap: 1.75rem; }
.menu__nav a {
  font-size: var(--t-28);
  text-decoration: none;
  color: var(--white);
  transition: color .3s var(--ease);
}
.menu__nav a:hover { color: var(--light-grey); }

.menu__meta {
  margin-top: 3.5rem;
  font-size: var(--t-12);
  letter-spacing: .16em;
  text-transform: uppercase;
  line-height: 2;
  color: var(--light-grey);
}


/* ------------------------------------------------------------------
   6. HERO
   ------------------------------------------------------------------ */
.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: grid;
  place-items: center;
  overflow: hidden;
  /* White at the top, settling into the off-white band so the hero hands off
     to the introduction without a seam. */
  background: linear-gradient(180deg, var(--white) 0%, var(--white) 52%, var(--bone) 100%);
}

.hero__content {
  text-align: center;
  color: var(--charcoal);
  padding: calc(var(--header-h) + 3rem) var(--gutter) 7rem;
  max-width: 900px;
}

.hero__eyebrow {
  font-size: var(--t-12);
  letter-spacing: .34em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 2.75rem;
}
.hero__eyebrow span { position: relative; padding-inline: 2.1rem; }
.hero__eyebrow span::before,
.hero__eyebrow span::after {
  content: "";
  position: absolute;
  top: 50%;
  width: 1.35rem;
  height: 1px;
  background: var(--crimson);
}
.hero__eyebrow span::before { left: 0; }
.hero__eyebrow span::after  { right: 0; }

/* Alternative treatment — script eyebrow (see handoff note).
   Swap the .hero__eyebrow markup for <p class="hero__eyebrow hero__eyebrow--script">An Invitation</p> */
.hero__eyebrow--script {
  font-family: var(--script);
  font-size: clamp(1.75rem, 1.2rem + 2vw, 2.75rem);
  letter-spacing: 0;
  text-transform: none;
  color: var(--crimson);
}
.hero__eyebrow--script span { padding: 0; }
.hero__eyebrow--script span::before,
.hero__eyebrow--script span::after { content: none; }

.hero__title { margin-bottom: 2.75rem; }
.hero__title img {
  width: min(540px, 72vw);
  height: auto;
  margin-inline: auto;
}

.hero__dates {
  font-size: var(--t-14);
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--ink);
}
.hero__when, .hero__where { display: inline; }
.hero__dot { padding-inline: .9em; color: var(--light-grey); }

/* Hairline between the dates and the supporting line. */
.hero__rule {
  display: block;
  width: 40px;
  height: 1px;
  margin: 2.25rem auto 0;
  background: var(--crimson);
}

.hero__lede {
  margin: 2rem auto 0;
  max-width: 46ch;
  font-size: var(--t-20);
  font-style: italic;
  line-height: 1.6;
  color: var(--muted);
  text-wrap: balance;
}

.hero__cta { margin-top: 3.25rem; }

/* Marks the foot of the hero; the header watches it to decide when to solidify. */
.hero__sentinel {
  position: absolute;
  left: 0;
  bottom: 0;
  width: 1px;
  height: 1px;
}

.hero__scroll {
  position: absolute;
  left: 50%;
  bottom: 2.25rem;
  transform: translateX(-50%);
  display: grid;
  justify-items: center;
  gap: .85rem;
  text-decoration: none;
  color: var(--muted);
  font-size: 10px;
  letter-spacing: .3em;
  text-transform: uppercase;
  transition: color .3s var(--ease);
}
.hero__scroll:hover { color: var(--ink); }
.hero__scroll i {
  display: block;
  width: 1px;
  height: 46px;
  background: linear-gradient(to bottom, var(--light-grey), rgba(165, 165, 165, 0));
}

@media (max-width: 700px) {
  .hero__title img { width: min(560px, 70vw); }
  .hero__dates { font-size: var(--t-12); letter-spacing: .1em; line-height: 1.9; }
  .hero__when { display: block; text-wrap: balance; }
  .hero__where { display: block; }
  .hero__dot { display: none; }
  .hero__scroll { display: none; }
}


/* ------------------------------------------------------------------
   7. INTRODUCTION
   ------------------------------------------------------------------ */
.intro {
  padding-block: var(--section-y);
  text-align: center;
  background: var(--bone);
}
/* The welcome statement is set large, so it needs a wider measure than the
   default narrow wrap or it stacks into too many short lines. */
.intro .wrap--narrow { max-width: 880px; }
.intro__lead {
  font-size: var(--t-40);
  line-height: 1.28;
  letter-spacing: -.005em;
  color: var(--ink);
  text-wrap: pretty;
}
.intro__body {
  margin-top: 1.75rem;
  font-size: var(--t-18);
  color: var(--muted);
  max-width: 56ch;
  margin-inline: auto;
}
.intro__sign {
  margin-top: 3rem;
  font-size: var(--t-16);
  color: var(--muted);
}
.intro__sign .script { font-size: 1.9rem; color: var(--crimson); }


/* ------------------------------------------------------------------
   7b. FACILITY EXTERIOR
   Sits on the same off-white field as the introduction so a cutout reads
   as floating on the page rather than pasted into a box.
   ------------------------------------------------------------------ */
.facility {
  background: var(--bone);
  padding-bottom: clamp(3rem, 8vh, 6rem);
}

.facility__figure {
  margin: 0 auto;
  max-width: 1120px;
}
.facility__figure img {
  width: 100%;
  height: auto;
}

/* ------------------------------------------------------------------
   8. SELLING-POINT BLOCKS
   Alternates automatically: every even block flips sides.
   ------------------------------------------------------------------ */
.blocks { padding-bottom: var(--section-y); }

.block {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  align-items: center;
  gap: clamp(2rem, 6vw, 6rem);
  max-width: 1400px;
  margin-inline: auto;
  padding: clamp(2.5rem, 6vh, 5rem) var(--gutter);
}

.block__media { margin: 0; }
.block__media img { width: 100%; height: auto; }

.block:nth-child(even) .block__media { order: 2; }

.block__body { max-width: 46ch; }
.block:nth-child(even) .block__body { justify-self: end; }

.block__title {
  font-size: var(--t-40);
  font-weight: 400;
  line-height: 1.12;
  letter-spacing: -.01em;
  color: var(--ink);
  margin-bottom: 1.5rem;
}

.block__body p + p { margin-top: 1.1rem; }
.block__body > p:not(.kicker) { color: var(--muted); }

/* Placeholder panel for pending photography */
.block__placeholder {
  display: grid;
  place-items: center;
  aspect-ratio: 4 / 3;
  background: var(--ink);
}
.block__placeholder img { width: 46%; max-width: 260px; height: auto; opacity: .17; }

@media (max-width: 900px) {
  .block { grid-template-columns: 1fr; gap: 2.25rem; }
  .block:nth-child(even) .block__media { order: 0; }
  .block:nth-child(even) .block__body { justify-self: start; }
  .block__body { max-width: 56ch; }
}


/* ------------------------------------------------------------------
   9. STATEMENT BAND
   ------------------------------------------------------------------ */
.band {
  position: relative;
  isolation: isolate;
  min-height: clamp(340px, 62vh, 620px);
  display: grid;
  place-items: center;
  overflow: hidden;
}
.band__media { position: absolute; inset: 0; z-index: -2; }
.band__media img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 45%; }
.band__scrim {
  position: absolute; inset: 0; z-index: -1;
  background:
    radial-gradient(64% 74% at 50% 50%,
      rgba(31, 31, 31, .42) 0%,
      rgba(31, 31, 31, .16) 68%,
      rgba(31, 31, 31, 0)  100%),
    linear-gradient(to bottom, rgba(31, 31, 31, .52), rgba(31, 31, 31, .66));
}
.band__content {
  text-align: center;
  color: var(--white);
  padding: 4rem var(--gutter);
  max-width: 900px;
}
.band__line {
  font-size: var(--t-64);
  line-height: 1.12;
  letter-spacing: -.01em;
  text-wrap: balance;
}


/* ------------------------------------------------------------------
   10. AGENDA
   ------------------------------------------------------------------ */
.agenda {
  background: var(--bone);
  padding-block: var(--section-y);
}

.day + .day { margin-top: clamp(3.5rem, 8vh, 6rem); }

.day__title {
  font-size: var(--t-28);
  font-weight: 400;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--ink);
  padding-bottom: 1.15rem;
  border-bottom: 1px solid var(--charcoal);
}

.track { margin-top: 2.75rem; }

.track__title {
  font-size: var(--t-12);
  font-weight: 700;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--crimson);
  margin-bottom: 1.25rem;
}
.track__title span { opacity: .5; padding-inline: .35em; }

.sched__row {
  display: grid;
  grid-template-columns: 190px 1fr;
  gap: 1.5rem 2.5rem;
  padding: 1.15rem 0;
  border-top: 1px solid var(--rule);
}
.sched__row:first-child { border-top: 0; padding-top: 0; }

.sched dt {
  font-size: var(--t-14);
  font-weight: 700;
  letter-spacing: .07em;
  text-transform: uppercase;
  color: var(--ink);
  padding-top: .2rem;
}
.sched dd { font-size: var(--t-18); color: var(--charcoal); max-width: 62ch; }

.agenda__close {
  margin-top: clamp(3rem, 7vh, 5rem);
  padding-top: 2rem;
  border-top: 1px solid var(--rule);
  font-size: var(--t-18);
  font-style: italic;
  color: var(--muted);
  max-width: 56ch;
}

@media (max-width: 700px) {
  .sched__row { grid-template-columns: 1fr; gap: .4rem; padding: 1.25rem 0; }
  .sched dt { padding-top: 0; }
  .sched dd { font-size: var(--t-16); }
}


/* ------------------------------------------------------------------
   11. PARTICIPATION
   ------------------------------------------------------------------ */
.cost {
  background: var(--ink);
  color: var(--white);
  padding-block: var(--section-y);
  text-align: center;
}

.cost__figure {
  font-size: var(--t-96);
  font-weight: 400;
  line-height: 1;
  letter-spacing: -.02em;
}

.cost__unit {
  margin-top: 1.1rem;
  font-size: var(--t-12);
  letter-spacing: .3em;
  text-transform: uppercase;
  color: var(--light-grey);
}

.cost__list {
  margin: clamp(3rem, 7vh, 4.5rem) auto 0;
  max-width: 620px;
  text-align: left;
  border-top: 1px solid var(--rule-dark);
}
.cost__list li {
  padding: 1rem 0 1rem 2.1rem;
  border-bottom: 1px solid var(--rule-dark);
  font-size: var(--t-16);
  color: rgba(255, 255, 255, .84);
  position: relative;
}
.cost__list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 1.6rem;
  width: 12px;
  height: 1px;
  background: var(--crimson);
}

.cost__note {
  margin: 2.5rem auto 0;
  max-width: 52ch;
  font-size: var(--t-14);
  font-style: italic;
  color: var(--light-grey);
}

.cost__footnote {
  margin: 1.5rem auto 0;
  max-width: 52ch;
  font-size: var(--t-12);
  line-height: 1.6;
  color: var(--light-grey);
}


/* ------------------------------------------------------------------
   12. REGISTRATION (Jotform embed)
   The form is built in Jotform; this section only frames it.
   ------------------------------------------------------------------ */
.register { padding-block: var(--section-y); }

.jotform { width: 100%; }

.jotform__frame {
  display: block;
  width: 1px;              /* with min-width:100% this makes the iframe */
  min-width: 100%;         /* shrink-to-fit correctly on iOS Safari */
  border: 0;
  min-height: 620px;       /* holds the space until the handler reports height */
}
/* Used only when the form never reports its height — the frame becomes tall
   and scrollable so no field is left unreachable. */
.jotform__frame--static { height: 1600px; min-height: 0; }

/* Stand-in shown while JOTFORM_ID is still the placeholder. */
.jotform__placeholder {
  display: grid;
  place-content: center;
  gap: .75rem;
  text-align: center;
  min-height: 320px;
  padding: 3rem var(--gutter);
  border: 1px dashed var(--light-grey);
  background: var(--bone);
}
.jotform__placeholder-label {
  font-size: var(--t-12);
  font-weight: 700;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--muted);
}
.jotform__placeholder-note {
  font-size: var(--t-16);
  color: var(--muted);
  max-width: 44ch;
}

.register__fallback {
  margin-top: 2.5rem;
  text-align: center;
  font-size: var(--t-14);
  color: var(--muted);
}
.register__fallback a {
  color: var(--crimson);
  text-underline-offset: 3px;
}


/* ------------------------------------------------------------------
   13. FOOTER
   ------------------------------------------------------------------ */
.footer {
  background: var(--ink);
  color: var(--light-grey);
  padding-block: clamp(3.5rem, 8vh, 6rem);
  text-align: center;
}
.footer__logo { width: min(220px, 52vw); height: auto; margin: 0 auto 2.5rem; }
.footer__meta {
  font-size: var(--t-12);
  letter-spacing: .18em;
  text-transform: uppercase;
  line-height: 2.1;
  color: rgba(255, 255, 255, .72);
}
.footer__contact { margin-top: 2rem; font-size: var(--t-16); color: rgba(255,255,255,.72); }
.footer__contact a { color: var(--white); text-decoration: none; border-bottom: 1px solid rgba(255,255,255,.35); padding-bottom: 2px; }
.footer__contact a:hover { border-bottom-color: var(--white); }
.footer__fine { margin-top: 2.5rem; font-size: var(--t-12); color: rgba(255, 255, 255, .42); }


/* ------------------------------------------------------------------
   14. MOTION
   ------------------------------------------------------------------ */
.js [data-reveal] {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity .9s var(--ease), transform .9s var(--ease);
}
.js [data-reveal].is-visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
  .js [data-reveal] { opacity: 1; transform: none; }
}


/* ------------------------------------------------------------------
   15. STATE OVERRIDES
   ------------------------------------------------------------------ */
.masthead.is-menu-open {
  background: transparent;
  border-bottom-color: transparent;
}
.masthead.is-menu-open .masthead__logo-img--white { opacity: 1; }
.masthead.is-menu-open .masthead__logo-img--color { opacity: 0; }
.masthead.is-menu-open .masthead__toggle { color: var(--white); }

