/* ====================================================
  CONVOINVOICE — Design System
   Editorial · Warm Cream · Terracotta · Ink
==================================================== */

@import url('https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght,SOFT@9..144,300..900,0..100&family=Manrope:wght@300..800&family=JetBrains+Mono:wght@400;500&display=swap');

:root {
  --cream: #F4EFE3;
  --cream-2: #ECE5D3;
  --cream-3: #E2D9C2;
  --ink: #1A1814;
  --ink-soft: #3A352C;
  --ink-mute: #6B6356;
  --terra: #C8553D;
  --terra-dark: #A8422E;
  --gold: #C99A4A;
  --sage: #6B7F5C;
  --line: rgba(26, 24, 20, 0.12);
  --line-soft: rgba(26, 24, 20, 0.07);
  --shadow-sm: 0 1px 2px rgba(26, 24, 20, 0.06);
  --shadow-md: 0 6px 24px rgba(26, 24, 20, 0.08);
  --shadow-lg: 0 24px 60px rgba(26, 24, 20, 0.12);
  --radius: 14px;
  --radius-sm: 8px;

  --font-display: 'Fraunces', 'Times New Roman', serif;
  --font-body: 'Manrope', system-ui, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;

  --container: 1200px;
}

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

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  font-family: var(--font-body);
  background: var(--cream);
  color: var(--ink);
  line-height: 1.6;
  font-size: 16px;
  font-weight: 400;
  overflow-x: hidden;
  background-image:
    radial-gradient(circle at 100% 0%, rgba(200, 85, 61, 0.05) 0%, transparent 40%),
    radial-gradient(circle at 0% 100%, rgba(201, 154, 74, 0.06) 0%, transparent 35%);
}

/* Grain overlay */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  opacity: 0.35;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='3'/%3E%3CfeColorMatrix values='0 0 0 0 0.1 0 0 0 0 0.1 0 0 0 0 0.08 0 0 0 0.18 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  mix-blend-mode: multiply;
}

img, svg { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; border: none; background: none; color: inherit; }

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 32px;
  position: relative;
  z-index: 2;
}

/* ====================================================
   Typography
==================================================== */
h1, h2, h3, h4, h5 {
  font-family: var(--font-display);
  font-weight: 400;
  line-height: 1.05;
  letter-spacing: -0.02em;
  color: var(--ink);
  font-variation-settings: 'opsz' 144, 'SOFT' 30;
}

.eyebrow {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--terra);
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.eyebrow::before {
  content: '';
  width: 24px;
  height: 1px;
  background: var(--terra);
}

.italic { font-style: italic; font-feature-settings: 'ss01' on; }

/* ====================================================
   Header / Navigation
==================================================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(244, 239, 227, 0.85);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid var(--line);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 0;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-size: 26px;
  font-weight: 500;
  letter-spacing: -0.03em;
  color: var(--ink);
}

.brand-mark {
  width: 32px;
  height: 32px;
  background: var(--ink);
  color: var(--cream);
  display: grid;
  place-items: center;
  border-radius: 6px;
  font-family: var(--font-display);
  font-style: italic;
  font-size: 19px;
  font-weight: 500;
  transform: rotate(-4deg);
  box-shadow: 2px 2px 0 var(--terra);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 38px;
  list-style: none;
}

.nav-links a {
  font-size: 14px;
  color: var(--ink-soft);
  font-weight: 500;
  position: relative;
  transition: color 0.2s;
}

.nav-links a:hover { color: var(--terra); }

.nav-links a::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: -4px;
  width: 0;
  height: 1px;
  background: var(--terra);
  transition: width 0.3s ease;
}

.nav-links a:hover::after { width: 100%; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 12px 22px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: -0.005em;
  transition: all 0.25s ease;
  white-space: nowrap;
  cursor: pointer;
  border: 1px solid transparent;
}

.btn-primary {
  background: var(--ink);
  color: var(--cream);
}

.btn-primary:hover {
  background: var(--terra);
  transform: translateY(-1px);
  box-shadow: 0 8px 22px rgba(200, 85, 61, 0.28);
}

.btn-outline {
  background: transparent;
  color: var(--ink);
  border-color: var(--ink);
}

.btn-outline:hover {
  background: var(--ink);
  color: var(--cream);
}

.btn-ghost {
  background: var(--cream-2);
  color: var(--ink);
}

.btn-ghost:hover { background: var(--cream-3); }

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

.menu-toggle {
  display: none;
  width: 40px;
  height: 40px;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  border: 1px solid var(--line);
}

.menu-toggle svg { width: 20px; height: 20px; }

/* ====================================================
   Hero
==================================================== */
.hero {
  padding: 80px 0 100px;
  position: relative;
}

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

