/* ==========================================================================
   tribes — marketing site. Locked "Ink & Citrus" editorial theme:
   paper #FAF8F4 · ink #14130F · tangerine #FF5A1F · teal #15403B ·
   mustard #C98A2B · warm hairline #E6E2D8.
   Space Grotesk: BOLD lowercase display + UPPERCASE tracked micro-labels.
   Sharp 6-8px radii, hard 1px ink borders, hard offset shadows. No emojis.
   ========================================================================== */

:root {
  --paper: #faf8f4;
  --surface: #ffffff;
  --ink: #14130f;
  --muted: #6b665c;
  --citrus: #ff5a1f;
  --citrus-dark: #d8430f;
  --teal: #15403b;
  --mustard: #c98a2b;
  --warmgrey: #e7e2d8;
  --hairline: #e6e2d8;

  --border: 1px solid var(--ink);
  --border-soft: 1px solid var(--hairline);
  --r: 8px;
  --r-sm: 6px;

  --shadow-hard: 4px 4px 0 var(--ink);
  --shadow-hard-sm: 3px 3px 0 var(--ink);

  --ease: cubic-bezier(0.4, 0, 0.2, 1);
  --maxw: 1140px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: "Space Grotesk", system-ui, sans-serif;
  background: var(--paper);
  color: var(--ink);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
::selection { background: var(--citrus); color: #fff; }

h1, h2, h3 { margin: 0; font-weight: 700; letter-spacing: -0.03em; line-height: 1.02; }
.lower { text-transform: lowercase; }

.micro {
  font-size: 11.5px; font-weight: 700; letter-spacing: 0.16em; text-transform: uppercase;
}

.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 clamp(20px, 5vw, 44px); }

/* ---------------- nav ---------------- */
.nav {
  position: fixed; inset: 0 0 auto 0; z-index: 90;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 clamp(20px, 4vw, 36px);
  height: 64px;
  background: var(--paper);
  border-bottom: var(--border);
}
.brand { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 19px; text-transform: lowercase; }
.brand .mark {
  width: 30px; height: 30px; border-radius: var(--r-sm);
  display: grid; place-items: center;
  background: var(--citrus); color: #fff;
  border: var(--border);
  font-size: 15px; font-weight: 700;
}
.nav-links { display: flex; align-items: center; gap: 26px; }
.nav-links a.navlink { font-size: 12px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink); position: relative; padding: 4px 0; }
.nav-links a.navlink::after {
  content: ""; position: absolute; left: 0; right: 100%; bottom: 0;
  height: 3px; background: var(--citrus); transition: right 0.25s var(--ease);
}
.nav-links a.navlink:hover::after, .nav-links a.navlink.active::after { right: 0; }

