@charset "UTF-8";
/* ============================================================
   格付けリーグ — style.css
   方向: ダーク×発光(黒×ゴールド)。スタジアムナイターの空気。
   構成: 1.トークン → 2.ベース → 3.ヘッダー/ヒーロー → 4.ナビ
        → 5.ビュー共通 → 6.各ビュー → 7.モーダル/トースト → 8.モーション
   ============================================================ */

/* ---------- 1. トークン ---------- */
:root {
  --color-bg: #06080d;
  --color-bg-2: #0a0e16;
  --color-surface: #0f141d;
  --color-surface-2: #161d2a;
  --color-line: #1e2634;
  --color-line-strong: #2c3750;
  --color-text: #edf0f7;
  --color-muted: #8b94a8;
  --color-gold: #e8b84b;
  --color-gold-bright: #ffd97a;
  --color-gold-ink: #191203;
  --color-win: #46d47e;
  --color-draw: #93a0b4;
  --color-loss: #f06a6a;
  --color-danger: #e0492f;
  --color-yellow: #f5cf3c;

  --font-display: "Oswald", "Noto Sans JP", sans-serif;
  --font-body: "Noto Sans JP", "Hiragino Kaku Gothic ProN", "Yu Gothic", sans-serif;

  --space: 8px;
  --container: 1180px;
  --radius: 6px;

  --z-header: 100;
  --z-nav: 90;
  --z-modal: 1000;
  --z-toast: 1100;

  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
}

/* ---------- 2. ベース ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  color: var(--color-text);
  background:
    radial-gradient(1100px 480px at 50% -140px, rgba(232, 184, 75, 0.14), transparent 68%),
    repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.018) 0 1px, transparent 1px 96px),
    linear-gradient(180deg, var(--color-bg-2), var(--color-bg) 640px);
  background-color: var(--color-bg);
  line-height: 1.8;
  font-size: 15px;
  letter-spacing: 0.02em;
  -webkit-font-smoothing: antialiased;
  overflow-wrap: anywhere;
}

img, svg { max-width: 100%; display: block; }
a { color: inherit; }
button { font-family: inherit; }

:focus-visible {
  outline: 2px solid var(--color-gold);
  outline-offset: 2px;
}

h1, h2, h3 { line-height: 1.35; letter-spacing: 0.04em; }

input, select, button, textarea { font-size: 15px; }

input[type="text"], input[type="number"], select {
  background: var(--color-bg-2);
  border: 1px solid var(--color-line-strong);
  border-radius: var(--radius);
  color: var(--color-text);
  padding: 8px 10px;
  transition: border-color 0.25s;
}
input[type="text"]:focus, input[type="number"]:focus, select:focus {
  border-color: var(--color-gold);
  outline: none;
}
input[type="number"] { font-family: var(--font-display); font-variant-numeric: tabular-nums; }

::placeholder { color: #5b6478; }

/* ボタン */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 9px 18px;
  border-radius: var(--radius);
  border: 1px solid transparent;
  font-weight: 700;
  font-size: 13px;
  letter-spacing: 0.08em;
  cursor: pointer;
  transition: transform 0.2s var(--ease-out), box-shadow 0.2s, background 0.2s, border-color 0.2s;
}
.btn:active { transform: translateY(1px); }
.btn--gold {
  background: linear-gradient(160deg, var(--color-gold-bright), var(--color-gold));
  color: var(--color-gold-ink);
}
.btn--gold:hover { box-shadow: 0 0 22px rgba(232, 184, 75, 0.35); }
.btn--ghost {
  background: transparent;
  border-color: var(--color-line-strong);
  color: var(--color-text);
}
.btn--ghost:hover { border-color: var(--color-gold); color: var(--color-gold-bright); }
.btn--danger {
  background: transparent;
  border-color: rgba(224, 73, 47, 0.55);
  color: #ff8d75;
}
.btn--danger:hover { background: rgba(224, 73, 47, 0.12); }
.btn--mini { padding: 4px 10px; font-size: 12px; }

/* ---------- 3. ヘッダー / ヒーロー ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: var(--z-header);
  background: color-mix(in srgb, var(--color-bg) 82%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--color-line);
}
.site-header__inner {
  width: min(var(--container), 100% - 40px);
  margin-inline: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-block: 10px;
}
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; }
.brand__mark {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  background: linear-gradient(160deg, var(--color-gold-bright), var(--color-gold) 70%);
  color: var(--color-gold-ink);
  font-weight: 900;
  font-size: 22px;
  border-radius: 4px;
  box-shadow: 0 0 18px rgba(232, 184, 75, 0.35);
}
.brand__text { line-height: 1.2; }
.brand__name { display: block; font-weight: 900; font-size: 17px; letter-spacing: 0.1em; }
.brand__en {
  display: block;
  font-family: var(--font-display);
  font-size: 10px;
  letter-spacing: 0.34em;
  color: var(--color-gold);
}
.header-right { display: flex; flex-direction: column; align-items: flex-end; gap: 6px; }
.header-tools { display: flex; align-items: center; gap: 10px; }
.league-title {
  font-size: 13px;
  color: var(--color-muted);
  text-align: right;
  line-height: 1.4;
}

/* 同期ステータス・編集モード切替 */
.sync-status {
  font-size: 11px;
  color: var(--color-muted);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}
.sync-status::before {
  content: "";
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--color-muted);
  flex-shrink: 0;
}
.sync-status--ok::before { background: var(--color-win); box-shadow: 0 0 8px var(--color-win); }
.sync-status--busy::before { background: var(--color-gold); animation: syncPulse 1s ease-in-out infinite; }
.sync-status--dirty::before { background: var(--color-yellow); }
.sync-status--error::before { background: var(--color-loss); }
.sync-status--view::before { background: #5ea2ff; }
@keyframes syncPulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.25; } }

.league-title__season {
  display: block;
  font-family: var(--font-display);
  font-size: 11px;
  letter-spacing: 0.22em;
  color: var(--color-gold);
}

/* ヒーロー = スコアボード */
.hero {
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid var(--color-line);
}
/* assets/img/hero.(jpg|webp|png) を置くと自動で背景に採用される */
.hero__bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center 30%;
  opacity: 0;
  transition: opacity 1.2s var(--ease-out);
}
.hero__bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(6, 8, 13, 0.62), rgba(6, 8, 13, 0.55) 45%, rgba(6, 8, 13, 0.94) 92%),
    radial-gradient(900px 380px at 50% 0%, rgba(232, 184, 75, 0.16), transparent 70%);
}
.hero.has-image .hero__bg { opacity: 1; }
.hero.has-image .hero__watermark { -webkit-text-stroke-color: rgba(232, 184, 75, 0.2); }
.hero.has-image .hero__stats { background: color-mix(in srgb, var(--color-bg-2) 74%, transparent); backdrop-filter: blur(6px); }

/* リーグロゴ(assets/img/logo.(png|svg|webp) を置くと「格」マークと差し替わる) */
.brand__mark img { width: 100%; height: 100%; object-fit: cover; border-radius: 4px; }
.brand__mark.has-logo { background: var(--color-bg-2); box-shadow: 0 0 18px rgba(232, 184, 75, 0.25); }

/* チームエンブレム(チームカードからアップロード) */
.team-emblem {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  box-shadow: 0 0 0 1px var(--color-line-strong), 0 0 10px rgba(0, 0, 0, 0.5);
  vertical-align: middle;
}
.who__team .team-emblem { width: 15px; height: 15px; }
.team-card__name .team-emblem { width: 28px; height: 28px; }
.modal__score .team-emblem { width: 34px; height: 34px; }
.hero__watermark {
  position: absolute;
  inset-inline: 0;
  top: -6px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(96px, 17vw, 230px);
  letter-spacing: 0.06em;
  line-height: 1;
  text-align: center;
  color: transparent;
  -webkit-text-stroke: 1px rgba(232, 184, 75, 0.12);
  pointer-events: none;
  user-select: none;
  white-space: nowrap;
}
.hero__inner {
  position: relative;
  width: min(var(--container), 100% - 40px);
  margin-inline: auto;
  padding-block: clamp(48px, 7vw, 84px) clamp(36px, 5vw, 60px);
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 32px;
}
.hero__kicker {
  font-family: var(--font-display);
  font-size: 12px;
  letter-spacing: 0.42em;
  color: var(--color-gold);
  margin-bottom: 10px;
}
.hero__title {
  font-size: clamp(34px, 6vw, 58px);
  font-weight: 900;
  letter-spacing: 0.06em;
  text-shadow: 0 0 42px rgba(232, 184, 75, 0.25);
}
.hero__leader { margin-top: 14px; font-size: 14px; color: var(--color-muted); }
.hero__leader strong { color: var(--color-gold-bright); font-weight: 700; }

.hero__stats {
  display: flex;
  gap: 0;
  border: 1px solid var(--color-line-strong);
  border-radius: var(--radius);
  background: color-mix(in srgb, var(--color-surface) 78%, transparent);
  overflow: hidden;
}
.hero__stats .stat {
  padding: 16px 22px;
  border-left: 1px solid var(--color-line);
  min-width: 108px;
}
.hero__stats .stat:first-child { border-left: none; }
.hero__stats dt {
  font-size: 11px;
  letter-spacing: 0.14em;
  color: var(--color-muted);
  margin-bottom: 2px;
  white-space: nowrap;
}
.hero__stats dd { display: flex; align-items: baseline; gap: 4px; }
.stat__num {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 30px;
  line-height: 1.1;
  color: var(--color-text);
  font-variant-numeric: tabular-nums;
}
.stat__unit { font-family: var(--font-display); font-size: 13px; color: var(--color-muted); }

