/* AI Spice Blends — site styles. Black, white, cool gray only. Mobile first. */
:root {
  --black: #0a0a0a;
  --ink: #111214;
  --white: #ffffff;
  --gray-50: #f4f5f6;
  --gray-100: #e9ebee;
  --gray-200: #d6d9de;
  --gray-300: #c9ccd1;
  --gray-500: #8b9098;
  --gray-600: #6b7078;
  --gray-700: #44474d;
  --gray-800: #26282c;
  --gray-900: #17181b;
  --radius: 10px;
  --gutter: 16px;
  --maxw: 1080px;
  --font-head: "Space Grotesk", system-ui, sans-serif;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--white); color: var(--ink);
  font-family: var(--font-body); font-size: 17px; line-height: 1.55;
  -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
img, svg { max-width: 100%; }
a { color: inherit; }
h1, h2, h3 { font-family: var(--font-head); line-height: 1.1; letter-spacing: -0.02em; margin: 0 0 .5em; }
h1 { font-size: clamp(1.9rem, 6.5vw, 3.1rem); font-weight: 700; }
h2 { font-size: clamp(1.45rem, 4.5vw, 2rem); font-weight: 700; }
h3 { font-size: 1.15rem; font-weight: 600; }
p { margin: 0 0 1em; }
.mono { font-family: var(--font-mono); font-size: .82rem; letter-spacing: .01em; }
.muted { color: var(--gray-600); }
.small { font-size: .875rem; }
.wrap { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 var(--gutter); }
.section { padding: 48px 0; }
.section.dark { background: var(--black); color: var(--white); }
.section.dark .muted { color: var(--gray-300); }
.section.gray { background: var(--gray-50); }
.skip { position: absolute; left: -999px; }
.skip:focus { left: 8px; top: 8px; background: var(--white); padding: 8px; z-index: 10; }

/* Header / footer */
.site-header { background: var(--black); color: var(--white); position: sticky; top: 0; z-index: 5; }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 12px; height: 60px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; font-family: var(--font-head); font-weight: 700; font-size: 1.05rem; white-space: nowrap; }
.brand svg { width: 28px; height: 28px; color: var(--white); flex: none; }
.nav-toggle { background: none; border: 1px solid var(--gray-700); color: var(--white); border-radius: 8px; padding: 6px 10px; font: inherit; font-size: .9rem; }
.site-nav { display: none; }
.site-nav.open { display: block; position: absolute; top: 60px; left: 0; right: 0; background: var(--black); border-top: 1px solid var(--gray-800); padding: 8px var(--gutter) 16px; }
.site-nav a { display: block; padding: 10px 0; text-decoration: none; color: var(--gray-300); }
.site-nav a:hover, .site-nav a[aria-current="page"] { color: var(--white); }
@media (min-width: 860px) {
  .nav-toggle { display: none; }
  .site-nav, .site-nav.open { display: flex; position: static; gap: 22px; padding: 0; border: 0; background: none; }
  .site-nav a { padding: 0; font-size: .95rem; }
}
.site-footer { background: var(--black); color: var(--gray-300); padding: 40px 0 48px; font-size: .9rem; }
.site-footer .cols { display: grid; gap: 24px; }
.site-footer a { color: var(--white); }
.site-footer nav a { display: block; text-decoration: none; padding: 3px 0; color: var(--gray-300); }
.site-footer nav a:hover { color: var(--white); }
@media (min-width: 720px) { .site-footer .cols { grid-template-columns: 2fr 1fr 1fr; } }

/* Hero */
.hero { background: var(--black); color: var(--white); padding: 56px 0 64px; }
.hero .display { font-family: var(--font-head); font-weight: 700; font-size: clamp(2.2rem, 9vw, 4.6rem); line-height: 1.02; letter-spacing: -0.035em; margin: 0 0 24px; }
.hero .display span { display: block; }
.hero .display span + span { color: var(--gray-300); }
.hero h1 { font-size: clamp(1.15rem, 3.6vw, 1.5rem); font-weight: 500; color: var(--white); max-width: 34ch; letter-spacing: -0.01em; }
.hero .lede { color: var(--gray-300); max-width: 52ch; }
.page-head { background: var(--black); color: var(--white); padding: 44px 0 48px; }
.page-head .lede { color: var(--gray-300); max-width: 60ch; font-size: 1.05rem; }
.eyebrow { font-family: var(--font-mono); font-size: .78rem; text-transform: uppercase; letter-spacing: .08em; color: var(--gray-500); margin-bottom: 10px; display: block; }

