/* Veritas Fairway app: colours, type and parts taken from the design pages in the project folder. */
:root {
  --cream: #FAF8F2; --ink: #161616; --muted: #4A4A45; --rule: #CFCABD; --soft: #33332F;
  --green: #0E3B2C; --leaf: #1F6B45; --mint: #9BD3B2; --mist: #CFE3D7; --sage: #DCE3DA;
  --nr-bg: #F4F7F3; --nr-ink: #10241B; --nr-line: #DCE6E0; --nr-muted: #4A5C53;
  --done-bg: #F1F8F3; --done-line: #9BD3B2; --done-ink: #145C38;
  --wait-bg: #FFFAF2; --wait-line: #E7B877; --wait-ink: #8A3B06;
  --bad-bg: #FDF1EF; --bad-line: #E4A99F; --bad-ink: #9B2C1D;
  --serif: 'Source Serif 4', Georgia, serif; --display: 'Playfair Display', Georgia, serif;
  --sans: Inter, system-ui, sans-serif; --head: Archivo, Inter, system-ui, sans-serif;
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body { background: var(--cream); color: var(--ink); font-family: var(--serif); }
a { color: inherit; }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 3px solid var(--leaf); outline-offset: 2px; }
[hidden] { display: none !important; }

/* ---------- shared controls ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 18px;
  border-radius: 10px; border: 1px solid transparent; font-family: var(--sans); font-weight: 700; font-size: 14px; text-decoration: none; }
.btn-primary { background: var(--leaf); color: #fff; }
.btn-dark { background: var(--green); color: #fff; }
.btn-light { background: #fff; color: var(--green); border-color: var(--nr-line); }
.btn-ghost { background: transparent; color: var(--green); border-color: var(--nr-line); }
.btn[disabled] { opacity: .5; cursor: not-allowed; }
.btn-sm { min-height: 36px; padding: 0 12px; font-size: 13px; }
.field { display: flex; flex-direction: column; gap: 6px; font-family: var(--sans); font-size: 13px; font-weight: 600; }
.input { min-height: 44px; padding: 0 12px; border: 1.5px solid #B9C7BF; border-radius: 10px; background: #fff; color: var(--nr-ink); font-family: var(--sans); font-size: 16px; }
.phone-input { display: flex; align-items: stretch; }
.phone-input span { display: inline-flex; align-items: center; padding: 0 12px; border: 1.5px solid #B9C7BF; border-right: 0; border-radius: 10px 0 0 10px; background: #F1F4F2; font-family: var(--sans); font-weight: 600; }
.phone-input .input { border-radius: 0 10px 10px 0; flex: 1; min-width: 0; }
.notice { font-family: var(--sans); font-size: 13px; line-height: 1.45; padding: 10px 12px; border-radius: 10px; border: 1px solid var(--nr-line); background: #fff; }
.notice.good { background: var(--done-bg); border-color: var(--done-line); color: var(--done-ink); }
.notice.wait { background: var(--wait-bg); border-color: var(--wait-line); color: var(--wait-ink); }
.notice.bad { background: var(--bad-bg); border-color: var(--bad-line); color: var(--bad-ink); }
.kicker { font-family: var(--sans); font-size: 11px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--leaf); }
.muted { color: var(--muted); }
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 12px; }
#toast { position: fixed; left: 50%; bottom: 20px; transform: translateX(-50%); z-index: 50; max-width: min(560px, calc(100% - 32px)); }

/* ---------- reader (the newspaper, phone width) ---------- */
.paper-page { background: #D9DED9; min-height: 100vh; display: flex; justify-content: center; }
.paper { width: 100%; max-width: 480px; background: var(--cream); min-height: 100vh; display: flex; flex-direction: column; }
.masthead { padding: 10px 16px 0; }
.masthead-row { display: flex; justify-content: space-between; align-items: center; min-height: 44px; }
.masthead-row .title { font-family: var(--display); font-weight: 900; font-size: 28px; text-decoration: none; }
.masthead-row a.icon, .masthead-row button.icon { width: 44px; height: 44px; display: inline-flex; align-items: center; justify-content: center; background: none; border: 0; color: var(--ink); }
.double-rule { border-top: 3px solid var(--ink); border-bottom: 1px solid var(--ink); height: 3px; margin-top: 6px; }
.tournament { margin: 14px 16px 0; border: 1.5px solid var(--ink); background: #fff; }
.tournament-top { display: flex; align-items: center; gap: 12px; padding: 12px; border-bottom: 1px solid var(--rule); }
.logo-slot { width: 92px; height: 52px; flex-shrink: 0; border: 1px dashed #A8A293; display: flex; align-items: center; justify-content: center; text-align: center; font-family: var(--sans); font-size: 10px; font-weight: 600; color: var(--muted); }
.tournament dl { margin: 0; display: grid; grid-template-columns: 1fr 1fr; font-family: var(--sans); }
.tournament dl div { padding: 8px 12px; display: flex; flex-direction: column; gap: 2px; }
.tournament dl div:nth-child(even) { border-left: 1px solid var(--rule); }
.tournament dl div:nth-child(n+3) { border-top: 1px solid var(--rule); }
.tournament dt { font-size: 10px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.tournament dd { margin: 0; font-size: 14px; font-weight: 600; }
.story { padding: 18px 16px 28px; display: flex; flex-direction: column; gap: 16px; }
.story h1 { margin: 0; font-family: var(--display); font-weight: 800; font-size: 34px; line-height: 1.05; letter-spacing: -.01em; }
.standfirst { margin: 0; font-size: 18px; line-height: 1.45; font-style: italic; color: var(--soft); }
.scorebox { background: var(--green); color: var(--cream); padding: 16px; display: flex; flex-direction: column; gap: 10px; }
.scorebox .big { font-family: var(--display); font-weight: 900; font-size: 56px; line-height: .9; }
.scorebox .sub { font-family: var(--sans); font-size: 14px; font-weight: 600; color: var(--mist); }
.scorebox .grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; font-family: var(--sans); border-top: 1px solid #2E5E4C; padding-top: 10px; }
.scorebox .grid span:first-child { display: block; font-size: 10px; letter-spacing: .1em; text-transform: uppercase; color: var(--mint); font-weight: 700; }
.scorebox .grid span:last-child { font-size: 22px; font-weight: 700; }
.scorebox .note { font-family: var(--sans); font-size: 11px; color: var(--mist); }
.byline { font-family: var(--sans); font-size: 12px; border-bottom: 1px solid var(--rule); padding-bottom: 8px; display: flex; align-items: center; gap: 10px; }
.avatar { width: 36px; height: 36px; border-radius: 50%; background: var(--green); color: var(--cream); display: inline-flex; align-items: center; justify-content: center; font-family: var(--display); font-weight: 900; font-size: 15px; flex-shrink: 0; }
.roundup { border-left: 4px solid var(--leaf); background: #fff; padding: 12px 14px; display: flex; flex-direction: column; gap: 6px; }
.roundup p { margin: 0; font-size: 16px; line-height: 1.55; }
.body-text { font-size: 17px; line-height: 1.65; display: flex; flex-direction: column; gap: 14px; }
.body-text p { margin: 0; }
.dropcap { float: left; font-family: var(--display); font-weight: 900; font-size: 62px; line-height: .8; padding: 6px 8px 0 0; }
.dateline { font-family: var(--sans); font-size: 12px; letter-spacing: .06em; font-weight: 700; }
.section-h { margin: 0; font-family: var(--sans); font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; border-top: 3px solid var(--ink); border-bottom: 1px solid var(--ink); padding: 8px 0; }
.review h3 { margin: 4px 0 0; font-family: var(--display); font-size: 19px; font-weight: 800; }
.review p { margin: 0; font-size: 16px; line-height: 1.6; }
.holes { display: grid; grid-template-columns: repeat(9, 1fr); gap: 3px; font-family: var(--sans); }
.holes div { text-align: center; border: 1px solid var(--rule); background: #fff; padding: 4px 0; }
.holes div b { display: block; font-size: 15px; }
.holes div small { display: block; font-size: 10px; color: var(--muted); }
.holes div i { display: block; font-style: normal; font-size: 10px; font-weight: 700; }
.holes .best { background: var(--done-bg); border-color: var(--done-line); }
.holes .worst { background: var(--bad-bg); border-color: var(--bad-line); }
.illus { background: var(--sage); border: 1px solid var(--rule); padding: 14px; display: flex; flex-direction: column; gap: 8px; }
.illus-label { align-self: flex-start; font-family: var(--sans); font-size: 10px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; background: var(--ink); color: var(--cream); padding: 3px 6px; }
.banter { background: #fff; border: 1.5px solid var(--ink); padding: 14px; display: flex; flex-direction: column; gap: 10px; }
.banter p { margin: 0; font-size: 16px; line-height: 1.6; }
.board { width: 100%; border-collapse: collapse; font-family: var(--sans); font-size: 14px; }
.board th { text-align: left; font-size: 10px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); border-bottom: 1px solid var(--ink); padding: 6px 4px; }
.board td { border-bottom: 1px solid var(--rule); padding: 8px 4px; }
.board td.n, .board th.n { text-align: right; }
.board tr.me td { background: var(--done-bg); font-weight: 700; }
.sponsor-para { border-top: 3px solid var(--ink); padding-top: 12px; font-size: 15px; line-height: 1.6; }
.lock { border: 1.5px solid var(--ink); background: #fff; padding: 16px; display: flex; flex-direction: column; gap: 12px; font-family: var(--sans); }
.lock ul { margin: 0; padding-left: 18px; font-size: 14px; line-height: 1.7; }
.passes { display: flex; flex-direction: column; gap: 8px; }
.pass { display: flex; align-items: center; gap: 12px; padding: 12px; border: 1.5px solid var(--rule); border-radius: 10px; background: #fff; text-align: left; font-family: var(--sans); color: var(--ink); }
.pass[aria-pressed="true"] { border-color: var(--leaf); box-shadow: inset 0 0 0 1px var(--leaf); background: var(--done-bg); }
.pass .grow { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.pass b { font-size: 15px; }
.pass small { font-size: 12px; color: var(--muted); }
.pass .price { font-weight: 800; font-size: 15px; white-space: nowrap; }
.reader-foot { margin-top: auto; padding: 16px; border-top: 1px solid var(--rule); font-family: var(--sans); font-size: 12px; display: flex; gap: 16px; flex-wrap: wrap; }

/* ---------- newsroom ---------- */
.nr { min-height: 100vh; background: var(--nr-bg); color: var(--nr-ink); font-family: var(--sans); display: flex; flex-direction: column; }
.nr-top { background: var(--green); color: #fff; padding: 14px clamp(16px, 3vw, 40px); display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; }
.nr-top .brand { display: flex; align-items: center; gap: 12px; }
.nr-top .brand b { font-family: var(--head); font-size: 17px; font-weight: 800; white-space: nowrap; }
.nr-top .brand span { font-size: 11px; color: var(--mist); border: 1px solid #3D6B58; border-radius: 4px; padding: 2px 6px; }
.nr-top nav { display: flex; flex-wrap: wrap; gap: 4px; }
.nr-top nav a { color: var(--mist); text-decoration: none; font-size: 14px; font-weight: 600; padding: 10px 12px; border-radius: 8px; }
.nr-top nav a[aria-current="page"] { background: rgba(255,255,255,.12); color: #fff; }
.nr-top .who { font-size: 13px; color: var(--mist); display: flex; align-items: center; gap: 10px; }
.nr-top .who button { background: none; border: 1px solid #3D6B58; color: #fff; border-radius: 8px; min-height: 36px; padding: 0 10px; font-size: 13px; }
.nr-main { padding: 24px clamp(16px, 3vw, 40px) 48px; display: flex; flex-direction: column; gap: 20px; max-width: 1280px; width: 100%; margin: 0 auto; }
.nr-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 12px; }
.nr-head h1 { margin: 0; font-family: var(--head); font-size: 26px; font-weight: 800; }
.nr-head p { margin: 4px 0 0; color: var(--nr-muted); font-size: 14px; }
.card { background: #fff; border: 1px solid var(--nr-line); border-radius: 14px; padding: 20px; display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.card h2 { margin: 0; font-family: var(--head); font-size: 18px; font-weight: 700; }
.pipeline { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 10px; }
.pipeline li { border: 1px solid var(--nr-line); border-radius: 12px; padding: 12px; display: flex; flex-direction: column; gap: 4px; }
.pipeline li.done { border-color: var(--done-line); background: var(--done-bg); color: var(--done-ink); }
.pipeline li.wait { border-color: var(--wait-line); background: var(--wait-bg); color: var(--wait-ink); }
.pipeline .num { font-size: 11px; font-weight: 700; color: var(--nr-muted); }
.pipeline .lbl { font-size: 14px; font-weight: 700; color: var(--nr-ink); }
.pipeline .val { font-family: var(--head); font-size: 22px; font-weight: 800; }
.pipeline .hint { font-size: 12px; line-height: 1.35; }
.table-wrap { overflow-x: auto; }
.tbl { width: 100%; border-collapse: collapse; font-size: 14px; }
.tbl th { text-align: left; font-size: 11px; letter-spacing: .06em; text-transform: uppercase; color: var(--nr-muted); padding: 8px; border-bottom: 1px solid var(--nr-line); white-space: nowrap; }
.tbl td { padding: 10px 8px; border-bottom: 1px solid var(--nr-line); vertical-align: middle; }
.chip { display: inline-flex; align-items: center; gap: 4px; padding: 3px 8px; border-radius: 999px; font-size: 12px; font-weight: 700; white-space: nowrap; border: 1px solid var(--nr-line); }
.chip.done { background: var(--done-bg); border-color: var(--done-line); color: var(--done-ink); }
.chip.wait { background: var(--wait-bg); border-color: var(--wait-line); color: var(--wait-ink); }
.chip.bad { background: var(--bad-bg); border-color: var(--bad-line); color: var(--bad-ink); }
.row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.cols { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 20px; }
.cols-side { display: grid; grid-template-columns: minmax(240px, 320px) minmax(0, 1fr); gap: 20px; align-items: start; }
.writers { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.writer { display: flex; gap: 10px; align-items: center; padding: 12px; border: 1.5px solid var(--nr-line); border-radius: 12px; background: #fff; text-align: left; color: var(--nr-ink); }
.writer[aria-pressed="true"] { border-color: var(--leaf); background: var(--done-bg); }
.writer small { display: block; color: var(--nr-muted); font-size: 12px; }
.scoregrid { border-collapse: collapse; font-size: 13px; }
.scoregrid th, .scoregrid td { border: 1px solid var(--nr-line); padding: 2px; text-align: center; }
.scoregrid th { background: #F1F4F2; font-size: 11px; padding: 4px; }
.scoregrid td.name { text-align: left; padding: 4px 8px; white-space: nowrap; font-weight: 600; }
.scoregrid input { width: 34px; height: 32px; border: 1px solid transparent; text-align: center; font-size: 14px; background: transparent; }
.scoregrid input:focus { border-color: var(--leaf); background: #fff; }
.scoregrid td.flag { background: var(--wait-bg); outline: 2px solid var(--wait-line); outline-offset: -2px; }
.scoregrid td.tot { font-weight: 700; background: #F7F9F8; padding: 4px 6px; }
.list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.pick { width: 100%; display: flex; flex-direction: column; gap: 3px; padding: 12px; border: 1.5px solid var(--nr-line); border-radius: 12px; background: #fff; text-align: left; color: var(--nr-ink); }
.pick[aria-pressed="true"] { border-color: var(--leaf); background: var(--done-bg); }
.pick small { color: var(--nr-muted); font-size: 12px; }
.wa { background: #E9E2D7; border-radius: 14px; padding: 14px; }
.wa-bubble { background: #fff; border-radius: 0 10px 10px 10px; padding: 10px 12px; white-space: pre-wrap; font-size: 14px; line-height: 1.45; max-width: 420px; box-shadow: 0 1px 1px rgba(0,0,0,.08); overflow-wrap: anywhere; }
.seg { display: inline-flex; border: 1px solid var(--nr-line); border-radius: 10px; overflow: hidden; }
.seg button { min-height: 36px; padding: 0 12px; border: 0; background: #fff; font-size: 13px; font-weight: 600; color: var(--nr-ink); }
.seg button + button { border-left: 1px solid var(--nr-line); }
.seg button[aria-pressed="true"] { background: var(--green); color: #fff; }
.stat { display: flex; flex-direction: column; gap: 4px; }
.stat b { font-family: var(--head); font-size: 28px; font-weight: 800; }
.stat span { font-size: 13px; color: var(--nr-muted); }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; }
.bars { display: flex; align-items: flex-end; gap: 8px; height: 140px; }
.bars div { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: 4px; font-size: 11px; color: var(--nr-muted); height: 100%; }
.bars div i { display: block; width: 100%; background: var(--leaf); border-radius: 4px 4px 0 0; min-height: 2px; }

/* ---------- sign-in and simple pages ---------- */
.narrow { max-width: 440px; margin: 0 auto; padding: 32px 16px 48px; display: flex; flex-direction: column; gap: 18px; font-family: var(--sans); }
.narrow h1 { margin: 0; font-family: var(--display); font-weight: 900; font-size: 40px; line-height: 1; }
.wordmark { font-family: var(--display); font-weight: 900; font-size: 30px; text-decoration: none; border-bottom: 4px solid var(--ink); padding-bottom: 8px; align-self: flex-start; }
.toggle { display: flex; gap: 12px; align-items: flex-start; padding: 12px 0; border-bottom: 1px solid var(--rule); font-size: 15px; }
.toggle input { width: 22px; height: 22px; accent-color: var(--leaf); margin-top: 1px; flex-shrink: 0; }

@media (max-width: 860px) {
  .cols, .cols-side { grid-template-columns: 1fr; }
}
@media (max-width: 480px) {
  .writers { grid-template-columns: 1fr; }
  .holes { grid-template-columns: repeat(6, 1fr); }
}

/* Long round names must not push the newsroom header wider than a phone. */
.nr-head > *, .nr-head .row, .nr-head label { min-width: 0; max-width: 100%; }
.nr-head label { flex-wrap: wrap; }
.nr-head select { max-width: 100%; text-overflow: ellipsis; }
