/* Forme design system — calm, confident, mature Gen-Z */
:root {
  --paper: #f3f1ec;
  --bg: #f3f1ec;
  --bg-2: #ebe8e1;
  --bg-3: #ffffff;
  --card: #ffffff;
  --ink: #0f0f12;
  --text: #0f0f12;
  --text-2: #46433d;
  --muted: #6b675e;
  --panel: rgba(15, 15, 18, 0.025);
  --panel-2: rgba(15, 15, 18, 0.05);
  --line: rgba(15, 15, 18, 0.09);
  --line-2: rgba(15, 15, 18, 0.16);
  --edge: 1px solid var(--line-2);
  --blue: #2f43ff;
  --blue-2: #5d6dff;
  --blue-soft: #e9ebff;
  --lime: #d7ff4f;          /* used sparingly as a signal colour */
  --lime-2: #c2ec2c;
  --pink: #ff6b9a;
  --sun: #ffcf4a;
  --orange: #ff7a45;
  --mint: #0b8253;
  --violet: #6f4dff;
  --coral: #e5482f;
  --sky: #2f7bff;
  --danger: #d6331f;
  --ok: #12a46a;
  --accent-ink: #2f43ff;
  --radius: 20px;
  --radius-sm: 12px;
  --hard: 0 1px 2px rgba(15, 15, 18, .04), 0 8px 24px -12px rgba(15, 15, 18, .14);
  --hard-lg: 0 2px 4px rgba(15, 15, 18, .04), 0 24px 60px -24px rgba(15, 15, 18, .28);
  --shadow: var(--hard);
  --font: 'DM Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --display: 'Bricolage Grotesque', 'DM Sans', system-ui, sans-serif;
  --serif: var(--display);
  --mono: 'Space Mono', ui-monospace, Consolas, monospace;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --bounce: cubic-bezier(0.22, 1, 0.36, 1);
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; overflow-x: clip; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--text);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}
h1, h2, h3, h4 { font-family: var(--display); letter-spacing: -0.035em; }
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; border: 0; background: none; }
::selection { background: var(--blue); color: #fff; }
:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; border-radius: 8px; }
code { font-family: var(--mono); }

.mono { font-family: var(--mono); }
.muted { color: var(--muted); }
/* Accent words */
.serif { font-family: var(--display); font-style: normal; font-weight: 800; }
.serif.grad, .grad { color: var(--blue); -webkit-text-fill-color: var(--blue); }
.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--mono); font-size: 11.5px; font-weight: 400; letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-2);
}
.eyebrow .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--blue); box-shadow: 0 0 0 4px var(--blue-soft); }

