/* ===== Tokens ===== */
:root {
  --cream: #F4F2F9;
  --cream-2: #ECE9F3;
  --ink: #16141D;
  --ink-2: #242031;
  --muted: #8B86A0;
  --line: rgba(22, 20, 29, 0.12);
  --accent: #7A63FF;
  --accent-soft: #E7E2FA;

  --bg: var(--cream);
  --fg: var(--ink);
  --fg-muted: #5B5570;
  --surface: #EAE7F2;
  --line-c: var(--line);

  --serif: "Instrument Serif", "Cormorant Garamond", Georgia, serif;
  --sans: "Geist", "Helvetica Neue", -apple-system, BlinkMacSystemFont, sans-serif;
  --mono: "JetBrains Mono", "IBM Plex Mono", ui-monospace, monospace;
}

[data-theme="dark"] {
  --bg: #121017;
  --fg: #ECE9F4;
  --fg-muted: #8B86A0;
  --surface: #1B1825;
  --line-c: rgba(236, 233, 244, 0.12);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
  background: var(--bg);
  color: var(--fg);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  transition: background 0.6s ease, color 0.6s ease;
  overflow-x: hidden;
}

html { scroll-behavior: smooth; }

body { cursor: none; }
@media (hover: none) { body { cursor: auto; } .cursor { display: none !important; } }

a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: none; cursor: none; }

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

/* ===== Cursor ===== */
.cursor {
  position: fixed; top: 0; left: 0; width: 14px; height: 14px;
  border-radius: 999px; background: var(--fg);
  pointer-events: none; z-index: 9999;
  transform: translate(-50%, -50%);
  transition: width 0.25s cubic-bezier(.2,.8,.2,1), height 0.25s cubic-bezier(.2,.8,.2,1), background 0.25s, mix-blend-mode 0.2s;
  mix-blend-mode: difference;
  background: #fff;
}
.cursor.is-hover { width: 68px; height: 68px; background: var(--accent); mix-blend-mode: normal; }
.cursor.is-text { width: 4px; height: 28px; border-radius: 2px; }
.cursor-label {
  position: absolute; inset: 0; display: grid; place-items: center;
  text-align: center; white-space: nowrap; line-height: 1;
  font-family: var(--sans); font-size: 10px; letter-spacing: 0.06em;
  text-transform: uppercase; color: #fff; opacity: 0;
  transition: opacity 0.2s;
}
.cursor.is-hover .cursor-label { opacity: 1; }

/* ===== Page transition curtain ===== */
.curtain {
  position: fixed; inset: 0; z-index: 9000;
  background: var(--accent);
  transform: translateY(100%);
  pointer-events: none;
}
.curtain.is-in { transform: translateY(0); transition: transform 0.7s cubic-bezier(.7,0,.3,1); }
.curtain.is-out { transform: translateY(-100%); transition: transform 0.7s cubic-bezier(.7,0,.3,1); }
.curtain-text {
  position: absolute; inset: 0; display: grid; place-items: center;
  font-family: var(--serif); color: var(--cream); font-size: 6vw;
  font-style: italic;
}

/* ===== Layout ===== */
.shell {
  width: min(1440px, 100% - 64px);
  margin-inline: auto;
}
@media (max-width: 720px) { .shell { width: calc(100% - 32px); } }

/* ===== Top nav ===== */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  padding: 24px 0;
  mix-blend-mode: normal;
  transition: backdrop-filter 0.3s, background 0.3s, padding 0.3s;
}
.nav.is-stuck {
  background: color-mix(in oklch, var(--bg) 80%, transparent);
  backdrop-filter: blur(12px);
  padding: 16px 0;
  border-bottom: 1px solid var(--line-c);
}
.nav-inner { display: flex; align-items: center; justify-content: space-between; }
.brand {
  font-family: var(--serif); font-size: 22px; font-style: italic;
  display: flex; align-items: center; gap: 10px;
}
.brand-dot {
  width: 10px; height: 10px; border-radius: 999px; background: var(--accent);
  display: inline-block;
  animation: pulse 2.4s ease-in-out infinite;
}
@keyframes pulse { 0%,100% { transform: scale(1); opacity: 1; } 50% { transform: scale(0.7); opacity: 0.6; } }

