/* ============================================================
   Binmodules site system
   The parent brand is neutral. Each product supplies its own accent.

   To add a product:
     1. add a [data-product="slug"] block below (light)
     2. add the matching block inside the dark-mode media query
     3. set <body data-product="slug"> on that product's page
     4. add a .product-card to the grid in /index.html
   ============================================================ */

:root {
  --paper:      #ffffff;
  --paper-2:    #f6f8f9;
  --paper-3:    #eef1f3;
  --ink:        #0f1419;
  --ink-2:      #5b6670;
  --line:       #e3e7ea;
  --line-2:     #cfd6db;

  /* Neutral parent accent - products override this */
  --accent:        #1f2933;
  --accent-strong: #0f1419;
  --accent-soft:   #eef1f3;
  --on-accent:     #ffffff;

  --sans: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --display: var(--sans);

  --wrap: 1120px;
  --radius: 14px;
  --shadow: 0 1px 2px rgba(15, 20, 25, .04), 0 8px 24px rgba(15, 20, 25, .06);
}

/* ---- Product accents (light) ---- */
[data-product="tariff-lens"] {
  --accent: #155e4b;
  --accent-strong: #0d4738;
  --accent-soft: #e4efea;
  --on-accent: #ffffff;
  --display: Newsreader, Georgia, serif;
}

[data-product="mobile-apps"] {
  --accent: #5b5bd6;
  --accent-strong: #4646b8;
  --accent-soft: #ececfb;
  --on-accent: #ffffff;
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper:   #0e1114;
    --paper-2: #141920;
    --paper-3: #1b222a;
    --ink:     #e8ecef;
    --ink-2:   #99a4ad;
    --line:    #232b33;
    --line-2:  #333d47;

    --accent:        #e8ecef;
    --accent-strong: #ffffff;
    --accent-soft:   #1b222a;
    --on-accent:     #0f1419;
  }

  [data-product="tariff-lens"] {
    --accent: #4cb894;
    --accent-strong: #6fd0ae;
    --accent-soft: #10241e;
    --on-accent: #06140f;
  }

  [data-product="mobile-apps"] {
    --accent: #9a9aef;
    --accent-strong: #b5b5f5;
    --accent-soft: #181832;
    --on-accent: #0c0c20;
  }
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

body {
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a { color: inherit; }
img, svg { max-width: 100%; }
::selection { background: var(--accent-soft); color: var(--accent-strong); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 24px; }
.narrow { max-width: 760px; }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: var(--paper);
  border-bottom: 1px solid var(--line);
}

.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-height: 66px;
  flex-wrap: wrap;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  font-weight: 700;
  letter-spacing: -.02em;
}

/* Light: full PNG lockup. Dark: the PNG wordmark is navy, so show the mark + text instead. */
.brand { color: var(--ink); }
.brand-logo { height: 34px; width: auto; display: block; flex: none; }
.brand-mark { display: none; height: 30px; width: auto; flex: none; }
.brand-name { display: none; font-size: 1.12rem; }
@media (prefers-color-scheme: dark) {
  .brand-logo { display: none; }
  .brand-mark { display: block; }
  .brand-name { display: inline; }
}

.site-nav { display: flex; align-items: center; gap: 24px; flex-wrap: wrap; }
.site-nav a { color: var(--ink-2); text-decoration: none; font-weight: 500; font-size: .94rem; transition: color .15s; }
.site-nav a:hover { color: var(--accent); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 12px 22px;
  border-radius: 10px;
  font-weight: 600;
  font-size: .95rem;
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform .15s, box-shadow .15s, background .15s, border-color .15s;
}

.btn svg { width: 18px; height: 18px; flex: none; }
.btn-primary { background: var(--accent); color: var(--on-accent); }
.btn-primary:hover { background: var(--accent-strong); transform: translateY(-1px); box-shadow: var(--shadow); }
.btn-ghost { border-color: var(--line-2); color: var(--ink); background: transparent; }
.btn-ghost:hover { border-color: var(--accent); color: var(--accent); }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }

/* ---------- Eyebrow / pills ---------- */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--accent-soft);
  color: var(--accent-strong);
  padding: 6px 14px;
  border-radius: 999px;
  font-size: .82rem;
  font-weight: 600;
  margin-bottom: 20px;
}

.eyebrow svg { width: 15px; height: 15px; }

.pill {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 999px;
  border: 1px solid var(--line-2);
  color: var(--ink-2);
  font-size: .76rem;
  font-weight: 600;
  letter-spacing: .02em;
  text-transform: uppercase;
}

/* ---------- Sections ---------- */
section { padding: 84px 0; }
.section-alt { background: var(--paper-2); border-block: 1px solid var(--line); }
.section-head { max-width: 680px; margin-bottom: 48px; }
.section-head.center { margin-inline: auto; text-align: center; }

