/* Indexo supplier site — shared styles.
   Layout: a calm, document-like site. A slim header, generous text column,
   project "credit sheets" on profiles. Brand: slate ink + Indexo orange. */

:root {
  --bg: #F6F7F9;
  --surface: #FFFFFF;
  --ink: #0F172A;
  --ink-2: #334155;
  --muted: #64748B;
  --line: #E2E8F0;
  --accent: #F7941D;          /* Indexo orange, used on marks and buttons */
  --accent-ink: #B45F06;      /* orange dark enough for text on light */
  --accent-soft: #FEF1E1;
  --good: #047857;
  --good-soft: #E3F4EC;
  --warn: #92600A;
  --warn-soft: #FBF0D9;
  --bad: #B42318;
  --bad-soft: #FDE7E5;

  --f-display: "Montserrat", "Arial Rounded MT Bold", Arial, sans-serif;
  --f-body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --f-mono: "JetBrains Mono", ui-monospace, Menlo, Consolas, monospace;

  --radius: 8px;
  --max: 1080px;
}

/* Light by default; dark ("CAD mode") only when chosen with the toggle on the map. */
:root[data-theme="dark"] {
    --bg: #0B1120;
    --surface: #111A2E;
    --ink: #F1F5F9;
    --ink-2: #CBD5E1;
    --muted: #94A3B8;
    --line: #1F2A40;
    --accent: #F7941D;
    --accent-ink: #FDB45C;
    --accent-soft: #3A2610;
    --good: #5FD3A5;
    --good-soft: #0F2E24;
    --warn: #F2C866;
    --warn-soft: #33290F;
    --bad: #F59A90;
    --bad-soft: #3A1A17;
    color-scheme: dark;
  }

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--f-body);
  font-size: 16px;
  line-height: 1.6;
}
img { max-width: 100%; display: block; }
a { color: var(--accent-ink); text-underline-offset: 3px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 3px; }

.container {
  max-width: var(--max);
  margin: 0 auto;
  padding-left: max(20px, env(safe-area-inset-left, 0px));
  padding-right: max(20px, env(safe-area-inset-right, 0px));
}

/* ---------- Wordmark (text, so it renders on every phone) ---------- */
.wordmark {
  font-family: "Nunito", var(--f-display);
  font-weight: 900;
  font-size: 26px;
  letter-spacing: 0.02em;
  color: var(--ink);
  text-decoration: none;
  line-height: 1;
  display: inline-flex;
  align-items: baseline;
}
.wordmark .x { color: var(--accent); transform: scaleX(1.18); display: inline-block; margin: 0 0.04em; }

/* ---------- Header / footer ---------- */
.site-header { border-bottom: 1px solid var(--line); background: var(--surface); }
.site-header .container {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding-block: 16px;
}
.site-header nav { display: flex; gap: 20px; font-size: 14px; font-weight: 500; }
.site-header nav a { color: var(--ink-2); text-decoration: none; }
.site-header nav a:hover { color: var(--ink); }

.site-footer { border-top: 1px solid var(--line); margin-top: 72px; }
.site-footer .container {
  padding-block: 28px 40px;
  display: flex; flex-wrap: wrap; gap: 12px 32px; justify-content: space-between;
  font-size: 14px; color: var(--muted);
}
.site-footer a { color: var(--muted); }

/* ---------- Type ---------- */
h1, h2, h3 { font-family: var(--f-display); color: var(--ink); text-wrap: balance; margin: 0; }
h1 { font-size: clamp(32px, 5.4vw, 52px); font-weight: 800; line-height: 1.08; letter-spacing: -0.02em; }
h2 { font-size: clamp(22px, 3vw, 28px); font-weight: 800; line-height: 1.2; letter-spacing: -0.01em; }
h3 { font-size: 18px; font-weight: 700; line-height: 1.3; }
p { margin: 0; }
.lead { font-size: clamp(17px, 2vw, 20px); color: var(--ink-2); max-width: 60ch; }
.eyebrow {
  font-family: var(--f-mono); font-size: 12px; font-weight: 500;
  letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted);
}
.mono { font-family: var(--f-mono); font-variant-numeric: tabular-nums; }
.muted { color: var(--muted); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font: 600 15px/1 var(--f-body);
  padding: 13px 20px; border-radius: var(--radius);
  border: 1px solid var(--line); background: var(--surface); color: var(--ink);
  text-decoration: none; cursor: pointer;
}
.btn:hover { border-color: var(--ink-2); }
.btn.primary { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.btn.primary:hover { opacity: 0.92; }
.btn[disabled] { opacity: 0.55; cursor: not-allowed; }

/* ---------- Landing ---------- */
.hero { padding-block: 72px 56px; display: grid; gap: 24px; }
.hero .actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 8px; }

.credit-sample {
  margin-top: 16px;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  max-width: 640px; overflow: hidden;
}
.credit-sample .row {
  display: grid; grid-template-columns: 150px 1fr; gap: 12px;
  padding: 11px 16px; border-bottom: 1px solid var(--line); font-size: 14px;
}
.credit-sample .row:last-child { border-bottom: 0; }
.credit-sample .k { font-family: var(--f-mono); font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: 0.06em; padding-top: 2px; }
.credit-sample .caption { padding: 10px 16px; background: var(--bg); font-size: 13px; color: var(--muted); }

.section { padding-block: 48px; border-top: 1px solid var(--line); }
.section > .container { display: grid; gap: 28px; }

.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 28px; }
.step { display: grid; gap: 8px; align-content: start; }
.step .n {
  font-family: var(--f-mono); font-size: 13px; font-weight: 500; color: var(--accent-ink);
}
.step p { color: var(--ink-2); }

