/* ============================================================
   WeSimplify — Design System (test-site)
   All fonts: Chakra Petch
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Chakra+Petch:ital,wght@0,300;0,400;0,500;0,600;1,400&display=swap');

:root {
  --bg:           #0f0e0c;
  --bg-raised:    #161512;
  --bg-border:    #1a1917;
  --fg:           #f5f2ec;
  --fg-muted:     #d4d0c8;
  --fg-dim:       #6b6860;
  --gold:         #c8a84b;
  --gold-bg:      rgba(200, 168, 75, 0.08);
  --gold-border:  rgba(200, 168, 75, 0.28);
  --blue:         #4a6fa5;
  --red:          #e8442a;
  --border:       rgba(245, 242, 236, 0.07);

  --font-mono:  'Chakra Petch', Arial, sans-serif;
  --font-serif: 'Chakra Petch', Arial, sans-serif;

  --max-w: 960px;
  --radius: 2px;
  --transition: 0.2s ease;
}

/* ── Reset ─────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; scroll-behavior: smooth; }
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
ul { list-style: none; }
button { font-family: inherit; cursor: pointer; }

/* ── Base ───────────────────────────────────────────────────── */
body {
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-mono);
  font-size: 0.875rem;
  line-height: 1.75;
  min-height: 100vh;
  overflow-x: hidden;
}

/* ── Grain overlay ─────────────────────────────────────────── */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: 9999;
  pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='300'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='300' height='300' filter='url(%23n)'/%3E%3C/svg%3E");
  background-size: 300px 300px;
  opacity: 0.038;
}

/* ── Layout ─────────────────────────────────────────────────── */
.container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 2rem;
}
.container--narrow {
  max-width: 680px;
  margin: 0 auto;
  padding: 0 2rem;
}

/* ── Navigation ─────────────────────────────────────────────── */
nav {
  position: sticky;
  top: 0;
  z-index: 100;
  border-bottom: 1px solid var(--border);
  background: rgba(15, 14, 12, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}
.nav-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 2rem;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: relative;
}
.nav-logo {
  font-family: var(--font-mono);
  font-size: 1.1rem;
  letter-spacing: 0.02em;
  color: var(--fg);
  z-index: 1;
}
.nav-links {
  display: flex;
  align-items: center;
  gap: 2.25rem;
}
.nav-links a {
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--fg-muted);
  transition: color var(--transition);
}
.nav-links a:hover { color: var(--fg); }
.nav-links a.active { color: var(--gold); }

.nav-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--fg);
  padding: 0.25rem;
  z-index: 1;
}
.nav-toggle svg { display: block; }

/* ── Nav right group (theme + hamburger) ────────────────────── */
.nav-right {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  z-index: 1;
}

.theme-toggle {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}
.theme-toggle__btn {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 2px solid transparent;
  cursor: pointer;
  transition: border-color 0.15s ease;
  flex-shrink: 0;
  padding: 0;
}
.theme-toggle__btn--dark {
  background: #1a1a1a;
  outline: 1px solid rgba(245,242,236,0.3);
}
.theme-toggle__btn--light {
  background: #f5f2ec;
  outline: 1px solid rgba(26,26,26,0.2);
}
.theme-toggle__btn.active {
  border-color: var(--gold);
}

/* ── Hero ───────────────────────────────────────────────────── */
.hero {
  padding: 7rem 0 5.5rem;
  border-bottom: 1px solid var(--border);
}
.hero__eyebrow {
  font-size: 0.68rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 1.5rem;
}
.hero__headline {
  font-family: var(--font-serif);
  font-size: clamp(2rem, 4vw, 3.4rem);
  line-height: 1.18;
  color: var(--fg);
  max-width: 720px;
  margin-bottom: 1.75rem;
}
.hero__sub {
  font-size: 0.875rem;
  color: var(--fg-muted);
  max-width: 520px;
  line-height: 1.85;
  margin-bottom: 2.75rem;
}
.hero__actions {
  display: flex;
  gap: 0.875rem;
  flex-wrap: wrap;
  align-items: center;
}

