/* BEEFY024 clip pool
   One accent (the stream's red), the logo's own pink for the header band,
   a warm off-white page, and nothing decorative beyond that. */

:root {
  --red: #961C1B;
  --red-dark: #7A1615;
  --brand-pink: #FFBBBA;   /* the logo's background, exactly */
  --paper: #FFFAF6;
  --surface: #FFFFFF;
  --tint: #FBEDEA;
  --line: #EAD7D3;
  --line-strong: #D8BDB8;
  --ink: #2B1312;
  --muted: #745250;
  --focus: #F5C518;
  --ok: #2F6B42;
  --ok-tint: #E6F2E9;
  --warn: #7A5300;
  --warn-tint: #FFF2D9;
  --font-display: 'Fredoka', 'Figtree', system-ui, sans-serif;
  --font-ui: 'Figtree', system-ui, -apple-system, 'Segoe UI', sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  font-family: var(--font-ui);
  font-size: 16px;
  line-height: 1.55;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
}
a { color: var(--red); text-underline-offset: 2px; }
a:hover { color: var(--red-dark); }
button, input, select, textarea { font: inherit; color: inherit; }
.hidden { display: none !important; }

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

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 40px; padding: 0 16px; border-radius: 8px; border: 1.5px solid transparent;
  background: var(--red); color: #fff; font-weight: 600; font-size: 15px;
  cursor: pointer; white-space: nowrap;
}
.btn:hover { background: var(--red-dark); }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn.secondary { background: var(--surface); color: var(--ink); border-color: var(--line-strong); }
.btn.secondary:hover { background: var(--tint); }
.btn.quiet { background: transparent; color: var(--red); padding: 0 10px; }
.btn.quiet:hover { background: var(--tint); }
.btn.approve { background: var(--ok); }
.btn.approve:hover { background: #255635; }
.btn.sm { height: 32px; padding: 0 12px; font-size: 14px; border-radius: 7px; }
.btn.lg { height: 52px; font-size: 17px; }
.btn.full { width: 100%; }

/* ---------- form controls ---------- */
.field { margin-bottom: 22px; }
.field > label, .field > .label { display: block; font-weight: 600; margin-bottom: 6px; }
.field .optional { font-weight: 400; color: var(--muted); }
.help { font-size: 14px; color: var(--muted); margin-top: 6px; }
.input, .select {
  width: 100%; height: 46px; padding: 0 14px; border-radius: 8px;
  border: 1.5px solid var(--line-strong); background: var(--surface); font-size: 16px;
}
.input:hover, .select:hover { border-color: #C4A39E; }
.input:focus, .select:focus { border-color: var(--red); outline: none; box-shadow: 0 0 0 3px rgba(150, 28, 27, .12); }
.input:focus-visible, .select:focus-visible { outline: 3px solid var(--focus); outline-offset: 1px; }
.input.invalid { border-color: var(--red); }

/* Joined button group for the music question */
.choice { display: flex; border: 1.5px solid var(--line-strong); border-radius: 8px; overflow: hidden; background: var(--surface); }
.choice input { position: absolute; opacity: 0; pointer-events: none; }
.choice label {
  flex: 1; text-align: center; padding: 11px 8px; cursor: pointer; font-weight: 600; font-size: 15px;
  border-left: 1.5px solid var(--line-strong); color: var(--muted);
}
.choice label:first-of-type { border-left: 0; }
.choice label:hover { background: var(--tint); color: var(--ink); }
.choice input:checked + label { background: var(--red); color: #fff; }
.choice input:focus-visible + label { outline: 3px solid var(--focus); outline-offset: -3px; }

.status-line { display: flex; align-items: center; gap: 6px; font-size: 14px; font-weight: 600; margin-top: 8px; min-height: 22px; }
.status-line.ok { color: var(--ok); }
.status-line.err { color: var(--red); }
.status-line svg { flex: none; }

.alert { border-radius: 8px; padding: 12px 14px; font-size: 15px; margin-bottom: 20px; background: var(--tint); color: var(--ink); border-left: 4px solid var(--red); }
.alert.warn { background: var(--warn-tint); color: var(--warn); border-left-color: var(--warn); }

/* ---------- toast ---------- */
#toast {
  position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 12px);
  background: var(--ink); color: #fff; padding: 11px 18px; border-radius: 8px;
  font-size: 15px; font-weight: 500; opacity: 0; pointer-events: none; z-index: 50;
  transition: opacity .18s, transform .18s; max-width: calc(100vw - 32px);
}
#toast.show { opacity: 1; transform: translate(-50%, 0); }
@media (prefers-reduced-motion: reduce) { #toast { transition: none; } }

/* ================================================================
   Brand header (submit page + sign-in)
   ================================================================ */
.brand-band { background: var(--brand-pink); display: flex; justify-content: center; padding: 28px 16px 20px; }
.brand-band img { display: block; width: 100%; max-width: 330px; height: auto; }
.brand-band a { display: block; }

/* ================================================================
   Public submit page
   ================================================================ */
.page { max-width: 600px; margin: 0 auto; padding: 40px 24px 56px; }
.page h1 {
  font-family: var(--font-display); font-weight: 600; font-size: 36px; line-height: 1.1;
  color: var(--red); margin: 0 0 14px; letter-spacing: -.2px;
}
.intro { font-size: 18px; color: var(--ink); margin: 0 0 22px; max-width: 34em; }

.steps { list-style: none; margin: 0 0 34px; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); border: 1.5px solid var(--line); border-radius: 10px; background: var(--surface); }
.steps li { padding: 14px 16px; font-size: 14px; color: var(--muted); border-left: 1.5px solid var(--line); }
.steps li:first-child { border-left: 0; }
.steps strong { display: block; color: var(--ink); font-size: 15px; margin-bottom: 2px; }

.form-head { font-family: var(--font-ui); font-size: 20px; font-weight: 700; margin: 0 0 18px; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.after-submit { font-size: 14px; color: var(--muted); margin: 14px 0 0; }

.done { padding: 8px 0 0; }
.done h2 { font-family: var(--font-display); font-weight: 600; font-size: 30px; color: var(--red); margin: 0 0 8px; }
.done p { margin: 0 0 24px; font-size: 17px; }
.done .actions { display: flex; gap: 10px; flex-wrap: wrap; }

.site-foot { border-top: 1.5px solid var(--line); margin-top: 44px; padding-top: 20px; font-size: 14px; color: var(--muted); display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; }

/* ================================================================
   Mod sign-in
   ================================================================ */
.signin { max-width: 400px; margin: 0 auto; padding: 36px 24px 56px; }
.signin h1 { font-family: var(--font-display); font-weight: 600; font-size: 28px; color: var(--red); margin: 0 0 6px; }
.signin .sub { color: var(--muted); margin: 0 0 26px; }
.signin .forgot { display: inline-block; margin-top: 14px; font-size: 14px; }
code { font-size: .92em; background: var(--tint); padding: 1px 5px; border-radius: 4px; }

/* ================================================================
   Mod dashboard
   ================================================================ */
.appbar { background: var(--red); color: #fff; }
.appbar .inner { max-width: 1120px; margin: 0 auto; padding: 0 24px; height: 60px; display: flex; align-items: center; gap: 14px; }
.appbar img { width: 34px; height: 34px; border-radius: 8px; }
.appbar .name { font-weight: 700; font-size: 17px; margin-right: auto; white-space: nowrap; }
.narrow-only { display: none; }
.appbar .who { font-size: 14px; opacity: .85; }
.appbar .btn.quiet { color: #fff; }
.appbar .btn.quiet:hover { background: rgba(255, 255, 255, .12); }

.dash { max-width: 1120px; margin: 0 auto; padding: 0 24px 80px; }

.tabs { display: flex; gap: 4px; border-bottom: 1.5px solid var(--line); margin: 0 0 18px; overflow-x: auto; }
.tab {
  background: none; border: 0; cursor: pointer; padding: 16px 12px 13px; margin-bottom: -1.5px;
  font-weight: 600; font-size: 15px; color: var(--muted); border-bottom: 3px solid transparent; white-space: nowrap;
}
.tab:hover { color: var(--ink); }
.tab[aria-selected="true"] { color: var(--red); border-bottom-color: var(--red); }
.tab .n { font-weight: 500; color: var(--muted); margin-left: 4px; font-variant-numeric: tabular-nums; }
.tab[aria-selected="true"] .n { color: var(--red); }

.toolbar { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin-bottom: 14px; }
.toolbar .input, .toolbar .select { height: 38px; font-size: 15px; width: auto; }
.toolbar .search { flex: 1 1 240px; }
.summary { font-size: 15px; color: var(--muted); margin: 0 0 14px; }

/* the clip list: one bordered table-like container, rows divided by rules */
.clips { background: var(--surface); border: 1.5px solid var(--line); border-radius: 10px; }
.clip { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px 20px; padding: 16px 18px; border-top: 1.5px solid var(--line); }
.clip:first-child { border-top: 0; }
.clip.picked { background: #FFFBEA; }
.clip .top { display: flex; align-items: baseline; gap: 10px; min-width: 0; }
.clip .pos { font-weight: 700; color: var(--red); font-variant-numeric: tabular-nums; min-width: 1.6em; }
.clip .plat { font-size: 13px; font-weight: 700; flex: none; }
.plat.tiktok { color: #222; }
.plat.instagram { color: #A3226B; }
.plat.youtube { color: #C1150F; }
.clip .url { font-weight: 600; text-decoration: none; overflow-wrap: anywhere; }
.clip .url:hover { text-decoration: underline; }
.clip .meta { font-size: 14px; color: var(--muted); display: flex; flex-wrap: wrap; gap: 2px 18px; }
.clip .meta span b { color: var(--ink); font-weight: 600; }
.clip .note {
  width: 100%; border: 1.5px solid transparent; background: transparent; border-radius: 6px;
  padding: 5px 8px; margin-left: -8px; font-size: 14px; color: var(--ink);
}
.clip .note::placeholder { color: #A88A87; }
.clip .note:hover { border-color: var(--line); }
.clip .note:focus { border-color: var(--red); background: var(--surface); outline: none; }
.clip .side { display: flex; align-items: flex-start; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.clip .music { height: 32px; font-size: 14px; border-radius: 7px; border: 1.5px solid var(--line-strong); background: var(--surface); padding: 0 8px; }
.clip .music.has { border-color: #E2C27A; background: var(--warn-tint); color: var(--warn); }

.empty { padding: 44px 20px; text-align: center; color: var(--muted); background: var(--surface); border: 1.5px dashed var(--line-strong); border-radius: 10px; }

.section { margin-bottom: 34px; }
.section h2 { font-size: 18px; font-weight: 700; margin: 0 0 4px; }
.section .lead { font-size: 15px; color: var(--muted); margin: 0 0 14px; }
.controls { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.controls .select, .controls .input { height: 40px; width: auto; font-size: 15px; }
.controls label.inline { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; font-size: 15px; }
.controls .grow { flex: 1; }
.export-bar { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; padding: 16px 18px; background: var(--surface); border: 1.5px solid var(--line); border-radius: 10px; }

/* ---------- change-password dialog ---------- */
dialog#pwDialog {
  border: 0; border-radius: 12px; padding: 0; width: min(420px, calc(100vw - 32px));
  background: var(--paper); color: var(--ink); box-shadow: 0 20px 60px rgba(43, 19, 18, .3);
}
dialog#pwDialog::backdrop { background: rgba(43, 19, 18, .45); }
dialog#pwDialog form { padding: 24px; }
dialog#pwDialog h2 { font-size: 20px; font-weight: 700; margin: 0 0 18px; }
.dialog-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 6px; }

@media (max-width: 720px) {
  .page { padding: 28px 18px 48px; }
  .page h1 { font-size: 30px; }
  .intro { font-size: 17px; }
  .steps { grid-template-columns: 1fr; }
  .steps li { border-left: 0; border-top: 1.5px solid var(--line); }
  .steps li:first-child { border-top: 0; }
  .brand-band img { max-width: 260px; }
  .appbar .who { display: none; }
  .appbar .inner { gap: 4px; }
  .appbar img { margin-right: 6px; }
  .appbar .btn.quiet { padding: 0 8px; }
  .wide-only { display: none; }
  .narrow-only { display: inline; }
  .dash, .appbar .inner { padding-left: 16px; padding-right: 16px; }
  .clip { grid-template-columns: 1fr; padding: 14px; }
  .clip .side { justify-content: flex-start; }
}