h1, h2, h3 { letter-spacing: -.025em; line-height: 1.18; font-weight: 700; }
h1 { font-family: var(--display); font-size: clamp(2.1rem, 5.2vw, 3.3rem); }
h2 { font-family: var(--display); font-size: clamp(1.6rem, 3.4vw, 2.2rem); }
h3 { font-size: 1.1rem; }
.lede { font-size: 1.15rem; color: var(--ink-2); margin-top: 18px; }
.muted { color: var(--ink-2); }

/* ---------- Hero ---------- */
.hero { padding: 96px 0 80px; }
.hero h1 { max-width: 17ch; }
.hero .lede { max-width: 58ch; font-size: 1.22rem; }
.hero .btn-row { margin-top: 34px; }

/* ---------- Card grid ---------- */
.grid { display: grid; gap: 22px; }
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(258px, 1fr)); }

.card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px;
}

.card h3 { margin-bottom: 10px; }
.card p { color: var(--ink-2); font-size: .95rem; }

/* Product card - the repeatable unit of this site */
.product-card {
  display: flex;
  flex-direction: column;
  text-decoration: none;
  position: relative;
  overflow: hidden;
  transition: transform .18s, box-shadow .18s, border-color .18s;
}

.product-card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 3px;
  background: var(--accent);
}

.product-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: var(--line-2); }

.product-card .icon {
  width: 46px;
  height: 46px;
  border-radius: 11px;
  margin-bottom: 20px;
  display: grid;
  place-items: center;
  background: var(--accent-soft);
  color: var(--accent-strong);
}

.product-card .icon svg { width: 23px; height: 23px; }
.product-card .status { margin-top: auto; padding-top: 20px; display: flex; align-items: center; gap: 10px; }
.product-card .go { color: var(--accent); font-weight: 600; font-size: .92rem; }

/* ---------- Numbered steps ---------- */
.steps { counter-reset: step; display: grid; gap: 2px; }

.step {
  display: grid;
  grid-template-columns: 44px 1fr;
  gap: 20px;
  align-items: start;
  padding: 24px 0;
  border-bottom: 1px solid var(--line);
}

.step:last-child { border-bottom: 0; }

.step::before {
  counter-increment: step;
  content: counter(step, decimal-leading-zero);
  font-variant-numeric: tabular-nums;
  font-weight: 700;
  font-size: .9rem;
  color: var(--accent);
  padding-top: 2px;
}

.step h3 { margin-bottom: 6px; }
.step p { color: var(--ink-2); font-size: .95rem; }

/* ---------- Spec list ---------- */
.specs { display: grid; gap: 0; border-top: 1px solid var(--line); }

.spec {
  display: grid;
  grid-template-columns: minmax(180px, 32%) 1fr;
  gap: 24px;
  padding: 18px 0;
  border-bottom: 1px solid var(--line);
}

.spec dt { font-weight: 600; font-size: .95rem; }
.spec dd { color: var(--ink-2); font-size: .95rem; }

/* ---------- Callout ---------- */
.callout {
  border-left: 3px solid var(--accent);
  background: var(--accent-soft);
  padding: 22px 26px;
  border-radius: 0 var(--radius) var(--radius) 0;
}

.callout strong { color: var(--accent-strong); }

/* ---------- Contact ---------- */
.contact-card { text-align: center; }

.mail-link {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  font-weight: 600;
  font-size: 1.05rem;
  color: var(--accent);
  text-decoration: none;
  word-break: break-word;
}

.mail-link:hover { text-decoration: underline; }
.mail-link svg { width: 21px; height: 21px; flex: none; }

/* ---------- Prose (legal pages) ---------- */
.prose h2 { font-size: 1.28rem; margin: 40px 0 12px; }
.prose h2:first-child { margin-top: 0; }
.prose p, .prose li { color: var(--ink-2); font-size: .97rem; }
.prose p { margin-bottom: 14px; }
.prose ul { margin: 0 0 16px 22px; }
.prose li { margin-bottom: 8px; }
.prose a { color: var(--accent); }
.prose strong { color: var(--ink); }

/* ---------- Footer ---------- */
.site-footer {
  border-top: 1px solid var(--line);
  background: var(--paper-2);
  padding: 52px 0 40px;
}

.footer-top { display: flex; justify-content: space-between; gap: 40px; flex-wrap: wrap; margin-bottom: 40px; }
.footer-col h4 { font-size: .78rem; text-transform: uppercase; letter-spacing: .07em; color: var(--ink-2); margin-bottom: 14px; }
.footer-col a { display: block; color: var(--ink-2); text-decoration: none; font-size: .93rem; margin-bottom: 9px; }
.footer-col a:hover { color: var(--accent); }

.footer-bottom {
  border-top: 1px solid var(--line);
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  font-size: .87rem;
  color: var(--ink-2);
}

