:root {
  --cream: #f4eadf;
  --cream-2: #fff8ef;
  --navy: #07122f;
  --muted: #73798b;
  --orange: #ff7a2f;
  --orange-dark: #e96018;
  --sand: #dfb789;
  --blue: #5267f7;
  --purple: #6d55dd;
  --green: #58bf7c;
  --mint: #95e7b2;
  --yellow: #ffc94d;
  --card: rgba(255, 250, 243, .92);
  --line: rgba(7, 18, 47, .09);
  --shadow: 0 28px 70px rgba(46, 31, 17, 0.15);
  --soft-shadow: 0 18px 44px rgba(46, 31, 17, 0.10);
  --radius-xl: 30px;
  --radius-lg: 22px;
  --radius-md: 16px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  color: var(--navy);
  background:
    radial-gradient(circle at 18% 12%, rgba(255, 122, 47, .08), transparent 28%),
    radial-gradient(circle at 85% 10%, rgba(255, 201, 77, .12), transparent 25%),
    var(--cream);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  overflow-x: hidden;
}

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

.container {
  width: min(1180px, calc(100% - 42px));
  margin: 0 auto;
}

.noise {
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: .22;
  background-image: radial-gradient(rgba(7, 18, 47, .10) .65px, transparent .65px);
  background-size: 18px 18px;
  mask-image: linear-gradient(to bottom, rgba(0,0,0,.55), transparent 70%);
  z-index: 0;
}

header {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(18px);
  background: rgba(244, 234, 223, .74);
  border-bottom: 1px solid rgba(7,18,47,.06);
}

.header-inner {
  min-height: 74px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-weight: 950;
  color: var(--navy);
  letter-spacing: -.04em;
}

.cube-logo {
  width: 36px;
  height: 36px;
  border-radius: 12px;
  background: var(--navy);
  position: relative;
  box-shadow: inset 0 0 0 3px rgba(255,255,255,.08), 0 10px 20px rgba(7,18,47,.12);
  transform: rotate(-10deg);
}

.cube-logo::before,
.cube-logo::after {
  content: "";
  position: absolute;
  border: 2px solid #fff;
  border-radius: 4px;
}

.cube-logo::before { width: 13px; height: 13px; top: 7px; left: 7px; transform: skewY(-25deg); }
.cube-logo::after { width: 13px; height: 13px; right: 7px; bottom: 7px; transform: skewY(-25deg); border-color: var(--orange); }

nav {
  display: flex;
  align-items: center;
  gap: 20px;
  font-size: 14px;
  color: rgba(7,18,47,.72);
  font-weight: 850;
}

nav a { transition: color .2s ease, transform .2s ease; }
nav a:hover { color: var(--orange); transform: translateY(-1px); }
.nav-cta {
  padding: 12px 17px;
  border-radius: 999px;
  background: var(--orange);
  color: #fff;
  box-shadow: 0 14px 30px rgba(255,122,47,.25);
}
.nav-cta:hover { color: #fff; background: var(--orange-dark); }

.hero {
  min-height: calc(100vh - 74px);
  display: grid;
  grid-template-columns: minmax(0, .92fr) minmax(420px, 1.08fr);
  align-items: center;
  gap: clamp(28px, 5vw, 70px);
  padding: 56px 0 86px;
  position: relative;
  z-index: 2;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--orange);
  font-size: 13px;
  font-weight: 950;
  letter-spacing: .05em;
  text-transform: uppercase;
  margin-bottom: 18px;
  white-space: normal;
}

.eyebrow::before {
  content: "";
  width: 42px;
  height: 2px;
  flex: 0 0 auto;
  border-radius: 999px;
  background: var(--orange);
}

.hero-title,
.section-title h2,
.detail-title {
  text-wrap: balance;
  overflow-wrap: normal;
  word-break: keep-all;
}

.hero-title {
  margin: 0;
  max-width: 680px;
  font-size: clamp(56px, 7.2vw, 104px);
  line-height: .86;
  letter-spacing: -.095em;
}

