/* =========================================================
   Andantino Music Studio — shared styles for sub pages
   (tokens & components mirror the inline CSS in index.html)
   ========================================================= */

:root {
  --bg: #f5f1ea;
  --bg-deep: #ebe4d6;
  --paper: #faf7f1;
  --ink: #1f1d1a;
  --ink-2: #3c3833;
  --ink-3: #6b655c;
  --ink-4: #9a9387;
  --line: #d8cfbe;
  --line-2: #c4b89f;
  --accent: #8a6e4b;
  --accent-2: #b08a5c;
  --dark: #2b2520;
  --serif: "Noto Serif TC", "Cormorant Garamond", "Gowun Batang", serif;
  --serif-en: "Cormorant Garamond", "Noto Serif TC", serif;
  --sans: "Inter", "Noto Sans TC", system-ui, sans-serif;
  --sans-tc: "Noto Sans TC", "Inter", system-ui, sans-serif;
  --ko: "Gowun Batang", "Noto Serif TC", serif;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans-tc);
  font-weight: 400;
  font-size: 15px;
  line-height: 1.65;
  letter-spacing: 0.01em;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 100;
  opacity: 0.35;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml;utf8,<svg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0.55  0 0 0 0 0.5  0 0 0 0 0.42  0 0 0 0.06 0'/></filter><rect width='200' height='200' filter='url(%23n)'/></svg>");
}

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

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

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

/* ============================= NAV ============================= */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  height: 64px;
  padding: 0 56px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  background: color-mix(in srgb, var(--bg) 86%, transparent);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid color-mix(in srgb, var(--line) 50%, transparent);
}

.nav-mark {
  font-family: var(--serif-en);
  font-size: 22px;
  letter-spacing: 0.02em;
  display: inline-flex;
  align-items: baseline;
  gap: 12px;
  white-space: nowrap;
}

.mark-serif {
  font-weight: 500;
}

.nav-cn {
  font-family: var(--serif);
  font-size: 13px;
  color: var(--ink-3);
  padding-left: 12px;
  border-left: 1px solid var(--line);
  letter-spacing: 0.04em;
  white-space: nowrap;
}

.nav-links {
  display: flex;
  gap: 28px;
  justify-content: center;
  font-family: var(--serif-en);
  font-size: 15px;
  letter-spacing: 0.04em;
}

.nav-links a {
  color: var(--ink-2);
  position: relative;
  padding: 4px 0;
  transition: color 0.2s;
}

.nav-links a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 1px;
  background: var(--ink);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s ease;
}

.nav-links a:hover,
.nav-links a[aria-current="page"] {
  color: var(--ink);
}

.nav-links a:hover::after,
.nav-links a[aria-current="page"]::after {
  transform: scaleX(1);
}

.nav-cta {
  justify-self: end;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 9px 16px 9px 18px;
  background: var(--dark);
  color: var(--bg);
  border-radius: 999px;
  font-size: 13px;
  letter-spacing: 0.08em;
  transition: background 0.2s, transform 0.2s;
}

.nav-cta:hover {
  background: var(--accent);
  transform: translateX(2px);
}

/* ============================= LAYOUT BASE ============================= */
.section {
  padding: 140px 56px 80px;
  position: relative;
  scroll-margin-top: 76px;
}

.sec-head {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 40px;
  margin-bottom: 64px;
  align-items: end;
}

.sec-num {
  font-family: var(--serif-en);
  font-size: 13px;
  letter-spacing: 0.15em;
  color: var(--ink-3);
  text-transform: uppercase;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
}

.sec-title {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(34px, 4.4vw, 56px);
  line-height: 1.15;
  letter-spacing: -0.01em;
  margin: 0;
  color: var(--ink);
}

.sec-title em {
  font-family: var(--serif-en);
  font-style: italic;
  font-weight: 300;
  color: var(--ink-3);
  font-size: 0.62em;
  letter-spacing: 0.01em;
  display: inline-block;
  margin-top: 6px;
}

.kicker {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--serif-en);
  font-size: 12px;
  letter-spacing: 0.22em;
  color: var(--accent);
  text-transform: uppercase;
}

.kicker .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
}