.hero-headline {
  font-size: clamp(48px, 7vw, 92px);
  line-height: 0.96;
  letter-spacing: -0.035em;
  margin: 24px 0 28px;
}

.hero-headline .italic {
  color: var(--terra);
  font-weight: 300;
}

.hero-sub {
  font-size: 19px;
  color: var(--ink-soft);
  line-height: 1.55;
  max-width: 510px;
  margin-bottom: 38px;
}

.hero-cta {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 44px;
}

.hero-meta {
  display: flex;
  align-items: center;
  gap: 22px;
  font-size: 13px;
  color: var(--ink-mute);
  font-family: var(--font-mono);
}

.hero-meta .divider {
  width: 4px; height: 4px; background: var(--ink-mute); border-radius: 50%;
}

.hero-meta strong { color: var(--terra); font-weight: 600; }

/* Hero Demo Card */
.demo-card {
  background: #FBF8EF;
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 24px;
  box-shadow: var(--shadow-lg);
  position: relative;
  transform: rotate(0.5deg);
}

.demo-card::before {
  content: '';
  position: absolute;
  inset: -1px;
  border-radius: 18px;
  border: 1px solid var(--ink);
  transform: translate(10px, 10px);
  z-index: -1;
  opacity: 0.5;
}

.demo-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 16px;
  border-bottom: 1px dashed var(--line);
  margin-bottom: 18px;
}

.demo-dots { display: flex; gap: 6px; }
.demo-dot { width: 11px; height: 11px; border-radius: 50%; background: var(--cream-3); }
.demo-dot:nth-child(1) { background: #E27A5F; }
.demo-dot:nth-child(2) { background: var(--gold); }
.demo-dot:nth-child(3) { background: var(--sage); }

.demo-label {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--ink-mute);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.chat-window {
  min-height: 280px;
  max-height: 380px;
  overflow-y: auto;
  padding: 4px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-bottom: 16px;
}

.chat-window::-webkit-scrollbar { width: 6px; }
.chat-window::-webkit-scrollbar-thumb { background: var(--cream-3); border-radius: 999px; }

.msg {
  padding: 12px 16px;
  border-radius: 14px;
  font-size: 14px;
  line-height: 1.5;
  max-width: 88%;
  animation: msgIn 0.35s ease both;
}

.msg.user {
  background: var(--ink);
  color: var(--cream);
  align-self: flex-end;
  border-bottom-right-radius: 4px;
}

.msg.bot {
  background: var(--cream-2);
  color: var(--ink);
  align-self: flex-start;
  border-bottom-left-radius: 4px;
  border: 1px solid var(--line-soft);
}

.msg.bot.typing {
  display: inline-flex;
  gap: 4px;
  padding: 16px 18px;
}

.msg.bot.typing span {
  width: 6px; height: 6px;
  background: var(--ink-mute);
  border-radius: 50%;
  animation: typing 1.2s infinite ease-in-out;
}
.msg.bot.typing span:nth-child(2) { animation-delay: 0.15s; }
.msg.bot.typing span:nth-child(3) { animation-delay: 0.3s; }

@keyframes typing {
  0%, 80%, 100% { opacity: 0.3; transform: translateY(0); }
  40% { opacity: 1; transform: translateY(-4px); }
}

@keyframes msgIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

.invoice-preview {
  background: var(--cream);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 18px;
  font-family: var(--font-mono);
  font-size: 12px;
  margin-top: 4px;
  align-self: stretch;
  max-width: 100%;
  animation: msgIn 0.4s ease both;
}

.invoice-preview h4 {
  font-family: var(--font-display);
  font-size: 18px;
  margin-bottom: 4px;
}

.invoice-preview .inv-meta {
  display: flex;
  justify-content: space-between;
  color: var(--ink-mute);
  margin-bottom: 14px;
  padding-bottom: 10px;
  border-bottom: 1px dashed var(--line);
}

.invoice-preview .inv-row {
  display: flex;
  justify-content: space-between;
  padding: 6px 0;
}

.invoice-preview .inv-row.total {
  margin-top: 8px;
  padding-top: 10px;
  border-top: 1px solid var(--ink);
  font-weight: 600;
  font-size: 14px;
  color: var(--terra);
}

.chat-input-wrap {
  display: flex;
  gap: 8px;
  background: var(--cream);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 6px;
  align-items: center;
}

.chat-input {
  flex: 1;
  border: none;
  background: transparent;
  padding: 10px 12px;
  font: inherit;
  font-size: 14px;
  color: var(--ink);
  outline: none;
}

.chat-input::placeholder { color: var(--ink-mute); }

.chat-send {
  width: 38px;
  height: 38px;
  background: var(--ink);
  color: var(--cream);
  border-radius: 9px;
  display: grid;
  place-items: center;
  transition: background 0.2s;
}

.chat-send:hover { background: var(--terra); }

.chat-suggestions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 12px;
}

