/* =========================================================
   Opinion — Early-interest launch page
   Brand: Ink & Ember, editorial and warm
   ========================================================= */

:root {
  --navy: #17130f;
  --navy-soft: #241d16;
  --ivory: #f6f1e4;
  --ivory-deep: #ece1c8;
  --gold: #e2572b;
  --gold-dark: #c2451e;
  --blue: #2f5de3;
  --green: #4f7942;
  --amber: #b9862e;
  --white: #ffffff;
  --border: #e4d9be;
  --text-muted: #6b6255;
  --text-on-navy: #d8cfbf;

  --radius-sm: 10px;
  --radius-md: 18px;
  --radius-lg: 24px;
  --shadow-soft: 0 20px 45px -25px rgba(23, 19, 15, 0.25);
  --shadow-card: 0 10px 30px -18px rgba(23, 19, 15, 0.18);
  --container: 1160px;
  --container-narrow: 720px;

  --font-display: "Boska", "Iowan Old Style", serif;
  --font-mono: "JetBrains Mono", "SFMono-Regular", monospace;
  --font-body: "General Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 90px;
}

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--navy);
  background: var(--ivory);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  position: relative;
}

/* Paper-grain overlay — the tactile, editorial layer that keeps flat colour
   fields from feeling like generic SaaS gradients. Pure CSS/SVG, no image. */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 2000;
  pointer-events: none;
  opacity: 0.035;
  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)'/%3E%3C/svg%3E");
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.12;
  margin: 0 0 16px;
  letter-spacing: -0.01em;
}

h1 em, h2 em, h3 em {
  font-style: italic;
  font-weight: 500;
}

p {
  margin: 0 0 16px;
  color: var(--text-muted);
}

.underline-accent {
  position: relative;
  white-space: nowrap;
}

.underline-accent svg {
  position: absolute;
  left: -2%;
  bottom: -0.22em;
  width: 104%;
  height: 0.3em;
  color: var(--gold);
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  max-width: 100%;
  display: block;
}

.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}

.container-narrow {
  max-width: var(--container-narrow);
}

section {
  padding: 96px 0;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gold-dark);
  margin-bottom: 18px;
  padding: 5px 12px 5px 8px;
  border: 1px solid rgba(226,87,43,0.4);
  border-radius: 999px;
  background: rgba(226,87,43,0.08);
}

.eyebrow-light {
  color: var(--gold);
  border-color: rgba(226,87,43,0.5);
  background: rgba(226,87,43,0.1);
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: 12px;
  font-weight: 600;
  font-size: 15px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.18s cubic-bezier(.34,1.56,.64,1), background 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
  white-space: nowrap;
}

.btn .arrow {
  display: inline-block;
  transition: transform 0.2s ease;
}

.btn:hover .arrow {
  transform: translateX(3px);
}

.btn:active {
  transform: scale(0.97);
}

.btn-primary {
  background: var(--gold);
  color: var(--navy);
}

.btn-primary:hover {
  background: var(--gold-dark);
  box-shadow: 0 10px 24px -10px rgba(226, 87, 43, 0.6);
  transform: translateY(-2px);
}

.btn-block {
  width: 100%;
}

.btn-lg {
  padding: 16px 32px;
  font-size: 16px;
}

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(246, 241, 228, 0.85);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 76px;
  flex-wrap: wrap;
  gap: 12px;
  padding-top: 12px;
  padding-bottom: 12px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 9px;
  font-family: var(--font-display);
  font-weight: 700;
  font-style: italic;
  font-size: 22px;
  color: var(--navy);
}

.logo .dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--gold);
  transform: translateY(-2px);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
}

.nav-link {
  font-family: var(--font-mono);
  font-size: 12.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--navy);
}

.nav-link:hover {
  color: var(--gold-dark);
}

/* ---------- Hero ---------- */

.hero {
  padding: 88px 0 80px;
  overflow: hidden;
}

.hero .container {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 56px;
  align-items: center;
}

.hero-copy h1 {
  font-size: clamp(34px, 5vw, 52px);
  margin-bottom: 20px;
}

.hero-copy .lede {
  font-size: 18px;
  color: var(--text-muted);
  max-width: 520px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin: 20px 0 28px;
}

.trust-line {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  color: var(--text-muted);
}

.trust-line svg {
  flex-shrink: 0;
  color: var(--green);
}

