/* ============================================================
   Shoot Shoot Penguin — Case Study
   Bilingual (KO / EN) case-study page.

   Layout model: a centred 1280 content column in normal flow.
   The previous build positioned every node at absolute Figma
   coordinates inside fixed-height sections; that cannot survive a
   KO/EN swap (the two languages set to different heights), so the
   design tokens and type scale are kept while the composition is
   rebuilt as flow + grid.

   Design tokens: single dark theme. Six colour tokens, two font
   stacks, four type steps (+ one intermediate step for long-form
   case copy). No saturated hue appears in the UI — colour lives
   only inside image and video content.
   ============================================================ */

*,
*::before,
*::after { box-sizing: border-box; }

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

html { scroll-behavior: smooth; scroll-padding-top: 96px; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-weight: 400;
  font-size: var(--fs-body);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
ul, ol { margin: 0; padding: 0; list-style: none; }
h1, h2, h3, p { margin: 0; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }

/* ---- Design tokens ---- */
:root {
  /* Colour — the whole palette. Everything else resolves to one of these. */
  --bg: #1A1A1A;            /* page background */
  --surface: #242423;       /* cards, bands, media slots */
  --text: #F5F5F2;          /* body copy, headings */
  --text-dim: #8B8B88;      /* secondary text, labels */
  --text-faint: #5C5C59;    /* captions, meta */
  --border: rgba(255, 255, 255, 0.08);

  /* Type */
  --font-sans: "Manrope", "Pretendard", sans-serif;
  --font-mono: "Azeret Mono", monospace;

  --fs-display: clamp(2.25rem, 4.5vw, 3.5rem);
  --fs-heading: clamp(1.5rem, 2.5vw, 2rem);
  --fs-mid: 1.125rem;       /* the one permitted intermediate step */
  --fs-body: 1rem;
  --fs-label: 0.8125rem;

  --wrap: 1280px;
  --gutter: 20px;
}

/* ---- Locale switching ------------------------------------------------
   lang code = 'en' / 'ko'. Both variants ship in the HTML; the inactive
   one is hidden.

   Hiding the inactive locale (rather than revealing the active one) keeps
   each block's own display value — a component class like
   `.pain-list { display: grid }` would otherwise out-rank a bare
   [data-lang-content] rule and leak the wrong language.

   No per-locale font rule is needed any more: Manrope carries no Hangul,
   so Korean resolves to Pretendard through the single --font-sans stack.
   -------------------------------------------------------------------- */
html[data-lang="en"] [data-lang-content="ko"],
html[data-lang="ko"] [data-lang-content="en"] { display: none; }

/* ============================================================
   TYPE STEPS
   display / heading / body / label, plus one intermediate step
   (--fs-mid) reserved for long-form case-study copy.
   ============================================================ */

/* Display */
.hero-title {
  font-family: var(--font-sans);
  font-weight: 400;
  font-size: var(--fs-display);
  line-height: 1.18;
  letter-spacing: -0.02em;
  color: var(--text);
}

/* Heading */
.h2,
.thumb-title {
  font-family: var(--font-sans);
  font-weight: 400;
  font-size: var(--fs-heading);
  line-height: 1.25;
  letter-spacing: -0.01em;
  color: var(--text);
}

/* Emphasis inside a heading: weight only, never hue. */
.acc { font-weight: 500; color: var(--text); }

/* Label — section labels, tags, chips, pills, nav, meta. */
.eyebrow,
.chip,
.tag,
.pill,
.logo-sub,
.topnav-links a,
.lang-btn,
.toggle,
.role-label,
.wf-num,
.feat-chip,
.metrics-note,
.sitefoot-copy {
  font-family: var(--font-mono);
  font-weight: 400;
  font-size: var(--fs-label);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-dim);
}

/* ---- Shared layout primitives ---- */
.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 var(--gutter);
}
.section {
  position: relative;
  padding: 72px 0;
}

.eyebrow {
  line-height: 1.2;
  margin-bottom: 20px;
}
.h2--center { text-align: center; }

.lead {
  margin-top: 20px;
  max-width: 820px;
  font-size: var(--fs-body);
  line-height: 1.6;
  color: var(--text-dim);
}
.lead--center { margin-left: auto; margin-right: auto; text-align: center; }
.lead--xl {
  max-width: 940px;
  font-size: var(--fs-mid);
  line-height: 1.6;
  color: var(--text);
}

/* ---- Chips / tags ---- */
.chip {
  display: inline-block;
  padding: 8px 14px;
  border-radius: 9999px;
  background: var(--surface);
  border: 1px solid var(--border);
  line-height: 1.2;
  white-space: nowrap;
}
.chip--lg { padding: 10px 16px; }