/* ---------- 3b. ニュース(自動で切り替わる横長スライド) ---------- */
.news {
  border-bottom: 1px solid var(--color-line);
  background: var(--color-bg-2);
}
.news[hidden] { display: none; }
.news__inner {
  width: min(var(--container), 100% - 40px);
  margin-inline: auto;
  padding-block: 18px 14px;
}
.news__viewport {
  position: relative;
  border: 1px solid var(--color-line-strong);
  border-radius: var(--radius);
  overflow: hidden;
  /* 画像の形に関わらず枠の大きさは常に一定 */
  aspect-ratio: 16 / 6;
  max-height: 380px;
  background: var(--color-surface);
}
.news-card {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: flex-end;
  text-decoration: none;
  opacity: 0;
  visibility: hidden;
  transform: scale(1.03);
  transition: opacity 0.9s var(--ease-out), transform 1.4s var(--ease-out), visibility 0.9s;
}
.news-card.is-active { opacity: 1; visibility: visible; transform: scale(1); }
.news-card:hover { opacity: 1; }
.news-card__bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  transition: transform 6s var(--ease-out);
}
.news-card.is-active .news-card__bg { transform: scale(1.06); }
.news-card__bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(6, 8, 13, 0.92) 12%, rgba(6, 8, 13, 0.55) 52%, rgba(6, 8, 13, 0.2));
}
/* ポスター(縦長)は全体を見せ、背後に同じ画像をぼかして敷く */
.news-card__blur {
  position: absolute;
  inset: -6%;
  background-size: cover;
  background-position: center;
  filter: blur(28px) saturate(1.1);
  opacity: 0.4;
}
/* 画像は常に全体表示。切り取らない */
.news-card__bg {
  background-size: contain;
  background-repeat: no-repeat;
}
.news-card--poster .news-card__bg::after { display: none; }
.news-card--poster { align-items: center; justify-content: center; }
.news-card--poster .news-card__body {
  max-width: min(560px, 92%);
  background: linear-gradient(180deg, transparent, rgba(6, 8, 13, 0.85));
  align-self: flex-end;
  width: 100%;
  border-radius: var(--radius);
}

/* 画像が無いニュースは金の光だけで見せる */
.news-card:not(.has-image) {
  background:
    radial-gradient(600px 220px at 12% 120%, rgba(232, 184, 75, 0.16), transparent 70%),
    var(--color-surface);
}
.news-card__body {
  position: relative;
  padding: clamp(18px, 3vw, 30px);
  max-width: min(620px, 76%);
  display: grid;
  gap: 6px;
}
.news-card__tag {
  justify-self: start;
  font-family: var(--font-display);
  font-size: 10px;
  letter-spacing: 0.24em;
  color: var(--color-gold-ink);
  background: linear-gradient(160deg, var(--color-gold-bright), var(--color-gold));
  padding: 3px 10px;
  border-radius: 3px;
  font-weight: 700;
}
.news-card__title {
  font-size: clamp(17px, 2.6vw, 27px);
  font-weight: 900;
  line-height: 1.35;
  color: var(--color-text);
  text-shadow: 0 2px 18px rgba(0, 0, 0, 0.85);
}
.news-card__text {
  font-size: clamp(12px, 1.5vw, 13.5px);
  color: #c3ccdb;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.85);
}
a.news-card:hover .news-card__title { color: var(--color-gold-bright); }

.news__dots { display: flex; justify-content: center; gap: 7px; margin-top: 10px; }
.news__dots:empty { display: none; }
.news__dots button {
  width: 26px;
  height: 4px;
  border-radius: 2px;
  border: none;
  padding: 0;
  background: var(--color-line-strong);
  cursor: pointer;
  transition: background 0.3s, width 0.3s var(--ease-out);
}
.news__dots button[aria-selected="true"] {
  background: var(--color-gold);
  width: 40px;
  box-shadow: 0 0 10px rgba(232, 184, 75, 0.5);
}

/* 設定タブのニュース管理 */
.settings-card--news { grid-column: 1 / -1; }
.news-form { display: grid; gap: 0; }
.news-form input[type="file"] { padding: 6px; font-size: 12px; }
.news-form__check {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12.5px;
  color: var(--color-muted);
  margin-bottom: 16px;
  cursor: pointer;
}
.news-admin { list-style: none; padding: 0; margin-top: 18px; display: grid; gap: 8px; }
.news-admin__empty { font-size: 12.5px; color: var(--color-muted); }
.news-admin__item {
  display: grid;
  grid-template-columns: 64px 1fr auto;
  align-items: center;
  gap: 12px;
  padding: 8px;
  background: var(--color-bg-2);
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
}
.news-admin__thumb {
  width: 64px; height: 36px;
  border-radius: 3px;
  background-size: cover;
  background-position: center;
  background-color: var(--color-surface-2);
}
.news-admin__thumb--none { border: 1px dashed var(--color-line-strong); }
.news-admin__text { display: grid; gap: 2px; min-width: 0; }
.news-admin__text strong { font-size: 13px; font-weight: 700; }
.news-admin__text small { font-size: 11.5px; color: var(--color-muted); }
.news-admin__actions { display: flex; gap: 6px; }

/* ---------- 4. タブナビ ---------- */
.tab-nav {
  position: sticky;
  top: var(--header-h, 61px);
  z-index: var(--z-nav);
  background: color-mix(in srgb, var(--color-bg) 88%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--color-line);
}
.tab-nav__inner {
  width: min(var(--container), 100% - 40px);
  margin-inline: auto;
  display: flex;
  gap: 4px;
  overflow-x: auto;
  scrollbar-width: none;
}
.tab-nav__inner::-webkit-scrollbar { display: none; }
.tab-nav a {
  flex-shrink: 0;
  padding: 13px 16px 11px;
  font-size: 13.5px;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--color-muted);
  text-decoration: none;
  border-bottom: 2px solid transparent;
  transition: color 0.2s;
}
.tab-nav a:hover { color: var(--color-text); }
.tab-nav a[aria-current="page"] {
  color: var(--color-gold-bright);
  border-bottom-color: var(--color-gold);
  text-shadow: 0 0 16px rgba(232, 184, 75, 0.5);
}

/* ---------- 5. ビュー共通 ---------- */
.app {
  width: min(var(--container), 100% - 40px);
  margin-inline: auto;
  padding-block: clamp(32px, 5vw, 56px) 80px;
  min-height: 55vh;
}
.view-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 24px;
}
.view-head__title { font-size: clamp(21px, 3vw, 27px); font-weight: 900; }
.view-head__en {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 12px;
  letter-spacing: 0.3em;
  color: var(--color-gold);
  margin-left: 10px;
}
.view-head__note { font-size: 12.5px; color: var(--color-muted); }
.view-head__actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.cycle-field {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12.5px;
  color: var(--color-muted);
}
.cycle-field input { width: 58px; text-align: center; padding: 6px 4px; }

.table-scroll { overflow-x: auto; border: 1px solid var(--color-line); border-radius: var(--radius); }

table { border-collapse: collapse; width: 100%; background: var(--color-surface); }
th, td { padding: 10px 12px; white-space: nowrap; }
thead th {
  font-size: 11.5px;
  letter-spacing: 0.12em;
  color: var(--color-muted);
  font-weight: 500;
  border-bottom: 1px solid var(--color-line-strong);
  background: var(--color-bg-2);
  text-align: center;
}
tbody td { border-bottom: 1px solid var(--color-line); text-align: center; }
tbody tr:last-child td { border-bottom: none; }
tbody tr { transition: background 0.2s; }
tbody tr:hover { background: rgba(232, 184, 75, 0.05); }

.num {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 16px;
  font-variant-numeric: tabular-nums;
}

.team-cell { display: flex; align-items: center; gap: 10px; text-align: left; }
.team-dot {
  width: 10px; height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
  box-shadow: 0 0 8px currentColor;
}
.team-cell__name { font-weight: 700; }
.team-cell__stack { display: grid; gap: 1px; min-width: 0; }
.team-cell__user {
  font-size: 10.5px;
  font-weight: 400;
  color: var(--color-muted);
  letter-spacing: 0.04em;
  line-height: 1.3;
}
.team-meta { grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); }

.empty-note {
  padding: 28px;
  text-align: center;
  color: var(--color-muted);
  border: 1px dashed var(--color-line-strong);
  border-radius: var(--radius);
  margin-top: 16px;
}

/* ---------- 6a. 順位表 ---------- */
.standings-table .col-team { text-align: left; }
.standings-table td.col-rank { font-family: var(--font-display); font-weight: 600; font-size: 17px; }
.standings-table td.col-pts .num { font-size: 19px; color: var(--color-gold-bright); }
.standings-table tr.is-first {
  background: linear-gradient(90deg, rgba(232, 184, 75, 0.12), transparent 65%);
}
.standings-table tr.is-first td { border-bottom-color: rgba(232, 184, 75, 0.3); }
.standings-table tr.is-first .team-cell__name { text-shadow: 0 0 18px rgba(232, 184, 75, 0.55); }