/* Buttons, forms */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 46px; padding: 0 20px; border-radius: 999px; border: 1px solid var(--ink); background: var(--ink); color: var(--white); font: 600 1rem var(--font-body); text-decoration: none; cursor: pointer; }
.btn:hover { background: var(--gray-800); }
.btn.ghost { background: transparent; color: var(--ink); }
.btn.ghost:hover { background: var(--gray-100); }
.dark .btn, .hero .btn, .page-head .btn { background: var(--white); color: var(--black); border-color: var(--white); }
.dark .btn.ghost, .hero .btn.ghost, .page-head .btn.ghost { background: transparent; color: var(--white); }
.btn[disabled] { opacity: .45; cursor: not-allowed; }
.btn.small { min-height: 36px; padding: 0 14px; font-size: .9rem; }
.actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 20px; }
label { font-weight: 500; font-size: .95rem; }
input[type=text], input[type=email], input[type=number], input[type=date], textarea, select {
  width: 100%; font: inherit; font-size: 16px; padding: 11px 12px; border: 1px solid var(--gray-300); border-radius: 8px; background: var(--white); color: var(--ink);
}
textarea { min-height: 110px; resize: vertical; }
input:focus, textarea:focus, select:focus, .btn:focus-visible, a:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
.field { display: grid; gap: 6px; margin-bottom: 14px; }
.check { display: flex; gap: 10px; align-items: flex-start; font-weight: 400; }
.check input { margin-top: 4px; width: 18px; height: 18px; flex: none; }
.form-grid { display: grid; gap: 0 16px; }
@media (min-width: 720px) { .form-grid.two { grid-template-columns: 1fr 1fr; } }

/* Cards, grids */
.grid { display: grid; gap: 16px; }
@media (min-width: 640px) { .grid.c2 { grid-template-columns: 1fr 1fr; } .grid.c3, .grid.c4 { grid-template-columns: 1fr 1fr; } }
@media (min-width: 960px) { .grid.c3 { grid-template-columns: repeat(3, 1fr); } .grid.c4 { grid-template-columns: repeat(4, 1fr); } }
.card { border: 1px solid var(--gray-200); border-radius: var(--radius); padding: 20px; background: var(--white); }
.card h3 { margin-bottom: 6px; }
.card a.stretch { text-decoration: none; }
.dark .card { background: var(--gray-900); border-color: var(--gray-800); }
.steps { counter-reset: s; display: grid; gap: 14px; padding: 0; margin: 0; list-style: none; }
@media (min-width: 720px) { .steps { grid-template-columns: repeat(3, 1fr); } }
.steps li { counter-increment: s; border-top: 2px solid currentColor; padding-top: 14px; }
.steps li::before { content: counter(s, decimal-leading-zero); font-family: var(--font-mono); font-size: .8rem; color: var(--gray-500); display: block; margin-bottom: 6px; }
.steps strong { font-family: var(--font-head); font-size: 1.2rem; display: block; margin-bottom: 4px; }

