/* =========================================
   Wang Xin Portfolio - Design System
   ========================================= */

/* Self-hosted Inter (latin subset) — avoids Google Fonts being blocked in China */
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('../fonts/inter-400.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('../fonts/inter-500.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('../fonts/inter-600.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('../fonts/inter-700.woff2') format('woff2');
}

:root {
  /* Background */
  --bg-main: #0E0B09;
  --bg-card: #16110E;
  --bg-card-2: #1C1612;
  --border: rgba(255, 255, 255, .12);
  --border-hover: rgba(255, 154, 98, .55);

  /* Accent */
  --accent: #FF9A62;
  --accent-ink: #111111;
  --accent-soft: rgba(255, 154, 98, .18);

  /* Secondary */
  --pink-soft: #FFC2CF;
  --pink-glow: rgba(255, 194, 207, .14);
  --gold-soft: #FFD166;

  /* Text */
  --text-primary: #F7F4F1;
  --text-secondary: #B8B0AA;
  --text-muted: #706A66;

  /* Layout */
  --content-max: 1700px;
  --content-pad: clamp(24px, 5vw, 80px);
  --section-py: clamp(96px, 14vw, 180px);

  /* Radii */
  --r-card: 24px;
  --r-card-sm: 16px;
  --r-btn: 12px;
  --r-pill: 999px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
*::selection { background: var(--accent); color: var(--accent-ink); }

html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', 'PingFang SC', 'Noto Sans SC', 'Helvetica Neue', Arial, sans-serif;
  font-size: 16px;
  line-height: 1.55;
  color: var(--text-primary);
  background: var(--bg-main);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; background: none; border: none; color: inherit; }

/* Subtle warm radial glow over the whole page */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background:
    radial-gradient(ellipse 60% 40% at 15% 8%, rgba(255, 154, 98, .10), transparent 60%),
    radial-gradient(ellipse 50% 35% at 90% 70%, rgba(255, 194, 207, .07), transparent 65%);
}

.container {
  max-width: var(--content-max);
  width: calc(100% - var(--content-pad) * 2);
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

.section { padding: var(--section-py) 0; position: relative; }

/* ============ TYPOGRAPHY ============ */
.eyebrow {
  display: flex;
  align-items: baseline;
  gap: 14px;
  font-size: 13px;
  letter-spacing: .14em;
  font-weight: 500;
  color: var(--text-secondary);
  text-transform: uppercase;
}
.eyebrow .num {
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: .04em;
}

.h1, .h2, .h3 {
  font-family: 'Inter', 'PingFang SC', 'Noto Sans SC', sans-serif;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.04;
  color: var(--text-primary);
}

.h1 { font-size: clamp(48px, 7.5vw, 120px); }
.h2 { font-size: clamp(36px, 5.5vw, 78px); }
.h3 { font-size: clamp(24px, 2.8vw, 36px); }

.accent { color: var(--accent); }

.muted { color: var(--text-secondary); }

/* ============ NAVBAR ============ */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 50;
  background: rgba(14, 11, 9, .72);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid transparent;
  transition: background .3s ease, border-color .3s ease;
}
.nav.scrolled {
  background: rgba(14, 11, 9, .92);
  border-bottom-color: var(--border);
}
.nav-inner {
  max-width: var(--content-max);
  width: calc(100% - var(--content-pad) * 2);
  margin: 0 auto;
  height: 78px;
  display: flex;
  align-items: center;
  gap: 32px;
}
.brand {
  font-weight: 700;
  font-size: 18px;
  letter-spacing: .02em;
  display: flex;
  align-items: center;
  gap: 10px;
}
.brand::before {
  content: "";
  width: 10px; height: 10px;
  border-radius: 50%;
  background: var(--accent);
  display: inline-block;
}
.nav-links {
  display: flex;
  gap: 38px;
  list-style: none;
  margin: 0 auto;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-secondary);
}
.nav-links a {
  position: relative;
  padding: 8px 16px;
  border-radius: var(--r-pill);
  border: 1px solid transparent;
  color: var(--text-secondary);
  transition: color .25s ease, background .25s ease, border-color .25s ease;
}
.nav-links a:hover {
  color: var(--text-primary);
  background: rgba(255, 154, 98, .08);
  border-color: var(--accent);
}
.nav-links a::after { display: none; }