/* Buttons */
.btn {
  --b: var(--ink);
  position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  height: 48px; padding: 0 22px; border-radius: 999px; border: 1px solid transparent;
  background: var(--b); color: #fff; font-family: var(--font); font-weight: 700; font-size: 15px; letter-spacing: -0.01em;
  transition: transform .25s var(--ease), background .2s, box-shadow .25s var(--ease), color .2s;
  white-space: nowrap; box-shadow: 0 8px 20px -10px rgba(15, 15, 18, .45);
}
.btn:hover { transform: translateY(-1px); background: #24242a; box-shadow: 0 14px 28px -12px rgba(15, 15, 18, .5); }
.btn:active { transform: translateY(0) scale(.98); }
.btn.ghost { background: rgba(255, 255, 255, .7); color: var(--ink); border-color: var(--line-2); box-shadow: none; backdrop-filter: blur(8px); }
.btn.ghost:hover { background: #fff; border-color: rgba(15, 15, 18, .3); }
.btn.blue, .btn.pink { --b: var(--blue); }
.btn.blue:hover, .btn.pink:hover { background: #2234e6; }
.btn.small { height: 38px; padding: 0 16px; font-size: 14px; }
.btn.danger { background: #fff; color: var(--danger); border-color: rgba(214, 51, 31, .3); box-shadow: none; }
.btn.danger:hover { background: var(--danger); color: #fff; }
.btn[disabled] { opacity: 0.5; pointer-events: none; }
.btn .arrow { transition: transform .3s var(--ease); display: inline-block; }
.btn:hover .arrow { transform: translateX(3px); }

/* Card (the .glass class name is used across pages) */
.glass {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--hard);
}

/* Inputs */
.field { display: grid; gap: 7px; }
.field > label, .label { font-size: 13px; color: var(--text-2); font-weight: 600; }
.input, .select, .textarea {
  width: 100%; height: 46px; padding: 0 14px; border-radius: 12px;
  background: #fff; border: 1px solid var(--line-2); color: var(--ink);
  transition: border-color .2s, box-shadow .2s;
}
.textarea { height: auto; min-height: 84px; padding: 12px 14px; resize: vertical; }
.input:focus, .select:focus, .textarea:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 4px var(--blue-soft); }
.select { appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%); background-position: calc(100% - 18px) 20px, calc(100% - 13px) 20px; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 34px; }
.select option { background: #fff; color: var(--ink); }

/* Segmented control */
.seg { display: inline-flex; padding: 4px; gap: 2px; border-radius: 999px; background: var(--bg-2); border: 1px solid var(--line); flex-wrap: wrap; }
.seg button { height: 34px; padding: 0 14px; border-radius: 999px; font-size: 14px; font-weight: 600; color: var(--text-2); transition: background .2s, color .2s, box-shadow .2s; }
.seg button:hover { color: var(--ink); }
.seg button.on { background: #fff; color: var(--ink); box-shadow: 0 1px 2px rgba(15, 15, 18, .08), 0 2px 8px -2px rgba(15, 15, 18, .12); }

/* Pills */
.pill { display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 10px; border-radius: 999px; font-size: 12px; font-weight: 600; background: var(--bg-2); border: 1px solid var(--line); color: var(--text-2); }
.pill.lime { background: var(--blue-soft); border-color: rgba(47, 67, 255, .2); color: var(--blue); }
.pill.mint { background: #e3f6ec; border-color: rgba(18, 164, 106, .2); color: #0b7a4d; }
.pill.coral { background: #fde8e3; border-color: rgba(229, 72, 47, .2); color: #b23a24; }
.pill.violet { background: #eee9ff; border-color: rgba(111, 77, 255, .2); color: #5a3be0; }
.pill.pink { background: #ffe9f0; border-color: rgba(255, 107, 154, .25); color: #c23668; }

/* Logo */
.logo { display: inline-flex; align-items: center; gap: 10px; font-family: var(--display); font-weight: 800; font-size: 21px; letter-spacing: -0.045em; color: var(--ink); }
.logo-mark { width: 32px; height: 32px; border-radius: 10px; display: grid; place-items: center; background: var(--ink); font-size: 17px; font-weight: 800; position: relative; overflow: hidden; transition: transform .4s var(--ease); }
.logo-mark::after { content: ''; position: absolute; right: 5px; bottom: 5px; width: 6px; height: 6px; border-radius: 50%; background: var(--lime); }
.logo:hover .logo-mark { transform: rotate(-8deg); }
.logo-mark span { color: #fff; font-family: var(--display); }

/* Toast */
.toast-wrap { position: fixed; z-index: 1000; left: 50%; bottom: 24px; transform: translateX(-50%); display: grid; gap: 8px; pointer-events: none; }
.toast { pointer-events: auto; padding: 12px 18px; border-radius: 14px; background: var(--ink); color: #fff; font-weight: 600; font-size: 14px; box-shadow: var(--hard-lg); animation: toast-in .45s var(--ease) both; }
.toast.err { background: var(--danger); }
@keyframes toast-in { from { opacity: 0; transform: translateY(14px) scale(.97); } }

/* Reveal on scroll */
[data-reveal] { opacity: 0; transform: translateY(24px); filter: blur(6px); transition: opacity .9s var(--ease), transform .9s var(--ease), filter .9s var(--ease); transition-delay: var(--d, 0s); }
[data-reveal].in { opacity: 1; transform: none; filter: none; }

/* Garment art */
.art { position: relative; display: grid; place-items: center; border-radius: 18px; overflow: hidden; border: 1px solid var(--line); background: radial-gradient(120% 90% at 30% 15%, color-mix(in srgb, var(--c) 28%, #fff), color-mix(in srgb, var(--c) 10%, #f6f4ef) 70%); }
.art svg { width: 70%; height: auto; filter: drop-shadow(0 14px 18px rgba(15, 15, 18, .18)); }

/* Maker credit */
.maverick { font-weight: 700; color: var(--ink); letter-spacing: -.01em; }
.made-by { font-size: 12px; color: var(--muted); }
.made-by .maverick { color: inherit; }

/* Code blocks stay dark */
pre.snippet, .code pre, pre.raw, .json pre, .secret-box { background: #121216 !important; color: #ecebe6 !important; border: 1px solid #222 !important; }

* { scrollbar-width: thin; scrollbar-color: rgba(15, 15, 18, .25) transparent; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; scroll-behavior: auto !important; }
  [data-reveal] { opacity: 1; transform: none; filter: none; }
}