.grade-chip {
  display: inline-grid;
  place-items: center;
  min-width: 30px;
  height: 24px;
  padding-inline: 6px;
  border-radius: 4px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 14px;
  letter-spacing: 0.05em;
  border: 1px solid var(--color-line-strong);
  color: var(--color-muted);
}
.grade-chip--s {
  background: linear-gradient(160deg, var(--color-gold-bright), var(--color-gold));
  color: var(--color-gold-ink);
  border-color: transparent;
  box-shadow: 0 0 16px rgba(232, 184, 75, 0.45);
  animation: gradePulse 2.6s ease-in-out infinite;
}
.grade-chip--a { color: #dfe5f0; border-color: #55627e; background: rgba(85, 98, 126, 0.18); }
.grade-chip--b { color: #c8a27c; border-color: #7d6248; background: rgba(125, 98, 72, 0.16); }

@keyframes gradePulse {
  0%, 100% { box-shadow: 0 0 10px rgba(232, 184, 75, 0.35); }
  50% { box-shadow: 0 0 24px rgba(232, 184, 75, 0.65); }
}

.form-dots { display: inline-flex; gap: 4px; }
.form-dot {
  width: 18px; height: 18px;
  display: inline-grid;
  place-items: center;
  border-radius: 3px;
  font-size: 10.5px;
  font-weight: 700;
}
.form-dot--w { background: rgba(70, 212, 126, 0.18); color: var(--color-win); }
.form-dot--d { background: rgba(147, 160, 180, 0.16); color: var(--color-draw); }
.form-dot--l { background: rgba(240, 106, 106, 0.15); color: var(--color-loss); }

/* 無失点(クリーンシート)・連勝連敗チップ */
.cs-chip {
  display: inline-grid;
  place-items: center;
  min-width: 24px;
  height: 22px;
  padding-inline: 5px;
  border-radius: 4px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 13px;
  color: #7fe0ff;
  background: rgba(127, 224, 255, 0.12);
  border: 1px solid rgba(127, 224, 255, 0.3);
}
.streak-chip {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}
.streak-chip--w { color: var(--color-win); background: rgba(70, 212, 126, 0.14); border: 1px solid rgba(70, 212, 126, 0.4); }
.streak-chip--l { color: var(--color-loss); background: rgba(240, 106, 106, 0.13); border: 1px solid rgba(240, 106, 106, 0.4); }
.streak-chip--d { color: var(--color-draw); background: rgba(147, 160, 180, 0.13); border: 1px solid rgba(147, 160, 180, 0.35); }

/* パネル(順位表タブ・ランキングタブの下に続く追加ブロック) */
.panel { margin-top: 40px; }
.panel__head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 14px;
}
.panel__title { font-size: 18px; font-weight: 900; }
.panel__note { font-size: 12.5px; color: var(--color-muted); }

/* 順位変動グラフ */
.rankchart {
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
  background: var(--color-surface);
  padding: 12px 8px;
  overflow-x: auto;
}
.rankchart svg { width: 100%; min-width: 620px; height: auto; display: block; }
.rc-grid { stroke: var(--color-line); stroke-width: 1; }
.rc-axis { fill: var(--color-muted); font-size: 11px; font-family: var(--font-display); }
.rc-axis--title { fill: var(--color-gold); letter-spacing: 0.1em; }
.rc-line {
  stroke-width: 2.5;
  stroke-linejoin: round;
  stroke-linecap: round;
  opacity: 0.85;
  stroke-dasharray: 1400;
  stroke-dashoffset: 1400;
  animation: rcDraw 1.4s var(--ease-out) forwards;
  animation-delay: var(--rc-delay, 0s);
}
@keyframes rcDraw { to { stroke-dashoffset: 0; } }
.rc-dot { opacity: 0; animation: rcDot 0.4s var(--ease-out) forwards; animation-delay: calc(var(--rc-delay, 0s) + 0.9s); }
@keyframes rcDot { to { opacity: 1; } }
.rc-label {
  font-size: 12px;
  font-weight: 700;
  opacity: 0;
  animation: rcDot 0.5s var(--ease-out) forwards;
  animation-delay: calc(var(--rc-delay, 0s) + 1.1s);
}
.rc-series { transition: opacity 0.25s; }
.rankchart:hover .rc-series { opacity: 0.28; }
.rankchart .rc-series:hover { opacity: 1; }
.rankchart .rc-series:hover .rc-line { stroke-width: 3.5; filter: drop-shadow(0 0 8px var(--rc-color)); }

/* ホーム/アウェイ別 */
.ha-table .col-team { text-align: left; }
.ha-group {
  font-family: var(--font-display);
  letter-spacing: 0.2em;
  font-size: 11px;
}
.ha-group--home { color: var(--color-gold); border-bottom: 2px solid rgba(232, 184, 75, 0.4); }
.ha-group--away { color: #7fe0ff; border-bottom: 2px solid rgba(127, 224, 255, 0.35); }
.ha-cell--home { background: rgba(232, 184, 75, 0.035); }
.ha-cell--away { background: rgba(127, 224, 255, 0.03); }
.ha-cell--pts { font-size: 17px; }
.ha-table td.ha-cell--home.ha-cell--pts { color: var(--color-gold-bright); }
.ha-table td.ha-cell--away.ha-cell--pts { color: #7fe0ff; }
.ha-cell--unbeaten { position: relative; }
.ha-cell--unbeaten::after {
  content: "無敗";
  position: absolute;
  top: 2px; right: 3px;
  font-family: var(--font-body);
  font-size: 8.5px;
  letter-spacing: 0;
  opacity: 0.75;
}

/* ---------- 6b. 対戦表 ---------- */
.cross-table th.cross-side { text-align: left; }
.cross-table td.cross-diag { background: var(--color-bg-2); }
.cross-table td.cross-diag::after { content: ""; display: block; height: 2px; width: 22px; margin-inline: auto; background: var(--color-line-strong); }
.cross-score {
  display: inline-block;
  min-width: 46px;
  padding: 3px 8px;
  border-radius: 4px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 14.5px;
  font-variant-numeric: tabular-nums;
  text-decoration: none;
  transition: box-shadow 0.2s;
}
.cross-score + .cross-score { margin-top: 4px; }
.cross-score--w { background: rgba(70, 212, 126, 0.14); color: var(--color-win); }
.cross-score--d { background: rgba(147, 160, 180, 0.14); color: var(--color-draw); }
.cross-score--l { background: rgba(240, 106, 106, 0.13); color: var(--color-loss); }
.cross-score--tbd { background: transparent; color: #525c70; border: 1px dashed var(--color-line-strong); }
.cross-score:hover { box-shadow: 0 0 0 1px var(--color-gold); }
.legend {
  display: inline-block;
  padding: 1px 8px;
  border-radius: 3px;
  font-size: 11px;
  margin-left: 6px;
}
.legend--win { background: rgba(70, 212, 126, 0.14); color: var(--color-win); }
.legend--draw { background: rgba(147, 160, 180, 0.14); color: var(--color-draw); }
.legend--loss { background: rgba(240, 106, 106, 0.13); color: var(--color-loss); }

/* 相性分析 */
.h2h { margin-top: 40px; }
.h2h__head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
}
.h2h__title { font-size: 18px; font-weight: 900; }
.h2h__picker { font-size: 12.5px; color: var(--color-muted); display: flex; align-items: center; gap: 8px; }
.h2h__picker select { min-width: 180px; }

.h2h__summary {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 24px;
  padding: 14px 18px;
  margin-bottom: 16px;
  background: linear-gradient(100deg, rgba(232, 184, 75, 0.1), var(--color-surface) 55%);
  border: 1px solid var(--color-line-strong);
  border-left: 3px solid var(--color-gold);
  border-radius: var(--radius);
}
.h2h__summary-team { display: flex; align-items: center; gap: 10px; font-size: 15px; }
.h2h__summary-rate { font-size: 13px; color: var(--color-muted); }
.h2h__summary-rate b {
  font-family: var(--font-display);
  font-size: 24px;
  color: var(--color-gold-bright);
  margin-inline: 4px;
  font-variant-numeric: tabular-nums;
}
.h2h__summary-wdl { font-size: 12.5px; color: var(--color-muted); margin-left: auto; }

.h2h-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 12px; }
.h2h-card {
  padding: 14px 16px;
  background: var(--color-surface);
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
  transition: border-color 0.25s, transform 0.25s var(--ease-out);
}
.h2h-card:hover { transform: translateY(-2px); border-color: var(--color-line-strong); }
.h2h-card--good { border-left: 3px solid var(--color-win); }
.h2h-card--even { border-left: 3px solid var(--color-draw); }
.h2h-card--bad { border-left: 3px solid #e8a44b; }
.h2h-card--worst { border-left: 3px solid var(--color-loss); }
.h2h-card--none { border-left: 3px solid var(--color-line-strong); }

.h2h-card__top { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 10px; }
.h2h-card__opp { display: flex; align-items: center; gap: 8px; font-weight: 700; font-size: 13.5px; min-width: 0; }
.h2h-card__opp span:not(.team-dot) { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.h2h-card__badge {
  flex-shrink: 0;
  padding: 2px 9px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
}
.h2h-card__badge--good { color: var(--color-win); background: rgba(70, 212, 126, 0.14); }
.h2h-card__badge--even { color: var(--color-draw); background: rgba(147, 160, 180, 0.14); }
.h2h-card__badge--bad { color: #e8a44b; background: rgba(232, 164, 75, 0.14); }
.h2h-card__badge--worst { color: var(--color-loss); background: rgba(240, 106, 106, 0.14); }
.h2h-card__badge--none { color: var(--color-muted); border: 1px solid var(--color-line-strong); }

.h2h-card__rate { display: flex; align-items: baseline; gap: 4px; margin-bottom: 8px; flex-wrap: wrap; }
.h2h-card__num {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 30px;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}
.h2h-card__pct { font-family: var(--font-display); font-size: 13px; color: var(--color-muted); }
.h2h-card__wdl { font-size: 11.5px; color: var(--color-muted); margin-left: auto; }
.h2h-card--good .h2h-card__num { color: var(--color-win); }
.h2h-card--worst .h2h-card__num { color: var(--color-loss); }
.h2h-card--bad .h2h-card__num { color: #e8a44b; }

.h2h-bar {
  display: flex;
  height: 6px;
  border-radius: 3px;
  overflow: hidden;
  background: rgba(240, 106, 106, 0.28);
  margin-bottom: 8px;
}
.h2h-bar__w { background: var(--color-win); }
.h2h-bar__d { background: var(--color-draw); opacity: 0.6; }
.h2h-card__form { font-size: 11px; color: var(--color-muted); display: flex; align-items: center; gap: 6px; }
.h2h-card__form .form-dot { width: 16px; height: 16px; font-size: 9.5px; }
.h2h-card__none { font-size: 12.5px; color: var(--color-muted); padding-block: 6px; }

/* ---------- 6c. 日程・結果 ---------- */
.round-filter { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 20px; }
.round-filter button {
  padding: 6px 14px;
  border-radius: 999px;
  border: 1px solid var(--color-line-strong);
  background: transparent;
  color: var(--color-muted);
  font-size: 12.5px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
}
.round-filter button:hover { border-color: var(--color-gold); color: var(--color-text); }
.round-filter button[aria-pressed="true"] {
  background: var(--color-gold);
  border-color: var(--color-gold);
  color: var(--color-gold-ink);
}

.round-group { margin-bottom: 28px; }
.round-group__title {
  display: flex;
  align-items: center;
  gap: 14px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 15px;
  letter-spacing: 0.18em;
  color: var(--color-gold);
  margin-bottom: 10px;
}
.round-group__title::after { content: ""; flex: 1; height: 1px; background: linear-gradient(90deg, var(--color-line-strong), transparent); }

/* 左右の側柱を同じ幅にしてスコアを必ず中央に置く */
.match-card {
  display: grid;
  grid-template-columns: 88px minmax(0, 1fr) auto minmax(0, 1fr) 88px;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  background: var(--color-surface);
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
  margin-bottom: 8px;
  transition: border-color 0.25s, box-shadow 0.25s;
}
.match-card:hover { border-color: var(--color-line-strong); }
/* 練習試合は色を落として公式戦と区別する */
.match-card--friendly { border-style: dashed; background: color-mix(in srgb, var(--color-surface) 70%, transparent); }
.round-group--friendly .round-group__title { color: #7fe0ff; }
.round-group--friendly .round-group__title::after { background: linear-gradient(90deg, rgba(127, 224, 255, 0.35), transparent); }
.manual-add__note { font-size: 11.5px; color: var(--color-muted); margin-top: 10px; }
.manual-add__form select { min-width: 130px; }

/* 節が多いときのプルダウン */
.round-picker { display: inline-flex; align-items: center; gap: 8px; font-size: 12.5px; color: var(--color-muted); }
.round-picker select { min-width: 150px; }
.player-row__actions { display: flex; gap: 6px; justify-content: flex-end; }
.player-row__actions .btn { white-space: nowrap; }
.match-card.is-highlight { border-color: var(--color-gold); box-shadow: 0 0 24px rgba(232, 184, 75, 0.25); }
.match-card__team { display: flex; align-items: center; gap: 10px; font-weight: 700; min-width: 0; }
.match-card__team--home { justify-content: flex-end; text-align: right; }
.match-card__team span:not(.team-dot) { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.match-card__score { display: flex; align-items: center; gap: 6px; }
.match-card__score input {
  width: 52px;
  text-align: center;
  font-size: 20px;
  font-weight: 600;
  padding: 5px 4px;
}
.match-card__score .vs { font-family: var(--font-display); color: var(--color-muted); font-size: 13px; }
.match-card--done .match-card__score input { border-color: var(--color-line); background: var(--color-bg); color: var(--color-gold-bright); }
.match-card__side { display: flex; align-items: center; }
.match-card__side--left { justify-content: flex-start; }
.match-card__side--right { justify-content: flex-end; }
.match-card__events { font-size: 10.5px; line-height: 1.5; color: var(--color-muted); }

.manual-add { margin-top: 24px; color: var(--color-muted); }
.manual-add summary { cursor: pointer; font-size: 13px; }
.manual-add summary:hover { color: var(--color-gold-bright); }
.manual-add__form {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  align-items: flex-end;
  padding: 16px;
  margin-top: 10px;
  background: var(--color-surface);
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
}
.manual-add__form label { display: grid; gap: 4px; font-size: 12px; }
.manual-add__form input[type="number"] { width: 72px; }

/* ---------- 6d. ランキング ---------- */
.ranking-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 24px;
}
.ranking-block {
  background: var(--color-surface);
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
  padding: 22px;
}
.ranking-block__title {
  font-size: 16px;
  font-weight: 900;
  padding-bottom: 12px;
  margin-bottom: 6px;
  border-bottom: 1px solid var(--color-line-strong);
}
.ranking-list { list-style: none; padding: 0; }
.ranking-list li {
  display: grid;
  grid-template-columns: 38px 1fr auto;
  align-items: center;
  gap: 12px;
  padding: 10px 4px;
  border-bottom: 1px solid var(--color-line);
  position: relative;
}
.ranking-list li:last-child { border-bottom: none; }
.ranking-list .rk {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 18px;
  color: var(--color-muted);
  text-align: center;
}
.ranking-list li.is-top .rk { color: var(--color-gold-bright); text-shadow: 0 0 14px rgba(232, 184, 75, 0.6); }
.ranking-list .who { min-width: 0; }
.ranking-list .who__name { font-weight: 700; display: block; line-height: 1.4; }
.ranking-list .who__team { font-size: 11.5px; color: var(--color-muted); display: flex; align-items: center; gap: 6px; }
.ranking-list .who__team .team-dot { width: 7px; height: 7px; }
.ranking-list .val {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 22px;
  font-variant-numeric: tabular-nums;
}
.ranking-list .bar {
  position: absolute;
  left: 0; bottom: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--color-gold), transparent);
  opacity: 0.55;
}
.ranking-list .empty {
  grid-column: 1 / -1;          /* 1列目(38px)に押し込まれて縦書きになるのを防ぐ */
  color: var(--color-muted);
  font-size: 13px;
  padding: 14px 4px;
  display: block;
  line-height: 1.7;
}
.ranking-block__sub {
  font-family: var(--font-display);
  font-size: 10.5px;
  letter-spacing: 0.16em;
  color: var(--color-gold);
  margin-left: 8px;
  padding: 2px 8px;
  border: 1px solid rgba(232, 184, 75, 0.4);
  border-radius: 999px;
  vertical-align: 2px;
}
/* G+Aは実質MVP指標なので一段格上げして見せる */
.ranking-block--hero {
  grid-column: 1 / -1;
  background: linear-gradient(150deg, rgba(232, 184, 75, 0.09), var(--color-surface) 55%);
  border-color: var(--color-line-strong);
  border-top: 2px solid var(--color-gold);
}
.ranking-block--hero .ranking-list li.is-top .who__name { font-size: 17px; text-shadow: 0 0 18px rgba(232, 184, 75, 0.4); }
.ranking-block--hero .ranking-list li.is-top .val { color: var(--color-gold-bright); }

/* リーグ記録 */
.records { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 16px; }
.record-card {
  padding: 20px;
  background: var(--color-surface);
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
  position: relative;
  overflow: hidden;
}
.record-card::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 3px;
  background: linear-gradient(180deg, var(--color-gold), transparent);
}
.record-card__label {
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.08em;
  margin-bottom: 10px;
  display: flex;
  align-items: baseline;
  gap: 8px;
  flex-wrap: wrap;
}
.record-card__sub {
  font-family: var(--font-display);
  font-size: 9.5px;
  letter-spacing: 0.24em;
  color: var(--color-gold);
  font-weight: 600;
}
.record-card__big {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 46px;
  line-height: 1;
  color: var(--color-gold-bright);
  text-shadow: 0 0 30px rgba(232, 184, 75, 0.3);
  margin-bottom: 14px;
  font-variant-numeric: tabular-nums;
}
.record-card__big small { font-family: var(--font-body); font-size: 13px; color: var(--color-muted); margin-left: 6px; text-shadow: none; }
.record-card__match {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 8px;
  padding-top: 12px;
  border-top: 1px solid var(--color-line);
  font-size: 12.5px;
}
.record-card__side { display: flex; align-items: center; gap: 6px; min-width: 0; }
.record-card__side:last-of-type { justify-content: flex-end; }
.record-card__side span:not(.team-dot):not(.team-emblem) { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.record-card__score {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 18px;
  font-variant-numeric: tabular-nums;
}
.record-card__meta { font-size: 11px; color: var(--color-muted); margin-top: 8px; }
.record-card__hint { font-size: 11.5px; color: var(--color-muted); margin-bottom: 12px; }

.timing-row { display: grid; grid-template-columns: 74px 1fr 34px; align-items: center; gap: 10px; margin-bottom: 8px; }
.timing-row__label { font-size: 12px; font-weight: 700; }
.timing-row__label small { display: block; font-size: 10px; font-weight: 400; color: var(--color-muted); }
.timing-row__bar { height: 8px; border-radius: 4px; background: var(--color-bg); overflow: hidden; }
.timing-row__bar span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, var(--color-gold), var(--color-gold-bright));
  box-shadow: 0 0 10px rgba(232, 184, 75, 0.4);
  transition: width 0.7s var(--ease-out);
}
.timing-row__num {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 15px;
  text-align: right;
  font-variant-numeric: tabular-nums;
}

/* ゴール時間・出場数の入力 */
.event-row__foot { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.minute-field { display: flex; align-items: center; gap: 4px; font-size: 11px; color: var(--color-muted); }
.minute-field input { width: 56px; padding: 4px 6px; font-size: 12.5px; text-align: center; }
.og-check { font-size: 11px; color: var(--color-muted); display: flex; gap: 4px; align-items: center; }
.apps-input {
  width: 52px;
  padding: 3px 6px !important;
  font-size: 12px !important;
  text-align: center;
}

/* ---------- 6e. 警告・出場停止 ---------- */
.suspension-board { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; margin-bottom: 24px; }
.suspension-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  border-radius: var(--radius);
  background: linear-gradient(120deg, rgba(224, 73, 47, 0.16), var(--color-surface) 70%);
  border: 1px solid rgba(224, 73, 47, 0.5);
}
.suspension-card__icon {
  width: 30px; height: 40px;
  border-radius: 4px;
  background: linear-gradient(160deg, #ff6b4a, var(--color-danger));
  box-shadow: 0 0 18px rgba(224, 73, 47, 0.5);
  flex-shrink: 0;
}
.suspension-card__icon--y { background: linear-gradient(160deg, #ffe27a, var(--color-yellow)); box-shadow: 0 0 18px rgba(245, 207, 60, 0.4); }
.suspension-card__name { font-weight: 900; }
.suspension-card__detail { font-size: 12px; color: var(--color-muted); }
.suspension-card__detail strong { color: #ff9d88; }
.suspension-none {
  grid-column: 1 / -1;
  padding: 16px;
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
  color: var(--color-muted);
  font-size: 13px;
  background: var(--color-surface);
}

.card-chip {
  display: inline-block;
  width: 11px; height: 15px;
  border-radius: 2px;
  margin-right: 6px;
  vertical-align: -2px;
}
.card-chip--y { background: var(--color-yellow); }
.card-chip--r { background: var(--color-danger); }

.discipline-table td:first-child { text-align: left; font-weight: 700; }
.discipline-table td:nth-child(2) { text-align: left; }
.status-chip {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 999px;
  font-size: 11.5px;
  font-weight: 700;
}
.status-chip--ok { color: var(--color-muted); border: 1px solid var(--color-line-strong); }
.status-chip--warn { color: var(--color-yellow); background: rgba(245, 207, 60, 0.1); border: 1px solid rgba(245, 207, 60, 0.4); }
.status-chip--out { color: #ff8d75; background: rgba(224, 73, 47, 0.12); border: 1px solid rgba(224, 73, 47, 0.55); }

/* ---------- 6f. チーム・選手 ---------- */
.team-add {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  align-items: center;
  padding: 18px;
  background: var(--color-surface);
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
  margin-bottom: 24px;
}
.team-add input[type="text"] { flex: 1 1 220px; }
.color-picker { display: flex; gap: 6px; flex-wrap: wrap; }
.color-swatch {
  width: 26px; height: 26px;
  border-radius: 50%;
  border: 2px solid transparent;
  cursor: pointer;
  padding: 0;
  background-clip: padding-box;
  transition: transform 0.15s, border-color 0.15s;
}
.color-swatch:hover { transform: scale(1.15); }
.color-swatch[aria-checked="true"] { border-color: #fff; box-shadow: 0 0 10px currentColor; }

.team-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(330px, 1fr)); gap: 18px; }
.team-card {
  background: var(--color-surface);
  border: 1px solid var(--color-line);
  border-top: 3px solid var(--team-color, var(--color-gold));
  border-radius: var(--radius);
  padding: 18px;
}
.team-card__head { display: grid; gap: 10px; margin-bottom: 12px; }
.team-card__name { font-size: 17px; font-weight: 900; display: flex; align-items: center; gap: 10px; }
.team-card__actions { display: flex; gap: 6px; flex-wrap: wrap; }
.team-card__actions .btn { white-space: nowrap; }
.team-card table { background: transparent; }
.team-card th, .team-card td { padding: 6px 8px; font-size: 13px; }
.team-card td:nth-child(2) { text-align: left; font-weight: 500; white-space: normal; }
.player-add {
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr) 72px auto;
  gap: 8px;
  margin-top: 12px;
  align-items: stretch;
}
.player-add input, .player-add select { padding: 6px 8px; font-size: 13px; min-width: 0; }
.player-add button { white-space: nowrap; padding-inline: 14px; }

/* ---------- 6g2. フォーメーション ---------- */
.formation-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(260px, 0.65fr);
  gap: 24px;
  align-items: start;
}

.pitch {
  position: relative;
  aspect-ratio: 3 / 4;
  max-height: 720px;
  border: 1px solid var(--color-line-strong);
  border-radius: var(--radius);
  overflow: hidden;
  background:
    repeating-linear-gradient(180deg, rgba(255, 255, 255, 0.022) 0 44px, transparent 44px 88px),
    radial-gradient(120% 80% at 50% 0%, rgba(232, 184, 75, 0.1), transparent 60%),
    linear-gradient(180deg, #0c1a14, #081410 60%, #06100d);
}
.pitch__lines { position: absolute; inset: 4%; border: 2px solid rgba(255, 255, 255, 0.14); border-radius: 3px; }
.pitch__halfway { position: absolute; left: 0; right: 0; top: 50%; height: 2px; background: rgba(255, 255, 255, 0.14); }
.pitch__circle {
  position: absolute; left: 50%; top: 50%;
  width: 26%; aspect-ratio: 1;
  transform: translate(-50%, -50%);
  border: 2px solid rgba(255, 255, 255, 0.14);
  border-radius: 50%;
}
.pitch__box {
  position: absolute; left: 50%;
  width: 46%; height: 15%;
  transform: translateX(-50%);
  border: 2px solid rgba(255, 255, 255, 0.14);
}
.pitch__box--top { top: 0; border-top: none; }
.pitch__box--bottom { bottom: 0; border-bottom: none; }
.pitch__label {
  position: absolute;
  left: 14px; top: 12px;
  font-family: var(--font-display);
  font-size: 12px;
  letter-spacing: 0.14em;
  color: rgba(232, 184, 75, 0.75);
  z-index: 2;
}

.player-pin {
  position: absolute;
  transform: translate(-50%, -50%);
  display: grid;
  justify-items: center;
  gap: 3px;
  width: 82px;
  text-align: center;
  animation: pinIn 0.45s var(--ease-out) backwards;
  animation-delay: var(--pin-delay, 0s);
}
@keyframes pinIn {
  from { opacity: 0; transform: translate(-50%, -30%) scale(0.85); }
  to { opacity: 1; transform: translate(-50%, -50%) scale(1); }
}
.player-pin__num {
  display: grid;
  place-items: center;
  width: 38px; height: 38px;
  border-radius: 50%;
  background: var(--pin-color, var(--color-gold));
  color: #08110d;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 17px;
  box-shadow: 0 0 0 2px rgba(6, 8, 13, 0.7), 0 4px 14px rgba(0, 0, 0, 0.6);
}
.player-pin__name {
  font-size: 11px;
  font-weight: 700;
  line-height: 1.25;
  color: var(--color-text);
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.95);
  max-width: 92px;
  overflow-wrap: anywhere;
}
.player-pin__pos {
  font-family: var(--font-display);
  font-size: 9.5px;
  letter-spacing: 0.14em;
  color: rgba(255, 255, 255, 0.5);
}
.player-pin__goals {
  position: absolute;
  top: -4px; right: 12px;
  padding: 1px 5px;
  border-radius: 999px;
  background: var(--color-gold);
  color: var(--color-gold-ink);
  font-family: var(--font-display);
  font-size: 9.5px;
  font-weight: 700;
}
.player-pin--empty .player-pin__num {
  background: transparent;
  border: 1px dashed rgba(255, 255, 255, 0.35);
  color: rgba(255, 255, 255, 0.4);
  box-shadow: none;
}
.player-pin--empty .player-pin__name { color: rgba(255, 255, 255, 0.4); font-weight: 400; }

.pitch__style {
  position: absolute;
  right: 14px; top: 12px;
  font-size: 12px;
  font-weight: 900;
  color: var(--color-text);
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.9);
  z-index: 2;
}
.pitch__manager {
  position: absolute;
  left: 14px; bottom: 12px;
  font-size: 11.5px;
  color: rgba(255, 255, 255, 0.7);
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.9);
  z-index: 2;
}
.pitch__hint {
  position: absolute;
  right: 14px; bottom: 12px;
  font-size: 10.5px;
  color: rgba(255, 255, 255, 0.42);
  z-index: 2;
}
.player-pin { cursor: pointer; touch-action: none; user-select: none; }
.player-pin:focus-visible { outline: 2px solid var(--color-gold); outline-offset: 4px; border-radius: 6px; }
.player-pin.is-pressing .player-pin__num { transform: scale(1.18); transition: transform 0.5s var(--ease-out); }
.player-pin__num { transition: transform 0.2s var(--ease-out); }

/* チームの監督・スタイル入力 */
.team-meta { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.team-meta__field { display: grid; gap: 3px; font-size: 11px; color: var(--color-muted); }
.team-meta__field input, .team-meta__field select { padding: 5px 8px; font-size: 12.5px; }

/* スタイル相性表 */
.style-table th.style-side { text-align: left; white-space: nowrap; }
.style-table td { padding: 6px 8px; }
.style-inuse {
  display: inline-block;
  margin-left: 8px;
  padding: 1px 7px;
  border-radius: 999px;
  font-size: 9.5px;
  font-weight: 700;
  color: var(--color-gold-ink);
  background: var(--color-gold);
}
.style-cell {
  display: inline-block;
  min-width: 62px;
  padding: 3px 8px;
  border-radius: 4px;
  font-size: 11.5px;
  font-weight: 700;
}
.style-cell--good { color: var(--color-win); background: rgba(70, 212, 126, 0.16); }
.style-cell--ok { color: #a8e6b8; background: rgba(70, 212, 126, 0.08); }
.style-cell--even { color: var(--color-draw); background: rgba(147, 160, 180, 0.12); }
.style-cell--bad { color: #ffb08f; background: rgba(240, 106, 106, 0.1); }
.style-cell--worst { color: var(--color-loss); background: rgba(240, 106, 106, 0.18); }

/* 移籍・獲得速報 */
.transfer-feed { display: grid; gap: 8px; }
.transfer-empty { font-size: 12.5px; color: var(--color-muted); padding: 14px; border: 1px dashed var(--color-line-strong); border-radius: var(--radius); }
.transfer-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  background: linear-gradient(100deg, rgba(232, 184, 75, 0.1), var(--color-surface) 60%);
  border: 1px solid var(--color-line);
  border-left: 3px solid var(--color-gold);
  border-radius: var(--radius);
  flex-wrap: wrap;
}
.transfer-item__tag {
  font-family: var(--font-display);
  font-size: 10px;
  letter-spacing: 0.18em;
  padding: 2px 9px;
  border-radius: 3px;
  background: var(--color-gold);
  color: var(--color-gold-ink);
  font-weight: 700;
  flex-shrink: 0;
}
.transfer-item__body { display: grid; gap: 3px; min-width: 0; }
.transfer-item__body strong { font-size: 14px; }
.transfer-item__route { display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--color-muted); flex-wrap: wrap; }
.transfer-item__arrow { color: var(--color-gold); font-weight: 700; }
.transfer-item__when { margin-left: auto; font-size: 11px; color: var(--color-muted); }

.formation-side { display: grid; gap: 18px; }
.formation-side__block {
  background: var(--color-surface);
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
  padding: 18px;
}
.formation-side__title {
  font-size: 14px;
  font-weight: 900;
  padding-bottom: 10px;
  margin-bottom: 6px;
  border-bottom: 1px solid var(--color-line-strong);
}
.lineup-list, .bench-list { list-style: none; padding: 0; }
.lineup-list li, .bench-list li {
  display: grid;
  grid-template-columns: 34px 30px 1fr;
  align-items: center;
  gap: 10px;
  padding: 7px 2px;
  border-bottom: 1px solid var(--color-line);
  font-size: 13px;
}
.bench-list li { grid-template-columns: 30px 1fr 34px; }
.lineup-list li:last-child, .bench-list li:last-child { border-bottom: none; }
.lineup-pos {
  font-family: var(--font-display);
  font-size: 10px;
  letter-spacing: 0.1em;
  color: var(--color-gold);
  text-align: center;
  border: 1px solid rgba(232, 184, 75, 0.35);
  border-radius: 3px;
  padding: 1px 0;
}
.lineup-num { font-family: var(--font-display); font-weight: 600; font-size: 15px; text-align: center; color: var(--color-muted); }
.lineup-name { font-weight: 700; }
.lineup-name em { font-style: normal; font-weight: 400; color: var(--color-muted); }
.bench-empty { color: var(--color-muted); font-size: 12.5px; display: block !important; }

/* ---------- 6g. 設定 ---------- */
.settings-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 24px; align-items: start; }
.settings-card {
  background: var(--color-surface);
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
  padding: 24px;
}
.settings-card__title { font-size: 16px; font-weight: 900; margin-bottom: 16px; }
.settings-card__note { font-size: 13px; color: var(--color-muted); margin-bottom: 16px; }
.settings-card__actions { display: flex; flex-wrap: wrap; gap: 10px; }
.field { display: grid; gap: 5px; font-size: 12.5px; color: var(--color-muted); margin-bottom: 14px; }
.field input { color: var(--color-text); }
.field-row { display: flex; gap: 12px; }
.field-row .field { flex: 1; }
.field-row .field input { width: 100%; }

/* ---------- 7. モーダル / トースト / フッター ---------- */
.modal { position: fixed; inset: 0; z-index: var(--z-modal); display: grid; place-items: center; padding: 20px; }
.modal[hidden] { display: none; }
.modal__backdrop { position: absolute; inset: 0; background: rgba(3, 5, 9, 0.78); backdrop-filter: blur(3px); }
.modal__panel {
  position: relative;
  width: min(680px, 100%);
  max-height: min(86vh, 900px);
  overflow-y: auto;
  background: var(--color-bg-2);
  border: 1px solid var(--color-line-strong);
  border-radius: 10px;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.6), 0 0 40px rgba(232, 184, 75, 0.08);
  animation: modalIn 0.35s var(--ease-out);
}
@keyframes modalIn {
  from { opacity: 0; transform: translateY(18px) scale(0.98); }
  to { opacity: 1; transform: none; }
}
.modal__head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 20px;
  border-bottom: 1px solid var(--color-line);
  position: sticky;
  top: 0;
  background: var(--color-bg-2);
  z-index: 1;
}
.modal__round { font-family: var(--font-display); letter-spacing: 0.22em; font-size: 13px; color: var(--color-gold); }
.modal__close {
  width: 36px; height: 36px;
  border-radius: 50%;
  border: 1px solid var(--color-line-strong);
  background: transparent;
  color: var(--color-muted);
  font-size: 18px;
  cursor: pointer;
  transition: all 0.2s;
}
.modal__close:hover { color: var(--color-text); border-color: var(--color-gold); }
.modal__score {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 14px;
  padding: 22px 20px;
  border-bottom: 1px solid var(--color-line);
  text-align: center;
}
.modal__score .side { font-weight: 900; font-size: 15px; display: grid; gap: 6px; justify-items: center; }
.modal__score .side .team-dot { width: 12px; height: 12px; }
.modal__score .score-inputs { display: flex; align-items: center; gap: 10px; }
.modal__score .score-inputs input {
  width: 64px;
  text-align: center;
  font-size: 30px;
  font-weight: 600;
  padding: 4px;
}
.modal__score .score-inputs .vs { font-family: var(--font-display); color: var(--color-muted); }
.modal__body { padding: 20px; display: grid; gap: 24px; }
.event-section__title {
  font-size: 13px;
  font-weight: 900;
  letter-spacing: 0.1em;
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.event-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.event-col__team { font-size: 12px; font-weight: 700; color: var(--color-muted); margin-bottom: 8px; display: flex; align-items: center; gap: 6px; }
.event-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 6px;
  margin-bottom: 6px;
  align-items: center;
}
.event-row__selects { display: grid; gap: 4px; }
.event-row select { width: 100%; font-size: 12.5px; padding: 5px 6px; }
.event-row__del {
  width: 26px; height: 26px;
  border-radius: 4px;
  border: 1px solid var(--color-line-strong);
  background: transparent;
  color: var(--color-muted);
  cursor: pointer;
  font-size: 13px;
}
.event-row__del:hover { color: #ff8d75; border-color: var(--color-danger); }
.event-add-btn {
  width: 100%;
  padding: 6px;
  border: 1px dashed var(--color-line-strong);
  border-radius: 4px;
  background: transparent;
  color: var(--color-muted);
  font-size: 12.5px;
  cursor: pointer;
  transition: all 0.2s;
}
.event-add-btn:hover { color: var(--color-gold-bright); border-color: var(--color-gold); }
.modal__tools { display: flex; flex-wrap: wrap; gap: 10px; justify-content: space-between; align-items: center; }
.modal__hint { font-size: 12px; color: var(--color-muted); }
.modal__hint--warn { color: var(--color-yellow); }

.toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translate(-50%, 16px);
  z-index: var(--z-toast);
  background: var(--color-surface-2);
  border: 1px solid var(--color-gold);
  color: var(--color-text);
  padding: 10px 22px;
  border-radius: 999px;
  font-size: 13.5px;
  font-weight: 700;
  box-shadow: 0 0 30px rgba(232, 184, 75, 0.25);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s, transform 0.3s var(--ease-out);
}
.toast.is-show { opacity: 1; transform: translate(-50%, 0); }

.site-footer {
  border-top: 1px solid var(--color-line);
  padding: 36px 20px 44px;
  text-align: center;
}
.site-footer__brand {
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: 0.4em;
  font-size: 13px;
  color: var(--color-gold);
  margin-bottom: 6px;
}
.site-footer__note { font-size: 12px; color: var(--color-muted); }
.site-footer__sponsor { font-size: 11.5px; color: var(--color-muted); margin-top: 10px; }
.site-footer__sponsor a { color: var(--color-gold); font-weight: 700; text-decoration: none; }
.site-footer__sponsor a:hover { color: var(--color-gold-bright); opacity: 1; }

/* ヒーローのスポンサー表記 */
.hero__sponsor {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 22px;
  padding-top: 16px;
  border-top: 1px solid rgba(232, 184, 75, 0.22);
  max-width: 340px;
}
.hero__sponsor-label {
  font-family: var(--font-display);
  font-size: 9.5px;
  letter-spacing: 0.3em;
  color: var(--color-muted);
  white-space: nowrap;
}
.hero__sponsor-link { display: inline-flex; align-items: center; transition: opacity 0.25s, filter 0.25s; }
.hero__sponsor-link:hover { opacity: 1; filter: drop-shadow(0 0 12px rgba(232, 184, 75, 0.5)); }
.hero__sponsor-link img { height: 30px; width: auto; }
.hero__sponsor-text {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 21px;
  letter-spacing: 0.14em;
  color: var(--color-gold-bright);
  text-shadow: 0 0 18px rgba(232, 184, 75, 0.4);
}

/* ティッカー左端の提供表記 */
.ticker__brand {
  flex-shrink: 0;
  padding-inline: 14px;
  font-family: var(--font-display);
  font-size: 10px;
  letter-spacing: 0.22em;
  color: var(--color-gold);
  border-right: 1px solid var(--color-line-strong);
  background: var(--color-bg-2);
  align-self: stretch;
  display: flex;
  align-items: center;
  gap: 6px;
  z-index: 1;
}
.ticker__brand em {
  font-family: var(--font-body);
  font-style: normal;
  font-size: 10px;
  letter-spacing: 0.06em;
  color: var(--color-muted);
}

/* スポンサーバンド(フッター手前の一枚) */
.sponsor-band {
  border-top: 1px solid var(--color-line);
  border-bottom: 1px solid var(--color-line);
  padding: clamp(40px, 6vw, 68px) 20px;
  text-align: center;
  background:
    radial-gradient(700px 220px at 50% 50%, rgba(232, 184, 75, 0.08), transparent 72%),
    var(--color-bg-2);
  position: relative;
  overflow: hidden;
}
.sponsor-band::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(102deg, transparent 40%, rgba(255, 217, 122, 0.07) 50%, transparent 60%);
  transform: translateX(-60%);
  animation: heroSweep 9s var(--ease-out) 2s infinite;
}
.sponsor-band__label {
  font-family: var(--font-display);
  font-size: 10.5px;
  letter-spacing: 0.42em;
  color: var(--color-muted);
  margin-bottom: 20px;
}
.sponsor-band__link { display: inline-block; transition: transform 0.35s var(--ease-out), filter 0.35s; }
.sponsor-band__link:hover { transform: translateY(-3px); filter: drop-shadow(0 0 22px rgba(232, 184, 75, 0.45)); opacity: 1; }
.sponsor-band__logo { height: clamp(52px, 8vw, 76px); width: auto; margin-inline: auto; }
.sponsor-band__fallback {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(38px, 7vw, 62px);
  letter-spacing: 0.16em;
  color: var(--color-gold-bright);
  text-shadow: 0 0 34px rgba(232, 184, 75, 0.45);
}
.sponsor-band__tagline { font-size: 12.5px; color: var(--color-muted); margin-top: 18px; }

