/* =========================================================
   顺发赛场 Shared Site Kit
   视觉基调：深夜球场数据指挥舱
   ========================================================= */

/* ---------- 1. Reset ---------- */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* ---------- 2. Design Tokens ---------- */
:root {
  --bg-primary: #0B0B0D;
  --bg-panel: #14141A;
  --bg-surface: #1E1E28;
  --accent-gold: #FFD700;
  --accent-red: #E63946;
  --accent-silver: #C0C0C0;
  --text-primary: #FFFFFF;
  --text-secondary: #B0B0B0;
  --line-regular: #2B2D42;
  --gradient-gold-red: linear-gradient(135deg, #FFD700 0%, #E63946 100%);

  --font-heading: "Anton", "Impact", sans-serif;
  --font-body: "Roboto Mono", "Courier New", monospace;

  --container-w: 1240px;
  --gutter: clamp(20px, 4vw, 48px);
  --header-h: 72px;
  --header-offset: 16px;

  --radius-full: 999px;
  --radius-lg: 20px;
  --radius-md: 12px;
  --radius-sm: 8px;

  --shadow-soft: 0 8px 32px rgba(0, 0, 0, 0.45);
  --shadow-float: 0 16px 56px rgba(0, 0, 0, 0.7);

  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --dur-fast: 200ms;
  --dur-med: 400ms;
  --dur-slow: 700ms;
}

/* ---------- 3. Base ---------- */
html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + var(--header-offset) + 24px);
}

body {
  background: var(--bg-primary);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.7;
  padding-top: calc(var(--header-h) + var(--header-offset) + 32px);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  font-variant-numeric: tabular-nums;
  position: relative;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse 900px 420px at 12% -5%, rgba(255, 215, 0, 0.07), transparent 65%),
    radial-gradient(ellipse 700px 500px at 88% 12%, rgba(230, 57, 70, 0.05), transparent 60%),
    repeating-linear-gradient(
      115deg,
      transparent 0px,
      transparent 26px,
      rgba(255, 255, 255, 0.012) 26px,
      rgba(255, 255, 255, 0.012) 27px
    );
}

main {
  position: relative;
  z-index: 1;
  display: block;
  min-height: 60vh;
}

#main-content {
  scroll-margin-top: calc(var(--header-h) + var(--header-offset) + 24px);
  outline: none;
}

a {
  color: var(--accent-gold);
  text-decoration: none;
  transition: color var(--dur-fast) var(--ease-out);
}

a:hover {
  color: var(--text-primary);
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-heading);
  font-weight: 400;
  line-height: 1.15;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--text-primary);
}

h1 {
  font-size: clamp(2.5rem, 6vw, 4rem);
}

h2 {
  font-size: clamp(1.8rem, 4vw, 2.5rem);
}

h3 {
  font-size: clamp(1.2rem, 2vw, 1.5rem);
}

h4,
h5,
h6 {
  font-size: 1.1rem;
}

p {
  margin-bottom: 1rem;
}

::selection {
  background: var(--accent-gold);
  color: var(--bg-primary);
}

:focus {
  outline: none;
}

:focus-visible {
  outline: 2px solid var(--accent-gold);
  outline-offset: 3px;
  border-radius: 3px;
}

/* ---------- 4. Utilities ---------- */
.container {
  width: 100%;
  max-width: var(--container-w);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.skip-link {
  position: fixed;
  top: var(--header-offset);
  left: 50%;
  transform: translateX(-50%) translateY(-220%);
  z-index: 900;
  background: var(--accent-gold);
  color: var(--bg-primary);
  border-radius: var(--radius-full);
  padding: 10px 24px;
  font-size: 0.875rem;
  font-weight: 700;
  box-shadow: var(--shadow-float);
  transition: transform var(--dur-med) var(--ease-out);
}

.skip-link:focus-visible {
  transform: translateX(-50%) translateY(0);
}

/* ---------- 5. Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: var(--radius-full);
  font-family: var(--font-body);
  font-size: 0.875rem;
  font-weight: 700;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  border: 0;
  transition:
    transform var(--dur-fast) var(--ease-out),
    box-shadow var(--dur-fast) var(--ease-out),
    border-color var(--dur-fast) var(--ease-out),
    background var(--dur-fast) var(--ease-out);
}

.btn-primary {
  background: var(--gradient-gold-red);
  color: var(--bg-primary);
  box-shadow: 0 4px 24px rgba(230, 57, 70, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(255, 215, 0, 0.4);
  color: var(--bg-primary);
}

.btn-outline {
  background: transparent;
  border: 1px solid var(--line-regular);
  color: var(--text-secondary);
}

.btn-outline:hover {
  border-color: var(--accent-gold);
  color: var(--text-primary);
  transform: translateY(-2px);
}

/* ---------- 6. Breadcrumbs ---------- */
.breadcrumbs {
  margin-bottom: 28px;
}

.breadcrumb-list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  list-style: none;
}