.nav-cta {
  background: transparent;
  color: var(--accent);
  border: 1px solid var(--accent);
  padding: 9px 18px;
  border-radius: var(--r-pill);
  font-size: 13px;
  font-weight: 600;
  transition: background .25s ease, color .25s ease, transform .25s ease;
}
.nav-cta:hover {
  background: var(--accent);
  color: var(--accent-ink);
  transform: translateY(-2px);
}

/* Hamburger (hidden on desktop) */
.nav-burger { display: none; }

/* Mobile menu — strictly hidden on desktop, even if a stray class is added */
.nav-mobile { display: none !important; }

/* ============ HERO (ABOUT) ============ */
.hero {
  padding-top: calc(78px + clamp(48px, 8vw, 120px));
  padding-bottom: clamp(48px, 8vw, 120px);
  position: relative;
}
.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, .85fr);
  gap: clamp(32px, 5vw, 80px);
  align-items: start;
}
/* Hero 3-column layout (moxibustion): handheld | text | robot */
.hero-3col {
  display: grid;
  grid-template-columns: minmax(0, .55fr) minmax(0, 1.15fr) minmax(0, .85fr);
  gap: clamp(24px, 3.5vw, 56px);
  align-items: start;
}
.hero-3col-side {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.hero-3col-side img {
  width: 100%;
  border-radius: 16px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  display: block;
}
.hero-3col-side .handheld-stack { display: flex; flex-direction: column; gap: 14px; }
.hero-3col-side .handheld-stack img { aspect-ratio: 1 / 1; object-fit: contain; padding: 14px; background: #fff; }
.hero-3col-side .robot-hero img { aspect-ratio: 4 / 5; object-fit: cover; }
.hero-3col-main { padding: 0 8px; }
.hero-eyebrow { margin-bottom: 24px; }
.hero-title { margin-bottom: 28px; }
.hero-title .h1 { display: block; }
.hero-desc {
  font-size: clamp(15px, 1.1vw, 18px);
  color: var(--text-secondary);
  max-width: 640px;
  margin-bottom: 36px;
}
.hero-actions {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: clamp(48px, 6vw, 80px);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 22px;
  font-size: 14px;
  font-weight: 600;
  border-radius: var(--r-btn);
  transition: background .25s ease, color .25s ease, transform .25s ease, border-color .25s ease, box-shadow .25s ease;
  border: 1px solid transparent;
  white-space: nowrap;
}
.btn .arrow { transition: transform .25s ease; }
.btn:hover .arrow { transform: translateX(4px); }
.btn-primary {
  background: var(--accent);
  color: var(--accent-ink);
}
.btn-primary:hover {
  transform: translateY(-2px);
  filter: brightness(1.05);
}
.btn-ghost {
  background: transparent;
  color: var(--accent);
  border-color: var(--accent);
}
.btn-ghost:hover {
  background: var(--accent);
  color: var(--accent-ink);
  transform: translateY(-2px);
}

/* Portrait */
.hero-portrait {
  position: relative;
  border-radius: var(--r-card);
  overflow: hidden;
  aspect-ratio: 4 / 5;
  background: var(--bg-card);
  border: 1px solid var(--border);
}
.hero-portrait img {
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: center 28%;
}
.hero-portrait::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 60%, rgba(14, 11, 9, .45) 100%);
  pointer-events: none;
}
.hero-portrait .name-pill {
  position: absolute;
  left: 22px;
  bottom: 22px;
  background: rgba(14, 11, 9, .75);
  backdrop-filter: blur(10px);
  border: 1px solid var(--border);
  border-radius: var(--r-pill);
  padding: 10px 18px;
  font-size: 13px;
  color: var(--text-primary);
  font-weight: 500;
  z-index: 2;
}
.hero-portrait .name-pill strong { color: var(--accent); margin-right: 6px; }