/* ── Buttons ────────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.65rem 1.4rem;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  border-radius: var(--radius);
  transition: all var(--transition);
  white-space: nowrap;
}
.btn--primary {
  background: var(--gold);
  color: var(--bg);
  border: 1px solid var(--gold);
  font-weight: 500;
}
.btn--primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 18px rgba(200, 168, 75, 0.28);
}
.btn--outline {
  background: transparent;
  color: var(--fg);
  border: 1px solid var(--border);
}
.btn--outline:hover {
  border-color: var(--fg-muted);
  transform: translateY(-1px);
}
.btn--ghost {
  background: transparent;
  color: var(--fg-muted);
  border: none;
  padding-left: 0;
  padding-right: 0;
}
.btn--ghost:hover { color: var(--fg); }

/* ── Page header ────────────────────────────────────────────── */
.page-header {
  padding: 4rem 0 4rem;
  border-bottom: 1px solid var(--border);
}
.page-header__eyebrow {
  font-size: 0.68rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 1rem;
}
.page-header__title {
  font-family: var(--font-serif);
  font-size: clamp(2rem, 3.5vw, 2.8rem);
  line-height: 1.2;
  margin-bottom: 1rem;
}
.page-header__sub {
  font-size: 0.875rem;
  color: var(--fg-muted);
  max-width: 520px;
  line-height: 1.85;
}

/* ── Sections ───────────────────────────────────────────────── */
.section {
  padding: 4rem 0;
  border-bottom: 1px solid var(--border);
}
.section:last-of-type { border-bottom: none; }

.section__eyebrow {
  font-size: 0.68rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 0.75rem;
}
.section__title {
  font-family: var(--font-serif);
  font-size: clamp(1.5rem, 2.5vw, 2.1rem);
  line-height: 1.25;
  margin-bottom: 1.25rem;
}
.section__body {
  font-size: 0.875rem;
  color: var(--fg-muted);
  line-height: 1.85;
  max-width: 600px;
}
.section__body p + p { margin-top: 1rem; }

/* ── Grids ──────────────────────────────────────────────────── */
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
  margin-top: 3rem;
}
.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.25rem;
  margin-top: 3rem;
}

/* ── Cards ──────────────────────────────────────────────────── */
.card {
  background: var(--bg-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.75rem;
  transition: border-color var(--transition), transform var(--transition);
}
.card:hover {
  border-color: var(--gold-border);
}
.card--link:hover {
  transform: translateY(-2px);
}
.card__eyebrow {
  font-size: 0.65rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 0.75rem;
}
.card__title {
  font-family: var(--font-mono);
  font-size: 1.1rem;
  line-height: 1.3;
  margin-bottom: 0.75rem;
}
.card__body {
  font-size: 0.8rem;
  color: var(--fg-muted);
  line-height: 1.8;
}
.card__footer {
  margin-top: 1.5rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.card__arrow {
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--fg-dim);
  transition: color var(--transition);
  display: flex;
  align-items: center;
  gap: 0.4rem;
}
.card:hover .card__arrow { color: var(--gold); }

/* ── Layers (3-column) ──────────────────────────────────────── */
.layers {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  margin-top: 3rem;
}
.layer {
  padding: 2rem 1.75rem;
  border-right: 1px solid var(--border);
}
.layer:last-child { border-right: none; }
.layer__num {
  font-size: 0.62rem;
  letter-spacing: 0.18em;
  color: var(--gold);
  margin-bottom: 0.875rem;
  display: block;
}
.layer__title {
  font-family: var(--font-mono);
  font-size: 1.05rem;
  margin-bottom: 0.625rem;
}
.layer__body {
  font-size: 0.78rem;
  color: var(--fg-muted);
  line-height: 1.75;
}

/* ── Steps ──────────────────────────────────────────────────── */
.steps {
  display: flex;
  align-items: flex-start;
  gap: 0;
  margin-top: 3rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}
.step {
  flex: 1;
  padding: 1.75rem 1.5rem;
  border-right: 1px solid var(--border);
  position: relative;
}
.step:last-child { border-right: none; }
.step__num {
  font-size: 0.6rem;
  letter-spacing: 0.18em;
  color: var(--gold);
  margin-bottom: 0.625rem;
  display: block;
}
.step__label {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--fg);
  margin-bottom: 0.4rem;
}
.step__desc {
  font-size: 0.75rem;
  color: var(--fg-dim);
  line-height: 1.65;
}

/* ── CTA Strip ──────────────────────────────────────────────── */
.cta-strip {
  padding: 6rem 0;
  text-align: center;
}
.cta-strip__title {
  font-family: var(--font-serif);
  font-size: clamp(1.6rem, 3vw, 2.6rem);
  line-height: 1.2;
  margin-bottom: 0.875rem;
}
.cta-strip__sub {
  font-size: 0.875rem;
  color: var(--fg-muted);
  margin-bottom: 2.25rem;
  max-width: 440px;
  margin-left: auto;
  margin-right: auto;
  line-height: 1.8;
}