.nav-links { display: flex; gap: 36px; align-items: center; }
.nav-links a {
  font-size: 13px; letter-spacing: 0.02em; position: relative;
  padding: 6px 0;
}
.nav-links a::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0;
  height: 1px; background: currentColor; transform: scaleX(0); transform-origin: right;
  transition: transform 0.4s cubic-bezier(.7,0,.3,1);
}
.nav-links a:hover::after { transform: scaleX(1); transform-origin: left; }
.nav-status {
  font-family: var(--mono); font-size: 14px;
  display: flex; align-items: center; gap: 8px;
  color: var(--fg-muted);
}
.nav-status .pip {
  width: 6px; height: 6px; border-radius: 999px; background: #4CAF50;
  box-shadow: 0 0 0 4px color-mix(in oklch, #4CAF50 20%, transparent);
}

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

/* ===== Hero ===== */
.hero {
  min-height: 100vh; padding: 160px 0 80px;
  display: flex; flex-direction: column; justify-content: space-between;
  position: relative;
}
.hero-meta {
  display: flex; justify-content: space-between; align-items: flex-start;
  font-family: var(--mono); font-size: 14px; color: var(--fg-muted);
  letter-spacing: 0.05em; text-transform: uppercase;
  margin-bottom: 80px;
}
.hero-meta span { display: block; }
.hero-meta-block { max-width: 240px; display: flex; flex-direction: column; gap: 4px; }

.hero-title {
  font-family: var(--serif); font-weight: 400;
  font-size: clamp(56px, 9.5vw, 168px);
  line-height: 0.95; letter-spacing: -0.02em;
}
.hero-title .it { font-style: italic; color: var(--fg-muted); }
.hero-title .ac { color: var(--accent); }

.hero-bottom {
  display: grid; grid-template-columns: 1.2fr 1fr; gap: 48px;
  margin-top: 80px; align-items: end;
}
@media (max-width: 900px) { .hero-bottom { grid-template-columns: 1fr; } }

.hero-tagline {
  font-family: var(--serif); font-size: clamp(20px, 1.8vw, 28px);
  line-height: 1.4; max-width: 56ch;
  font-style: italic; color: var(--fg);
}
.hero-tagline .strong { font-style: normal; color: var(--fg); }

.hero-cta { display: flex; gap: 16px; justify-content: flex-end; align-items: center; flex-wrap: wrap; }

/* ===== Reveal text ===== */
.reveal-line { display: block; overflow: hidden; }
.reveal-line > span {
  display: inline-block; transform: translateY(110%);
  transition: transform 1s cubic-bezier(.7,0,.2,1);
  transition-delay: var(--d, 0ms);
}
.reveal-line.in > span { transform: translateY(0); }

.reveal-fade {
  opacity: 0; transform: translateY(20px);
  transition: opacity 0.9s ease, transform 0.9s cubic-bezier(.2,.8,.2,1);
  transition-delay: var(--d, 0ms);
}
.reveal-fade.in { opacity: 1; transform: translateY(0); }

/* ===== Magnetic buttons ===== */
.btn {
  display: inline-flex; align-items: center; gap: 12px;
  padding: 18px 28px; border-radius: 999px;
  background: var(--ink); color: var(--cream);
  font-size: 13px; letter-spacing: 0.02em;
  position: relative; overflow: hidden;
  transition: background 0.4s, color 0.4s;
  will-change: transform;
}
[data-theme="dark"] .btn { background: var(--cream); color: var(--ink); }
.btn .arrow {
  width: 14px; height: 14px; transition: transform 0.4s cubic-bezier(.7,0,.3,1);
}
.btn:hover .arrow { transform: rotate(-45deg); }

.btn-ghost {
  background: transparent; color: var(--fg);
  border: 1px solid var(--line-c);
}
.btn-ghost:hover { background: var(--surface); }

.btn-fill {
  position: absolute; inset: 0; background: var(--accent);
  transform: translateY(101%); border-radius: inherit;
  transition: transform 0.55s cubic-bezier(.7,0,.3,1);
  z-index: 0;
}
.btn:hover .btn-fill { transform: translateY(0); }
.btn span, .btn .arrow { position: relative; z-index: 1; }
.btn:hover { color: #fff; }
[data-theme="dark"] .btn:hover { color: #fff; }
.btn-ghost:hover { color: var(--fg); background: var(--surface); }
[data-theme="dark"] .btn-ghost:hover { color: var(--fg); background: var(--surface); }

/* ===== Section ===== */
.section { padding: 140px 0; position: relative; }
.section-head { display: flex; justify-content: space-between; align-items: baseline; gap: 32px; margin-bottom: 44px; flex-wrap: wrap; }
.eyebrow {
  font-family: var(--mono); font-size: 14px; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--fg-muted); display: flex; align-items: center; gap: 12px;
}
.eyebrow::before {
  content: ""; width: 24px; height: 1px; background: currentColor;
}
.section-title {
  font-family: var(--serif); font-weight: 400;
  font-size: clamp(40px, 6vw, 96px); line-height: 1; letter-spacing: -0.02em;
}
.section-title .it { font-style: italic; color: var(--fg-muted); }

.section-meta {
  font-family: var(--mono); font-size: 14px; color: var(--fg-muted);
  letter-spacing: 0.04em; max-width: 280px; text-align: right;
  text-transform: uppercase;
}

/* ===== Work list ===== */
.work-list { border-top: 1px solid var(--line-c); }
.work-row {
  display: grid; grid-template-columns: 60px 1fr 1.5fr 200px 60px;
  align-items: center;
  padding: 32px 0;
  border-bottom: 1px solid var(--line-c);
  position: relative;
  transition: padding 0.5s cubic-bezier(.7,0,.3,1);
}
.work-row:hover { padding: 40px 0; }
.work-row .num {
  font-family: var(--mono); font-size: 14px; color: var(--fg-muted);
  letter-spacing: 0.04em;
}
.work-row .name {
  font-family: var(--serif); font-size: clamp(28px, 4vw, 56px);
  font-weight: 400; line-height: 1.05; letter-spacing: -0.01em;
  transition: transform 0.5s cubic-bezier(.7,0,.3,1), color 0.5s;
}
.work-row:hover .name { transform: translateX(16px); color: var(--accent); }
.work-row .desc {
  font-size: 16px; color: var(--fg-muted); max-width: 36ch;
}
.work-row .meta {
  font-family: var(--mono); font-size: 14px; color: var(--fg-muted);
  text-transform: uppercase; letter-spacing: 0.04em;
}
.work-row .arrow-cell {
  display: grid; place-items: end; opacity: 0;
  transition: opacity 0.4s, transform 0.4s;
  transform: translateX(-8px);
}
.work-row:hover .arrow-cell { opacity: 1; transform: translateX(0); }
.work-row .thumb { display: none; }

@media (max-width: 900px) {
  .work-row {
    grid-template-columns: 40px 1fr 40px;
    grid-template-areas:
      "num name arrow"
      "thumb thumb thumb"
      "desc desc desc"
      "meta meta meta";
    row-gap: 14px;
  }
  .work-row:hover { padding: 32px 0; }
  .work-row .num { grid-area: num; }
  .work-row .name { grid-area: name; }
  .work-row .arrow-cell { grid-area: arrow; opacity: 1; transform: none; align-self: center; }
  .work-row .thumb {
    display: block; grid-area: thumb;
    aspect-ratio: 16 / 10; border-radius: 6px;
    background-size: cover; background-position: center top;
    background-color: var(--surface);
  }
  .work-row .desc { display: block; grid-area: desc; max-width: none; }
  .work-row .meta { display: block; grid-area: meta; }
}
@media (hover: none) {
  .work-preview { display: none; }
}

/* hover-reveal preview */
.work-preview {
  position: fixed; pointer-events: none;
  width: 360px; height: 240px;
  border-radius: 8px; overflow: hidden;
  z-index: 50;
  opacity: 0; transform: translate(-50%, -50%) scale(0.9);
  transition: opacity 0.3s, transform 0.5s cubic-bezier(.7,0,.3,1);
}
.work-preview.is-on { opacity: 1; transform: translate(-50%, -50%) scale(1); }
.work-preview .panel {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--serif); font-style: italic; font-size: 22px;
  color: rgba(255,255,255,0.85);
  background-size: cover; background-position: center top;
  background-color: var(--surface);
}

/* ===== Services ===== */
.svc-grid {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 0;
  border-top: 1px solid var(--line-c);
}
@media (max-width: 720px) { .svc-grid { grid-template-columns: 1fr; } }
.svc {
  padding: 48px 0; padding-right: 32px;
  border-bottom: 1px solid var(--line-c);
  display: grid; grid-template-columns: 40px 1fr; gap: 24px;
  position: relative;
}
.svc:nth-child(odd) { border-right: 1px solid var(--line-c); padding-left: 0; padding-right: 48px; }
.svc:nth-child(even) { padding-left: 48px; padding-right: 0; }
@media (max-width: 720px) {
  .svc, .svc:nth-child(odd), .svc:nth-child(even) {
    padding: 40px 0; border-right: none;
  }
}
.svc-num { font-family: var(--mono); font-size: 14px; color: var(--fg-muted); letter-spacing: 0.05em; padding-top: 6px; }
.svc-name { font-family: var(--serif); font-size: clamp(24px, 2.4vw, 36px); font-weight: 400; margin-bottom: 12px; letter-spacing: -0.01em; }
.svc-desc { font-size: 16px; color: var(--fg-muted); line-height: 1.55; max-width: 44ch; }
.svc-tags { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 20px; }
.svc-tags span {
  font-family: var(--mono); font-size: 10px; letter-spacing: 0.06em; text-transform: uppercase;
  padding: 6px 10px; border: 1px solid var(--line-c); border-radius: 999px;
  color: var(--fg-muted);
}

/* ===== Marquee ===== */
.marquee {
  overflow: hidden; padding: 60px 0;
  border-block: 1px solid var(--line-c);
  position: relative;
}
.marquee-track {
  display: flex; gap: 80px; align-items: center;
  animation: scroll 40s linear infinite;
  width: max-content;
}
.marquee:hover .marquee-track { animation-play-state: paused; }
@keyframes scroll {
  to { transform: translateX(-50%); }
}
.marquee-item {
  font-family: var(--serif); font-size: clamp(56px, 9vw, 144px);
  font-style: italic; line-height: 1;
  display: inline-flex; align-items: center; gap: 80px;
  white-space: nowrap;
}
.marquee-item .star {
  width: 28px; height: 28px; color: var(--accent); flex-shrink: 0;
}

/* ===== About ===== */
.about-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 80px;
  align-items: start;
}
@media (max-width: 900px) { .about-grid { grid-template-columns: 1fr; gap: 40px; } }
.about-portrait {
  aspect-ratio: 4/5;
  background: var(--accent-soft);
  border-radius: 4px;
  position: relative; overflow: hidden;
}
[data-theme="dark"] .about-portrait { background: var(--surface); }
.about-portrait .label {
  position: absolute; bottom: 16px; left: 16px;
  font-family: var(--mono); font-size: 10px; letter-spacing: 0.08em;
  color: var(--fg-muted); text-transform: uppercase;
  background: var(--bg); padding: 6px 10px; border-radius: 4px;
}
.about-cutout {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover; object-position: top center;
  filter: grayscale(1) contrast(1.04);
}
.about-body { padding-top: 8px; }
.about-body p {
  font-family: var(--serif); font-size: clamp(22px, 2vw, 30px);
  line-height: 1.4; margin-bottom: 24px; letter-spacing: -0.005em;
}
.about-body p .accent { color: var(--accent); font-style: italic; }
.about-body .small {
  font-family: var(--sans); font-size: 16px; color: var(--fg-muted);
  margin-top: 32px;
}
.about-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; margin-top: 48px; padding-top: 32px; border-top: 1px solid var(--line-c); }
.about-stats .stat .n { font-family: var(--serif); font-size: 44px; line-height: 1; }
.about-stats .stat .l { font-family: var(--mono); font-size: 10px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--fg-muted); margin-top: 8px; }

