/* moatopshot.com: brand colors from the logo, light first (readable in sun). */
:root {
  --charcoal: #363636;
  --red: #e02420;
  --red-dark: #b81c19;
  --gray: #f3f3f1;
  --bg: #ffffff;
  --surface: #ffffff;
  --text: #1e1e1e;
  --muted: #555555;
  --border: #e3e3e3;
  --tint: #fdf1f0;
  --radius: 16px;
  --max: 1120px;
  color-scheme: light;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: #f6f6f5;
  color: var(--text);
  font: 17px/1.6 -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}
img { max-width: 100%; height: auto; }
a { color: var(--red); text-underline-offset: 3px; }
a:hover { color: var(--red-dark); }
h1, h2, h3 { line-height: 1.15; letter-spacing: -0.01em; margin: 0 0 0.5em; }
h1 { font-size: clamp(2.1rem, 5vw, 3.4rem); font-weight: 900; }
h2 { font-size: clamp(1.4rem, 3vw, 2rem); font-weight: 800; margin-top: 1.2em; }
h3 { font-size: 1.15rem; font-weight: 800; }
p { margin: 0 0 1em; }

.wrap { max-width: var(--max); margin: 0 auto; padding: 0 20px; }
.narrow { max-width: 760px; }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 12px; top: 12px; background: var(--surface); padding: 8px 12px; border-radius: 8px; z-index: 10; }
.muted { color: var(--muted); }
.small { font-size: 0.85rem; }

/* Header */
.site-header { position: sticky; top: 0; z-index: 5; }
.header-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 68px; flex-wrap: wrap; }
.brand img { display: block; width: 132px; height: auto; }
.nav { display: flex; gap: 6px; flex-wrap: wrap; }
.nav a { color: var(--text); text-decoration: none; font-weight: 600; font-size: 0.95rem; padding: 8px 12px; border-radius: 999px; }
.nav a:hover, .nav a[aria-current="page"] { background: var(--gray); color: var(--text); }

/* Hero */
.hero { padding: 72px 0 56px; }
.hero-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 40px; align-items: center; }
.hero-art { display: flex; justify-content: center; }
.hero-art img { width: min(256px, 60vw); border-radius: 56px; box-shadow: 0 24px 60px rgba(0, 0, 0, 0.18); }
.eyebrow { text-transform: uppercase; letter-spacing: 0.12em; font-weight: 800; font-size: 0.8rem; color: var(--red); margin-bottom: 0.8em; }
.lead { font-size: 1.2rem; color: var(--muted); max-width: 40em; }
.cta-row { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; margin-top: 24px; }

