/* ==========================================================================
   LI Generator — Global Stylesheet
   Brand: Purple #7C3AED  |  Orange #F97316
   Structure: 1. Tokens  2. Reset  3. Layout  4. Nav  5. Hero  6. Tool
              7. Content sections  8. Legal pages  9. Footer  10. Responsive
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. DESIGN TOKENS
   -------------------------------------------------------------------------- */
:root {
  /* Brand */
  --purple: #7c3aed;
  --purple-dark: #6d28d9;
  --purple-light: #a78bfa;
  --purple-soft: #f3edff;
  --orange: #f97316;
  --orange-dark: #ea580c;
  --orange-soft: #fff3e9;

  /* Surfaces */
  --white: #ffffff;
  --off-white: #fafafa;
  --border: #e8e8ef;

  /* Text */
  --text: #1e293b;
  --muted: #64748b;

  /* Type */
  --font-body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-head: "Poppins", "Inter", -apple-system, sans-serif;

  /* Shape */
  --radius: 12px;
  --radius-lg: 20px;
  --radius-pill: 999px;

  /* Elevation */
  --shadow-sm: 0 1px 2px rgba(30, 41, 59, 0.06);
  --shadow: 0 4px 16px rgba(30, 41, 59, 0.07);
  --shadow-lg: 0 12px 36px rgba(30, 41, 59, 0.1);
  --shadow-purple: 0 8px 24px rgba(124, 58, 237, 0.18);
  --shadow-orange: 0 8px 24px rgba(249, 115, 22, 0.28);

  /* Rhythm */
  --container: 1160px;
  --gap: 24px;
  --section-y: 72px;

  --transition: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

/* --------------------------------------------------------------------------
   2. RESET & BASE
   -------------------------------------------------------------------------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  scroll-padding-top: 88px; /* clears the sticky nav on anchor jumps */
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.7;
  color: var(--text);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

h1,
h2,
h3,
h4,
h5 {
  font-family: var(--font-head);
  font-weight: 700;
  line-height: 1.2;
  color: var(--text);
  margin: 0 0 16px;
  letter-spacing: -0.02em;
}

h1 { font-size: clamp(2rem, 5vw, 3.4rem); }
h2 { font-size: clamp(1.6rem, 3.6vw, 2.4rem); }
h3 { font-size: clamp(1.15rem, 2.2vw, 1.4rem); }

p { margin: 0 0 16px; }

a {
  color: var(--purple);
  text-decoration: none;
  transition: color var(--transition);
}

a:hover { color: var(--orange); }

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

ul, ol { margin: 0 0 16px; padding-left: 22px; }
li { margin-bottom: 8px; }

:focus-visible {
  outline: 3px solid var(--orange);
  outline-offset: 2px;
  border-radius: 4px;
}

/* Screen-reader-only utility (used for labels on icon-only controls) */
.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* --------------------------------------------------------------------------
   3. LAYOUT HELPERS
   -------------------------------------------------------------------------- */
.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 20px;
}

.container--narrow { max-width: 820px; }

section { padding: var(--section-y) 0; }

.section--alt { background: var(--off-white); }

.section-head {
  text-align: center;
  max-width: 680px;
  margin: 0 auto 48px;
}

.section-head p {
  color: var(--muted);
  font-size: 1.05rem;
  margin: 0;
}

.eyebrow {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--purple);
  background: var(--purple-soft);
  padding: 6px 14px;
  border-radius: var(--radius-pill);
  margin-bottom: 16px;
}

