/* ============================================================
   Pickleball Aware — design system
   Grounded in the sport itself: court lines, the kitchen line,
   camera-framing marks used to check court coverage. The signature
   corner-bracket motif on cards is a direct reference to framing
   marks and court-boundary registration, not a decorative default.
   ============================================================ */

:root {
  --ink: #12181A;
  --court-blue: #24506B;
  --court-blue-dark: #1A3B50;
  --clay: #B8563A;
  --chalk: #F7F5F0;
  --paper: #FFFFFF;
  --line: #DEDAD0;
  --muted: #63666A;

  --display: "Space Grotesk", "Arial Narrow", sans-serif;
  --body: "IBM Plex Sans", "Segoe UI", sans-serif;

  /* A real spacing scale -- previously every value in this file was
     hand-picked ad hoc (14px, 20px, 22px, 24px, 40px, 48px...) with
     no consistent rhythm tying them together. 4px base unit. */
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 24px;
  --space-6: 32px;
  --space-7: 48px;
  --space-8: 64px;
  --space-9: 96px;
}

* { box-sizing: border-box; }

html { -webkit-font-smoothing: antialiased; }

body {
  margin: 0;
  background: var(--chalk);
  color: var(--ink);
  font-family: var(--body);
  font-size: 16px;
  line-height: 1.55;
}

h1, h2, h3 {
  font-family: var(--display);
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--ink);
  margin: 0 0 0.5em;
}

h1 { font-size: 2.25rem; letter-spacing: -0.02em; }
h2 {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--court-blue);
  font-weight: 600;
  border-bottom: 1px solid var(--line);
  padding-bottom: 0.6em;
}

/* A key number deserves to look like one -- session counts, sample
   counts, peak rotation readings. Previously every number on this
   site rendered in plain body text, indistinguishable from a
   sentence around it, even where the number IS the actual point. */
.stat {
  font-family: var(--display);
  font-weight: 700;
  color: var(--ink);
  letter-spacing: -0.01em;
  line-height: 1;
}
.stat-lg { font-size: 2.25rem; }
.stat-md { font-size: 1.5rem; }
.stat-label {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  font-weight: 600;
  margin-top: 2px;
}

a { color: var(--court-blue); }
a:hover { color: var(--court-blue-dark); }

p.lede {
  color: var(--muted);
  font-size: 1.05rem;
  max-width: 46ch;
}

/* ---- layout shell ---- */

.shell {
  max-width: 720px;
  margin: 0 auto;
  padding: 0 var(--space-5) var(--space-8);
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 24px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 8px;
}

.wordmark {
  font-family: var(--display);
  font-weight: 700;
  font-size: 1.15rem;
  letter-spacing: 0.02em;
  color: var(--ink);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 8px;
}

.wordmark .dot {
  width: 9px;
  height: 9px;
  background: var(--clay);
  border-radius: 1px;
  display: inline-block;
  transform: rotate(45deg);
}

.site-header nav a {
  font-size: 0.85rem;
  color: var(--muted);
  text-decoration: none;
  font-weight: 500;
}
.site-header nav a:hover { color: var(--ink); }

/* ---- hero (landing) ---- */

.hero {
  background: var(--ink);
  color: var(--chalk);
  padding: 72px 24px 88px;
  margin-bottom: 48px;
  position: relative;
  overflow: hidden;
}

.hero::before {
  /* a single faint court-line arc, evoking the kitchen line without
     illustrating a literal court diagram */
  content: "";
  position: absolute;
  right: -120px;
  top: -120px;
  width: 420px;
  height: 420px;
  border: 1px solid rgba(247, 245, 240, 0.09);
  border-radius: 50%;
}

.hero-inner { max-width: 720px; margin: 0 auto; position: relative; }

.eyebrow {
  font-family: var(--display);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: #8FB3C7;
  margin-bottom: 18px;
}

.hero h1 {
  color: var(--paper);
  font-size: 2.75rem;
  max-width: 14ch;
  margin-bottom: 20px;
}

