/* ---------------------------------------------------------------------------
   Design tokens

   Taken from the approved design. The mockup expressed its tracking in fixed
   pixels (`letter-spacing:-3.5px` on a heading that clamps from 70px down to
   40px); those are converted to `em` here at the ratio the design used at its
   reference size, so the same tightness holds instead of turning into a crush
   at the small end of the clamp.
   --------------------------------------------------------------------------- */
:root {
  --ink: #13243a;
  --muted: #62748a;
  --blue: #3767f6;
  --blue2: #5b8cff;
  --mint: #20c997;
  --line: #dce6f0;
  --soft: #f5f9ff;
  --dark: #172540;
  --darker: #101c31;
  --shadow: 0 18px 55px rgba(30, 72, 130, .13);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.65;
  background: #fff;
}

a { color: inherit; text-decoration: none; }
button { cursor: pointer; font-family: inherit; }

.wrap { width: min(1120px, calc(100% - 40px)); margin: auto; }

/* ---------------------------------------------------------------------------
   Header
   --------------------------------------------------------------------------- */
.nav { height: 74px; display: flex; align-items: center; justify-content: space-between; gap: 20px; }

.brand { font-weight: 850; font-size: 21px; letter-spacing: -.028em; white-space: nowrap; }
.brand i { font-style: normal; color: var(--blue); }