/* ---------- 8. モーション ---------- */
.js-reveal { opacity: 0; transform: translateY(14px); }
.js-reveal.is-in {
  opacity: 1;
  transform: none;
  transition: opacity 0.55s var(--ease-out), transform 0.55s var(--ease-out);
}

/* 8a. ローディング(スタジアム照明の点灯) */
.loader {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 22px;
  background: var(--color-bg);
  transition: transform 0.9s cubic-bezier(0.76, 0, 0.24, 1), opacity 0.5s ease 0.4s;
}
.loader.is-done { transform: translateY(-100%); opacity: 0; pointer-events: none; }
.loader__rig { display: flex; gap: 10px; }
.loader__lamp {
  width: 26px;
  height: 8px;
  border-radius: 2px;
  background: #1a2130;
  animation: lampOn 1.6s var(--ease-out) infinite;
}
.loader__lamp:nth-child(1) { animation-delay: 0s; }
.loader__lamp:nth-child(2) { animation-delay: 0.11s; }
.loader__lamp:nth-child(3) { animation-delay: 0.22s; }
.loader__lamp:nth-child(4) { animation-delay: 0.33s; }
.loader__lamp:nth-child(5) { animation-delay: 0.44s; }
.loader__lamp:nth-child(6) { animation-delay: 0.55s; }
@keyframes lampOn {
  0%, 70%, 100% { background: #1a2130; box-shadow: none; }
  22%, 48% { background: var(--color-gold-bright); box-shadow: 0 0 22px rgba(232, 184, 75, 0.85), 0 0 46px rgba(232, 184, 75, 0.4); }
}
.loader__brand {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 13px;
  letter-spacing: 0.5em;
  color: var(--color-gold);
  text-indent: 0.5em;
}
.loader__count { display: flex; align-items: baseline; gap: 2px; }
.loader__count #loader-num {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 52px;
  line-height: 1;
  color: var(--color-text);
  font-variant-numeric: tabular-nums;
}
.loader__pct { font-family: var(--font-display); font-size: 15px; color: var(--color-muted); }
.loader__line { width: min(240px, 60vw); height: 2px; background: var(--color-line); overflow: hidden; }
.loader__line span {
  display: block;
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, var(--color-gold), var(--color-gold-bright));
  box-shadow: 0 0 12px rgba(232, 184, 75, 0.8);
  transition: width 0.25s var(--ease-out);
}
body.is-loading { overflow: hidden; }