.gradient-text {
  background: linear-gradient(100deg, var(--purple) 0%, var(--purple-light) 42%, var(--orange) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: var(--purple); /* fallback where background-clip is unsupported */
}

/* Buttons ---------------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font-body);
  font-size: 0.98rem;
  font-weight: 600;
  padding: 13px 26px;
  border-radius: var(--radius);
  border: 2px solid transparent;
  cursor: pointer;
  transition: transform var(--transition), box-shadow var(--transition),
              background var(--transition), color var(--transition);
  text-align: center;
  line-height: 1.2;
}

.btn:active { transform: translateY(1px); }

.btn--orange {
  background: var(--orange);
  color: var(--white);
  box-shadow: var(--shadow-orange);
}

.btn--orange:hover {
  background: var(--orange-dark);
  color: var(--white);
  transform: translateY(-2px);
}

.btn--purple {
  background: var(--purple);
  color: var(--white);
  box-shadow: var(--shadow-purple);
}

.btn--purple:hover {
  background: var(--purple-dark);
  color: var(--white);
  transform: translateY(-2px);
}

.btn--outline {
  background: var(--white);
  color: var(--purple);
  border-color: var(--purple);
}

.btn--outline:hover {
  background: var(--purple);
  color: var(--white);
  transform: translateY(-2px);
}

.btn--lg { padding: 16px 34px; font-size: 1.05rem; }

/* Ad slot placeholders ---------------------------------------------------- */
.ad-slot {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 20px;
}

.ad-slot__inner {
  min-height: 90px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px dashed var(--border);
  border-radius: var(--radius);
  background: var(--off-white);
  color: #b6bfcc;
  font-size: 0.75rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

/* --------------------------------------------------------------------------
   4. NAVIGATION
   -------------------------------------------------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--white);
  border-bottom: 1px solid transparent;
  transition: box-shadow var(--transition), border-color var(--transition);
}

/* .is-scrolled is toggled by script.js once the page scrolls */
.site-header.is-scrolled {
  box-shadow: 0 2px 14px rgba(30, 41, 59, 0.08);
  border-bottom-color: var(--border);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}

.logo {
  font-family: var(--font-head);
  font-size: 1.4rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--text);
  display: inline-flex;
  align-items: center;
  gap: 2px;
}

.logo:hover { color: var(--text); }
.logo__li { color: var(--purple); }
.logo__gen { color: var(--orange); }

.nav__links {
  display: flex;
  align-items: center;
  gap: 6px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav__links li { margin: 0; }

.nav__links a {
  display: block;
  padding: 9px 16px;
  border-radius: var(--radius);
  font-weight: 500;
  color: var(--text);
  transition: background var(--transition), color var(--transition);
}

.nav__links a:hover,
.nav__links a.is-active {
  background: var(--purple-soft);
  color: var(--purple);
}

.nav__toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 0;
  background: none;
  border: 0;
  cursor: pointer;
  border-radius: var(--radius);
}

.nav__toggle span {
  display: block;
  width: 22px;
  height: 2px;
  margin: 0 auto;
  border-radius: 2px;
  background: var(--text);
  transition: transform var(--transition), opacity var(--transition);
}

/* Hamburger morphs into a close icon while the drawer is open */
.nav__toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav__toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav__toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.nav__overlay {
  position: fixed;
  inset: 0;
  background: rgba(30, 41, 59, 0.45);
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--transition), visibility var(--transition);
  z-index: 98;
}

.nav__overlay.is-open { opacity: 1; visibility: visible; }

/* --------------------------------------------------------------------------
   5. HERO
   -------------------------------------------------------------------------- */
.hero {
  position: relative;
  min-height: calc(100vh - 72px);
  display: flex;
  align-items: center;
  overflow: hidden;
  padding: 64px 0;
  background: var(--white);
}

.hero__content {
  position: relative;
  z-index: 2;
  text-align: center;
  max-width: 780px;
  margin: 0 auto;
}

.hero h1 { margin-bottom: 20px; }

.hero__sub {
  font-size: clamp(1.02rem, 2vw, 1.22rem);
  color: var(--muted);
  max-width: 600px;
  margin: 0 auto 34px;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  justify-content: center;
}

.hero__stats {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px 36px;
  margin-top: 46px;
  padding-top: 30px;
  border-top: 1px solid var(--border);
}

