/* Coach Hub - combined app's own small shared shell (login + launcher only).
   Deliberately its own tiny stylesheet rather than pulling in either
   product's full base.css - this is the one surface that's neither
   Goalkeeper Coach (orange) nor Team Coach (blue), so it gets its own
   neutral "parent brand" indigo instead of borrowing either sub-product's
   accent. */
:root {
  --bg: #f7f7fb;
  --panel: #ffffff;
  --border: #e2e1ec;
  --text: #1c1b29;
  --text-muted: #55536b;
  --text-faint: #8b899e;
  --accent: #4f46e5;
  --accent-hover: #4338ca;
  --accent-bg: #eeecfd;
  --danger: #b3261e;
  --danger-bg: #fbe9e7;
  --success: #0d9488;
  --success-bg: #e6f6f4;
  --radius: 10px;
  --radius-lg: 16px;
  --shadow-lg: 0 12px 32px -8px rgba(28, 27, 41, 0.18);
}
/* Three states, not two - see either product app's own base.css comment on
   this exact pattern: 'system' (default) follows the OS via the media query
   below; an explicit 'dark'/'light' choice (same esfc.a11y.prefs blob,
   readable here even before signing in - same origin, same localStorage)
   applies html.a11y-dark/a11y-light and always wins over the OS. */
@media (prefers-color-scheme: dark) {
  html:not(.a11y-light) {
    --bg: #14131c;
    --panel: #1d1c29;
    --border: #302f42;
    --text: #f1f0f7;
    --text-muted: #b6b4c8;
    --text-faint: #85839b;
    --accent: #7c72f0;
    --accent-hover: #8f86f4;
    --accent-bg: #262246;
    --danger: #f2837c;
    --danger-bg: #3a2320;
    --success: #5ecdc0;
    --success-bg: #163330;
  }
}
html.a11y-dark {
  --bg: #14131c;
  --panel: #1d1c29;
  --border: #302f42;
  --text: #f1f0f7;
  --text-muted: #b6b4c8;
  --text-faint: #85839b;
  --accent: #7c72f0;
  --accent-hover: #8f86f4;
  --accent-bg: #262246;
  --danger: #f2837c;
  --danger-bg: #3a2320;
  --success: #5ecdc0;
  --success-bg: #163330;
}

* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
}

.shell {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: radial-gradient(560px 380px at 50% -8%, var(--accent-bg), transparent), var(--bg);
}

.card {
  width: 100%;
  max-width: 400px;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  padding: 36px 32px 32px;
}

.brand { display: flex; flex-direction: column; align-items: center; text-align: center; margin-bottom: 28px; }
.brand-mark {
  width: 52px; height: 52px; border-radius: 14px;
  background: linear-gradient(155deg, var(--accent), var(--accent-hover));
  color: #fff; display: flex; align-items: center; justify-content: center;
  font-size: 18px; font-weight: 800; letter-spacing: -0.02em;
  box-shadow: 0 6px 16px rgba(79, 70, 229, 0.35);
  margin-bottom: 14px;
}
.brand h1 { margin: 0; font-size: 20px; font-weight: 700; letter-spacing: -0.015em; }
.brand .sub { margin-top: 3px; font-size: 11.5px; font-weight: 600; color: var(--text-faint); text-transform: uppercase; letter-spacing: 0.06em; }

.field { margin-bottom: 16px; }
.field label { display: block; font-size: 13px; font-weight: 600; margin-bottom: 5px; color: var(--text-muted); }
.field input {
  width: 100%; padding: 9px 12px; font-size: 14.5px;
  border: 1px solid var(--border); border-radius: var(--radius);
  background: var(--panel); color: var(--text);
}
.field input:focus { outline: 2px solid var(--accent); outline-offset: 1px; }

.error-box {
  background: var(--danger-bg); color: var(--danger); border-radius: var(--radius);
  padding: 9px 12px; font-size: 13px; font-weight: 500; margin-bottom: 16px;
}
.success-box {
  background: var(--success-bg); color: var(--success); border-radius: var(--radius);
  padding: 9px 12px; font-size: 13px; font-weight: 500; margin-bottom: 16px;
}

button.primary {
  width: 100%; padding: 10px 15px; font-size: 14.5px; font-weight: 600;
  border: none; border-radius: var(--radius); background: var(--accent); color: #fff; cursor: pointer;
}
button.primary:hover { background: var(--accent-hover); }
button.primary:disabled { opacity: 0.65; cursor: default; }

.link-row { text-align: center; margin-top: 14px; font-size: 13px; }
.link-row a { color: var(--accent); text-decoration: none; }
.link-row a:hover { text-decoration: underline; }

/* A separated footer strip, not just another line in .link-row - signing up
   is a different action from signing in (new account vs existing one), so it
   gets its own visual weight: a divider above it, and the link itself styled
   like a small secondary button rather than plain text. */
.signup-cta {
  margin-top: 24px; padding-top: 18px; border-top: 1px solid var(--border);
  display: flex; align-items: center; justify-content: center; gap: 8px;
  font-size: 13px; color: var(--text-muted);
}
.signup-cta a {
  color: var(--accent); font-weight: 700; text-decoration: none;
}
.signup-cta a:hover { text-decoration: underline; }