/* 8b. フィルムグレイン(軽量なSVGノイズ) */
.grain {
  position: fixed;
  inset: -50%;
  z-index: 900;
  pointer-events: none;
  opacity: 0.045;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)'/%3E%3C/svg%3E");
  animation: grainShift 0.8s steps(4) infinite;
}
@keyframes grainShift {
  0% { transform: translate(0, 0); }
  25% { transform: translate(-3%, 2%); }
  50% { transform: translate(2%, -3%); }
  75% { transform: translate(-2%, -2%); }
  100% { transform: translate(0, 0); }
}

/* 8c. ヒーロー背景のゆるやかなズーム(Ken Burns)と光のスイープ */
.hero.has-image .hero__bg { animation: kenBurns 26s ease-in-out infinite alternate; }
@keyframes kenBurns {
  from { transform: scale(1) translateY(0); }
  to { transform: scale(1.08) translateY(-1.5%); }
}
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(102deg, transparent 38%, rgba(255, 217, 122, 0.09) 48%, transparent 58%);
  transform: translateX(-60%);
  animation: heroSweep 7.5s var(--ease-out) 1.2s infinite;
}
@keyframes heroSweep {
  0% { transform: translateX(-60%); }
  38%, 100% { transform: translateX(120%); }
}

/* 8d. 開演シーケンス(ローダーが開いてからヒーローが立ち上がる) */
body.is-loaded .hero__kicker { animation: riseIn 0.7s var(--ease-out) 0.05s backwards; }
body.is-loaded .hero__title { animation: riseIn 0.9s var(--ease-out) 0.16s backwards; }
body.is-loaded .hero__leader { animation: riseIn 0.8s var(--ease-out) 0.34s backwards; }
body.is-loaded .hero__stats { animation: riseIn 0.8s var(--ease-out) 0.44s backwards; }
body.is-loaded .hero__watermark { animation: watermarkIn 1.6s var(--ease-out) 0.2s backwards; }
@keyframes riseIn {
  from { opacity: 0; transform: translateY(26px); }
  to { opacity: 1; transform: none; }
}
@keyframes watermarkIn {
  from { opacity: 0; letter-spacing: 0.24em; }
  to { opacity: 1; letter-spacing: 0.06em; }
}

