/* OnDeck's colors: near-black, white and red, readable outdoors. */
:root {
  --bg: #f4f1ec;
  --surface: #ffffff;
  --ink: #111213;
  --muted: #55504a;
  --line: #bdb5aa;
  --red: #d20f1f;
  --on-red: #ffffff;
  --hero: #0a0b0c;
  --on-hero: #ffffff;
  --ok: #1b7a3a;
  --ok-bg: #e3f3e8;
  --warn-bg: #fdecea;
  --tonal: #dce3ec;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #121314;
    --surface: #1c1d1f;
    --ink: #f2f0ed;
    --muted: #b7b1aa;
    --line: #3f3c39;
    --red: #ff5a5f;
    --on-red: #1a0003;
    --hero: #000000;
    --ok: #7fd49b;
    --ok-bg: #16301f;
    --warn-bg: #3a1714;
    --tonal: #2a3340;
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 17px/1.45 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

.top {
  background: var(--hero);
  color: var(--on-hero);
  /* Lines up with the 560px content column on wide screens. */
  padding: 10px max(16px, calc((100% - 528px) / 2));
  display: flex;
  align-items: center;
  gap: 10px;
}
.logo { width: 40px; height: 40px; border-radius: 10px; display: block; }
.brand { font-weight: 800; letter-spacing: 0.02em; font-size: 1.05rem; }

/* The team, front and center, so parents know they're in the right place. */
.hero {
  background: var(--hero);
  color: var(--on-hero);
  padding: 4px max(16px, calc((100% - 528px) / 2)) 20px;
  border-bottom: 4px solid var(--red);
}
.hero[hidden] { display: none; }
.hero-kicker { margin: 0; font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.08em; opacity: 0.75; }
.hero-team { margin: 2px 0 0; font-size: 1.9rem; line-height: 1.1; font-weight: 800; }

main {
  max-width: 560px;
  margin: 0 auto;
  padding: 16px 16px 48px;
}

h1 { font-size: 1.5rem; line-height: 1.2; margin: 8px 0 12px; }
h2 { font-size: 1.1rem; margin: 24px 0 8px; }
p { margin: 8px 0; }
.muted { color: var(--muted); }
.small { font-size: 0.9rem; }

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 14px 16px;
  margin: 10px 0;
}

.song-title { font-weight: 600; }
.row { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 10px; }

button, .button {
  font: inherit;
  min-height: 48px;
  padding: 10px 18px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink);
  cursor: pointer;
}
button.primary { background: var(--red); border-color: var(--red); color: var(--on-red); font-weight: 600; }
button.tonal { background: var(--tonal); border-color: var(--tonal); }
button.link { background: none; border: none; color: var(--ink); text-decoration: underline; padding: 10px 4px; }
button:disabled { opacity: 0.5; cursor: default; }
button.block { width: 100%; }

.players { display: grid; gap: 8px; }
.player {
  display: flex;
  align-items: center;
  gap: 14px;
  text-align: left;
  width: 100%;
  border-radius: 14px;
  padding: 12px 16px;
}
.jersey {
  min-width: 44px;
  height: 44px;
  border-radius: 10px;
  background: var(--hero);
  color: var(--on-hero);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
}

label { display: block; font-weight: 600; margin: 16px 0 6px; }
input[type=text], input[type=url] {
  width: 100%;
  font: inherit;
  padding: 12px 14px;
  min-height: 48px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink);
}
input.time { width: 7em; }
.choice { display: flex; align-items: center; gap: 10px; font-weight: 400; margin: 10px 0; }
.choice input[type=radio], .choice input[type=checkbox] { width: 22px; height: 22px; accent-color: var(--red); }
.error { color: var(--red); font-weight: 600; }

.embed { width: 100%; height: 152px; border: 0; border-radius: 12px; margin-top: 12px; }

.status { border-radius: 12px; padding: 10px 14px; margin: 8px 0; }
.status.pending { background: var(--tonal); }
.status.applied { background: var(--ok-bg); }
.status.rejected, .status.undone { background: var(--warn-bg); }
.status.replaced { background: var(--surface); border: 1px solid var(--line); color: var(--muted); }
.status strong { display: block; }

/* A note at the top of a screen, e.g. "sign in first". */
.notice { background: var(--tonal); border-radius: 12px; padding: 10px 14px; }

/* Song cards: album art beside the title. */
.song { display: flex; gap: 14px; align-items: flex-start; }
.art {
  width: 64px;
  height: 64px;
  border-radius: 8px;
  flex: none;
  object-fit: cover;
  background: var(--line);
}
.song-text { min-width: 0; flex: 1; }

/* The send button stays in reach at the bottom of the screen on the song form. */
.send-bar {
  position: sticky;
  bottom: 0;
  margin: 16px -16px 0;
  padding: 12px 16px calc(12px + env(safe-area-inset-bottom));
  background: var(--bg);
  border-top: 1px solid var(--line);
}

.paste-row { display: flex; gap: 8px; }
.paste-row input { flex: 1; min-width: 0; }

.status .meta { display: block; margin-top: 4px; font-size: 0.8rem; opacity: 0.8; }
