/* ============ Instant Project — dark terminal theme ============ */
@font-face {
  font-family: 'Space Grotesk';
  src: url('/fonts/space-grotesk-400.woff2') format('woff2');
  font-weight: 400; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'Space Grotesk';
  src: url('/fonts/space-grotesk-500.woff2') format('woff2');
  font-weight: 500; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'Space Grotesk';
  src: url('/fonts/space-grotesk-600.woff2') format('woff2');
  font-weight: 600; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'Space Grotesk';
  src: url('/fonts/space-grotesk-700.woff2') format('woff2');
  font-weight: 700; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'IBM Plex Mono';
  src: url('/fonts/ibm-plex-mono-400.woff2') format('woff2');
  font-weight: 400; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'IBM Plex Mono';
  src: url('/fonts/ibm-plex-mono-500.woff2') format('woff2');
  font-weight: 500; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'IBM Plex Mono';
  src: url('/fonts/ibm-plex-mono-600.woff2') format('woff2');
  font-weight: 600; font-style: normal; font-display: swap;
}

:root {
  --coral: #e07850;
  --coral-hover: #c4623a;
  --orange: #ff6b35;
  --bg: #0a0a0a;
  --surface: #111111;
  --surface-2: #1a1a1a;
  --text: #f5f5f0;
  --text-muted: #9a9a94;
  --text-dim: #85857e;
  --border: #2d2d2d;
  --border-subtle: #1d1d1d;
  --green: #4ade80;
  --danger: #f87171;
  --grotesk: 'Space Grotesk', 'Segoe UI', system-ui, sans-serif;
  --mono: 'IBM Plex Mono', Consolas, monospace;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  font-family: var(--grotesk);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
::selection { background: rgba(224, 120, 80, 0.35); color: #fff; }
img { max-width: 100%; height: auto; }
a { color: var(--coral); text-decoration: none; transition: color .2s; }
a:hover { color: var(--orange); }

.container { width: min(1140px, 92%); margin: 0 auto; }
.container.narrow { width: min(820px, 92%); }
.center { text-align: center; }
.muted { color: var(--text-muted); }
.small { font-size: .82rem; }
.mono { font-family: var(--mono); }

/* mono section labels */
.tag {
  font-family: var(--mono); font-size: 11px; font-weight: 500;
  letter-spacing: .18em; text-transform: uppercase; color: var(--coral);
}

.skip-link {
  position: absolute; left: -9999px; top: 0; z-index: 200;
  background: var(--coral); color: #0a0a0a; padding: 10px 18px;
}
.skip-link:focus { left: 0; color: #0a0a0a; }

/* ---------- buttons: flat, sharp, compact ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  font-family: var(--grotesk); font-size: 13px; font-weight: 700;
  letter-spacing: .06em; text-transform: uppercase;
  text-decoration: none; cursor: pointer;
  border: 1px solid transparent; border-radius: 0;
  padding: 0 26px; height: 46px;
  transition: background .15s ease, border-color .15s ease, color .15s ease, transform .15s ease;
}
.btn:focus-visible { outline: 2px solid var(--coral); outline-offset: 3px; }
.btn-primary { background: var(--coral); color: #0a0a0a; }
.btn-primary:hover { background: var(--orange); color: #0a0a0a; }
.btn-outline { border-color: var(--border); color: var(--text); background: transparent; }
.btn-outline:hover { border-color: var(--coral); color: var(--coral); }
.btn-ghost { color: var(--text-muted); background: transparent; }
.btn-ghost:hover { color: var(--text); }
.btn-invert { background: #f5f5f0; color: #0a0a0a; }
.btn-invert:hover { background: #fff; }
.btn-large { height: 54px; padding: 0 34px; font-size: 14px; }
.btn-small { height: 34px; padding: 0 16px; font-size: 11px; }
.btn-block { width: 100%; }
.btn[disabled] { opacity: .5; cursor: not-allowed; }

/* ---------- header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(10, 10, 10, 0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border-subtle);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 20px; height: 62px; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--text); padding: 10px 4px; min-height: 44px; }
.brand-mark { display: block; }
.brand-name { font-family: var(--grotesk); font-weight: 700; font-size: 15px; letter-spacing: .04em; }
.site-nav { display: flex; align-items: center; gap: 30px; }
.site-nav a { font-family: var(--mono); font-size: 11px; font-weight: 500; letter-spacing: .16em; text-transform: uppercase; color: var(--text-muted); position: relative; }
.site-nav a::after {
  content: ''; position: absolute; left: 0; bottom: -6px; height: 1.5px; width: 0;
  background: var(--coral); transition: width .25s;
}
.site-nav a:hover, .site-nav a.active { color: var(--text); }
.site-nav a:hover::after, .site-nav a.active::after { width: 100%; }
.site-nav .nav-cta { color: #0a0a0a; padding: 0 16px; height: 34px; display: inline-flex; align-items: center; background: var(--coral); }
.site-nav .nav-cta:hover { color: #0a0a0a; background: var(--orange); }
.site-nav .nav-cta::after { display: none; }
.header-account-wrap { display: flex; align-items: center; gap: 14px; }
.header-account, .header-signout {
  display: inline-flex; align-items: center; gap: 7px; background: none; cursor: pointer;
  color: var(--text-muted); font-family: var(--mono); font-size: 11px; font-weight: 500;
  letter-spacing: .12em; text-transform: uppercase; text-decoration: none;
}
.header-account { border: 1px solid var(--border); height: 34px; padding: 0 12px; }
.header-account:hover { color: var(--text); border-color: var(--text-muted); }
.header-signout { border: 0; padding: 0; }
.header-signout:hover { color: var(--text); }
.header-logout { display: inline; margin: 0; }
.nav-toggle { display: none; background: none; border: 1px solid var(--border); cursor: pointer; padding: 12px; min-width: 44px; min-height: 44px; }
.nav-toggle span { display: block; width: 18px; height: 1.5px; background: var(--text); margin: 4px 0; transition: transform .25s, opacity .25s; }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(5.5px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-5.5px) rotate(-45deg); }

/* ---------- hero: terminal grid ---------- */
.hero {
  position: relative; overflow: hidden;
  padding: 96px 0 110px;
  border-bottom: 1px solid var(--border-subtle);
  background:
    linear-gradient(rgba(45, 45, 45, 0.14) 1px, transparent 1px),
    linear-gradient(90deg, rgba(45, 45, 45, 0.14) 1px, transparent 1px);
  background-size: 44px 44px;
}
.hero::after {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(ellipse 70% 60% at 50% 0%, transparent 30%, var(--bg) 100%);
  pointer-events: none;
}
.hero-glow {
  position: absolute; width: 520px; height: 520px; border-radius: 50%;
  background: radial-gradient(circle, rgba(224, 120, 80, 0.16), transparent 65%);
  top: -180px; right: -120px; animation: pulse 8s ease-in-out infinite alternate;
  pointer-events: none;
}
@keyframes pulse { from { opacity: .6; transform: scale(1); } to { opacity: 1; transform: scale(1.15); } }

.hero-grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: 56px; align-items: center; position: relative; z-index: 1; }
.hero-badge {
  display: inline-flex; align-items: center; gap: 10px; height: 30px; padding: 0 14px;
  background: var(--surface-2); border: 1px solid var(--border);
  font-family: var(--mono); font-size: 10.5px; font-weight: 500;
  letter-spacing: .18em; text-transform: uppercase; color: var(--text-muted);
  margin-bottom: 26px;
}
.hero-badge .dot { width: 7px; height: 7px; background: var(--coral); animation: blink 1.6s steps(2) infinite; }
@keyframes blink { 50% { opacity: .25; } }

.hero h1 {
  font-family: var(--grotesk); font-weight: 700;
  font-size: clamp(2.4rem, 5.4vw, 4.2rem);
  line-height: 1.02; letter-spacing: -0.035em;
}
.accent-word { color: var(--coral); }
.hero-sub {
  margin: 24px 0 32px; color: var(--text-muted);
  font-size: 1.02rem; max-width: 33rem; line-height: 1.75;
}
.hero-sub strong { color: var(--text); font-weight: 600; }
.hero-cta { display: flex; gap: 14px; flex-wrap: wrap; }
.hero-meta {
  margin-top: 22px; font-family: var(--mono); font-size: 11.5px;
  color: var(--text-dim); letter-spacing: .04em;
}
.hero-meta .sep { color: var(--coral); margin: 0 8px; }
.animate-in { animation: rise .7s ease both; }
@keyframes rise { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }

/* hero visual: stacked document, terminal style */
.hero-visual { position: relative; min-height: 430px; }
.doc-mock { position: relative; width: min(280px, 78%); margin: 0 auto; }
.doc-page {
  background: var(--surface); border: 1px solid var(--border);
  padding: 26px 22px; min-height: 390px;
}
.doc-page-back { position: absolute; inset: 0; transform: rotate(4deg) translate(14px, 8px); opacity: .55; }
.doc-page-main { position: relative; animation: floaty 5s ease-in-out infinite alternate; }
@keyframes floaty { from { transform: translateY(0) rotate(-0.6deg); } to { transform: translateY(-9px) rotate(0.4deg); } }
.mock-school { height: 11px; width: 62%; margin: 4px auto 16px; background: var(--text); opacity: .9; }
.mock-logo { width: 58px; height: 58px; background: var(--coral); margin: 16px auto 22px; border: 1px solid var(--border); }
.mock-title { height: 13px; width: 84%; margin: 0 auto 18px; background: var(--coral); }
.mock-line { height: 7px; background: var(--surface-2); border-bottom: 1px solid var(--border-subtle); margin: 10px 0; }
.w90 { width: 90%; } .w85 { width: 85%; } .w75 { width: 75%; } .w60 { width: 60%; }
.mock-img {
  height: 86px; margin: 16px 0; border: 1px solid var(--border);
  background: repeating-linear-gradient(45deg, var(--surface-2), var(--surface-2) 8px, #161616 8px, #161616 16px);
}
.chip {
  position: absolute; display: inline-flex; align-items: center; gap: 8px;
  background: var(--bg); border: 1px solid var(--border);
  padding: 7px 13px; font-family: var(--mono); font-size: 11px;
  letter-spacing: .1em; text-transform: uppercase; color: var(--text-muted);
  animation: pop .55s ease both;
}
.chip svg { color: var(--coral); flex-shrink: 0; }
.chip-1 { top: 3%; left: 0; animation-delay: .15s; }
.chip-2 { top: 27%; right: 0; animation-delay: .3s; }
.chip-3 { bottom: 31%; left: 0; animation-delay: .45s; }
.chip-4 { bottom: 11%; right: 4%; animation-delay: .6s; }
.chip-5 { bottom: -3%; left: 36%; background: var(--coral); color: #0a0a0a; border-color: var(--coral); animation-delay: .75s; }
.chip-5 svg { color: #0a0a0a; }
@keyframes pop { from { opacity: 0; transform: scale(.75); } to { opacity: 1; transform: scale(1); } }

/* floating file-type icons in hero (PDF / DOCX) */
.chip-file { padding: 9px 12px; animation: pop .55s ease both, floaty 5s ease-in-out infinite; }
.chip-file img { display: block; width: 30px; height: 30px; object-fit: contain; filter: drop-shadow(0 4px 10px rgba(0,0,0,.45)); }
.chip-file.pdf { top: 1%; right: 8%; animation-delay: .15s, 0s; }
.chip-file.docx { bottom: -9%; left: 14%; animation-delay: .3s, 1.6s; }
@keyframes floaty { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-9px); } }

/* ---------- breadcrumbs ---------- */
.breadcrumbs { padding: 18px 0 0; margin-bottom: 26px; }
.breadcrumbs ol { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 4px; }
.breadcrumbs li { display: inline-flex; align-items: center; font-family: var(--mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; }
.breadcrumbs a { color: var(--text-muted); text-decoration: none; transition: color .15s ease; }
.breadcrumbs a:hover { color: var(--coral); }
.breadcrumbs li:not(.sep) > span[aria-current] { color: var(--coral); }
.breadcrumbs .sep { color: var(--border); padding: 0 4px; }

/* ---------- sections ---------- */
.section { padding: 88px 0; }
.section-alt { background: var(--surface); border-top: 1px solid var(--border-subtle); border-bottom: 1px solid var(--border-subtle); }
.section-head { text-align: center; margin-bottom: 52px; }
.section-tag { font-family: var(--mono); font-size: 11px; letter-spacing: .2em; text-transform: uppercase; color: var(--coral); display: block; margin-bottom: 14px; }
.section-title { font-size: clamp(1.7rem, 3.2vw, 2.4rem); letter-spacing: -0.025em; line-height: 1.15; }
.section-sub { color: var(--text-muted); margin-top: 12px; }

/* steps */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--border); border: 1px solid var(--border); }
.step { background: var(--surface); padding: 34px 28px; }
.step-num {
  font-family: var(--mono); font-size: 12px; font-weight: 600;
  color: var(--coral); letter-spacing: .12em; display: block; margin-bottom: 18px;
}
.step-num::after { content: ''; display: block; width: 26px; height: 2px; background: var(--coral); margin-top: 8px; }
.step h3 { font-size: 1.08rem; margin-bottom: 10px; letter-spacing: -0.01em; }
.step p { color: var(--text-muted); font-size: .93rem; line-height: 1.7; }

/* home demo video (click-to-play YouTube facade) */
.demo-video { max-width: 900px; margin: 0 auto 48px; }
.demo-video-facade {
  position: relative; display: block; width: 100%; aspect-ratio: 16 / 9;
  padding: 0; border: 1px solid var(--border); background: #000;
  cursor: pointer; overflow: hidden; line-height: 0;
}
.demo-video-facade img {
  width: 100%; height: 100%; object-fit: cover; display: block;
  opacity: .82; transition: opacity .25s ease, transform .45s ease;
}
.demo-video-facade::after {
  content: ''; position: absolute; inset: 0; z-index: 1;
  background: linear-gradient(180deg, rgba(10,10,10,0) 42%, rgba(10,10,10,.6));
}
.demo-video-facade:hover img, .demo-video-facade:focus-visible img { opacity: 1; transform: scale(1.03); }
.demo-video-facade:focus-visible { outline: 2px solid var(--coral); outline-offset: 2px; }
.demo-video-play {
  position: absolute; top: 50%; left: 50%; z-index: 2;
  transform: translate(-50%, -50%);
  width: 74px; height: 74px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: var(--coral); color: #0a0a0a;
  box-shadow: 0 12px 34px rgba(0,0,0,.5);
  transition: transform .2s ease, background .2s ease;
}
.demo-video-play svg { margin-left: 4px; }
.demo-video-facade:hover .demo-video-play, .demo-video-facade:focus-visible .demo-video-play {
  transform: translate(-50%, -50%) scale(1.08); background: var(--orange);
}
.demo-video-caption {
  display: flex; align-items: center; justify-content: center; gap: 12px;
  margin-top: 18px; font-size: .92rem; color: var(--text-muted); text-align: center;
}
.demo-video-label {
  font-family: var(--mono); font-size: 10.5px; letter-spacing: .18em; text-transform: uppercase;
  color: var(--coral); border: 1px solid var(--border); background: var(--bg); padding: 4px 9px;
}
.demo-video-embed { display: block; width: 100%; aspect-ratio: 16 / 9; border: 1px solid var(--border); background: #000; }
.demo-video-embed iframe { display: block; width: 100%; height: 100%; border: 0; }

/* features: numbered tiles like the reference */
.feature-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--border); border: 1px solid var(--border); }
.feature { background: var(--surface); padding: 32px 28px; position: relative; transition: background .2s; }
.feature:hover { background: var(--surface-2); }
.feature-idx {
  font-family: var(--mono); font-size: 11px; color: var(--coral);
  letter-spacing: .12em; display: block; margin-bottom: 20px;
}
.feature-icon { color: var(--coral); margin-bottom: 16px; }
.feature h3 { font-size: 1.02rem; margin-bottom: 8px; letter-spacing: -0.01em; }
.feature p { color: var(--text-muted); font-size: .9rem; line-height: 1.7; }

/* subjects */
.subject-chips { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }
.subject-chip {
  font-family: var(--mono); font-size: 11px; letter-spacing: .1em; text-transform: uppercase;
  color: var(--text-muted); background: var(--bg);
  border: 1px solid var(--border); padding: 9px 16px;
  transition: border-color .2s, color .2s;
}
.subject-chip:hover { border-color: var(--coral); color: var(--coral); }

/* faq */
.faq {
  background: var(--surface); border: 1px solid var(--border);
  padding: 24px 26px; margin-bottom: 14px;
}
.faq h3 {
  font-size: 1rem; margin-bottom: 10px; letter-spacing: -0.01em;
  display: flex; gap: 12px; align-items: baseline;
}
.faq h3 .q { font-family: var(--mono); color: var(--coral); font-size: .85rem; flex-shrink: 0; }
.faq p { color: var(--text-muted); font-size: .92rem; line-height: 1.7; }

/* blog cards */
.post-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--border); border: 1px solid var(--border); }
.post-card {
  display: flex; flex-direction: column; gap: 12px;
  background: var(--surface); padding: 30px 26px;
  transition: background .2s;
}
.post-card:hover { background: var(--surface-2); }
.post-card:hover .post-card-link { color: var(--orange); }
.post-card h2, .post-card h3 { font-size: 1.05rem; line-height: 1.4; letter-spacing: -0.01em; color: var(--text); }
.post-card p { color: var(--text-muted); font-size: .9rem; line-height: 1.65; flex: 1; }
.post-card-link { font-family: var(--mono); font-size: 11px; letter-spacing: .14em; text-transform: uppercase; color: var(--coral); }