/* ===== Contact ===== */
.contact { padding: 160px 0 60px; position: relative; }
.contact-prefix {
  font-family: var(--mono); font-size: 14px; color: var(--fg-muted);
  letter-spacing: 0.1em; text-transform: uppercase;
  display: flex; align-items: center; gap: 12px;
  margin-bottom: 32px;
}
.contact-prefix::before { content: ""; width: 32px; height: 1px; background: currentColor; }
.contact-headline {
  font-family: var(--serif); font-weight: 400;
  font-size: clamp(56px, 11vw, 200px);
  line-height: 0.9; letter-spacing: -0.025em;
}
.contact-headline .reveal-line { padding-bottom: 0.12em; margin-bottom: -0.12em; }
.contact-headline .it { font-style: italic; color: var(--fg-muted); }
.contact-headline .underline {
  position: relative; display: inline-block;
}
.contact-headline .underline::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0.06em;
  height: 4px; background: var(--accent);
}
.contact-cta { margin-top: 64px; }
.contact-mail {
  font-family: var(--serif); font-size: clamp(28px, 3.6vw, 56px);
  font-style: italic; display: inline-flex; align-items: center; gap: 16px;
  position: relative;
}
.contact-mail::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 4px;
  height: 1px; background: currentColor; transform: scaleX(1); transform-origin: left;
  transition: transform 0.5s cubic-bezier(.7,0,.3,1);
}
.contact-mail:hover::after { transform: scaleX(0); transform-origin: right; }

