@font-face {
  font-family: "Noto Sans TC Local";
  src: url("assets/NotoSansHant-Regular.otf") format("opentype");
  font-weight: 400 500;
  font-display: swap;
}
@font-face {
  font-family: "Noto Sans TC Local";
  src: url("assets/NotoSansHant-Bold.otf") format("opentype");
  font-weight: 600 800;
  font-display: swap;
}

:root {
  --night: #282b30;
  --night-deep: #171a1f;
  --mist: #eef1ef;
  --paper: #f3efe7;
  --paper-deep: #e7dfd2;
  --ink: #24272c;
  --muted: #686a6d;
  --brass: #a37947;
  --brass-light: #e1c591;
  --burgundy: #713d44;
  --line: rgba(59, 68, 73, .16);
  --max: 1120px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(circle at 1px 1px, rgba(42, 44, 48, .045) 1px, transparent 1.1px) 0 0 / 12px 12px,
    var(--paper);
  font-family: "Noto Sans TC Local", sans-serif;
  line-height: 1.75;
}
a { color: inherit; }

.site-header {
  position: absolute;
  z-index: 5;
  top: 0;
  left: 50%;
  width: min(100%, var(--max));
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 24px 28px;
  color: #fff;
}
.brand {
  display: flex;
  align-items: center;
  gap: 11px;
  font-family: "Noto Sans TC Local", sans-serif;
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: .12em;
  text-decoration: none;
  white-space: nowrap;
}
.brand-mark {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  color: rgba(255,255,255,.86);
}
.brand-mark img {
  width: 32px;
  height: 32px;
  display: block;
}
}
nav { display: flex; gap: 30px; }
nav a {
  font-size: .9rem;
  text-decoration: none;
  text-shadow: 0 1px 10px rgba(0,0,0,.35);
  white-space: nowrap;
}
nav a:hover { color: var(--brass-light); }

.hero {
  position: relative;
  min-height: 710px;
  height: min(86vh, 860px);
  overflow: hidden;
  display: flex;
  align-items: center;
  color: #fff;
  border-bottom: 5px solid var(--ink);
  background: var(--night-deep);
}
.hero-art {
  position: absolute;
  inset: 0;
  display: block;
}
.hero-art img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  object-position: center;
  filter: saturate(.88) contrast(1.02);
}
.hero-shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(19,22,27,.88) 0%, rgba(24,27,32,.68) 34%, rgba(20,23,28,.17) 66%, rgba(20,23,28,.04) 100%),
    linear-gradient(0deg, rgba(19,22,27,.42), transparent 46%);
}
.hero-content {
  position: relative;
  z-index: 2;
  width: min(100%, var(--max));
  margin: 0 auto;
  padding: 84px 28px 40px;
}
.eyebrow, .section-kicker {
  margin: 0 0 10px;
  color: var(--brass-light);
  font-size: .78rem;
  font-weight: 600;
  letter-spacing: .17em;
}
h1, h2, h3 { font-family: "Noto Sans TC Local", sans-serif; }
h1 {
  margin: 0;
  font-size: 8rem;
  line-height: 1.05;
  letter-spacing: .14em;
  text-shadow: 3px 3px 0 rgba(0,0,0,.26), 0 3px 24px rgba(0,0,0,.3);
}
.hero-tagline {
  max-width: 610px;
  margin: 22px 0 0;
  font-size: clamp(1.24rem, 2vw, 1.75rem);
  font-weight: 700;
  letter-spacing: .055em;
  line-height: 1.55;
  color: #fff7e7;
}
.hero-copy {
  max-width: 590px;
  margin: 14px 0 32px;
  font-family: "Noto Sans TC Local", sans-serif;
  font-size: 1.1rem;
  line-height: 2;
  color: rgba(255,255,255,.9);
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 10px 21px;
  border: 1px solid rgba(255,255,255,.45);
  text-decoration: none;
  font-size: .93rem;
  letter-spacing: .06em;
  box-shadow: 3px 3px 0 rgba(10,12,14,.32);
  transition: .2s ease;
}
.button-primary {
  color: #1e2931;
  background: #e6d3ad;
  border-color: #e6d3ad;
}
.button-quiet { background: rgba(18,21,25,.36); backdrop-filter: blur(8px); }
.button:hover { transform: translateY(-2px); }
.scroll-cue {
  position: absolute;
  z-index: 2;
  left: 50%;
  bottom: 22px;
  transform: translateX(-50%);
  font-size: .78rem;
  letter-spacing: .12em;
  text-decoration: none;
  color: rgba(255,255,255,.74);
}