/* ── Tags ───────────────────────────────────────────────────── */
.tag {
  display: inline-flex;
  align-items: center;
  padding: 0.22rem 0.65rem;
  background: var(--bg-raised);
  border: 1px solid var(--border);
  border-radius: 2px;
  font-size: 0.65rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--fg-muted);
}
.tag--gold {
  border-color: var(--gold-border);
  color: var(--gold);
  background: var(--gold-bg);
}
.tag--blue {
  border-color: rgba(74, 111, 165, 0.35);
  color: var(--blue);
  background: rgba(74, 111, 165, 0.08);
}

/* ── Divider ────────────────────────────────────────────────── */
.divider {
  width: 36px;
  height: 1px;
  background: var(--gold);
  opacity: 0.45;
  margin: 1.75rem 0;
}

/* ── Inline stat row ────────────────────────────────────────── */
.stat-row {
  display: flex;
  gap: 3rem;
  margin-top: 3rem;
  flex-wrap: wrap;
}
.stat__num {
  font-family: var(--font-mono);
  font-size: 2.2rem;
  line-height: 1;
  color: var(--fg);
  margin-bottom: 0.375rem;
}
.stat__label {
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--fg-dim);
}

/* ── Filter bar ─────────────────────────────────────────────── */
.filter-bar {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 2.5rem;
  flex-wrap: wrap;
}
.filter-btn {
  padding: 0.4rem 0.9rem;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--fg-muted);
  transition: all var(--transition);
}
.filter-btn:hover { border-color: var(--fg-dim); color: var(--fg); }
.filter-btn.active {
  background: var(--gold-bg);
  border-color: var(--gold-border);
  color: var(--gold);
}

/* ── Challenger feature block ───────────────────────────────── */
.feature-block {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  margin-top: 3rem;
}
.feature-block__header {
  padding: 1.5rem 2rem;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--bg-raised);
}
.feature-block__title {
  font-family: var(--font-mono);
  font-size: 1.1rem;
}
.feature-block__body {
  padding: 2rem;
}
.feature-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}

/* ── Left-bordered quote/note ───────────────────────────────── */
.note {
  padding: 1.25rem 1.5rem;
  border-left: 2px solid var(--gold);
  background: var(--gold-bg);
  border-radius: 0 var(--radius) var(--radius) 0;
  font-size: 0.875rem;
  color: var(--fg-muted);
  line-height: 1.8;
}

/* ── Footer ─────────────────────────────────────────────────── */
footer {
  border-top: 1px solid var(--border);
  padding: 2.5rem 0;
}
.footer-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}
.footer-logo {
  font-family: var(--font-mono);
  font-size: 1rem;
  color: var(--fg-muted);
}
.footer-copy {
  font-size: 0.68rem;
  color: var(--fg-dim);
  letter-spacing: 0.08em;
}
.footer-links {
  display: flex;
  gap: 1.75rem;
}
.footer-links a {
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--fg-dim);
  transition: color var(--transition);
}
.footer-links a:hover { color: var(--fg-muted); }
.footer-logo-col {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  align-items: flex-start;
}
.footer-agent-link {
  font-family: 'Chakra Petch', Arial, sans-serif;
  font-size: 0.6rem;
  letter-spacing: 0.08em;
  color: var(--fg);
  opacity: 0.5;
  text-decoration: none;
  transition: opacity var(--transition);
}
.footer-agent-link:hover { opacity: 0.8; }

/* ── Chakra Petch overrides for HTML-inline serif elements ──── */
/* These are defined in per-page <style> blocks that load after  */
/* this stylesheet, so !important is required to win.            */
.team-card__name,
.article-card__title,
.case-study__title,
.work-cta__text                         { font-family: var(--font-mono) !important; }

/* ── Font size increases (body copy +2–3px) ─────────────────── */
/* Base body: 0.875rem (14px) → 1rem (16px)                      */
/* Card body: 0.8rem (12.8px) → 0.95rem (15.2px)                 */
body                                    { font-size: 1rem; }
.hero__sub,
.section__body,
.page-header__sub,
.note,
.cta-strip__sub                         { font-size: 1rem; }
.card__body                             { font-size: 0.95rem; }