/* 8e. 順位表の行が上から順に着席する */
.standings-table tbody tr { animation: rowIn 0.5s var(--ease-out) backwards; }
.standings-table tbody tr:nth-child(1) { animation-delay: 0.02s; }
.standings-table tbody tr:nth-child(2) { animation-delay: 0.06s; }
.standings-table tbody tr:nth-child(3) { animation-delay: 0.1s; }
.standings-table tbody tr:nth-child(4) { animation-delay: 0.14s; }
.standings-table tbody tr:nth-child(5) { animation-delay: 0.18s; }
.standings-table tbody tr:nth-child(6) { animation-delay: 0.22s; }
.standings-table tbody tr:nth-child(7) { animation-delay: 0.26s; }
.standings-table tbody tr:nth-child(8) { animation-delay: 0.3s; }
.standings-table tbody tr:nth-child(n+9) { animation-delay: 0.34s; }
@keyframes rowIn {
  from { opacity: 0; transform: translateX(-12px); }
  to { opacity: 1; transform: none; }
}

/* 首位の行に光沢が走る */
.standings-table tr.is-first { position: relative; }
.standings-table tr.is-first td:first-child::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(105deg, transparent 42%, rgba(255, 217, 122, 0.16) 50%, transparent 58%);
  animation: rowSheen 5.5s var(--ease-out) 1s infinite;
}
@keyframes rowSheen {
  0% { transform: translateX(-100%); }
  40%, 100% { transform: translateX(100%); }
}