/* ============================================================
   Display components
   Reusable across product pages, not specific to one product.
   ============================================================ */

.mono {
  font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
  font-size: .84rem;
  letter-spacing: -.01em;
}

/* Split hero: copy beside a visual */
.split {
  display: grid;
  grid-template-columns: 1.05fr .95fr;
  gap: 64px;
  align-items: center;
}

/* Hairline rule with optional label */
.rule {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 28px;
  color: var(--ink-2);
  font-size: .78rem;
  font-weight: 600;
  letter-spacing: .09em;
  text-transform: uppercase;
}

.rule::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--line);
}

/* ---- Document -> data visual ---- */
.doc-flow { display: grid; gap: 0; }

.doc-card, .data-card {
  border-radius: 14px;
  border: 1px solid var(--line);
  background: var(--paper);
  overflow: hidden;
}

.doc-card-head, .data-card-head {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 11px 18px;
  border-bottom: 1px solid var(--line);
  background: var(--paper-2);
  font-size: .74rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--ink-2);
}

.doc-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--line-2); flex: none; }
.data-card-head .doc-dot { background: var(--accent); }

.doc-body {
  padding: 20px 18px;
  color: var(--ink-2);
  white-space: pre-wrap;
  line-height: 1.75;
  margin: 0;
}

.flow-arrow {
  display: grid;
  place-items: center;
  height: 42px;
  position: relative;
}

.flow-arrow::before {
  content: "";
  position: absolute;
  inset: 0 auto;
  width: 1px;
  height: 100%;
  background: linear-gradient(var(--line-2), var(--accent));
}

.flow-arrow span {
  position: relative;
  background: var(--paper);
  color: var(--accent);
  padding: 3px 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: .68rem;
  font-weight: 700;
  letter-spacing: .09em;
  text-transform: uppercase;
}

.fields { margin: 0; padding: 6px 0; }

.fields > div {
  display: grid;
  grid-template-columns: 42% 1fr;
  gap: 16px;
  padding: 8px 18px;
  align-items: baseline;
}

.fields dt {
  color: var(--ink-2);
  font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
  font-size: .78rem;
}

.fields dd {
  margin: 0;
  font-weight: 600;
  font-size: .9rem;
  color: var(--ink);
}

.fields dd.accent { color: var(--accent); }

.fields .trace {
  border-top: 1px solid var(--line);
  margin-top: 6px;
  padding-top: 14px;
}

.fields .trace dd { font-weight: 500; color: var(--ink-2); font-size: .84rem; }

/* ---- Dark feature panel (intentionally dark in both themes) ---- */
.panel {
  background: #0b1a16;
  color: #d7e5df;
  border-radius: 20px;
  padding: 52px;
}

.panel h2 { color: #ffffff; }
.panel .lede { color: #9fb5ac; }
.panel a { color: #79d3b2; }

.panel-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 1px;
  background: rgba(255, 255, 255, .09);
  border: 1px solid rgba(255, 255, 255, .09);
  border-radius: 14px;
  overflow: hidden;
  margin-top: 40px;
}

.panel-cell { background: #0b1a16; padding: 26px 24px; }
.panel-cell h3 { color: #ffffff; margin-bottom: 8px; font-size: 1rem; }
.panel-cell p { color: #9fb5ac; font-size: .9rem; margin: 0; }

.panel-cell .tag {
  display: block;
  color: #c2a15e;
  font-size: .7rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  margin-bottom: 12px;
}

/* ---- Numbered pillars ---- */
.pillars { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 0; }

.pillar { padding: 32px 30px; border-left: 1px solid var(--line); }
.pillar:first-child { border-left: 0; padding-left: 0; }

.pillar .n {
  display: block;
  font-family: var(--display);
  font-size: 1.9rem;
  line-height: 1;
  color: var(--accent);
  margin-bottom: 16px;
}

.pillar h3 { margin-bottom: 10px; }
.pillar p { color: var(--ink-2); font-size: .95rem; }

@media (max-width: 900px) {
  .split { grid-template-columns: 1fr; gap: 48px; }
  .panel { padding: 36px 26px; }
  .pillars { grid-template-columns: 1fr; }
  .pillar { border-left: 0; border-top: 1px solid var(--line); padding: 28px 0; }
  .pillar:first-child { border-top: 0; padding-top: 0; }
}

@media (max-width: 640px) {
  section { padding: 60px 0; }
  .hero { padding: 64px 0 56px; }
  .site-header .wrap { min-height: 0; padding-block: 12px; }
  .spec { grid-template-columns: 1fr; gap: 4px; }
  .step { grid-template-columns: 32px 1fr; gap: 14px; }
  .fields > div { grid-template-columns: 1fr; gap: 2px; }
  .panel { padding: 30px 20px; }
}