/* ---------- article / pages ---------- */
.page-head { padding: 44px 0 30px; }
.page-head .tag { display: block; margin-bottom: 14px; }
.page-head h1 { font-size: clamp(1.9rem, 3.6vw, 2.6rem); letter-spacing: -0.03em; line-height: 1.1; }
.page-head p { color: var(--text-muted); margin-top: 12px; }
.article { padding: 44px 0 90px; }
.article-head { margin-bottom: 30px; }
.article-head h1 { font-size: clamp(1.8rem, 3.4vw, 2.4rem); line-height: 1.15; letter-spacing: -0.025em; }
.article-head time { font-family: var(--mono); color: var(--text-dim); font-size: 11px; letter-spacing: .1em; text-transform: uppercase; }
.article-cover { border: 1px solid var(--border); margin-bottom: 30px; width: 100%; }
.article-body h2 { font-size: 1.4rem; margin: 36px 0 12px; letter-spacing: -0.02em; }
.article-body h3 { font-size: 1.12rem; margin: 28px 0 10px; }
.article-body h4 { font-size: 1rem; margin: 22px 0 8px; }
.article-body p { margin-bottom: 15px; color: #c9c8c2; line-height: 1.75; }
.article-body ul, .article-body ol { margin: 0 0 16px 22px; color: #c9c8c2; }
.article-body li { margin-bottom: 7px; }
.article-body li::marker { color: var(--coral); }
.article-body li.task-item { list-style: none; display: flex; align-items: flex-start; gap: 8px; }
.article-body li.task-item .task-box {
  flex: 0 0 auto; width: 15px; height: 15px; margin-top: 3px;
  border: 1px solid var(--border); border-radius: 2px; position: relative;
}
.article-body li.task-item.is-done .task-box { background: var(--coral); border-color: var(--coral); }
.article-body li.task-item.is-done .task-box::after {
  content: ''; position: absolute; left: 4px; top: 0; width: 4px; height: 9px;
  border: solid #fff; border-width: 0 2px 2px 0; transform: rotate(45deg);
}
.article-body blockquote {
  margin: 0 0 18px; padding: 16px 18px; background: var(--surface);
  border-left: 3px solid var(--coral); color: var(--text);
}
.article-body blockquote p { margin: 0 0 10px; color: var(--text); }
.article-body blockquote p:last-child { margin-bottom: 0; }
.article-body img { border: 1px solid var(--border); margin: 10px 0; }
.article-body a { border-bottom: 1px solid rgba(224, 120, 80, .4); }
.article-cta {
  margin-top: 52px; background: var(--surface); border: 1px solid var(--border);
  padding: 28px 30px; display: flex; align-items: center; justify-content: space-between;
  gap: 18px; flex-wrap: wrap;
}
.article-cta p { font-weight: 600; margin: 0; color: var(--text); }

/* ---------- tool page ---------- */
.tool-hero { padding: 64px 0 8px; }
.tool-hero .tag { display: block; margin-bottom: 14px; }
.tool-hero h1 { font-size: clamp(2rem, 3.8vw, 2.7rem); letter-spacing: -0.03em; }
.tool-hero-sub { color: var(--text-muted); margin-top: 12px; }
.tool-section { padding-top: 40px; padding-bottom: 90px; }

.wizard { display: flex; flex-direction: column; gap: 20px; }
.wizard-step {
  background: var(--surface); border: 1px solid var(--border);
  padding: 30px 30px 32px; border-left: 2px solid var(--coral);
}
.wizard-step legend {
  font-weight: 600; font-size: 1rem; padding: 0 10px; letter-spacing: -0.01em;
  display: flex; align-items: center; gap: 12px; color: var(--text);
}
.step-tag {
  font-family: var(--mono); font-size: 11px; font-weight: 600;
  letter-spacing: .18em; text-transform: uppercase;
  color: var(--coral); border: 1px solid var(--border);
  background: var(--bg); padding: 5px 11px;
}
.field { margin-top: 18px; flex: 1; min-width: 0; }
.field label { display: block; font-family: var(--mono); font-size: 10.5px; font-weight: 500; letter-spacing: .14em; text-transform: uppercase; color: var(--text-muted); margin-bottom: 8px; }
.field .req { color: var(--coral); }
.field input[type="text"], .field input[type="email"], .field select, .field textarea {
  width: 100%; font-family: var(--grotesk); font-size: .95rem; color: var(--text);
  background: var(--bg); border: 1px solid var(--border); border-radius: 0;
  padding: 12px 14px; transition: border-color .15s ease;
}
.field select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath d='M2 4l4 4 4-4' stroke='%239a9a94' stroke-width='1.5' fill='none'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; }
.field input::placeholder, .field textarea::placeholder { color: #55554f; }
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none; border-color: var(--coral);
}
.field input[aria-invalid="true"], .field select[aria-invalid="true"] { border-color: var(--danger); }
.field-row { display: flex; gap: 18px; flex-wrap: wrap; }
.field-error { color: var(--danger); font-size: .8rem; margin-top: 6px; }
.checkboxes .check { display: flex; align-items: center; gap: 10px; margin-top: 14px; font-size: .92rem; color: var(--text); cursor: pointer; }
.check input { width: 16px; height: 16px; accent-color: var(--coral); }
.hp-field { position: absolute; left: -9999px; top: -9999px; opacity: 0; height: 0; overflow: hidden; }
.logo-preview { margin-top: 12px; max-height: 84px; border: 1px solid var(--border); }
.wizard-actions { padding: 8px 0 34px; }
.wizard-note { font-family: var(--mono); color: var(--text-dim); font-size: 11px; letter-spacing: .06em; margin-top: 14px; text-align: center; }
.wizard-actions .btn-block { display: flex; margin: 0 auto; max-width: 460px; }

.form-banner-error {
  background: rgba(248, 113, 113, 0.08); border: 1px solid rgba(248, 113, 113, 0.35);
  color: var(--danger); padding: 12px 16px; font-size: .9rem; margin-bottom: 16px;
}

/* ---------- building screen (professional document loader) ---------- */
.build-panel {
  background: var(--surface); border: 1px solid var(--border);
  padding: 0; margin-bottom: 44px;
  position: relative; overflow: hidden;
}
.build-top {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 22px; border-bottom: 1px solid var(--border-subtle);
  background: var(--surface-2);
}
.build-top .mono-label { font-family: var(--mono); font-size: 10.5px; letter-spacing: .16em; text-transform: uppercase; color: var(--text-muted); }
.build-top .live { display: inline-flex; align-items: center; gap: 8px; font-family: var(--mono); font-size: 10.5px; letter-spacing: .14em; text-transform: uppercase; color: var(--coral); }
.build-top .live .dot { width: 7px; height: 7px; background: var(--coral); animation: blink 1.2s steps(2) infinite; }
.build-grid { display: grid; grid-template-columns: 300px 1fr; gap: 0; }

/* left: animated document preview */
.build-doc {
  border-right: 1px solid var(--border-subtle);
  padding: 34px 30px; display: flex; flex-direction: column; align-items: center; gap: 14px;
  background:
    linear-gradient(rgba(45, 45, 45, 0.1) 1px, transparent 1px),
    linear-gradient(90deg, rgba(45, 45, 45, 0.1) 1px, transparent 1px);
  background-size: 28px 28px;
}
.build-paper {
  width: 190px; height: 250px; background: #141414; border: 1px solid var(--border);
  padding: 18px 16px; position: relative;
}
.build-paper::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px;
  background: var(--coral); width: 0; animation: papercolor 2.4s ease-in-out infinite;
}
@keyframes papercolor { 0% { width: 8%; } 55% { width: 100%; } 100% { width: 100%; } }
.build-paper .pl { height: 6px; background: var(--surface-2); margin-bottom: 9px; position: relative; overflow: hidden; }
.build-paper .pl::after {
  content: ''; position: absolute; inset: 0; width: 40%;
  background: linear-gradient(90deg, transparent, rgba(224, 120, 80, 0.45), transparent);
  animation: shimmer 1.8s linear infinite;
}
@keyframes shimmer { from { transform: translateX(-100%); } to { transform: translateX(320%); } }
.build-paper .pl-1 { width: 55%; margin: 6px auto 14px; height: 9px; background: var(--coral); opacity: .85; }
.build-paper .pl-2 { width: 38%; height: 26px; margin: 0 auto 14px; border: 1px solid var(--border); background: transparent; }
.build-paper .pl:nth-child(3) { width: 92%; }
.build-paper .pl:nth-child(4) { width: 85%; }
.build-paper .pl:nth-child(5) { width: 88%; }
.build-paper .pl-img { height: 44px; width: 70%; margin: 12px auto; border: 1px dashed var(--border); }
.build-pages {
  font-family: var(--mono); font-size: 11px; letter-spacing: .14em;
  text-transform: uppercase; color: var(--text-muted);
}
.build-pages b { color: var(--coral); font-weight: 600; }