/* 8f. 結果ティッカー(スポーツ中継の下部テロップ) */
.ticker {
  border-top: 1px solid var(--color-line);
  background: linear-gradient(90deg, var(--color-bg-2), rgba(232, 184, 75, 0.05), var(--color-bg-2));
  overflow: hidden;
  height: 30px;
  display: flex;
  align-items: center;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 4%, #000 96%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 4%, #000 96%, transparent);
}
.ticker:empty, .ticker.is-empty { display: none; }
.ticker__track {
  display: flex;
  gap: 0;
  white-space: nowrap;
  animation: tickerRun 42s linear infinite;
  will-change: transform;
}
.ticker:hover .ticker__track { animation-play-state: paused; }
@keyframes tickerRun {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}
.ticker__item {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding-inline: 18px;
  font-size: 12px;
  color: var(--color-muted);
  border-right: 1px solid var(--color-line);
}
.ticker__round { font-family: var(--font-display); font-size: 10.5px; letter-spacing: 0.16em; color: var(--color-gold); }
.ticker__score {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 13px;
  color: var(--color-text);
  font-variant-numeric: tabular-nums;
}
.ticker__team--win { color: var(--color-text); font-weight: 700; }

/* 8g. 数字のロールアップ(スコア確定時) */
@keyframes scorePop {
  0% { transform: scale(1); }
  40% { transform: scale(1.18); color: var(--color-gold-bright); }
  100% { transform: scale(1); }
}
.match-card--done .match-card__score input.is-fresh { animation: scorePop 0.5s var(--ease-out); }