.hero-title .line { display: block; }
.hero-title .name { white-space: nowrap; }

.hero-copy p {
  margin: 28px 0 0;
  max-width: 580px;
  color: var(--muted);
  font-size: clamp(16px, 1.2vw, 18px);
  line-height: 1.85;
  font-weight: 700;
}

.hero-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 34px;
}

.btn {
  min-height: 48px;
  border: 0;
  border-radius: 999px;
  padding: 0 24px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  font-size: 14px;
  font-weight: 950;
  cursor: pointer;
  transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
}

.btn.primary { background: var(--orange); color: #fff; box-shadow: 0 18px 34px rgba(255,122,47,.32); }
.btn.secondary { background: rgba(255,255,255,.65); color: var(--navy); box-shadow: inset 0 0 0 1px rgba(7,18,47,.08); backdrop-filter: blur(10px); }
.btn.ghost { background: rgba(255,255,255,.18); color: #fff; box-shadow: inset 0 0 0 1px rgba(255,255,255,.16); }
.btn:hover { transform: translateY(-3px); }
.btn.primary:hover { background: var(--orange-dark); }

.mini-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 34px;
  max-width: 560px;
}

.mini-stat {
  background: rgba(255,255,255,.48);
  border: 1px solid rgba(7,18,47,.08);
  border-radius: 20px;
  padding: 17px 15px;
  box-shadow: 0 12px 32px rgba(46, 31, 17, .06);
}

.mini-stat strong {
  display: block;
  font-size: clamp(24px, 2vw, 30px);
  line-height: 1;
  letter-spacing: -0.05em;
  margin-bottom: 8px;
}

.mini-stat span {
  font-size: 12px;
  color: var(--muted);
  font-weight: 850;
  line-height: 1.35;
}

.hero-visual {
  position: relative;
  min-height: 620px;
  display: grid;
  place-items: center;
  perspective: 1200px;
}

.visual-card {
  position: relative;
  width: min(620px, 100%);
  height: 560px;
  border-radius: 34px;
  background:
    radial-gradient(circle at 25% 18%, rgba(255, 201, 77, .18), transparent 22%),
    radial-gradient(circle at 75% 74%, rgba(82, 103, 247, .12), transparent 30%),
    rgba(255, 248, 239, .45);
  border: 1px solid rgba(7,18,47,.06);
  box-shadow: 0 34px 90px rgba(46,31,17,.14);
  overflow: hidden;
  transform-style: preserve-3d;
  animation: floatScene 6s ease-in-out infinite;
}

@keyframes floatScene { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }

.shelf {
  position: absolute;
  top: 54px;
  left: 120px;
  width: 150px;
  height: 17px;
  border-radius: 999px;
  background: #f2c772;
  box-shadow: 0 16px 30px rgba(85,56,27,.12);
}
.shelf .book { position:absolute; left:28px; bottom:16px; width:28px; height:80px; border-radius:8px 8px 4px 4px; background:#6f86ef; box-shadow:34px 0 0 #f6a128, 68px 0 0 #ffc84d; }
.shelf .plant-orb { position:absolute; right:24px; bottom:18px; width:38px; height:38px; border-radius:50%; background:#fff; }
.shelf .plant-orb::after { content:""; position:absolute; right:-12px; top:5px; width:24px; height:20px; border-radius:20px 0 20px 0; background:#75d779; transform: rotate(-25deg); }

.pinboard {
  position: absolute;
  top: 70px;
  right: 56px;
  width: 248px;
  height: 158px;
  border-radius: 24px;
  background: #b08d70;
  box-shadow: inset 0 0 0 14px #d0aa83, var(--soft-shadow);
  transform: rotate(2deg);
}
.pinboard::before { content:""; position:absolute; width:14px; height:14px; border-radius:50%; right:76px; top:35px; background:var(--orange); }
.pin-note { position:absolute; width:62px; height:80px; border-radius:7px; top:60px; left:58px; background:#dfeaff; transform:rotate(-7deg); box-shadow:0 10px 18px rgba(0,0,0,.12); }
.pin-note::before, .pin-note.alt::before { content:""; position:absolute; width:34px; height:34px; border-radius:50%; background:#f34d68; top:-14px; left:16px; box-shadow: 22px 8px 0 rgba(243,77,104,.72); }
.pin-note.alt { left:auto; right:44px; top:74px; background:#fff4ec; transform:rotate(10deg); }

.monitor {
  position: absolute;
  left: 95px;
  top: 250px;
  width: 210px;
  height: 144px;
  border-radius: 18px;
  background: #2b3047;
  box-shadow: inset 0 0 0 8px #44415c, 0 26px 28px rgba(25,15,15,.18);
  padding: 34px 28px;
}
.code-line { display:block; height:6px; border-radius:999px; margin-bottom:12px; background:#58d28e; }
.code-line:nth-child(1){ width:68px; background:#ffc84d; }
.code-line:nth-child(2){ width:118px; background:#ff6b6b; }
.code-line:nth-child(3){ width:86px; }
.code-line:nth-child(4){ width:130px; background:#8c7cff; }
.code-line:nth-child(5){ width:108px; background:#52e0ff; }

.chart-screen {
  position:absolute;
  right:110px;
  top:270px;
  width:170px;
  height:124px;
  border-radius:19px;
  background:#27324e;
  box-shadow: inset 0 0 0 8px #4d4766, 0 22px 32px rgba(25,15,15,.15);
  display:grid;
  place-items:center;
}
.chart-screen svg { width:116px; }

.avatar-worker { position:absolute; left:275px; top:280px; width:118px; height:170px; z-index:5; }
.avatar-worker .head { position:absolute; width:92px; height:88px; border-radius:50%; left:5px; top:0; background:#af7a4f; box-shadow: inset -12px -10px 0 rgba(55,28,15,.12); }
.avatar-worker .body { position:absolute; width:82px; height:92px; border-radius:28px 28px 20px 20px; background:#172039; left:16px; top:76px; }
.avatar-worker .arm { position:absolute; width:90px; height:20px; border-radius:999px; left:78px; top:105px; background:#c9904e; transform: rotate(20deg); }

.desk {
  position:absolute;
  left:54px;
  right:54px;
  bottom:105px;
  height:112px;
  border-radius:32px;
  background:#fff;
  box-shadow:0 28px 50px rgba(46,31,17,.13);
}
.desk::before,
.desk::after { content:""; position:absolute; bottom:-86px; width:28px; height:96px; border-radius:999px; background:#c9904e; }
.desk::before { left:80px; }
.desk::after { right:80px; }
.wide-drawer { position:absolute; left:40px; right:40px; bottom:-66px; height:80px; border-radius:18px; background:#f0b330; box-shadow: inset 0 0 0 22px #ffe177; transform: rotate(-4deg); z-index:-1; }

.label-bubble {
  position:absolute;
  z-index:8;
  background:rgba(255,255,255,.76);
  border:1px solid rgba(7,18,47,.08);
  box-shadow:0 18px 36px rgba(7,18,47,.12);
  border-radius:999px;
  padding:12px 15px;
  font-size:12px;
  font-weight:950;
  color:var(--navy);
  backdrop-filter: blur(12px);
  animation: bob 4.8s ease-in-out infinite;
}
.label-bubble.one { left:20px; top:220px; }
.label-bubble.two { right:150px; top:245px; animation-delay:.5s; }
.label-bubble.three { right:24px; bottom:180px; animation-delay:1s; }
@keyframes bob { 50% { transform: translateY(-10px); } }

section { position: relative; z-index: 2; padding: 92px 0; }

.dark-lab {
  width: 100vw;
  margin-left: calc(50% - 50vw);
  background: radial-gradient(circle at 70% 42%, rgba(15,156,255,.32), transparent 32%), linear-gradient(135deg, #04122f 0%, #061b47 55%, #061028 100%);
  color: #fff;
  padding: 92px max(21px, calc((100vw - 1180px) / 2));
  overflow: hidden;
}
.lab-grid { display:grid; grid-template-columns: .85fr 1.15fr; gap:42px; align-items:center; }
.profile-card { border:2px solid rgba(82,224,255,.65); background:rgba(18,74,154,.33); border-radius:22px; padding:22px; box-shadow:0 0 60px rgba(24,154,255,.18), inset 0 0 0 1px rgba(255,255,255,.06); }
.profile-head { display:flex; align-items:center; gap:18px; margin-bottom:22px; }
.avatar-box { width:98px; height:98px; border-radius:22px; background:linear-gradient(145deg,#d9a078,#7c4b31); box-shadow:inset -10px -10px 0 rgba(0,0,0,.18),0 0 0 2px rgba(82,224,255,.65); position:relative; overflow:hidden; flex:0 0 auto; }
.avatar-box::before { content:""; position:absolute; width:82px; height:52px; background:#2d1b14; border-radius:50% 50% 35% 35%; left:8px; top:0; }
.avatar-box::after { content:"AI"; position:absolute; left:50%; bottom:16px; transform:translateX(-50%); color:#fff; font-weight:950; letter-spacing:.08em; }
.meta { display:grid; grid-template-columns:repeat(3,1fr); gap:12px; flex:1; }
.meta small { display:block; color:rgba(82,224,255,.86); font-weight:900; margin-bottom:4px; }
.meta strong { display:block; color:#fff; font-size:14px; }
.skill-row { margin-top:14px; display:grid; grid-template-columns:120px 1fr 44px; gap:12px; align-items:center; font-size:13px; font-weight:900; color:#bfeaff; }
.bar { height:10px; background:rgba(82,224,255,.16); border-radius:999px; overflow:hidden; }
.bar i { display:block; height:100%; border-radius:999px; background:linear-gradient(90deg,var(--blue),#52e0ff); }
.lab-copy h2 { margin:0 0 18px; font-size:clamp(40px,5vw,76px); line-height:.92; letter-spacing:-.07em; text-wrap:balance; word-break:keep-all; }
.lab-copy p { margin:0; color:rgba(255,255,255,.72); font-size:17px; line-height:1.9; font-weight:650; max-width:620px; }
.lab-badges { display:flex; gap:10px; flex-wrap:wrap; margin-top:28px; }
.lab-badges span { color:#bfeaff; border:1px solid rgba(82,224,255,.32); background:rgba(82,224,255,.08); border-radius:999px; padding:10px 13px; font-size:13px; font-weight:900; }

.section-title {
  display: grid;
  grid-template-columns: minmax(0, .9fr) minmax(280px, 1.1fr);
  gap: clamp(24px, 5vw, 72px);
  align-items: end;
  margin-bottom: 38px;
}
.section-title h2 { margin: 0; font-size: clamp(42px, 5.2vw, 76px); line-height: .95; letter-spacing: -.075em; }
.section-title p { margin: 0; color: var(--muted); font-size: 16px; line-height: 1.85; font-weight: 700; max-width: 620px; }

.projects-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 22px;
}
.project-card {
  background: var(--card);
  border: 8px solid rgba(255,255,255,.78);
  border-radius: 24px;
  min-height: 442px;
  overflow: hidden;
  box-shadow: 0 20px 44px rgba(84,57,28,.12);
  display: flex;
  flex-direction: column;
  transition: transform .2s ease, box-shadow .2s ease;
  position: relative;
}
.project-card:hover { transform: translateY(-8px); box-shadow: 0 30px 64px rgba(84,57,28,.18); }
.project-visual { height: 172px; border-radius: 16px; position: relative; overflow:hidden; margin:0; }
.project-card .project-visual { border-bottom-left-radius: 12px; border-bottom-right-radius: 12px; }
.visual-vibeshow { background: linear-gradient(135deg, #2b2779, #5267f7); }
.visual-content { background: linear-gradient(135deg, #ffd27b, #ff7429); }
.visual-pet { background: linear-gradient(135deg, #9feac1, #55b876); }
.visual-sound { background: linear-gradient(135deg, #27306f, #5267f7); }
.browser-card, .workflow-card, .pet-window, .sound-card { position:absolute; left:20px; right:20px; top:32px; height:104px; border-radius:16px; background:rgba(255,255,255,.78); box-shadow:0 16px 24px rgba(0,0,0,.11); padding:16px; }
.browser-card i, .workflow-card i { display:block; height:9px; border-radius:999px; margin-bottom:11px; background:rgba(7,18,47,.18); }
.browser-card i:nth-child(1), .workflow-card i:nth-child(1) { width:46%; background:rgba(255,122,47,.82); }
.browser-card i:nth-child(2), .workflow-card i:nth-child(2) { width:86%; }
.browser-card i:nth-child(3), .workflow-card i:nth-child(3) { width:68%; }
.browser-card i:nth-child(4), .workflow-card i:nth-child(4) { width:40%; }
.workflow-card { background:rgba(255,246,232,.88); }
.pet-window { background:rgba(255,255,255,.28); border:1px solid rgba(255,255,255,.5); }
.dog { position:absolute; width:84px; height:58px; background:#fff; border-radius:42px 42px 28px 28px; left:50%; top:66px; transform:translateX(-50%); box-shadow:inset -10px -8px 0 rgba(0,0,0,.08); }
.dog::before { content:""; position:absolute; width:32px; height:32px; background:#a97349; border-radius:50%; left:-10px; top:2px; box-shadow:70px 2px 0 #a97349; }
.dog::after { content:""; position:absolute; width:12px; height:8px; background:#10182b; border-radius:50%; left:36px; top:24px; }
.sound-card { display:grid; place-items:center; background:rgba(255,255,255,.16); border:1px solid rgba(255,255,255,.17); }
.sound-card svg { width:86%; }
.project-body { padding: 18px 12px 12px; display:flex; flex-direction:column; flex:1; }
.project-body h3 { margin: 0 0 10px; font-size: clamp(22px, 2vw, 27px); letter-spacing: -.05em; line-height: 1.05; }
.chips { display:flex; flex-wrap:wrap; gap:6px; margin-bottom:14px; }
.chip { font-size: 10px; font-weight: 950; padding: 5px 8px; border-radius:999px; background:#efe6da; color:#68616a; }
.chip.orange { background:#ffe1cf; color:#e85d13; }
.chip.blue { background:#dff2ff; color:#007bd1; }
.chip.green { background:#dcf8e5; color:#159657; }
.project-body p { margin:0; color:var(--muted); font-size:13px; line-height:1.7; font-weight:700; }
.project-meta { margin-top:14px; }
.status { display:inline-flex; align-items:center; height:26px; padding:0 11px; border-radius:999px; background:#ffe1cf; color:#e85d13; font-size:12px; font-weight:950; }
.status.verified { background:#e2f6e8; color:#16874f; }
.status.prototype { background:#fff0d6; color:#aa6417; }
.status.idea { background:#ece8e1; color:#69615b; }
.project-footer { margin-top:auto; display:flex; gap:9px; padding-top:20px; }
.icon-btn { width:40px; height:36px; border-radius:11px; display:grid; place-items:center; color:#fff; background:#b9b1aa; font-weight:950; flex:0 0 auto; }
.live-btn { flex:1; min-height:36px; border:0; border-radius:11px; display:grid; place-items:center; color:#fff; background:var(--sand); font-size:12px; font-weight:950; cursor:pointer; transition:transform .2s ease, background .2s ease; }
a.live-btn { display:grid; }
.live-btn:hover { transform: translateY(-2px); background:#ce9f6a; }
.project-card.featured .live-btn { background: var(--orange); }
.ribbon { position:absolute; right:-39px; top:20px; transform:rotate(42deg); background:#ffcf33; color:var(--navy); font-size:10px; font-weight:950; padding:8px 42px; z-index:4; box-shadow:0 8px 16px rgba(0,0,0,.13); }

.content-grid { display:grid; grid-template-columns:1.08fr .92fr; gap:24px; align-items:stretch; }
.content-panel, .writing-panel { background:rgba(255,255,255,.54); border:1px solid var(--line); border-radius:var(--radius-xl); padding:28px; box-shadow:0 20px 54px rgba(84,57,28,.10); }
.content-panel h3, .writing-panel h3 { margin:0 0 16px; font-size:28px; letter-spacing:-.05em; }
.content-panel p, .writing-panel p { color:var(--muted); line-height:1.8; font-weight:650; margin:0 0 22px; }
.metric-list { display:grid; grid-template-columns:repeat(2,1fr); gap:12px; }
.metric { background:var(--cream-2); border-radius:20px; padding:18px; }
.metric strong { display:block; font-size:30px; letter-spacing:-.06em; margin-bottom:7px; }
.metric span { color:var(--muted); font-size:13px; font-weight:850; }
.note-list { display:grid; gap:12px; }
.note-item { background:var(--cream-2); border-radius:18px; padding:16px; display:flex; gap:12px; align-items:flex-start; }
.note-index { min-width:34px; height:34px; border-radius:11px; background:var(--orange); color:#fff; display:grid; place-items:center; font-weight:950; }
.note-item strong { display:block; margin-bottom:5px; }
.note-item span { color:var(--muted); font-size:13px; line-height:1.6; font-weight:650; }

.timeline { display:grid; grid-template-columns:repeat(3,1fr); gap:18px; }
.timeline-card { min-height:250px; background:rgba(255,255,255,.58); border:1px solid var(--line); border-radius:26px; padding:24px; position:relative; overflow:hidden; box-shadow:0 20px 45px rgba(84,57,28,.09); }
.timeline-card::after { content:""; position:absolute; width:140px; height:140px; border-radius:50%; right:-50px; bottom:-50px; background:rgba(255,122,47,.12); }
.year { color:var(--orange); font-weight:950; margin-bottom:16px; display:block; }
.timeline-card h3 { margin:0 0 12px; font-size:25px; letter-spacing:-.04em; }
.timeline-card p { margin:0; color:var(--muted); line-height:1.8; font-weight:650; }

.contact { width:100vw; margin-left:calc(50% - 50vw); padding:92px max(21px, calc((100vw - 1180px) / 2)) 42px; background:var(--navy); color:#fff; overflow:hidden; }
.contact-card { position:relative; background:linear-gradient(135deg, rgba(255,255,255,.10), rgba(255,255,255,.04)); border:1px solid rgba(255,255,255,.12); border-radius:34px; padding:44px; display:grid; grid-template-columns:1.05fr .95fr; gap:28px; align-items:center; overflow:hidden; }
.contact-card::before { content:""; position:absolute; width:420px; height:420px; border-radius:50%; right:-160px; top:-160px; background:rgba(255,122,47,.22); filter:blur(2px); }
.contact-card h2 { margin:0; font-size:clamp(38px,5vw,72px); line-height:.96; letter-spacing:-.07em; text-wrap:balance; word-break:keep-all; }
.contact-card p { color:rgba(255,255,255,.72); line-height:1.8; font-weight:650; font-size:16px; margin:18px 0 0; max-width:560px; }
.contact-links { position:relative; z-index:2; display:grid; gap:12px; }
.contact-link { background:rgba(255,255,255,.09); border:1px solid rgba(255,255,255,.12); border-radius:18px; padding:16px 18px; display:flex; align-items:center; justify-content:space-between; gap:14px; font-weight:900; transition:transform .2s ease, background .2s ease; }
.contact-link:hover { transform:translateX(5px); background:rgba(255,255,255,.14); }
footer { margin-top:36px; display:flex; justify-content:space-between; gap:20px; color:rgba(255,255,255,.48); font-weight:700; font-size:13px; }

/* Project detail page */
.detail-hero {
  position: relative;
  z-index: 2;
  padding: 70px 0 40px;
}
.back-link {
  display:inline-flex;
  align-items:center;
  gap:8px;
  color:var(--orange);
  font-size:14px;
  font-weight:950;
  margin-bottom:28px;
}
.detail-shell {
  display:grid;
  grid-template-columns:minmax(0, .98fr) minmax(360px, .88fr);
  gap:clamp(26px,5vw,70px);
  align-items:center;
}
.detail-title {
  margin:0;
  font-size:clamp(52px,7vw,98px);
  line-height:.88;
  letter-spacing:-.09em;
}
.detail-subtitle { margin:18px 0 0; color:var(--orange); font-weight:950; letter-spacing:.02em; }
.detail-intro { margin:24px 0 0; color:var(--muted); line-height:1.85; font-size:17px; font-weight:700; max-width:690px; }
.detail-points { display:flex; gap:10px; flex-wrap:wrap; margin-top:28px; }
.detail-points span { padding:10px 13px; border-radius:999px; background:rgba(255,255,255,.6); border:1px solid var(--line); color:var(--navy); font-size:13px; font-weight:950; }
.detail-visual-card {
  border:10px solid rgba(255,255,255,.72);
  border-radius:32px;
  min-height:390px;
  box-shadow:var(--shadow);
  overflow:hidden;
  position:relative;
  background:var(--card);
}
.detail-visual-card .project-visual { height:390px; border-radius:22px; }
.detail-stats { display:grid; grid-template-columns:repeat(3,1fr); gap:12px; margin-top:22px; }
.detail-stat { background:rgba(255,255,255,.58); border:1px solid var(--line); border-radius:20px; padding:18px; }
.detail-stat strong { display:block; font-size:22px; letter-spacing:-.04em; margin-bottom:6px; }
.detail-stat span { color:var(--muted); font-size:12px; font-weight:850; }
.detail-content { padding:50px 0 100px; position:relative; z-index:2; }
.detail-grid { display:grid; grid-template-columns:minmax(0, 1fr) 320px; gap:24px; align-items:start; }
.case-sections { display:grid; gap:16px; }
.case-block { background:rgba(255,255,255,.58); border:1px solid var(--line); border-radius:26px; padding:26px; box-shadow:0 18px 42px rgba(84,57,28,.08); }
.case-block h2 { margin:0 0 12px; font-size:26px; letter-spacing:-.04em; }
.case-block p, .case-block li { color:var(--muted); line-height:1.85; font-weight:680; font-size:15px; }
.case-block p { margin:0; }
.case-block ul { margin:0; padding-left:18px; }
.side-panel { position:sticky; top:96px; display:grid; gap:14px; }
.side-card { background:rgba(255,255,255,.58); border:1px solid var(--line); border-radius:26px; padding:22px; box-shadow:0 18px 42px rgba(84,57,28,.08); }
.side-card h3 { margin:0 0 14px; font-size:20px; }
.ability-list { display:flex; gap:8px; flex-wrap:wrap; }
.ability-list span { padding:8px 10px; border-radius:999px; background:#fff1e7; color:#de5a15; font-size:12px; font-weight:950; }
.project-nav { display:grid; grid-template-columns:1fr 1fr; gap:10px; }
.project-nav a { background:var(--navy); color:#fff; border-radius:16px; padding:14px; font-size:13px; font-weight:950; text-align:center; }
.project-nav a.secondary { background:rgba(7,18,47,.08); color:var(--navy); }
.not-found { min-height:60vh; display:grid; place-items:center; text-align:center; }
.not-found h1 { font-size:clamp(38px,6vw,70px); letter-spacing:-.07em; margin:0 0 16px; }
.not-found p { color:var(--muted); font-weight:700; }

@media (max-width: 1080px) {
  .hero { grid-template-columns: 1fr; min-height: auto; }
  .hero-visual { min-height: 560px; }
  .section-title, .lab-grid, .content-grid, .contact-card, .detail-shell, .detail-grid { grid-template-columns: 1fr; }
  .side-panel { position: static; }
}

@media (max-width: 760px) {
  .container { width: min(100% - 28px, 1180px); }
  .header-inner { min-height: 64px; }
  nav a:not(.nav-cta) { display:none; }
  .nav-cta { padding:10px 14px; }
  .brand span:last-child { font-size:14px; }
  .hero { padding: 42px 0 58px; }
  .eyebrow { font-size: 12px; margin-bottom: 14px; }
  .eyebrow::before { width: 32px; }
  .hero-title { font-size: clamp(54px, 18vw, 78px); letter-spacing: -.09em; }
  .hero-copy p { font-size: 15px; line-height: 1.75; }
  .mini-stats, .metric-list, .timeline, .detail-stats { grid-template-columns: 1fr; }
  .hero-visual { min-height: 430px; transform: scale(.72); transform-origin: center top; width: 138%; margin-left:-19%; margin-bottom:-110px; }
  section { padding: 68px 0; }
  .dark-lab, .contact { padding-left:14px; padding-right:14px; }
  .profile-head { flex-direction:column; align-items:flex-start; }
  .meta { width:100%; }
  .skill-row { grid-template-columns:92px 1fr 34px; }
  .project-card { min-height: auto; }
  .contact-card { padding: 28px; }
  .contact-link { flex-direction:column; align-items:flex-start; }
  footer { flex-direction:column; }
  .detail-hero { padding-top:42px; }
  .detail-title { font-size: clamp(46px, 16vw, 72px); }
  .detail-visual-card .project-visual { height:260px; }
  .detail-visual-card { min-height:260px; }
  .project-nav { grid-template-columns:1fr; }
}

/* v4: project images + confirmed copy refinements */
.hero-title-cn {
  max-width: 720px;
  font-size: clamp(48px, 5.8vw, 86px);
  line-height: .98;
  letter-spacing: -.065em;
}
.hero-title-cn em {
  color: var(--orange);
  font-style: normal;
}

@media (min-width: 980px) {
  .projects-row {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    align-items: stretch;
  }
}

.project-card {
  min-height: 540px;
}
.project-visual {
  height: auto;
  aspect-ratio: 16 / 10;
  border-radius: 18px;
  background: #fff8ef;
}
.project-card .project-visual {
  border-bottom-left-radius: 14px;
  border-bottom-right-radius: 14px;
}
.project-image-wrap {
  background: rgba(255,255,255,.72);
}
.project-image-wrap img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  object-position: center top;
}
.project-body {
  padding: 20px 16px 14px;
}
.project-body p {
  min-height: 66px;
}
.icon-btn {
  font-size: 12px;
  letter-spacing: -.02em;
}
.detail-visual-card {
  min-height: 0;
  background: rgba(255,255,255,.66);
}
.detail-visual-card .project-visual {
  height: auto;
  aspect-ratio: 16 / 10;
  border-radius: 22px;
}
.project-detail-image img {
  object-fit: cover;
  object-position: center top;
}
.case-block ul {
  display: grid;
  gap: 6px;
}
.contact-links .contact-link span:last-child {
  text-align: right;
}

@media (max-width: 760px) {
  .hero-title-cn {
    font-size: clamp(42px, 12vw, 64px);
    line-height: 1.02;
    letter-spacing: -.055em;
  }
  .project-card {
    min-height: auto;
  }
  .project-body p {
    min-height: 0;
  }
  .detail-visual-card .project-visual {
    height: auto;
    aspect-ratio: 16 / 10;
  }
}

/* v6: keep “HI 卡尔KARL” on one line */
.hero-title-name {
  max-width: none;
  font-size: clamp(48px, 5.6vw, 86px);
  line-height: .96;
  letter-spacing: -.075em;
  white-space: nowrap;
}
.hero-title-name .greeting,
.hero-title-name .cn-name,
.hero-title-name .latin-name {
  display: inline;
  white-space: nowrap;
}
.hero-title-name .latin-name {
  margin-left: .08em;
  letter-spacing: -.09em;
}

@media (max-width: 760px) {
  .hero-title-name {
    font-size: clamp(40px, 10.5vw, 56px);
    line-height: 1;
    letter-spacing: -.065em;
  }
  .hero-title-name .latin-name {
    display: inline;
    margin-left: .08em;
  }
}