.breadcrumb-item {
  font-size: 0.8125rem;
  color: var(--text-secondary);
}

.breadcrumb-item a {
  color: var(--text-secondary);
  text-decoration: none;
}

.breadcrumb-item a:hover {
  color: var(--accent-gold);
}

.breadcrumb-sep {
  color: var(--line-regular);
}

/* ---------- 7. Header / Navigation ---------- */
.site-header {
  position: fixed;
  top: var(--header-offset);
  left: 0;
  right: 0;
  display: flex;
  justify-content: center;
  padding: 0 var(--gutter);
  z-index: 200;
  pointer-events: none;
}

.header-island {
  position: relative;
  pointer-events: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  width: 100%;
  max-width: var(--container-w);
  padding: 10px 16px;
  background: linear-gradient(180deg, rgba(30, 30, 40, 0.88), rgba(20, 20, 26, 0.85));
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid var(--line-regular);
  border-radius: var(--radius-full);
  box-shadow:
    var(--shadow-soft),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
  transition:
    border-color var(--dur-med) var(--ease-out),
    box-shadow var(--dur-med) var(--ease-out);
}

.site-header:hover .header-island {
  border-color: #3A3D56;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  color: var(--text-primary);
  text-decoration: none;
  flex-shrink: 0;
}

.brand:hover {
  color: var(--text-primary);
}

.brand-mark {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--gradient-gold-red);
  font-family: var(--font-heading);
  font-size: 1.05rem;
  color: var(--bg-primary);
  letter-spacing: 0.04em;
  box-shadow: 0 0 0 1px rgba(255, 215, 0, 0.25);
  flex-shrink: 0;
}

.brand-copy {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

.brand-name {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-primary);
  line-height: 1;
}

.brand-tagline {
  font-size: 0.75rem;
  color: var(--accent-silver);
  font-family: var(--font-body);
  margin-top: 3px;
  letter-spacing: 0.02em;
}

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid var(--line-regular);
  background: transparent;
  cursor: pointer;
  flex-shrink: 0;
  transition:
    background var(--dur-fast) var(--ease-out),
    border-color var(--dur-fast) var(--ease-out);
}

.nav-toggle:hover {
  background: var(--bg-surface);
  border-color: var(--accent-gold);
}

.nav-toggle-bar {
  display: block;
  width: 18px;
  height: 2px;
  border-radius: 2px;
  background: var(--text-primary);
  transition:
    transform var(--dur-med) var(--ease-out),
    opacity var(--dur-med) var(--ease-out);
}

.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(2) {
  opacity: 0;
}

.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.site-nav {
  display: block;
}

.nav-list {
  display: flex;
  align-items: center;
  list-style: none;
  gap: 2px;
}

.nav-link {
  display: inline-flex;
  align-items: center;
  padding: 10px 16px;
  border-radius: var(--radius-full);
  color: var(--text-secondary);
  font-family: var(--font-body);
  font-size: 0.875rem;
  text-decoration: none;
  white-space: nowrap;
  transition:
    color var(--dur-fast) var(--ease-out),
    background var(--dur-fast) var(--ease-out),
    box-shadow var(--dur-fast) var(--ease-out);
}

.nav-link:hover {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.06);
}

.nav-link[aria-current="page"] {
  color: var(--bg-primary);
  background: var(--accent-gold);
  box-shadow:
    0 0 0 1px rgba(255, 215, 0, 0.4),
    0 2px 12px rgba(255, 215, 0, 0.25);
}