.content-section {
  width: min(calc(100% - 48px), var(--max));
  margin: 0 auto;
  padding: 92px 0;
}
.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 30px;
}
.section-heading h2, .about-grid h2 {
  margin: 0;
  font-size: 3rem;
  line-height: 1.35;
  letter-spacing: .04em;
}
.section-kicker { color: #8b6941; }
.chapter-date { color: var(--muted); font-size: .85rem; }
.latest-card {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 32px;
  padding: 46px;
  border: 2px solid rgba(42, 44, 48, .2);
  border-left: 6px solid var(--burgundy);
  background: rgba(255,255,255,.46);
  box-shadow: 0 24px 70px rgba(42,51,57,.08);
}
.latest-number {
  font-family: "Noto Sans TC Local", sans-serif;
  font-size: 4rem;
  line-height: 1;
  color: var(--brass);
  border-right: 1px solid var(--line);
}
.latest-card h3 { margin: 0 0 12px; font-size: 1.65rem; }
.latest-card p { max-width: 720px; margin: 0 0 18px; color: #56616a; }
.text-link { color: #785a37; font-weight: 600; text-decoration: none; }

.chapter-list { margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--line); }
.chapter-list li { border-bottom: 1px solid var(--line); }
.chapter-list a {
  display: grid;
  grid-template-columns: 70px 1fr auto;
  gap: 20px;
  align-items: center;
  min-height: 78px;
  padding: 12px 8px;
  text-decoration: none;
  transition: padding .2s ease, background .2s ease;
}
.chapter-list a:hover { padding-left: 18px; background: rgba(255,255,255,.52); }
.chapter-list span { color: var(--brass); font-family: "Noto Sans TC Local", sans-serif; }
.chapter-list strong { font-family: "Noto Sans TC Local", sans-serif; font-size: 1.05rem; }
.chapter-list em { color: var(--muted); font-size: .82rem; font-style: normal; }
.prototype-note { margin: 20px 0 0; color: var(--muted); font-size: .84rem; }

.about-wrap {
  border-top: 2px solid rgba(42, 44, 48, .14);
  background:
    linear-gradient(135deg, rgba(255,255,255,.28), transparent 54%),
    #dedfd9;
}
.about-grid {
  display: grid;
  grid-template-columns: .9fr 1.1fr;
  gap: 70px;
  align-items: start;
}
.about-grid > p { margin: 5px 0 0; font-family: "Noto Sans TC Local", sans-serif; font-size: 1.08rem; line-height: 2.05; color: #4d5a62; }

footer {
  display: flex;
  justify-content: space-between;
  gap: 30px;
  padding: 42px max(24px, calc((100% - var(--max)) / 2));
  color: rgba(255,255,255,.7);
  background: var(--night);
  font-size: .8rem;
}
footer strong { color: #fff; font-family: "Noto Sans TC Local", sans-serif; font-size: 1.1rem; }
footer p { margin: 4px 0 0; }
footer > div > p {
  display: flex;
  align-items: center;
  gap: 7px;
}
footer > div > p::before {
  content: "";
  flex: 0 0 auto;
  width: 40px;
  height: 32px;
  border: 2px solid var(--paper-deep);
  border-radius: 7px;
  background-color: #050505;
  background-image: url("assets/kuchi-logo.jpg");
  background-repeat: no-repeat;
  background-position: center;
  background-size: contain;
  box-shadow: 0 0 0 1px rgba(163, 121, 71, .9);
}

/* Chapter reader */
.reader-page { background-color: #f6f2ea; }
.reading-progress {
  position: fixed;
  z-index: 30;
  top: 0;
  left: 0;
  width: 100%;
  height: 3px;
  background: rgba(255,255,255,.12);
}
.reading-progress span {
  display: block;
  width: 100%;
  height: 100%;
  transform: scaleX(0);
  transform-origin: left center;
  background: var(--brass-light);
}
.reader-site-header {
  position: sticky;
  z-index: 20;
  top: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 72px;
  padding: 14px max(24px, calc((100% - var(--max)) / 2));
  color: #fff;
  background: rgba(27,30,35,.97);
  box-shadow: 0 8px 30px rgba(14,17,20,.18);
}
.reader-site-header .brand-mark { color: rgba(255,255,255,.84); }
.reader-nav { gap: 0; }
.reader-nav a + a { margin-left: 24px; }
.reader-nav a { color: rgba(255,255,255,.8); }
.chapter-masthead {
  position: relative;
  min-height: 360px;
  display: flex;
  align-items: end;
  overflow: hidden;
  color: #fff;
  background: var(--night-deep);
  border-bottom: 4px solid var(--ink);
}
.chapter-masthead-art {
  position: absolute;
  inset: 0;
  background-image: url("assets/hero-v2.webp");
  background-position: center 42%;
  background-size: cover;
  opacity: .66;
  filter: saturate(.72);
}
.chapter-masthead-shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(20,23,28,.95), rgba(20,23,28,.62) 52%, rgba(20,23,28,.2)),
    linear-gradient(0deg, rgba(20,23,28,.58), transparent 68%);
}
.chapter-masthead-inner {
  position: relative;
  z-index: 1;
  width: min(calc(100% - 48px), 880px);
  margin: 0 auto;
  padding: 60px 0 48px;
}
.chapter-label {
  margin: 0 0 12px;
  color: var(--brass-light);
  font-size: .76rem;
  font-weight: 700;
  letter-spacing: .22em;
}
.chapter-masthead h1 {
  max-width: 720px;
  margin: 0;
  font-size: 3.25rem;
  line-height: 1.35;
  letter-spacing: .055em;
  text-shadow: 0 3px 24px rgba(0,0,0,.32);
}
.chapter-meta {
  display: flex;
  gap: 18px;
  margin-top: 22px;
  color: rgba(255,255,255,.7);
  font-size: .82rem;
  letter-spacing: .04em;
}
.chapter-meta span + span::before {
  content: "·";
  margin-right: 18px;
  color: var(--brass-light);
}
.reader-layout {
  width: min(calc(100% - 40px), 760px);
  margin: 0 auto;
  padding: 76px 0 100px;
}
.reader-article {
  font-family: "Noto Sans TC Local", sans-serif;
  color: #30343a;
}
.reader-article p {
  margin: 0 0 1.42em;
  font-size: 1.075rem;
  line-height: 2.08;
  letter-spacing: .025em;
}
.reader-article .chapter-opening {
  margin-bottom: 1.7em;
  padding-left: 20px;
  border-left: 3px solid var(--burgundy);
  color: #22272d;
  font-size: 1.2rem;
  font-weight: 600;
  line-height: 1.95;
}
.scene-break {
  display: flex;
  align-items: center;
  gap: 18px;
  margin: 50px 0;
  color: var(--brass);
  font-size: .58rem;
}
.scene-break::before, .scene-break::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--line);
}
.chapter-end {
  margin-top: 66px;
  padding-top: 34px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  text-align: center;
  font-size: .82rem;
  letter-spacing: .2em;
}
.chapter-pagination {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-top: 62px;
}
.chapter-nav-card {
  min-height: 112px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 20px 22px;
  border: 1px solid var(--line);
  background: rgba(255,255,255,.52);
  text-decoration: none;
  transition: transform .2s ease, background .2s ease;
}
.chapter-nav-card small {
  margin-bottom: 7px;
  color: var(--brass);
  font-size: .75rem;
  letter-spacing: .12em;
}
.chapter-nav-card strong { font-size: .94rem; line-height: 1.55; }
.chapter-nav-next { text-align: right; }
.chapter-nav-card:not(.is-disabled):hover {
  transform: translateY(-2px);
  background: rgba(255,255,255,.84);
}
.chapter-nav-card.is-disabled { opacity: .5; }
.back-to-index { margin-top: 30px; text-align: center; }

@media (max-width: 720px) {
  .site-header { padding: 18px 20px; }
  nav { gap: 15px; }
  nav a:nth-child(2), nav a:nth-child(3) { display: none; }
  .hero { min-height: 690px; height: 86svh; }
  .hero-art img { object-position: 66% center; }
  .hero-shade {
    background:
      linear-gradient(0deg, rgba(20,22,27,.88) 0%, rgba(20,22,27,.22) 78%),
      linear-gradient(90deg, rgba(20,22,27,.44), transparent 85%);
  }
  .hero-content { align-self: end; padding: 110px 22px 82px; }
  h1 { font-size: 5rem; letter-spacing: .09em; }
  .hero-tagline { margin-top: 15px; font-size: 1.2rem; }
  .hero-copy { margin: 10px 0 24px; font-size: .96rem; line-height: 1.82; }
  .hero-actions { display: grid; grid-template-columns: 1fr 1fr; }
  .button { min-height: 46px; padding: 9px 12px; font-size: .85rem; }
  .scroll-cue { display: none; }
  .content-section { width: min(calc(100% - 36px), var(--max)); padding: 68px 0; }
  .section-heading { align-items: start; flex-direction: column; gap: 4px; }
  .latest-card { grid-template-columns: 1fr; gap: 18px; padding: 28px 24px; }
  .latest-number { padding-bottom: 15px; border-right: 0; border-bottom: 1px solid var(--line); font-size: 3rem; }
  .latest-card h3 { font-size: 1.35rem; }
  .chapter-list a { grid-template-columns: 43px 1fr; gap: 10px; min-height: 72px; padding: 12px 0; }
  .chapter-list em { display: none; }
  .about-grid { grid-template-columns: 1fr; gap: 24px; }
  footer { flex-direction: column; padding: 34px 20px; }
  .reader-site-header { min-height: 64px; padding: 12px 18px; }
  .reader-site-header .brand { font-size: 1rem; }
  .reader-site-header .brand-mark { width: 31px; height: 31px; }
  .reader-nav { gap: 14px; }
  .reader-nav a + a { margin-left: 0; }
  .reader-nav a:last-child { display: none; }
  .chapter-masthead { min-height: 300px; }
  .chapter-masthead-art { background-position: 63% 42%; }
  .chapter-masthead-shade {
    background:
      linear-gradient(90deg, rgba(20,23,28,.88), rgba(20,23,28,.46)),
      linear-gradient(0deg, rgba(20,23,28,.72), transparent 72%);
  }
  .chapter-masthead-inner { width: min(calc(100% - 36px), 880px); padding: 50px 0 34px; }
  .chapter-masthead h1 { font-size: 2.15rem; line-height: 1.42; }
  .chapter-meta { gap: 12px; margin-top: 17px; font-size: .75rem; }
  .chapter-meta span + span::before { margin-right: 12px; }
  .reader-layout { width: min(calc(100% - 36px), 760px); padding: 54px 0 72px; }
  .reader-article p { font-size: 1.035rem; line-height: 2.02; letter-spacing: .018em; }
  .reader-article .chapter-opening { font-size: 1.11rem; }
  .scene-break { margin: 42px 0; }
  .chapter-pagination { grid-template-columns: 1fr; }
  .chapter-nav-card { min-height: 96px; }
  .chapter-nav-next { text-align: left; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}
