/* ── Live Scoring section (homepage) ── */
#live {
	--hgc: #1f4f9e;          /* validated data colors: brighter than brand navy/green so small marks stay distinct */
	--wamp: #268a3e;
	--halved: #9a968c;
	--rule: #e0d8cc;
	--muted: #6b665d;
}
#live > .inner { width: 62rem; max-width: 100%; }
#live .live-pill {
	display: inline-flex; align-items: center; gap: 0.55em;
	font-family: var(--font-display); font-weight: 700; font-size: 0.72rem; letter-spacing: 0.16em; text-transform: uppercase;
	color: var(--navy); border: 1px solid var(--rule); background: #fff; padding: 0.45em 1em; margin: 0 0 1.25rem;
}
#live .live-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--halved); flex: none; }
#live[data-state="live"] .live-dot { background: #c22121; animation: live-pulse 1.6s ease-in-out infinite; }
#live[data-state="final"] .live-dot { background: var(--gold); }
@keyframes live-pulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(194,33,33,0.55); } 60% { box-shadow: 0 0 0 7px rgba(194,33,33,0); } }
@media (prefers-reduced-motion: reduce) { #live[data-state="live"] .live-dot { animation: none; } }

/* Scoreboard */
#live .sb { display: grid; grid-template-columns: 1fr auto 1fr; align-items: stretch; border: 1px solid var(--rule); background: #fff; text-align: left; }
#live .sb-team { padding: 1.1rem 1.4rem; display: flex; align-items: center; justify-content: space-between; gap: 1rem; border-top: 5px solid var(--hgc); }
#live .sb-team.wamp { border-top-color: var(--wamp); flex-direction: row-reverse; text-align: right; }
#live .sb-name { font-family: var(--font-display); font-weight: 700; letter-spacing: 0.08em; font-size: 1.05rem; color: var(--navy); margin: 0; line-height: 1.25; }
#live .sb-players { font-size: 0.85rem; color: var(--muted); margin: 0.2rem 0 0; line-height: 1.4; }
#live .sb-pts { font-family: var(--font-display); font-weight: 700; font-size: 3.6rem; line-height: 1; color: var(--navy); font-variant-numeric: tabular-nums; }
#live .sb-mid { display: flex; flex-direction: column; justify-content: center; align-items: center; padding: 0.8rem 1.4rem; background: var(--navy); color: #fff; min-width: 10.5rem; text-align: center; }
#live .sb-status { font-family: var(--font-display); font-weight: 700; font-size: 1.35rem; letter-spacing: 0.08em; color: #fff; line-height: 1.2; }
#live .sb-sub { font-size: 0.8rem; color: var(--gold); letter-spacing: 0.12em; text-transform: uppercase; font-family: var(--font-display); font-weight: 600; margin-top: 0.3rem; }

#live .live-h { font-family: var(--font-display); font-weight: 600; font-size: 0.8rem; letter-spacing: 0.16em; text-transform: uppercase; color: var(--muted); margin: 2rem 0 0.7rem; text-align: left; display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 0.4rem 1.2rem; }
#live .live-legend { display: flex; flex-wrap: wrap; gap: 0.3rem 1.1rem; font-family: var(--font-body); font-size: 0.8rem; letter-spacing: 0; text-transform: none; color: var(--ink); font-weight: 400; }
#live .live-legend span { display: inline-flex; align-items: center; gap: 0.4em; }
#live .sw { width: 11px; height: 11px; border-radius: 2px; flex: none; }
#live .sw.hgc { background: var(--hgc); }
#live .sw.wamp { background: var(--wamp); }
#live .sw.halved { background: var(--halved); height: 4px; border-radius: 2px; }

/* Hole-by-hole strip: the mark sits in the lane of the team that won the hole */
#live .strip { display: grid; grid-template-columns: 3.2rem repeat(18, minmax(0, 1fr)); gap: 2px; position: relative; }
#live .strip-label { font-family: var(--font-display); font-weight: 700; font-size: 0.7rem; letter-spacing: 0.08em; color: var(--navy); display: flex; align-items: center; }
#live .strip-cell { height: 1.9rem; background: #f4f1ea; border-radius: 3px; }
#live .strip-cell.won.hgc { background: var(--hgc); }
#live .strip-cell.won.wamp { background: var(--wamp); }
#live .strip-num { height: 1.5rem; display: flex; align-items: center; justify-content: center; font-family: var(--font-display); font-weight: 600; font-size: 0.72rem; color: var(--muted); position: relative; }
#live .strip-num.played { color: var(--ink); }
#live .strip-num.halved::after { content: ''; position: absolute; left: 18%; right: 18%; bottom: 1px; height: 3px; border-radius: 2px; background: var(--halved); }
#live .strip-num.next { color: var(--navy); box-shadow: inset 0 0 0 2px var(--gold); border-radius: 3px; }
#live .strip-col { position: absolute; top: 0; bottom: 0; cursor: default; background: transparent; border: 0; padding: 0; margin: 0; box-shadow: none; border-radius: 3px; height: auto; min-width: 0; max-width: none; line-height: 1; }
#live .strip-col:hover, #live .strip-col:focus-visible { background: rgba(13,34,53,0.08); outline: none; }

/* Match flow */
#live .flow svg { display: block; width: 100%; height: auto; overflow: visible; }
#live .flow text { font-family: var(--font-body); font-size: 12px; fill: var(--muted); }
#live .flow text.zone { font-family: var(--font-display); font-weight: 700; font-size: 11px; letter-spacing: 0.1em; }
#live .flow .hit { fill: transparent; }

/* Scorecard */
#live .card-wrap { overflow-x: auto; border: 1px solid var(--rule); background: #fff; }
#live table.card { width: 100%; min-width: 46rem; border-collapse: collapse; margin: 0; font-family: var(--font-body); font-size: 0.85rem; font-variant-numeric: tabular-nums; }
#live table.card tbody tr { background: none; border: 0; }
#live table.card th, #live table.card td { padding: 0.45em 0.3em; text-align: center; border: 0; border-bottom: 1px solid #efeae0; background: none; color: var(--ink); font-weight: 400; }
#live table.card thead th { background: var(--navy); color: var(--gold); font-family: var(--font-display); font-weight: 600; font-size: 0.72rem; letter-spacing: 0.06em; }
#live table.card th.rowh { text-align: left; padding-left: 0.8em; white-space: nowrap; font-weight: 700; position: sticky; left: 0; background: #fff; }
#live table.card thead th.rowh { background: var(--navy); }
#live table.card th.rowh .sw { display: inline-block; margin-right: 0.5em; }
#live table.card tr.meta td, #live table.card tr.meta th.rowh { color: var(--muted); font-size: 0.78rem; font-weight: 400; }
#live table.card tr.teamgap td, #live table.card tr.teamgap th { border-top: 2px solid var(--rule); }
#live table.card td.count { font-weight: 700; }
#live table.card td.count.hgc { box-shadow: inset 0 -3px 0 var(--hgc); }
#live table.card td.count.wamp { box-shadow: inset 0 -3px 0 var(--wamp); }
#live table.card td .under { display: inline-block; min-width: 1.55em; line-height: 1.45em; border: 1px solid currentColor; border-radius: 50%; }
#live .live-foot { font-size: 0.82rem; color: var(--muted); margin: 1.2rem 0 0; }
#live .live-note { font-style: italic; color: var(--ink); margin: 1rem 0 0; }
#live .live-body { position: relative; }
#live .live-tip { position: absolute; z-index: 20; pointer-events: none; background: var(--navy); color: #fff; font-size: 0.8rem; line-height: 1.45; padding: 0.55em 0.8em; border-radius: 3px; text-align: left; width: max-content; max-width: 15rem; box-shadow: 0 4px 14px rgba(0,0,0,0.25); }
#live .live-tip b { font-family: var(--font-display); letter-spacing: 0.06em; color: var(--gold); font-weight: 700; display: block; }

/* Match story */
#live .story-lede { text-align: left; font-size: 1.08rem; line-height: 1.6; margin: 0 0 1rem; color: var(--ink); }
#live .story { text-align: left; border: 1px solid var(--rule); background: #fff; }
#live .story-item { display: grid; grid-template-columns: 2.4rem minmax(0, 1fr); gap: 0.9rem; padding: 0.9rem 1rem; border-bottom: 1px solid #efeae0; }
#live .story-item:last-child { border-bottom: 0; }
#live .story-badge { width: 2.4rem; height: 2.4rem; border-radius: 3px; display: flex; align-items: center; justify-content: center; font-family: var(--font-display); font-weight: 700; font-size: 0.95rem; color: #fff; background: var(--halved); font-variant-numeric: tabular-nums; }
#live .story-badge.hgc { background: var(--hgc); }
#live .story-badge.wamp { background: var(--wamp); }
#live .story-badge.none { background: #fff; color: var(--muted); box-shadow: inset 0 0 0 1px var(--rule); }
#live .story-head { font-family: var(--font-display); font-weight: 700; font-size: 1rem; letter-spacing: 0.04em; color: var(--navy); margin: 0; line-height: 1.35; }
#live .story-hole { display: block; font-size: 0.68rem; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); }
#live .story-tag { display: inline-block; margin-left: 0.7em; padding: 0.1em 0.6em; font-size: 0.62rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--navy); border: 1px solid var(--gold); vertical-align: middle; }
#live .story-text { margin: 0.25rem 0 0; font-size: 0.95rem; line-height: 1.55; color: var(--ink); }
#live .story-more { -webkit-appearance: none; appearance: none; display: block; width: 100%; height: auto; max-width: none; margin: 0; padding: 0.8em 1em; line-height: 1.2; border: 1px solid var(--rule); border-top: 0; border-radius: 0; box-shadow: none; background: #fff; color: var(--navy); font-family: var(--font-display); font-weight: 600; font-size: 0.72rem; letter-spacing: 0.14em; text-transform: uppercase; cursor: pointer; white-space: normal; }
#live .story-more:hover, #live .story-more:focus-visible { background: var(--cream); color: var(--navy); box-shadow: none; }

@media (max-width: 736px) {
	#live .sb { grid-template-columns: 1fr 1fr; }
	#live .sb-mid { grid-column: 1 / -1; grid-row: 1; flex-direction: row; gap: 0.9rem; min-width: 0; padding: 0.6rem 1rem; }
	#live .sb-sub { margin-top: 0; }
	#live .sb-team { flex-direction: column; align-items: flex-start; padding: 0.9rem 1rem; gap: 0.5rem; }
	#live .sb-team.wamp { flex-direction: column; align-items: flex-end; }
	#live .sb-pts { font-size: 3rem; }
	#live .sb-name { font-size: 0.9rem; }
	#live .strip { grid-template-columns: repeat(18, minmax(0, 1fr)); }
	#live .strip-label { grid-column: 1 / -1; padding: 0.2rem 0; }
	#live .strip-cell { height: 1.6rem; }
	#live .strip-num { font-size: 0.62rem; }
}