/* 紧凑断点 */
@media (max-width: 1120px) {
  .brand-tagline {
    display: none;
  }

  .nav-link {
    padding: 10px 12px;
    font-size: 0.8125rem;
  }
}

/* 移动端 */
@media (max-width: 920px) {
  .nav-toggle {
    display: flex;
  }

  .site-nav {
    position: absolute;
    top: calc(100% + 10px);
    left: 10px;
    right: 10px;
    background: var(--bg-panel);
    border: 1px solid var(--line-regular);
    border-radius: var(--radius-lg);
    padding: 16px;
    box-shadow: var(--shadow-float);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition:
      opacity var(--dur-med) var(--ease-out),
      transform var(--dur-med) var(--ease-out),
      visibility 0s linear var(--dur-med);
  }

  .site-nav[data-open="true"] {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    transition:
      opacity var(--dur-med) var(--ease-out),
      transform var(--dur-med) var(--ease-out);
  }

  .nav-list {
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
  }

  .nav-link {
    display: block;
    padding: 14px 16px;
    border-radius: var(--radius-md);
    font-size: 1rem;
    text-align: center;
  }

  .nav-link[aria-current="page"] {
    background: var(--accent-gold);
    color: var(--bg-primary);
  }
}

@media (max-width: 380px) {
  .brand-name {
    font-size: 1.1rem;
  }

  .header-island {
    gap: 12px;
    padding: 10px 12px;
  }
}

/* ---------- 8. Page Head & Section Panels ---------- */
.page-head {
  margin-bottom: var(--gutter);
}

.page-title {
  font-size: clamp(2.5rem, 6vw, 4rem);
  line-height: 1.1;
  margin-bottom: 12px;
}

.page-desc {
  color: var(--text-secondary);
  max-width: 640px;
  font-size: 1rem;
}

.section-panel {
  position: relative;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.03) 0%, transparent 12px),
    var(--bg-panel);
  border: 1px solid var(--line-regular);
  border-radius: var(--radius-lg);
  padding: clamp(28px, 5vw, 56px);
  margin-bottom: 24px;
  box-shadow: var(--shadow-soft);
  overflow: hidden;
}

.section-panel::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 3px;
  height: 56px;
  background: var(--gradient-gold-red);
  border-radius: 0 0 4px 0;
}

.panel-head {
  margin-bottom: var(--gutter);
}

.kicker {
  display: inline-block;
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent-gold);
  padding: 4px 12px;
  border: 1px solid rgba(255, 215, 0, 0.25);
  border-radius: var(--radius-full);
  margin-bottom: 16px;
  background: rgba(255, 215, 0, 0.08);
}

.panel-title {
  font-size: clamp(1.8rem, 4vw, 2.5rem);
  line-height: 1.1;
}

.panel-desc {
  color: var(--text-secondary);
  font-size: 0.9375rem;
  max-width: 640px;
}

.panel-foot {
  display: flex;
  gap: 16px;
  margin-top: var(--gutter);
  flex-wrap: wrap;
}

/* ---------- 9. Cards & Grid ---------- */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(280px, 100%), 1fr));
  gap: 24px;
}

.panel-card {
  background: var(--bg-surface);
  border: 1px solid var(--line-regular);
  border-radius: var(--radius-md);
  padding: 24px;
  transition:
    transform var(--dur-med) var(--ease-out),
    border-color var(--dur-med) var(--ease-out),
    box-shadow var(--dur-med) var(--ease-out);
  position: relative;
}

.panel-card:hover {
  transform: translateY(-4px);
  border-color: rgba(255, 215, 0, 0.4);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.4);
}

.card-title {
  font-size: 1.25rem;
  text-transform: uppercase;
  margin-bottom: 8px;
}

.card-text {
  color: var(--text-secondary);
  font-size: 0.875rem;
  margin-bottom: 16px;
}

.card-link {
  color: var(--accent-gold);
  font-size: 0.875rem;
  font-weight: 700;
  text-decoration: none;
}

.card-link:hover {
  color: var(--text-primary);
}

/* ---------- 10. Image Containers ---------- */
.img-container {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line-regular);
  border-radius: var(--radius-md);
  background: var(--bg-surface);
  aspect-ratio: 16 / 9;
  --ratio: 16 / 9;
  display: block;
  min-width: 0;
}