/* right: pipeline */
.build-pipeline { padding: 34px 36px; }
.build-pipeline h2 { font-size: 1.35rem; letter-spacing: -0.02em; margin-bottom: 6px; }
.build-status-line {
  font-family: var(--mono); font-size: 12px; color: var(--coral);
  min-height: 20px; margin-bottom: 24px; letter-spacing: .02em;
}
.build-status-line::before { content: '> '; color: var(--text-dim); }
.build-bar { height: 6px; background: var(--surface-2); border: 1px solid var(--border-subtle); margin-bottom: 10px; position: relative; overflow: hidden; }
.build-bar-fill { height: 100%; width: 0%; background: var(--coral); transition: width .3s ease; position: relative; }
.build-bar-fill::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.35), transparent);
  animation: shimmer 1.4s linear infinite;
}
.build-pct-row { display: flex; justify-content: space-between; font-family: var(--mono); font-size: 10.5px; letter-spacing: .14em; text-transform: uppercase; color: var(--text-dim); margin-bottom: 26px; }
.build-pct-row b { color: var(--text); font-weight: 600; }

.build-steps { list-style: none; display: flex; flex-direction: column; }
.build-steps li {
  display: flex; align-items: center; gap: 14px;
  padding: 11px 0; border-bottom: 1px solid var(--border-subtle);
  font-size: .92rem; color: var(--text-dim);
  transition: color .3s;
}
.build-steps li:last-child { border-bottom: 0; }
.build-steps .st-icon { width: 20px; height: 20px; flex-shrink: 0; display: grid; place-items: center; }
.build-steps .st-icon .ring { width: 16px; height: 16px; border: 1.5px solid var(--border); display: block; }
.build-steps .st-icon .spinner { width: 16px; height: 16px; border: 1.5px solid var(--border); border-top-color: var(--coral); border-radius: 50%; display: none; animation: spin .7s linear infinite; }
.build-steps .st-icon .tick { display: none; color: var(--green); }
@keyframes spin { to { transform: rotate(360deg); } }
.build-steps li.active { color: var(--text); }
.build-steps li.active .st-icon .ring { display: none; }
.build-steps li.active .st-icon .spinner { display: block; }
.build-steps li.done { color: var(--text-muted); }
.build-steps li.done .st-icon .ring, .build-steps li.done .st-icon .spinner { display: none; }
.build-steps li.done .st-icon .tick { display: block; }
.build-steps li .st-time { margin-left: auto; font-family: var(--mono); font-size: 10px; letter-spacing: .1em; color: var(--text-dim); text-transform: uppercase; }
.build-steps li.done .st-time::after { content: ' done'; color: var(--green); }
.build-steps li.active .st-time::after { content: ' running'; color: var(--coral); }