.button { display: inline-block; background: var(--charcoal); color: #fff; text-decoration: none; font-weight: 700; padding: 12px 22px; border-radius: 999px; border: 2px solid var(--charcoal); }
.button:hover { color: #fff; background: #222; }
.button.secondary { background: transparent; color: var(--text); border-color: var(--border); }
.button.secondary:hover { border-color: var(--text); color: var(--text); }
.badge-soon { display: inline-block; font-weight: 800; padding: 12px 22px; border-radius: 999px; background: var(--red); color: #fff; }

/* Sections */
.section { padding: 56px 0; }
.section.alt { background: rgba(255, 255, 255, 0.28); }
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 16px; margin: 24px 0; }
.cards.three { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.card { background: var(--surface); border: 1px solid var(--border); border-top: 4px solid var(--red); border-radius: var(--radius); padding: 22px; box-shadow: 0 6px 20px rgba(0, 0, 0, 0.05); }
.card.plain { border-top-width: 1px; border-top-color: var(--border); }
.card p:last-child { margin-bottom: 0; }
.steps { padding-left: 1.2em; display: grid; gap: 12px; max-width: 46em; }
.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; }
.ticks { list-style: none; padding: 0; margin: 0 0 1em; }
.ticks li { position: relative; padding-left: 1.6em; margin: 0.4em 0; }
.ticks li::before { content: "✓"; position: absolute; left: 0; color: var(--red); font-weight: 900; }

/* Pricing */
.plan h2 { margin-top: 0; }
.plan.featured { border: 2px solid var(--red); }
.price { font-size: 2.4rem; font-weight: 900; margin: 0; }
.price span { font-size: 1rem; font-weight: 600; color: var(--muted); }
.note { color: var(--muted); font-size: 0.95rem; }

/* FAQ */
.qa details { background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 14px 18px; margin: 10px 0; }
.qa summary { cursor: pointer; font-weight: 700; }
.qa details p { margin: 10px 0 0; }

/* Legal */
.legal h2 { font-size: 1.3rem; }
.draft { background: #fff4d6; color: #5a4300; border: 1px solid #f0d58a; border-radius: 12px; padding: 12px 16px; }
.contact { margin: 24px 0; }

/* Footer */
.site-footer { border-top: 1px solid var(--border); padding: 40px 0 24px; margin-top: 40px; }
.footer-grid { display: grid; grid-template-columns: 1.2fr 1fr; gap: 24px; }
.footer-tag { font-weight: 800; }
.footer-links { display: grid; grid-template-columns: 1fr 1fr; gap: 6px 16px; align-content: start; }
.footer-links a { color: var(--text); text-decoration: none; }
.footer-links a:hover { color: var(--red); }

@media (max-width: 760px) {
  .hero { padding-top: 36px; }
  .hero-grid, .two-col, .footer-grid { grid-template-columns: 1fr; }
  .hero-art { order: -1; justify-content: flex-start; }
  .hero-art img { width: 120px; border-radius: 28px; }
  .nav a { padding: 6px 10px; font-size: 0.9rem; }
  /* Phones: a compact header that scrolls away instead of covering the page. */
  .site-header { position: static; }
  .header-row { min-height: 0; padding: 10px 20px; gap: 6px; }
  .brand img { width: 96px; }
  .hero .hero-tile { padding: 12px; border-radius: 28px; }
  .hero .hero-tile img { width: 104px; border-radius: 24px; }
  .hero .hero-tile .hero-photo { width: 100%; border-radius: 20px; }
  .nav { gap: 2px; }
}

/* Photo slots (website/photos/*). Shown only when the files exist. */
.hero-photo { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 24px; box-shadow: 0 24px 60px rgba(0, 0, 0, 0.18); }
.gallery { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 14px; margin-top: 24px; }
.gallery img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 16px; display: block; }
.feature-photo { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; border-radius: 20px; margin: 16px 0 8px; }

/* ---------------------------------------------------------------------------
   Liquid glass. A soft brand-color backdrop with drifting color orbs sits
   behind everything; panels are frosted glass with bright edges and a
   highlight that follows the cursor. In Chrome/Edge (.liquid) the glass also
   bends what is behind it (SVG displacement filter #liquid).
   ------------------------------------------------------------------------ */
.backdrop { position: fixed; inset: 0; z-index: -2; background: #f6f6f5 url(/bg-glass.jpg) center / cover no-repeat; }
.orbs { position: fixed; inset: 0; z-index: -1; overflow: hidden; pointer-events: none; }
.orb { position: absolute; border-radius: 50%; filter: blur(40px); opacity: 0.55; }
.orb.red { width: 420px; height: 420px; right: 6%; top: 8%; background: radial-gradient(circle, rgba(224, 36, 32, 0.55), rgba(224, 36, 32, 0) 70%); }
.orb.brass { width: 360px; height: 360px; left: 2%; top: 46%; background: radial-gradient(circle, rgba(201, 162, 39, 0.5), rgba(201, 162, 39, 0) 70%); }
.orb.slate { width: 460px; height: 460px; right: 22%; bottom: -6%; background: radial-gradient(circle, rgba(88, 118, 158, 0.45), rgba(88, 118, 158, 0) 70%); }
.orb.char { width: 300px; height: 300px; left: 30%; top: 4%; background: radial-gradient(circle, rgba(54, 54, 54, 0.22), rgba(54, 54, 54, 0) 70%); }
.svg-defs { position: absolute; width: 0; height: 0; overflow: hidden; }

.glass {
  position: relative;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.62), rgba(255, 255, 255, 0.28));
  -webkit-backdrop-filter: blur(22px) saturate(175%);
  backdrop-filter: blur(22px) saturate(175%);
  border: 1px solid rgba(255, 255, 255, 0.75);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.95),
    inset 0 -1px 0 rgba(255, 255, 255, 0.35),
    inset 0 0 24px rgba(255, 255, 255, 0.25),
    0 14px 40px rgba(30, 30, 30, 0.10);
  isolation: isolate;
}
.glass::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  background: radial-gradient(420px circle at var(--mx, 25%) var(--my, 0%), rgba(255, 255, 255, 0.65), rgba(255, 255, 255, 0) 45%);
  opacity: 0.7;
  z-index: -1;
}
.liquid .glass { -webkit-backdrop-filter: url(#liquid) blur(16px) saturate(175%); backdrop-filter: url(#liquid) blur(16px) saturate(175%); }

.site-header.glass { border: 0; border-bottom: 1px solid rgba(255, 255, 255, 0.7); border-radius: 0; }
.card.glass { border-top: 1px solid rgba(255, 255, 255, 0.75); border-radius: 22px; }
.card.glass.accent { box-shadow: inset 0 3px 0 var(--red), inset 0 1px 0 rgba(255, 255, 255, 0.95), 0 14px 40px rgba(30, 30, 30, 0.10); }
.plan.featured.glass { border: 2px solid rgba(224, 36, 32, 0.7); }
.qa details.glass { border-radius: 16px; }
.hero-tile { padding: 28px; border-radius: 44px; display: inline-block; }
.hero-tile img { display: block; width: min(220px, 50vw); border-radius: 40px; box-shadow: 0 18px 40px rgba(0, 0, 0, 0.16); }
.hero-tile .hero-photo { width: min(520px, 80vw); border-radius: 28px; }
.button.glass { background: linear-gradient(135deg, rgba(255, 255, 255, 0.7), rgba(255, 255, 255, 0.35)); color: var(--text); border: 1px solid rgba(255, 255, 255, 0.85); }
.button.glass:hover { color: var(--text); }
.magnetic { will-change: transform; }
.tilt { transform-style: preserve-3d; will-change: transform; }
.nav a:hover, .nav a[aria-current="page"] { background: rgba(255, 255, 255, 0.7); }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}


/* ---------------------------------------------------------------------------
   Live display (moatopshot.com/live/<key>): made for a TV across the room.
   No site header/footer; type scales with the screen.
   ------------------------------------------------------------------------ */
.live-page .site-header, .live-page .site-footer, .live-page .skip { display: none; }
.live { max-width: 1800px; padding: 2vh 2.5vw; display: grid; gap: 2vh; font-size: clamp(16px, 1.25vw, 30px); }
.live h1 { font-size: clamp(1.6rem, 2.6vw, 3.4rem); margin: 0; }
.live .muted { margin: 0; }
.live-header { display: grid; grid-template-columns: 1fr auto; gap: 1vh 2vw; align-items: center; padding: 1.4vh 1.6vw; border-radius: 24px; }
.live-tabs { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 8px; }
.live-tools { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; justify-content: flex-end; }
.tab, .tool { font: inherit; font-size: 0.85em; font-weight: 700; cursor: pointer; border-radius: 999px; padding: 0.45em 1em; border: 1px solid rgba(255, 255, 255, 0.85); background: rgba(255, 255, 255, 0.5); color: var(--text); }
.tab.on { background: var(--charcoal); color: #fff; border-color: var(--charcoal); }
.live-status { font-size: 0.8em; color: var(--muted); }
.live-status.stale { color: var(--red); font-weight: 700; }
.live-message { padding: 4vh 3vw; border-radius: 24px; text-align: center; }
.eyebrow { display: block; text-transform: uppercase; letter-spacing: 0.12em; font-weight: 800; font-size: 0.75em; color: var(--red); }

.live-leader, .live-champion { display: flex; align-items: center; gap: 2vw; padding: 2vh 2vw; border-radius: 24px; flex-wrap: wrap; }
.live-leader strong, .live-champion strong { font-size: clamp(1.8rem, 3.4vw, 4.4rem); font-weight: 900; flex: 1; }
.leader-points { font-size: clamp(1.8rem, 3.4vw, 4.4rem); font-weight: 900; font-variant-numeric: tabular-nums; }

.live-table { width: 100%; border-collapse: separate; border-spacing: 0; border-radius: 24px; overflow: hidden; }
.live-table th, .live-table td { padding: 0.55em 0.9em; text-align: left; border-bottom: 1px solid rgba(255, 255, 255, 0.6); }
.live-table th { font-size: 0.75em; text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); }
.live-table td { font-size: 1.15em; }
.live-table .num { text-align: right; font-variant-numeric: tabular-nums; }
.live-table .total { font-weight: 900; }
.live-table .place { width: 3.2em; font-weight: 900; color: var(--muted); }
.live-table .name { font-weight: 700; }
.live-table .team { color: var(--muted); }
.live-table tr.top1 td { background: rgba(224, 36, 32, 0.10); }
.live-table tr.top1 .place, .live-table tr.top2 .place, .live-table tr.top3 .place { color: var(--red); }
.pager { text-align: right; }

.live-teams { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 1.6vh 1.4vw; }
.team-card { padding: 1.6vh 1.4vw; border-radius: 22px; }
.team-card.first { border: 2px solid rgba(224, 36, 32, 0.7); }
.team-head { display: flex; align-items: baseline; gap: 0.8em; font-size: 1.25em; }
.team-head strong { flex: 1; }
.team-head .place { color: var(--red); font-weight: 900; }
.team-head .points { font-weight: 900; font-variant-numeric: tabular-nums; }
.team-card ul { list-style: none; padding: 0; margin: 0.6em 0 0; }
.team-card li { display: flex; justify-content: space-between; padding: 0.15em 0; }
.team-card li.counts { font-weight: 700; }
.team-card li.extra { color: var(--muted); }

.on-line { padding: 2vh 2vw; border-radius: 26px; border: 3px solid var(--charcoal); }
.versus { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 2vw; margin-top: 1vh; }
.side { text-align: center; display: grid; gap: 0.4em; }
.side-label { font-weight: 900; letter-spacing: 0.2em; color: var(--red); font-size: 0.8em; }
.side strong { font-size: clamp(1.8rem, 3.6vw, 4.6rem); font-weight: 900; line-height: 1.1; }
.side .wins { font-size: clamp(1.8rem, 3.2vw, 4rem); font-weight: 900; font-variant-numeric: tabular-nums; }
.vs { color: var(--muted); font-weight: 700; font-size: 1.4em; }
.on-deck { padding: 1.4vh 1.6vw; border-radius: 22px; }
.deck-row { margin: 0.4em 0 0; font-size: 1.1em; }
.rounds { display: flex; gap: 1.2vw; overflow-x: auto; padding-bottom: 1vh; }
.round { min-width: 240px; flex: 1; display: flex; flex-direction: column; gap: 0.8vh; justify-content: space-around; }
.round h3 { font-size: 0.8em; text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); text-align: center; margin: 0; }
.heat { border-radius: 16px; padding: 0.3em 0.7em; }
.heat.ready { border: 2px solid var(--charcoal); }
.heat-line { display: flex; gap: 0.6em; align-items: center; padding: 0.25em 0; }
.heat-line + .heat-line { border-top: 1px solid rgba(255, 255, 255, 0.7); }
.heat-line .seed { width: 1.4em; color: var(--muted); font-size: 0.8em; text-align: right; }
.heat-line .who { flex: 1; }
.heat-line.won .who { font-weight: 900; }
.heat-line.lost .who { color: var(--muted); text-decoration: line-through; }
.heat-line .wins { font-weight: 900; }