.links { display: flex; gap: 28px; color: #53657a; font-size: 14px; }
.links a:hover { color: var(--blue); }

/* Inner pages have no hero to sit on, so the bar carries the hero's own tint
   and edge instead of floating on bare white. */
.topbar { background: var(--soft); border-bottom: 1px solid #eaf0f7; }

/* The bar is not sticky, so an in-page anchor needs only enough offset to keep
   the target heading off the very top edge of the viewport. */
section[id], #tool { scroll-margin-top: 20px; }

/* ---------------------------------------------------------------------------
   Hero
   --------------------------------------------------------------------------- */
.hero {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(circle at 80% 10%, #c9fff0 0, transparent 28%),
    linear-gradient(150deg, #f5f9ff 0, #fff 55%, #eefcf8 100%);
  border-bottom: 1px solid #eaf0f7;
}

.hero::before {
  content: "";
  position: absolute;
  width: 430px;
  height: 430px;
  border: 75px solid rgba(55, 103, 246, .06);
  border-radius: 50%;
  top: 60px;
  right: -150px;
  pointer-events: none;
}

.hero-inner { position: relative; padding: 84px 0 96px; text-align: center; }

.eyebrow {
  display: inline-flex;
  gap: 8px;
  align-items: center;
  padding: 7px 13px;
  border: 1px solid #cfe0ff;
  border-radius: 999px;
  background: #fff;
  color: #3862c7;
  font-weight: 700;
  font-size: 13px;
}
.eyebrow::before {
  content: "";
  width: 8px;
  height: 8px;
  background: var(--mint);
  border-radius: 50%;
  box-shadow: 0 0 0 4px #d9f8ee;
}

h1 {
  font-size: clamp(42px, 6vw, 70px);
  letter-spacing: -.05em;
  line-height: 1.05;
  margin: 22px auto 18px;
  max-width: 900px;
}
h1 span { color: var(--blue); }

.lead { max-width: 720px; margin: 0 auto 32px; font-size: 18px; color: var(--muted); }

/* ---------------------------------------------------------------------------
   Downloader form
   --------------------------------------------------------------------------- */
.downloader {
  max-width: 830px;
  margin: auto;
  padding: 10px;
  background: #fff;
  border: 1px solid #d7e3f3;
  border-radius: 18px;
  display: flex;
  gap: 10px;
  box-shadow: var(--shadow);
}
.downloader:focus-within { border-color: #b9d0f7; }

.downloader input {
  flex: 1;
  border: 0;
  outline: 0;
  padding: 15px 17px;
  font-size: 16px;
  font-family: inherit;
  color: var(--ink);
  min-width: 0;
  background: transparent;
}
.downloader input::placeholder { color: #90a2b6; }

.paste {
  border: 0;
  background: #eef4ff;
  color: #315dc8;
  padding: 0 18px;
  border-radius: 11px;
  font-weight: 750;
  font-size: 14px;
}
.paste:hover { background: #e2ecff; }

.download {
  border: 0;
  background: linear-gradient(135deg, var(--blue), var(--blue2));
  color: #fff;
  padding: 0 27px;
  border-radius: 11px;
  font-weight: 800;
  font-size: 15px;
  box-shadow: 0 8px 22px rgba(55, 103, 246, .25);
  transition: transform .15s ease;
}
.download:hover:not(:disabled) { transform: translateY(-1px); }
.download:disabled { opacity: .6; cursor: progress; transform: none; }

.micro { font-size: 12px; color: #8494a8; margin-top: 13px; }

.trust { display: flex; justify-content: center; gap: 28px; margin-top: 30px; color: #5f7186; font-size: 13px; }
.trust span::before { content: "✓"; color: #0eaf7e; font-weight: 900; margin-right: 7px; }

/* ---------------------------------------------------------------------------
   Result panel

   Written by public/assets/app.js after a resolve. Everything here is on the
   hero's pale gradient, so the card is white-on-light rather than the inverted
   treatment the rest of the page uses for dark blocks.
   --------------------------------------------------------------------------- */
.result { max-width: 830px; margin: 22px auto 0; text-align: left; }

.result-message {
  padding: 16px 18px;
  border-radius: 14px;
  font-size: 14px;
  line-height: 1.6;
  border: 1px solid var(--line);
  background: #fff;
  color: #4c5f75;
}
.result-message b { color: var(--ink); font-weight: 750; }
.result-message.is-busy { border-color: #bfe7dc; background: #f2fdfa; color: #14705f; }
.result-message.is-error { border-color: #f6cfd7; background: #fff5f7; color: #a32741; }

.result-card {
  display: grid;
  grid-template-columns: 168px 1fr;
  gap: 24px;
  padding: 22px;
  border-radius: 20px;
  background: #fff;
  border: 1px solid #d7e3f3;
  box-shadow: var(--shadow);
}

.result-media { border-radius: 14px; overflow: hidden; background: #eaf1fa; aspect-ratio: 9/16; }
.result-media video, .result-media img { width: 100%; height: 100%; object-fit: cover; display: block; }

.result-body { min-width: 0; display: flex; flex-direction: column; }
.result-caption { margin: 0 0 6px; font-size: 15px; line-height: 1.5; overflow-wrap: anywhere; }
.result-meta { margin: 0 0 18px; font-size: 12.5px; color: #7d8fa4; display: flex; flex-wrap: wrap; gap: 6px 14px; }

.result-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: auto; }

.action {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 13px 18px;
  font-size: 14px;
  font-weight: 800;
  font-family: inherit;
  background: #f4f8fe;
  color: #2c4363;
  transition: transform .15s ease, background .15s ease;
}
.action:hover:not(:disabled):not([aria-disabled="true"]) { transform: translateY(-1px); background: #eaf2fd; }
/* A link cannot be :disabled, and the MP4 action is a link — it stays a real
   download target for right-click and long-press — so it says so out loud
   instead, for the seconds it spends preparing the file. */
.action:disabled, .action[aria-disabled="true"] { opacity: .55; cursor: progress; transform: none; }
.action small { font-weight: 600; opacity: .75; }

.action-primary {
  border-color: transparent;
  background: linear-gradient(135deg, var(--blue), var(--blue2));
  color: #fff;
  box-shadow: 0 10px 26px rgba(55, 103, 246, .24);
}
.action-primary:hover:not(:disabled):not([aria-disabled="true"]) { background: linear-gradient(135deg, #2c5cf0, #4f83ff); }

.action-audio { border-color: transparent; background: linear-gradient(135deg, var(--mint), #46ddb0); color: #06342a; }
.action-audio:hover:not(:disabled) { background: linear-gradient(135deg, #17bd8d, #38d6a7); }

.result-note { margin: 14px 0 0; font-size: 12px; color: #8494a8; line-height: 1.6; }

.progress { margin-top: 14px; height: 6px; border-radius: 99px; background: #e6eefa; overflow: hidden; }
.progress > i { display: block; height: 100%; width: 0; border-radius: 99px; background: linear-gradient(90deg, var(--blue), var(--mint)); transition: width .2s ease; }
.progress-label { margin: 8px 0 0; font-size: 12px; color: #7d8fa4; }
.progress-label a { color: var(--blue); font-weight: 700; }

.result-gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 10px; margin-top: 16px; }
.result-gallery a { display: block; border-radius: 10px; overflow: hidden; border: 1px solid var(--line); aspect-ratio: 3/4; }
.result-gallery img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* ---------------------------------------------------------------------------
   Sections
   --------------------------------------------------------------------------- */
.section { padding: 92px 0; }
.section.alt { background: var(--soft); }

.section-head { text-align: center; max-width: 720px; margin: 0 auto 50px; }
.kicker { color: var(--blue); font-weight: 800; font-size: 13px; text-transform: uppercase; letter-spacing: .09em; }
.section h2 { font-size: clamp(30px, 4vw, 44px); line-height: 1.15; letter-spacing: -.04em; margin: 9px 0 16px; }
.section-head p, .feature p, .step p, .copy p, .faq p { color: var(--muted); }

.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.step { padding: 28px; background: #fff; border: 1px solid var(--line); border-radius: 18px; }
.num { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 13px; background: #eaf0ff; color: var(--blue); font-weight: 850; }
.step h3 { margin: 18px 0 7px; }
.step p { margin: 0; }

.features { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.feature { padding: 27px; border: 1px solid var(--line); border-radius: 20px; background: #fff; transition: transform .2s ease, box-shadow .2s ease; }
.feature:hover { transform: translateY(-4px); box-shadow: 0 16px 36px rgba(27, 68, 121, .09); }
.icon { display: grid; place-items: center; width: 46px; height: 46px; border-radius: 14px; background: linear-gradient(135deg, #eaf0ff, #e7fbf5); font-size: 21px; font-weight: 800; color: #2f4f86; }
.feature h3 { margin: 17px 0 7px; }
.feature p { margin: 0; font-size: 14px; }

.split { display: grid; grid-template-columns: 1fr 1fr; gap: 70px; align-items: center; }

.mock { padding: 28px; border-radius: 28px; background: linear-gradient(150deg, #dfe9ff, #dffaf2); min-height: 390px; display: grid; place-items: center; }
.phone { width: 220px; background: #18243a; border-radius: 32px; padding: 10px; box-shadow: 0 30px 60px rgba(28, 53, 90, .25); transform: rotate(3deg); }
.screen { background: #fff; border-radius: 24px; padding: 22px 15px; height: 370px; }
.video { height: 190px; border-radius: 15px; background: linear-gradient(140deg, #3850a0, #26c69b); position: relative; }
.play { position: absolute; inset: 0; margin: auto; width: 48px; height: 48px; border-radius: 50%; background: #fff; display: grid; place-items: center; color: var(--blue); }
.bar { height: 10px; background: #e8eef6; border-radius: 10px; margin-top: 16px; }
.bar.short { width: 62%; }
.mini-btn { margin-top: 22px; padding: 11px; text-align: center; border-radius: 10px; background: var(--blue); color: #fff; font-size: 12px; font-weight: 800; }

.copy h2 { margin-top: 0; }
.copy ul { padding: 0; list-style: none; margin: 18px 0 0; }
.copy li { padding: 9px 0; color: #506278; }
.copy li::before {
  content: "✓";
  display: inline-grid;
  place-items: center;
  width: 22px;
  height: 22px;
  background: #dcf8ef;
  color: #0ea879;
  border-radius: 50%;
  font-weight: 900;
  margin-right: 10px;
}

/* ---------------------------------------------------------------------------
   FAQ

   `<details>` rather than a button plus a class toggle: the answers are then in
   the DOM for a crawler with no JavaScript, and the site ships a strict CSP
   with no `'unsafe-inline'`, which the mockup's inline toggle script could not
   have run under anyway.
   --------------------------------------------------------------------------- */
.faq-wrap { max-width: 830px; margin: auto; }

.faq { border-bottom: 1px solid var(--line); }
.faq summary {
  list-style: none;
  cursor: pointer;
  padding: 22px 0;
  font-weight: 800;
  color: var(--ink);
  display: flex;
  justify-content: space-between;
  gap: 20px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--blue); font-size: 24px; line-height: 1.1; }
.faq[open] summary::after { content: "−"; }
.faq p { margin: 0; padding: 0 40px 22px 0; }

/* ---------------------------------------------------------------------------
   Final call to action
   --------------------------------------------------------------------------- */
.final { padding: 80px 0; text-align: center; background: var(--dark); color: #fff; }
.final h2 { font-size: clamp(30px, 4vw, 40px); letter-spacing: -.035em; margin: 0 0 12px; }
.final p { color: #bdc9d9; max-width: 600px; margin: 0 auto 26px; }
.cta { display: inline-block; padding: 14px 24px; background: var(--mint); color: #06342a; border-radius: 12px; font-weight: 850; transition: transform .15s ease; }
.cta:hover { transform: translateY(-1px); }

/* ---------------------------------------------------------------------------
   Footer
   --------------------------------------------------------------------------- */
.footer { background: var(--darker); color: #92a3b9; padding: 28px 0; font-size: 13px; }
.footer .wrap { display: flex; justify-content: space-between; gap: 20px; }
.footer nav { display: flex; gap: 18px; flex-wrap: wrap; }
.footer a:hover { color: #fff; }

/* ---------------------------------------------------------------------------
   Static content pages (privacy / terms / contact / 404)
   --------------------------------------------------------------------------- */
.prose { max-width: 760px; margin: auto; padding: 72px 0 96px; }
.prose h1 { font-size: clamp(32px, 5vw, 46px); letter-spacing: -.04em; line-height: 1.12; margin: 0 0 10px; }
.prose .updated { color: var(--muted); font-size: 13px; margin: 0 0 40px; }
.prose h2 { font-size: 21px; letter-spacing: -.025em; margin: 40px 0 12px; }
.prose p, .prose li { color: var(--muted); font-size: 15px; line-height: 1.8; }
.prose ul { padding-left: 20px; }
.prose b { color: var(--ink); }
.prose a { color: var(--blue); font-weight: 600; }
.prose a:hover { text-decoration: underline; }

.notfound { text-align: center; padding: 120px 0 130px; }
.notfound h1 { font-size: clamp(60px, 12vw, 118px); letter-spacing: -.06em; line-height: 1; margin: 0; color: var(--blue); }
.notfound p { color: var(--muted); margin: 12px 0 32px; }
.notfound a {
  display: inline-block;
  background: linear-gradient(135deg, var(--blue), var(--blue2));
  color: #fff;
  font-weight: 800;
  padding: 15px 28px;
  border-radius: 12px;
  box-shadow: 0 12px 30px rgba(55, 103, 246, .24);
}

/* ---------------------------------------------------------------------------
   Blog (CMS-backed: /blog and /blog/{slug})

   Same 760px measure and rhythm as `.prose`, so an article and the privacy page
   read as one site. The index is wider because it is a grid.
   --------------------------------------------------------------------------- */
.blog-index { padding: 72px 0 96px; }
.blog-index h1 { font-size: clamp(32px, 5vw, 46px); letter-spacing: -.04em; line-height: 1.12; margin: 10px 0 10px; }
.blog-lead { color: var(--muted); font-size: 16px; max-width: 620px; margin: 0 0 48px; }
.blog-empty { color: var(--muted); font-size: 15px; }
.blog-empty a { color: var(--blue); font-weight: 600; }

.blog-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; }

.blog-card {
  display: flex;
  flex-direction: column;
  height: 100%;
  border: 1px solid var(--line);
  border-radius: 20px;
  overflow: hidden;
  background: #fff;
  transition: transform .18s ease, box-shadow .18s ease;
}
.blog-card:hover { transform: translateY(-4px); box-shadow: 0 16px 36px rgba(27, 68, 121, .09); }

/* A fixed aspect ratio keeps the grid rows aligned whatever the CMS uploads. */
.blog-card-art { width: 100%; aspect-ratio: 16/9; object-fit: cover; display: block; background: var(--line); }
.blog-card-art-empty {
  display: grid;
  place-items: center;
  background: linear-gradient(150deg, #dfe9ff, #dffaf2);
  color: var(--blue);
  font-size: 34px;
  font-weight: 900;
}

.blog-card-body { padding: 22px 22px 24px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.blog-card-body h2 { font-size: 19px; letter-spacing: -.025em; line-height: 1.3; margin: 2px 0 0; }
.blog-card-body p { color: var(--muted); font-size: 14px; line-height: 1.65; margin: 0; }
.blog-card-body small { color: #8494a8; font-size: 12px; margin-top: auto; padding-top: 10px; }

.blog-article { max-width: 760px; margin: auto; padding: 56px 0 96px; }
.blog-back { display: inline-block; color: var(--muted); font-size: 13px; font-weight: 600; margin-bottom: 26px; }
.blog-back:hover { color: var(--blue); }
.blog-article > .kicker { display: block; }
.blog-article h1 { font-size: clamp(30px, 4.4vw, 44px); letter-spacing: -.04em; line-height: 1.15; margin: 10px 0 10px; }
.blog-meta { color: var(--muted); font-size: 13px; margin: 0 0 36px; }
.blog-meta span { margin: 0 6px; color: var(--line); }

.blog-draft-flag {
  display: inline-block;
  background: var(--blue);
  color: #fff;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .1em;
  text-transform: uppercase;
  padding: 7px 13px;
  border-radius: 999px;
  margin: 0 0 22px;
}

.blog-hero { width: 100%; border-radius: 20px; margin: 0 0 40px; display: block; }

/* `.blog-content` is trusted CMS HTML, so it is styled by element rather than
   by class — the editor cannot be asked to remember class names. */
.blog-content { color: var(--muted); font-size: 16px; line-height: 1.85; }
.blog-content h2 { color: var(--ink); font-size: 25px; letter-spacing: -.03em; margin: 46px 0 12px; }
.blog-content h3 { color: var(--ink); font-size: 19px; letter-spacing: -.02em; margin: 34px 0 10px; }
.blog-content p { margin: 0 0 20px; }
.blog-content ul, .blog-content ol { padding-left: 22px; margin: 0 0 20px; }
.blog-content li { margin-bottom: 9px; }
.blog-content a { color: var(--blue); font-weight: 600; }
.blog-content a:hover { text-decoration: underline; }
.blog-content img { max-width: 100%; height: auto; border-radius: 16px; margin: 12px 0 24px; display: block; }
.blog-content strong, .blog-content b { color: var(--ink); }
.blog-content blockquote { margin: 26px 0; padding: 4px 0 4px 22px; border-left: 3px solid var(--mint); color: var(--ink); font-style: italic; }
.blog-content pre { background: var(--dark); color: #e7eefb; padding: 20px; border-radius: 14px; overflow-x: auto; font-size: 13px; line-height: 1.6; }
.blog-content code { font-size: 13px; background: #eaf1fa; border-radius: 6px; padding: 2px 6px; }
.blog-content pre code { background: none; padding: 0; }
.blog-content table { width: 100%; border-collapse: collapse; margin: 0 0 24px; font-size: 14px; }
.blog-content th, .blog-content td { border: 1px solid var(--line); padding: 10px 12px; text-align: left; }
.blog-content th { color: var(--ink); background: var(--soft); }
.blog-content hr { border: 0; border-top: 1px solid var(--line); margin: 40px 0; }

.blog-author { display: flex; gap: 16px; align-items: flex-start; margin-top: 56px; padding-top: 30px; border-top: 1px solid var(--line); }
.blog-author img { width: 52px; height: 52px; border-radius: 50%; object-fit: cover; flex: none; }
.blog-author b { font-size: 15px; letter-spacing: -.01em; }
.blog-author p { color: var(--muted); font-size: 14px; line-height: 1.7; margin: 5px 0 0; }

/* ---------------------------------------------------------------------------
   Responsive
   --------------------------------------------------------------------------- */
@media (max-width: 800px) {
  .links { display: none; }
  .hero-inner { padding: 58px 0 72px; }
  h1 { letter-spacing: -.04em; }
  .downloader { display: grid; grid-template-columns: 1fr auto; }
  .download { grid-column: 1/-1; height: 52px; }
  .trust { flex-wrap: wrap; gap: 10px 18px; }
  .section { padding: 70px 0; }
  .steps, .features { grid-template-columns: 1fr; }
  .split { grid-template-columns: 1fr; gap: 35px; }
  .mock { order: 2; }
  .blog-list { grid-template-columns: repeat(2, 1fr); }
  .footer .wrap { display: block; }
  .footer nav { margin-top: 12px; }
}

@media (max-width: 620px) {
  .result-card { grid-template-columns: 1fr; }
  .result-media { max-width: 200px; margin: 0 auto; }
  .result-actions .action { flex: 1 1 100%; justify-content: center; }
  .blog-list { grid-template-columns: 1fr; gap: 20px; }
  .blog-index { padding: 48px 0 72px; }
  .blog-article { padding: 40px 0 72px; }
  .blog-content { font-size: 15px; }
  .blog-hero { border-radius: 14px; margin-bottom: 30px; }
  .prose { padding: 52px 0 76px; }
  .notfound { padding: 90px 0 100px; }
}

@media (max-width: 430px) {
  .wrap { width: min(100% - 24px, 1120px); }
  h1 { font-size: 40px; }
  .lead { font-size: 16px; }
  .paste { padding: 0 12px; }
  .features { gap: 13px; }
  .faq p { padding-right: 0; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .download:hover, .action:hover, .cta:hover, .feature:hover, .blog-card:hover { transform: none; }
  .progress > i { transition: none; }
}
