@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@300;400;500;600;700&family=Syne:wght@400;500;600;700&display=swap');

:root {
  --void: #0e0b14;
  --rose: #ff5c8a;
  --ink: #f4efe8;
  --ink-70: rgba(244, 239, 232, 0.72);
  --ink-46: rgba(244, 239, 232, 0.46);
  --glass: rgba(244, 239, 232, 0.055);
  --glass-deep: rgba(244, 239, 232, 0.03);
  --line: rgba(244, 239, 232, 0.14);
  --line-soft: rgba(244, 239, 232, 0.08);
  --radius: 10px;
  --gutter: clamp(16px, 4.6vw, 46px);
  --stick: 156px;
  --scroll: 0;
  --display: 'Syne', 'Manrope', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', system-ui, sans-serif;
  --body: 'Manrope', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', system-ui, sans-serif;
}

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

html {
  scroll-behavior: smooth;
  background: var(--void);
  overflow-x: hidden;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  overflow-x: hidden;
  background: var(--void);
  color: var(--ink);
  font-family: var(--body);
  font-size: 17px;
  font-weight: 400;
  line-height: 1.78;
  letter-spacing: 0.01em;
  text-rendering: optimizeLegibility;
}

body::before,
body::after {
  content: '';
  position: fixed;
  left: 0;
  right: 0;
  top: -25vh;
  height: 165vh;
  z-index: 0;
  pointer-events: none;
  will-change: transform;
}

body::before {
  background:
    radial-gradient(58vw 58vw at 84% 6%, rgba(255, 92, 138, 0.3), transparent 62%),
    radial-gradient(44vw 44vw at 6% 24%, rgba(255, 92, 138, 0.13), transparent 66%);
  transform: translate3d(0, calc(var(--scroll) * 0.16px), 0);
}

body::after {
  background:
    radial-gradient(46vw 46vw at 50% 74%, rgba(114, 86, 255, 0.17), transparent 70%),
    radial-gradient(34vw 34vw at 18% 96%, rgba(255, 92, 138, 0.1), transparent 72%);
  transform: translate3d(0, calc(var(--scroll) * -0.09px), 0);
}

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

a {
  color: inherit;
  text-decoration: none;
}

a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--rose);
  outline-offset: 3px;
}

p {
  margin: 0 0 1.05em;
}

/* ---------- masthead ---------- */

.masthead {
  position: sticky;
  top: 0;
  z-index: 30;
  padding: 0 var(--gutter);
  background: linear-gradient(180deg, rgba(14, 11, 20, 0.94), rgba(14, 11, 20, 0.7));
  border-bottom: 1px solid var(--line-soft);
  backdrop-filter: blur(16px) saturate(140%);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
}

.masthead-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 10px 0 6px;
  border-bottom: 1px solid var(--line-soft);
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 8px 0;
  min-height: 40px;
  font-family: var(--display);
  font-weight: 700;
  font-size: 17px;
  letter-spacing: 0.06em;
  color: var(--ink);
}

.wordmark-mark {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: var(--rose);
  color: #14060c;
  font-size: 15px;
  letter-spacing: 0;
}

.contact {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 10px 16px;
  border: 1px solid rgba(255, 92, 138, 0.5);
  border-radius: 999px;
  font-size: 16px;
  color: var(--rose);
  white-space: nowrap;
  transition: background 0.25s ease, color 0.25s ease;
}

.contact:hover {
  background: var(--rose);
  color: #14060c;
}

.dock {
  padding: 2px 0 8px;
}

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

.dock-list a {
  display: block;
  padding: 11px 12px;
  min-height: 40px;
  border-radius: 8px;
  font-size: 16px;
  line-height: 1.15;
  color: var(--ink-70);
  transition: color 0.2s ease, background 0.2s ease;
}

.dock-list a:hover {
  color: var(--ink);
  background: rgba(255, 92, 138, 0.14);
}

/* ---------- hero ---------- */

main,
.masthead,
.colophon {
  position: relative;
  z-index: 1;
}

.story {
  display: block;
}

.hero {
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: flex-end;
  min-height: min(45vh, 440px);
  padding: clamp(30px, 6vw, 58px) var(--gutter) clamp(22px, 4vw, 42px);
  border-bottom: 1px solid var(--line-soft);
}

.hero-ghost {
  position: absolute;
  top: -0.16em;
  right: calc(var(--gutter) - 0.06em);
  z-index: 0;
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(120px, 31vw, 300px);
  line-height: 0.78;
  letter-spacing: -0.04em;
  color: transparent;
  -webkit-text-stroke: 2px rgba(255, 92, 138, 0.55);
  opacity: 0.42;
  pointer-events: none;
  will-change: transform;
}