.sec-body {
  margin-left: 240px;
  max-width: 880px;
}

.lede {
  font-family: var(--serif);
  font-size: 20px;
  line-height: 1.8;
  color: var(--ink-2);
  margin: 0 0 32px;
  text-wrap: pretty;
}

.fine {
  font-size: 13px;
  line-height: 1.8;
  color: var(--ink-3);
  margin: 32px 0 0;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}


/* ============================= APPROACH (course-card family) ============================= */
.approach-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

.course-card {
  background: var(--paper);
  border: 1px solid var(--line);
  padding: 36px 32px 32px;
  border-radius: 2px;
  display: flex;
  flex-direction: column;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.course-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 24px 48px -28px rgba(31, 29, 26, 0.2);
}

.course-card.dark {
  background: var(--dark);
  color: var(--bg);
  border-color: var(--dark);
}

.course-card.dark .course-desc {
  color: color-mix(in srgb, var(--bg) 80%, transparent);
}

.course-card.dark .course-num {
  color: color-mix(in srgb, var(--bg) 60%, transparent);
}

.course-card.dark .course-ko {
  color: var(--accent-2);
}

.course-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 20px;
}

.course-ko {
  font-family: var(--ko);
  font-size: 18px;
  color: var(--accent);
  letter-spacing: 0.05em;
}

.course-num {
  font-family: var(--serif-en);
  font-style: italic;
  font-size: 13px;
  color: var(--ink-3);
  letter-spacing: 0.06em;
}

.course-title {
  font-family: var(--serif);
  font-size: 26px;
  font-weight: 400;
  line-height: 1.3;
  margin: 0 0 14px;
  letter-spacing: -0.01em;
}

.course-desc {
  font-size: 14px;
  line-height: 1.85;
  color: var(--ink-2);
  margin: 0;
}

/* ============================= TRIAL ============================= */
.trial {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 56px;
  padding: 48px;
}

.trial .course-title {
  font-size: 34px;
}

.trial-tags {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 1px solid color-mix(in srgb, var(--bg) 18%, transparent);
}

.trial-tags li {
  display: flex;
  gap: 14px;
  align-items: baseline;
  padding: 14px 0;
  border-bottom: 1px dashed color-mix(in srgb, var(--bg) 18%, transparent);
  font-family: var(--serif);
  font-size: 17px;
}

.trial-tags li span {
  font-family: var(--serif-en);
  font-style: italic;
  font-size: 13px;
  color: var(--accent-2);
  min-width: 22px;
}

.closing {
  text-align: center;
  max-width: 640px;
  margin: 96px auto 0;
}

.closing h3 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(30px, 3.6vw, 44px);
  line-height: 1.3;
  margin: 20px 0 20px;
}

.closing p {
  font-size: 15px;
  line-height: 1.95;
  color: var(--ink-2);
  margin: 0 0 32px;
  text-wrap: pretty;
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
}

.trial-cta {
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 14px 20px;
  background: var(--ink);
  color: var(--bg);
  font-family: var(--serif-en);
  font-size: 14px;
  letter-spacing: 0.06em;
  border-radius: 2px;
  border: 1px solid var(--ink);
  transition: background 0.2s, color 0.2s, border-color 0.2s;
}

.trial-cta span {
  font-family: var(--sans-tc);
  letter-spacing: 0.05em;
}

.trial-cta:hover {
  background: var(--accent);
  border-color: var(--accent);
}

.trial-cta.ghost {
  background: transparent;
  color: var(--ink);
}

.trial-cta.ghost:hover {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--bg);
}

/* ============================= CONTACT / FOOTER ============================= */
.contact {
  background: var(--dark);
  color: var(--bg);
  margin-top: 40px;
  padding: 56px 56px 32px;
}

.foot {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 24px;
}

.foot-mark {
  display: inline-flex;
  align-items: baseline;
  gap: 14px;
  font-family: var(--serif-en);
  font-size: 18px;
}

.foot-cn {
  font-family: var(--serif);
  font-size: 13px;
  color: color-mix(in srgb, var(--bg) 55%, transparent);
  padding-left: 12px;
  border-left: 1px solid color-mix(in srgb, var(--bg) 18%, transparent);
}

