/* =========================================================
   龙珠CN / PEARL ORBIT ARCHIVE
   Shared site kit: reset, tokens, header, footer, components
   ========================================================= */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 24px);
}

body,
h1,
h2,
h3,
h4,
p,
figure,
blockquote,
dl,
dd,
ul,
ol {
  margin: 0;
}

ul,
ol {
  padding: 0;
}

:root {
  --ink: #0E0F12;
  --indigo: #1B2A6B;
  --pearl: #F6F2E9;
  --orange: #FF5A1F;
  --cyan: #3DE8D2;
  --sand: #E8DFC9;
  --steel: #4A5C9A;
  --copper: #C23B12;
  --fog: #C9CED6;
  --ink-blue: #10162E;

  --line: rgba(27, 42, 107, 0.16);
  --line-strong: rgba(27, 42, 107, 0.3);
  --line-dark: rgba(246, 242, 233, 0.16);
  --paper: #FFFDF7;
  --paper-soft: rgba(255, 253, 247, 0.72);

  --font-display: "PingFang SC", "Hiragino Sans GB", "Noto Sans SC", "Microsoft YaHei", sans-serif;
  --font-body: "PingFang SC", "Hiragino Sans GB", "Noto Sans SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  --font-serif: "Songti SC", "SimSun", Georgia, "Times New Roman", serif;
  --font-mono: "SFMono-Regular", "Cascadia Mono", "Roboto Mono", Consolas, "Liberation Mono", monospace;

  --page-max: 1440px;
  --gutter: clamp(18px, 4vw, 64px);
  --header-h: 82px;
  --radius-sm: 2px;
  --radius-md: 10px;
  --shadow-soft: 0 10px 30px -18px rgba(14, 15, 18, 0.35);
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
}

[hidden] {
  display: none !important;
}

html,
body {
  min-height: 100%;
}

body {
  background-color: var(--pearl);
  background-image:
    linear-gradient(to right, rgba(74, 92, 154, 0.07) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(74, 92, 154, 0.07) 1px, transparent 1px);
  background-size: 72px 72px;
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.85;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

img,
svg,
video {
  display: block;
  max-width: 100%;
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  color: inherit;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-display);
  font-weight: 900;
  line-height: 1.08;
  letter-spacing: -0.02em;
}

p {
  overflow-wrap: break-word;
}

a {
  color: inherit;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

::selection {
  background: var(--orange);
  color: var(--ink);
}

:focus-visible {
  outline: 2px solid var(--indigo);
  outline-offset: 3px;
  box-shadow: 0 0 0 4px var(--cyan);
}

.site-footer :focus-visible {
  outline-color: var(--cyan);
  box-shadow: 0 0 0 4px rgba(61, 232, 210, 0.18);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Skip link */
.skip-link {
  position: fixed;
  top: 10px;
  left: 10px;
  z-index: 999;
  display: inline-block;
  padding: 12px 18px;
  background: var(--ink);
  color: var(--pearl);
  border: 1px solid var(--cyan);
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-decoration: none;
  transform: translateY(-160%);
  transition: transform 0.2s var(--ease);
}

.skip-link:focus {
  transform: translateY(0);
}

/* Layout primitives */
.container {
  width: min(calc(100% - (var(--gutter) * 2)), var(--page-max));
  margin-inline: auto;
}

.section {
  padding-block: clamp(48px, 7vw, 96px);
}

.grid-12 {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: var(--grid-gap, 24px);
}

.col-4 {
  grid-column: span 4;
}

.col-6 {
  grid-column: span 6;
}

.col-8 {
  grid-column: span 8;
}

.col-12 {
  grid-column: span 12;
}

.prose {
  max-width: 72ch;
  font-size: clamp(16px, 1.05vw, 18px);
  line-height: 1.85;
}

.prose > * + * {
  margin-top: 1.2em;
}

.prose h2,
.prose h3 {
  margin-top: 1.8em;
  color: var(--indigo);
}

.prose ul,
.prose ol {
  padding-left: 1.3em;
}

.prose li + li {
  margin-top: 0.45em;
}

.display {
  font-family: var(--font-display);
  font-size: clamp(48px, 7vw, 112px);
  font-weight: 900;
  line-height: 0.95;
  letter-spacing: -0.04em;
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(28px, 3.6vw, 52px);
  font-weight: 900;
  line-height: 1.05;
  letter-spacing: -0.03em;
}

.eyebrow {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  line-height: 1.5;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--steel);
}

.lede {
  max-width: 62ch;
  font-size: clamp(17px, 1.35vw, 21px);
  line-height: 1.75;
  color: #2A2F45;
}

.mono {
  font-family: var(--font-mono);
  font-size: 0.82em;
  letter-spacing: 0.04em;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 12px 20px;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 700;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition:
    transform 0.18s var(--ease),
    background-color 0.18s var(--ease),
    color 0.18s var(--ease),
    border-color 0.18s var(--ease),
    box-shadow 0.18s var(--ease);
}

.btn:hover {
  transform: translateY(-1px);
}

.btn-primary {
  background: var(--orange);
  color: var(--ink);
  box-shadow: 0 6px 0 -4px rgba(194, 59, 18, 0.5);
}

.btn-primary:hover {
  background: #FF7246;
  color: var(--ink);
}

.btn-ghost {
  background: transparent;
  color: var(--indigo);
  border-color: var(--indigo);
}

.btn-ghost:hover {
  background: var(--indigo);
  color: var(--pearl);
}

.btn-small {
  min-height: 36px;
  padding: 8px 14px;
  font-size: 12px;
}

/* Tags */
.tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 26px;
  padding: 4px 9px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--sand);
  color: var(--indigo);
  font-family: var(--font-mono);
  font-size: 11px;
  line-height: 1.2;
  letter-spacing: 0.06em;
  white-space: nowrap;
}