/* Launcher (post-login, both-entitlements picker) */
.launcher-choices { display: flex; flex-direction: column; gap: 12px; margin-top: 8px; }
.launcher-choice {
  display: flex; align-items: center; gap: 14px; padding: 16px 18px;
  border: 1px solid var(--border); border-radius: var(--radius-lg);
  background: var(--panel); text-decoration: none; color: var(--text);
  transition: border-color 120ms, transform 120ms;
}
.launcher-choice:hover { border-color: var(--accent); transform: translateY(-1px); }
.launcher-choice .icon {
  width: 44px; height: 44px; border-radius: 12px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center; font-size: 20px; font-weight: 800; color: #fff;
}
.launcher-choice.gk .icon { background: linear-gradient(155deg, #ea580c, #c2410c); }
.launcher-choice.players .icon { background: linear-gradient(155deg, #2563eb, #1d4ed8); }
.launcher-choice .label { font-weight: 700; font-size: 15px; }
.launcher-choice .desc { font-size: 12.5px; color: var(--text-faint); margin-top: 2px; }

@media (max-width: 420px) {
  .card { padding: 30px 24px 26px; }
}

/* Wider admin/signup pages - subscription-plans.html, signup.html,
   onboarding.html all extend this same shared shell rather than pulling in
   either product's own app-shell/sidebar (this surface is neither product). */
.card.wide { max-width: 880px; text-align: left; }
.card.wide .brand { align-items: flex-start; text-align: left; }

table.admin-table { width: 100%; border-collapse: collapse; font-size: 13.5px; margin-top: 4px; }
table.admin-table th, table.admin-table td { padding: 9px 10px; text-align: left; border-bottom: 1px solid var(--border); }
table.admin-table thead th { font-size: 11.5px; text-transform: uppercase; letter-spacing: 0.03em; color: var(--text-faint); font-weight: 700; }
table.admin-table input[type="number"] { width: 90px; padding: 5px 8px; border: 1px solid var(--border); border-radius: 6px; background: var(--panel); color: var(--text); font-size: 13px; }
table.admin-table input[type="checkbox"] { width: 17px; height: 17px; cursor: pointer; }
.admin-section { margin-top: 34px; }
.admin-section h2 { font-size: 15px; margin: 0 0 4px; }
.admin-section .hint { font-size: 12.5px; color: var(--text-faint); margin: 0 0 12px; }
button.small { padding: 5px 12px; font-size: 12.5px; font-weight: 600; border: 1px solid var(--border); border-radius: 7px; background: var(--panel); color: var(--text); cursor: pointer; }
button.small:hover { border-color: var(--accent); color: var(--accent); }
button.small.primary { background: var(--accent); color: #fff; border-color: var(--accent); }
button.small.primary:hover { background: var(--accent-hover); }
.tag { display: inline-block; font-size: 11px; font-weight: 700; padding: 2px 8px; border-radius: 999px; background: var(--success-bg); color: var(--success); }
.tag.muted { background: var(--accent-bg); color: var(--text-faint); }

/* Signup - tier + plan-type picker */
.plantype-toggle { display: flex; gap: 8px; margin-bottom: 18px; }
.plantype-toggle button { flex: 1; padding: 10px; border: 1.5px solid var(--border); border-radius: var(--radius); background: var(--panel); color: var(--text-muted); font-weight: 700; font-size: 13.5px; cursor: pointer; }
.plantype-toggle button.active { border-color: var(--accent); color: var(--accent); background: var(--accent-bg); }
.tier-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.tier-card { border: 1.5px solid var(--border); border-radius: var(--radius-lg); padding: 16px; cursor: pointer; transition: border-color 120ms; }
.tier-card:hover { border-color: var(--accent); }
.tier-card.selected { border-color: var(--accent); background: var(--accent-bg); }
.tier-card .tier-name { font-weight: 800; font-size: 15px; }
.tier-card .tier-price { font-size: 20px; font-weight: 800; color: var(--accent); margin: 6px 0 2px; }
.tier-card .tier-price small { font-size: 11px; font-weight: 600; color: var(--text-faint); }
.tier-card ul { margin: 10px 0 0; padding-left: 16px; font-size: 12px; color: var(--text-muted); }
.tier-card li { margin-bottom: 3px; }
.seat-stepper { display: flex; align-items: center; gap: 10px; margin: 14px 0; }
.seat-stepper button { width: 30px; height: 30px; border-radius: 50%; border: 1px solid var(--border); background: var(--panel); color: var(--text); font-size: 16px; cursor: pointer; }
.seat-stepper .count { font-weight: 700; font-size: 15px; min-width: 90px; text-align: center; }
.product-checks { display: flex; gap: 16px; margin: 14px 0; }
.product-checks label { display: flex; align-items: center; gap: 7px; font-size: 13.5px; cursor: pointer; }
.total-row { display: flex; justify-content: space-between; align-items: baseline; padding: 12px 0; border-top: 1px solid var(--border); margin-top: 14px; font-size: 14px; }
.total-row strong { font-size: 20px; }

/* Onboarding wizard - numbered steps */
.wizard-steps { display: flex; gap: 6px; margin-bottom: 22px; }
.wizard-steps .dot { flex: 1; height: 4px; border-radius: 2px; background: var(--border); }
.wizard-steps .dot.done, .wizard-steps .dot.active { background: var(--accent); }
.wizard-instructions { background: var(--accent-bg); border-radius: var(--radius); padding: 14px 16px; font-size: 13.5px; color: var(--text-muted); margin: 12px 0; }
.wizard-instructions ol { margin: 6px 0 0; padding-left: 20px; }
.wizard-instructions li { margin-bottom: 6px; }

@media (max-width: 720px) {
  .card.wide { padding: 24px 20px; }
  .tier-cards { grid-template-columns: 1fr; }
}