.hero p.lede { color: #C9CDCE; max-width: 42ch; }

.hero-cta { margin-top: 32px; display: flex; gap: 14px; align-items: center; }

/* ---- signature: corner-bracket framing on cards ---- */

.card {
  position: relative;
  background: var(--paper);
  border: 1px solid var(--line);
  padding: 20px 22px;
  margin-bottom: var(--space-3);
  transition: border-color 0.15s ease, transform 0.15s ease;
}

.card::before, .card::after {
  content: "";
  position: absolute;
  width: 14px;
  height: 14px;
  border-color: var(--clay);
  border-style: solid;
  border-width: 0;
  transition: width 0.15s ease, height 0.15s ease;
}
.card::before { top: -1px; left: -1px; border-top-width: 2px; border-left-width: 2px; }
.card::after  { bottom: -1px; right: -1px; border-bottom-width: 2px; border-right-width: 2px; }

/* On hover, the framing brackets grow -- like a camera reticle
   tightening focus -- rather than a generic shadow/lift, keeping the
   court-framing metaphor consistent instead of reaching for a
   default hover treatment. */
.card:hover {
  border-color: var(--court-blue);
}
.card:hover::before,
.card:hover::after {
  width: 20px;
  height: 20px;
}

.card a.card-link {
  text-decoration: none;
  color: var(--ink);
  font-weight: 600;
  display: block;
}
.card a.card-link:focus-visible {
  outline: 2px solid var(--court-blue);
  outline-offset: 3px;
}
.card .meta { color: var(--muted); font-size: 0.9rem; margin-top: 2px; }

/* ---- buttons + forms ---- */

.btn {
  display: inline-block;
  font-family: var(--body);
  font-weight: 600;
  font-size: 0.9rem;
  padding: 11px 20px;
  border-radius: 3px;
  border: 1px solid transparent;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.15s ease, border-color 0.15s ease;
}

.btn-primary { background: var(--clay); color: var(--paper); }
.btn-primary:hover { background: #9C4A31; }

.btn-ghost {
  background: transparent;
  color: var(--chalk);
  border-color: rgba(247, 245, 240, 0.35);
}
.btn-ghost:hover { border-color: var(--chalk); }

.btn-secondary {
  background: var(--paper);
  color: var(--ink);
  border-color: var(--line);
}
.btn-secondary:hover { border-color: var(--court-blue); color: var(--court-blue); }

.btn:focus-visible {
  outline: 2px solid var(--court-blue);
  outline-offset: 2px;
}

form.stack { display: flex; flex-direction: column; gap: 16px; margin: 20px 0; }

label {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--muted);
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

input[type="text"], input[type="email"], input[type="date"], input[type="password"], input[type="time"], select {
  font-family: var(--body);
  font-size: 1rem;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 3px;
  background: var(--paper);
  color: var(--ink);
  width: 100%;
  max-width: 320px;
}
input[type="text"]:focus, input[type="email"]:focus, input[type="date"]:focus, input[type="password"]:focus, input[type="time"]:focus, select:focus {
  outline: 2px solid var(--court-blue);
  outline-offset: 1px;
}

/* Never styled before this -- every textarea in the app (including
   the coach's session-recap notes) was rendering with raw browser
   defaults: narrow, wrong font, cramped for actually writing in.
   Deliberately NOT capped at the same 320px max-width as short text
   inputs above -- a recap or log entry is meant to hold real
   sentences, not a short value, so it gets the full width of
   whatever container it's in instead. */
textarea {
  font-family: var(--body);
  font-size: 1rem;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 3px;
  background: var(--paper);
  color: var(--ink);
  width: 100%;
  min-height: 90px;
  resize: vertical;
}
textarea:focus {
  outline: 2px solid var(--court-blue);
  outline-offset: 1px;
}

.check-row { display: flex; align-items: center; gap: 8px; }
.check-row label { margin: 0; text-transform: none; letter-spacing: normal; font-weight: 500; color: var(--ink); }

.inline-form { display: flex; gap: 10px; align-items: flex-end; flex-wrap: wrap; margin: 16px 0 24px; }

.section { margin-bottom: var(--space-7); }

.empty-state {
  color: var(--muted);
  font-style: italic;
  padding: 18px 0;
}

.hairline { border: none; border-top: 1px solid var(--line); margin: 40px 0; }

.list-plain { list-style: none; padding: 0; margin: 0 0 20px; }

.phone-row { display: flex; gap: 8px; }

/* First real breakpoint this system has needed -- everything else
   held up fluidly without one. Two genuine mobile problems found by
   actually testing at 375px width: the wordmark wrapping awkwardly,
   and the country-code select truncating its own text once squeezed
   next to the phone input. */
@media (max-width: 480px) {
  .wordmark { font-size: 1rem; }
  .site-header { flex-wrap: wrap; row-gap: 8px; }
  .phone-row { flex-direction: column; }
  .phone-row select { max-width: none; }
}