/* ---------- Photography and illustrated beliefs ---------- */

.hero-visual {
  position: relative;
  align-self: stretch;
  min-width: 0;
  margin: 8px 0 24px;
  min-height: 520px;
}

.hero-photo {
  width: 100%;
  height: 100%;
  position: absolute;
  inset: 0;
  object-fit: cover;
  object-position: 52% center;
  border-radius: 120px 12px 100px 12px;
}

.hero-sticker {
  position: absolute;
  top: 24px;
  left: 24px;
  display: flex;
  align-items: center;
  gap: 6px;
  background: var(--ivory);
  color: var(--navy);
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 10px 14px;
  border-radius: 999px;
}

.hero-sticker svg { color: var(--gold-dark); }

.hero-card {
  position: absolute;
  bottom: -24px;
  left: 24px;
  right: 24px;
  padding: 22px 24px;
  background: var(--ivory);
  border: 1px solid var(--border);
  border-radius: 4px 4px 32px 4px;
}

.hero-card-line {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 26px;
  color: var(--navy);
  margin: 0;
  text-align: center;
}

.belief-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px 88px;
}

.belief {
  padding: 0 28px;
  background: transparent;
}

.belief + .belief { border-left: 1px solid var(--border); }
.belief:first-child { padding-left: 0; }
.belief:last-child { padding-right: 0; }
.belief-alt { border-top: 0; border-bottom: 0; }
.belief .container { padding: 0; text-align: left; }
.belief h2 { font-size: clamp(26px, 2.5vw, 32px); margin-bottom: 20px; }
.belief p { font-size: 16px; }

.belief-art,
.join-art {
  background-image: url("assets/editorial-illustrations.png");
  background-size: 300% 100%;
  background-repeat: no-repeat;
  aspect-ratio: 1;
  mix-blend-mode: multiply;
}

.belief-art { width: 100%; margin-bottom: 28px; }
.art-think { background-position: left center; }
.art-connect { background-position: center; }
.art-future { background-position: right center; }
.join-art { width: 100%; max-width: 420px; margin-top: 36px; }

/* ---------- Closing statement ---------- */

.statement {
  background: var(--navy);
  color: var(--ivory);
  text-align: center;
  position: relative;
  overflow: hidden;
}

.statement .container {
  max-width: var(--container-narrow);
  position: relative;
}

.statement h2 {
  color: var(--white);
  font-size: clamp(28px, 4vw, 40px);
}

.statement-lede {
  color: var(--text-on-navy);
  font-size: 17px;
  max-width: 520px;
  margin: 0 auto 28px;
}

.statement blockquote {
  margin: 0 auto 32px;
  max-width: 560px;
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 500;
  font-size: clamp(22px, 3.4vw, 30px);
  line-height: 1.3;
  color: var(--white);
}

.statement blockquote em {
  color: var(--gold);
  font-style: italic;
}

.statement-blob {
  position: absolute;
  width: 380px;
  height: 380px;
  border-radius: 45% 55% 60% 40% / 50% 45% 55% 50%;
  background: var(--gold);
  opacity: 0.08;
  top: -140px;
  right: -120px;
}

.statement-blob.b2 {
  background: var(--blue);
  top: auto;
  right: auto;
  bottom: -160px;
  left: -140px;
  width: 320px;
  height: 320px;
}

/* ---------- Signup ---------- */

.join {
  background: var(--white);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.join-wrap {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 48px;
  align-items: flex-start;
}

.join-side p {
  font-size: 15.5px;
}

.join-points {
  list-style: none;
  padding: 0;
  margin: 24px 0 0;
  display: grid;
  gap: 14px;
}

.join-points li {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  color: var(--navy);
  font-size: 14.5px;
}

.join-points li svg {
  color: var(--gold-dark);
  flex-shrink: 0;
  margin-top: 3px;
}

.join-form {
  background: var(--ivory);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 36px;
  color: var(--navy);
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 16px;
}

.field {
  margin-bottom: 18px;
}

.field label {
  display: block;
  font-size: 13.5px;
  font-weight: 600;
  margin-bottom: 6px;
  color: var(--navy);
}

.req {
  color: var(--gold-dark);
}

.optional {
  font-weight: 400;
  color: var(--text-muted);
}

.field input[type="text"],
.field input[type="email"],
.field input[type="tel"] {
  width: 100%;
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--white);
  font-family: inherit;
  font-size: 14.5px;
  color: var(--navy);
}