.img-container[data-ratio="3/2"] {
  --ratio: 3 / 2;
  aspect-ratio: 3 / 2;
}

.img-container[data-ratio="4/3"] {
  --ratio: 4 / 3;
  aspect-ratio: 4 / 3;
}

.img-container[data-ratio="1/1"] {
  --ratio: 1 / 1;
  aspect-ratio: 1 / 1;
}

.img-container[data-ratio="21/9"] {
  --ratio: 21 / 9;
  aspect-ratio: 21 / 9;
}

.img-container::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    repeating-linear-gradient(-45deg, rgba(255, 255, 255, 0.03) 0 1px, transparent 1px 12px),
    radial-gradient(ellipse at 70% 20%, rgba(255, 215, 0, 0.05), transparent 55%),
    radial-gradient(ellipse at 20% 80%, rgba(230, 57, 70, 0.05), transparent 50%);
}

.img-container img {
  position: absolute;
  inset: 0;
  z-index: 2;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.img-placeholder {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  color: var(--text-secondary);
  text-align: center;
  padding: 24px;
  font-size: 0.8125rem;
}

.img-stroke {
  display: block;
  width: 56px;
  height: 3px;
  border-radius: 2px;
  background: var(--gradient-gold-red);
}

/* ---------- 11. Data & Numbers ---------- */
.data-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 1px;
  background: var(--line-regular);
  border: 1px solid var(--line-regular);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.data-item {
  flex: 1 1 140px;
  background: var(--bg-surface);
  padding: 18px 20px;
  min-width: 0;
}

.data-label {
  display: block;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--text-secondary);
  margin-bottom: 6px;
}

.data-value {
  display: block;
  font-family: var(--font-heading);
  font-size: 1.6rem;
  color: var(--text-primary);
  line-height: 1.2;
}

.score-num {
  font-family: var(--font-heading);
  font-size: clamp(2.2rem, 5vw, 3.2rem);
  background: var(--gradient-gold-red);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
  line-height: 1;
}

/* ---------- 12. Speed Line ---------- */
.speed-line {
  display: block;
  height: 3px;
  background: linear-gradient(90deg, transparent, rgba(230, 57, 70, 0.7) 30%, rgba(255, 215, 0, 0.9) 100%);
  border-radius: 2px;
  position: relative;
  overflow: hidden;
  margin: 24px 0;
}

.speed-line::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.6), transparent);
  transform: translateX(-100%);
  animation: speed-sweep 3s ease-in-out infinite;
}

@keyframes speed-sweep {
  0% {
    transform: translateX(-100%);
  }
  100% {
    transform: translateX(100%);
  }
}

/* ---------- 13. Chapter Anchor ---------- */
[data-chapter] {
  scroll-margin-top: calc(var(--header-h) + var(--header-offset) + 24px);
}

/* ---------- 14. Footer ---------- */
.site-footer {
  position: relative;
  z-index: 1;
  background: var(--bg-panel);
  border-top: 1px solid var(--line-regular);
  margin-top: var(--gutter);
}

.footer-rail {
  height: 3px;
  background:
    repeating-linear-gradient(90deg, var(--accent-gold) 0 8px, transparent 8px 16px),
    linear-gradient(90deg, transparent, var(--accent-red) 70%, var(--accent-gold) 100%);
  opacity: 0.5;
}

.footer-body {
  padding: 64px 0 48px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1.2fr;
  gap: 48px;
}

.footer-brand {
  min-width: 0;
}

.footer-logo {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--text-primary);
  margin-bottom: 12px;
}

.footer-logo:hover {
  color: var(--text-primary);
}

.footer-logo-mark {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--gradient-gold-red);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-heading);
  font-size: 0.9375rem;
  color: var(--bg-primary);
  flex-shrink: 0;
}

.footer-logo-text {
  font-family: var(--font-heading);
  font-size: 1.75rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.footer-tagline {
  color: var(--accent-silver);
  font-size: 0.875rem;
  margin-bottom: 12px;
}

.footer-trust {
  color: var(--text-secondary);
  font-size: 0.8125rem;
  max-width: 360px;
  line-height: 1.7;
  margin-bottom: 0;
}

.footer-heading {
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--accent-gold);
  margin-bottom: 20px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--line-regular);
}