.footer {
  margin-top: 120px; padding: 32px 0;
  border-top: 1px solid var(--line-c);
  display: flex; justify-content: space-between; align-items: center;
  font-family: var(--mono); font-size: 14px; letter-spacing: 0.04em;
  color: var(--fg-muted); text-transform: uppercase; flex-wrap: wrap; gap: 16px;
}
.footer a { transition: color 0.3s; }
.footer a:hover { color: var(--fg); }
.footer-socials { display: flex; gap: 24px; }

/* ===== Theme toggle ===== */
.theme-toggle {
  position: fixed; bottom: 24px; right: 24px; z-index: 80;
  width: 52px; height: 52px; border-radius: 999px;
  background: var(--ink); color: var(--cream);
  display: grid; place-items: center;
  box-shadow: 0 10px 40px -8px rgba(0,0,0,0.25);
  transition: transform 0.4s cubic-bezier(.7,0,.3,1), background 0.4s;
}
[data-theme="dark"] .theme-toggle { background: var(--cream); color: var(--ink); }
.theme-toggle:hover { transform: scale(1.08); }

/* misc */
.dim { color: var(--fg-muted); }
.serif-it { font-family: var(--serif); font-style: italic; }
.mono { font-family: var(--mono); }

.brand-last { font-style: normal; font-family: var(--sans); font-size: 13px; letter-spacing: 0.04em; color: var(--fg-muted); margin-left: 2px; align-self: center; padding-top: 4px; }
.about-small { font-family: var(--sans); font-size: 16px; line-height: 1.6; }
.work-foot { margin-top: 56px; display: flex; }
.nav-links a.is-current { color: var(--accent); }
.nav-links a.is-current::after { transform: scaleX(1); background: var(--accent); }

