/* ==========================================================================
   CRAFT LAYER — homepage only (linked after styles.css in index.html)
   Purpose: make the typographic system, hierarchy, colour discipline and
   branding explicit. Case-study pages do not load this file.

   Rules the page now follows
   - Type: Space Grotesk leads, Instrument Serif Italic is the single human
     voice (one word per headline), Figtree reads, JetBrains Mono labels.
   - Scale: 12 / 17 / 20 / 48 / 62 (fluid), one step apart is always visible.
   - Colour: linen + ink do the work; coral marks the one thing to act on.
   - Radius: 20px for surfaces, pill only for buttons. No stacked shadows.
   ========================================================================== */

:root {
  --serif-weight: 400;
  --craft-radius: 20px;
  --craft-measure: 60ch;
}

/* ---------- Brand ---------- */
.brand { gap: 3px; }
.brand-name {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-size: 1.0625rem;
  font-weight: 600;
  letter-spacing: -0.025em;
  text-transform: none;
}
.brand-mark {
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: var(--accent-coral);
  flex: none;
  transition: transform var(--transition-smooth);
}
.brand:hover .brand-mark { transform: scale(1.35); }
.brand-role {
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding-left: 20px;
}

/* ---------- Section labels: no false numbering ---------- */
.section-meta {
  gap: 10px;
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  color: var(--text-secondary);
  margin-bottom: 18px;
}
.section-meta::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent-coral);
}

/* ---------- Headings: scale + single serif voice ---------- */
.section-title {
  font-size: clamp(2.25rem, 4.6vw, 3.5rem);
  line-height: 1.04;
  letter-spacing: -0.04em;
  max-width: 14em;
  text-wrap: balance;
}
.section-title em,
.hero-headline .coral-accent {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: var(--serif-weight);
  letter-spacing: -0.02em;
  font-size: 1.1em;
  line-height: 0.9;
}
.section-desc {
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--text-secondary);
}

/* ---------- Hero hierarchy ---------- */
.hero-headline {
  font-size: clamp(2.6rem, 4.7vw, 4.1rem);
  line-height: 1;
  letter-spacing: -0.045em;
  text-wrap: balance;
}
.hero-headline .coral-accent { font-size: 1.12em; }
.hero-bio {
  font-size: 1.125rem;
  line-height: 1.6;
  color: var(--text-secondary);
  max-width: 32em;
}

.stats-strip { gap: 0; border-top: 1px solid var(--border-strong); }
.stat-item {
  padding: 18px 28px 0 0;
  margin-right: 28px;
}
.stat-item + .stat-item { border-left: 1px solid var(--border-subtle); padding-left: 28px; }
.stat-value {
  font-size: 1.75rem;
  font-weight: 500;
  letter-spacing: -0.04em;
}
.stat-label {
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

/* ---------- Work cards: quieter chrome, stronger type ---------- */
.project-card {
  border-radius: var(--craft-radius);
  box-shadow: none;
}
.project-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.project-index { display: none; }
.project-content { padding: 28px 26px 26px; gap: 10px; }
.project-title {
  font-size: 1.9rem;
  letter-spacing: -0.035em;
  line-height: 1.05;
}
.project-category {
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.project-desc { color: var(--text-secondary); line-height: 1.6; }

/* tags become one quiet line of metadata, not a wall of pills */
.project-tags { gap: 0; margin-top: 6px; }
.project-tags .tag-pill {
  background: none;
  border: 0;
  padding: 0;
  border-radius: 0;
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  letter-spacing: 0.04em;
  color: var(--text-muted);
}
.project-tags .tag-pill:not(:last-child)::after { content: "/"; margin: 0 8px; opacity: 0.5; }

.project-action { color: var(--text-primary); font-weight: 600; }
.project-card:hover .project-action { color: var(--accent-coral); }

/* ---------- Radius discipline for the rest of the surfaces ---------- */
.process-card, .experience-card { border-radius: var(--craft-radius); }
.tag-pill { border-radius: 6px; }

/* ---------- Responsive ---------- */
@media (max-width: 640px) {
  .stat-item, .stat-item + .stat-item { padding-left: 16px; padding-right: 0; margin-right: 16px; }
  .stat-item:first-child { padding-left: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .brand-mark { transition: none; }
}

/* Guard: hero grid columns must be allowed to shrink below their content */
.hero-left, .hero-right { min-width: 0; }
@media (max-width: 900px) {
  .hero-grid { grid-template-columns: minmax(0, 1fr); }
  .bento-collage { max-width: 100%; }
}

@media (max-width: 460px) {
  .bento-collage {
    grid-template-columns: minmax(0, 7fr) minmax(0, 7fr) minmax(0, 4fr);
    grid-template-rows: 120px 88px 78px;
    gap: 10px;
  }
  .bento-card { padding: 14px; }
}

@media (max-width: 640px) {
  .brand-name, .btn-hire { white-space: nowrap; }
  .stats-strip { display: grid; grid-template-columns: repeat(3, auto); justify-content: start; }
  .stat-item, .stat-item + .stat-item { margin-right: 0; padding-right: 14px; padding-left: 14px; }
  .stat-item:first-child { padding-left: 0; }
  .stat-label { max-width: 11ch; }
}
@media (max-width: 480px) {
  .brand-role { display: none; }
}