.chip {
  font-size: 11.5px;
  padding: 6px 12px;
  background: var(--cream-2);
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--ink-soft);
  font-family: var(--font-mono);
  cursor: pointer;
  transition: all 0.2s;
}

.chip:hover {
  background: var(--ink);
  color: var(--cream);
  border-color: var(--ink);
}

/* ====================================================
   Sections — generic
==================================================== */
section { padding: 100px 0; position: relative; }

.section-head {
  max-width: 720px;
  margin-bottom: 64px;
}

.section-head h2 {
  font-size: clamp(38px, 5vw, 64px);
  margin: 18px 0 18px;
  letter-spacing: -0.03em;
}

.section-head p {
  font-size: 18px;
  color: var(--ink-soft);
  max-width: 580px;
}

/* ====================================================
   Marquee
==================================================== */
.marquee {
  padding: 36px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  overflow: hidden;
  background: var(--cream-2);
}

.marquee-track {
  display: flex;
  gap: 60px;
  animation: marquee 28s linear infinite;
  white-space: nowrap;
  width: max-content;
}

.marquee-item {
  font-family: var(--font-display);
  font-size: 22px;
  color: var(--ink-soft);
  display: inline-flex;
  align-items: center;
  gap: 60px;
  font-style: italic;
}

.marquee-item::after {
  content: '✦';
  color: var(--terra);
  font-style: normal;
}

@keyframes marquee {
  to { transform: translateX(-50%); }
}

/* ====================================================
   Features
==================================================== */
.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
  border-top: 1px solid var(--line);
  border-left: 1px solid var(--line);
}

.feature-card {
  padding: 36px 32px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: rgba(255,255,255,0.2);
  transition: background 0.3s;
  position: relative;
}

.feature-card:hover {
  background: var(--cream-2);
}

.feature-num {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--terra);
  letter-spacing: 0.15em;
  margin-bottom: 30px;
}

.feature-icon {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  background: var(--ink);
  color: var(--cream);
  border-radius: 10px;
  margin-bottom: 24px;
}

.feature-icon svg { width: 22px; height: 22px; }

.feature-card h3 {
  font-size: 24px;
  margin-bottom: 12px;
}

.feature-card p {
  font-size: 15px;
  color: var(--ink-soft);
  line-height: 1.6;
}

/* ====================================================
   How it works
==================================================== */
.how-section { background: var(--ink); color: var(--cream); }
.how-section .eyebrow { color: var(--gold); }
.how-section .eyebrow::before { background: var(--gold); }
.how-section h2 { color: var(--cream); }
.how-section .section-head p { color: rgba(244, 239, 227, 0.7); }