/* scroll hint — removed per review */

/* ===== Burger + mobile menu ===== */
.nav-burger {
  display: none; width: 44px; height: 44px;
  flex-direction: column; align-items: center; justify-content: center; gap: 7px;
  position: relative; z-index: 9500;
}
.nav-burger span {
  display: block; width: 24px; height: 1.5px; background: var(--fg);
  transition: transform 0.4s cubic-bezier(.7,0,.3,1);
}
.nav-burger.is-open span:first-child { transform: translateY(4.25px) rotate(45deg); }
.nav-burger.is-open span:last-child { transform: translateY(-4.25px) rotate(-45deg); }

.mobile-menu {
  position: fixed; inset: 0; z-index: 9000;
  background: var(--bg);
  display: flex; flex-direction: column; justify-content: center;
  padding: 0 32px;
  opacity: 0; pointer-events: none;
  transition: opacity 0.4s ease;
}
.mobile-menu.is-open { opacity: 1; pointer-events: auto; }
.mobile-menu-links { display: flex; flex-direction: column; gap: 8px; }
.mobile-menu-links a {
  font-family: var(--serif); font-size: clamp(40px, 11vw, 64px); line-height: 1.15;
  letter-spacing: -0.02em;
  opacity: 0; transform: translateY(16px);
  transition: opacity 0.5s ease, transform 0.5s cubic-bezier(.2,.8,.2,1);
  transition-delay: calc(var(--i, 0) * 60ms);
}
.mobile-menu.is-open .mobile-menu-links a { opacity: 1; transform: translateY(0); }
.mobile-menu-links a.is-current { color: var(--accent); font-style: italic; }
.mobile-menu-foot {
  position: absolute; bottom: 32px; left: 32px; right: 32px;
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px;
  font-family: var(--mono); font-size: 14px; color: var(--fg-muted);
  text-transform: uppercase; letter-spacing: 0.05em;
}
@media (max-width: 720px) {
  .nav-burger { display: flex; }
  .nav-status { display: none; }
}

/* scroll progress bar */
.scroll-bar {
  position: fixed; top: 0; left: 0; height: 2px;
  background: var(--accent); z-index: 200;
  width: 0%;
  transition: width 0.1s linear;
}

/* ===== Inner page hero ===== */
.page-hero { padding: 180px 0 80px; }
.page-hero-title { font-size: clamp(52px, 8.5vw, 140px); line-height: 0.95; margin-top: 20px; }
.page-hero-lead {
  font-family: var(--serif); font-style: italic;
  font-size: clamp(19px, 1.7vw, 26px); line-height: 1.45;
  max-width: 52ch; margin-top: 32px; color: var(--fg);
}
@media (max-width: 720px) { .page-hero { padding: 140px 0 56px; } }