/* Metrics — 4 cards with frosted glass hover */
.metrics {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
  margin-top: 28px;
}
.metric-card {
  position: relative;
  padding: 22px 22px 26px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--r-card-sm);
  overflow: hidden;
  transition: border-color .35s ease, transform .35s ease;
}
/* Blurred radial spotlight that follows the cursor */
.metric-card::before {
  content: "";
  position: absolute;
  top: var(--mx, 50%);
  left: var(--my, 50%);
  width: 220px; height: 220px;
  transform: translate(-50%, -50%);
  background: radial-gradient(circle, rgba(255, 154, 98, .35) 0%, rgba(255, 154, 98, .10) 35%, transparent 70%);
  filter: blur(24px);
  opacity: 0;
  transition: opacity .4s ease;
  pointer-events: none;
  z-index: 0;
}
/* Subtle frosted wash on hover */
.metric-card::after {
  content: "";
  position: absolute; inset: 0;
  background: rgba(255, 255, 255, .03);
  backdrop-filter: blur(2px);
  opacity: 0;
  transition: opacity .4s ease;
  pointer-events: none;
  z-index: 0;
}
.metric-card > * { position: relative; z-index: 1; }
.metric-card:hover {
  border-color: var(--border-hover);
  transform: translateY(-3px);
}
.metric-card:hover::before { opacity: 1; }
.metric-card:hover::after { opacity: 1; }
.metric-num {
  font-family: 'Inter', sans-serif;
  font-weight: 700;
  font-size: clamp(36px, 4vw, 56px);
  line-height: 1;
  color: var(--accent);
  letter-spacing: -0.02em;
  margin-bottom: 10px;
}
.metric-label {
  font-size: 13px;
  color: var(--text-secondary);
  letter-spacing: .02em;
}

/* Mini info cards (设计定位/工作方式/核心能力/项目结果) */
.hero-info-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin-top: 28px;
  margin-bottom: 28px;
}
.hero-info-cell {
  padding: 16px 18px;
  border: 1px solid var(--border);
  border-radius: var(--r-card-sm);
  background: var(--bg-card);
  transition: border-color .3s ease;
}
.hero-info-cell:hover { border-color: var(--border-hover); }
.hero-info-label {
  font-size: 11px;
  letter-spacing: .14em;
  color: var(--accent);
  font-weight: 600;
  text-transform: uppercase;
  margin-bottom: 8px;
}
.hero-info-value {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.5;
}

/* Single-line hero title */
.hero-title { margin-bottom: 28px; }
.hero-title .h1 { font-size: clamp(38px, 5.6vw, 76px); }

/* ============ ADVANTAGES ============ */
.section-head {
  margin-bottom: clamp(48px, 6vw, 80px);
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  gap: 48px;
  align-items: end;
}
.section-head .h2 { margin-top: 14px; }
.section-head .lede {
  font-size: 15px;
  color: var(--text-secondary);
  max-width: 460px;
}

.advantages-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}
.advantage-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--r-card);
  padding: 32px 26px;
  display: flex;
  flex-direction: column;
  min-height: 380px;
  transition: border-color .3s ease, transform .3s ease, background .3s ease;
  position: relative;
  overflow: hidden;
}
.advantage-card::before {
  content: "";
  position: absolute;
  top: -40px; right: -40px;
  width: 160px; height: 160px;
  background: radial-gradient(circle, var(--accent-soft) 0%, transparent 70%);
  opacity: 0;
  transition: opacity .4s ease;
  pointer-events: none;
}
.advantage-card:hover {
  border-color: var(--border-hover);
  transform: translateY(-6px);
}
.advantage-card:hover::before { opacity: 1; }