.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  margin-top: 40px;
}

.step {
  padding: 32px;
  border-radius: var(--radius);
  background: rgba(244, 239, 227, 0.05);
  border: 1px solid rgba(244, 239, 227, 0.12);
  position: relative;
  overflow: hidden;
}

.step-num {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 84px;
  color: var(--terra);
  line-height: 1;
  margin-bottom: 18px;
  font-weight: 300;
}

.step h3 {
  font-size: 22px;
  margin-bottom: 12px;
  color: var(--cream);
}

.step p {
  color: rgba(244, 239, 227, 0.7);
  font-size: 14.5px;
  line-height: 1.6;
}

/* ====================================================
   Pricing
==================================================== */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
  margin-top: 24px;
}

.plan {
  background: #FBF8EF;
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 36px 30px;
  position: relative;
  transition: transform 0.3s, box-shadow 0.3s;
}

.plan:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.plan.featured {
  background: var(--ink);
  color: var(--cream);
  border-color: var(--ink);
  transform: scale(1.02);
}

.plan.featured:hover { transform: scale(1.02) translateY(-4px); }

.plan-tag {
  position: absolute;
  top: -12px;
  right: 24px;
  background: var(--terra);
  color: var(--cream);
  padding: 5px 12px;
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.plan h3 {
  font-size: 26px;
  margin-bottom: 6px;
}

.plan.featured h3 { color: var(--cream); }

.plan-desc {
  color: var(--ink-mute);
  font-size: 13.5px;
  margin-bottom: 24px;
  min-height: 36px;
}

.plan.featured .plan-desc { color: rgba(244, 239, 227, 0.6); }

.plan-price {
  font-family: var(--font-display);
  font-size: 54px;
  letter-spacing: -0.03em;
  line-height: 1;
  margin-bottom: 4px;
}

.plan-price small {
  font-size: 16px;
  color: var(--ink-mute);
  font-family: var(--font-body);
  font-weight: 500;
}

.plan.featured .plan-price small { color: rgba(244, 239, 227, 0.6); }

.plan ul {
  list-style: none;
  margin: 28px 0 28px;
  padding-top: 24px;
  border-top: 1px dashed var(--line);
}

.plan.featured ul { border-top-color: rgba(244, 239, 227, 0.15); }

.plan ul li {
  font-size: 14px;
  padding: 8px 0;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  color: var(--ink-soft);
}

.plan.featured ul li { color: rgba(244, 239, 227, 0.85); }

.plan ul li::before {
  content: '✓';
  color: var(--terra);
  font-weight: 700;
  margin-top: 1px;
}

.plan .btn { width: 100%; }

/* ====================================================
   Creator Section
==================================================== */
.creator-section {
  background: var(--cream-2);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.creator-grid {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 60px;
  align-items: center;
}

.creator-photo {
  position: relative;
}

.creator-photo .frame {
  background: linear-gradient(135deg, var(--terra), var(--gold));
  padding: 8px;
  border-radius: 20px;
  transform: rotate(-2deg);
  box-shadow: var(--shadow-lg);
}

.creator-photo .avatar {
  background: var(--cream);
  border-radius: 14px;
  aspect-ratio: 4/5;
  width: 100%;
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-size: 110px;
  color: var(--ink);
  font-style: italic;
  position: relative;
  overflow: hidden;
}

.creator-photo .avatar::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 30% 30%, rgba(200, 85, 61, 0.18), transparent 50%),
    radial-gradient(circle at 70% 70%, rgba(201, 154, 74, 0.15), transparent 50%);
}

.creator-name {
  font-size: 48px;
  letter-spacing: -0.03em;
  margin: 14px 0 4px;
}

.creator-role {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--terra);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  margin-bottom: 22px;
}

.creator-bio {
  font-size: 16.5px;
  color: var(--ink-soft);
  line-height: 1.7;
  margin-bottom: 22px;
  max-width: 620px;
}