.foot-mid {
  font-family: var(--serif);
  font-size: 14px;
  color: color-mix(in srgb, var(--bg) 70%, transparent);
  text-align: center;
}

.foot-mid em {
  font-family: var(--serif-en);
  font-style: italic;
  color: var(--accent-2);
  margin-left: 6px;
}

.foot-r {
  font-family: var(--serif-en);
  font-style: italic;
  font-size: 12px;
  text-align: right;
  color: color-mix(in srgb, var(--bg) 45%, transparent);
  letter-spacing: 0.04em;
}

.foot-social {
  display: inline-flex;
  justify-self: end;
  gap: 8px;
  margin-top: 8px;
}

.social-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border: 1px solid color-mix(in srgb, var(--bg) 24%, transparent);
  border-radius: 2px;
  font-family: var(--serif-en);
  font-size: 13px;
  letter-spacing: 0.04em;
  color: var(--bg);
  transition: background 0.2s, border-color 0.2s, color 0.2s;
}

.social-link:hover {
  background: var(--accent-2);
  border-color: var(--accent-2);
  color: var(--bg);
}

/* ============================= SCROLL ANIM ============================= */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.9s ease, transform 0.9s cubic-bezier(0.22, 1, 0.36, 1);
}

.reveal.in {
  opacity: 1;
  transform: none;
}

.reveal-delay-1 {
  transition-delay: 0.08s;
}

.reveal-delay-2 {
  transition-delay: 0.16s;
}

.reveal-delay-3 {
  transition-delay: 0.24s;
}


