/*
 * Hockey Stick Alerts
 * Look: rink ice and boards. The one loud thing is the "shaft strip", the dark bar with
 * printed specs you see on a pro stock stick (LEFT  P92  75). Everything else stays quiet.
 */
@import url('https://fonts.googleapis.com/css2?family=Saira+Condensed:wght@500;700;800&family=Public+Sans:wght@400;500;600;700&display=swap');

:root {
  --ice: #f3f7fa;
  --ice-2: #e3ebf2;
  --boards: #13294b;
  --shaft: #1b2330;
  --goal-red: #c8102e;
  --blue-line: #1f5fbf;
  --text: #13294b;
  --muted: #5a6b82;
  --line: #cfdbe6;
  --white: #ffffff;
  --good: #187a43;
  --display: 'Saira Condensed', 'Arial Narrow', sans-serif;
  --body: 'Public Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--ice);
  color: var(--text);
  font: 16px/1.55 var(--body);
}
img { max-width: 100%; display: block; }
a { color: var(--blue-line); }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, label:focus-within {
  outline: 3px solid var(--blue-line);
  outline-offset: 2px;
}
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 16px; }

/* Header: the boards, with the red line under it */
.top { background: var(--boards); border-bottom: 4px solid var(--goal-red); }
.top .wrap { display: flex; align-items: center; justify-content: space-between; min-height: 60px; gap: 16px; }
.logo {
  color: var(--white); text-decoration: none;
  font: 800 26px/1 var(--display); letter-spacing: .01em;
  display: flex; align-items: center; gap: 10px;
}
.puck { width: 22px; height: 12px; border-radius: 50%; background: var(--white); box-shadow: inset 0 -4px 0 #9fb2c8; }
.top nav a { color: #dbe6f3; text-decoration: none; font-weight: 600; font-size: 15px; }
.top nav a:hover { color: var(--white); text-decoration: underline; }

main.wrap { padding-top: 32px; padding-bottom: 56px; }

h1, h2, h3 { font-family: var(--display); line-height: 1.05; margin: 0 0 12px; color: var(--boards); }
h1 { font-size: clamp(40px, 7vw, 68px); font-weight: 800; letter-spacing: -.005em; }
h2 { font-size: clamp(28px, 4vw, 36px); font-weight: 700; margin-top: 40px; }
h3 { font-size: 22px; font-weight: 700; }
p { max-width: 68ch; }
.lede { font-size: 19px; color: var(--muted); max-width: 52ch; }
.muted { color: var(--muted); }
.small { font-size: 14px; }

/* The shaft strip */
.shaft {
  display: inline-flex; flex-wrap: wrap; align-items: center;
  background: var(--shaft); color: var(--white);
  font: 700 15px/1 var(--display); letter-spacing: .08em; text-transform: uppercase;
  padding: 7px 12px 6px; border-radius: 3px; gap: 4px 14px;
  border-left: 6px solid var(--goal-red);
}
.shaft b { font-weight: 800; color: #ffd166; letter-spacing: .04em; }

/* Home hero */
.hero { display: grid; grid-template-columns: 1fr; gap: 32px; align-items: start; }
@media (min-width: 900px) {
  .hero { grid-template-columns: 1.05fr 1fr; gap: 48px; }
  .hero-copy { position: sticky; top: 24px; }
}
.hero-copy h1 { margin-bottom: 18px; }
.hero-copy .shaft { font-size: 19px; margin: 6px 0 22px; }
.watching { margin-top: 18px; font-size: 15px; color: var(--muted); }
.watching strong { color: var(--boards); }

.steps { list-style: none; margin: 28px 0 0; padding: 0; display: grid; gap: 14px; max-width: 480px; }
.steps li { display: grid; grid-template-columns: 34px 1fr; gap: 12px; align-items: start; }
.steps .n {
  width: 34px; height: 34px; border-radius: 50%; border: 2px solid var(--blue-line); color: var(--blue-line);
  display: grid; place-items: center; font: 800 18px/1 var(--display);
}

/* Panels (forms, notices) */
.panel { background: var(--white); border: 1px solid var(--line); border-radius: 10px; padding: 22px; }
.panel h2:first-child, .panel h3:first-child { margin-top: 0; }
.notice { background: var(--white); border-left: 5px solid var(--blue-line); padding: 14px 18px; border-radius: 6px; margin: 0 0 20px; }
.notice.error { border-left-color: var(--goal-red); }
.notice.good { border-left-color: var(--good); }

/* Alert form */
.field { margin: 0 0 20px; }
.field > .label { display: block; font-weight: 700; margin-bottom: 4px; }
.field > .hint { display: block; color: var(--muted); font-size: 14px; margin-bottom: 8px; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { position: relative; }
.chip input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.chip span {
  display: inline-block; padding: 6px 11px; border: 1px solid var(--line); border-radius: 999px;
  background: var(--ice); font-size: 14px; font-weight: 600; cursor: pointer; user-select: none;
}
.chip span small { font-weight: 400; color: var(--muted); }
.chip input:checked + span { background: var(--boards); border-color: var(--boards); color: var(--white); }
.chip input:checked + span small { color: #c3d2e4; }
.chip input:focus-visible + span { outline: 3px solid var(--blue-line); outline-offset: 2px; }
.chip span:hover { border-color: var(--boards); }

.model-box { border: 1px solid var(--line); border-radius: 8px; background: var(--ice); padding: 10px; }
.model-box input[type=search] { margin-bottom: 8px; }
.model-list { max-height: 230px; overflow-y: auto; display: flex; flex-wrap: wrap; gap: 6px; align-content: flex-start; }
.model-list .chip span { background: var(--white); }
.model-list .empty { color: var(--muted); font-size: 14px; padding: 4px; }

input[type=email], input[type=search], input[type=text], select {
  width: 100%; font: inherit; padding: 10px 12px; border: 1px solid var(--line); border-radius: 6px; background: var(--white); color: var(--text);
}
.consent { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; color: var(--muted); }
.consent input { margin-top: 4px; }

.btn {
  display: inline-block; font: 700 18px/1 var(--display); letter-spacing: .03em;
  background: var(--goal-red); color: var(--white); border: 0; border-radius: 6px;
  padding: 13px 22px 12px; cursor: pointer; text-decoration: none;
}
.btn:hover { background: #a50d26; }
.btn.secondary { background: var(--white); color: var(--boards); border: 2px solid var(--boards); padding: 11px 18px 10px; }
.btn.secondary:hover { background: var(--ice-2); }
.btn.small { font-size: 15px; padding: 9px 14px 8px; }
.linkish { background: none; border: 0; color: var(--goal-red); font: inherit; font-weight: 600; cursor: pointer; padding: 0; text-decoration: underline; }

/* Stick rows */
.sticks { display: grid; gap: 12px; margin: 16px 0 8px; }
.stick {
  display: grid; grid-template-columns: 84px 1fr; gap: 14px;
  background: var(--white); border: 1px solid var(--line); border-radius: 8px; padding: 12px;
}
@media (min-width: 720px) { .stick { grid-template-columns: 110px 1fr auto; align-items: center; } }
.stick .pic { width: 100%; aspect-ratio: 1; object-fit: contain; background: var(--ice); border-radius: 6px; }
.stick .pic.none { display: grid; place-items: center; color: var(--muted); font-size: 12px; }
.stick h3 { font-size: 21px; margin: 0 0 6px; }
.stick h3 a { color: inherit; text-decoration: none; }
.stick h3 a:hover { text-decoration: underline; }
.stick .meta { font-size: 14px; color: var(--muted); margin: 6px 0 0; }
.stick .meta span + span::before { content: "/"; margin: 0 7px; color: var(--line); }
.stick .buy { grid-column: 1 / -1; display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
@media (min-width: 720px) { .stick .buy { grid-column: auto; flex-direction: column; align-items: flex-end; text-align: right; } }
.price { font: 800 28px/1 var(--display); color: var(--boards); }
.price s { font: 600 17px/1 var(--body); color: var(--muted); margin-right: 6px; }
.badge { display: inline-block; font-size: 12px; font-weight: 700; padding: 2px 8px; border-radius: 4px; background: var(--ice-2); color: var(--boards); margin-right: 6px; }
.badge.drop { background: #fde7ea; color: var(--goal-red); }
.badge.new { background: #e3f3ea; color: var(--good); }
.stick.sold { opacity: .55; }
.stick.sold .price::after { content: " sold"; font: 700 14px var(--body); color: var(--goal-red); }
.stick .shaft { font-size: 13px; padding: 5px 9px 4px; border-left-width: 4px; }

.section-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; margin-top: 36px; }
.section-head h2 { margin: 0; }

/* Ads */
.ad { margin: 24px 0; min-height: 90px; }

/* Filters (browse) */
.filters { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin: 18px 0; }
@media (min-width: 760px) { .filters { grid-template-columns: repeat(6, 1fr); align-items: end; } }
.filters label { font-size: 13px; font-weight: 700; display: block; margin-bottom: 4px; }
.pager { display: flex; gap: 10px; justify-content: center; margin: 24px 0; }

/* Charts */
.chart-box { background: var(--white); border: 1px solid var(--line); border-radius: 10px; padding: 16px; margin: 16px 0; height: 320px; }
.range { display: flex; gap: 6px; }
.range a { text-decoration: none; font-weight: 600; font-size: 14px; padding: 4px 10px; border-radius: 999px; border: 1px solid var(--line); color: var(--boards); background: var(--white); }
.range a.on { background: var(--boards); color: var(--white); border-color: var(--boards); }

/* Alert list on manage page */
.alert-row { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--ice-2); }
.alert-row:last-child { border-bottom: 0; }

/* Admin tables */
table.data { width: 100%; border-collapse: collapse; background: var(--white); font-size: 14px; }
table.data th, table.data td { text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--ice-2); vertical-align: top; }
table.data th { background: var(--ice-2); }
.scroll-x { overflow-x: auto; }
.bad { color: var(--goal-red); font-weight: 700; }
.ok { color: var(--good); font-weight: 700; }

.foot { border-top: 1px solid var(--line); color: var(--muted); font-size: 14px; padding: 24px 0 40px; }

@media (prefers-reduced-motion: reduce) { * { scroll-behavior: auto !important; transition: none !important; } }