.footer-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-list a {
  color: var(--text-secondary);
  font-size: 0.875rem;
  text-decoration: none;
  transition:
    color var(--dur-fast) var(--ease-out),
    padding-left var(--dur-fast) var(--ease-out);
}

.footer-list a:hover {
  color: var(--accent-gold);
  padding-left: 4px;
}

.footer-contact-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
  color: var(--text-secondary);
  font-size: 0.8125rem;
  margin-bottom: 20px;
}

.footer-contact-list li {
  position: relative;
  padding-left: 14px;
}

.footer-contact-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.65em;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent-red);
}

.footer-legal-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.footer-legal-links a {
  font-size: 0.8125rem;
  color: var(--text-secondary);
  text-decoration: none;
  padding: 6px 14px;
  border: 1px solid var(--line-regular);
  border-radius: var(--radius-full);
  transition:
    border-color var(--dur-fast) var(--ease-out),
    color var(--dur-fast) var(--ease-out);
}

.footer-legal-links a:hover {
  border-color: var(--accent-gold);
  color: var(--accent-gold);
}

.footer-bottom {
  border-top: 1px solid var(--line-regular);
  padding: 24px 0;
}

.footer-bottom-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  font-size: 0.75rem;
  color: var(--text-secondary);
}

.footer-bottom-inner p {
  margin: 0;
}

@media (max-width: 900px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }

  .footer-brand {
    grid-column: 1 / -1;
  }
}

@media (max-width: 600px) {
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .footer-brand {
    grid-column: auto;
  }
}

/* ---------- 15. Chapter Dock ---------- */
.chapter-dock {
  position: fixed;
  right: 20px;
  top: 50%;
  transform: translateY(-50%);
  z-index: 160;
  background: rgba(20, 20, 26, 0.82);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--line-regular);
  border-radius: var(--radius-md);
  padding: 12px 10px;
  box-shadow: var(--shadow-soft);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.chapter-dock[hidden] {
  display: none;
}

.chapter-dock-title {
  font-family: var(--font-body);
  font-size: 0.6875rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-secondary);
  writing-mode: vertical-rl;
  text-orientation: mixed;
  margin: 2px 0 6px;
}

.chapter-dock-list {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

.chapter-dock-link {
  display: block;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--line-regular);
  font-size: 0;
  overflow: hidden;
  text-indent: -999px;
  transition:
    background var(--dur-fast) var(--ease-out),
    transform var(--dur-fast) var(--ease-out),
    box-shadow var(--dur-fast) var(--ease-out);
}

.chapter-dock-link:hover {
  background: var(--accent-red);
  transform: scale(1.3);
}

.chapter-dock-link[data-active="true"] {
  background: var(--accent-gold);
  box-shadow: 0 0 0 3px rgba(255, 215, 0, 0.2);
  transform: scale(1.2);
}

@media (max-width: 900px) {
  .chapter-dock {
    display: none;
  }

  .chapter-dock[hidden] {
    display: none;
  }
}

/* ---------- 16. Scroll Progress & Back to Top ---------- */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  width: 0;
  background: var(--gradient-gold-red);
  box-shadow: 0 0 12px rgba(255, 215, 0, 0.4);
  z-index: 400;
  pointer-events: none;
  transition: width 0.1s linear;
}

.back-to-top {
  position: fixed;
  right: 24px;
  bottom: 24px;
  width: 48px;
  height: 48px;
  border: none;
  border-radius: 50%;
  background: var(--gradient-gold-red);
  color: var(--bg-primary);
  font-size: 1.25rem;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 250;
  box-shadow: var(--shadow-float);
  opacity: 0;
  transform: translateY(16px);
  pointer-events: none;
  transition:
    opacity var(--dur-med) var(--ease-out),
    transform var(--dur-med) var(--ease-out),
    box-shadow var(--dur-fast) var(--ease-out);
}

.back-to-top:hover {
  box-shadow: 0 12px 32px rgba(255, 215, 0, 0.4);
}

.back-to-top[data-visible="true"] {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

/* ---------- 17. Focus & Reduced Motion ---------- */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  .speed-line::after {
    animation: none;
  }
}
