/* ============================================================
   QUIRE — pre-press / document-rendering aesthetic
   Paper, ink, registration marks, monospace spec sheets.
   ============================================================ */

:root {
  --paper:      #EDE7D8;   /* warm uncoated stock */
  --paper-2:    #E4DCC8;   /* deeper paper for panels */
  --ink:        #16140E;   /* near-black ink */
  --ink-soft:   #4A4538;   /* muted ink for body */
  --vermilion:  #E23B17;   /* registration red accent */
  --press-blue: #1E3A5F;   /* secondary cool ink */
  --hair:       #16140E1a; /* hairline rules */
  --maxw: 1240px;
}

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

html { scroll-behavior: smooth; }

body {
  background-color: var(--paper);
  color: var(--ink);
  font-family: "IBM Plex Mono", ui-monospace, monospace;
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  position: relative;
}

/* paper grain overlay */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 9999;
  opacity: .5;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.32'/%3E%3C/svg%3E");
}

/* faint baseline grid */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background-image: linear-gradient(var(--hair) 1px, transparent 1px);
  background-size: 100% 32px;
  opacity: .35;
}

/* ---------- crop-mark frame ---------- */
.frame { position: fixed; inset: 18px; pointer-events: none; z-index: 50; }
.crop { position: absolute; width: 22px; height: 22px; }
.crop::before, .crop::after { content: ""; position: absolute; background: var(--ink); }
.crop::before { width: 1px; height: 22px; }
.crop::after  { width: 22px; height: 1px; }
.crop.tl { top: 0; left: 0; } .crop.tl::before { left: 0; top: 0; } .crop.tl::after { top: 0; left: 0; }
.crop.tr { top: 0; right: 0; } .crop.tr::before { right: 0; top: 0; } .crop.tr::after { top: 0; right: 0; }
.crop.bl { bottom: 0; left: 0; } .crop.bl::before { left: 0; bottom: 0; } .crop.bl::after { bottom: 0; left: 0; }
.crop.br { bottom: 0; right: 0; } .crop.br::before { right: 0; bottom: 0; } .crop.br::after { bottom: 0; right: 0; }

/* ---------- registration target ---------- */
.reg {
  display: inline-block;
  width: 14px; height: 14px;
  border-radius: 50%;
  border: 1px solid var(--vermilion);
  position: relative;
  flex: none;
}
.reg::before, .reg::after {
  content: ""; position: absolute; background: var(--vermilion);
}
.reg::before { left: 50%; top: -4px; bottom: -4px; width: 1px; transform: translateX(-50%); }
.reg::after  { top: 50%; left: -4px; right: -4px; height: 1px; transform: translateY(-50%); }
.reg.big { width: 38px; height: 38px; margin-bottom: 28px; }
.reg.big::before { top: -10px; bottom: -10px; }
.reg.big::after { left: -10px; right: -10px; }

/* ---------- layout shell ---------- */
main { position: relative; z-index: 1; }
section {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 96px 40px;
  border-bottom: 1px solid var(--hair);
}