.advantage-num {
  font-size: 13px;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: .04em;
  margin-bottom: 18px;
}
.advantage-title {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.01em;
  margin-bottom: 16px;
}
.advantage-title::after {
  content: ".";
  color: var(--accent);
}
.advantage-desc {
  font-size: 14px;
  color: var(--text-secondary);
  margin-bottom: 24px;
  flex: 1;
}
.advantage-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.tag {
  font-size: 12px;
  font-weight: 500;
  color: var(--text-secondary);
  padding: 6px 12px;
  border-radius: var(--r-pill);
  background: rgba(255, 255, 255, .04);
  border: 1px solid var(--border);
}

/* ============ COLOR PALETTE (wheelchair detail) ============ */
.color-palette {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  align-self: start;
}
.color-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 16px;
  transition: border-color .3s ease, transform .3s ease;
}
.color-card:hover {
  border-color: var(--border-hover);
  transform: translateY(-2px);
}
.color-swatch {
  width: 100%;
  aspect-ratio: 16 / 6;
  border-radius: 8px;
  margin-bottom: 12px;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .06);
}
.color-name {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 2px;
}
.color-hex {
  font-size: 11px;
  color: var(--text-muted);
  font-family: 'Inter', monospace;
  letter-spacing: .04em;
  margin-bottom: 8px;
}
.color-desc {
  font-size: 12px;
  color: var(--text-secondary);
  line-height: 1.5;
}
@media (max-width: 1024px) {
  .color-palette { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 768px) {
  .color-palette { grid-template-columns: 1fr 1fr; }
}

/* ============ PROJECTS (Homepage) ============ */
.projects-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 32px;
  margin-bottom: clamp(40px, 5vw, 64px);
}
.projects-head .h2 { margin-top: 12px; }
.projects-head .view-all {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 500;
  color: var(--accent);
  white-space: nowrap;
}
.projects-head .view-all:hover .arrow { transform: translateX(4px); }

.projects-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.project-card {
  display: flex;
  flex-direction: column;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--r-card);
  overflow: hidden;
  transition: transform .35s ease, border-color .35s ease;
  position: relative;
}
.project-card:hover {
  transform: translateY(-6px);
  border-color: var(--border-hover);
}
.project-media {
  aspect-ratio: 4 / 3;
  overflow: hidden;
  position: relative;
}
.project-media img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform .6s ease;
}
.project-card:hover .project-media img { transform: scale(1.04); }
.project-media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 60%, rgba(14, 11, 9, .35));
  pointer-events: none;
}

.project-body {
  padding: 28px 26px 32px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.project-meta {
  font-size: 12px;
  color: var(--accent);
  font-weight: 600;
  letter-spacing: .04em;
  display: flex;
  align-items: center;
  gap: 10px;
}
.project-meta .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }
.project-title {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.01em;
  line-height: 1.2;
}
.project-role {
  font-size: 13px;
  color: var(--text-secondary);
}
.project-desc {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
}
.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 6px;
}

/* Award badge */
.project-card.is-award .project-media::before {
  content: "AWARD";
  position: absolute;
  top: 16px;
  right: 16px;
  z-index: 2;
  background: var(--gold-soft);
  color: var(--accent-ink);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .08em;
  padding: 6px 12px;
  border-radius: var(--r-pill);
}

/* ============ WORKS (Other Works) ============ */
.works-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 32px;
  margin-bottom: clamp(40px, 5vw, 56px);
  flex-wrap: wrap;
}
.works-head .h2 { margin-top: 12px; }
.filter {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.filter button {
  font-size: 13px;
  padding: 8px 16px;
  border-radius: var(--r-pill);
  border: 1px solid var(--border);
  color: var(--text-secondary);
  transition: all .25s ease;
}
.filter button:hover { color: var(--text-primary); border-color: rgba(255,255,255,.25); }
.filter button.is-active {
  background: var(--accent);
  color: var(--accent-ink);
  border-color: var(--accent);
}

.works-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  grid-auto-rows: 200px;
  gap: 18px;
}
.work-card {
  position: relative;
  border-radius: var(--r-card);
  overflow: hidden;
  background: var(--bg-card);
  border: 1px solid var(--border);
  cursor: pointer;
  transition: transform .35s ease, border-color .35s ease;
}
.work-card:hover {
  transform: translateY(-4px);
  border-color: var(--border-hover);
}
.work-card:hover .img { transform: scale(1.05); }
.work-card .img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform .7s ease;
}