.tagrow { display: flex; flex-wrap: wrap; gap: 8px; }
.tag {
  padding: 5px 12px;
  border: 1px solid var(--border);
  border-radius: 9999px;
  line-height: 1.3;
  white-space: nowrap;
}

/* ---- Flow diagrams (pill → arrow → pill) ---- */
.flow {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-top: 32px;
}
.flow--center { justify-content: center; }
.pill {
  padding: 10px 16px;
  border-radius: 9999px;
  background: var(--surface);
  border: 1px solid var(--border);
  line-height: 1.2;
  white-space: nowrap;
}
.flow-arrow {
  flex: none;
  display: inline-flex;
  color: var(--text-faint);
}
.flow-arrow svg {
  width: 20px; height: 20px;
  fill: none; stroke: currentColor;
  stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round;
}

/* ============================================================
   SITE CHROME — wordmark, project link, language toggle
   ============================================================ */
.topnav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 24px var(--gutter) 8px;
}
.logo { display: block; }
.logo-name {
  display: block;
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: var(--fs-mid);
  line-height: 1.2;
  letter-spacing: -0.01em;
  color: var(--text);
}
.logo-sub {
  display: block;
  margin-top: 2px;
}
.topnav-links { display: flex; align-items: center; gap: 20px; }
.topnav-links a {
  transition: color 0.15s ease;
}
.topnav-links a:hover,
.topnav-links a.is-active { color: var(--text); }

.lang {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 4px;
  border: 1px solid var(--border);
  border-radius: 9999px;
}
.lang-btn {
  padding: 4px 10px;
  border-radius: 9999px;
  transition: color 0.15s ease, background 0.15s ease;
}
.lang-btn:hover { color: var(--text); }
.lang-btn.is-active { color: var(--text); background: var(--surface); }

/* ---- Section navigation (sticky) ---- */
.navpill {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  gap: 4px;
  padding: 12px var(--gutter);
  overflow-x: auto;
  scrollbar-width: none;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}
.navpill::-webkit-scrollbar { display: none; }
.toggle {
  flex: none;
  padding: 8px 14px;
  border-radius: 9999px;
  line-height: 1.2;
  white-space: nowrap;
  transition: color 0.15s ease, background 0.15s ease;
}
.toggle:hover { color: var(--text); }
.toggle--active { color: var(--text); background: var(--surface); }

/* ============================================================
   01 — OVERVIEW / HERO
   ============================================================ */
.hero { padding-top: 48px; overflow: hidden; }
.hero-inner { position: relative; z-index: 1; }

/* Neutral depth only — the former orange bloom carried hue into the UI. */
.hero-glow {
  position: absolute;
  width: 520px; height: 520px;
  border-radius: 50%;
  background: radial-gradient(circle,
    color-mix(in srgb, var(--text) 5%, transparent) 0%,
    transparent 70%);
  filter: blur(60px);
  pointer-events: none;
}
.hero-glow--tr { right: -180px; top: -60px; }
.hero-glow--bl { left: -220px; bottom: 40px; }

.hero-title { margin-top: 8px; }

.hero-body {
  margin-top: 24px;
  max-width: 880px;
  font-size: var(--fs-mid);
  line-height: 1.6;
  color: var(--text);
}

/* Key-visual slot */
.thumb {
  position: relative;
  margin-top: 48px;
  aspect-ratio: 16 / 9;
  border-radius: 20px;
  border: 1px solid var(--border);
  background:
    radial-gradient(circle at 50% 40%,
      color-mix(in srgb, var(--text) 4%, transparent) 0%,
      transparent 60%),
    var(--surface);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 20px;
  padding: 24px;
  text-align: center;
}
.thumb .tagrow { justify-content: center; }

.role-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  margin-top: 48px;
}
.rolecol { padding-top: 20px; border-top: 1px solid var(--border); }
.role-value {
  margin-top: 10px;
  font-size: var(--fs-body);
  line-height: 1.6;
  color: var(--text);
}

/* ============================================================
   02 — THE PROBLEM
   ============================================================ */
.problem .lead { margin-top: 28px; max-width: 900px; }

.wf { margin-top: 56px; }
.wf-cards {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  margin-top: 20px;
}
.wf-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 18px;
  border-radius: 14px;
  background: var(--surface);
  border: 1px solid var(--border);
}
.wf-num { flex: none; }
.wf-label { font-size: var(--fs-body); line-height: 1.6; color: var(--text); }
.wf-caption {
  margin-top: 20px;
  font-size: var(--fs-body);
  line-height: 1.6;
  color: var(--text-dim);
}