.hero__stat strong {
  display: block;
  font-family: var(--font-head);
  font-size: 1.5rem;
  color: var(--purple);
}

.hero__stat span {
  font-size: 0.85rem;
  color: var(--muted);
}

/* Animated background: gradient blobs + grid overlay ---------------------- */
.hero__bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}

.blob {
  position: absolute;
  width: 420px;
  height: 420px;
  filter: blur(48px);
  opacity: 0.42;
  will-change: transform, border-radius;
}

.blob--1 {
  top: -110px;
  left: -90px;
  background: radial-gradient(circle at 30% 30%, #a78bfa, #7c3aed);
  border-radius: 62% 38% 55% 45% / 48% 52% 48% 52%;
  animation: drift1 22s ease-in-out infinite alternate;
}

.blob--2 {
  top: 8%;
  right: -120px;
  width: 380px;
  height: 380px;
  background: radial-gradient(circle at 60% 40%, #fdba74, #f97316);
  border-radius: 42% 58% 38% 62% / 56% 40% 60% 44%;
  animation: drift2 26s ease-in-out infinite alternate;
}

.blob--3 {
  bottom: -140px;
  left: 22%;
  width: 460px;
  height: 460px;
  background: radial-gradient(circle at 40% 60%, #c4b5fd, #8b5cf6);
  border-radius: 50% 50% 62% 38% / 44% 60% 40% 56%;
  animation: drift3 30s ease-in-out infinite alternate;
}

.blob--4 {
  bottom: -60px;
  right: 12%;
  width: 300px;
  height: 300px;
  background: radial-gradient(circle at 50% 50%, #fed7aa, #fb923c);
  border-radius: 58% 42% 44% 56% / 38% 62% 38% 62%;
  animation: drift4 24s ease-in-out infinite alternate;
}

@keyframes drift1 {
  0%   { transform: translate(0, 0) scale(1); border-radius: 62% 38% 55% 45% / 48% 52% 48% 52%; }
  50%  { transform: translate(70px, 50px) scale(1.12); border-radius: 40% 60% 35% 65% / 60% 38% 62% 40%; }
  100% { transform: translate(30px, 110px) scale(0.96); border-radius: 55% 45% 62% 38% / 42% 58% 42% 58%; }
}

@keyframes drift2 {
  0%   { transform: translate(0, 0) scale(1); border-radius: 42% 58% 38% 62% / 56% 40% 60% 44%; }
  50%  { transform: translate(-80px, 70px) scale(1.08); border-radius: 60% 40% 58% 42% / 38% 62% 38% 62%; }
  100% { transform: translate(-40px, 140px) scale(1.02); border-radius: 38% 62% 46% 54% / 62% 36% 64% 38%; }
}

@keyframes drift3 {
  0%   { transform: translate(0, 0) scale(1); border-radius: 50% 50% 62% 38% / 44% 60% 40% 56%; }
  50%  { transform: translate(90px, -60px) scale(1.1); border-radius: 36% 64% 42% 58% / 58% 42% 60% 40%; }
  100% { transform: translate(-30px, -30px) scale(0.94); border-radius: 58% 42% 50% 50% / 40% 58% 42% 60%; }
}

@keyframes drift4 {
  0%   { transform: translate(0, 0) scale(1); border-radius: 58% 42% 44% 56% / 38% 62% 38% 62%; }
  50%  { transform: translate(-60px, -80px) scale(1.14); border-radius: 44% 56% 60% 40% / 62% 38% 58% 42%; }
  100% { transform: translate(-100px, -20px) scale(1); border-radius: 52% 48% 38% 62% / 46% 54% 46% 54%; }
}

/* 5% opacity grid overlay sits above the blobs */
.hero__grid {
  position: absolute;
  inset: 0;
  z-index: 1;
  opacity: 0.05;
  pointer-events: none;
  background-image:
    linear-gradient(to right, var(--text) 1px, transparent 1px),
    linear-gradient(to bottom, var(--text) 1px, transparent 1px);
  background-size: 46px 46px;
  -webkit-mask-image: radial-gradient(ellipse at center, #000 35%, transparent 78%);
  mask-image: radial-gradient(ellipse at center, #000 35%, transparent 78%);
}

/* --------------------------------------------------------------------------
   6. THE TOOL
   -------------------------------------------------------------------------- */
.tool-grid {
  display: grid;
  grid-template-columns: 340px 1fr;
  gap: 28px;
  align-items: start;
}

.card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  padding: 28px;
}

.card__title {
  font-family: var(--font-head);
  font-size: 1.1rem;
  font-weight: 600;
  margin: 0 0 20px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border);
}

.field { margin-bottom: 20px; }

.field > label,
.field__legend {
  display: block;
  font-size: 0.86rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 8px;
  padding: 0;
}

.field__hint {
  display: block;
  font-size: 0.76rem;
  font-weight: 400;
  color: var(--muted);
  margin-top: 4px;
}

.field input[type="number"],
.field select {
  width: 100%;
  font-family: var(--font-body);
  font-size: 0.95rem;
  color: var(--text);
  padding: 11px 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--white);
  transition: border-color var(--transition), box-shadow var(--transition);
  -webkit-appearance: none;
  appearance: none;
}

.field select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%2364748b' d='M6 8 0 0h12z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 36px;
}

.field input[type="number"]:focus,
.field select:focus {
  border-color: var(--purple);
  box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.14);
  outline: none;
}

fieldset.field {
  border: 0;
  margin: 0 0 20px;
  padding: 0;
  min-width: 0;
}

/* Custom checkbox rows */
.check {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  cursor: pointer;
  font-size: 0.9rem;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: border-color var(--transition), background var(--transition);
  margin-bottom: 10px;
}

.check:hover { border-color: var(--purple-light); background: var(--purple-soft); }

.check input { margin: 3px 0 0; accent-color: var(--purple); width: 16px; height: 16px; flex-shrink: 0; }

.tool__actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 24px;
}