/* ---------- result panel ---------- */
.result-panel {
  background: var(--surface); border: 1px solid var(--coral);
  padding: 48px 36px; text-align: center; margin-bottom: 44px;
  position: relative;
}
.result-check {
  width: 62px; height: 62px; margin: 0 auto 22px;
  border: 1.5px solid var(--green); color: var(--green);
  display: grid; place-items: center;
  animation: pop .5s ease both;
}
.result-panel h2 { font-size: 1.6rem; letter-spacing: -0.02em; margin-bottom: 10px; }
.result-sub { color: var(--text-muted); font-size: .95rem; margin-bottom: 8px; }
.result-sub .tick { color: var(--green); font-family: var(--mono); }
.result-actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; margin-top: 26px; }
.result-tip { font-family: var(--mono); font-size: 11px; color: var(--text-dim); letter-spacing: .04em; margin-top: 24px; }
.result-panel .btn-ghost { margin-top: 8px; }

/* reCAPTCHA box on the tool form */
.captcha-box { margin-top: 22px; padding: 16px 18px; background: var(--bg); border: 1px solid var(--border); display: inline-block; }

/* recovery note after reload/disconnect */
.resume-note {
  background: var(--surface-2); border: 1px solid var(--border);
  padding: 14px 18px; margin-bottom: 16px;
  font-family: var(--mono); font-size: 12px; color: var(--text-muted); letter-spacing: .04em;
}
.resume-note[hidden] { display: none; }