/* ── Animations ─────────────────────────────────────────────── */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: translateY(0); }
}
.fade-up   { animation: fadeUp 0.5s ease both; }
.fade-up-1 { animation: fadeUp 0.5s 0.1s ease both; }
.fade-up-2 { animation: fadeUp 0.5s 0.2s ease both; }
.fade-up-3 { animation: fadeUp 0.5s 0.3s ease both; }
.fade-up-4 { animation: fadeUp 0.5s 0.4s ease both; }

/* ── Responsive ─────────────────────────────────────────────── */
@media (max-width: 768px) {
  /* Grids → single column */
  .grid-3      { grid-template-columns: 1fr; }
  .grid-2      { grid-template-columns: 1fr; }
  .layers      { grid-template-columns: 1fr; }
  .layer       { border-right: none; border-bottom: 1px solid var(--border); }
  .layer:last-child { border-bottom: none; }
  .steps       { flex-direction: column; }
  .step        { border-right: none; border-bottom: 1px solid var(--border); }
  .step:last-child { border-bottom: none; }
  .feature-row { grid-template-columns: 1fr; }

  /* Spacing −30% */
  .hero      { padding: 3.15rem 0 2.45rem; }
  .section   { padding: 2.8rem 0; }
  .cta-strip { padding: 2.8rem 0; }
  .stat-row  { gap: 2rem; }
  .page-header       { padding: 2.8rem 0; }
  .page-header__title { font-size: clamp(1.4rem, 6vw, 2rem); }

  /* Typography − section eyebrows −20% */
  .section__eyebrow,
  .page-header__eyebrow { font-size: 0.55rem; }
  /* Body copy minimum 15px */
  body       { font-size: 0.9375rem; }
  .card__body { font-size: 0.875rem; }
  .hero__sub, .section__body,
  .page-header__sub { font-size: 0.9375rem; }

  /* Footer */
  .footer-inner { flex-direction: column; align-items: flex-start; }
  .footer-links { flex-wrap: wrap; gap: 1.25rem; }

  /* Mobile nav — full-screen overlay */
  .nav-toggle { display: flex; }
  .nav-right  { gap: 0.75rem; }
  .nav-links {
    display: none;
    position: fixed;
    top: 57px;    /* nav height (56px) + border */
    left: 0;
    right: 0;
    bottom: 0;
    flex-direction: column;
    align-items: flex-start;
    background: rgba(15, 14, 12, 0.98);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    padding: 2rem;
    gap: 1.75rem;
    overflow-y: auto;
    z-index: 190;
  }
  .nav-links.open { display: flex; }
  .nav-links a    { font-size: 1rem; letter-spacing: 0.1em; }
  /* Keep Get in touch CTA readable in overlay */
  .nav-links .nav-cta { display: inline-block; }
}

@media (max-width: 480px) {
  .container       { padding: 0 1.25rem; }
  .container--narrow { padding: 0 1.25rem; }
  .section  { padding: 2rem 0; }
  .page-header { padding: 2rem 0; }
  .cta-strip { padding: 2rem 0; }
}

/* ── Section label overrides ───────────────────────────────── */
.hero__label,
.reveal-label,
.logo-strip__label,
.case-section__label,
.section-label {
  font-family: 'Chakra Petch', Arial, sans-serif !important;
  font-size: clamp(1.8rem, 3vw, 2.6rem) !important;
  font-weight: 700 !important;
  color: #c8a84b !important;
  letter-spacing: normal !important;
  text-transform: none !important;
}

/* ── Light mode ────────────────────────────────────────────── */
:root[data-mode="light"] {
  --bg:          #f5f2ec;
  --bg-raised:   #ede9e0;
  --fg:          #1a1a1a;
  --fg-muted:    #3a3a3a;
  --fg-dim:      #888880;
  --border:      rgba(26,26,26,0.1);
  --gold:        #5c6b2a;
  --gold-bg:     rgba(92,107,42,0.07);
  --gold-border: rgba(92,107,42,0.28);
}
:root[data-mode="light"] nav {
  background: rgba(245,242,236,0.92);
}
@media (max-width: 768px) {
  :root[data-mode="light"] .nav-links {
    background: rgba(245, 242, 236, 0.98);
  }
}
:root[data-mode="light"] .hero__label,
:root[data-mode="light"] .reveal-label,
:root[data-mode="light"] .logo-strip__label,
:root[data-mode="light"] .case-section__label,
:root[data-mode="light"] .section-label {
  color: #5c6b2a !important;
}