/* 8h. モーション停止ボタン(reduced-motion環境にのみ表示) */
.motion-stop {
  position: fixed;
  right: 16px;
  bottom: 16px;
  z-index: var(--z-toast);
  padding: 8px 14px;
  font-size: 12px;
  font-weight: 700;
  border-radius: 999px;
  border: 1px solid var(--color-line-strong);
  background: var(--color-surface-2);
  color: var(--color-text);
  cursor: pointer;
}
.motion-stop:hover { border-color: var(--color-gold); color: var(--color-gold-bright); }

/* 停止した人にだけ静的表示(デフォルトは全員フル演出) */
@media (prefers-reduced-motion: reduce) {
  html:not(.force-motion) { scroll-behavior: auto; }
  html:not(.force-motion) *, html:not(.force-motion) *::before, html:not(.force-motion) *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  html:not(.force-motion) .js-reveal { opacity: 1; transform: none; }
  html:not(.force-motion) .loader { display: none; }
  html:not(.force-motion) .grain { display: none; }
  html:not(.force-motion) .hero::after { display: none; }
  html:not(.force-motion) .ticker__track { animation: none; }
}

/* ============================================================
   9. 装飾画像(任意) — assets/img/decor/ に置くと自動で有効になる
   どれも「無くても成立する」上乗せ。データの可読性を最優先に薄く敷く
   ============================================================ */

/* 9a. ローディング背景 */
.has-loader .loader::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: var(--img-loader);
  background-size: cover;
  background-position: center;
  opacity: 0.3;
  animation: kenBurns 20s ease-in-out infinite alternate;
}
.has-loader .loader::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(70% 60% at 50% 50%, rgba(6, 8, 13, 0.55), var(--color-bg) 78%);
}
.loader > * { position: relative; z-index: 1; }

/* 9b. 各タブ見出しの背景帯 */
.view-head { position: relative; }
.view-head::before {
  content: "";
  position: absolute;
  inset: -18px -20px -14px -20px;
  z-index: -1;
  border-radius: var(--radius);
  background-size: cover;
  background-position: center 40%;
  opacity: 0;
  transition: opacity 0.8s var(--ease-out);
  -webkit-mask-image: linear-gradient(90deg, #000 0%, rgba(0, 0, 0, 0.25) 62%, transparent 92%);
  mask-image: linear-gradient(90deg, #000 0%, rgba(0, 0, 0, 0.25) 62%, transparent 92%);
}
[data-view-panel="standings"] .view-head::before { background-image: var(--img-band-standings); }
[data-view-panel="crosstable"] .view-head::before { background-image: var(--img-band-crosstable); }
[data-view-panel="matches"] .view-head::before { background-image: var(--img-band-matches); }
[data-view-panel="rankings"] .view-head::before { background-image: var(--img-band-rankings); }
[data-view-panel="discipline"] .view-head::before { background-image: var(--img-band-discipline); }
[data-view-panel="teams"] .view-head::before { background-image: var(--img-band-teams); }
.has-band-standings [data-view-panel="standings"] .view-head::before,
.has-band-crosstable [data-view-panel="crosstable"] .view-head::before,
.has-band-matches [data-view-panel="matches"] .view-head::before,
.has-band-rankings [data-view-panel="rankings"] .view-head::before,
.has-band-discipline [data-view-panel="discipline"] .view-head::before,
.has-band-teams [data-view-panel="teams"] .view-head::before { opacity: 0.4; }
/* 帯を敷いたら見出しに影を足して可読性を確保する */
.has-band-standings [data-view-panel="standings"] .view-head,
.has-band-crosstable [data-view-panel="crosstable"] .view-head,
.has-band-matches [data-view-panel="matches"] .view-head,
.has-band-rankings [data-view-panel="rankings"] .view-head,
.has-band-discipline [data-view-panel="discipline"] .view-head,
.has-band-teams [data-view-panel="teams"] .view-head { text-shadow: 0 2px 14px rgba(0, 0, 0, 0.9); }

/* 9c. リーグ記録カードの背景 */
.has-record .record-card::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  background-image: var(--img-record);
  background-size: cover;
  background-position: center;
  opacity: 0.14;
  -webkit-mask-image: linear-gradient(200deg, #000, transparent 72%);
  mask-image: linear-gradient(200deg, #000, transparent 72%);
  pointer-events: none;
}
.record-card > * { position: relative; z-index: 1; }

/* 9d. 試合詳細モーダルのスコア背景 */
.has-modal .modal__score {
  position: relative;
  isolation: isolate;
}
.has-modal .modal__score::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background-image: var(--img-modal);
  background-size: cover;
  background-position: center;
  opacity: 0.22;
}
.has-modal .modal__score::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(180deg, rgba(10, 14, 22, 0.55), rgba(10, 14, 22, 0.9));
}

/* 9e. 芝目テクスチャ(スポンサーバンドとフッター) */
.has-turf .sponsor-band::before,
.has-turf .site-footer::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: var(--img-turf);
  background-size: cover;
  background-position: center;
  opacity: 0.1;
  pointer-events: none;
}
.has-turf .site-footer { position: relative; overflow: hidden; }
.sponsor-band > *, .site-footer > * { position: relative; z-index: 1; }

/* 9f. 空状態のイラスト */
.has-empty .empty-note::before {
  content: "";
  display: block;
  width: 110px;
  height: 110px;
  margin: 0 auto 14px;
  background-image: var(--img-empty);
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  opacity: 0.55;
}

/* 9g. トロフィー(首位) / ゴールデンブーツ(得点王) */
.has-trophy .standings-table tr.is-first .col-rank {
  position: relative;
  padding-left: 26px;
}
.has-trophy .standings-table tr.is-first .col-rank::after {
  content: "";
  position: absolute;
  left: 6px;
  top: 50%;
  transform: translateY(-50%);
  width: 20px;
  height: 20px;
  background-image: var(--img-trophy);
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  filter: drop-shadow(0 0 8px rgba(232, 184, 75, 0.7));
}
/* 1位は順位の数字を残したまま、下に小さくブーツを添える */
.has-boot #ranking-goals li.is-top .rk {
  position: relative;
  padding-bottom: 12px;
}
.has-boot #ranking-goals li.is-top .rk::after {
  content: "";
  position: absolute;
  left: 50%; bottom: 0;
  transform: translateX(-50%);
  width: 26px; height: 11px;
  background-image: var(--img-boot);
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  filter: drop-shadow(0 0 6px rgba(232, 184, 75, 0.6));
}

/* 9h. カードの質感(警告・退場) */
.has-card-yellow .card-chip--y,
.has-card-yellow .suspension-card__icon--y {
  background-image: var(--img-card-yellow);
  background-size: cover;
  background-position: center;
}
.has-card-red .card-chip--r,
.has-card-red .suspension-card__icon:not(.suspension-card__icon--y) {
  background-image: var(--img-card-red);
  background-size: cover;
  background-position: center;
}

/* ---------- レスポンシブ ---------- */
@media (max-width: 768px) {
  .site-header__inner { width: calc(100% - 32px); }
  .league-title { display: none; }
  .hero__inner, .tab-nav__inner, .app { width: calc(100% - 32px); }
  .hero__stats { width: 100%; overflow-x: auto; }
  .hero__stats .stat { padding: 12px 16px; min-width: 92px; }
  .stat__num { font-size: 24px; }
  .ticker { height: 26px; }
  .ticker__item { font-size: 11px; padding-inline: 12px; }
  .ticker__brand { display: none; }
  .hero__sponsor { max-width: none; margin-top: 18px; }
  .news__inner { width: calc(100% - 32px); padding-block: 14px 12px; }
  .news__viewport { aspect-ratio: 4 / 3; max-height: none; }
  .news-card__body { max-width: 100%; }
  .news-card__bg::after { background: linear-gradient(180deg, rgba(6, 8, 13, 0.35), rgba(6, 8, 13, 0.94) 78%); }
  .formation-layout { grid-template-columns: 1fr; }
  .pitch { aspect-ratio: 3 / 4.2; max-height: none; }
  .player-pin { width: 62px; }
  .player-pin__num { width: 32px; height: 32px; font-size: 14px; }
  .player-pin__name { font-size: 10px; max-width: 70px; }
  .news-admin__item { grid-template-columns: 52px 1fr; }
  .news-admin__actions { grid-column: 1 / -1; justify-content: flex-end; }
  .header-right { align-items: flex-end; }
  .header-tools { gap: 6px; }
  .sync-status { font-size: 10px; }
  .match-card { grid-template-columns: 1fr; gap: 8px; padding: 14px; }
  .match-card__team--home { justify-content: flex-start; text-align: left; }
  .match-card__score { justify-content: center; }
  .match-card__side { justify-content: center; }
  .match-card__side--left:empty { display: none; }
  .event-cols { grid-template-columns: 1fr; }
  .h2h__picker { width: 100%; }
  .h2h__picker select { flex: 1; min-width: 0; }
  .h2h__summary-wdl { margin-left: 0; width: 100%; }
  .h2h-grid { grid-template-columns: 1fr; }
  .records { grid-template-columns: 1fr; }
  .record-card__big { font-size: 38px; }
  .rankchart { padding: 8px 4px; }
  .event-row__foot { gap: 8px; }
  .panel { margin-top: 32px; }
  .player-add { grid-template-columns: 56px 1fr; }
  .player-add select, .player-add button { grid-column: span 1; }
  .field-row { flex-direction: column; gap: 0; }
}