/* file-type icons inside download buttons */
.file-btn svg { flex-shrink: 0; }
.file-btn img.file-icon { width: 24px; height: 24px; object-fit: contain; flex-shrink: 0; filter: drop-shadow(0 2px 5px rgba(0,0,0,.4)); }

/* ---------- CTA band ---------- */
.cta-band {
  background: var(--coral); padding: 72px 0; border-top: 1px solid var(--border);
}
.cta-inner { text-align: center; }
.cta-band .tag { color: #0a0a0a; display: block; margin-bottom: 14px; opacity: .75; }
.cta-band h2 { font-size: clamp(1.8rem, 3.6vw, 2.5rem); letter-spacing: -0.03em; color: #0a0a0a; margin-bottom: 10px; }
.cta-band p { color: rgba(10, 10, 10, 0.75); margin-bottom: 30px; font-size: 1.02rem; }
.cta-band .btn { background: #0a0a0a; color: #f5f5f0; }
.cta-band .btn:hover { background: #1a1a1a; color: #fff; }

/* ---------- footer ---------- */
.site-footer { background: var(--bg); border-top: 1px solid var(--border-subtle); padding: 64px 0 0; margin-top: 0; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 44px; padding-bottom: 48px; }
.footer-logo { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 15px; letter-spacing: .04em; color: var(--text); margin-bottom: 14px; }
.footer-brand p { font-size: .92rem; color: var(--text-muted); max-width: 30rem; line-height: 1.7; }
.footer-note { color: var(--text-dim); font-family: var(--mono); font-size: 11px !important; letter-spacing: .04em; margin-top: 10px; }
.site-footer h3 {
  font-family: var(--mono); font-size: 10.5px; font-weight: 500;
  letter-spacing: .18em; text-transform: uppercase; color: var(--text-dim); margin-bottom: 18px;
}
.site-footer nav { display: flex; flex-direction: column; gap: 11px; }
.site-footer nav a { color: var(--text-muted); font-size: .92rem; }
.site-footer nav a:hover { color: var(--coral); }
.footer-bottom { border-top: 1px solid var(--border-subtle); padding: 22px 0; font-family: var(--mono); font-size: 11px; color: var(--text-dim); letter-spacing: .06em; display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; }

/* ---------- cookie banner ---------- */
.cookie-banner {
  position: fixed; bottom: 18px; left: 0; right: 0; margin: 0 auto; z-index: 300;
  width: min(660px, calc(100vw - 24px)); background: var(--surface-2); border: 1px solid var(--border);
  padding: 18px 22px; display: flex; align-items: center; gap: 18px; flex-wrap: wrap;
  animation: rise .5s ease both;
}
.cookie-banner[hidden] { display: none; }
.cookie-banner p { flex: 1; min-width: 240px; font-size: .85rem; color: var(--text-muted); line-height: 1.6; }
.cookie-actions { display: flex; gap: 10px; }

/* ---------- 404 ---------- */
.notfound { padding: 110px 0; }
.notfound-code {
  font-family: var(--mono); font-size: clamp(4rem, 11vw, 7rem); font-weight: 600;
  letter-spacing: -0.02em; line-height: 1; color: var(--text);
}
.notfound-code .accent-word { color: var(--coral); }
.notfound h1 { font-size: 1.4rem; margin: 18px 0 8px; letter-spacing: -0.02em; }
.notfound .mono-sub { font-family: var(--mono); font-size: 12px; color: var(--text-dim); letter-spacing: .08em; }
.notfound-actions { display: flex; gap: 14px; justify-content: center; margin-top: 32px; flex-wrap: wrap; }

/* ---------- reveal ---------- */
/* Hidden only when JS is available (and adds .visible); no-JS users see all content. */
.js .reveal { opacity: 0; transform: translateY(18px); transition: opacity .6s ease, transform .6s ease; }
.js .reveal.visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .js .reveal { opacity: 1; transform: none; }
  html { scroll-behavior: auto; }
}

/* ---------- responsive ---------- */
@media (max-width: 940px) {
  .hero-grid { grid-template-columns: 1fr; gap: 64px; }
  .hero { padding: 64px 0 76px; }
  .hero-visual { min-height: 380px; }
  .steps, .feature-grid, .post-row { grid-template-columns: 1fr 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .build-grid { grid-template-columns: 1fr; }
  .build-doc { border-right: 0; border-bottom: 1px solid var(--border-subtle); }
}
@media (max-width: 720px) {
  .site-nav {
    position: absolute; top: 100%; left: 0; right: 0; flex-direction: column; align-items: stretch;
    background: var(--bg); border-bottom: 1px solid var(--border); padding: 20px 5%;
    display: none; gap: 18px;
  }
  .site-nav.open { display: flex; }
  .nav-toggle { display: block; }
  .ha-label { display: none; }
  .header-account { height: 44px; padding: 0 11px; }
  .header-signout { min-height: 44px; }
  .steps, .feature-grid, .post-row { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 28px; }
  .section { padding: 62px 0; }
  .article-cta { flex-direction: column; text-align: center; }
  .build-pipeline { padding: 26px 22px; }
  .chip-5 { left: 8%; }
  .demo-video { margin-bottom: 36px; }
  .demo-video-play { width: 58px; height: 58px; }
  .btn { height: 44px; }
  .btn-large { height: 50px; }
}

/* ============ SEO & a11y polish ============ */
.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;
}

/* hero mini-generator (SXO: get the user into the tool from the hero) */
.hero-mini { display: flex; gap: 10px; flex-wrap: wrap; margin: 4px 0 12px; max-width: 640px; }
.hero-mini input[type="text"], .hero-mini select {
  background: var(--bg); border: 1px solid var(--border); color: var(--text);
  font-family: var(--grotesk); font-size: .95rem; padding: 14px 16px; min-width: 0;
}
.hero-mini input[type="text"] { flex: 1 1 240px; }
.hero-mini select { flex: 0 1 190px; }
.hero-mini input:focus, .hero-mini select:focus { outline: none; border-color: var(--coral); }
.hero-mini .btn { height: 52px; }
.hero-mini-note { font-family: var(--mono); font-size: 11px; color: var(--text-dim); margin: 0 0 14px; letter-spacing: .04em; }

/* micro-typography floor + 44px tap targets */
.hero-badge { font-size: 11px; }
.tag, .section-tag, .step-num, .feature-idx { font-size: 11px; }
.site-nav a { min-height: 44px; display: inline-flex; align-items: center; padding: 0 4px; }
.breadcrumbs li, .breadcrumbs a, .breadcrumbs li > span { min-height: 36px; display: inline-flex; align-items: center; }
.breadcrumbs a { padding: 0 2px; }
.subject-chip { padding: 12px 18px; font-size: 11.5px; }
.build-top .mono-label, .build-top .live, .build-pages, .build-pct-row { font-size: 11px; }
.field label { font-size: 11px; }
.wizard-note, .result-tip { font-size: 11px; }
.site-footer h3 { font-size: 11px; }
.site-footer nav a { padding: 10px 0; display: inline-flex; align-items: center; min-height: 36px; }
.footer-contact { margin-top: 12px; }
.footer-contact a { color: var(--coral); font-family: var(--mono); font-size: 12px; word-break: break-all; display: inline-flex; align-items: center; min-height: 44px; }

/* LCP: hero entrance animation must not delay above-the-fold text paint */
.hero-copy .animate-in, .hero-mini.animate-in, .hero-mini-note.animate-in { animation: none !important; opacity: 1; transform: none; }

/* Allow long checkbox labels on the generator to wrap so nothing overflows
   the 375px mobile viewport */
label.check { overflow-wrap: anywhere; word-break: normal; }

/* Home blog teaser: link to all guides below the featured cards */
.blog-view-all { margin-top: 20px; text-align: center; }
.blog-view-all a { color: var(--coral); font-family: var(--mono); font-size: 13px; letter-spacing: .08em; text-transform: uppercase; padding: 8px 10px; min-height: 36px; display: inline-flex; align-items: center; }
.blog-view-all a:hover { color: var(--text); }
.site-footer nav a { padding: 4px 0; display: inline-block; }

/* proof / testimonial section on the homepage */
.proof-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--border); border: 1px solid var(--border); }
.proof-item { background: var(--surface); padding: 32px 28px; }
.proof-item h3 { font-size: 1rem; line-height: 1.5; letter-spacing: -0.01em; margin-bottom: 10px; }
.proof-item p { color: var(--text-muted); font-size: .9rem; line-height: 1.7; }
.proof-sheet { background: #0c0c0c; border: 1px solid var(--border); padding: 16px; margin-bottom: 18px; min-height: 140px; }
.proof-sheet .mock-school { height: 9px; width: 55%; margin: 4px auto 12px; }
.proof-sheet .mock-logo { width: 44px; height: 44px; margin: 12px auto 16px; }
.proof-sheet .mock-title { height: 11px; width: 80%; margin: 0 auto 14px; }
.proof-sheet .mock-line { height: 6px; }

/* article meta + related guides */
.article-meta { font-family: var(--mono); color: var(--text-dim); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; margin-top: 10px; display: flex; gap: 8px; flex-wrap: wrap; }
.article-meta time { color: var(--coral); }
.related-guides { margin-top: 64px; }
.related-guides h2 { font-size: 1.5rem; margin-bottom: 24px; letter-spacing: -0.02em; }

/* post cards that show a cover image */
.post-card-cover { width: 100%; height: auto; border: 1px solid var(--border); margin-bottom: 6px; }

/* tool page info content */
.tool-checklist { list-style: none; margin: 0 0 44px; padding: 0; display: grid; gap: 10px; }
.tool-checklist li {
  background: var(--surface); border: 1px solid var(--border); border-left: 2px solid var(--coral);
  padding: 14px 18px; font-size: .95rem; line-height: 1.65; color: var(--text-muted);
}
.tool-checklist strong { color: var(--text); }
.tool-info > .container > p { color: var(--text-muted); line-height: 1.8; margin-bottom: 14px; }

@media (max-width: 940px) { .proof-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 720px) {
  .proof-grid { grid-template-columns: 1fr; }
  .hero-mini { flex-direction: column; }
  .hero-mini input[type="text"] { flex: 1 1 auto; }
  .hero-mini select { flex: 1 1 auto; }
  .hero-mini .btn { width: 100%; }
  .field input[type="text"], .field input[type="email"], .field select, .field textarea { font-size: 16px; }
}

/* ---------- front page design picker ---------- */
.fp-step legend { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.adv-badge {
  font-family: var(--mono); font-size: 9.5px; font-weight: 500; letter-spacing: .14em;
  text-transform: uppercase; color: var(--text-muted);
  border: 1px solid var(--border); background: var(--bg); padding: 4px 9px;
}
.step-hint { color: var(--text-muted); font-size: .85rem; line-height: 1.6; margin: 12px 0 4px; }
.fp-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin-top: 18px; }
.fp-card {
  position: relative; display: flex; flex-direction: column;
  border: 1px solid var(--border); background: var(--bg); padding: 11px; cursor: pointer;
  transition: border-color .15s ease, box-shadow .15s ease, transform .15s ease;
}
.fp-card:hover { border-color: #4a4a4a; transform: translateY(-2px); }
.fp-card input { position: absolute; opacity: 0; width: 1px; height: 1px; margin: 0; pointer-events: none; }
.fp-card:has(input:checked) { border-color: var(--coral); box-shadow: 0 0 0 1px var(--coral); }
.fp-card:focus-within { border-color: var(--coral); }
.fp-preview {
  display: flex; flex-direction: column; gap: 5px;
  aspect-ratio: 1 / 1.32; overflow: hidden;
  background: #f6f5ef; border: 1px solid #dedcd3; padding: 13% 12%;
}
.fp-preview i { display: block; flex: none; background: #c9c7be; }
.fp-preview .t { height: 10px; background: #8f8d83; }
.fp-preview .b { height: 6px; background: #c4c2b9; }
.fp-preview .r { height: 2px; background: #2b2b2b; }
.fp-preview .r.thin { height: 1px; background: #9a988f; }
.fp-preview .u { height: 2px; background: #cfcdc4; }
.fp-card input:checked ~ .fp-preview { box-shadow: inset 0 0 0 2px var(--coral); }
.fp-preview .bar { height: 4px; background: #1f3a5f; }
.fp-preview .c { margin-left: auto; margin-right: auto; }
.fp-preview .w30 { width: 30%; } .fp-preview .w40 { width: 40%; } .fp-preview .w50 { width: 50%; }
.fp-preview .w60 { width: 60%; } .fp-preview .w70 { width: 70%; } .fp-preview .w80 { width: 80%; }
.fp-preview .sp { flex: 1 1 auto; }
.fp-preview .hdr { display: flex; flex-direction: column; gap: 5px; background: #1f3a5f; padding: 8px 7px; }
.fp-preview .hdr i { background: rgba(255,255,255,.85); height: 6px; }
.fp-preview .boxed { display: block; border: 1.5px solid #8a6d3b; padding: 6px; }
.fp-preview .tbl { display: block; border: 1px solid #b9b7ae; }
.fp-preview .tbl i { display: block; height: 9px; border-bottom: 1px solid #e0ded5; background: transparent; }
.fp-preview .tbl i:last-child { border-bottom: 0; }

/* Illustrated covers: notebook (elegant) and science-lab (academic) previews. */
.fp-preview.has-note {
  background:
    radial-gradient(circle at 0% 0%, #d9c8f0 0 20%, rgba(217,200,240,0) 42%),
    radial-gradient(circle at 100% 0%, #f9c6dd 0 20%, rgba(249,198,221,0) 42%),
    radial-gradient(circle at 0% 100%, #f7e08a 0 18%, rgba(247,224,138,0) 40%),
    radial-gradient(circle at 100% 100%, #aedaf7 0 18%, rgba(174,218,247,0) 40%),
    #ffffff;
  border-color: #e6ddf2;
}
.fp-preview .script { background: #2b2530; height: 11px; }
.fp-preview .rib { display: block; height: 11px; background: #7c5ab0; border-radius: 2px; }
.fp-preview .card {
  display: block; border: 1.4px solid #7c5ab0; border-radius: 4px;
  background: #ffffff; padding: 6px 7px;
}
.fp-preview .card i { height: 2px; background: #cdc6dc; margin: 4px 0; }

.fp-preview.has-lab {
  background:
    radial-gradient(circle at 100% 0%, #d7ecdf 0 26%, rgba(215,236,223,0) 56%),
    radial-gradient(circle at 0% 100%, #dcefe4 0 24%, rgba(220,239,228,0) 54%),
    #ffffff;
  border-color: #cfe6da;
}
.fp-preview .mintbar { height: 3px; background: #2f7d5b; }
.fp-preview .mintbox {
  display: block; border: 1.3px solid #2f7d5b; border-radius: 3px;
  background: #eaf6ef; padding: 6px 7px;
}
.fp-preview .mintbox i { height: 2px; background: #b7ddc9; margin: 4px 0; }

/* Illustrated covers: doodle notebook (bold) and framed report (minimal). */
.fp-preview.has-doodle {
  background:
    radial-gradient(circle at 0% 0%, #bcd7ea 0 22%, rgba(188,215,234,0) 46%),
    radial-gradient(circle at 100% 0%, #f7e08a 0 22%, rgba(247,224,138,0) 46%),
    radial-gradient(circle at 0% 100%, #bfe8d2 0 20%, rgba(191,232,210,0) 44%),
    radial-gradient(circle at 100% 100%, #f9cfa8 0 20%, rgba(249,207,168,0) 44%),
    #fffdf7;
  border-color: #ece5d3;
}
.fp-preview .dlogo {
  width: 20%; aspect-ratio: 1 / 1; margin: 3px auto 1px;
  border: 1px dashed #c9a24b; border-radius: 4px; background: #fffdf3;
}
.fp-preview .rainbow {
  height: 10px; border-radius: 2px;
  background: linear-gradient(90deg, #e8590c, #1c7ed6, #2f9e44, #d6336c, #f08c00, #6741d9, #0ca678);
}
.fp-preview .doodlecard {
  display: block; border: 2px dashed #c9a24b; border-radius: 5px;
  background: #fffdf3; padding: 7px 8px;
}
.fp-preview .doodlecard i { height: 3px; background: #ded8c4; margin: 5px 0; }
.fp-preview .doodlecard i:first-child { background: #8f8d83; }

.fp-preview.has-frame {
  background:
    radial-gradient(circle at 100% 0%, #dbeae5 0 24%, rgba(219,234,229,0) 50%),
    radial-gradient(circle at 0% 100%, #f3e2c8 0 22%, rgba(243,226,200,0) 48%),
    #ffffff;
  border-color: #d3e2dd;
}
.fp-preview .grid2 {
  display: grid; grid-template-columns: 1fr 1fr;
  border: 1px solid #9fb2ac; border-radius: 2px; overflow: hidden; background: #ffffff;
}
.fp-preview .grid2 i { height: 12px; background: #eef4f2; border-bottom: 1px solid #d8e2df; border-right: 1px solid #d8e2df; }
.fp-preview .grid2 i:nth-child(2n) { border-right: 0; }
.fp-preview .grid2 i:nth-child(n+5) { border-bottom: 0; }
.fp-name {
  font-family: var(--mono); font-size: 10.5px; font-weight: 500; letter-spacing: .1em;
  text-transform: uppercase; color: var(--text); margin-top: 10px;
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
}
.fp-name em { font-style: normal; color: var(--coral); border: 1px solid var(--border); padding: 2px 7px; font-size: 9px; letter-spacing: .12em; }
.fp-desc { font-size: .74rem; color: var(--text-muted); line-height: 1.45; margin-top: 4px; }

@media (max-width: 720px) { .fp-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 460px) { .fp-grid { grid-template-columns: 1fr; } }

/* ===== Customize (login popup) + AI button ===== */
.btn-customize {
  position: relative; overflow: hidden;
  background: linear-gradient(120deg, #1d1d1d, #242424 45%, #2b1d17);
  border: 1px solid rgba(224,120,80,.55); color: var(--text);
}
.btn-customize:hover { border-color: var(--orange); color: #fff; }
.btn-customize .ai-spark {
  display: inline-grid; place-items: center; width: 26px; height: 26px; border-radius: 8px;
  background: radial-gradient(circle at 30% 30%, #ff8a3d, #e07850 62%, #a8451f); color: #fff;
  box-shadow: 0 0 12px rgba(224,120,80,.6); animation: aiSpark 2.4s ease-in-out infinite;
}
@keyframes aiSpark { 0%,100% { box-shadow: 0 0 8px rgba(224,120,80,.4); } 50% { box-shadow: 0 0 18px rgba(255,107,53,.85); } }
@media (prefers-reduced-motion: reduce) { .btn-customize .ai-spark { animation: none; } }

.ps-modal { position: fixed; inset: 0; z-index: 200; display: grid; place-items: center; padding: 20px; }
.ps-modal[hidden] { display: none !important; }
.ps-modal-bg { position: absolute; inset: 0; background: rgba(5,5,5,.74); backdrop-filter: blur(4px); animation: psFade .18s ease; }
.ps-modal-card { position: relative; width: min(424px, 100%); background: #131313; border: 1px solid #2b2b2b; border-radius: 18px; padding: 30px 28px; box-shadow: 0 40px 90px rgba(0,0,0,.7); animation: psPop .22s cubic-bezier(.2,.8,.3,1); }
.ps-modal-card h2 { font-size: 21px; margin: 12px 0 6px; }
.ps-modal-x { position: absolute; top: 12px; right: 12px; width: 34px; height: 34px; border: 0; border-radius: 9px; background: transparent; color: #9a9a94; font-size: 22px; line-height: 1; cursor: pointer; }
.ps-modal-x:hover { background: #1f1f1f; color: #fff; }
.ps-modal-badge { display: inline-block; font-size: 12px; letter-spacing: .12em; text-transform: uppercase; color: var(--coral); font-weight: 700; }
.ps-modal-badge b { color: #fff; }
.ps-lead { color: var(--text-muted); font-size: 13.5px; line-height: 1.6; margin-bottom: 16px; }
.ps-modal-card label { display: block; font-size: 12px; letter-spacing: .06em; text-transform: uppercase; color: var(--text-dim); margin-bottom: 7px; }
.ps-modal-card input[type="email"], .ps-modal-card input[type="password"], .ps-modal-card input[type="text"] {
  width: 100%; background: #0b0b0b; border: 1px solid #2d2d2d; border-radius: 10px; padding: 12px 13px; color: #fff; font: inherit; font-size: 15px; margin-bottom: 12px;
}
.ps-modal-card input:focus { outline: none; border-color: var(--coral); box-shadow: 0 0 0 3px rgba(224,120,80,.16); }
.ps-note { font-size: 11.5px; color: var(--text-muted); margin-top: 12px; }
.ps-err { color: #f87171; font-size: 12.5px; margin: -4px 0 10px; }
.ps-captcha { margin: 4px 0 12px; }
.ps-modal-foot { display: flex; justify-content: space-between; align-items: center; margin-top: 14px; }
.ps-link { background: none; border: 0; color: var(--text-muted); font: inherit; font-size: 12.5px; cursor: pointer; padding: 0; }
.ps-link:hover { color: var(--coral); }
.ps-check { width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; background: rgba(74,222,128,.15); color: var(--green); margin-bottom: 6px; }
.ps-step[hidden] { display: none; }
.ps-note em { color: var(--coral); font-style: normal; }
@keyframes psFade { from { opacity: 0; } to { opacity: 1; } }
@keyframes psPop { from { opacity: 0; transform: translateY(14px) scale(.98); } to { opacity: 1; transform: none; } }
body.ps-modal-open { overflow: hidden; }