/* Data labels / badges */
.tag { display: inline-block; font-family: var(--font-mono); font-size: .74rem; letter-spacing: .03em; border: 1px solid var(--gray-300); border-radius: 999px; padding: 2px 9px; color: var(--gray-700); background: var(--white); }
.dark .tag, .reveal .tag, .page-head .tag, .hero .tag { background: transparent; color: var(--gray-300); border-color: var(--gray-700); }
.tag.solid { background: var(--ink); color: var(--white); border-color: var(--ink); }
.dark .tag.solid, .reveal .tag.solid, .page-head .tag.solid, .hero .tag.solid { background: var(--white); color: var(--black); border-color: var(--white); }
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin: 8px 0; }
.notice { border: 1px dashed var(--gray-500); border-radius: var(--radius); padding: 12px 14px; font-size: .92rem; background: var(--gray-50); color: var(--gray-700); }
.dark .notice { background: var(--gray-900); color: var(--gray-300); border-color: var(--gray-700); }
.notice.preview { border-style: solid; border-color: var(--ink); background: var(--white); color: var(--ink); font-family: var(--font-mono); font-size: .8rem; }
.kv { display: grid; grid-template-columns: max-content 1fr; gap: 6px 16px; margin: 0; }
.kv dt { font-family: var(--font-mono); font-size: .78rem; text-transform: uppercase; letter-spacing: .06em; color: var(--gray-600); padding-top: 3px; }
.kv dd { margin: 0; }
.prose { max-width: 68ch; }
.prose h2 { margin-top: 1.4em; }
details.faq { border-top: 1px solid var(--gray-200); padding: 14px 0; }
details.faq summary { cursor: pointer; font-family: var(--font-head); font-weight: 600; font-size: 1.1rem; }
details.faq p { margin: 10px 0 0; }
.blend-card .name { font-family: var(--font-head); font-size: 1.3rem; font-weight: 700; margin: 0 0 4px; }
.status-line { font-family: var(--font-mono); font-size: .8rem; color: var(--gray-600); margin-top: 10px; }

/* Order builder */
.builder-row { display: grid; gap: 10px; border: 1px solid var(--gray-200); border-radius: var(--radius); padding: 14px; margin-bottom: 10px; background: var(--white); }
.builder-row.saved { background: var(--gray-50); }
.builder-row .row-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; flex-wrap: wrap; }
.trait-grid { display: flex; flex-wrap: wrap; gap: 6px; }
.trait-grid label { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--gray-300); border-radius: 999px; padding: 6px 12px; font-size: .9rem; cursor: pointer; user-select: none; background: var(--white); }
.trait-grid input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.trait-grid label.on { background: var(--ink); color: var(--white); border-color: var(--ink); }
.trait-grid label.off { opacity: .4; }
.trait-grid input:focus-visible + span { outline: 2px solid var(--ink); outline-offset: 3px; }
.counter { font-family: var(--font-mono); font-size: .8rem; color: var(--gray-600); }
.error { color: var(--ink); font-weight: 600; font-size: .9rem; }

/* Proof grid */
.proof-grid { display: grid; gap: 20px; }
@media (min-width: 900px) { .proof-grid { grid-template-columns: 1fr 1fr; } }
.proof-item { border: 1px solid var(--gray-200); border-radius: var(--radius); padding: 12px; background: var(--white); }
.proof-grid > *, .grid > * { min-width: 0; }
.label-scale { width: 100%; overflow: hidden; }
.proof-item .edit { display: grid; gap: 8px; margin-top: 10px; }
.proof-item .edit textarea { min-height: 60px; }
.approve-bar { position: sticky; bottom: 0; background: var(--white); border-top: 1px solid var(--gray-200); padding: 12px 0; margin-top: 16px; }

/* Chat */
.chat { border: 1px solid var(--gray-200); border-radius: var(--radius); background: var(--white); display: flex; flex-direction: column; min-height: 360px; }
.chat-log { padding: 14px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.msg { max-width: 88%; padding: 10px 13px; border-radius: 14px; white-space: pre-wrap; }
.msg.ai { background: var(--gray-50); border: 1px solid var(--gray-200); align-self: flex-start; }
.msg.me { background: var(--ink); color: var(--white); align-self: flex-end; }
.chat-form { display: flex; gap: 8px; padding: 10px; border-top: 1px solid var(--gray-200); }
.chat-form input { flex: 1; }
.choice-row { display: flex; flex-wrap: wrap; gap: 8px; }
.seg { display: inline-flex; border: 1px solid var(--ink); border-radius: 999px; overflow: hidden; }
.seg button { border: 0; background: var(--white); color: var(--ink); padding: 9px 16px; font: 600 .95rem var(--font-body); cursor: pointer; }
.seg button[aria-pressed="true"] { background: var(--ink); color: var(--white); }
.fineprint { font-size: .8rem; color: var(--gray-600); }
.reveal { background: var(--black); color: var(--white); border-radius: var(--radius); padding: 24px; }
.reveal .blend { font-family: var(--font-head); font-size: clamp(1.8rem, 8vw, 2.6rem); font-weight: 700; margin: 4px 0 8px; line-height: 1.05; }
.hidden { display: none !important; }