.tool__actions .btn { width: 100%; }

/* Output panel ----------------------------------------------------------- */
.output-card { display: flex; flex-direction: column; min-height: 100%; }

.output__box {
  flex: 1;
  min-height: 340px;
  max-height: 620px;
  overflow-y: auto;
  padding: 22px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--off-white);
  font-size: 0.97rem;
  line-height: 1.8;
  color: var(--text);
  white-space: pre-wrap;
  word-break: break-word;
}

.output__box p { margin: 0 0 14px; }
.output__box p:last-child { margin-bottom: 0; }
.output__box ul { margin: 0; padding-left: 22px; }

.output__box.is-empty {
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: var(--muted);
  font-style: italic;
}

/* Fade-in used every time new text is generated */
.fade-in { animation: fadeIn 0.45s ease both; }

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

.output__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 24px;
  align-items: center;
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
  font-size: 0.85rem;
  color: var(--muted);
}

.output__meta strong { color: var(--purple); font-weight: 600; }

/* Small toast confirmation for copy/download */
.toast {
  position: fixed;
  left: 50%;
  bottom: 28px;
  transform: translate(-50%, 20px);
  background: var(--text);
  color: var(--white);
  font-size: 0.9rem;
  padding: 12px 22px;
  border-radius: var(--radius-pill);
  box-shadow: var(--shadow-lg);
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--transition), transform var(--transition), visibility var(--transition);
  z-index: 200;
}

.toast.is-visible { opacity: 1; visibility: visible; transform: translate(-50%, 0); }

/* --------------------------------------------------------------------------
   7. CONTENT SECTIONS
   -------------------------------------------------------------------------- */
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--gap);
}

.feature {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px 26px;
  text-align: center;
  transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
}

.feature:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: var(--purple-light);
}

.feature__icon {
  width: 58px;
  height: 58px;
  margin: 0 auto 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 16px;
  background: var(--purple-soft);
  color: var(--purple);
}