.creator-bio::first-letter {
  font-family: var(--font-display);
  font-size: 56px;
  float: left;
  line-height: 0.95;
  margin: 6px 10px 0 0;
  color: var(--terra);
  font-style: italic;
  font-weight: 300;
}

.creator-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--ink);
  border-bottom: 1px solid var(--ink);
  padding-bottom: 2px;
  transition: gap 0.2s, color 0.2s;
}

.creator-cta:hover { gap: 14px; color: var(--terra); border-bottom-color: var(--terra); }

/* ====================================================
   FAQ
==================================================== */
.faq-list { max-width: 820px; }

.faq-item {
  border-bottom: 1px solid var(--line);
  padding: 22px 0;
  cursor: pointer;
}

.faq-q {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: var(--font-display);
  font-size: 22px;
  letter-spacing: -0.015em;
  gap: 24px;
}

.faq-q .plus {
  width: 32px; height: 32px;
  border: 1px solid var(--line);
  border-radius: 50%;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  font-family: var(--font-body);
  font-size: 18px;
  transition: transform 0.3s, background 0.3s, color 0.3s;
}

.faq-item.open .plus {
  transform: rotate(45deg);
  background: var(--ink);
  color: var(--cream);
}

.faq-a {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease, padding 0.3s, opacity 0.3s;
  font-size: 16px;
  color: var(--ink-soft);
  line-height: 1.7;
  opacity: 0;
}

.faq-item.open .faq-a {
  max-height: 200px;
  padding-top: 14px;
  opacity: 1;
}

/* ====================================================
   Contact Section
==================================================== */
.contact-section {
  background: var(--ink);
  color: var(--cream);
}

.contact-section .eyebrow { color: var(--gold); }
.contact-section .eyebrow::before { background: var(--gold); }
.contact-section h2 { color: var(--cream); }
.contact-section .section-head p { color: rgba(244, 239, 227, 0.7); }

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 60px;
  align-items: start;
}

.contact-info h3 {
  color: var(--cream);
  font-size: 28px;
  margin-bottom: 14px;
}

.contact-info p {
  color: rgba(244, 239, 227, 0.7);
  margin-bottom: 30px;
  font-size: 16px;
}

.contact-points {
  list-style: none;
}

.contact-points li {
  display: flex;
  gap: 14px;
  padding: 16px 0;
  border-bottom: 1px solid rgba(244, 239, 227, 0.1);
  font-size: 14.5px;
  color: rgba(244, 239, 227, 0.85);
}

.contact-points li strong {
  display: block;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--gold);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 4px;
  font-weight: 500;
}

.contact-points li > div { flex: 1; }

.form-card {
  background: rgba(244, 239, 227, 0.05);
  border: 1px solid rgba(244, 239, 227, 0.15);
  border-radius: 18px;
  padding: 36px;
}

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

.field { margin-bottom: 16px; }

.field label {
  display: block;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--gold);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 8px;
  font-weight: 500;
}

.field input,
.field textarea,
.field select {
  width: 100%;
  padding: 14px 16px;
  border-radius: 10px;
  background: var(--cream);
  border: 1px solid transparent;
  color: var(--ink);
  font: inherit;
  font-size: 15px;
  outline: none;
  transition: border-color 0.2s;
}

.field input:focus,
.field textarea:focus,
.field select:focus { border-color: var(--terra); }

.field textarea {
  resize: vertical;
  min-height: 110px;
  font-family: inherit;
}

.form-card .btn { width: 100%; margin-top: 8px; }

/* ====================================================
   Modal / Dialog
==================================================== */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(26, 24, 20, 0.6);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  z-index: 1000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  transition: opacity 0.25s;
}

.modal-backdrop.open {
  display: flex;
  opacity: 1;
}

.modal {
  background: var(--cream);
  border-radius: 18px;
  width: 100%;
  max-width: 540px;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
  padding: 40px;
  box-shadow: 0 40px 80px rgba(0,0,0,0.4);
  transform: translateY(20px) scale(0.96);
  opacity: 0;
  transition: transform 0.3s, opacity 0.3s;
}

