/* Slick Machines — site styles. Tokens live in tokens.css. */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.5;
  color: var(--color-text-primary);
  background: var(--color-bg-page);
}
img { max-width: 100%; display: block; }
a { color: inherit; }

/* Type ramp (matches Figma text styles) */
.display, h1, h2, h3 { font-family: var(--font-heading); font-weight: 600; margin: 0; }
.display { font-size: clamp(40px, 5.2vw, 64px); line-height: 1.05; letter-spacing: -1.5px; }
h1, .h1 { font-size: clamp(32px, 3.6vw, 48px); line-height: 1.12; letter-spacing: -1px; }
h2, .h2 { font-size: clamp(26px, 2.6vw, 32px); line-height: 1.2; letter-spacing: -0.5px; }
h3, .h3 { font-size: clamp(19px, 1.8vw, 22px); line-height: 1.3; letter-spacing: -0.2px; }
p { margin: 0; }
.lead { font-size: clamp(17px, 1.5vw, 20px); line-height: 1.5; color: var(--color-text-secondary); }
.small { font-size: 14px; color: var(--color-text-secondary); }
.label {
  font-family: var(--font-heading); font-weight: 500; font-size: 13px;
  letter-spacing: 1.2px; text-transform: uppercase; color: var(--color-text-accent);
}

/* Layout */
.wrap { width: 100%; max-width: 1440px; margin: 0 auto; padding: 0 clamp(16px, 6.6vw, 96px); }
.section { padding: clamp(64px, 8vw, 112px) 0; }
.stack > * + * { margin-top: var(--spacing-md); }
.stack-lg > * + * { margin-top: var(--spacing-lg); }
.bg-warm { background: var(--color-bg-warm); }
.bg-cream { background: var(--color-bg-cream); }
.bg-brand { background: var(--color-bg-brand); color: var(--color-text-inverse); }
.bg-brand .label, .bg-brand .lead { color: var(--color-text-inverse); }
.bg-ink { background: var(--color-bg-inverse); color: var(--color-text-inverse); }
.section-head { max-width: 780px; margin-bottom: var(--spacing-2xl); }
.grid { display: grid; gap: 20px; }
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr)); }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); }
.grid-4 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); }
.split { display: grid; gap: clamp(40px, 6vw, 96px); grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr)); align-items: center; }

/* Buttons */
.actions { display: flex; flex-wrap: wrap; gap: 16px; }
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 15px 28px; border-radius: var(--radius-full);
  font-family: var(--font-heading); font-weight: 600; font-size: 15px;
  text-decoration: none; border: 1.5px solid transparent; transition: transform .15s ease, background .15s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn:focus-visible, a:focus-visible { outline: 3px solid var(--color-border-brand); outline-offset: 3px; }
.btn-primary { background: var(--color-bg-accent); color: var(--color-text-inverse); }
.btn-primary:hover { background: var(--prim-accent-700); }
.btn-outline { border-color: var(--color-border-brand); color: var(--color-text-brand); }
.bg-brand .btn-outline { border-color: var(--color-bg-cream); color: var(--color-text-inverse); }
.link-arrow { font-family: var(--font-heading); font-weight: 600; font-size: 15px; color: var(--color-text-brand); text-decoration: none; }
.link-arrow:hover { text-decoration: underline; }
.link-arrow::after { content: '  →'; }

/* Nav */
.site-header { background: var(--color-bg-warm); }
.nav { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding-top: 22px; padding-bottom: 22px; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; }
.brand img { height: 34px; width: auto; }
.brand-words { display: flex; flex-direction: column; line-height: 1.1; }
.brand-name { font-family: 'Poppins', var(--font-heading); font-weight: 600; font-size: 16px; letter-spacing: 1.1px; }
.brand-tag { font-family: var(--font-heading); font-weight: 500; font-size: 9px; letter-spacing: 2.3px; color: var(--color-text-brand); }
.nav-links { display: flex; align-items: center; gap: 32px; list-style: none; margin: 0; padding: 0; }
.nav-links a:not(.btn) { text-decoration: none; font-size: 15px; }
.nav-links a:not(.btn):hover, .nav-links a[aria-current="page"] { color: var(--color-text-brand); }
.nav-links a[aria-current="page"] { font-weight: 600; }
.nav-toggle { display: none; background: none; border: 1.5px solid var(--color-border-strong); border-radius: var(--radius-full); padding: 8px 16px; font: 600 14px var(--font-heading); color: var(--color-text-primary); }
@media (max-width: 820px) {
  .nav { flex-wrap: wrap; gap: 12px; }
  .nav-toggle { display: inline-flex; margin-left: auto; }
  .brand { gap: 8px; }
  .brand img { height: 28px; }
  .brand-name { font-size: 14px; }
  .nav-links { display: none; width: 100%; flex-direction: column; align-items: flex-start; gap: 18px; padding: 12px 0 8px; }
  .nav-links.open { display: flex; }
}