.feature:nth-child(2) .feature__icon { background: var(--orange-soft); color: var(--orange); }

.feature h3 { margin-bottom: 10px; }
.feature p { color: var(--muted); margin: 0; font-size: 0.95rem; }

/* Numbered how-to cards */
.step {
  position: relative;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 34px 26px 26px;
  transition: transform var(--transition), box-shadow var(--transition);
}

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

.step__num {
  position: absolute;
  top: -22px;
  left: 26px;
  width: 46px;
  height: 46px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--purple), var(--orange));
  color: var(--white);
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.15rem;
  box-shadow: var(--shadow-purple);
}

.step h3 { margin: 12px 0 8px; }
.step p { color: var(--muted); margin: 0; font-size: 0.95rem; }

.steps { margin-top: 32px; }

/* Prose blocks (What is Lorem Ipsum, legal pages, about) */
.prose { max-width: 780px; }
.prose.prose--center { margin: 0 auto; }
.prose p { color: var(--text); }
.prose h2 { margin-top: 40px; }
.prose h3 { margin-top: 28px; }
.prose li { color: var(--text); }

.callout {
  border-left: 4px solid var(--orange);
  background: var(--orange-soft);
  border-radius: 0 var(--radius) var(--radius) 0;
  padding: 18px 22px;
  margin: 26px 0;
}

.callout p:last-child { margin-bottom: 0; }

/* FAQ accordion — pure CSS via <details> */
.faq { max-width: 820px; margin: 0 auto; }

.faq details {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  margin-bottom: 12px;
  overflow: hidden;
  transition: border-color var(--transition), box-shadow var(--transition);
}

.faq details[open] { border-color: var(--purple-light); box-shadow: var(--shadow); }

.faq summary {
  cursor: pointer;
  list-style: none;
  padding: 18px 52px 18px 22px;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 1rem;
  position: relative;
}

.faq summary::-webkit-details-marker { display: none; }

.faq summary::after {
  content: "+";
  position: absolute;
  right: 22px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1.5rem;
  font-weight: 400;
  color: var(--purple);
  transition: transform var(--transition);
  line-height: 1;
}

.faq details[open] summary::after { content: "\2212"; color: var(--orange); }

.faq summary:hover { color: var(--purple); }

.faq__body { padding: 0 22px 20px; color: var(--muted); font-size: 0.95rem; }
.faq__body p:last-child { margin-bottom: 0; }

/* Page banner used on inner pages */
.page-hero {
  background: linear-gradient(160deg, var(--purple-soft) 0%, var(--white) 70%);
  padding: 60px 0 52px;
  text-align: center;
  border-bottom: 1px solid var(--border);
}

.page-hero p { color: var(--muted); max-width: 620px; margin: 0 auto; }
.page-hero .updated { font-size: 0.85rem; margin-top: 12px; }

/* Contact page ----------------------------------------------------------- */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 28px;
  align-items: start;
}

.form-field { margin-bottom: 18px; }

.form-field label {
  display: block;
  font-size: 0.88rem;
  font-weight: 600;
  margin-bottom: 8px;
}

.form-field input,
.form-field textarea,
.form-field select {
  width: 100%;
  font-family: var(--font-body);
  font-size: 0.95rem;
  color: var(--text);
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--white);
  transition: border-color var(--transition), box-shadow var(--transition);
}

.form-field textarea { min-height: 160px; resize: vertical; }

.form-field input:focus,
.form-field textarea:focus,
.form-field select:focus {
  border-color: var(--purple);
  box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.14);
  outline: none;
}

.info-row {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  padding: 16px 0;
  border-bottom: 1px solid var(--border);
}

.info-row:last-child { border-bottom: 0; padding-bottom: 0; }

.info-row__icon {
  width: 38px;
  height: 38px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  background: var(--purple-soft);
  color: var(--purple);
}