.two { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 32px; }
.points { display: grid; gap: 14px; padding: 0; margin: 0; list-style: none; }
.points li { padding-left: 22px; position: relative; color: var(--ink-2); }
.points li::before {
  content: ""; position: absolute; left: 0; top: 0.62em;
  width: 9px; height: 9px; border-radius: 2px; background: var(--accent);
}

.faq { display: grid; gap: 0; max-width: 760px; }
.faq details { border-bottom: 1px solid var(--line); padding-block: 16px; }
.faq summary { cursor: pointer; font-weight: 600; list-style: none; display: flex; justify-content: space-between; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-family: var(--f-mono); color: var(--muted); }
.faq details[open] summary::after { content: "–"; }
.faq details p { margin-top: 10px; color: var(--ink-2); max-width: 65ch; }

.find {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 20px; display: grid; gap: 12px; max-width: 640px;
}

/* ---------- Profile ---------- */
.profile-head { padding-block: 40px 28px; display: grid; gap: 14px; }
.profile-head .meta { display: flex; flex-wrap: wrap; gap: 8px 18px; color: var(--muted); font-size: 15px; }

.status {
  display: flex; gap: 12px; align-items: flex-start;
  background: var(--warn-soft); color: var(--ink);
  border: 1px solid color-mix(in srgb, var(--warn) 30%, transparent);
  border-radius: var(--radius); padding: 14px 16px; font-size: 15px;
}
.status.claimed { background: var(--good-soft); border-color: color-mix(in srgb, var(--good) 30%, transparent); }
.status strong { display: block; }

.pill {
  display: inline-block; font-size: 12px; font-weight: 600;
  padding: 3px 9px; border-radius: 999px; white-space: nowrap;
  background: var(--line); color: var(--ink-2);
}
.pill.warn { background: var(--warn-soft); color: var(--warn); }
.pill.good { background: var(--good-soft); color: var(--good); }
.pill.example { background: var(--accent-soft); color: var(--accent-ink); }

.layout { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 32px; align-items: start; }
@media (max-width: 880px) { .layout { grid-template-columns: minmax(0, 1fr); } }

.projects { display: grid; gap: 16px; }
.project {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden;
}
.project .top { padding: 16px 18px 12px; display: flex; justify-content: space-between; gap: 12px; align-items: start; }
.project dl { margin: 0; display: grid; grid-template-columns: 130px minmax(0, 1fr); border-top: 1px solid var(--line); }
.project dt, .project dd { padding: 9px 18px; margin: 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.project dt { font-family: var(--f-mono); font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: 0.06em; padding-top: 11px; }
.project dd { color: var(--ink-2); min-width: 0; overflow-wrap: anywhere; }
.project dl > :nth-last-child(-n+2) { border-bottom: 0; }
@media (max-width: 480px) {
  .project dl { grid-template-columns: minmax(0, 1fr); }
  .project dt { border-bottom: 0; padding-bottom: 0; }
}

/* ---------- Claim form ---------- */
.claim {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 22px; display: grid; gap: 18px;
  position: sticky; top: 16px;
}
@media (max-width: 880px) { .claim { position: static; } }
.claim-form { display: grid; gap: 24px; }
.claim fieldset { border: 0; padding: 0; margin: 0; display: grid; gap: 12px; min-width: 0; }
.claim legend { font-weight: 700; font-size: 15px; margin-bottom: 4px; padding: 0; }
.field { display: grid; gap: 5px; }
.field label, .field .label { font-size: 13px; font-weight: 600; color: var(--ink-2); }
.field .hint { font-size: 12px; color: var(--muted); }
input[type="text"], input[type="email"], input[type="tel"], input[type="url"], input[type="search"], textarea, select {
  font: 15px/1.4 var(--f-body); color: var(--ink);
  background: var(--bg); border: 1px solid var(--line); border-radius: 6px;
  padding: 10px 12px; width: 100%; min-width: 0;
}
input:focus, textarea:focus, select:focus { outline: 2px solid var(--accent); outline-offset: 0; border-color: transparent; }
textarea { min-height: 84px; resize: vertical; }
.choice { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; color: var(--ink-2); cursor: pointer; }
.choice input { margin-top: 4px; accent-color: var(--accent); flex: none; }
.choice-list { display: grid; gap: 8px; }
.project-check {
  display: grid; gap: 6px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 6px;
}
.project-check .pname { font-weight: 600; font-size: 14px; }
.project-check .opts { display: flex; flex-wrap: wrap; gap: 6px 14px; }
.project-check .opts label { display: flex; gap: 6px; align-items: center; font-size: 13px; color: var(--ink-2); cursor: pointer; }
.project-check .opts input { accent-color: var(--accent); }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-msg { font-size: 14px; }
.form-msg.err { color: var(--bad); }
.done {
  display: grid; gap: 10px; text-align: left;
}
.done .tick {
  width: 40px; height: 40px; border-radius: 50%;
  background: var(--good-soft); color: var(--good);
  display: grid; place-items: center; font-weight: 800; font-size: 20px;
}

/* ---------- Simple pages ---------- */
.doc { padding-block: 48px; display: grid; gap: 20px; max-width: 720px; }
.doc h2 { margin-top: 16px; }
.doc p, .doc li { color: var(--ink-2); }
.doc ul { margin: 0; padding-left: 20px; display: grid; gap: 6px; }

.notfound { padding-block: 80px; display: grid; gap: 16px; max-width: 620px; }

@media (prefers-reduced-motion: reduce) { * { scroll-behavior: auto !important; } }
