/* ============================================================
   PriceCalc Pro — marketing site
   Design tokens mirror the Remotion hero (theme.ts)
   ============================================================ */
@import url("fonts.css");

:root {
  --ink: #0e1b2e;
  --ink-2: #12233d;
  --ink-3: #1a3a70;
  --blue: #2563eb;
  --blue-600: #1d4fd0;
  --blue-light: #5b8def;
  --green: #2fb344;
  --green-soft: #3bd65f;
  --green-ink: #1f7d34;
  --paper: #f5f8fc;
  --paper-2: #eef3fa;
  --mist: #9fb3ce;
  --white: #fff;

  --text: #1b2740;
  --muted: #55647e;
  --line: #e2e9f3;
  --line-dark: rgba(159, 179, 206, 0.2);

  --font-display: "Space Grotesk", system-ui, sans-serif;
  --font-body: "Inter", system-ui, -apple-system, sans-serif;
  --font-mono: "Space Mono", ui-monospace, "SFMono-Regular", monospace;

  --wrap: 1120px;
  --radius: 16px;
  --shadow-sm: 0 2px 8px rgba(16, 34, 60, 0.06);
  --shadow: 0 18px 44px rgba(16, 34, 60, 0.1);
  --shadow-lg: 0 30px 70px rgba(16, 34, 60, 0.16);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
}

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--text);
  background: var(--white);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4 { font-family: var(--font-display); line-height: 1.1; letter-spacing: -0.02em; color: var(--ink); margin: 0 0 0.4em; }
p { margin: 0 0 1em; }
a { color: var(--blue); text-decoration: none; }
a:hover { color: var(--blue-600); }
img, video { max-width: 100%; display: block; }
ul { margin: 0; padding: 0; }

.wrap { width: 100%; max-width: var(--wrap); margin-inline: auto; padding-inline: 22px; }
.mono { font-family: var(--font-mono); font-variant-numeric: tabular-nums; }
.eyebrow {
  font-family: var(--font-mono);
  font-size: 0.78rem; letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--blue); font-weight: 700; margin: 0 0 14px;
}
.eyebrow.on-dark { color: var(--blue-light); }
.section { padding: 92px 0; }
.section-head { max-width: 680px; margin: 0 0 48px; }
.section-head.center { margin-inline: auto; text-align: center; }
.section-head h2 { font-size: clamp(1.9rem, 4vw, 2.7rem); }
.section-head p { font-size: 1.12rem; color: var(--muted); margin-bottom: 0; }