/* Hero */
.hero { background: var(--color-bg-warm); padding: clamp(32px, 5vw, 72px) 0 clamp(64px, 8vw, 112px); }
.hero .split { grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); }
@media (max-width: 900px) { .hero .split { grid-template-columns: 1fr; } }
.portrait { position: relative; }
.portrait-photo {
  aspect-ratio: 44 / 52; border-radius: 32px; background: var(--color-bg-cream);
  display: grid; place-items: center; overflow: hidden;
}
.portrait-photo img { width: 100%; height: 100%; object-fit: cover; }
.placeholder-text { font: 500 13px var(--font-heading); letter-spacing: 1.2px; color: var(--color-text-secondary); text-transform: uppercase; }
.quote-card {
  position: absolute; left: -32px; bottom: 32px; max-width: 260px;
  background: var(--color-bg-page); border-radius: 20px; padding: 20px 24px;
  box-shadow: 0 12px 32px rgba(26, 20, 0, 0.12);
}
.quote-card .h3 { color: var(--color-text-brand); }
@media (max-width: 900px) { .quote-card { left: 16px; } }

/* Cards */
.card { border-radius: var(--radius-card); padding: clamp(24px, 2.5vw, 36px); }
.card-warm { background: var(--color-bg-warm); }
.card-white { background: var(--color-bg-page); }
.bg-brand .card-white { color: var(--color-text-primary); }
.step-num { font-family: var(--font-heading); font-weight: 600; font-size: 32px; color: var(--color-text-brand); }
.grid > :nth-child(even) .step-num { color: var(--color-text-accent); }
.dot { display: block; width: 14px; height: 14px; border-radius: 50%; }
.tags { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; padding: 0; margin-bottom: 0; }
.tags li { background: var(--color-bg-warm); border-radius: var(--radius-full); padding: 6px 12px; font-size: 14px; color: var(--color-text-secondary); }

/* Case study cards */
.case { text-decoration: none; display: block; }
.case-img { aspect-ratio: 3 / 2; border-radius: var(--radius-card); background: var(--color-bg-cream); margin-bottom: 18px; overflow: hidden; }
.case-img img { width: 100%; height: 100%; object-fit: cover; }
.case .company { font: 500 13px var(--font-heading); letter-spacing: 1.2px; text-transform: uppercase; color: var(--color-text-brand); }
.case:hover h3 { text-decoration: underline; }
.badge { display: inline-block; font: 500 12px var(--font-heading); letter-spacing: 1px; text-transform: uppercase; padding: 4px 10px; border-radius: var(--radius-full); background: var(--prim-accent-100); color: var(--color-text-accent); }

/* Company list */
.company-list { list-style: none; padding: 0; margin-bottom: 0; display: grid; gap: 12px; }
.company-list li { background: var(--color-bg-warm); border-radius: var(--radius-lg); padding: 18px 24px; font: 600 20px var(--font-heading); }

/* Narrative steps (case study template) */
.narrative { counter-reset: n; list-style: none; padding: 0; margin: 0; display: grid; gap: 20px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 340px), 1fr)); }
.narrative li { counter-increment: n; }
.narrative li::before { content: '0' counter(n); display: block; font: 600 24px var(--font-heading); color: var(--color-text-brand); margin-bottom: 8px; }

/* Form */
.form { display: grid; gap: 18px; }
.field { display: grid; gap: 6px; }
.field label { font: 600 14px var(--font-heading); }
.field input, .field select, .field textarea {
  font: 16px var(--font-body); padding: 14px 16px; border-radius: 12px;
  border: 1.5px solid var(--color-border-default); background: var(--color-bg-page); color: var(--color-text-primary);
}
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--color-border-brand); }
.notice { background: var(--prim-accent-100); color: var(--prim-accent-700); border-radius: 12px; padding: 12px 16px; font-size: 14px; }

/* Footer */
.site-footer { background: var(--color-bg-inverse); color: var(--color-text-inverse); padding: 56px 0; }
.footer-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 24px; }
.footer-links { display: flex; flex-wrap: wrap; gap: 28px; list-style: none; padding: 0; margin: 0; }
.footer-links a { text-decoration: none; font-size: 14px; }
.footer-links a:hover { text-decoration: underline; }
.footer-brand { font: 600 20px var(--font-heading); }
.footer-sub { font-size: 14px; opacity: .8; }