.tag-orange {
  background: var(--orange);
  border-color: var(--orange);
  color: var(--ink);
}

.tag-legacy {
  background: transparent;
  border-color: var(--copper);
  color: var(--copper);
}

/* Breadcrumb */
.breadcrumb {
  font-family: var(--font-mono);
  font-size: 11px;
  line-height: 1.6;
  letter-spacing: 0.08em;
  color: var(--steel);
}

.breadcrumb ol {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.breadcrumb li {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.breadcrumb li + li::before {
  content: "/";
  color: var(--fog);
}

.breadcrumb a {
  color: var(--indigo);
  text-decoration: none;
  border-bottom: 1px solid transparent;
}

.breadcrumb a:hover {
  border-bottom-color: var(--indigo);
}

/* Surface card */
.surface-card {
  position: relative;
  display: block;
  min-width: 0;
  padding: clamp(18px, 2.4vw, 28px);
  background: var(--paper-soft);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  color: inherit;
  text-decoration: none;
  box-shadow: 0 1px 0 rgba(14, 15, 18, 0.02);
  transition:
    transform 0.18s var(--ease),
    border-color 0.18s var(--ease),
    background-color 0.18s var(--ease),
    box-shadow 0.18s var(--ease);
}

.surface-card:hover {
  transform: translateY(-2px);
  border-color: var(--indigo);
  background: var(--paper);
  box-shadow: var(--shadow-soft);
}

/* Pearl primitives */
.pearl {
  display: inline-block;
  width: clamp(140px, 18vw, 260px);
  aspect-ratio: 1;
  border-radius: 50%;
  background:
    radial-gradient(circle at 32% 28%,
      #FFF8E6 0%,
      #FFD9A8 12%,
      var(--orange) 42%,
      var(--copper) 68%,
      var(--indigo) 100%);
  box-shadow:
    inset -14px -18px 30px rgba(14, 15, 18, 0.32),
    inset 8px 10px 22px rgba(255, 255, 255, 0.4),
    0 0 0 1px rgba(27, 42, 107, 0.3);
}

.pearl--small {
  width: 80px;
}

.pearl--large {
  width: clamp(220px, 32vw, 420px);
}

.pearl-chain {
  display: flex;
  align-items: center;
  gap: 7px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.pearl-chain__dot {
  display: block;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--orange);
  box-shadow: 0 0 0 1px rgba(14, 15, 18, 0.15);
}

.pearl-chain__dot--indigo {
  background: var(--indigo);
}

.pearl-chain__dot--cyan {
  background: var(--cyan);
}

/* Image frames for page-stage imagery */
.img-frame {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: var(--sand);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
}

.img-frame img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.img-frame--circle {
  aspect-ratio: 1;
  border-radius: 50%;
}

.img-frame--portrait {
  aspect-ratio: 3 / 4;
}

.img-frame--wide {
  aspect-ratio: 21 / 9;
}

.img-frame--blueprint {
  background-color: var(--indigo);
  background-image:
    linear-gradient(to right, rgba(61, 232, 210, 0.12) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(61, 232, 210, 0.12) 1px, transparent 1px);
  background-size: 32px 32px;
}

/* Table of contents */
.toc {
  font-size: 13px;
  line-height: 1.6;
}

.toc ul,
.toc ol {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.toc a {
  display: block;
  padding: 6px 0 6px 12px;
  border-left: 1px solid var(--fog);
  color: var(--steel);
  text-decoration: none;
  transition: color 0.18s var(--ease), border-color 0.18s var(--ease);
}

.toc a:hover {
  color: var(--indigo);
  border-left-color: var(--indigo);
}

.toc a[aria-current="true"] {
  border-left: 2px solid var(--orange);
  color: var(--indigo);
  font-weight: 700;
}

/* =========================================================
   Header
   ========================================================= */

.site-header {
  position: sticky;
  top: 0;
  z-index: 120;
  background: rgba(246, 242, 233, 0.95);
  border-bottom: 1px solid var(--line);
  -webkit-backdrop-filter: saturate(1.2) blur(12px);
  backdrop-filter: saturate(1.2) blur(12px);
  transition: background-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}

.site-header[data-scrolled] {
  background: rgba(246, 242, 233, 0.99);
  box-shadow: 0 12px 28px -24px rgba(14, 15, 18, 0.5);
}

.scroll-progress {
  position: absolute;
  right: 0;
  bottom: -1px;
  left: 0;
  height: 2px;
  background: transparent;
  pointer-events: none;
}

.scroll-progress__bar {
  display: block;
  width: calc(var(--scroll-progress, 0) * 100%);
  height: 100%;
  background: linear-gradient(90deg, var(--orange), var(--cyan));
  transform-origin: left center;
  transition: width 0.1s linear;
}

.header-shell {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  width: min(calc(100% - (var(--gutter) * 2)), var(--page-max));
  min-height: var(--header-h);
  margin-inline: auto;
}

.header-left {
  display: flex;
  align-items: center;
  gap: 26px;
  min-width: 0;
}

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

.brand-pearls {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
  width: 34px;
  height: 34px;
  padding: 6px;
  background: var(--pearl);
  border: 1px solid var(--line);
  border-radius: 50%;
}

.brand-pearls i {
  display: block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--orange);
}

.brand-pearls i:nth-child(2) {
  background: var(--indigo);
}

.brand-pearls i:nth-child(3) {
  background: var(--cyan);
  box-shadow: 0 0 0 1px rgba(27, 42, 107, 0.2);
}

.brand-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.brand-mark {
  font-family: var(--font-display);
  font-size: clamp(18px, 1.6vw, 22px);
  font-weight: 900;
  line-height: 1;
  letter-spacing: -0.02em;
}

.brand-mark em {
  font-style: normal;
  color: var(--orange);
}

.brand-sub {
  font-family: var(--font-mono);
  font-size: 9px;
  line-height: 1.2;
  letter-spacing: 0.16em;
  color: var(--steel);
}

.brand-index {
  display: flex;
  align-items: center;
  gap: 8px;
  padding-left: 18px;
  border-left: 1px solid var(--fog);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.4;
  letter-spacing: 0.12em;
  color: var(--steel);
}

.brand-index__label {
  text-transform: uppercase;
}

.brand-index__num {
  color: var(--indigo);
}

.nav-toggle {
  display: none;
  align-items: center;
  gap: 8px;
  min-height: 42px;
  padding: 8px 12px;
  background: transparent;
  border: 1px solid var(--indigo);
  border-radius: var(--radius-sm);
  color: var(--indigo);
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
}

.nav-toggle__lines {
  display: grid;
  gap: 5px;
  width: 18px;
}

.nav-toggle__lines i {
  display: block;
  width: 18px;
  height: 2px;
  background: currentColor;
  transition: transform 0.2s var(--ease), opacity 0.2s var(--ease);
}

.nav-toggle[aria-expanded="true"] .nav-toggle__lines i:first-child {
  transform: translateY(3.5px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] .nav-toggle__lines i:last-child {
  transform: translateY(-3.5px) rotate(-45deg);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 22px;
}

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

.nav-link {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px;
  border-radius: var(--radius-sm);
  color: var(--ink);
  font-size: 14px;
  font-weight: 600;
  line-height: 1;
  text-decoration: none;
  transition: color 0.18s var(--ease), background-color 0.18s var(--ease);
}

.nav-link:hover {
  background: rgba(232, 223, 201, 0.55);
  color: var(--indigo);
}

.nav-index {
  font-family: var(--font-mono);
  font-size: 9px;
  line-height: 1;
  letter-spacing: 0.04em;
  color: var(--steel);
}

.nav-link[aria-current="page"] {
  color: var(--indigo);
}

.nav-link[aria-current="page"]::after {
  content: "";
  position: absolute;
  right: 10px;
  bottom: 3px;
  left: 10px;
  height: 2px;
  background: var(--orange);
}

.nav-link[aria-current="page"] .nav-index {
  color: var(--orange);
}

.nav-utility {
  display: flex;
  align-items: center;
  gap: 14px;
  padding-left: 16px;
  border-left: 1px solid var(--fog);
}

.utility-btn {
  padding: 6px 0;
  background: none;
  border: 0;
  border-bottom: 1px dotted var(--fog);
  color: var(--steel);
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 600;
  line-height: 1.4;
  cursor: pointer;
  transition: color 0.18s var(--ease), border-color 0.18s var(--ease);
}

.utility-btn:hover {
  color: var(--indigo);
  border-bottom-color: var(--indigo);
}

.legacy-tag {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.4;
  letter-spacing: 0.06em;
  color: var(--copper);
  white-space: nowrap;
}

.legacy-tag::before {
  content: "";
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--copper);
}

.header-cta {
  flex-shrink: 0;
}

/* Search panel */
.search-panel {
  position: absolute;
  top: 100%;
  right: 0;
  left: 0;
  padding: 18px var(--gutter) 22px;
  background: var(--pearl);
  border-bottom: 1px solid var(--line);
  box-shadow: 0 24px 40px -30px rgba(14, 15, 18, 0.6);
}

.search-inner {
  display: grid;
  grid-template-columns: 160px minmax(0, 1fr);
  gap: 12px 20px;
  align-items: center;
  width: min(calc(100% - (var(--gutter) * 2)), var(--page-max));
  margin-inline: auto;
}

.search-label {
  font-family: var(--font-mono);
  font-size: 11px;
  line-height: 1.4;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--steel);
}

.search-input {
  width: 100%;
  height: 46px;
  padding: 0 14px;
  background: var(--paper);
  border: 1px solid var(--fog);
  border-radius: var(--radius-sm);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.4;
}

.search-input:focus {
  border-color: var(--indigo);
}

.search-list {
  grid-column: 2;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.search-list a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 10px;
  background: var(--sand);
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  color: var(--indigo);
  font-size: 12px;
  font-weight: 600;
  line-height: 1.3;
  text-decoration: none;
}

.search-list a:hover {
  background: var(--pearl);
  border-color: var(--indigo);
}

.search-list span {
  font-family: var(--font-mono);
  font-size: 9px;
  color: var(--steel);
}

.search-empty {
  grid-column: 2;
  margin: 0;
  color: var(--copper);
  font-size: 13px;
  line-height: 1.6;
}

/* =========================================================
   Footer
   ========================================================= */

.site-footer {
  position: relative;
  overflow: hidden;
  margin-top: clamp(72px, 10vw, 140px);
  background: var(--ink-blue);
  border-top: 2px solid var(--orange);
  color: var(--pearl);
}

.site-footer::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.55;
  background-image:
    linear-gradient(to right, rgba(61, 232, 210, 0.06) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(61, 232, 210, 0.06) 1px, transparent 1px);
  background-size: 80px 80px;
}