.field input:focus {
  outline: 2px solid var(--blue);
  outline-offset: 1px;
}

.field-help {
  font-size: 12.5px;
  color: var(--text-muted);
  margin: 6px 0 0;
}

.field-help-tight {
  margin-top: -8px;
  margin-bottom: 14px;
}

.checkbox-group {
  display: grid;
  gap: 10px;
}

.checkbox-option {
  position: relative;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 14px;
  color: var(--navy);
  cursor: pointer;
  font-weight: 500;
}

.checkbox-option input {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  opacity: 0;
  cursor: pointer;
}

.checkbox-box {
  display: inline-block;
  flex-shrink: 0;
  width: 19px;
  height: 19px;
  margin-top: 1px;
  border: 1.5px solid var(--border);
  border-radius: 6px;
  background: var(--white);
  position: relative;
  transition: all 0.15s ease;
}

.checkbox-option input:checked + .checkbox-box {
  background: var(--navy);
  border-color: var(--navy);
}

.checkbox-option input:checked + .checkbox-box::after {
  content: "";
  position: absolute;
  left: 5px;
  top: 1.5px;
  width: 6px;
  height: 10px;
  border: solid var(--gold);
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.checkbox-option input:focus-visible + .checkbox-box {
  outline: 2px solid var(--blue);
  outline-offset: 2px;
}

.notice {
  font-size: 12.5px;
  color: var(--text-muted);
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 14px 16px;
  margin-bottom: 20px;
}

.notice a {
  color: var(--blue);
  text-decoration: underline;
}

.policy-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 14px;
  font-size: 13px;
  font-weight: 600;
  color: var(--navy);
  text-align: center;
  width: 100%;
  justify-content: center;
}

.policy-link:hover {
  color: var(--gold-dark);
}

mark.todo {
  background: rgba(185,134,46,0.25);
  color: var(--navy);
  padding: 1px 5px;
  border-radius: 4px;
  font-weight: 600;
  font-family: var(--font-mono);
  font-size: 0.92em;
}

.form-success,
.form-error {
  display: none;
  text-align: center;
  padding: 24px 0;
}

.form-success.show,
.form-error.show {
  display: block;
}

.icon-circle {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: rgba(79,121,66,0.15);
  color: #35502a;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 18px;
}

.icon-circle-error {
  background: rgba(226,87,43,0.15);
  color: var(--gold-dark);
}

.join-form.submitted form,
.join-form.errored form {
  display: none;
}

/* ---------- Footer ---------- */

.site-footer {
  background: var(--navy);
  color: var(--text-on-navy);
  padding: 56px 0;
  text-align: center;
}

.footer-logo {
  justify-content: center;
  color: var(--white);
}

.footer-tagline {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 16px;
  color: var(--text-on-navy);
  margin: 10px 0 20px;
}

.footer-links {
  display: flex;
  justify-content: center;
  gap: 14px;
  font-size: 14px;
  margin-bottom: 20px;
}

.footer-links a:hover {
  color: var(--gold);
}

.footer-sep {
  color: #55503f;
}

.footer-bottom {
  font-size: 13px;
  color: #9c9280;
}

/* ---------- Draft banner (privacy.html) ---------- */

.draft-banner {
  background: rgba(185,134,46,0.16);
  border-bottom: 1px solid rgba(185,134,46,0.4);
  color: var(--navy);
  text-align: center;
  padding: 12px 20px;
  font-size: 13.5px;
  font-weight: 600;
}

/* ---------- Policy / prose page ---------- */

.policy {
  padding: 64px 0 96px;
}

.policy .container {
  max-width: var(--container-narrow);
}