/* ===== Work page grid ===== */
.wp-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 64px 48px; }
.wp-card.is-feature { grid-column: 1 / -1; }
.wp-card a { display: block; }
.wp-cover {
  border-radius: 8px; overflow: hidden;
  background: var(--surface);
  aspect-ratio: 16 / 10;
}
.wp-card.is-feature .wp-cover { aspect-ratio: 21 / 10; }
.wp-cover img {
  width: 100%; height: 100%; object-fit: cover; object-position: center top;
  transition: transform 0.8s cubic-bezier(.2,.8,.2,1);
}
.wp-card a:hover .wp-cover img { transform: scale(1.04); }
.wp-body { padding-top: 24px; }
.wp-top {
  display: flex; justify-content: space-between; align-items: baseline;
  font-family: var(--mono); font-size: 14px; letter-spacing: 0.06em;
  text-transform: uppercase; color: var(--fg-muted);
  margin-bottom: 12px;
}
.wp-name {
  font-family: var(--serif); font-weight: 400;
  font-size: clamp(30px, 3.2vw, 48px); line-height: 1.05; letter-spacing: -0.01em;
  transition: color 0.4s;
}
.wp-card a:hover .wp-name { color: var(--accent); }
.wp-summary { font-size: 15px; color: var(--fg-muted); line-height: 1.55; max-width: 58ch; margin-top: 12px; }
.wp-meta {
  display: flex; gap: 24px; align-items: center; flex-wrap: wrap;
  margin-top: 20px;
  font-family: var(--mono); font-size: 14px; letter-spacing: 0.05em;
  text-transform: uppercase; color: var(--fg-muted);
}
.wp-read {
  display: inline-flex; align-items: center; gap: 8px;
  color: var(--fg); margin-left: auto;
}
.wp-read .arrow { width: 13px; height: 13px; transition: transform 0.4s cubic-bezier(.7,0,.3,1); }
.wp-card a:hover .wp-read .arrow { transform: rotate(-45deg); }
@media (max-width: 900px) {
  .wp-grid { grid-template-columns: 1fr; gap: 56px; }
  .wp-card.is-feature .wp-cover { aspect-ratio: 16 / 10; }
}

/* ===== Case study ===== */
.cs-header { padding: 180px 0 64px; }
.cs-crumb {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--mono); font-size: 14px; letter-spacing: 0.08em;
  text-transform: uppercase; color: var(--fg-muted); margin-bottom: 28px;
}
.cs-crumb .arrow { width: 12px; height: 12px; transform: rotate(180deg); }
.cs-crumb:hover { color: var(--fg); }
.cs-title { font-family: var(--serif); font-weight: 400; font-size: clamp(48px, 8vw, 130px); line-height: 0.95; letter-spacing: -0.02em; }
.cs-summary {
  font-family: var(--serif); font-style: italic;
  font-size: clamp(19px, 1.8vw, 27px); line-height: 1.45;
  max-width: 56ch; margin-top: 32px;
}
.cs-facts {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px;
  margin-top: 48px; padding-top: 28px; border-top: 1px solid var(--line-c);
}
.cs-facts .l { font-family: var(--mono); font-size: 10px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--fg-muted); }
.cs-facts .v { font-size: 15px; margin-top: 8px; }
@media (max-width: 720px) { .cs-facts { grid-template-columns: repeat(2, 1fr); } .cs-header { padding: 140px 0 48px; } .cs-title { font-size: 48px; } }

.cs-hero-img { border-radius: 8px; overflow: hidden; background: var(--surface); }
.cs-hero-img img { width: 100%; }
.cs-hero-img video { width: 100%; display: block; }

.cs-section { padding: 88px 0 0; }
.cs-section:last-of-type { padding-bottom: 40px; }
.cs-grid { display: grid; grid-template-columns: 170px 1fr; gap: 48px; align-items: start; }
.cs-grid > * { min-width: 0; }
@media (max-width: 900px) { .cs-grid { grid-template-columns: 1fr; gap: 24px; } }
.cs-grid .eyebrow { position: sticky; top: 110px; }
.cs-body p {
  font-family: var(--serif); font-size: clamp(20px, 1.8vw, 27px);
  line-height: 1.5; letter-spacing: -0.005em; max-width: 62ch;
  text-wrap: pretty;
}
.cs-body p + p { margin-top: 24px; }
.cs-body .intro { font-style: italic; color: var(--fg-muted); }

.cs-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; border-top: 1px solid var(--line-c); margin-top: 40px; }
.cs-cards .card { padding: 32px 32px 32px 0; border-bottom: 1px solid var(--line-c); }
.cs-cards .card:not(:nth-child(3n)) { border-right: 1px solid var(--line-c); }
.cs-cards .card:not(:nth-child(3n)) + .card { padding-left: 32px; }
.cs-cards .card h3 { font-family: var(--serif); font-weight: 400; font-size: 22px; line-height: 1.2; margin-bottom: 12px; }
.cs-cards .card p { font-size: 16px; color: var(--fg-muted); line-height: 1.6; }
@media (max-width: 900px) {
  .cs-cards { grid-template-columns: 1fr; }
  .cs-cards .card, .cs-cards .card:not(:nth-child(3n)) + .card { padding: 28px 0; border-right: none; }
}