/* ============================= RESPONSIVE ============================= */
@media (max-width: 1100px) {
  .nav {
    padding: 0 28px;
    grid-template-columns: auto 1fr auto;
  }

  .nav-links {
    gap: 22px;
  }

  .section,
  .contact {
    padding-left: 28px;
    padding-right: 28px;
  }

  .sec-head {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .sec-body {
    margin-left: 0;
  }

  .trial {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .foot {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .foot-r,
  .foot-mid {
    text-align: center;
  }

  .foot-social {
    justify-self: center;
    justify-content: center;
  }
}

@media (max-width: 900px) {
  .nav {
    grid-template-columns: 1fr auto;
    grid-template-rows: 62px 42px;
    height: 104px;
    padding: 0;
    align-items: center;
  }

  .nav-mark {
    margin-left: 28px;
  }

  .nav-links {
    grid-column: 1 / -1;
    grid-row: 2;
    height: 42px;
    padding: 0 28px;
    gap: 0;
    justify-content: flex-start;
    align-items: center;
    overflow-x: auto;
    overflow-y: hidden;
    border-top: 1px solid color-mix(in srgb, var(--line) 55%, transparent);
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }

  .nav-links::-webkit-scrollbar {
    display: none;
  }

  .nav-links a {
    flex: 0 0 auto;
    min-height: 40px;
    display: inline-flex;
    align-items: center;
    padding: 0 14px;
    font-size: 13px;
    letter-spacing: 0.08em;
  }

  .nav-links a:first-child {
    padding-left: 0;
  }

  .nav-cta {
    margin-right: 28px;
  }

  .section {
    scroll-margin-top: 116px;
  }

  .approach-grid {
    grid-template-columns: 1fr;
  }

  .trial {
    padding: 36px 28px;
  }
}

@media (max-width: 640px) {
  .nav {
    grid-template-rows: 56px 40px;
    height: 96px;
  }

  .nav-mark {
    margin-left: 20px;
    font-size: 20px;
  }

  .nav-cn {
    display: none;
  }

  .nav-links {
    height: 40px;
    padding: 0 20px;
  }

  .nav-links a {
    min-height: 38px;
    padding: 0 12px;
    font-size: 12px;
  }

  .nav-cta {
    margin-right: 20px;
    padding: 8px 12px;
    font-size: 12px;
  }

  .section,
  .contact {
    padding-left: 20px;
    padding-right: 20px;
  }

  .section {
    padding-top: 96px;
    scroll-margin-top: 108px;
  }

  .lede {
    font-size: 17px;
  }

  .course-card {
    padding: 28px 22px 26px;
  }

  .trial .course-title {
    font-size: 28px;
  }

  .cta-row .trial-cta {
    width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

/* ============================= JOURNAL — ARTICLE LIST ============================= */
.journal-head {
  padding-top: 152px;
}

.post-list {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--line-2);
}

.post-row {
  display: grid;
  grid-template-columns: 200px 1fr 40px;
  gap: 40px;
  align-items: baseline;
  padding: 32px 0;
  border-bottom: 1px solid var(--line);
  transition: padding-left 0.25s;
}

.post-row:hover {
  padding-left: 8px;
}

.post-date {
  font-family: var(--serif-en);
  font-style: italic;
  font-size: 15px;
  color: var(--accent);
}

.post-date small {
  display: block;
  font-size: 12px;
  color: var(--ink-3);
  letter-spacing: 0.06em;
  margin-top: 4px;
}

.post-title {
  font-family: var(--serif);
  font-size: 26px;
  font-weight: 400;
  line-height: 1.4;
  margin: 0 0 10px;
  color: var(--ink);
}

.post-excerpt {
  margin: 0;
  font-size: 14px;
  line-height: 1.85;
  color: var(--ink-2);
  max-width: 640px;
}

.post-arr {
  justify-self: end;
  font-family: var(--serif-en);
  font-size: 24px;
  color: var(--accent);
  transition: transform 0.25s;
}

.post-row:hover .post-arr {
  transform: translateX(4px);
}

/* ============================= GUIDE PAGES (moved from adult-piano.html) ============================= */
/* ============================= GUIDE HERO ============================= */
.guide-hero {
  padding: 152px 56px 88px;
}

.guide-grid {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: 72px;
  align-items: start;
}

.guide-title {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(46px, 6vw, 82px);
  line-height: 1.08;
  letter-spacing: -0.02em;
  margin: 24px 0 28px;
}

.guide-title em {
  display: block;
  font-style: normal;
  font-size: 0.46em;
  line-height: 1.4;
  letter-spacing: 0;
  color: var(--ink-3);
  margin-top: 18px;
}

.guide-sub {
  font-size: 15px;
  line-height: 1.9;
  color: var(--ink-2);
  max-width: 480px;
  margin: 0;
  text-wrap: pretty;
}

.q-list {
  list-style: none;
  margin: 0 0 20px;
  padding: 0;
  border-top: 1px solid var(--line);
}

.q-list li {
  display: grid;
  grid-template-columns: 56px 1fr;
  align-items: baseline;
  padding: 20px 0;
  border-bottom: 1px solid var(--line);
  font-family: var(--serif);
  font-size: 21px;
  line-height: 1.5;
}

.q-mark {
  font-family: var(--serif-en);
  font-style: italic;
  font-size: 15px;
  color: var(--accent);
}

.q-after {
  font-family: var(--serif-en);
  font-style: italic;
  color: var(--ink-3);
  font-size: 15px;
  margin: 0 0 28px;
}

.q-after span {
  font-family: var(--serif);
  font-style: normal;
  margin-right: 8px;
  color: var(--ink-2);
}

.insight {
  background: var(--dark);
  color: var(--bg);
  padding: 32px;
  border-radius: 2px;
}

.insight-k {
  font-family: var(--serif-en);
  font-style: italic;
  font-size: 13px;
  color: var(--accent-2);
  letter-spacing: 0.04em;
}

.insight strong {
  display: block;
  font-family: var(--serif);
  font-weight: 400;
  font-size: 26px;
  line-height: 1.45;
  margin: 12px 0 16px;
}

.insight p {
  margin: 0;
  font-size: 14px;
  line-height: 1.85;
  color: color-mix(in srgb, var(--bg) 78%, transparent);
}

/* ============================= SKILLS ============================= */
.skills {
  background: color-mix(in srgb, var(--bg-deep) 72%, var(--bg));
}

.skill-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  border-top: 1px solid var(--line-2);
  border-bottom: 1px solid var(--line-2);
}

.skill-list li {
  padding: 28px 20px 32px;
  border-left: 1px solid var(--line);
}

.skill-list li:first-child {
  border-left: 0;
  padding-left: 0;
}

.skill-n {
  display: block;
  font-family: var(--serif-en);
  font-style: italic;
  font-size: 15px;
  color: var(--accent);
  margin-bottom: 14px;
}

.skill-t {
  font-family: var(--serif);
  font-size: 18px;
  line-height: 1.5;
  color: var(--ink);
}

/* ============================= TIMELINE ============================= */
.levels {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--line);
}

.level {
  display: grid;
  grid-template-columns: 96px 1fr 200px;
  gap: 32px;
  align-items: baseline;
  padding: 32px 0;
  border-bottom: 1px solid var(--line);
}

.level-n {
  font-family: var(--serif-en);
  font-weight: 300;
  font-size: 56px;
  line-height: 1;
  color: var(--accent);
}

.level-ko {
  font-family: var(--serif-en);
  font-style: italic;
  font-size: 13px;
  color: var(--ink-3);
  letter-spacing: 0.06em;
}

.level h3 {
  font-family: var(--serif);
  font-size: 26px;
  font-weight: 400;
  line-height: 1.3;
  margin: 4px 0 10px;
}

.level p {
  margin: 0;
  font-size: 14px;
  line-height: 1.8;
  color: var(--ink-2);
}

.level-time {
  justify-self: end;
  text-align: right;
  font-family: var(--serif);
  font-size: 20px;
  color: var(--ink);
  white-space: nowrap;
}

.level-time small {
  display: block;
  font-family: var(--serif-en);
  font-style: italic;
  font-size: 12px;
  color: var(--ink-3);
  letter-spacing: 0.06em;
  margin-top: 4px;
}

/* progress bar under each level */
.level-bar {
  grid-column: 2 / -1;
  height: 2px;
  background: var(--line);
  position: relative;
  margin-top: 4px;
}

.level-bar::after {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: var(--w);
  background: var(--accent-2);
}


@media (max-width: 1100px) {
  .guide-hero {
    padding-left: 28px;
    padding-right: 28px;
  }

  .guide-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .skill-list {
    grid-template-columns: 1fr 1fr;
  }

  .skill-list li,
  .skill-list li:first-child {
    padding: 22px 20px 24px 0;
    border-left: 0;
    border-top: 1px solid var(--line);
  }

  .skill-list li:nth-child(-n+2) {
    border-top: 0;
  }
}

@media (max-width: 900px) {
  .guide-hero {
    padding-top: 160px;
  }

  .level {
    grid-template-columns: 64px 1fr;
    gap: 8px 20px;
  }

  .level-n {
    font-size: 40px;
  }

  .level-time {
    grid-column: 2;
    justify-self: start;
    text-align: left;
  }
}

@media (max-width: 640px) {
  .guide-hero {
    padding: 144px 20px 88px;
  }

  .q-list li {
    grid-template-columns: 40px 1fr;
    font-size: 18px;
  }

  .skill-list {
    grid-template-columns: 1fr;
  }

  .skill-list li:nth-child(2) {
    border-top: 1px solid var(--line);
  }
}

/* ============================= BLOG POST (template for articles/*.html) ============================= */
/*
  Structure:
  .post-header  → breadcrumb, h1.post-h1, dek (one-line summary), meta (date · reading time)
  .post-layout  → aside.post-toc (built by site.js from h2[id]) + .post-body
  .post-body    → .key-points, h2/h3, p, .pull, .note, .point-list, .takeaway
*/
.post {
  padding: 136px 56px 40px;
}

.post-header {
  max-width: 1000px;
  margin: 0 0 56px 260px;
}

.post-crumb {
  font-family: var(--serif-en);
  font-size: 13px;
  letter-spacing: 0.08em;
  color: var(--ink-3);
}

.post-crumb a {
  color: var(--accent);
}

.post-crumb a:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.post-h1 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(32px, 4.2vw, 52px);
  line-height: 1.3;
  letter-spacing: -0.01em;
  margin: 18px 0 18px;
  text-wrap: balance;
}

.post-h1 small {
  display: block;
  font-size: 0.42em;
  letter-spacing: 0.06em;
  color: var(--accent);
  margin-bottom: 10px;
}

.post-dek {
  font-size: 17px;
  line-height: 1.85;
  color: var(--ink-2);
  max-width: 720px;
  margin: 0 0 22px;
  text-wrap: pretty;
}

.post-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 18px;
  font-size: 13px;
  color: var(--ink-3);
  padding-top: 16px;
  border-top: 1px solid var(--line);
  max-width: 720px;
}