.hero-copy {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 780px;
  margin-left: auto;
  text-align: right;
}

.hero-copy h1 {
  margin: 0;
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(31px, 6.4vw, 60px);
  line-height: 1.06;
  letter-spacing: -0.02em;
  text-wrap: balance;
}

.hero-brand {
  margin: 12px 0 10px;
  font-family: var(--body);
  font-weight: 500;
  font-size: clamp(17px, 2.4vw, 21px);
  letter-spacing: 0.24em;
  color: var(--rose);
  text-transform: uppercase;
}

.subtitle {
  max-width: 52ch;
  margin: 0 0 0 auto;
  font-size: 16px;
  line-height: 1.75;
  color: var(--ink-70);
}

/* ---------- deck / rail / prose ---------- */

.deck {
  display: grid;
  grid-template-columns: 196px minmax(0, 1fr);
  gap: clamp(20px, 4vw, 56px);
  padding: clamp(26px, 5vw, 56px) var(--gutter) clamp(40px, 7vw, 90px);
}

.rail {
  align-self: start;
  position: sticky;
  top: calc(var(--stick) - 6px);
}

.rail-list {
  margin: 0;
  padding: 0;
  list-style: none;
  border-left: 1px solid var(--line-soft);
}

.rail-list li + li {
  margin-top: 2px;
}

.rail-list a {
  display: flex;
  align-items: baseline;
  gap: 10px;
  min-height: 40px;
  padding: 9px 8px 9px 14px;
  border-left: 2px solid transparent;
  margin-left: -1px;
  color: var(--ink-46);
  font-size: 16px;
  line-height: 1.3;
  transition: color 0.22s ease, border-color 0.22s ease;
}

.rail-list a:hover {
  color: var(--ink);
  border-left-color: var(--rose);
}

.rail-num {
  font-family: var(--display);
  font-size: 12px;
  letter-spacing: 0.1em;
  color: var(--rose);
  opacity: 0.8;
}

.rail-name {
  flex: 1 1 auto;
}

.prose {
  min-width: 0;
  max-width: 74ch;
}

.prose > article {
  position: relative;
  margin: 0 0 18px;
  padding: clamp(20px, 3.4vw, 42px);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background: var(--glass);
  backdrop-filter: blur(14px) saturate(130%);
  -webkit-backdrop-filter: blur(14px) saturate(130%);
  box-shadow: 0 24px 60px -46px rgba(0, 0, 0, 0.9);
  scroll-margin-top: calc(var(--stick) + 14px);
}

.prose > article:nth-child(even) {
  background: var(--glass-deep);
}

.prose > article > *:first-child {
  margin-top: 0;
}

.prose > article > *:last-child {
  margin-bottom: 0;
}

.prose h2 {
  margin: 0 0 0.7em;
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(22px, 3.1vw, 30px);
  line-height: 1.24;
  letter-spacing: -0.01em;
  color: var(--ink);
}

.prose h2::after {
  content: '';
  display: block;
  width: 44px;
  height: 3px;
  margin-top: 14px;
  border-radius: 3px;
  background: linear-gradient(90deg, var(--rose), rgba(255, 92, 138, 0));
}

.prose h3 {
  margin: 1.6em 0 0.5em;
  font-family: var(--body);
  font-weight: 700;
  font-size: 18px;
  line-height: 1.45;
  color: var(--ink);
}

.prose h3::before {
  content: '';
  display: inline-block;
  width: 8px;
  height: 8px;
  margin-right: 10px;
  border-radius: 2px;
  background: var(--rose);
  transform: translateY(-1px);
}

.prose p,
.prose li {
  color: var(--ink-70);
  font-size: 17px;
  line-height: 1.85;
}

.prose strong,
.prose b {
  color: var(--ink);
  font-weight: 700;
}

.prose a {
  color: var(--rose);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

.prose a:hover {
  color: var(--ink);
}

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

.prose li {
  margin-bottom: 0.5em;
}

.prose li::marker {
  color: var(--rose);
}

.prose blockquote {
  margin: 1.3em 0;
  padding: 14px 20px;
  border-left: 3px solid var(--rose);
  border-radius: 0 var(--radius) var(--radius) 0;
  background: rgba(255, 92, 138, 0.09);
  color: var(--ink);
}

.prose blockquote p:last-child {
  margin-bottom: 0;
}

.prose figure {
  margin: 1.3em 0;
}

.prose img {
  border-radius: var(--radius);
  border: 1px solid var(--line-soft);
}

.prose time {
  display: inline-block;
  margin-right: 8px;
  padding: 2px 9px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-family: var(--display);
  font-size: 13px;
  letter-spacing: 0.06em;
  color: var(--ink-70);
}

.prose table {
  width: 100%;
  border-collapse: collapse;
  font-size: 16px;
}

.prose th,
.prose td {
  padding: 10px 12px;
  border-bottom: 1px solid var(--line-soft);
  text-align: left;
}

.prose th {
  color: var(--ink);
  font-weight: 700;
}

/* ---------- colophon ---------- */

.colophon {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr);
  gap: clamp(20px, 4vw, 48px);
  padding: clamp(34px, 6vw, 72px) var(--gutter) clamp(20px, 3vw, 32px);
  border-top: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(255, 92, 138, 0.06), rgba(14, 11, 20, 0.9) 42%);
}