.site-footer::after {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  left: 0;
  height: 1px;
  background: linear-gradient(90deg, var(--orange), transparent 45%, var(--cyan));
  opacity: 0.6;
}

.footer-orbit {
  position: absolute;
  top: -160px;
  right: -140px;
  width: clamp(320px, 40vw, 560px);
  aspect-ratio: 1;
  border: 1px solid rgba(61, 232, 210, 0.18);
  border-radius: 50%;
  pointer-events: none;
}

.footer-orbit::before,
.footer-orbit::after {
  content: "";
  position: absolute;
  border: 1px solid rgba(61, 232, 210, 0.12);
  border-radius: 50%;
  inset: 12%;
}

.footer-orbit::after {
  inset: 28%;
  border-color: rgba(255, 90, 31, 0.25);
}

.footer-orbit span {
  position: absolute;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--orange);
  box-shadow: 0 0 0 4px rgba(255, 90, 31, 0.12);
}

.footer-orbit span:nth-child(1) {
  top: 12%;
  left: 18%;
}

.footer-orbit span:nth-child(2) {
  top: 40%;
  right: 8%;
  background: var(--cyan);
  box-shadow: 0 0 0 4px rgba(61, 232, 210, 0.12);
}

.footer-orbit span:nth-child(3) {
  bottom: 6%;
  left: 42%;
  background: var(--pearl);
  box-shadow: 0 0 0 4px rgba(246, 242, 233, 0.1);
}