/* ---------- topbar ---------- */
.topbar {
  position: relative; z-index: 2;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 34px 40px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.brand {
  display: inline-flex; align-items: center; gap: 12px;
  font-weight: 600; letter-spacing: .26em; font-size: 15px;
  text-decoration: none; color: var(--ink);
}
.nav { display: flex; gap: 30px; align-items: center; }
.nav a {
  text-decoration: none; color: var(--ink-soft);
  font-size: 12.5px; letter-spacing: .12em; text-transform: uppercase;
  transition: color .25s ease; position: relative;
}
.nav a:hover { color: var(--ink); }
.nav a:not(.nav-cta)::after {
  content: ""; position: absolute; left: 0; bottom: -5px; height: 1px; width: 0;
  background: var(--vermilion); transition: width .3s ease;
}
.nav a:not(.nav-cta):hover::after { width: 100%; }
.nav-cta {
  border: 1px solid var(--ink); padding: 9px 16px;
  color: var(--ink) !important; transition: all .25s ease;
}
.nav-cta:hover { background: var(--ink); color: var(--paper) !important; }

.lang-toggle {
  font-family: "IBM Plex Mono", monospace;
  font-size: 12px; letter-spacing: .12em; font-weight: 600;
  background: transparent; color: var(--vermilion);
  border: 1px solid var(--vermilion); border-radius: 50%;
  width: 34px; height: 34px; cursor: pointer; flex: none;
  transition: all .25s ease;
}
.lang-toggle:hover { background: var(--vermilion); color: var(--paper); }

/* ---------- typography helpers ---------- */
.kicker {
  font-size: 12px; letter-spacing: .28em; color: var(--vermilion);
  font-weight: 500;
}
em { font-style: italic; }

h1, h2, h3, h4 { font-family: "Fraunces", Georgia, serif; font-weight: 400; }

/* ---------- hero ---------- */
.hero { padding-top: 64px; border-bottom: 1px solid var(--ink); }
.hero h1 {
  font-size: clamp(3.4rem, 11vw, 8.6rem);
  line-height: .92;
  letter-spacing: -.02em;
  margin: 26px 0 0;
  font-weight: 300;
}
.hero h1 em {
  font-weight: 500; color: var(--vermilion);
  font-optical-sizing: auto;
}
.lede {
  font-size: clamp(1rem, 1.6vw, 1.18rem);
  max-width: 56ch; margin-top: 34px; color: var(--ink-soft);
  line-height: 1.65;
}
.hero-cta { display: flex; gap: 16px; margin-top: 40px; flex-wrap: wrap; }

.btn {
  font-family: "IBM Plex Mono", monospace;
  font-size: 13px; letter-spacing: .08em; text-transform: uppercase;
  padding: 15px 26px; text-decoration: none; cursor: pointer;
  border: 1px solid var(--ink); transition: all .25s ease;
  display: inline-block;
}
.btn-primary { background: var(--ink); color: var(--paper); }
.btn-primary:hover { background: var(--vermilion); border-color: var(--vermilion); transform: translateY(-2px); }
.btn-ghost { background: transparent; color: var(--ink); }
.btn-ghost:hover { background: var(--ink); color: var(--paper); }

.spec-strip {
  list-style: none; display: grid; grid-template-columns: repeat(4, 1fr);
  margin-top: 64px; border-top: 1px solid var(--ink);
}
.spec-strip li {
  padding: 18px 18px 18px 0; display: flex; flex-direction: column; gap: 8px;
  border-right: 1px solid var(--hair);
}
.spec-strip li:last-child { border-right: 0; }
.spec-k { font-size: 11px; letter-spacing: .18em; color: var(--ink-soft); }
.spec-v { font-family: "Fraunces", serif; font-size: 1.7rem; line-height: 1; }

/* ---------- section heads ---------- */
.sec-head { margin-bottom: 8px; }
.sec-no {
  display: inline-block; font-size: 12px; letter-spacing: .2em;
  color: var(--vermilion); margin-bottom: 18px;
}
.sec-head h2 {
  font-size: clamp(2.2rem, 5.4vw, 4.2rem); line-height: .98;
  letter-spacing: -.015em; font-weight: 300;
}

/* ---------- engine ---------- */
.engine { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: 64px; align-items: start; }
.sec-copy { color: var(--ink-soft); font-size: .98rem; line-height: 1.7; max-width: 52ch; }
.bars { margin-top: 4px; }
.bar-row { margin-bottom: 26px; }
.bar-meta { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 8px; font-size: 12.5px; }
.bar-meta .hl { color: var(--vermilion); font-weight: 600; }
.bar-note { color: var(--ink-soft); font-size: 11px; letter-spacing: .04em; }
.bar-track { height: 38px; border: 1px solid var(--ink); position: relative; background: repeating-linear-gradient(45deg, transparent, transparent 7px, var(--hair) 7px, var(--hair) 8px); }
.bar {
  height: 100%; width: 0; transition: width 1.1s cubic-bezier(.2,.7,.2,1);
  display: flex; align-items: center; justify-content: flex-end;
  padding: 0 12px; position: relative; overflow: visible;
}
.fill-bad  { background: var(--ink); }
.fill-mid  { background: var(--press-blue); }
.fill-good { background: var(--vermilion); }
.bar-val { font-size: 12px; color: var(--paper); letter-spacing: .04em; white-space: nowrap; font-weight: 500; }
.bar-val.out { color: var(--ink); position: absolute; right: -86px; }
.bars-foot { font-size: 11px; color: var(--ink-soft); margin-top: 20px; line-height: 1.55; max-width: 50ch; }

/* ---------- why us + comparison ---------- */
.why { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: 64px; align-items: start; }
.compare { margin-top: 4px; }
.compare-head, .compare-row {
  display: grid; grid-template-columns: 1fr 1fr 1.15fr; gap: 16px;
  padding: 15px 0; align-items: baseline; border-bottom: 1px solid var(--hair);
}
.compare-head {
  font-size: 11px; letter-spacing: .16em; text-transform: uppercase;
  color: var(--ink-soft); border-bottom: 1px solid var(--ink); padding-top: 4px;
}
.compare-head .c-us { color: var(--vermilion); font-weight: 600; }
.c-dim { font-size: 12px; letter-spacing: .04em; color: var(--ink-soft); }
.compare-row .c-them { font-size: 13px; color: var(--ink-soft); }
.compare-row .c-us { font-size: 13.5px; font-weight: 500; color: var(--vermilion); }

/* ---------- value props ---------- */
.props { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; padding-top: 0; padding-bottom: 0; }
.prop {
  padding: 56px 34px 56px 0; border-right: 1px solid var(--hair);
}
.prop:last-child { border-right: 0; padding-right: 0; }
.props .prop:not(:first-child) { padding-left: 34px; }
.prop-no {
  font-family: "Fraunces", serif; font-size: 2.4rem; color: var(--vermilion);
  display: block; margin-bottom: 16px; line-height: 1;
}
.prop h3 { font-size: 1.5rem; margin-bottom: 14px; font-weight: 400; }
.prop p { color: var(--ink-soft); font-size: .92rem; line-height: 1.65; }

/* ---------- pipeline ---------- */
.flow .steps { list-style: none; display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; margin-top: 48px; background: var(--hair); border: 1px solid var(--hair); }
.flow .steps.steps-3 { grid-template-columns: repeat(3, 1fr); }
.flow .steps li { background: var(--paper); padding: 30px 26px 38px; position: relative; }
.step-n { font-size: 12px; letter-spacing: .2em; color: var(--vermilion); }
.flow h4 { font-family: "Fraunces", serif; font-size: 1.32rem; font-weight: 500; margin: 18px 0 12px; }
.flow .steps p { color: var(--ink-soft); font-size: .86rem; line-height: 1.6; }

/* ---------- pricing ---------- */
.pricing { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: center; }
.price-card { border: 1px solid var(--ink); padding: 44px; background: var(--paper-2); }
.price-from { font-size: 12px; letter-spacing: .2em; color: var(--ink-soft); }
.price-big { font-family: "Fraunces", serif; font-size: clamp(3rem, 7vw, 4.6rem); font-weight: 300; line-height: 1; margin: 6px 0 22px; }
.price-big span { font-family: "IBM Plex Mono", monospace; font-size: 1rem; color: var(--ink-soft); letter-spacing: .04em; }
.price-note { color: var(--ink-soft); font-size: .9rem; line-height: 1.65; margin-bottom: 30px; }

/* ---------- access / waitlist ---------- */
.access { text-align: left; }
.access h2 { font-size: clamp(2.6rem, 7vw, 5rem); font-weight: 300; letter-spacing: -.02em; line-height: .96; }
.access-lede { color: var(--ink-soft); max-width: 54ch; margin-top: 22px; font-size: 1rem; line-height: 1.65; }
.wl-form { margin-top: 44px; display: grid; grid-template-columns: 1.4fr 1fr auto; gap: 18px; align-items: end; max-width: 760px; }
.field { display: flex; flex-direction: column; gap: 9px; }
.field label { font-size: 11px; letter-spacing: .18em; color: var(--ink-soft); }
.field input {
  background: transparent; border: 0; border-bottom: 1px solid var(--ink);
  padding: 11px 2px; font-family: "IBM Plex Mono", monospace; font-size: 1rem;
  color: var(--ink); transition: border-color .25s ease;
}
.field input::placeholder { color: #9a917c; }
.field input:focus { outline: none; border-bottom-color: var(--vermilion); }
.wl-submit { white-space: nowrap; }
.wl-msg { grid-column: 1 / -1; font-size: 13px; min-height: 1.2em; letter-spacing: .03em; }
.wl-msg.ok { color: var(--press-blue); }
.wl-msg.err { color: var(--vermilion); }

/* ---------- footer ---------- */
.footer {
  max-width: var(--maxw); margin: 0 auto; padding: 30px 40px 40px;
  display: flex; justify-content: space-between; align-items: center;
  font-size: 11px; letter-spacing: .16em; color: var(--ink-soft);
  position: relative; z-index: 1; flex-wrap: wrap; gap: 12px;
}
.f-brand { color: var(--ink); font-weight: 600; letter-spacing: .26em; }

/* ---------- reveal animation ---------- */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity .7s ease, transform .7s cubic-bezier(.2,.7,.2,1); }
.reveal.in { opacity: 1; transform: none; }
.hero .reveal.d1 { transition-delay: .08s; }
.hero .reveal.d2 { transition-delay: .16s; }
.hero .reveal.d3 { transition-delay: .24s; }
.hero .reveal.d4 { transition-delay: .32s; }

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .bar { transition: none; }
  html { scroll-behavior: auto; }
}

/* ---------- responsive ---------- */
@media (max-width: 880px) {
  section { padding: 64px 26px; }
  .topbar { padding: 26px 26px 14px; }
  .nav { gap: 16px; }
  .nav a:not(.nav-cta) { display: none; }
  .engine, .why, .pricing { grid-template-columns: 1fr; gap: 38px; }
  .compare-head, .compare-row { grid-template-columns: 1fr 1fr; gap: 6px 14px; }
  .compare-head span:first-child, .c-dim { grid-column: 1 / -1; margin-top: 6px; }
  .props { grid-template-columns: 1fr; }
  .prop, .props .prop:not(:first-child) { padding: 32px 0; border-right: 0; border-bottom: 1px solid var(--hair); }
  .prop:last-child { border-bottom: 0; }
  .flow .steps { grid-template-columns: 1fr 1fr; }
  .spec-strip { grid-template-columns: 1fr 1fr; }
  .spec-strip li:nth-child(2) { border-right: 0; }
  .wl-form { grid-template-columns: 1fr; }
  .bar-val.out { right: 12px; color: var(--paper); }
  .fill-good { background: var(--vermilion); }
}
@media (max-width: 480px) {
  .flow .steps { grid-template-columns: 1fr; }
  .frame { inset: 10px; }
}
