/* Layout: navy band with the next tournament as the hero, then a season timeline (Apr–Mar) and reference shelves below */
:root {
  --bg: #f4f6f9; --surface: #ffffff; --ink: #1b2436; --muted: #5a6478; --line: #dde2ea;
  --navy: #1f2f4d; --navy-deep: #16223a; --on-navy: #f4f6f9; --on-navy-muted: #b9c3d6;
  --red: #c8102e; --red-hover: #a50d26; --gold: #b8963e; --chip-bg: #e8ecf3;
  --open-bg: #fde8eb; --open-ink: #a50d26; --ok-bg: #e5f4ec; --ok-ink: #1f6b43;
  --c-kama: #c8102e; --c-pref: #1f2f4d; --c-kokusupo: #b8963e; --c-rec: #2a9fd6; --c-jr: #3aa66a; --c-indoor: #8a6fd1; --c-field: #8b6b3d; --c-city: #9aa3b3; --c-national: #5a6478;
  --f-display: "Zen Kaku Gothic New", "Hiragino Kaku Gothic ProN", "Yu Gothic", "Meiryo", sans-serif;
  --f-num: "Barlow Condensed", "Arial Narrow", "Helvetica Neue", sans-serif;
  --wrap: 1120px; --radius: 10px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0f1522; --surface: #182133; --ink: #e8ecf3; --muted: #a3adc0; --line: #2a3550;
    --navy: #1a2742; --navy-deep: #0b1120; --on-navy: #eef1f7; --on-navy-muted: #a9b4c9;
    --red: #e23a52; --red-hover: #f0566c; --gold: #d4b25c; --chip-bg: #222d44;
    --open-bg: #3a1820; --open-ink: #ff8f9f; --ok-bg: #16301f; --ok-ink: #7fd3a3;
    --c-kama: #e23a52; --c-pref: #8fa6d1; --c-kokusupo: #d4b25c; --c-field: #c49a5e;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0f1522; --surface: #182133; --ink: #e8ecf3; --muted: #a3adc0; --line: #2a3550;
  --navy: #1a2742; --navy-deep: #0b1120; --on-navy: #eef1f7; --on-navy-muted: #a9b4c9;
  --red: #e23a52; --red-hover: #f0566c; --gold: #d4b25c; --chip-bg: #222d44;
  --open-bg: #3a1820; --open-ink: #ff8f9f; --ok-bg: #16301f; --ok-ink: #7fd3a3;
  --c-kama: #e23a52; --c-pref: #8fa6d1; --c-kokusupo: #d4b25c; --c-field: #c49a5e;
  color-scheme: dark;
}
* { box-sizing: border-box; }
:root { padding-top: env(safe-area-inset-top, 0px); padding-bottom: env(safe-area-inset-bottom, 0px); }
html { scroll-behavior: smooth; scroll-padding-top: 76px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { transition: none !important; } }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: var(--f-display); font-size: 16px; line-height: 1.75; }
body::before { content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); z-index: 10; background: var(--navy-deep); }
img { max-width: 100%; }
[hidden] { display: none !important; }
a { color: inherit; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; border-radius: 4px; }
h1, h2, h3 { margin: 0; line-height: 1.35; text-wrap: balance; }
p { margin: 0; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); }
.num { font-family: var(--f-num); font-variant-numeric: tabular-nums; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.sample-unused { background: var(--gold); color: #1b1608; font-size: 12px; font-weight: 700; text-align: center; padding-block: 4px; letter-spacing: .08em; }

.site-header { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 20; background: var(--navy-deep); color: var(--on-navy); }
.site-header .wrap { display: flex; align-items: center; gap: 18px; min-height: 64px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; flex-shrink: 0; }
.brand svg { width: 34px; height: 34px; }
.brand b { font-weight: 900; font-size: 17px; display: block; line-height: 1.2; }
.brand small { display: block; font-family: var(--f-num); font-size: 11px; letter-spacing: .18em; color: var(--on-navy-muted); text-transform: uppercase; line-height: 1.2; }
.nav { display: flex; gap: 2px; margin-left: auto; overflow-x: auto; scrollbar-width: none; }
.nav a { text-decoration: none; font-size: 14px; font-weight: 500; padding: 8px 11px; border-radius: 6px; white-space: nowrap; color: var(--on-navy-muted); }
.nav a:hover, .nav a[aria-current] { color: var(--on-navy); background: rgba(255,255,255,.08); }
@media (max-width: 860px) { .site-header .wrap { flex-wrap: wrap; gap: 0 12px; padding-block: 8px 0; } .nav { width: 100%; margin-left: -11px; padding-bottom: 4px; } }

.btn { display: inline-flex; align-items: center; gap: 8px; text-decoration: none; font-weight: 700; font-size: 14px; border-radius: 8px; padding: 9px 16px; border: 2px solid transparent; transition: background .15s; }
.btn-red { background: var(--red); color: #fff; }
.btn-red:hover { background: var(--red-hover); }
.btn-ghost { border-color: rgba(255,255,255,.3); color: var(--on-navy); }
.btn-ghost:hover { background: rgba(255,255,255,.08); }

/* Hero: next tournament */
.hero { background: var(--navy); color: var(--on-navy); }
.hero .wrap { display: grid; grid-template-columns: 1fr 1.1fr; gap: 36px; align-items: center; padding-block: 44px; }
.crumb { font-size: 13px; color: var(--on-navy-muted); }
.crumb a { color: var(--on-navy-muted); }
.hero h1 { font-weight: 900; font-size: clamp(26px, 3.6vw, 38px); margin-top: 8px; }
.hero .lead { margin-top: 12px; color: var(--on-navy-muted); font-size: 15px; max-width: 32em; }
.stats { display: flex; flex-wrap: wrap; gap: 22px; margin-top: 22px; }
.stats div { display: grid; }
.stats b { font-family: var(--f-num); font-size: 30px; line-height: 1.1; }
.stats span { font-size: 12px; color: var(--on-navy-muted); }
.next { background: var(--navy-deep); border: 1px solid rgba(255,255,255,.1); border-radius: 12px; padding: 22px 24px; position: relative; overflow: hidden; min-width: 0; }
.next::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 6px; background: var(--red); }
.next .lbl { font-family: var(--f-num); font-weight: 600; letter-spacing: .2em; font-size: 12px; color: var(--gold); text-transform: uppercase; }
.next .when { display: flex; align-items: baseline; gap: 14px; margin-top: 6px; flex-wrap: wrap; }
.next .date { font-family: var(--f-num); font-weight: 700; font-size: 40px; line-height: 1; }
.next .date small { font-size: 18px; margin-left: 4px; }
.next .days { font-size: 14px; font-weight: 700; background: var(--red); color: #fff; border-radius: 99px; padding: 2px 12px; }
.next h2 { font-size: 21px; font-weight: 700; margin-top: 10px; }
.next .meta { font-size: 13px; color: var(--on-navy-muted); margin-top: 2px; }
.next .acts { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.next .later { margin-top: 16px; border-top: 1px solid rgba(255,255,255,.1); padding-top: 12px; display: grid; gap: 4px; font-size: 13px; color: var(--on-navy-muted); }
.next .later span b { font-family: var(--f-num); color: var(--on-navy); font-size: 15px; margin-right: 8px; }
@media (max-width: 860px) { .hero .wrap { grid-template-columns: 1fr; padding-block: 32px; } }

section.block { padding-block: 56px; }
section.block + section.block { border-top: 1px solid var(--line); }
.sec-head { display: flex; align-items: baseline; gap: 14px; margin-bottom: 22px; flex-wrap: wrap; }
.sec-head h2 { font-size: clamp(22px, 2.8vw, 28px); font-weight: 900; position: relative; padding-left: 18px; }
.sec-head h2::before { content: ""; position: absolute; left: 0; top: .2em; bottom: .2em; width: 6px; background: var(--red); border-radius: 2px; }
.sec-head .en { font-family: var(--f-num); font-weight: 600; letter-spacing: .2em; text-transform: uppercase; font-size: 13px; color: var(--muted); }
.sec-head .aside { margin-left: auto; font-size: 13px; color: var(--muted); }

/* Filters */
.filters { display: grid; gap: 12px; margin-bottom: 18px; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chips button { font: inherit; font-size: 13px; font-weight: 500; border: 1px solid var(--line); background: var(--surface); color: var(--ink); border-radius: 99px; padding: 5px 12px; cursor: pointer; display: inline-flex; gap: 6px; align-items: center; }
.chips button i { width: 8px; height: 8px; border-radius: 50%; }
.chips button b { font-family: var(--f-num); font-weight: 600; color: var(--muted); }
.chips button[aria-pressed="true"] { background: var(--navy); color: var(--on-navy); border-color: var(--navy); }
.chips button[aria-pressed="true"] b { color: var(--on-navy-muted); }
.row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.row select, .row input[type="search"] { font: inherit; font-size: 14px; padding: 7px 10px; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); color: var(--ink); max-width: 100%; }
.row input[type="search"] { width: 15em; }
.row label.tg { font-size: 14px; display: inline-flex; gap: 6px; align-items: center; cursor: pointer; }
.row .count { margin-left: auto; font-size: 13px; color: var(--muted); }

/* Season timeline */
.season { display: grid; gap: 26px; }
.month { display: grid; grid-template-columns: 74px minmax(0,1fr); gap: 16px; }
.month h3 { font-family: var(--f-num); font-weight: 700; font-size: 30px; line-height: 1; position: sticky; top: 84px; align-self: start; }
.month h3 small { display: block; font-family: var(--f-display); font-size: 12px; font-weight: 500; color: var(--muted); margin-top: 4px; }
.month.past h3 { color: var(--muted); }
.ev-list { display: grid; gap: 8px; }
.ev { background: var(--surface); border: 1px solid var(--line); border-left: 5px solid var(--c); border-radius: 8px; padding: 14px 18px; display: grid; grid-template-columns: 64px minmax(0,1fr); gap: 4px 16px; }
.ev.mine { background: color-mix(in srgb, var(--c-kama) 7%, var(--surface)); }
.ev.away { background: var(--bg); border-style: dashed; border-left-style: solid; }
.ev .d { white-space: nowrap; }
.ev .d { font-family: var(--f-num); font-weight: 700; font-size: 22px; line-height: 1.1; }
.ev .d small { display: block; font-family: var(--f-display); font-size: 12px; font-weight: 500; color: var(--muted); }
.ev .body { min-width: 0; }
.ev .top { display: flex; flex-wrap: wrap; gap: 6px 10px; align-items: center; }
.ev h4 { margin: 0; font-size: 16px; font-weight: 700; }
.ev .meta { font-size: 13px; color: var(--muted); }
.cat { font-size: 11px; font-weight: 700; padding: 2px 8px; border-radius: 4px; background: var(--chip-bg); color: var(--ink); white-space: nowrap; }
.state { font-size: 11px; font-weight: 700; padding: 2px 8px; border-radius: 99px; white-space: nowrap; }
.state.soon { background: var(--open-bg); color: var(--open-ink); }
.state.done { background: var(--ok-bg); color: var(--ok-ink); }
.links { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.links a { font-size: 12px; font-weight: 700; text-decoration: none; border: 1px solid var(--line); border-radius: 6px; padding: 4px 9px; display: inline-flex; gap: 6px; align-items: center; background: var(--bg); }
.links a:hover { border-color: var(--red); color: var(--red); }
.links a .k { font-family: var(--f-num); font-size: 11px; letter-spacing: .06em; color: var(--muted); }
.links a.ianseo { border-color: var(--navy); }
@media (max-width: 640px) {
  .month { grid-template-columns: 1fr; gap: 8px; }
  .month h3 { position: static; display: flex; gap: 8px; align-items: baseline; }
  .ev { grid-template-columns: 1fr; padding: 12px 14px; }
  .ev .d { display: flex; gap: 8px; align-items: baseline; font-size: 18px; }
}

/* News */
.news-wrap { display: grid; grid-template-columns: 220px minmax(0,1fr); gap: 24px; }
.side { display: grid; gap: 4px; align-content: start; position: sticky; top: 84px; }
.side button { font: inherit; font-size: 14px; text-align: left; border: 0; background: none; color: var(--muted); padding: 8px 12px; border-radius: 6px; cursor: pointer; display: flex; justify-content: space-between; gap: 8px; }
.side button b { font-family: var(--f-num); font-weight: 600; }
.side button[aria-pressed="true"] { background: var(--surface); color: var(--ink); font-weight: 700; box-shadow: inset 3px 0 0 var(--red); }
.posts { list-style: none; margin: 0; padding: 0; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.posts li { padding: 14px 20px; border-top: 1px solid var(--line); }
.posts li:first-child { border-top: 0; }
.posts .h { display: flex; gap: 10px; align-items: baseline; flex-wrap: wrap; }
.posts .h time { font-family: var(--f-num); font-weight: 600; color: var(--muted); font-size: 15px; }
.posts .h a.t { font-weight: 500; text-decoration: none; min-width: 0; }
.posts .h a.t:hover { text-decoration: underline; }
.posts .new { font-size: 11px; font-weight: 700; color: #fff; background: var(--red); border-radius: 4px; padding: 0 6px; }
.more { margin-top: 12px; text-align: center; }
.more button { font: inherit; font-size: 14px; font-weight: 700; border: 1px solid var(--line); background: var(--surface); color: var(--ink); border-radius: 8px; padding: 8px 20px; cursor: pointer; }
@media (max-width: 760px) { .news-wrap { grid-template-columns: 1fr; } .side { position: static; display: flex; overflow-x: auto; } .side button { white-space: nowrap; } .posts li { padding: 12px 14px; } }

/* Guidelines */
.yoko { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 10px; }
.yoko a { display: flex; gap: 12px; align-items: center; text-decoration: none; background: var(--surface); border: 1px solid var(--line); border-radius: 8px; padding: 12px 14px; min-width: 0; }
.yoko a:hover { border-color: var(--red); }
.pdf { flex-shrink: 0; width: 34px; height: 40px; border-radius: 4px; background: var(--red); color: #fff; font-family: var(--f-num); font-weight: 700; font-size: 12px; display: grid; place-items: center; }
.yoko span { font-size: 14px; font-weight: 500; min-width: 0; }

/* Records */
.rec-scroll { overflow-x: auto; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); max-height: 560px; overflow-y: auto; }
table.rec { border-collapse: collapse; width: 100%; min-width: 620px; font-size: 14px; }
.rec th, .rec td { text-align: left; padding: 10px 14px; border-bottom: 1px solid var(--line); }
.rec thead th { position: sticky; top: 0; background: var(--surface); font-size: 12px; color: var(--muted); font-weight: 500; z-index: 1; }
.rec td.dt { font-family: var(--f-num); font-weight: 600; white-space: nowrap; }
.rnd { display: inline-block; font-family: var(--f-num); font-weight: 600; font-size: 12px; background: var(--chip-bg); border-radius: 3px; padding: 0 6px; margin: 1px 2px 1px 0; }
.rec a { color: var(--red); font-weight: 700; font-size: 13px; white-space: nowrap; }

/* Clubs */
.clubs { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 8px; }
.clubs div { background: var(--surface); border: 1px solid var(--line); border-radius: 8px; padding: 12px 14px; font-size: 14px; font-weight: 500; }
.clubs div.mine { border-color: var(--red); box-shadow: inset 4px 0 0 var(--red); }
.clubs small { display: block; color: var(--muted); font-size: 12px; font-weight: 400; }
.note { margin-top: 14px; font-size: 13px; color: var(--muted); }
.note a { color: var(--red); }

footer { background: var(--navy-deep); color: var(--on-navy-muted); font-size: 13px; }
footer .wrap { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; padding-block: 22px; }
footer a { color: var(--on-navy); }

/* --- shared header CTA / footer nav (multi-page) --- */
.header-cta { padding: 9px 16px; font-size: 14px; flex-shrink: 0; }
.nav a[aria-current="page"] { color: var(--on-navy); background: rgba(255,255,255,.08); }
.foot-nav { display: flex; flex-wrap: wrap; gap: 16px; }
.foot-nav a { color: var(--on-navy); text-decoration: none; }
@media (max-width: 860px) { .header-cta { margin-left: auto; } .nav { order: 3; } }
@media (max-width: 480px) {
  .brand small { display: none; }
  .brand b { font-size: 15px; }
  .header-cta { padding: 7px 12px; font-size: 13px; }
}
.prerender { display: grid; gap: 8px; }
.prerender h3 { font-size: 16px; margin-top: 8px; }
.prerender ul { margin: 0; padding-left: 1.2em; }
.prerender time { font-family: var(--f-num); font-weight: 600; color: var(--muted); margin-right: 6px; }
.foot-mail { color: var(--on-navy); }
