/* ============================================================
   Rocket City Swim League - Redesign Stylesheet
   Design system version: V26.00.01
   Mobile-first, responsive. Replaces table-based Dreamweaver layout.
   ============================================================ */

/* ---- Self-hosted web fonts (files live in ../fonts/) ------------------
   Bebas Neue = display/headings (one weight, all-caps).
   Roboto     = body/UI (variable, covers weights 400–900 in one file).
   Relative ../fonts/ paths resolve from this CSS file's own location,
   so they work no matter where this stylesheet is served from.           */
@font-face {
  font-family: 'Bebas Neue'; font-style: normal; font-weight: 400; font-display: swap;
  src: url('../fonts/bebas-neue-latin-400.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Bebas Neue'; font-style: normal; font-weight: 400; font-display: swap;
  src: url('../fonts/bebas-neue-latin-ext-400.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Roboto'; font-style: normal; font-weight: 400 900; font-display: swap;
  src: url('../fonts/roboto-latin-var.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Roboto'; font-style: normal; font-weight: 400 900; font-display: swap;
  src: url('../fonts/roboto-latin-ext-var.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

/* ---- Design tokens ---- */
:root {
  --blue-900: #10275f;
  --blue-700: #1b4fd8;
  --blue-600: #2563eb;
  --blue-500: #3b82f6;
  --blue-100: #dbeafe;
  --teal-500: #14b8a6;
  --teal-300: #8dc8bd;   /* legacy RCSL panel teal */
  --teal-100: #d5f0ea;
  --ink:      #1e293b;
  --ink-soft: #475569;
  --line:     #e2e8f0;
  --bg:       #f4f7fb;
  --white:    #ffffff;
  --sun:      #ffb703;

  --radius: 14px;
  --radius-sm: 9px;
  --shadow: 0 6px 20px rgba(16, 39, 95, 0.08);
  --shadow-lg: 0 14px 40px rgba(16, 39, 95, 0.16);
  --wrap: 1080px;
  --font: 'Roboto', system-ui, -apple-system, "Segoe UI", Helvetica, Arial, sans-serif;
  --font-head: 'Bebas Neue', 'Oswald', 'Arial Narrow', Impact, system-ui, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.45;
  color: var(--ink);
  background: var(--bg);
  -webkit-text-size-adjust: 100%;
}

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

a { color: var(--blue-600); text-decoration: none; }
a:hover { text-decoration: underline; }

p { margin: 0 0 .5em; }
ol, ul { margin: .3em 0; }

/* Headings use Bebas Neue (display). It's a single-weight all-caps face, so
   pin font-weight:400 (no faux-bold), add a little tracking, and tighten the
   line-height that tall all-caps type wants. Sizes bumped ~15% since Bebas is
   condensed and reads smaller than a normal-width sans at the same px. */
h1, h2, h3 {
  font-family: var(--font-head);
  font-weight: 400;
  letter-spacing: .02em;
  line-height: 1.08;
  color: var(--blue-900);
  margin: 0 0 .3em;
}
h1 { font-size: 1.9rem; }
h2 { font-size: 1.5rem; }
h3 { font-size: 1.2rem; }

@media (min-width: 700px) {
  h1 { font-size: 2.4rem; }
  h2 { font-size: 1.75rem; }
}

/* ---- Version badge (upper-left, per project rules) ---- */
.version-badge {
  position: fixed;
  top: 8px;
  left: 8px;
  z-index: 200;
  background: rgba(16, 39, 95, .78);
  color: #fff;
  font-size: 10px;
  letter-spacing: .04em;
  padding: 2px 7px;
  border-radius: 999px;
  pointer-events: none;
}

/* ---- Skip link (accessibility) ---- */
.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: #fff;
  padding: 10px 16px;
  border-radius: 0 0 8px 0;
  z-index: 300;
}
.skip-link:focus { left: 0; }

/* ============================================================
   Header + Navigation
   ============================================================ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  /* Pool water: rippling wave lines (inline SVG) layered over a blue→teal gradient */
  background-color: var(--blue-600);
  background-image:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='46'%3E%3Cpath d='M0 12 Q35 -4 70 12 T140 12' fill='none' stroke='%23ffffff' stroke-opacity='0.09' stroke-width='2.5'/%3E%3Cpath d='M0 24 Q35 8 70 24 T140 24' fill='none' stroke='%23ffffff' stroke-opacity='0.14' stroke-width='2.5'/%3E%3Cpath d='M0 36 Q35 20 70 36 T140 36' fill='none' stroke='%23ffffff' stroke-opacity='0.09' stroke-width='2.5'/%3E%3C/svg%3E"),
    linear-gradient(90deg, var(--teal-500), var(--blue-700) 50%, var(--teal-500));
  background-repeat: repeat, no-repeat;
  background-position: 0 0, 0 0;
  color: #fff;
  box-shadow: var(--shadow);
  animation: rcsl-wave-drift 11s linear infinite;   /* gentle moving water */
}
@media (prefers-reduced-motion: reduce) {
  .site-header { animation: none; }   /* honor the visitor's motion preference */
}
@keyframes rcsl-wave-drift {
  to { background-position: 140px 0, 0 0; }
}

/* Concrete pool coping across the very top, casting a soft shadow onto the water */
.site-header::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 8px;
  background: linear-gradient(#f2efe8, #d9d3c6 55%, #bfb8a8);
  box-shadow: 0 5px 9px rgba(6, 20, 55, .50);
  z-index: 3;
}

/* Scalloped edges on the top AND bottom of the menu bar — desktop only.
   They vanish in phone mode (the menu collapses into the hamburger). */
@media (min-width: 860px) {
  .site-nav { position: relative; }
  .site-nav::before,
  .site-nav::after {
    content: "";
    position: absolute;
    left: 0; right: 0;
    height: 10px;
    background-repeat: repeat-x;
    background-size: 44px 10px;
    pointer-events: none;
  }
  /* top edge: blue scallops rising up into the water */
  .site-nav::before {
    top: -10px;
    background-position: bottom;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='44' height='10'%3E%3Cpath fill='%2310275f' d='M0 10 H44 V5 Q33 -1 22 5 Q11 -1 0 5 Z'/%3E%3C/svg%3E");
  }
  /* bottom edge: blue scallops hanging down into the page */
  .site-nav::after {
    bottom: -10px;
    background-position: top;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='44' height='10'%3E%3Cpath fill='%2310275f' d='M0 0 H44 V5 Q33 11 22 5 Q11 11 0 5 Z'/%3E%3C/svg%3E");
  }
}

/* Full-width bar carries the bottom-edge shadow so it spans edge to edge,
   matching the full-width concrete shadow at the top (no mid-header artifacts). */
.header-bar {
  position: relative;
  box-shadow: inset 0 -12px 11px -5px rgba(6, 20, 55, .62);
}
/* Centered inner holds the actual header content (hamburger / logo / blast). */
.header-bar-inner {
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 12px 10px 13px 12px;   /* top/left/bottom; right = 10px min gap for the blast image */
  display: grid;
  grid-template-columns: 1fr auto 1fr;   /* [hamburger] [brand] [tagline] */
  align-items: center;
  column-gap: 8px;
}
@media (min-width: 860px) {
  .header-bar-inner { padding: 18px 10px 20px 16px; }   /* ~22% water margin; keeps 10px right gap */
}

/* Brand: "Rocket City" / "Swim & Dive" / small uppercase locale, centered */
.brand { grid-column: 2; display: flex; flex-direction: column; align-items: center; line-height: 1.1; }
.brand a { color: #fff; text-decoration: none; display: flex; flex-direction: column; align-items: center; }
.brand-logo {
  display: block;
  height: 70px;           /* logo carries all three lines, incl. Huntsville, AL */
  width: auto;
  max-width: 62vw;
  object-fit: contain;
  transform: translateY(3px);                          /* nudge down to look centered */
  filter: drop-shadow(0 4px 6px rgba(6, 20, 55, .72)); /* shadow on the letterforms (2x prior) */
}
@media (min-width: 700px) { .brand-logo { height: 132px; max-width: 60vw; } }

/* "It's a BLAST!" image, pinned to the right (portrait PNG, sized by height) */
.tagline-img {
  grid-column: 3;
  justify-self: end;
  display: block;
  height: 78px;
  width: auto;
  max-width: 40vw;
  object-fit: contain;
  margin-right: 0;               /* right gap comes from the inner's 10px right padding */
  transform: translateY(4px);    /* nudge down so the rocket art reads as centered */
  filter: drop-shadow(0 4px 6px rgba(6, 20, 55, .72));   /* same shadow as the logo */
}
@media (min-width: 700px) { .tagline-img { height: 132px; } }

/* Hamburger button pinned to the left (mobile only) */
.nav-toggle {
  grid-column: 1;
  justify-self: start;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: rgba(255,255,255,.15);
  border: 1px solid rgba(255,255,255,.35);
  color: #fff;
  font-size: .85rem;
  font-weight: 600;
  padding: 6px 10px;
  border-radius: 9px;
  cursor: pointer;
}
.nav-toggle .bars {
  width: 18px; height: 2px; background: #fff; position: relative; display: inline-block;
}
.nav-toggle .bars::before,
.nav-toggle .bars::after {
  content: ""; position: absolute; left: 0; width: 18px; height: 2px; background: #fff;
}
.nav-toggle .bars::before { top: -6px; }
.nav-toggle .bars::after { top: 6px; }

/* Nav list */
.site-nav { background: var(--blue-900); }
.nav-list {
  max-width: var(--wrap);
  margin: 0 auto;
  list-style: none;
  padding: 0;
  display: none;              /* collapsed on mobile until toggled */
  flex-direction: column;
}
.nav-list.open { display: flex; }
.nav-list li { border-top: 1px solid rgba(255,255,255,.08); }
.nav-list a {
  display: block;
  color: #e6eeff;
  padding: 6px 18px;
  font-weight: 600;
  text-decoration: none;
}
.nav-list a:hover { background: rgba(255,255,255,.08); text-decoration: none; }
.nav-list a[aria-current="page"] {
  color: var(--teal-300);   /* active page = teal text, no bar */
}
/* Menu items in Bebas (display face). Single-weight all-caps → pin 400, add tracking + a size bump. */
.nav-list a, .nav-dd-toggle {
  font-family: var(--font-head);
  font-weight: 400;
  letter-spacing: 1pt;
  font-size: 1.12rem;
}

@media (min-width: 860px) {
  .nav-toggle { display: none; }
  .nav-list {
    display: flex !important;
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    max-width: none;      /* not capped at content width, so all items fit one line when wide */
    padding: 0 16px;
  }
  .nav-list li { border-top: none; }
  .nav-list a { padding: 6px 12px; white-space: nowrap; }
}

/* ---- "Meets" dropdown ---- */
.nav-dd-toggle {
  display: block;
  width: 100%;
  text-align: left;
  background: none;
  border: none;
  color: #e6eeff;
  /* font-family / weight / size / tracking come from the Bebas nav rule above */
  line-height: inherit;   /* match the anchor links' line-height so MEETS aligns vertically */
  padding: 7px 18px;
  cursor: pointer;
}
.nav-dd-toggle[data-active="1"] { color: var(--teal-300); }
.nav-dd-toggle .caret { font-size: .72em; opacity: .85; display: inline-block; transition: transform .15s ease; }
.has-dropdown.open > .nav-dd-toggle .caret { transform: rotate(180deg); }

.dropdown {
  list-style: none;
  margin: 0;
  padding: 4px 12px 8px;
  display: none;
  grid-template-columns: repeat(3, 1fr);
  gap: 2px;
  background: rgba(0, 0, 0, .18);
}
.has-dropdown.open > .dropdown { display: grid; }
.dropdown li { text-align: center; }   /* center the box within its cell */
.dropdown a {
  display: inline-block;        /* box hugs the year, symmetric padding = centered over it */
  color: #e6eeff;
  padding: 8px 14px;
  font-weight: 600;
  border-radius: 8px;
  text-decoration: none;
}
.dropdown a:hover { background: rgba(255, 255, 255, .12); color: #fff; text-decoration: none; }
.dropdown a[aria-current="page"] { color: var(--teal-300); background: rgba(255, 255, 255, .14); }

@media (min-width: 860px) {
  .has-dropdown { position: relative; }
  .nav-dd-toggle { width: auto; padding: 6px 12px; white-space: nowrap; }
  .dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    padding: 10px;
    gap: 2px 4px;
    grid-template-columns: repeat(4, auto);
    background: var(--blue-900);
    border-radius: 0 0 12px 12px;
    box-shadow: var(--shadow-lg);
    z-index: 120;
  }
  .has-dropdown:hover > .dropdown,
  .has-dropdown:focus-within > .dropdown,
  .has-dropdown.open > .dropdown { display: grid; }
  .dropdown a { padding: 7px 16px; }
}

/* ============================================================
   Layout
   ============================================================ */
main { max-width: var(--wrap); margin: 0 auto; padding: 12px 12px 22px; }

.page-title {
  text-align: center;
  margin: 13px 0 10px;   /* ~8px extra breathing room above the main heading */
}
.page-title .eyebrow {
  display: inline-block;
  background: var(--teal-100);
  color: var(--blue-900);
  font-weight: 700;
  font-size: .75rem;
  letter-spacing: .08em;
  text-transform: uppercase;
  padding: 4px 12px;
  border-radius: 999px;
  margin-bottom: 10px;
}

/* Single-column readable content card (About, Officiating, Board, etc.) */
.prose {
  max-width: 720px;
  margin: 0 auto;
  background: var(--white);
  border: 1px solid var(--line);
  border-top: 4px solid var(--teal-500);   /* teal highlight on top, like the pool cards */
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 20px 26px;
}
.prose > :first-child { margin-top: 0; }
.prose h2 { margin: 1.1em 0 .3em; }
.prose p { color: var(--ink-soft); }
.prose address { font-style: normal; color: var(--ink); line-height: 1.7; }
.prose h2 { color: var(--blue-900); font-size: 1.3rem; }
.prose h3 { color: var(--blue-700); margin: 1em 0 .2em; }
.prose .year { font-weight: 800; color: var(--blue-900); margin: .9em 0 .2em; }
.prose ul { padding-left: 1.2em; }
.prose .table-wrap { overflow-x: auto; }
.prose table { width: 100%; border-collapse: separate; border-spacing: 0; margin: 10px 0; background: #fff; border-radius: var(--radius-sm); overflow: hidden; }
.prose th, .prose td { padding: 8px 11px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.prose thead th {
  background: #f8fafc;
  color: var(--blue-900);
  font-weight: 700;
  font-size: .75rem;
  letter-spacing: .08em;
  text-transform: uppercase;
  border-top: 4px solid var(--teal-500);
  border-bottom: 3px solid var(--teal-500);
}
.prose thead th:first-child { border-top-left-radius: var(--radius-sm); }
.prose thead th:last-child { border-top-right-radius: var(--radius-sm); }
.prose tbody tr:nth-child(even) { background: #f8fafc; }
.prose blockquote { margin: 8px 0 8px 6px; padding: 2px 0 2px 14px; border-left: 3px solid var(--teal-300); }
.prose--wide { max-width: 940px; }
/* Documents page: every table identical — same width, columns, and centered headers */
.doc-table { table-layout: fixed; }
.doc-table thead th { text-align: center; }
.doc-table th:nth-child(1), .doc-table td:nth-child(1) { width: 46%; }
.doc-table th:nth-child(2), .doc-table td:nth-child(2) { width: 34%; }
.doc-table th:nth-child(3), .doc-table td:nth-child(3) { width: 20%; }
.prose td.date { text-align: center; white-space: nowrap; color: var(--ink-soft); font-size: .85rem; }
.prose .subhead-row td { background: var(--blue-100); font-weight: 700; color: var(--blue-900); }
/* Documents page: one uniform type size across every column, header, date, and sub-heading row (~10pt) */
.doc-table td, .doc-table th,
.doc-table thead th, .doc-table td.date, .doc-table .subhead-row td { font-size: .83rem; }

/* Archive / Records page — legacy record content, re-skinned into a uniform layout */
.archive h2 { text-align: center; margin: 1.5em 0 .4em; }
.archive p { color: var(--ink); }
.archive .results { font-size: .85rem; color: var(--ink-soft); }

/* Every record row identical: fixed table + column widths. Photo frame hugs each photo's own size. */
.archive table {
  width: 100%;
  max-width: 850px;
  margin: 14px auto;
  table-layout: fixed;              /* all tables & columns share the same widths */
  border-collapse: separate;
  border-spacing: 12px;
}
.archive table tr:nth-child(even) { background: transparent; }  /* override .prose's generic row striping — the record cards have their own background */
.archive td { vertical-align: middle; padding: 0; }
.archive td:first-child { width: 210px; text-align: center; }   /* image column (uniform) */
/* Photos scale to fit within this box (whichever dimension is the tighter fit), keeping their
   own aspect ratio — the frame sits directly on the image, so there's never a blank margin
   inside it the way a fixed-size box would leave for a non-matching photo. */
.archive td:first-child img,
.archive .imageborder {
  width: auto;
  height: auto;
  max-width: 186px;
  max-height: 140px;
  border: 3px solid var(--teal-500);
  border-radius: 8px;
  box-shadow: 0 4px 8px rgba(6, 20, 55, .40);   /* matches the home-page image shadow weight */
}
.archive .rec-cell {                 /* details cell — uniform formatting */
  background: var(--teal-100);
  color: var(--blue-900);
  border-radius: 10px;
  padding: 12px 16px;
  text-align: center;
  box-shadow: 0 4px 8px rgba(6, 20, 55, .40);   /* matches the home-page image shadow weight */
}
.archive .rec-cell p { margin: 3px 0; }
.archive .rec-cell .results { color: var(--ink); }

@media (max-width: 560px) {
  .archive table, .archive tbody, .archive tr, .archive td { display: block; width: auto !important; }
  .archive td:first-child { margin: 0 auto 8px; }
}

/* Member-pools card grid */
.pool-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}
@media (min-width: 620px) { .pool-grid { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1000px) { .pool-grid { grid-template-columns: 1fr 1fr 1fr; } }
.pool-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-top: 4px solid var(--teal-500);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow);
  padding: 13px 15px;
}
.pool-card h2 { font-size: 1.05rem; margin: 0 0 2px; }
.pool-card h2 .abbr-inline { color: var(--teal-500); }
.pool-card .specs { font-size: .8rem; color: var(--ink-soft); margin: 0 0 8px; }
.pool-card address { font-style: normal; font-size: .9rem; color: var(--ink); line-height: 1.5; }
.pool-links { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.pool-links a {
  font-size: .78rem; font-weight: 700; text-decoration: none;
  padding: 4px 11px; border-radius: 999px; background: var(--teal-100); color: var(--blue-900);
}
.pool-links a.map { background: var(--blue-100); }
.pool-links a:hover { filter: brightness(.96); text-decoration: none; }

/* Photo gallery grid (e.g. images2005city.php) */
.photo-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin: 20px 0;
}
@media (min-width: 620px) { .photo-grid { grid-template-columns: 1fr 1fr 1fr; } }
.photo-card { text-align: center; }
.photo-card a { display: inline-block; }
.photo-card img {
  max-width: 100%;
  border: 3px solid var(--teal-500);
  border-radius: var(--radius-sm);
  box-shadow: 0 4px 8px rgba(6, 20, 55, .40);   /* matches the home-page image shadow weight */
}
.photo-card p { margin: 6px 0 0; font-size: .85rem; color: var(--ink); }
.photo-card strong { color: var(--blue-900); }

/* Two-column card grid that stacks on mobile */
.grid-2 {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}
@media (min-width: 820px) {
  .grid-2 { grid-template-columns: 1fr 1fr; }
}
/* Swap the panels: News on the left, Important Info on the right (also stacks News-first on mobile) */
.grid-2 .card--accent { order: 1; }

.card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 15px 18px;
}
.card h2 { text-align: center; }
.card--accent { border-top: 5px solid var(--teal-500); }
.card--news   { border-top: 5px solid var(--teal-500); }
.card p { color: var(--ink-soft); }
.card .subhead {
  text-align: center;
  color: var(--blue-900);   /* match the darker blue used by the other headings/text */
  margin-top: 10px;
}

/* Info rows (dates etc.) */
.info-block { text-align: center; margin: 3px 0 8px; }
.info-block strong { color: var(--blue-900); display: block; }

/* Buttons */
.btn {
  display: inline-block;
  background: var(--blue-600);
  color: #fff !important;
  font-weight: 700;
  padding: 11px 20px;
  border-radius: 999px;
  text-decoration: none !important;
  transition: transform .08s ease, background .15s ease;
}
.btn:hover { background: var(--blue-700); transform: translateY(-1px); }
.btn--ghost {
  background: #fff;
  color: var(--blue-700) !important;
  border: 2px solid var(--blue-600);
}
.btn-center { text-align: center; margin: 8px 0; }

/* Results score list */
.scorelist { list-style: none; padding: 0; margin: 5px 0; font-size: .82rem; }
.scorelist li {
  display: flex;
  justify-content: space-between;
  padding: 2px 10px;
  font-variant-numeric: tabular-nums;
}
.scorelist li:nth-child(even) { background: #f8fafc; }   /* subtle alternating rows, like the results table */
.scorelist .rank { font-weight: 700; color: var(--blue-900); }
.scorelist .pts { font-weight: 700; color: var(--ink); }

/* ============================================================
   Raw meet-results viewer (viewer.php) — a Hy-Tek Meet Manager
   export, shown as-is inside the normal page shell instead of opening bare.
   ============================================================ */
.results-raw {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  background: var(--white);
  border: 3px solid var(--teal-500);   /* same frame as the photo-card / results-image frame */
  border-radius: var(--radius-sm);
  box-shadow: 0 4px 8px rgba(6, 20, 55, .40);   /* matches the home-page image shadow weight */
  padding: 16px;
  margin: 14px auto;      /* center the box itself on the page */
  width: max-content;     /* hug the report's natural width instead of stretching full-width */
  max-width: 100%;        /* but never wider than the viewport — overflow-x above handles the rest */
}
.results-raw pre {
  margin: 0;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: .82rem;
  line-height: 1.4;
  color: var(--ink);
  white-space: pre;
}
.results-pdf {
  margin: 14px auto;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  overflow: hidden;         /* keeps the iframe's corners inside the rounded border */
}
.results-pdf iframe {
  display: block;
  width: 100%;
  height: 88vh;
  min-height: 650px;
  border: 0;
}
.results-image { margin: 14px 0; }
.results-image img {
  max-width: 100%;
  margin: 0 auto;   /* base img{display:block} means text-align can't center it — margin auto does */
  border: 3px solid var(--teal-500);
  border-radius: var(--radius-sm);
  box-shadow: 0 4px 8px rgba(6, 20, 55, .40);   /* matches the home-page image shadow weight */
}

/* ============================================================
   Results table (meets page) - responsive
   ============================================================ */
.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.results-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  background: #fff;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}
.results-table th, .results-table td {
  padding: 7px 11px;
  text-align: left;
  border-bottom: 1px solid var(--line);
}
.results-table thead th {
  background: #f8fafc;
  color: var(--blue-900);
  font-weight: 700;
  font-size: .75rem;
  text-transform: uppercase;
  letter-spacing: .08em;
  border-top: 4px solid var(--teal-500);
  border-bottom: 3px solid var(--teal-500);
}
.results-table thead th:first-child { border-top-left-radius: var(--radius-sm); }
.results-table thead th:last-child { border-top-right-radius: var(--radius-sm); }
.results-table tbody tr:nth-child(even) { background: #f8fafc; }
.results-table .col-links { text-align: center; white-space: nowrap; }
/* Desktop: fix the column widths so every results table lines up identically —
   the Results column sits at the same spot on the City Meet, Sanctioned, etc.
   tables regardless of how wide the item/meet names are. (Mobile stacks below.) */
@media (min-width: 601px) {
  .results-table { table-layout: fixed; }
  .results-table th:nth-child(2),
  .results-table td:nth-child(2) { width: 220px; text-align: center; }
}
.result-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 700;
  font-size: .85rem;
  padding: 5px 12px;
  border-radius: 999px;
  margin: 2px;
}
.result-link.html { background: var(--teal-100); color: var(--blue-900); }
.result-link.pdf  { background: #fde2e2; color: #9b1c1c; }
.result-link.none { color: #94a3b8; font-weight: 500; }

/* On small screens, let the results table become card-like */
@media (max-width: 600px) {
  .results-table thead { display: none; }
  .results-table, .results-table tbody, .results-table tr, .results-table td { display: block; width: 100%; }
  .results-table tr {
    margin-bottom: 14px;
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow);
    background: #fff;
  }
  .results-table td { border-bottom: 1px solid var(--line); }
  .results-table td.col-item { font-weight: 700; color: var(--blue-900); background: #f0f5ff; }
  .results-table td.col-item[data-label]::before { display: none; }  /* title is self-evident */
  .results-table td.col-links[data-label]::before { display: none; } /* chips already say HTML/PDF */
  .results-table td.col-links { padding-top: 10px; padding-bottom: 12px; }
  .results-table td[data-label]::before {
    content: attr(data-label);
    display: block;
    font-size: .7rem;
    text-transform: uppercase;
    letter-spacing: .05em;
    color: var(--ink-soft);
    margin-bottom: 2px;
  }
}

/* ---- Section jump-nav (sticky chips) ---- */
.jump-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: center;
  margin: 0 0 14px;
}
.jump-nav a, .link-chip {
  display: inline-block;
  background: #fff;
  border: 1px solid var(--line);
  color: var(--blue-600);   /* matches the home-page link blue */
  font-weight: 700;
  font-size: .85rem;
  padding: 7px 14px;
  border-radius: 999px;
  text-decoration: none;
}
.jump-nav a:hover, .link-chip:hover { background: var(--blue-600); color: #fff; text-decoration: none; }

/* ---- Forms (e.g. feedback.php) ---- */
.rcsl-form { max-width: 480px; margin: 18px auto; }
.form-row { margin-bottom: 16px; display: flex; flex-direction: column; }
.form-row label { font-weight: 700; color: var(--blue-900); margin-bottom: 5px; font-size: .9rem; }
.form-row input[type="text"],
.form-row input[type="email"],
.form-row textarea {
  font: inherit;
  font-size: .95rem;
  padding: 9px 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  color: var(--ink);
  background: var(--white);
}
.form-row input[type="text"]:focus,
.form-row input[type="email"]:focus,
.form-row textarea:focus {
  outline: 2px solid var(--teal-500);
  outline-offset: 1px;
}
.form-row textarea { resize: vertical; min-height: 110px; }
.form-error { color: #b91c1c; font-size: .82rem; margin-top: 4px; }
.form-success {
  background: var(--teal-100); color: var(--blue-900); font-weight: 700;
  padding: 12px 16px; border-radius: var(--radius-sm); border-left: 4px solid var(--teal-500);
}
.btn-submit {
  font: inherit; font-weight: 700; font-size: .95rem; cursor: pointer;
  background: var(--teal-500); color: #fff; border: none;
  padding: 10px 22px; border-radius: 999px;
}
.btn-submit:hover { background: var(--blue-700); }
/* Honeypot field: invisible and unreachable to real visitors, still present for bots. */
.form-hp {
  position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden;
}

/* ---- Section heading ---- */
.section-head {
  text-align: center;
  margin: 18px 0 3px;
  scroll-margin-top: 92px;   /* so sticky header doesn't cover anchor target */
}
.section-sub { text-align: center; color: var(--ink-soft); margin: 0 0 10px; }

/* ---- Result chips (shared) ---- */
.res-chips { display: inline-flex; gap: 4px; flex-wrap: wrap; justify-content: center; }
.chip {
  display: inline-flex; align-items: center; gap: 3px;
  font-weight: 700; font-size: .66rem;
  padding: 3px 7px; border-radius: 999px; text-decoration: none;
}
.chip.html { background: var(--teal-100); color: var(--blue-900); }
.chip.pdf  { background: #fde2e2; color: #9b1c1c; }
.chip.html:hover, .chip.pdf:hover { text-decoration: none; filter: brightness(.96); }
.chip-none { color: #b6c0cf; font-size: .8rem; }
/* Larger chip for standalone calls-to-action (e.g. home page "Team Results (PDF)") */
.chip--lg { font-size: .72rem; padding: 7px 15px; gap: 5px; }

/* ---- Dual-meet matchup cards ---- */
.week-block { margin: 10px 0 4px; text-align: center; }
.week-label {
  font-weight: 800;
  color: var(--blue-900);
  background: var(--blue-100);
  display: inline-block;
  padding: 3px 12px;
  border-radius: 999px;
  font-size: .85rem;
  margin-bottom: 7px;
}
.matchup-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
}
@media (min-width: 720px) { .matchup-grid { grid-template-columns: 1fr 1fr 1fr; } }

.matchup {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow);
  padding: 8px 10px 7px;
  text-align: center;
}
.matchup.bye { opacity: .55; }
.matchup .teams {
  display: flex; align-items: stretch; justify-content: center; gap: 8px;
  margin-bottom: 6px;
}
.matchup .team { flex: 1; }
.matchup .team .abbr { font-weight: 800; color: var(--blue-900); font-size: 1.05rem; }
.matchup .team .score { display: block; font-variant-numeric: tabular-nums; color: var(--ink-soft); font-weight: 700; }
.matchup .team.win .abbr { color: var(--blue-900); }  /* both names blue; trophy marks the winner */
.matchup .team.win .score::after { content: " 🏆"; }
.matchup .vs { align-self: center; color: #94a3b8; font-weight: 700; font-size: .8rem; }
.matchup .cancel { color: #9b1c1c; font-weight: 700; font-size: .85rem; }

/* ---- Home page media (shirts, live stream, meet mobile, candids) ---- */
.home-media { text-align: center; margin: 8px 0 4px; }
.home-media img {
  display: inline-block;
  width: 222px;          /* all home images share the shirt image's width */
  max-width: 100%;
  height: auto;
  border: 3px solid var(--teal-500);   /* same frame as the photo-card / records / results-viewer images */
  border-radius: var(--radius-sm);
  box-shadow: 0 4px 8px rgba(6, 20, 55, .40);   /* matches the logo/IAB shadow weight */
}
/* Transparent cutout art (e.g. the "It's a BLAST!" rocket): no border/box — shadow follows the
   artwork's alpha shape instead of a rectangular box, honoring the transparency. */
.home-media--cutout img {
  border: none;
  border-radius: 0;
  box-shadow: none;
  filter: drop-shadow(0 4px 8px rgba(6, 20, 55, .32));   /* tuned to match the box-shadow images' weight */
}
.home-media a { display: inline-block; }
.img-caption {
  text-align: center;
  color: var(--ink-soft);
  font-size: .82rem;
  font-style: italic;
  margin: 4px 0 10px;
}

/* Sponsor strip */
.sponsors {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  justify-content: center;
  align-items: center;
  margin: 22px auto 0;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}
.sponsors figure { margin: 0; text-align: center; max-width: 160px; }
.sponsors img { border-radius: var(--radius-sm); box-shadow: 0 4px 8px rgba(6, 20, 55, .40); }
.sponsors figcaption {
  font-size: .7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .05em;
  color: var(--ink-soft);
  margin-bottom: 8px;
}
.sponsors img { margin: 0 auto; }

/* ============================================================
   Footer
   ============================================================ */
.site-footer {
  background: var(--blue-900);
  color: #c7d5f5;
  text-align: center;
  padding: 16px 18px 20px;
  font-size: .85rem;
  margin-top: 22px;
}
.site-footer a { color: #fff; text-decoration: underline; }
.site-footer .foot-credit { font-size: .72rem; color: #8ea3d6; margin-top: 10px; }