/* Video card play overlay */
.work-card.video-card {
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, #1C1612, #2A1F1A);
}
.work-card .video-play {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 72px; height: 72px;
  border-radius: 50%;
  background: rgba(255, 154, 98, .92);
  box-shadow: 0 8px 28px rgba(0,0,0,.4);
  transition: transform .3s ease, background .3s ease;
  z-index: 2;
  pointer-events: none;
}
.work-card .video-play::before {
  content: "";
  position: absolute;
  top: 50%; left: 56%;
  transform: translate(-50%, -50%);
  border-style: solid;
  border-width: 14px 0 14px 22px;
  border-color: transparent transparent transparent #0E0B09;
}
.work-card.video-card:hover .video-play {
  transform: translate(-50%, -50%) scale(1.12);
  background: rgba(255, 154, 98, 1);
}
.work-card .work-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 40%, rgba(14, 11, 9, .85) 100%);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 22px 24px;
  opacity: 1;
}
.work-card .work-name {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 4px;
}
.work-card .work-cat {
  font-size: 12px;
  color: var(--text-secondary);
  letter-spacing: .04em;
}

/* Editorial grid spans */
.work-card.size-lg { grid-column: span 6; grid-row: span 2; }
.work-card.size-md { grid-column: span 4; grid-row: span 2; }
.work-card.size-sm { grid-column: span 3; grid-row: span 1; }
.work-card.size-wide { grid-column: span 6; grid-row: span 1; }
.work-card.size-tall { grid-column: span 3; grid-row: span 2; }

/* ============ CONTACT ============ */
.contact {
  text-align: center;
  padding: clamp(140px, 18vw, 220px) 0;
}
.contact .h2 {
  font-size: clamp(34px, 4.8vw, 64px);
  margin-bottom: 56px;
}
.contact .lede {
  font-size: 16px;
  color: var(--text-secondary);
  max-width: 540px;
  margin: 0 auto 64px;
}
.contact-actions {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 8px;
}

/* ============ FOOTER ============ */
.footer {
  border-top: 1px solid var(--border);
  padding: 56px 0 36px;
  font-size: 13px;
  color: var(--text-muted);
}
.footer-inner {
  max-width: var(--content-max);
  width: calc(100% - var(--content-pad) * 2);
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
  align-items: center;
}
.footer .brand { color: var(--text-primary); }
.footer p { color: var(--text-secondary); margin-top: 8px; }
.footer .links { display: flex; gap: 20px; }
.footer .links a:hover { color: var(--text-primary); }

/* Footer contact block — email pinned to bottom-right */
.footer-contact {
  margin-left: auto;
  text-align: right;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 16px;
}
.footer-contact .footer-info { display: flex; flex-direction: column; align-items: flex-end; }
.footer-contact .footer-qr-block {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 6px;
}
.footer-contact .footer-qr-block .qr-label {
  font-size: 11px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--text-muted);
}
.footer-contact .footer-qr {
  flex-shrink: 0;
  width: 96px; height: 96px;
  padding: 6px;
  background: #fff;
  border-radius: 12px;
  border: 1px solid var(--border);
  display: block;
}
.footer-contact .footer-qr img {
  width: 100%; height: 100%; display: block; object-fit: contain;
}
.footer-contact .footer-label {
  font-size: 11px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 6px;
}
.footer-contact a.footer-email {
  font-size: 17px;
  font-weight: 600;
  color: var(--text-primary);
  transition: color .25s ease;
}
.footer-contact a.footer-email:hover { color: var(--accent); }
.footer-contact .footer-copy {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 8px;
}
@media (max-width: 768px) {
  .footer-contact { margin-left: 0; text-align: left; align-items: flex-start; }
  .footer-contact .footer-info { align-items: flex-start; }
  .footer-contact .footer-qr-block { align-items: flex-start; }
}

