/* ========================================================================
   Design tokens — extracted from reference site's computed styles
   (colors, type scale, spacing, radii). Swap values here to re-skin.
   ======================================================================== */
:root {
  --bg: #121212;
  --bg-card: #1e1e1e;
  --placeholder-grad: linear-gradient(145deg, #101010 0%, #444444 100%);

  --text-primary: #ffffff;
  --text-soft: #e4e4e4;
  --text-muted: #7a7a7a;
  --text-dim: #787878;
  --border: #383838;

  --accent-orange: #ff520e;
  --accent-pink: #ff0a95;

  --font-display: "Instrument Serif", "Georgia", serif;
  --font-body: "Inter", -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: "Roboto Mono", ui-monospace, monospace;

  --page-margin: 24px;
  --grid-gap: 16px;
  --radius: 16px;
  --radius-sm: 10px;
}

* { box-sizing: border-box; }

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

body {
  background: var(--bg);
  color: var(--text-soft);
  font-family: var(--font-body);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, p, figure { margin: 0; }

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

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

/* ---------- Layout shell ---------- */

.page {
  max-width: 1440px;
  margin: 0 auto;
  padding: 0 var(--page-margin) 120px;
}

/* ---------- Nav pill ---------- */

.nav-wrap {
  display: flex;
  justify-content: center;
  padding: 32px 0;
}

.nav-pill {
  display: flex;
  align-items: center;
  gap: 4px;
  background: rgba(23, 23, 23, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 50px;
  padding: 8px;
}

.nav-pill a {
  font-size: 16px;
  line-height: 20.8px;
  color: var(--text-muted);
  padding: 10px 20px;
  border-radius: 50px;
  transition: color 0.15s ease, background-color 0.15s ease;
}

.nav-pill a:hover {
  color: var(--text-soft);
  background-color: rgba(255, 255, 255, 0.07);
}

.nav-pill a.active { color: #ffffff; font-weight: 500; }
.nav-pill a.active:hover { background-color: rgba(255, 255, 255, 0.07); }

/* ---------- Hero (home) ---------- */

.badge-check {
  width: 32px;
  height: 32px;
  margin-bottom: 24px;
}

.hero {
  padding: 0 8px;
  margin-bottom: 64px;
}

.hero h1 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 56px;
  line-height: 1.2;
  color: var(--text-primary);
  max-width: 1100px;
}

.hero p {
  margin-top: 20px;
  font-family: var(--font-body);
  font-weight: 300;
  font-size: 22px;
  line-height: 36px;
  letter-spacing: -0.3px;
  color: var(--text-soft);
  max-width: 900px;
}

/* ---------- Project grid (3-col masonry via manual columns) ---------- */

.grid {
  display: flex;
  gap: var(--grid-gap);
  align-items: flex-start;
}

.grid-col {
  flex: 1 1 0;
  display: flex;
  flex-direction: column;
  gap: var(--grid-gap);
}

.card {
  display: flex;
  flex-direction: column;
  background: var(--bg-card);
  border-radius: var(--radius);
  overflow: hidden;
}

.card-media {
  width: 100%;
  background: var(--placeholder-grad);
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.card-media.h-sm { height: 224px; }
.card-media.h-md { height: 320px; }
.card-media.h-lg { height: 416px; }
.card-media.h-xl { height: 480px; }

.card-media.tone-nova { background: linear-gradient(135deg, #1fd1ff 0%, #7b5cff 55%, #ff0a95 100%); }
.card-media.tone-origin { background: linear-gradient(135deg, #3a0d2b 0%, #ff0a95 100%); }
.card-media.tone-dynamic { background: linear-gradient(150deg, #2a0a3d 0%, #7b1fa2 50%, #ff0a95 100%); }
.card-media.tone-light { background: #f2f2f0; }

.card-mark {
  font-family: var(--font-display);
  font-size: 40px;
  color: rgba(0,0,0,0.85);
  transform: rotate(-4deg);
}

.card-caption {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 20px 16px;
  gap: 12px;
}

.card-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 16px;
  line-height: 24px;
  letter-spacing: -0.6px;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.card-title .lock {
  width: 13px;
  height: 13px;
  flex-shrink: 0;
  opacity: 0.6;
}

.card-badge {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  color: var(--text-muted);
  white-space: nowrap;
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 4px 10px;
}

/* ---------- Me / about page ---------- */

.me-layout {
  display: flex;
  gap: 64px;
  padding-top: 24px;
  flex-wrap: wrap;
}

.me-photo {
  width: 410px;
  aspect-ratio: 410 / 528;
  border-radius: var(--radius);
  background: linear-gradient(160deg, #2b2b2b 0%, #171717 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.me-content { flex: 1 1 420px; max-width: 620px; padding-top: 8px; }

.me-content h1 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 64px;
  line-height: 1.1;
  color: var(--text-primary);
  margin-bottom: 28px;
}

.me-content p {
  font-size: 17px;
  line-height: 1.65;
  color: var(--text-soft);
  margin-bottom: 22px;
}

.me-content a {
  color: var(--text-muted);
  border-bottom: 1px solid transparent;
  transition: color 0.15s ease, border-color 0.15s ease;
}

.me-content a:hover {
  color: var(--text-soft);
  border-color: var(--text-muted);
}

.signature {
  width: 170px;
  height: auto;
  margin: 24px 0 28px;
  opacity: 0.9;
}

.social-row {
  display: flex;
  gap: 28px;
  flex-wrap: wrap;
}

.social-row a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 1px;
  color: var(--text-muted);
}

.social-row a:hover { color: var(--text-soft); }

.social-row svg { width: 12px; height: 12px; }

/* ---------- Case study pages ---------- */

.cs-hero {
  text-align: center;
  max-width: 760px;
  margin: 40px auto 56px;
}

.cs-logo {
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 3px;
  color: var(--text-muted);
  margin-bottom: 28px;
}

.cs-hero h1 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 48px;
  line-height: 1.25;
  color: var(--text-primary);
}

.cs-hero p {
  margin-top: 20px;
  font-size: 17px;
  line-height: 1.6;
  color: var(--text-muted);
  max-width: 560px;
  margin-left: auto;
  margin-right: auto;
}

.cs-strip {
  display: flex;
  gap: var(--grid-gap);
  margin-bottom: 100px;
}

.cs-strip .card-media {
  flex: 1;
  height: 260px;
  border-radius: var(--radius);
}

.cs-section {
  max-width: 640px;
  margin: 0 auto 100px;
  text-align: center;
}

.cs-section.wide { max-width: 900px; }

.cs-eyebrow {
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--text-dim);
  margin-bottom: 16px;
}

.cs-section h2 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 32px;
  line-height: 1.3;
  color: var(--text-primary);
  margin-bottom: 20px;
}

.cs-section p {
  font-size: 16px;
  line-height: 1.7;
  color: var(--text-muted);
}

.cs-section .cs-media {
  margin-top: 40px;
  border-radius: var(--radius);
  overflow: hidden;
}

.cs-subgrid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  margin-top: 48px;
  text-align: left;
}

.cs-subgrid .cs-eyebrow { margin-bottom: 12px; }

.cs-image-row {
  display: flex;
  gap: var(--grid-gap);
  margin-top: 40px;
}

.cs-image-row .card-media { flex: 1; height: 220px; border-radius: var(--radius-sm); }

.cs-image-stack { display: flex; flex-direction: column; gap: var(--grid-gap); margin-top: 40px; }
.cs-image-stack .card-media { height: 300px; border-radius: var(--radius-sm); }

.cs-reflection {
  display: flex;
  justify-content: space-between;
  gap: 40px;
  max-width: 1000px;
  margin: 0 auto 48px;
  flex-wrap: wrap;
}

.cs-reflection .col-left { flex: 1 1 280px; }
.cs-reflection .col-right { flex: 1 1 380px; }

.cs-reflection h2 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 32px;
  color: var(--text-primary);
  line-height: 1.3;
}

.cs-reflection p {
  font-size: 15px;
  line-height: 1.7;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.cs-footer {
  max-width: 1000px;
  margin: 0 auto;
  padding-top: 32px;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 1px;
  color: var(--text-muted);
}

.cs-footer a:hover { color: var(--text-soft); }

/* ---------- Responsive ---------- */

@media (max-width: 900px) {
  .hero h1 { font-size: 40px; }
  .grid { flex-direction: column; }
  .me-layout { flex-direction: column; }
  .me-photo { width: 100%; max-width: 410px; }
  .cs-strip { flex-wrap: wrap; }
  .cs-strip .card-media { flex: 1 1 45%; }
  .cs-subgrid { grid-template-columns: 1fr; }
  .cs-hero h1 { font-size: 34px; }
}

@media (max-width: 560px) {
  .nav-pill a { font-size: 14px; padding: 9px 14px; }
  .hero h1 { font-size: 32px; }
  .hero p { font-size: 18px; line-height: 1.5; }
}