.skip-link {
  position: absolute; left: -999px; top: 0; z-index: 200;
  background: var(--ink); color: #fff; padding: 10px 16px; border-radius: 0 0 10px 0;
}
.skip-link:focus { left: 0; color: #fff; }

:focus-visible { outline: 3px solid var(--blue-light); outline-offset: 2px; border-radius: 6px; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 9px;
  font-family: var(--font-display); font-weight: 600; font-size: 1rem;
  padding: 13px 22px; border-radius: 12px; border: 1.5px solid transparent;
  cursor: pointer; transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: var(--blue); color: #fff; box-shadow: 0 10px 24px rgba(37, 99, 235, 0.32); }
.btn-primary:hover { background: var(--blue-600); color: #fff; }
.btn-green { background: linear-gradient(150deg, var(--green-soft), var(--green-ink)); color: #06210d; box-shadow: 0 10px 24px rgba(47, 179, 68, 0.32); }
.btn-green:hover { color: #06210d; }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn-ghost.on-dark { color: #fff; border-color: var(--line-dark); }
.btn-ghost:hover { border-color: var(--blue); color: var(--blue); }
.btn-ghost.on-dark:hover { color: #fff; border-color: var(--blue-light); background: rgba(255,255,255,0.04); }
.btn-lg { padding: 16px 28px; font-size: 1.06rem; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--line);
}
.nav { display: flex; align-items: center; gap: 24px; height: 68px; }
.brand { display: flex; align-items: center; gap: 11px; font-family: var(--font-display); font-weight: 700; font-size: 1.18rem; color: var(--ink); }
.brand:hover { color: var(--ink); }
.brand img { width: 34px; height: 34px; border-radius: 9px; box-shadow: var(--shadow-sm); }
.brand .pro { color: var(--green-ink); }
.nav-links { display: flex; gap: 6px; margin-left: auto; align-items: center; list-style: none; }
.nav-links a { color: var(--muted); font-weight: 500; padding: 8px 12px; border-radius: 9px; font-size: 0.96rem; }
.nav-links a:hover { color: var(--ink); background: var(--paper-2); }
.nav-cta { margin-left: 6px; }
.lang-switch { display: inline-flex; align-items: center; gap: 2px; margin-left: 8px; font-family: var(--font-mono); font-size: 0.8rem; }
.lang-switch a, .lang-switch span { padding: 5px 8px; border-radius: 7px; color: var(--muted); font-weight: 700; }
.lang-switch .active { color: var(--ink); background: var(--paper-2); }
.lang-switch a:hover { color: var(--ink); background: var(--paper-2); }
.nav-toggle { display: none; margin-left: auto; background: none; border: 1.5px solid var(--line); border-radius: 10px; width: 42px; height: 42px; cursor: pointer; color: var(--ink); }

/* ---------- Hero ---------- */
.hero {
  position: relative; overflow: hidden;
  background: radial-gradient(120% 120% at 50% -10%, var(--ink-2) 0%, var(--ink) 62%);
  color: #fff; padding: 74px 0 0;
}
.hero::after {
  content: ""; position: absolute; inset: 0;
  background-image: linear-gradient(var(--line-dark) 1px, transparent 1px), linear-gradient(90deg, var(--line-dark) 1px, transparent 1px);
  background-size: 60px 60px;
  -webkit-mask-image: radial-gradient(ellipse 75% 60% at 50% 30%, #000 20%, transparent 72%);
  mask-image: radial-gradient(ellipse 75% 60% at 50% 30%, #000 20%, transparent 72%);
  opacity: 0.6; pointer-events: none;
}
.hero .wrap { position: relative; z-index: 1; }
.hero-badge {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--font-mono); font-size: 0.8rem; letter-spacing: 0.04em;
  color: var(--mist); background: rgba(255,255,255,0.05);
  border: 1px solid var(--line-dark); padding: 7px 14px; border-radius: 999px; margin-bottom: 24px;
}
.hero-badge b { color: var(--green-soft); font-weight: 700; }
.hero h1 { color: #fff; font-size: clamp(2.3rem, 5.6vw, 4rem); max-width: 15ch; }
.hero h1 .accent { color: var(--blue-light); }
.hero-sub { font-size: clamp(1.05rem, 2.2vw, 1.3rem); color: var(--mist); max-width: 52ch; margin-bottom: 30px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-bottom: 20px; }
.hero-note { font-size: 0.85rem; color: rgba(159,179,206,0.75); margin: 0; }
.hero-media {
  position: relative; margin-top: 54px; border-radius: 20px 20px 0 0;
  overflow: hidden; border: 1px solid var(--line-dark); border-bottom: none;
  box-shadow: 0 -10px 60px rgba(37,99,235,0.18);
  background: var(--ink);
}
.hero-media video { width: 100%; height: auto; display: block; }
.hero-media .browser-bar {
  display: flex; align-items: center; gap: 7px; padding: 11px 16px;
  background: rgba(255,255,255,0.03); border-bottom: 1px solid var(--line-dark);
}
.hero-media .dot { width: 11px; height: 11px; border-radius: 50%; background: rgba(159,179,206,0.4); }

/* ---------- Stat strip ---------- */
.stripe { background: var(--ink); color: #fff; padding: 0 0 0; }
.stat-strip { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; background: var(--line-dark); border-block: 1px solid var(--line-dark); }
.stat-strip .cell { background: var(--ink); padding: 28px 22px; text-align: center; }
.stat-strip .num { font-family: var(--font-display); font-weight: 700; font-size: 1.7rem; color: #fff; }
.stat-strip .num .g { color: var(--green-soft); }
.stat-strip .lbl { color: var(--mist); font-size: 0.9rem; margin-top: 4px; }

/* ---------- Features ---------- */
.features { background: var(--paper); }
.feature-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.feature-card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 26px 24px; box-shadow: var(--shadow-sm);
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}
.feature-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: #cfe0d6; }
.feature-icon {
  width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center;
  font-size: 22px; margin-bottom: 16px;
  background: linear-gradient(150deg, #e8f0ff, #d8e6ff); border: 1px solid #cfe0ff;
}
.feature-card.accent .feature-icon { background: linear-gradient(150deg, #e2f7e7, #cdefd6); border-color: #b9e6c6; }
.feature-card h3 { font-size: 1.2rem; }
.feature-card p { color: var(--muted); margin-bottom: 12px; font-size: 0.97rem; }
.tag {
  display: inline-block; font-family: var(--font-mono); font-size: 0.72rem; font-weight: 700;
  padding: 3px 9px; border-radius: 999px; letter-spacing: 0.03em;
}
.tag-free { background: #eef3fa; color: #3a4d6b; }
.tag-basic { background: #e8f0ff; color: #1d4fd0; }
.tag-premium { background: #efe8ff; color: #6b3ad0; }
.tag-unlim { background: #e2f7e7; color: var(--green-ink); }

/* ---------- Calculation explainer ---------- */
.calc { background: var(--white); }
.calc-chain { display: flex; align-items: stretch; gap: 2px; padding: 8px 0 4px; }
.calc-node {
  flex: 1 1 0; min-width: 0;
  background: var(--paper); border: 1.5px solid var(--line); border-radius: 14px; padding: 16px 14px;
  text-align: center;
}
.calc-node.result { background: linear-gradient(160deg, #e6f8ec, #d3f0dc); border-color: #a6e2b7; }
.calc-node .k { font-family: var(--font-mono); font-size: 0.68rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); font-weight: 700; }
.calc-node.result .k { color: var(--green-ink); }
.calc-node .v { font-family: var(--font-mono); font-weight: 700; font-size: clamp(1.05rem, 2vw, 1.5rem); color: var(--ink); margin: 6px 0 3px; white-space: nowrap; }
.calc-node.result .v { color: var(--green-ink); }
.calc-node .s { font-size: 0.78rem; color: var(--muted); line-height: 1.3; }
.calc-arrow { flex: 0 0 auto; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; width: 62px; }
.calc-arrow .op { font-family: var(--font-mono); font-size: 0.72rem; line-height: 1.15; font-weight: 700; color: var(--blue); text-align: center; }
.calc-arrow .ln { color: var(--blue); font-size: 1.15rem; line-height: 1; }
@media (max-width: 720px) {
  .calc-chain { flex-direction: column; align-items: stretch; gap: 4px; }
  .calc-node { width: 100%; display: flex; align-items: baseline; justify-content: space-between; gap: 12px; text-align: left; padding: 14px 18px; }
  .calc-node .k { flex: 0 0 auto; }
  .calc-node .v { flex: 1 1 auto; text-align: right; margin: 0; order: 3; }
  .calc-node .s { display: none; }
  .calc-arrow { width: 100%; flex-direction: row; justify-content: center; gap: 8px; padding: 2px 0; }
  .calc-arrow .ln { transform: rotate(90deg); }
}
.calc-legend { display: flex; flex-wrap: wrap; gap: 10px 24px; margin-top: 20px; color: var(--muted); font-size: 0.92rem; }
.calc-legend b { color: var(--ink); font-family: var(--font-display); }

/* ---------- Screenshots ---------- */
.shots { background: var(--paper); }
.shot { display: grid; grid-template-columns: 1.05fr 1fr; gap: 40px; align-items: center; margin-bottom: 46px; }
.shot:last-child { margin-bottom: 0; }
.shot.rev .shot-copy { order: 2; }
.shot-frame {
  border-radius: 14px; overflow: hidden; border: 1px solid var(--line);
  box-shadow: var(--shadow); background: #fff;
}
.shot-frame .browser-bar { display: flex; gap: 6px; padding: 10px 14px; background: #f2f5fa; border-bottom: 1px solid var(--line); }
.shot-frame .dot { width: 10px; height: 10px; border-radius: 50%; background: #cfd8e6; }
.shot-copy h3 { font-size: 1.5rem; }
.shot-copy p { color: var(--muted); }
.shot-copy .feat-list { list-style: none; margin-top: 14px; }
.shot-copy .feat-list li { position: relative; padding-left: 28px; margin-bottom: 9px; color: var(--text); }
.shot-copy .feat-list li::before { content: "✓"; position: absolute; left: 0; top: 0; color: var(--green-ink); font-weight: 700; }

/* ---------- Pricing ---------- */
.pricing { background: var(--white); }
.plan-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.plan {
  border: 1.5px solid var(--line); border-radius: var(--radius); padding: 26px 22px; background: #fff;
  display: flex; flex-direction: column;
}
.plan.featured { border-color: var(--blue); box-shadow: 0 18px 44px rgba(37,99,235,0.14); position: relative; }
.plan .ribbon {
  position: absolute; top: -12px; left: 22px; background: var(--blue); color: #fff;
  font-family: var(--font-mono); font-size: 0.68rem; font-weight: 700; letter-spacing: 0.08em;
  padding: 4px 11px; border-radius: 999px;
}
.plan h3 { font-size: 1.3rem; margin-bottom: 2px; }
.plan .limit { font-family: var(--font-mono); font-weight: 700; color: var(--blue); font-size: 1.02rem; margin-bottom: 4px; }
.plan.free .limit { color: var(--muted); }
.plan.unlim .limit { color: var(--green-ink); }
.plan .price { font-family: var(--font-display); font-size: 1rem; color: var(--muted); margin-bottom: 18px; padding-bottom: 18px; border-bottom: 1px solid var(--line); }
.plan .price b { color: var(--ink); font-size: 1.5rem; }
.plan ul { list-style: none; flex: 1; }
.plan li { position: relative; padding-left: 24px; margin-bottom: 10px; font-size: 0.93rem; color: var(--text); }
.plan li::before { content: "✓"; position: absolute; left: 0; color: var(--green-ink); font-weight: 700; }
.plan li.muted { color: var(--muted); }
.plan li.muted::before { content: "＋"; color: var(--mist); }
.pricing-note { text-align: center; color: var(--muted); margin-top: 26px; font-size: 0.92rem; }

/* ---------- FAQ ---------- */
.faq { background: var(--paper); }
.faq-list { max-width: 800px; margin-inline: auto; }
.faq-item { background: #fff; border: 1px solid var(--line); border-radius: 12px; margin-bottom: 12px; overflow: hidden; }
.faq-item summary {
  cursor: pointer; padding: 18px 22px; font-family: var(--font-display); font-weight: 600;
  font-size: 1.05rem; color: var(--ink); list-style: none; display: flex; justify-content: space-between; gap: 16px; align-items: center;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: "+"; font-family: var(--font-mono); color: var(--blue); font-size: 1.3rem; transition: transform 0.2s; }
.faq-item[open] summary::after { transform: rotate(45deg); }
.faq-item .a { padding: 0 22px 20px; color: var(--muted); }
.faq-item .a p:last-child { margin-bottom: 0; }

/* ---------- CTA band ---------- */
.cta {
  background: radial-gradient(120% 140% at 50% 0%, var(--ink-3) 0%, var(--ink) 60%);
  color: #fff; text-align: center; position: relative; overflow: hidden;
}
.cta h2 { color: #fff; font-size: clamp(1.9rem, 4.5vw, 2.9rem); }
.cta p { color: var(--mist); font-size: 1.15rem; max-width: 46ch; margin-inline: auto; margin-bottom: 28px; }
.cta-actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

/* ---------- Footer ---------- */
.site-footer { background: var(--ink); color: var(--mist); padding: 64px 0 30px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 34px; margin-bottom: 44px; }
.footer-brand .brand { color: #fff; margin-bottom: 14px; }
.footer-brand .brand .pro { color: var(--green-soft); }
.footer-brand p { font-size: 0.92rem; max-width: 34ch; }
.footer-col h4 { color: #fff; font-size: 0.82rem; letter-spacing: 0.1em; text-transform: uppercase; font-family: var(--font-mono); margin-bottom: 14px; }
.footer-col ul { list-style: none; }
.footer-col li { margin-bottom: 9px; }
.footer-col a { color: var(--mist); font-size: 0.94rem; }
.footer-col a:hover { color: #fff; }
.footer-bottom { border-top: 1px solid var(--line-dark); padding-top: 22px; display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; font-size: 0.85rem; color: rgba(159,179,206,0.75); }
.footer-bottom a { color: rgba(159,179,206,0.9); }

/* ---------- Legal pages ---------- */
.legal { background: var(--paper); padding: 54px 0 80px; }
.legal-wrap { max-width: 820px; margin-inline: auto; }
.legal-head { margin-bottom: 30px; }
.legal-head .back { font-family: var(--font-mono); font-size: 0.85rem; color: var(--muted); }
.legal-head h1 { font-size: clamp(1.8rem, 4vw, 2.4rem); margin-top: 12px; }
.legal-head .stand { color: var(--muted); font-size: 0.9rem; }
.legal-card { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 30px 34px; box-shadow: var(--shadow-sm); }
.legal-card h2 { font-size: 1.25rem; margin-top: 30px; padding-top: 22px; border-top: 1px solid var(--line); }
.legal-card h2:first-of-type, .legal-card > h2:first-child { border-top: none; margin-top: 0; padding-top: 0; }
.legal-card h3 { font-size: 1.05rem; margin-top: 20px; color: var(--ink-3); }
.legal-card p, .legal-card li { color: var(--text); font-size: 0.98rem; }
.legal-card ul { padding-left: 22px; margin-bottom: 14px; list-style: disc; }
.legal-card li { margin-bottom: 6px; }
.legal-card table { width: 100%; border-collapse: collapse; margin: 8px 0 18px; font-size: 0.92rem; }
.legal-card th { text-align: left; background: var(--paper-2); color: var(--ink-3); padding: 8px 12px; border-bottom: 2px solid var(--line); }
.legal-card td { padding: 8px 12px; border-bottom: 1px solid var(--line); color: var(--muted); }
.legal-card code { font-family: var(--font-mono); background: var(--paper-2); padding: 1px 6px; border-radius: 5px; font-size: 0.88em; }
.legal-note { background: #f0f5ff; border: 1px solid #d3e2ff; border-left: 3px solid var(--blue); border-radius: 8px; padding: 14px 18px; color: var(--ink-3); margin-bottom: 22px; font-size: 0.95rem; }
.legal-toc { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 24px; }
.legal-toc a { font-size: 0.85rem; padding: 6px 13px; border-radius: 999px; background: #fff; border: 1px solid var(--line); color: var(--ink-3); }
.legal-toc a:hover { border-color: var(--blue); }

/* ---------- Manual / user guide ---------- */
.legal-card h4.m-sub { font-family: var(--font-display); font-size: 1.02rem; color: var(--ink-3); margin: 20px 0 7px; padding-left: 10px; border-left: 3px solid var(--blue); }
.m-tip { background: #edf3ff; border: 1px solid #cfe0ff; border-left: 3px solid var(--blue); border-radius: 8px; padding: 11px 16px; font-size: 0.95rem; color: var(--ink-3); margin: 0 0 12px; line-height: 1.6; }
.m-warn { background: #fef1e8; border: 1px solid #f6cba0; border-left: 3px solid #ea580c; border-radius: 8px; padding: 11px 16px; font-size: 0.95rem; color: #8b4a12; margin: 0 0 12px; line-height: 1.6; }
.m-badge { display: inline-block; padding: 3px 10px; border-radius: 999px; font-family: var(--font-mono); font-size: 0.72rem; font-weight: 700; }
.m-badge.green { background: #e6f4d9; color: #3b6d11; }
.m-badge.blue { background: #e8f0ff; color: #185fa5; }
.m-badge.orange { background: #fdeede; color: #b7600b; }
.m-badge.red { background: #fce9e9; color: #b93636; }
.legal-toc.m-toc a { background: #fff; }
.legal-card hr.m-div { border: none; border-top: 1px solid var(--line); margin: 22px 0; }
.legal-card .m-faq { background: var(--paper); border-radius: 8px; border-left: 3px solid #cfe0ff; padding: 12px 16px; margin-bottom: 12px; }
.legal-card .m-faq .q { font-family: var(--font-display); font-weight: 600; color: var(--ink); margin-bottom: 4px; }
.legal-card .m-faq .a { color: var(--muted); font-size: 0.95rem; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .nav-links { display: none; }
  .nav-links.open {
    display: flex; position: absolute; top: 68px; left: 0; right: 0; flex-direction: column;
    background: #fff; border-bottom: 1px solid var(--line); padding: 12px 22px; gap: 2px; align-items: stretch;
  }
  .nav-links.open a { padding: 12px; border-radius: 8px; }
  .nav-links.open .nav-cta { margin: 8px 0 0; }
  .nav-toggle { display: grid; place-items: center; }
  .feature-grid { grid-template-columns: repeat(2, 1fr); }
  .plan-grid { grid-template-columns: repeat(2, 1fr); }
  .stat-strip { grid-template-columns: repeat(2, 1fr); }
  .shot { grid-template-columns: 1fr; gap: 22px; }
  .shot.rev .shot-copy { order: 0; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 28px; }
  .footer-brand { grid-column: 1 / -1; }
}
@media (max-width: 560px) {
  .section { padding: 62px 0; }
  .feature-grid, .plan-grid { grid-template-columns: 1fr; }
  .hero-actions .btn { flex: 1 1 auto; justify-content: center; }
  .footer-bottom { flex-direction: column; }
  .legal-card { padding: 22px 20px; }
}