.modal-backdrop.open .modal {
  transform: translateY(0) scale(1);
  opacity: 1;
}

.modal-close {
  position: absolute;
  top: 18px;
  right: 18px;
  width: 36px; height: 36px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--cream-2);
  transition: background 0.2s;
}

.modal-close:hover { background: var(--cream-3); }

.modal-header {
  margin-bottom: 24px;
}

.modal-header .eyebrow { margin-bottom: 10px; }

.modal-header h3 {
  font-size: 32px;
  letter-spacing: -0.025em;
  margin-bottom: 8px;
}

.modal-header p {
  color: var(--ink-soft);
  font-size: 15px;
}

.modal .field input,
.modal .field textarea,
.modal .field select {
  background: var(--cream-2);
}

.modal .field label { color: var(--terra); }

.modal .btn { width: 100%; }

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

.modal-success.show { display: block; }

.modal-success-icon {
  width: 72px; height: 72px;
  background: var(--terra);
  color: var(--cream);
  border-radius: 50%;
  display: grid;
  place-items: center;
  margin: 0 auto 24px;
  animation: pop 0.5s cubic-bezier(0.2, 1.2, 0.4, 1.1) both;
}

@keyframes pop {
  from { transform: scale(0); }
  to { transform: scale(1); }
}

.modal-success h3 {
  font-size: 30px;
  margin-bottom: 10px;
}

.modal-success p {
  color: var(--ink-soft);
  margin-bottom: 24px;
}

body.modal-open { overflow: hidden; }

/* ====================================================
   Footer
==================================================== */
.site-footer {
  background: var(--cream-2);
  border-top: 1px solid var(--line);
  padding-top: 80px;
  position: relative;
  z-index: 2;
}

.footer-top {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 50px;
  padding-bottom: 60px;
  border-bottom: 1px solid var(--line);
}

.footer-brand .brand { margin-bottom: 18px; }

.footer-brand p {
  font-size: 14.5px;
  color: var(--ink-soft);
  max-width: 320px;
  line-height: 1.6;
  margin-bottom: 24px;
}

.socials {
  display: flex;
  gap: 10px;
}

.social-icon {
  width: 38px;
  height: 38px;
  border: 1px solid var(--line);
  border-radius: 50%;
  display: grid;
  place-items: center;
  transition: all 0.2s;
}

.social-icon:hover {
  background: var(--ink);
  color: var(--cream);
  border-color: var(--ink);
  transform: translateY(-2px);
}

.social-icon svg { width: 16px; height: 16px; }

.footer-col h4 {
  font-family: var(--font-mono);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--terra);
  margin-bottom: 22px;
  font-weight: 500;
}

.footer-col ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer-col li a {
  font-size: 14.5px;
  color: var(--ink-soft);
  transition: color 0.2s;
}

.footer-col li a:hover { color: var(--terra); }

.footer-bottom {
  padding: 28px 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
  color: var(--ink-mute);
  flex-wrap: wrap;
  gap: 16px;
}

.footer-bottom-links {
  display: flex;
  gap: 24px;
  list-style: none;
}

.footer-bottom-links a {
  color: var(--ink-mute);
  font-size: 13px;
  transition: color 0.2s;
}

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

.footer-mega {
  font-family: var(--font-display);
  font-size: clamp(80px, 18vw, 220px);
  font-style: italic;
  font-weight: 200;
  color: var(--ink);
  line-height: 0.9;
  letter-spacing: -0.04em;
  padding: 30px 0 0;
  text-align: center;
  overflow: hidden;
  opacity: 0.92;
}

.footer-mega .terra { color: var(--terra); }

/* ====================================================
   Subpage hero
==================================================== */
.page-hero {
  padding: 100px 0 60px;
  border-bottom: 1px solid var(--line);
}

.page-hero h1 {
  font-size: clamp(56px, 9vw, 120px);
  letter-spacing: -0.04em;
  line-height: 0.95;
  margin: 18px 0 22px;
}

.page-hero p {
  font-size: 19px;
  color: var(--ink-soft);
  max-width: 620px;
}