.post-meta span + span::before {
  content: "·";
  margin-right: 18px;
  color: var(--line-2);
}

.post-layout {
  display: grid;
  grid-template-columns: 220px minmax(0, 720px);
  gap: 40px;
  align-items: start;
}

/* ---- table of contents ---- */
.post-toc {
  position: sticky;
  top: 96px;
  font-size: 13.5px;
}

.post-toc summary {
  list-style: none;
  font-family: var(--serif-en);
  font-size: 13px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--ink-3);
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 8px;
  pointer-events: none;
}

.post-toc summary::-webkit-details-marker {
  display: none;
}

.post-toc ol {
  list-style: none;
  margin: 0;
  padding: 0;
  counter-reset: toc;
}

.post-toc li {
  counter-increment: toc;
}

.post-toc a {
  display: grid;
  grid-template-columns: 28px 1fr;
  padding: 8px 0;
  line-height: 1.55;
  color: var(--ink-3);
  transition: color 0.2s;
}

.post-toc a::before {
  content: counter(toc, decimal-leading-zero);
  font-family: var(--serif-en);
  font-style: italic;
  color: var(--accent-2);
}

.post-toc a:hover,
.post-toc a.active {
  color: var(--ink);
}

.post-toc a.active::before {
  color: var(--accent);
}