/* ============ PROJECT DETAIL ============ */
.project-hero {
  padding-top: calc(78px + clamp(56px, 8vw, 110px));
  padding-bottom: clamp(40px, 6vw, 80px);
}
.project-hero .crumb {
  font-size: 13px;
  color: var(--text-secondary);
  margin-bottom: 28px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.project-hero .crumb a:hover { color: var(--accent); }
.project-hero .h1 {
  margin-bottom: 24px;
  font-size: clamp(40px, 6.5vw, 100px);
}
.project-hero .lead {
  font-size: clamp(15px, 1.1vw, 18px);
  color: var(--text-secondary);
  max-width: 760px;
  margin-bottom: 48px;
}
.project-tags-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 24px;
}

.hero-image {
  width: 100%;
  border-radius: var(--r-card);
  overflow: hidden;
  aspect-ratio: 16 / 8;
  background: var(--bg-card);
  border: 1px solid var(--border);
}
.hero-image img {
  width: 100%; height: 100%;
  object-fit: cover;
}

.detail-section { padding: clamp(72px, 10vw, 120px) 0; }
.detail-section.tight { padding: clamp(48px, 6vw, 80px) 0; }

.overview-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr);
  gap: 64px;
  align-items: start;
}
.overview-grid .h3 { margin-bottom: 18px; }
.overview-grid p { color: var(--text-secondary); margin-bottom: 14px; }
.facts {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--r-card);
  padding: 32px;
}
.facts h4 {
  font-size: 12px;
  letter-spacing: .12em;
  color: var(--text-muted);
  text-transform: uppercase;
  margin-bottom: 22px;
}
.fact-row {
  display: flex;
  justify-content: space-between;
  padding: 12px 0;
  border-bottom: 1px dashed var(--border);
  font-size: 14px;
}
.fact-row:last-child { border-bottom: none; }
.fact-row span:first-child { color: var(--text-secondary); }
.fact-row span:last-child { color: var(--text-primary); font-weight: 500; }

.metrics-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  margin: clamp(48px, 6vw, 80px) 0;
  padding: 48px 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.text-block {
  max-width: 760px;
  margin: 0 auto;
}
.text-block h2 {
  font-size: clamp(28px, 3.5vw, 44px);
  font-weight: 700;
  letter-spacing: -0.01em;
  margin-bottom: 20px;
}
.text-block p {
  font-size: 16px;
  color: var(--text-secondary);
  margin-bottom: 18px;
  line-height: 1.75;
}

.full-img {
  width: 100%;
  border-radius: var(--r-card);
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--bg-card);
}
.full-img img { width: 100%; height: 100%; object-fit: cover; }

.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}
.two-col .full-img { aspect-ratio: 4 / 3; }

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}
.gallery-grid .full-img { aspect-ratio: 1 / 1; }

/* Project hero h1 with split layout (title left, accent label right) */
.h1-split {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 20px 40px;
  line-height: 1;
}
.h1-split > span { white-space: nowrap; }

/* Banner stack — single photo per row, wide aspect */
.banner-stack { display: flex; flex-direction: column; gap: 18px; margin-bottom: 24px; }
.banner-stack .full-img.wide { aspect-ratio: 21 / 9; }

/* Logo card — contained, smaller, padded */
.gallery-grid .logo-card {
  aspect-ratio: 4 / 3;
  background: #fff;
  padding: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.gallery-grid .logo-card img { width: 100%; height: 100%; object-fit: contain; }

/* Magazine covers stack — 3 covers linked to PDFs */
.cover-stack { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; max-width: 520px; }
.cover-item {
  position: relative;
  display: block;
  border-radius: 14px;
  overflow: hidden;
  background: var(--bg-card);
  border: 1px solid var(--border);
  transition: transform .35s ease, border-color .35s ease;
}
.cover-item:hover {
  transform: translateY(-4px);
  border-color: var(--border-hover);
}
.cover-item img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  display: block;
}
.cover-label {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  padding: 10px 12px;
  background: rgba(14, 11, 9, .85);
  backdrop-filter: blur(8px);
  font-size: 11px;
  color: var(--accent);
  font-weight: 600;
  letter-spacing: .04em;
  text-align: center;
}
.cover-label::after {
  content: " ↓";
  margin-left: 4px;
  font-weight: 400;
}