.pain-cards {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
  margin-top: 48px;
}
.pain-card {
  padding: 28px 24px;
  border-radius: 18px;
  background: var(--surface);
  border: 1px solid var(--border);
}
.pain-list {
  margin-top: 20px;
  padding-left: 18px;
  border-left: 2px solid var(--border);
  display: grid;
  gap: 12px;
}
.pain-list li {
  position: relative;
  padding-left: 16px;
  font-size: var(--fs-body); line-height: 1.6;
  color: var(--text);
}
.pain-list li::before {
  content: "";
  position: absolute;
  left: 0; top: 10px;
  width: 5px; height: 5px;
  border-radius: 50%;
  background: var(--text-faint);
}

/* ============================================================
   03 — THE CORE QUESTION  (full-bleed band)
   ============================================================ */
.coreq {
  padding: 88px 0;
  background: var(--surface);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.coreq .eyebrow { text-align: center; }

/* ============================================================
   04 — SYSTEM ARCHITECTURE
   ============================================================ */
.loop { margin-top: 40px; }
.flow--loop { margin-top: 0; }

/* The feedback connector only reads correctly when the pills sit on one
   line, which happens from the desktop breakpoint up. */
.loop-line { display: none; }

/* ============================================================
   05 / 06 — SIDE A · SIDE B
   ============================================================ */
.side-head {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 20px;
}
.side-body {
  display: grid;
  grid-template-columns: 1fr;
  gap: 32px;
  margin-top: 44px;
  align-items: start;
}
.feat-cards { display: grid; gap: 16px; }
.feat-card {
  position: relative;
  display: flex;
  align-items: flex-start;
  gap: 18px;
  padding: 24px;
  padding-top: 52px;
  border-radius: 16px;
  background: var(--surface);
  border: 1px solid var(--border);
}
.feat-num {
  flex: none;
  font-family: var(--font-mono);
  font-weight: 400;
  font-size: var(--fs-heading);
  line-height: 1;
  letter-spacing: 0.02em;
  color: var(--text-dim);
}
.feat-title {
  font-weight: 500;
  font-size: var(--fs-body);
  line-height: 1.6;
  color: var(--text);
}
.feat-desc {
  margin-top: 6px;
  font-size: var(--fs-body);
  line-height: 1.6;
  color: var(--text-dim);
}
.feat-chip {
  position: absolute;
  top: 18px; right: 20px;
  padding: 5px 12px;
  border-radius: 9999px;
  background: var(--bg);
  border: 1px solid var(--border);
  line-height: 1.2;
  white-space: nowrap;
}

/* Prototype slot */
.phone {
  width: 100%;
  max-width: 360px;
  aspect-ratio: 390 / 844;
  margin: 0 auto;
  border-radius: 28px;
  background: var(--surface);
  border: 1px solid var(--border);
  overflow: hidden;
}
/* Recordings are 2160x4670 — same 390:844 ratio as the slot, so cover crops
   nothing; it only absorbs sub-pixel rounding. */
.phone-video {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.side-caption {
  margin-top: 40px;
  max-width: 680px;
  margin-left: auto; margin-right: auto;
  text-align: center;
  font-size: var(--fs-body);
  line-height: 1.6;
  color: var(--text-dim);
}

/* ============================================================
   07 — KEY DECISIONS & COLLABORATION
   ============================================================ */
.dec-cards {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
  margin-top: 44px;
}
.dec-card {
  padding: 28px 24px;
  border-radius: 18px;
  background: var(--surface);
  border: 1px solid var(--border);
}
.dec-num {
  display: block;
  font-family: var(--font-mono);
  font-weight: 400;
  font-size: var(--fs-heading);
  line-height: 1;
  letter-spacing: 0.02em;
  color: var(--text-dim);
}
.dec-title {
  margin-top: 14px;
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: var(--fs-mid);
  line-height: 1.4;
  letter-spacing: -0.01em;
  color: var(--text);
}
.dec-body {
  margin-top: 12px;
  font-size: var(--fs-body);
  line-height: 1.6;
  color: var(--text-dim);
}

.collab-card {
  margin-top: 24px;
  padding: 28px 24px;
  border-radius: 18px;
  background: var(--surface);
  border: 1px solid var(--border);
}
.collab-body {
  margin-top: 18px;
  padding-left: 18px;
  border-left: 2px solid var(--border);
  max-width: 900px;
  font-size: var(--fs-body);
  line-height: 1.6;
  color: var(--text);
}

/* ============================================================
   08 — WHERE IT STANDS
   ============================================================ */
.metrics {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
  margin-top: 44px;
}
.metric {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 22px 20px;
  border-radius: 16px;
  background: var(--surface);
  border: 1px solid var(--border);
}
.metric-dir {
  flex: none;
  font-family: var(--font-mono);
  font-weight: 400;
  font-size: var(--fs-mid);
  line-height: 1;
  color: var(--text);
}
.metric-label { font-size: var(--fs-body); line-height: 1.6; color: var(--text); }
.metrics-note {
  margin-top: 16px;
  color: var(--text-faint);
}

.reflection {
  margin-top: 48px;
  padding: 32px 28px;
  border-radius: 18px;
  background: var(--surface);
  border: 1px solid var(--border);
}
.reflection-body {
  margin-top: 20px;
  max-width: 900px;
  font-size: var(--fs-mid);
  line-height: 1.6;
  color: var(--text);
}

/* ============================================================
   SEE MORE PROJECTS
   ============================================================ */
.seemore { border-top: 1px solid var(--border); }
.proj-cards {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
  margin-top: 32px;
}
.proj-card {
  position: relative;
  display: flex;
  flex-direction: column;
  border-radius: 18px;
  background: var(--surface);
  border: 1px solid var(--border);
  overflow: hidden;
  transition: border-color 0.18s ease, transform 0.18s ease;
}
.proj-card:hover { border-color: var(--text-faint); transform: translateY(-2px); }
.proj-thumb {
  aspect-ratio: 16 / 9;
  background:
    radial-gradient(circle at 50% 50%,
      color-mix(in srgb, var(--text) 4%, transparent) 0%,
      transparent 65%),
    var(--bg);
  border-bottom: 1px solid var(--border);
}
.proj-meta { padding: 24px; }
.proj-title {
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: var(--fs-mid);
  line-height: 1.3;
  letter-spacing: -0.01em;
  color: var(--text);
}
.proj-desc {
  margin-top: 10px;
  font-size: var(--fs-body);
  line-height: 1.6;
  color: var(--text-dim);
}
.proj-card .tagrow { margin-top: 18px; }
.proj-go {
  position: absolute;
  top: 20px; right: 20px;
  width: 34px; height: 34px;
  display: grid; place-items: center;
  border-radius: 50%;
  background: var(--bg);
  border: 1px solid var(--border);
  font-size: var(--fs-body);
  color: var(--text);
}

/* ============================================================
   FOOTER
   ============================================================ */
.sitefoot {
  border-top: 1px solid var(--border);
  padding: 40px 0 56px;
}
.sitefoot-inner {
  display: flex;
  flex-direction: column;
  gap: 10px;
  align-items: flex-start;
}
.sitefoot-mail {
  font-size: var(--fs-body);
  color: var(--text);
  border-bottom: 1px solid var(--border);
  padding-bottom: 2px;
  transition: color 0.15s ease, border-color 0.15s ease;
}
.sitefoot-mail:hover { color: var(--text-dim); border-color: var(--text-faint); }
.sitefoot-copy { color: var(--text-faint); }

/* ============================================================
   TABLET  (>= 768px)
   ============================================================ */
@media (min-width: 768px) {
  :root { --gutter: 40px; }

  .section { padding: 96px 0; }
  .coreq { padding: 112px 0; }

  .wf-cards { grid-template-columns: repeat(2, 1fr); }
  .pain-cards { grid-template-columns: repeat(2, 1fr); }
  .role-grid { grid-template-columns: repeat(2, 1fr); gap: 28px 40px; }
  .dec-cards { grid-template-columns: repeat(2, 1fr); }
  .metrics { grid-template-columns: repeat(2, 1fr); }
  .proj-cards { grid-template-columns: repeat(2, 1fr); }

  .side-head { flex-direction: row; justify-content: space-between; align-items: flex-start; }
  .side-head > div { flex: 1; }

  .sitefoot-inner { flex-direction: row; align-items: center; justify-content: space-between; }
}

/* ============================================================
   DESKTOP  (>= 992px)
   ============================================================ */
@media (min-width: 992px) {
  .section { padding: 120px 0; }
  .coreq { padding: 140px 0; }

  .eyebrow { margin-bottom: 24px; }

  .wf-cards { grid-template-columns: repeat(4, 1fr); }
  .role-grid { grid-template-columns: repeat(4, 1fr); }
  .metrics { grid-template-columns: repeat(4, 1fr); }

  /* Side A / B: cards on the left, prototype pinned alongside. The device
     slot is taller than the card stack, so the stack is centred against it
     rather than leaving all the slack below. */
  .side-body { grid-template-columns: minmax(0, 1fr) 390px; gap: 56px; }
  .feat-cards { align-self: center; }
  .phone { max-width: 390px; margin: 0; position: sticky; top: 112px; }

  .feat-card { padding: 28px; padding-top: 28px; align-items: center; }
  .feat-chip { top: 20px; right: 24px; }

  /* Feedback loop: pills hold a single row, so draw the return line */
  .flow--loop { flex-wrap: nowrap; }
  .loop-line {
    display: block;
    width: 100%; height: 44px;
    margin-top: 4px;
    color: var(--text-faint);
  }

  .navpill { gap: 8px; padding: 14px var(--gutter); }
  .toggle { padding: 8px 16px; }
}

/* ============================================================
   MOTION
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .proj-card { transition: none; }
}