.cs-steps { counter-reset: step; display: grid; grid-template-columns: repeat(2, 1fr); gap: 32px 48px; margin-top: 40px; }
.cs-steps .step { display: grid; grid-template-columns: 40px 1fr; gap: 16px; }
.cs-steps .step .n { font-family: var(--mono); font-size: 14px; color: var(--accent); padding-top: 5px; }
.cs-steps .step h3 { font-family: var(--serif); font-weight: 400; font-size: 21px; margin-bottom: 8px; }
.cs-steps .step p { font-size: 16px; color: var(--fg-muted); line-height: 1.6; }
@media (max-width: 720px) { .cs-steps { grid-template-columns: 1fr; } }

.cs-img { border-radius: 8px; overflow: hidden; background: var(--surface); margin-top: 48px; }
.cs-img img { width: 100%; }
.cs-img-caption {
  font-family: var(--mono); font-size: 14px; letter-spacing: 0.05em;
  text-transform: uppercase; color: var(--fg-muted); margin-top: 14px;
}
.cs-compare { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; margin-top: 48px; }
@media (max-width: 720px) { .cs-compare { grid-template-columns: 1fr; } }
.cs-compare figure { margin: 0; }
.cs-compare figcaption {
  font-family: var(--mono); font-size: 14px; letter-spacing: 0.05em;
  text-transform: uppercase; color: var(--fg-muted); margin-bottom: 12px;
}
.cs-compare .frame { border-radius: 8px; overflow: hidden; background: var(--surface); }
.cs-compare .frame img { width: 100%; }

.cs-metrics { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; margin-top: 40px; padding-top: 32px; border-top: 1px solid var(--line-c); }
.cs-metrics .n { font-family: var(--serif); font-size: clamp(36px, 4vw, 60px); line-height: 1; color: var(--accent); }
.cs-metrics .l { font-family: var(--mono); font-size: 10px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--fg-muted); margin-top: 12px; max-width: 24ch; }
@media (max-width: 720px) { .cs-metrics { grid-template-columns: 1fr; gap: 32px; } }

.cs-quote {
  margin-top: 88px; padding: 64px 0; border-block: 1px solid var(--line-c);
  font-family: var(--serif); font-style: italic;
  font-size: clamp(26px, 3vw, 44px); line-height: 1.3; letter-spacing: -0.01em;
  max-width: 28ch; text-wrap: pretty;
}
.cs-quote::before { content: "“"; color: var(--accent); }
.cs-quote::after { content: "”"; color: var(--accent); }

.cs-pagenav { display: grid; grid-template-columns: 1fr 1fr; gap: 1px; background: var(--line-c); border-block: 1px solid var(--line-c); margin-top: 96px; }
.cs-pagenav a { background: var(--bg); padding: 48px 32px; display: block; transition: background 0.4s; }
.cs-pagenav a:hover { background: var(--surface); }
.cs-pagenav .dir { font-family: var(--mono); font-size: 10px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--fg-muted); }
.cs-pagenav .t { font-family: var(--serif); font-size: clamp(24px, 2.6vw, 38px); margin-top: 12px; }
.cs-pagenav .next { text-align: right; }
@media (max-width: 720px) { .cs-pagenav { grid-template-columns: 1fr; } .cs-pagenav a { padding: 32px 20px; } }

/* ===== About page: timeline + toolbox ===== */
.tl { border-top: 1px solid var(--line-c); }
.tl-row {
  display: grid; grid-template-columns: 220px 1fr; gap: 32px;
  padding: 40px 0; border-bottom: 1px solid var(--line-c);
}
.tl-period { font-family: var(--mono); font-size: 14px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--accent); padding-top: 6px; }
.tl-role { font-family: var(--serif); font-weight: 400; font-size: clamp(22px, 2.2vw, 30px); line-height: 1.15; }
.tl-org { color: var(--fg-muted); font-size: 0.75em; font-family: var(--sans); letter-spacing: 0.02em; }
.tl-desc { font-size: 15px; color: var(--fg-muted); line-height: 1.6; max-width: 64ch; margin-top: 10px; }
@media (max-width: 720px) { .tl-row { grid-template-columns: 1fr; gap: 10px; padding: 32px 0; } }