/* Process steps */
.process {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  margin-top: 48px;
}
.process-step {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--r-card);
  padding: 28px 24px;
  transition: border-color .3s ease;
}
.process-step:hover { border-color: var(--border-hover); }
.process-step .step-n {
  font-size: 12px;
  letter-spacing: .14em;
  color: var(--accent);
  font-weight: 600;
  margin-bottom: 16px;
}
.process-step h4 {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 10px;
}
.process-step p {
  font-size: 13px;
  color: var(--text-secondary);
}

/* Next project */
.next-project {
  border-top: 1px solid var(--border);
  padding: clamp(80px, 12vw, 140px) 0;
  text-align: center;
}
.next-project .label {
  font-size: 12px;
  letter-spacing: .14em;
  color: var(--text-muted);
  text-transform: uppercase;
  margin-bottom: 18px;
}
.next-project a {
  display: inline-block;
  font-size: clamp(32px, 4.5vw, 64px);
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--text-primary);
  transition: color .25s ease;
}
.next-project a:hover { color: var(--accent); }

/* ============ EXPERIENCE (Work Experience section) ============ */
.exp-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-top: clamp(32px, 4vw, 56px);
}
.exp-card {
  position: relative;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--r-card);
  padding: 26px 26px 30px;
  transition: transform .45s cubic-bezier(.2, .8, .2, 1),
              border-color .35s ease,
              background .35s ease;
  overflow: hidden;
  cursor: default;
}
/* Top-left corner triangle (orange), matching reference */
.exp-card::before {
  content: "";
  position: absolute;
  top: 0; left: 0;
  border-style: solid;
  border-width: 16px 16px 0 0;
  border-color: var(--accent) transparent transparent transparent;
  filter: drop-shadow(0 0 6px rgba(255, 154, 98, .45));
}
.exp-card::after {
  content: "";
  position: absolute;
  top: 0; left: 0;
  width: 0; height: 0;
  border-style: solid;
  border-width: 16px 16px 0 0;
  border-color: rgba(255, 154, 98, .35) transparent transparent transparent;
  transform: scale(2.5);
  transform-origin: top left;
  opacity: 0;
  transition: opacity .5s ease;
  pointer-events: none;
  filter: blur(20px);
}
.exp-card:hover {
  transform: scale(1.04);
  border-color: var(--border-hover);
  background: var(--bg-card-2);
}
.exp-card:hover::after { opacity: 1; }
.exp-date {
  font-size: 13px;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: .02em;
  margin-bottom: 12px;
}
.exp-company {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: -0.01em;
  margin-bottom: 6px;
  line-height: 1.25;
}
.exp-role {
  font-size: 13px;
  color: var(--text-secondary);
  margin-bottom: 0;
  transition: margin-bottom .35s ease;
}
/* Description revealed on hover */
.exp-desc {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.65;
  margin-top: 0;
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  transition: max-height .45s ease, opacity .4s ease, margin-top .45s ease;
}
.exp-card:hover .exp-desc {
  max-height: 240px;
  opacity: 1;
  margin-top: 14px;
}
.exp-card:hover .exp-role {
  margin-bottom: 4px;
}

/* ============ REVEAL ANIMATION ============ */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity .8s cubic-bezier(.2, .8, .2, 1), transform .8s cubic-bezier(.2, .8, .2, 1);
  will-change: opacity, transform;
}
.reveal.in {
  opacity: 1;
  transform: translateY(0);
}

.reveal-stagger > * {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity .7s ease, transform .7s ease;
}
.reveal-stagger.in > * { opacity: 1; transform: translateY(0); }
.reveal-stagger.in > *:nth-child(1) { transition-delay: .05s; }
.reveal-stagger.in > *:nth-child(2) { transition-delay: .15s; }
.reveal-stagger.in > *:nth-child(3) { transition-delay: .25s; }
.reveal-stagger.in > *:nth-child(4) { transition-delay: .35s; }
.reveal-stagger.in > *:nth-child(5) { transition-delay: .45s; }
.reveal-stagger.in > *:nth-child(6) { transition-delay: .55s; }