.info-row h4 { margin: 0 0 2px; font-family: var(--font-head); font-size: 0.95rem; }
.info-row p { margin: 0; font-size: 0.9rem; color: var(--muted); }

/* 404 page --------------------------------------------------------------- */
.error-page {
  min-height: calc(100vh - 72px);
  display: flex;
  align-items: center;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.error-page__code {
  font-family: var(--font-head);
  font-size: clamp(5rem, 20vw, 10rem);
  font-weight: 800;
  line-height: 1;
  margin: 0 0 8px;
  letter-spacing: -0.04em;
}

/* --------------------------------------------------------------------------
   8. FOOTER
   -------------------------------------------------------------------------- */
.site-footer {
  background: var(--purple);
  color: rgba(255, 255, 255, 0.82);
  padding: 56px 0 0;
}

.site-footer a { color: rgba(255, 255, 255, 0.82); }
.site-footer a:hover { color: var(--orange); }

.footer__grid {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr;
  gap: 40px;
  padding-bottom: 40px;
}

.footer__logo {
  font-family: var(--font-head);
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--white);
  display: inline-block;
  margin-bottom: 12px;
}

.footer__logo:hover { color: var(--white); }
.footer__logo .logo__li { color: var(--white); }
.footer__logo .logo__gen { color: #fdba74; }

.footer__tagline { font-size: 0.92rem; max-width: 320px; margin-bottom: 16px; }

.footer__copy { font-size: 0.85rem; color: rgba(255, 255, 255, 0.6); margin: 0; }

.footer__col h4 {
  font-family: var(--font-head);
  font-size: 0.82rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--white);
  margin: 0 0 16px;
}

.footer__col ul { list-style: none; margin: 0; padding: 0; }
.footer__col li { margin-bottom: 10px; font-size: 0.92rem; }

.footer__bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.16);
  padding: 20px 0;
  font-size: 0.84rem;
  color: rgba(255, 255, 255, 0.6);
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  justify-content: space-between;
  align-items: center;
}

/* --------------------------------------------------------------------------
   9. RESPONSIVE — 1024px then 768px (mobile drawer)
   -------------------------------------------------------------------------- */
@media (max-width: 1024px) {
  :root { --section-y: 60px; }

  .tool-grid { grid-template-columns: 1fr; }
  .contact-grid { grid-template-columns: 1fr; }
  .footer__grid { grid-template-columns: 1fr 1fr; gap: 32px; }
  .footer__col--brand { grid-column: 1 / -1; }
}

@media (max-width: 768px) {
  :root { --section-y: 52px; }

  .nav__toggle { display: flex; }

  /* Slide-in drawer */
  .nav__links {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    width: min(78vw, 300px);
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
    background: var(--white);
    box-shadow: -8px 0 30px rgba(30, 41, 59, 0.16);
    padding: 88px 20px 32px;
    transform: translateX(100%);
    transition: transform var(--transition);
    z-index: 99;
  }

  .nav__links.is-open { transform: translateX(0); }

  .nav__links a { padding: 14px 16px; font-size: 1.02rem; }

  .hero { min-height: auto; padding: 56px 0 64px; }
  .hero__stats { gap: 20px; }
  .hero__actions .btn { width: 100%; }

  .blob { width: 260px; height: 260px; filter: blur(40px); }
  .blob--2, .blob--3, .blob--4 { width: 240px; height: 240px; }

  .grid-3 { grid-template-columns: 1fr; }
  .steps { gap: 40px; }

  .card { padding: 22px; }
  .output__box { min-height: 260px; }

  .footer__grid { grid-template-columns: 1fr; }
  .footer__bottom { justify-content: center; text-align: center; }
}

/* Respect reduced-motion preferences: kill blob drift and fades */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* Print: drop chrome, keep the generated text */
@media print {
  .site-header, .site-footer, .hero__bg, .ad-slot, .tool__actions { display: none !important; }
  .output__box { border: 0; background: none; max-height: none; }
}