.toolbox { margin-top: 72px; }
.toolbox-tags { display: flex; flex-wrap: wrap; gap: 10px; }
.toolbox-tags span {
  font-family: var(--mono); font-size: 14px; letter-spacing: 0.03em;
  padding: 9px 16px; border: 1px solid var(--line-c); border-radius: 99px;
  color: var(--fg-muted);
}

/* ===== Services page: detail rows ===== */
.svc-detail-list { border-top: 1px solid var(--line-c); }
.svc-detail {
  display: grid; grid-template-columns: 80px 1.4fr 1fr; gap: 40px;
  padding: 56px 0; border-bottom: 1px solid var(--line-c);
}
.svc-detail-name { font-family: var(--serif); font-weight: 400; font-size: clamp(28px, 3vw, 44px); line-height: 1.05; letter-spacing: -0.01em; }
.svc-detail-desc { font-size: 16px; color: var(--fg-muted); line-height: 1.65; max-width: 52ch; margin-top: 16px; }
.svc-detail-side .l {
  font-family: var(--mono); font-size: 10px; letter-spacing: 0.08em;
  text-transform: uppercase; color: var(--fg-muted); margin-bottom: 12px;
}
.svc-detail-side ul { list-style: none; display: flex; flex-direction: column; gap: 8px; }
.svc-detail-side li { font-size: 15px; line-height: 1.5; padding-left: 18px; position: relative; }
.svc-detail-side li::before { content: "—"; position: absolute; left: 0; color: var(--accent); }
.svc-detail-side .v { font-size: 15px; }
@media (max-width: 900px) {
  .svc-detail { grid-template-columns: 1fr; gap: 24px; padding: 44px 0; }
  .svc-detail .svc-num { display: none; }
}

/* ===== Solution gallery (auto-scroll carousel) ===== */
.cs-gallery-band { width: 100%; overflow: hidden; }
.cs-gallery {
  display: flex; gap: 16px;
  overflow-x: auto; overflow-y: hidden; margin-top: 48px;
  scrollbar-width: none; -webkit-overflow-scrolling: touch;
}
.cs-gallery::-webkit-scrollbar { display: none; }
.cs-gallery .cell {
  flex: 0 0 auto;
  height: 420px; width: auto;
  border-radius: 8px; overflow: hidden;
  background: var(--surface);
}
.cs-gallery .cell img { display: block; height: 100%; width: auto; }
.cs-gallery image-slot { flex: 0 0 auto; width: min(540px, 76vw); height: 420px; }
@media (max-width: 720px) { .cs-gallery .cell, .cs-gallery image-slot { height: 250px; } .cs-gallery image-slot { width: 76vw; } }
.cs-gallery-band .cs-img-caption { margin-top: 18px; }

.cs-gallery-nav { display: flex; gap: 12px; justify-content: flex-end; margin-top: 28px; }
.cs-gallery-btn {
  width: 54px; height: 54px; border-radius: 999px;
  border: 1px solid var(--line-c); color: var(--fg);
  display: grid; place-items: center;
  transition: background 0.4s, color 0.4s, border-color 0.4s, transform 0.4s cubic-bezier(.7,0,.3,1);
}
.cs-gallery-btn:hover { background: var(--accent); color: #fff; border-color: transparent; transform: translateY(-2px); }
.cs-gallery-btn .arrow { width: 18px; height: 18px; }
@media (max-width: 720px) { .cs-gallery-nav { justify-content: center; } }

.cs-live { margin-top: 36px; display: flex; }

/* ===== Small-screen rhythm ===== */
@media (max-width: 720px) {
  .hero { padding: 130px 0 70px; min-height: 92vh; }
  .hero-meta { margin-bottom: 48px; }
  .hero-title { font-size: clamp(34px, 8.8vw, 50px); line-height: 1.1; }
  .hero-bottom { margin-top: 56px; gap: 32px; }
  .hero-cta { justify-content: flex-start; }
  .section { padding: 96px 0; }
  .section-head { margin-bottom: 40px; }
  .section-meta { text-align: left; max-width: none; }
  .about-stats { gap: 16px; }
  .about-stats .stat .n { font-size: 34px; }
  .contact { padding: 120px 0 40px; }
  .contact-cta { margin-top: 44px; }
  .footer { margin-top: 80px; flex-direction: column; align-items: flex-start; font-size: 12px; }
  .footer-socials { flex-wrap: wrap; gap: 12px 18px; }
  .theme-toggle { bottom: 16px; right: 16px; width: 46px; height: 46px; }
  .marquee { padding: 40px 0; }
}