/* ---------------- buttons ---------------- */
.btn {
  display: inline-flex; align-items: center; gap: 9px;
  padding: 13px 22px; border-radius: var(--r-sm);
  font-family: "Space Grotesk"; font-size: 12.5px; font-weight: 700;
  letter-spacing: 0.12em; text-transform: uppercase;
  border: var(--border); cursor: pointer;
  transition: transform 0.18s var(--ease), box-shadow 0.18s var(--ease), background 0.18s;
}
.btn svg { width: 15px; height: 15px; }
.btn-citrus { background: var(--citrus); color: #fff; box-shadow: var(--shadow-hard-sm); }
.btn-citrus:hover { transform: translate(-2px, -2px); box-shadow: 5px 5px 0 var(--ink); background: var(--citrus-dark); }
.btn-paper { background: var(--surface); color: var(--ink); box-shadow: var(--shadow-hard-sm); }
.btn-paper:hover { transform: translate(-2px, -2px); box-shadow: 5px 5px 0 var(--ink); }
.btn-ink { background: var(--ink); color: var(--paper); box-shadow: 3px 3px 0 var(--citrus); }
.btn-ink:hover { transform: translate(-2px, -2px); box-shadow: 5px 5px 0 var(--citrus); }
.btn-sm { padding: 10px 16px; }

/* ---------------- ticker strip ---------------- */
.ticker {
  border-top: var(--border); border-bottom: var(--border);
  background: var(--ink); color: var(--paper);
  overflow: hidden; white-space: nowrap;
  padding: 10px 0;
}
.ticker .lane { display: inline-block; animation: tick 28s linear infinite; }
.ticker span { font-size: 12px; font-weight: 700; letter-spacing: 0.18em; text-transform: uppercase; margin: 0 22px; }
.ticker b { color: var(--citrus); }
@keyframes tick { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* ---------------- hero ---------------- */
.hero { padding: 140px 0 0; position: relative; }
.hero-grid { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: clamp(28px, 4vw, 56px); align-items: center; padding-bottom: clamp(40px, 6vw, 72px); }
.eyebrow {
  display: inline-flex; align-items: center; gap: 9px;
  padding: 8px 14px; border-radius: var(--r-sm);
  border: var(--border); background: var(--surface);
  font-size: 11px; font-weight: 700; letter-spacing: 0.16em; text-transform: uppercase;
  box-shadow: var(--shadow-hard-sm); margin-bottom: 26px;
}
.eyebrow .dot { width: 8px; height: 8px; background: var(--citrus); border: 1px solid var(--ink); }
.hero h1 { font-size: clamp(44px, 6.6vw, 82px); text-transform: lowercase; }
.hero h1 .hl { color: var(--citrus); }
.hero h1 .box {
  display: inline-block; background: var(--ink); color: var(--paper);
  padding: 0 14px 6px; border-radius: var(--r-sm); line-height: 1.05;
  box-shadow: 4px 4px 0 var(--citrus);
}
.hero .lede { font-size: clamp(15.5px, 1.55vw, 18px); color: var(--muted); font-weight: 500; max-width: 50ch; margin: 24px 0 30px; line-height: 1.65; }
.hero-ctas { display: flex; gap: 14px; flex-wrap: wrap; }
.hero-foot { margin-top: 26px; display: flex; gap: 20px; flex-wrap: wrap; }
.hero-foot span { font-size: 11.5px; font-weight: 700; letter-spacing: 0.13em; text-transform: uppercase; color: var(--muted); display: inline-flex; align-items: center; gap: 7px; }
.hero-foot svg { width: 14px; height: 14px; color: var(--citrus); }

/* hero collage: tribe cards + match card, hard-edged */
.collage { position: relative; min-height: 430px; }
.tile {
  position: absolute; background: var(--surface); border: var(--border); border-radius: var(--r);
  box-shadow: var(--shadow-hard); padding: 16px;
}
.tile .mono {
  width: 38px; height: 38px; border-radius: var(--r-sm); border: var(--border);
  display: grid; place-items: center; font-weight: 700; font-size: 16px; color: #fff;
  margin-bottom: 10px;
}
.tile .tile-title { margin: 0 0 3px; font-size: 15.5px; font-weight: 700; text-transform: lowercase; }
.tile .sub { font-size: 11px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); }
.tile .chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.chip {
  font-size: 10.5px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase;
  padding: 4px 9px; border: var(--border); border-radius: 99px; background: var(--paper);
}
.chip.fill { background: var(--citrus); color: #fff; }
.chip.teal { background: var(--teal); color: #fff; }
.chip.mustard { background: var(--mustard); color: #fff; }
.match-bar { margin-top: 12px; }
.match-bar .track { height: 10px; border: var(--border); border-radius: 99px; background: var(--paper); overflow: hidden; }
.match-bar .fill { height: 100%; width: 78%; background: var(--citrus); }
.match-bar .label { font-size: 10.5px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; margin-top: 6px; color: var(--muted); }

/* ---------------- sections ---------------- */
section { padding: clamp(56px, 7.5vw, 92px) 0; }
.sec-head { max-width: 660px; margin-bottom: 44px; }
.sec-head.center { margin-inline: auto; text-align: center; }
.kicker { color: var(--citrus); margin-bottom: 14px; display: inline-flex; align-items: center; gap: 10px; }
.kicker::before { content: ""; width: 26px; height: 3px; background: var(--citrus); }
.sec-title { font-size: clamp(30px, 4.2vw, 50px); text-transform: lowercase; }
.sec-title .hl { color: var(--citrus); }
.sec-sub { font-size: clamp(15px, 1.4vw, 17px); color: var(--muted); font-weight: 500; margin-top: 14px; line-height: 1.65; }

/* numbered editorial cards */
.grid { display: grid; gap: 18px; }
.cols-3 { grid-template-columns: repeat(3, 1fr); }
.cols-2 { grid-template-columns: repeat(2, 1fr); }
.cols-4 { grid-template-columns: repeat(4, 1fr); }

.ed-card {
  position: relative;
  background: var(--surface); border: var(--border); border-radius: var(--r);
  padding: 26px; box-shadow: var(--shadow-hard);
  transition: transform 0.18s var(--ease), box-shadow 0.18s var(--ease);
}
a.ed-card:hover { transform: translate(-3px, -3px); box-shadow: 7px 7px 0 var(--ink); }
.ed-card .num {
  position: absolute; top: 18px; right: 20px;
  font-size: 12px; font-weight: 700; letter-spacing: 0.1em; color: var(--muted);
}
.ed-card .tag { display: inline-block; font-size: 10.5px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; padding: 5px 10px; border: var(--border); border-radius: var(--r-sm); margin-bottom: 16px; }
.ed-card .tag.citrus { background: var(--citrus); color: #fff; }
.ed-card .tag.teal { background: var(--teal); color: #fff; }
.ed-card .tag.mustard { background: var(--mustard); color: #fff; }
.ed-card .tag.ink { background: var(--ink); color: var(--paper); }
.ed-card h3 { font-size: 19px; text-transform: lowercase; margin-bottom: 9px; }
.ed-card p { font-size: 14px; color: var(--muted); font-weight: 500; margin: 0; line-height: 1.6; }

/* big stat band */
.stat-band { border-top: var(--border); border-bottom: var(--border); background: var(--surface); }
.stat-grid { display: grid; grid-template-columns: repeat(3, 1fr); }
.stat { padding: 34px 28px; border-right: var(--border); }
.stat:last-child { border-right: none; }
.stat .big { font-size: clamp(34px, 4vw, 52px); font-weight: 700; letter-spacing: -0.04em; }
.stat .big em { font-style: normal; color: var(--citrus); }
.stat .micro { color: var(--muted); margin-top: 6px; display: block; }

/* detail rows */
.row { display: grid; grid-template-columns: repeat(12, 1fr); gap: clamp(24px, 5vw, 56px); align-items: center; padding: 50px 0; }
.row + .row { border-top: var(--border-soft); }
.row .copy { grid-column: 1 / span 6; }
.row .aside { grid-column: 8 / span 5; }
.row.flip .copy { grid-column: 7 / span 6; order: 2; }
.row.flip .aside { grid-column: 1 / span 5; order: 1; }
.row h2 { font-size: clamp(24px, 3vw, 34px); text-transform: lowercase; margin-bottom: 13px; }
.row p { font-size: 15px; color: var(--muted); font-weight: 500; line-height: 1.68; margin: 0 0 12px; }
.row p b { color: var(--ink); font-weight: 700; }
.mini { list-style: none; margin: 16px 0 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.mini li { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; font-weight: 500; }
.mini li svg { width: 17px; height: 17px; flex: none; color: var(--citrus); margin-top: 1px; }

/* aside panel: a hard-edged mock */
.panel {
  position: relative; border: var(--border); border-radius: var(--r);
  background: var(--surface); box-shadow: var(--shadow-hard);
  min-height: 250px; overflow: hidden; padding: 18px;
}
.panel .p-row { display: flex; align-items: center; gap: 12px; padding: 11px 12px; border: var(--border); border-radius: var(--r-sm); background: var(--paper); margin-bottom: 10px; }
.panel .p-row .mono { width: 34px; height: 34px; border-radius: var(--r-sm); border: var(--border); display: grid; place-items: center; color: #fff; font-weight: 700; font-size: 14px; flex: none; }
.panel .p-row .t { font-size: 14px; font-weight: 700; text-transform: lowercase; }
.panel .p-row .s { font-size: 10.5px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); display: block; margin-top: 1px; }
.panel .p-row .right { margin-left: auto; font-size: 11px; font-weight: 700; letter-spacing: 0.08em; color: var(--citrus); text-transform: uppercase; }

.bg-citrus { background: var(--citrus); }
.bg-teal { background: var(--teal); }
.bg-mustard { background: var(--mustard); }
.bg-ink { background: var(--ink); }

/* CTA slab */
.cta-slab {
  border: var(--border); border-radius: var(--r);
  background: var(--citrus); color: #fff;
  box-shadow: 6px 6px 0 var(--ink);
  padding: clamp(38px, 5.5vw, 64px); text-align: center;
  position: relative; overflow: hidden;
}
.cta-slab h2 { font-size: clamp(30px, 4.4vw, 52px); text-transform: lowercase; }
.cta-slab .sub { font-size: 13px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; margin: 14px 0 28px; opacity: 0.9; }
.cta-slab .hero-ctas { justify-content: center; }
.cta-slab .btn-paper { box-shadow: 3px 3px 0 var(--ink); }

/* ---------------- subpage hero ---------------- */
.page-hero { padding: 140px 0 24px; }
.back { display: inline-flex; align-items: center; gap: 7px; font-size: 11px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); margin-bottom: 22px; }
.back svg { width: 14px; height: 14px; }
.back:hover { color: var(--citrus); }
.page-hero h1 { font-size: clamp(36px, 5vw, 62px); text-transform: lowercase; max-width: 18ch; }
.page-hero .lede { font-size: clamp(15.5px, 1.5vw, 18px); color: var(--muted); font-weight: 500; max-width: 56ch; margin-top: 16px; line-height: 1.65; }

/* ---------------- footer ---------------- */
footer { border-top: var(--border); background: var(--ink); color: var(--paper); padding: 40px 0 48px; margin-top: 30px; }
.foot { display: flex; align-items: center; justify-content: space-between; gap: 18px; flex-wrap: wrap; }
.foot .brand .mark { box-shadow: none; }
.foot-links { display: flex; gap: 22px; }
.foot-links a { font-size: 11px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--paper); opacity: 0.8; }
.foot-links a:hover { color: var(--citrus); opacity: 1; }
.foot-note { font-size: 11px; font-weight: 700; letter-spacing: 0.13em; text-transform: uppercase; opacity: 0.55; }
.foot-divider { width: 1px; height: 12px; background: var(--paper); opacity: 0.2; align-self: center; }
.foot-links a.foot-legal { opacity: 0.45; }
.foot-links a.foot-legal:hover { color: var(--citrus); opacity: 0.8; }

/* ---------------- reveal ---------------- */
.reveal { opacity: 0; transform: translateY(16px); transition: opacity 0.5s var(--ease), transform 0.5s var(--ease); }
.reveal.in { opacity: 1; transform: none; }

/* ---------------- responsive ---------------- */
@media (max-width: 960px) {
  .hero-grid { grid-template-columns: 1fr; }
  .collage { min-height: 380px; }
  .cols-3, .cols-4 { grid-template-columns: 1fr 1fr; }
  .stat-grid { grid-template-columns: 1fr; }
  .stat { border-right: none; border-bottom: var(--border); }
  .stat:last-child { border-bottom: none; }
  .row .copy, .row.flip .copy, .row .aside, .row.flip .aside { grid-column: 1 / span 12; order: initial; }
}
@media (max-width: 640px) {
  .nav-links a.navlink { display: none; }
  .cols-2, .cols-3, .cols-4 { grid-template-columns: 1fr; }
  .hero { padding-top: 120px; }
}