@media (max-width: 760px) {
  .live-header { grid-template-columns: 1fr; }
  .live-tools { justify-content: flex-start; }
  .live-table .team, .live-table th.team { display: none; }
}

/* Live: code entry and home-page promo */
.live-entry { max-width: 720px; margin: 6vh auto 0; text-align: left; }
.entry-form { margin: 1.4em 0 1em; }
.entry-label { display: block; font-weight: 700; margin-bottom: 0.4em; }
.entry-row { display: flex; gap: 10px; flex-wrap: wrap; }
.entry-input { flex: 1; min-width: 220px; font: inherit; font-size: 1.4em; font-weight: 800; letter-spacing: 0.12em; text-transform: uppercase; padding: 0.45em 0.7em; border-radius: 14px; border: 1px solid rgba(54, 54, 54, 0.25); background: rgba(255, 255, 255, 0.75); color: var(--text); }
.entry-input:focus { outline: 3px solid rgba(224, 36, 32, 0.35); outline-offset: 2px; }
.entry-row .button { font-size: 1.1em; cursor: pointer; }
.entry-error { color: var(--red); min-height: 1.4em; margin: 0.5em 0 0; }
.live-promo { display: flex; gap: 24px; align-items: center; justify-content: space-between; flex-wrap: wrap; }
.live-promo h2 { margin-top: 0; }
.live-promo p { margin: 0; max-width: 46em; }