/* Hide works cards via JS */
.work-card.is-hidden { display: none; }

/* ============ RESPONSIVE ============ */
@media (max-width: 1280px) {
  .nav-links { gap: 28px; }
}

@media (max-width: 1024px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-3col { grid-template-columns: 1fr; }
  .hero-3col-side { flex-direction: row; }
  .hero-3col-side .handheld-stack { flex-direction: row; }
  .hero-3col-side .handheld-stack img { aspect-ratio: 4 / 3; }
  .hero-3col-side .robot-hero img { aspect-ratio: 4 / 3; }
  .hero-portrait { max-width: 460px; aspect-ratio: 5 / 6; }
  .advantages-grid { grid-template-columns: repeat(2, 1fr); }
  .projects-grid { grid-template-columns: repeat(2, 1fr); }
  .overview-grid { grid-template-columns: 1fr; gap: 36px; }
  .process { grid-template-columns: repeat(2, 1fr); }
  .section-head { grid-template-columns: 1fr; gap: 24px; }
  .two-col { grid-template-columns: 1fr; }
  .gallery-grid { grid-template-columns: repeat(2, 1fr); }
  .work-card.size-lg { grid-column: span 6; }
  .work-card.size-md { grid-column: span 6; }
  .work-card.size-sm { grid-column: span 6; grid-row: span 2; }
  .work-card.size-wide { grid-column: span 12; }
  .work-card.size-tall { grid-column: span 6; grid-row: span 2; }
  .hero-info-row { grid-template-columns: repeat(2, 1fr); }
  .exp-grid { grid-template-columns: 1fr; gap: 14px; }
}

@media (max-width: 768px) {
  .nav-links { display: none; }
  .nav-burger {
    display: inline-flex;
    width: 40px; height: 40px;
    border: 1px solid var(--border);
    border-radius: var(--r-pill);
    align-items: center;
    justify-content: center;
  }
  .nav-mobile {
    position: fixed;
    inset: 78px 0 auto 0;
    background: rgba(14, 11, 9, .96);
    backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border);
    padding: 24px var(--content-pad) 32px;
    flex-direction: column;
    gap: 14px;
  }
  .nav-mobile.open { display: flex !important; }
  .nav-mobile a {
    font-size: 18px;
    font-weight: 500;
    color: var(--text-primary);
    padding: 10px 0;
    border-bottom: 1px solid var(--border);
  }
  .nav-cta { padding: 8px 14px; font-size: 12px; }
  .hero { padding-top: calc(78px + 32px); }
  .metrics { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .advantages-grid { grid-template-columns: 1fr; }
  .projects-grid { grid-template-columns: 1fr; }
  .advantage-card { min-height: auto; }
  .process { grid-template-columns: 1fr; }
  .metrics-row { grid-template-columns: repeat(2, 1fr); gap: 20px; padding: 32px 0; }
  .gallery-grid { grid-template-columns: 1fr; }
  .works-grid {
    grid-template-columns: repeat(6, 1fr);
    grid-auto-rows: 180px;
  }
  .work-card.size-lg { grid-column: span 6; grid-row: span 2; }
  .work-card.size-md { grid-column: span 6; grid-row: span 1; }
  .work-card.size-sm { grid-column: span 3; grid-row: span 1; }
  .work-card.size-wide { grid-column: span 6; grid-row: span 1; }
  .work-card.size-tall { grid-column: span 3; grid-row: span 2; }
  .section { padding: 80px 0; }
  .projects-head, .works-head { flex-direction: column; align-items: start; }
  .footer-inner { flex-direction: column; align-items: start; gap: 16px; }
  .hero-info-row { grid-template-columns: 1fr; }
  .exp-grid { grid-template-columns: 1fr; }
  .exp-card:hover { transform: scale(1.02); }
}