/* ====================================================
   Legal pages content
==================================================== */
.legal-content {
  max-width: 760px;
  margin: 0 auto;
  padding: 60px 0;
}

.legal-content h2 {
  font-size: 32px;
  margin: 48px 0 16px;
}

.legal-content h3 {
  font-size: 22px;
  margin: 28px 0 12px;
}

.legal-content p,
.legal-content li {
  font-size: 16px;
  color: var(--ink-soft);
  line-height: 1.75;
  margin-bottom: 14px;
}

.legal-content ul, .legal-content ol {
  padding-left: 22px;
  margin-bottom: 18px;
}

.legal-meta {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--ink-mute);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 40px;
}

/* ====================================================
   About page
==================================================== */
.about-story {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: start;
  padding: 40px 0;
}

.about-story .lead {
  font-family: var(--font-display);
  font-size: 28px;
  line-height: 1.3;
  font-style: italic;
  font-weight: 300;
  color: var(--ink);
}

.about-story p {
  font-size: 16.5px;
  color: var(--ink-soft);
  line-height: 1.75;
  margin-bottom: 16px;
}

.values-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
  margin-top: 40px;
}

.value-card {
  padding: 30px;
  background: rgba(255,255,255,0.4);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.value-card .num {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 36px;
  color: var(--terra);
  font-weight: 300;
  margin-bottom: 18px;
}

.value-card h3 {
  font-size: 24px;
  margin-bottom: 10px;
}

.value-card p {
  font-size: 14.5px;
  color: var(--ink-soft);
}

/* ====================================================
   Responsive
==================================================== */
@media (max-width: 1024px) {
  .hero-grid { grid-template-columns: 1fr; gap: 50px; }
  .features-grid { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: 1fr; gap: 18px; }
  .pricing-grid { grid-template-columns: 1fr; max-width: 480px; margin: 24px auto 0; }
  .plan.featured { transform: none; }
  .plan.featured:hover { transform: translateY(-4px); }
  .creator-grid { grid-template-columns: 1fr; gap: 40px; text-align: left; }
  .creator-photo { max-width: 280px; }
  .contact-grid { grid-template-columns: 1fr; gap: 40px; }
  .footer-top { grid-template-columns: 1fr 1fr; gap: 40px; }
  .about-story { grid-template-columns: 1fr; gap: 30px; }
  .values-grid { grid-template-columns: 1fr; }
}

@media (max-width: 720px) {
  .container { padding: 0 22px; }
  section { padding: 70px 0; }
  .hero { padding: 50px 0 70px; }
  .nav-links { display: none; position: fixed; top: 70px; left: 0; right: 0; background: var(--cream); flex-direction: column; gap: 0; padding: 18px 22px; border-bottom: 1px solid var(--line); box-shadow: var(--shadow-md); }
  .nav-links.open { display: flex; }
  .nav-links li { width: 100%; }
  .nav-links a { display: block; padding: 14px 0; border-bottom: 1px solid var(--line-soft); width: 100%; font-size: 16px; }
  .nav-links li:last-child { padding-top: 12px; }
  .nav-links li:last-child .btn { width: 100%; justify-content: center; }
  .menu-toggle { display: inline-flex; }
  .hero-cta { flex-direction: column; align-items: stretch; }
  .hero-cta .btn { width: 100%; justify-content: center; }
  .hero-meta { flex-direction: column; align-items: flex-start; gap: 8px; }
  .hero-meta .divider { display: none; }
  .features-grid { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .footer-top { grid-template-columns: 1fr; gap: 36px; padding-bottom: 40px; }
  .footer-bottom { flex-direction: column; align-items: flex-start; }
  .footer-bottom-links { flex-wrap: wrap; gap: 14px; }
  .modal { padding: 28px 22px; }
  .section-head { margin-bottom: 40px; }
  .creator-name { font-size: 38px; }
  .demo-card { padding: 18px; }
  .legal-content { padding: 30px 0; }
}

/* ====================================================
   Utility
==================================================== */
.fade-in {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}