/* ---- body ---- */
.post-body {
  font-size: 16px;
  line-height: 2;
  color: var(--ink-2);
  counter-reset: h2;
}

.post-body p {
  margin: 0 0 1.3em;
  text-wrap: pretty;
}

/* key sentences: highlighter mark so skimmers catch them */
.post-body strong {
  font-weight: 500;
  color: var(--ink);
  background: linear-gradient(transparent 62%, color-mix(in srgb, var(--accent-2) 30%, transparent) 62%);
  padding: 0 1px;
}

.post-body h2 {
  counter-increment: h2;
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(24px, 2.6vw, 30px);
  line-height: 1.4;
  color: var(--ink);
  margin: 72px 0 24px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
  scroll-margin-top: 96px;
}

.post-body h2::before {
  content: counter(h2, decimal-leading-zero);
  display: block;
  font-family: var(--serif-en);
  font-style: italic;
  font-weight: 400;
  font-size: 15px;
  color: var(--accent);
  margin-bottom: 4px;
}

.post-body h2.no-num::before {
  content: none;
}

.post-body h3 {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 19px;
  line-height: 1.5;
  color: var(--ink);
  margin: 36px 0 8px;
}

/* key points box at the top */
.key-points {
  background: var(--paper);
  border: 1px solid var(--line);
  border-top: 3px solid var(--accent-2);
  border-radius: 2px;
  padding: 26px 30px 24px;
  margin: 0 0 48px;
}

.key-points-k {
  font-family: var(--serif);
  font-size: 17px;
  color: var(--ink);
  margin: 0 0 12px;
}

.key-points-k em {
  font-family: var(--serif-en);
  font-size: 14px;
  color: var(--ink-3);
  margin-left: 8px;
}

.key-points ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.key-points li {
  position: relative;
  padding: 7px 0 7px 24px;
  font-size: 15px;
  line-height: 1.8;
  color: var(--ink);
}

.key-points li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: var(--accent);
  font-weight: 600;
}

/* quote */
.post-body .pull {
  margin: 36px 0;
  padding: 2px 0 2px 24px;
  border-left: 2px solid var(--accent-2);
  font-family: var(--serif);
  font-size: clamp(20px, 2.3vw, 24px);
  line-height: 1.65;
  color: var(--ink);
}

/* side note */
.post-body .note {
  margin: 36px 0;
  padding: 22px 26px;
  background: var(--bg-deep);
  border-radius: 2px;
  font-size: 14.5px;
  line-height: 1.95;
}

.note-label {
  display: block;
  font-weight: 500;
  color: var(--accent);
  margin-bottom: 4px;
}