.footer-shell {
  position: relative;
  z-index: 1;
  width: min(calc(100% - (var(--gutter) * 2)), var(--page-max));
  margin-inline: auto;
  padding: clamp(44px, 6vw, 88px) 0 28px;
}

.footer-top {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 1.25fr);
  gap: clamp(28px, 5vw, 72px);
  padding-bottom: clamp(28px, 4vw, 52px);
  border-bottom: 1px solid var(--line-dark);
}

.footer-brand {
  max-width: 520px;
}

.footer-eyebrow {
  margin: 0 0 16px;
  color: var(--cyan);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.5;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.footer-brandline {
  margin: 0 0 18px;
  color: var(--pearl);
  font-family: var(--font-display);
  font-size: clamp(26px, 3.3vw, 48px);
  font-weight: 900;
  line-height: 1.08;
  letter-spacing: -0.03em;
}

.footer-brandline span {
  padding: 0 0.18em;
  color: var(--orange);
}

.footer-note {
  max-width: 46ch;
  margin: 0;
  color: rgba(246, 242, 233, 0.68);
  font-size: 14px;
  line-height: 1.8;
}

.footer-cols {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px 32px;
}

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

.footer-col__title {
  margin: 0 0 14px;
  color: var(--cyan);
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  line-height: 1.5;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.footer-links {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.footer-links a {
  display: inline-block;
  border-bottom: 1px solid transparent;
  color: rgba(246, 242, 233, 0.86);
  font-size: 14px;
  line-height: 1.6;
  text-decoration: none;
  transition: color 0.18s var(--ease), border-color 0.18s var(--ease);
}

.footer-links a:hover {
  color: var(--cyan);
  border-bottom-color: var(--cyan);
}

.footer-legacy {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 12px 24px;
  align-items: start;
  margin-top: clamp(24px, 4vw, 44px);
  padding-bottom: clamp(24px, 4vw, 40px);
  border-bottom: 1px solid var(--line-dark);
}

.footer-legacy__title {
  grid-row: 1 / span 2;
  margin: 0;
  padding-top: 4px;
  color: var(--cyan);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.5;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.legacy-row {
  grid-column: 2;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.legacy-chip {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 4px 10px;
  background: rgba(246, 242, 233, 0.04);
  border: 1px solid rgba(246, 242, 233, 0.22);
  border-radius: 999px;
  color: rgba(246, 242, 233, 0.8);
  font-family: var(--font-mono);
  font-size: 11px;
  line-height: 1.4;
  letter-spacing: 0.04em;
}

.footer-contact {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 20px 28px;
  padding: clamp(24px, 4vw, 36px) 0;
  border-bottom: 1px solid var(--line-dark);
  font-style: normal;
}

.contact-item {
  min-width: 0;
}

.contact-label {
  display: block;
  margin-bottom: 6px;
  color: rgba(61, 232, 210, 0.8);
  font-family: var(--font-mono);
  font-size: 9px;
  line-height: 1.5;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.contact-value {
  display: block;
  color: var(--pearl);
  font-size: 14px;
  line-height: 1.6;
  overflow-wrap: anywhere;
}

.contact-note {
  grid-column: 1 / -1;
  margin: 0;
  color: rgba(246, 242, 233, 0.58);
  font-size: 12px;
  line-height: 1.7;
}

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 24px;
  padding-top: 24px;
}

.footer-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  margin: 0;
  color: rgba(246, 242, 233, 0.6);
  font-family: var(--font-mono);
  font-size: 11px;
  line-height: 1.6;
}

.icp {
  color: rgba(246, 242, 233, 0.6);
}

.footer-legal {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
  margin: 0;
  padding: 0;
}

.footer-legal a {
  color: rgba(246, 242, 233, 0.72);
  font-family: var(--font-mono);
  font-size: 11px;
  line-height: 1.6;
  text-decoration: none;
  border-bottom: 1px solid transparent;
}

.footer-legal a:hover {
  color: var(--cyan);
  border-bottom-color: var(--cyan);
}

/* =========================================================
   Responsive
   ========================================================= */

@media (max-width: 1240px) {
  .brand-index {
    display: none;
  }

  .nav-link {
    padding-right: 8px;
    padding-left: 8px;
  }

  .site-nav {
    gap: 16px;
  }
}

@media (max-width: 1120px) {
  .nav-utility {
    display: none;
  }
}

@media (max-width: 1079px) {
  :root {
    --header-h: 72px;
  }

  .nav-toggle {
    display: inline-flex;
  }

  .site-nav {
    position: absolute;
    top: 100%;
    right: 0;
    left: 0;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    max-height: calc(100vh - var(--header-h));
    max-height: calc(100dvh - var(--header-h));
    padding: 14px var(--gutter) 26px;
    overflow-y: auto;
    background: var(--ink-blue);
    border-top: 2px solid var(--orange);
    box-shadow: 0 30px 40px -30px #000;
  }

  .site-nav[data-open] {
    display: flex;
  }

  .nav-list {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--line-dark);
  }

  .nav-link {
    padding: 14px 4px;
    border-bottom: 1px solid rgba(246, 242, 233, 0.1);
    border-radius: 0;
    color: rgba(246, 242, 233, 0.88);
    font-size: 16px;
  }

  .nav-link:hover {
    background: transparent;
    color: var(--cyan);
  }

  .nav-link[aria-current="page"] {
    color: var(--cyan);
  }

  .nav-link[aria-current="page"]::after {
    right: auto;
    bottom: 10px;
    left: 0;
    width: 4px;
    height: 4px;
    border-radius: 50%;
  }

  .nav-index {
    color: rgba(61, 232, 210, 0.7);
  }

  .nav-utility {
    display: flex;
    justify-content: space-between;
    padding: 16px 0 0;
    border-left: 0;
  }

  .utility-btn {
    border-bottom-color: rgba(61, 232, 210, 0.4);
    color: var(--cyan);
    font-size: 13px;
  }

  .legacy-tag {
    color: #FF8A63;
  }

  .header-cta {
    width: 100%;
    margin-top: 16px;
  }

  .site-nav :focus-visible {
    outline-color: var(--cyan);
    box-shadow: 0 0 0 4px rgba(61, 232, 210, 0.18);
  }

  .search-panel {
    padding-top: 14px;
    padding-bottom: 18px;
  }

  .search-inner {
    grid-template-columns: minmax(0, 1fr);
    gap: 10px;
  }

  .search-list,
  .search-empty {
    grid-column: 1;
  }
}

@media (max-width: 900px) {
  .col-4,
  .col-6,
  .col-8 {
    grid-column: span 12;
  }

  .footer-top {
    grid-template-columns: minmax(0, 1fr);
  }

  .footer-brand {
    max-width: 640px;
  }

  .footer-contact {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .footer-legacy {
    grid-template-columns: minmax(0, 1fr);
  }

  .footer-legacy__title {
    grid-row: auto;
    padding-top: 0;
  }

  .legacy-row {
    grid-column: 1;
  }
}

@media (max-width: 640px) {
  :root {
    --header-h: 66px;
  }

  body {
    background-size: 56px 56px;
  }

  .header-shell {
    gap: 12px;
  }

  .brand {
    gap: 9px;
  }

  .brand-pearls {
    width: 30px;
    height: 30px;
    padding: 5px;
  }

  .brand-sub {
    font-size: 8px;
    letter-spacing: 0.12em;
  }

  .nav-toggle {
    min-height: 38px;
    padding: 7px 9px;
  }

  .nav-toggle__label {
    display: none;
  }

  .footer-cols {
    gap: 20px;
  }

  .footer-contact {
    grid-template-columns: minmax(0, 1fr);
  }

  .footer-bottom {
    align-items: flex-start;
    flex-direction: column;
  }

  .footer-orbit {
    top: -90px;
    right: -110px;
    width: 300px;
  }

  .search-list {
    max-height: 42vh;
    overflow-y: auto;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }

  .btn:hover,
  .surface-card:hover {
    transform: none;
  }
}