.colophon-word {
  margin: 0;
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(38px, 8.4vw, 92px);
  line-height: 0.94;
  letter-spacing: -0.03em;
  color: var(--ink);
  word-break: break-word;
}

.colophon-nav {
  margin: 0;
  padding: 0;
  list-style: none;
  columns: 2;
  column-gap: 16px;
}

.colophon-nav a {
  display: block;
  min-height: 40px;
  padding: 11px 0;
  font-size: 16px;
  color: var(--ink-70);
  border-bottom: 1px solid var(--line-soft);
  transition: color 0.2s ease;
}

.colophon-nav a:hover {
  color: var(--rose);
}

.colophon-legal {
  grid-column: 1 / -1;
  margin-top: 6px;
  padding-top: 16px;
  border-top: 1px solid var(--line-soft);
  text-align: center;
}

.colophon-legal p {
  margin: 0;
  font-size: 15px;
  letter-spacing: 0.08em;
  color: var(--ink-46);
}

/* ---------- to top ---------- */

.to-top {
  position: fixed;
  right: 16px;
  bottom: 18px;
  z-index: 40;
  display: inline-flex;
  align-items: center;
  min-height: 42px;
  padding: 11px 16px;
  border: 1px solid rgba(255, 92, 138, 0.55);
  border-radius: 999px;
  background: rgba(14, 11, 20, 0.78);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  color: var(--rose);
  font-size: 15px;
  letter-spacing: 0.06em;
  transition: background 0.22s ease, color 0.22s ease;
}

.to-top:hover {
  background: var(--rose);
  color: #14060c;
}

/* ---------- scroll reveal ---------- */

.js .prose > article,
.js .rail-list li,
.js .colophon > article {
  opacity: 0;
  transform: translate3d(0, 26px, 0);
  transition: opacity 0.7s ease, transform 0.7s cubic-bezier(0.2, 0.7, 0.2, 1);
}

.js .prose > article.in,
.js .rail-list li.in,
.js .colophon > article.in {
  opacity: 1;
  transform: none;
}

/* ---------- breakpoints ---------- */

@media (max-width: 900px) {
  :root {
    --stick: 128px;
  }

  .deck {
    grid-template-columns: minmax(0, 1fr);
    gap: 22px;
  }

  .rail {
    position: static;
  }

  .rail-list {
    display: flex;
    gap: 6px;
    overflow-x: auto;
    padding-bottom: 4px;
    border-left: 0;
    scrollbar-width: thin;
  }

  .rail-list li {
    flex: 0 0 auto;
  }

  .rail-list li + li {
    margin-top: 0;
  }

  .rail-list a {
    padding: 10px 12px;
    border: 1px solid var(--line-soft);
    border-radius: 999px;
    margin-left: 0;
    white-space: nowrap;
  }

  .rail-list a:hover {
    border-left-color: var(--line-soft);
    border-color: rgba(255, 92, 138, 0.5);
  }

  .rail-num {
    font-size: 11px;
  }

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

  .colophon-nav {
    columns: 1;
  }
}

@media (max-width: 640px) {
  .masthead-top {
    padding: 8px 0 6px;
  }

  .dock-list {
    flex-wrap: nowrap;
    overflow-x: auto;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }

  .dock-list::-webkit-scrollbar {
    display: none;
  }

  .dock-list li {
    flex: 0 0 auto;
  }

  .dock-list a {
    padding: 11px 11px;
    white-space: nowrap;
  }

  .hero {
    min-height: auto;
    padding-top: 34px;
  }

  .hero-copy {
    text-align: right;
  }

  .hero-ghost {
    top: -0.2em;
    font-size: clamp(94px, 34vw, 170px);
    opacity: 0.32;
  }

  .prose > article {
    padding: 20px 18px;
  }

  .to-top {
    right: 12px;
    bottom: 12px;
    padding: 10px 13px;
    font-size: 14px;
  }
}

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

  .js .prose > article,
  .js .rail-list li,
  .js .colophon > article {
    transition: none;
  }

  body::before,
  body::after,
  .hero-ghost {
    will-change: auto;
  }
}

button[aria-expanded]{min-width:44px;min-height:44px}