.policy .caption {
  font-family: var(--font-mono);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.policy h1 {
  font-size: clamp(30px, 4.4vw, 42px);
  margin-bottom: 8px;
}

.policy h2 {
  font-size: 22px;
  margin-top: 44px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
}

.policy h2:first-of-type {
  margin-top: 32px;
  padding-top: 0;
  border-top: none;
}

.policy p {
  font-size: 15.5px;
  color: var(--navy);
}

.policy a {
  color: var(--blue);
  text-decoration: underline;
}

/* ---------- Confirmation page ---------- */

.confirm {
  min-height: 60vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 96px 0;
}

.confirm .container {
  max-width: 560px;
}

.confirm .icon-circle {
  width: 64px;
  height: 64px;
}

/* ---------- Reveal animation ---------- */

.reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal.in-view {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  .reveal { transition: none; }
}

/* ---------- Responsive ---------- */

@media (max-width: 980px) {
  .hero .container,
  .join-wrap {
    grid-template-columns: 1fr;
  }

  .hero-visual { min-height: 460px; margin-top: 12px; }
  .hero-photo { object-position: center; }

  .form-row {
    grid-template-columns: 1fr;
  }

  .belief-grid { grid-template-columns: 1fr; gap: 48px; }
  .belief, .belief:first-child, .belief:last-child { padding: 0; }
  .belief + .belief { border-left: 0; border-top: 1px solid var(--border); padding-top: 40px; }
  .belief .container { max-width: 620px; }
  .belief-art { width: 260px; max-width: 100%; margin: 0 auto 24px; }
  .join-art { max-width: 320px; margin: 28px auto 0; }
}

@media (max-width: 480px) {
  /* Keep the sticky header to a single line at narrow widths — it already
     duplicates in the footer, so hiding it here avoids the header wrapping
     and overlapping whatever scrolls beneath it. */
  .nav-link { display: none; }
}

@media (max-width: 640px) {
  section { padding: 64px 0; }

  .hero-actions .btn { width: 100%; }

  .join-form { padding: 24px; }

  .hero-visual { margin: 12px 0 24px; min-height: 340px; }
  .hero-photo { border-radius: 72px 8px 64px 8px; }
  .hero-card { padding: 18px; left: 16px; right: 16px; }
  .hero-sticker { font-size: 10px; padding: 8px 12px; }
  .hero-sticker { top: 18px; left: 18px; }
  .belief-grid { padding-bottom: 56px; }
}

/* ---------- Editorial visual treatment ---------- */
.site-header { border-bottom-color: transparent; }
.logo { font-size: 38px; font-style: normal; letter-spacing: -0.05em; }
.logo .dot { display: none; }
.btn { border-radius: 6px; }
.btn-primary { background: var(--gold-dark); color: var(--white); }
.btn-primary:hover { background: #a63819; }
.nav-link { font-family: var(--font-body); text-transform: none; letter-spacing: 0; font-size: 14px; }
.hero { padding: 60px 0 88px; }
.hero .container { grid-template-columns: 1fr 1fr; gap: 48px; }
.hero-copy h1 { font-size: clamp(40px, 4.5vw, 62px); line-height: 1.04; letter-spacing: -0.035em; }
.hero-copy .lede { font-size: 16px; line-height: 1.65; }
.hero-copy .lede:first-of-type { font-size: 18px; color: var(--navy); }
.eyebrow { border: 0; border-radius: 0; padding: 0; background: transparent; }
.statement { padding: 80px 0; }
.statement h2 { font-size: clamp(36px, 4vw, 50px); }
.statement blockquote { font-size: clamp(28px, 3.4vw, 40px); }
.statement-blob { opacity: 0.7; width: 240px; height: 240px; top: -80px; right: -80px; border-radius: 50%; }
.statement-blob.b2 { opacity: 0.35; }
.join { background: var(--ivory); padding: 88px 0; }
.join-side h2 { font-size: clamp(36px, 4vw, 50px); }
.join-form { background: rgba(255,255,255,0.45); border-radius: 8px; }
.field input[type="text"], .field input[type="email"], .field input[type="tel"] { border-radius: 5px; }
a:focus-visible, button:focus-visible { outline: 3px solid var(--blue); outline-offset: 4px; }

@media (max-width: 980px) {
  .hero .container { grid-template-columns: 1fr; gap: 28px; }
  .hero-copy .lede { max-width: 680px; }
  .hero { padding-top: 40px; }
}
@media (max-width: 640px) {
  .container { padding-left: 20px; padding-right: 20px; }
  .hero { padding: 32px 0 56px; }
  .hero-copy h1 { font-size: clamp(36px, 9vw, 48px); }
  .site-header .container { gap: 8px; }
  .site-header .logo { font-size: 32px; }
  .header-actions { gap: 12px; }
  .header-actions .btn { padding: 12px 14px; font-size: 13px; }
  .join { padding: 56px 0; }
  .join-form { padding: 24px 20px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .btn, .btn .arrow { transition: none; }
}