.post-body .note p:last-child {
  margin-bottom: 0;
}

/* parallel items (3 reasons, 3 periods …) */
.point-list {
  list-style: none;
  margin: 28px 0 36px;
  padding: 0;
  border-top: 1px solid var(--line);
}

.point-list li {
  display: grid;
  grid-template-columns: 110px 1fr;
  gap: 20px;
  padding: 22px 0;
  border-bottom: 1px solid var(--line);
}

.point-k {
  font-family: var(--serif-en);
  font-style: italic;
  font-size: 16px;
  color: var(--accent);
  line-height: 1.6;
}

.point-list h3 {
  margin: 0 0 4px;
  font-size: 18px;
}

.point-list p {
  margin: 0;
  font-size: 14.5px;
  line-height: 1.9;
}

/* conclusion */
.takeaway {
  margin: 64px 0 0;
  padding: 32px 34px;
  background: var(--dark);
  color: var(--bg);
  border-radius: 2px;
}

.takeaway-k {
  font-family: var(--serif-en);
  font-style: italic;
  font-size: 14px;
  color: var(--accent-2);
  margin-bottom: 10px;
}

.takeaway p {
  margin: 0 0 1em;
  font-size: 15px;
  line-height: 1.95;
  color: color-mix(in srgb, var(--bg) 82%, transparent);
}

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

.takeaway .takeaway-line {
  font-family: var(--serif);
  font-size: 21px;
  line-height: 1.6;
  color: var(--bg);
}

/* end of post */
.post-end {
  margin-top: 40px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.read-next {
  margin-top: 48px;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 6px 24px;
  align-items: center;
  padding: 24px 28px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 2px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.read-next:hover {
  transform: translateY(-3px);
  box-shadow: 0 24px 48px -28px rgba(31, 29, 26, 0.2);
}

.read-next-k {
  grid-column: 1 / -1;
  font-size: 12.5px;
  color: var(--accent);
  letter-spacing: 0.06em;
}

.read-next-t {
  font-family: var(--serif);
  font-size: 19px;
  line-height: 1.5;
  color: var(--ink);
}

.read-next-arr {
  font-family: var(--serif-en);
  font-size: 22px;
  color: var(--accent);
  transition: transform 0.25s;
}

.read-next:hover .read-next-arr {
  transform: translateX(4px);
}

@media (max-width: 1100px) {
  .post {
    padding-left: 28px;
    padding-right: 28px;
  }

  .post-header {
    margin-left: 0;
  }

  .post-layout {
    grid-template-columns: minmax(0, 720px);
    gap: 0;
  }

  /* toc becomes a collapsible box above the body */
  .post-toc {
    position: static;
    margin-bottom: 32px;
    border: 1px solid var(--line);
    border-radius: 2px;
    padding: 14px 18px 6px;
  }

  .post-toc summary {
    pointer-events: auto;
    cursor: pointer;
    border-bottom: 0;
    margin-bottom: 0;
    padding-bottom: 8px;
    display: flex;
    justify-content: space-between;
  }

  .post-toc summary::after {
    content: "+";
    font-size: 16px;
    color: var(--accent);
  }

  .post-toc[open] summary::after {
    content: "−";
  }

  .post-row {
    grid-template-columns: 1fr 32px;
    gap: 8px 20px;
  }

  .post-date {
    grid-column: 1 / -1;
  }

  .post-date small {
    display: inline;
    margin-left: 10px;
  }
}

@media (max-width: 900px) {
  .post,
  .journal-head {
    padding-top: 152px;
  }
}

@media (max-width: 640px) {
  .post {
    padding: 136px 20px 32px;
  }

  .journal-head {
    padding-top: 144px;
  }

  .post-body {
    font-size: 15.5px;
  }

  .post-body h2 {
    margin-top: 56px;
  }

  .key-points {
    padding: 22px 20px 20px;
  }

  .point-list li {
    grid-template-columns: 1fr;
    gap: 2px;
  }

  .takeaway {
    padding: 26px 22px;
  }

  .read-next {
    padding: 22px 20px;
  }

  .post-row .post-title {
    font-size: 22px;
  }
}
