:root {
  --bg: #f6f2eb;
  --bg-soft: #fffaf5;
  --surface: #fffdf9;
  --surface-strong: #ffffff;
  --surface-tint: #f0f6ff;
  --surface-warm: #fff1e7;
  --surface-mint: #eefaf4;
  --text: #18171b;
  --text-soft: #504b57;
  --line: #d9d0c6;
  --line-strong: #c9beb1;
  --accent: #f46a2f;
  --accent-strong: #db4e13;
  --accent-mint: #59b47b;
  --accent-blush: #ef8a9a;
  --focus: #1755d8;
  --shadow: 0 18px 48px rgba(32, 27, 19, 0.08);
  --radius-lg: 8px;
  --radius-md: 6px;
  --container: 1160px;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family:
    "SF Pro Text",
    "SF Pro Display",
    "Avenir Next",
    "Helvetica Neue",
    Helvetica,
    Arial,
    sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.5;
}

img,
video {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
  text-underline-offset: 3px;
}

a:focus-visible,
button:focus-visible,
summary:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  padding: 0.6rem 0.8rem;
  background: #fff;
  color: #000;
}

.skip-link:focus {
  left: 0.75rem;
  top: 0;
  z-index: 1000;
}

.container {
  width: min(100% - 2rem, var(--container));
  margin-inline: auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(20, 18, 23, 0.64);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

.nav-shell {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 4.5rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  text-decoration: none;
  color: #fff;
  font-weight: 700;
}

.brand-icon {
  width: 2rem;
  height: 2rem;
  border-radius: 0.6rem;
  object-fit: cover;
}

.nav-links {
  list-style: none;
  display: flex;
  align-items: center;
  gap: 1.15rem;
  padding: 0;
  margin: 0;
}

.nav-links a {
  text-decoration: none;
  color: rgba(255, 255, 255, 0.86);
  font-weight: 600;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.9rem;
  padding: 0.7rem 1.1rem;
  border: 1px solid transparent;
  border-radius: 999px;
  text-decoration: none;
  font-weight: 700;
  cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.button:hover {
  transform: translateY(-1px);
}

.button-primary {
  background: var(--accent);
  color: #fff;
}

.button-primary:hover {
  background: var(--accent-strong);
}

.button-secondary {
  background: rgba(255, 255, 255, 0.96);
  color: var(--text);
  border-color: rgba(24, 23, 27, 0.12);
}

.button-tertiary {
  margin-top: 0.9rem;
  background: var(--surface);
  color: var(--text);
  border-color: var(--line);
}

.button-small {
  min-height: 2.4rem;
  padding-inline: 0.95rem;
}

.button-disabled,
.button-disabled:hover {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
  pointer-events: none;
}

.hero {
  position: relative;
  background:
    radial-gradient(120% 80% at 85% 0%, rgba(244, 106, 47, 0.1) 0%, rgba(244, 106, 47, 0) 60%),
    var(--bg);
  border-bottom: 1px solid var(--line);
  overflow: hidden;
}

.hero-shell {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  align-items: center;
  gap: 2.5rem;
  padding-top: 6.5rem;
  padding-bottom: 6.5rem;
}

.hero-content {
  max-width: 42rem;
}

.hero-visual {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 30rem;
  overflow: visible;
}

.hero-device {
  margin: 0;
  padding: 0;
  background: transparent;
  border: none;
  box-shadow: none;
}

.hero-device-phone {
  position: relative;
  z-index: 2;
  width: min(82%, 26rem);
  transform: translateX(-2.2rem);
}

.hero-device-tablet {
  position: absolute;
  z-index: 1;
  right: -1.5rem;
  bottom: 0.25rem;
  width: min(98%, 38rem);
  transform: rotate(2.5deg);
}

.hero-device .screenshot-frame {
  background: transparent;
  border: none;
}

.eyebrow,
.section-kicker {
  margin: 0 0 0.85rem;
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--accent-strong);
}

h1,
h2,
h3 {
  margin: 0;
  line-height: 1.1;
}

h1 {
  max-width: 12ch;
  font-size: clamp(2.8rem, 6vw, 5.5rem);
}

h2 {
  font-size: clamp(2rem, 3vw, 3rem);
  max-width: 16ch;
}

h3 {
  font-size: 1.15rem;
}

p {
  margin: 0;
  color: var(--text-soft);
}

.hero-copy {
  margin-top: 1rem;
  max-width: 39rem;
  font-size: 1.15rem;
  color: var(--text-soft);
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  margin-top: 1.5rem;
}

.meta {
  margin-top: 0.9rem;
  font-size: 0.96rem;
  color: var(--text-soft);
}

.hero-points {
  list-style: none;
  padding: 0;
  margin: 1.4rem 0 0;
  display: grid;
  gap: 0.7rem;
  max-width: 40rem;
}

.hero-points li {
  padding-left: 1rem;
  border-left: 3px solid var(--accent);
  color: var(--text-soft);
}

.trust-strip {
  background: var(--surface-strong);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.trust-shell {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.6rem 1.25rem;
  padding: 1.1rem 0;
  text-align: center;
}

.trust-line {
  margin: 0;
  font-weight: 700;
  color: var(--text);
}

.trust-devices {
  list-style: none;
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  margin: 0;
  padding: 0;
  font-weight: 600;
  color: var(--text-soft);
}

.trust-dot {
  color: var(--line-strong);
}

.section {
  padding: 5rem 0;
}

.section-contrast {
  background: var(--bg-soft);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.section-heading {
  display: grid;
  gap: 0.8rem;
  margin-bottom: 2rem;
  max-width: 46rem;
}

.feature-card {
  background: var(--surface-strong);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
}

.screenshot-card {
  margin: 0;
  padding: 0.8rem;
  background: var(--surface-strong);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
}

.screenshot-frame {
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 4 / 5;
  border-radius: var(--radius-md);
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: transparent;
  overflow: hidden;
}

.screenshot-card-landscape .screenshot-frame {
  aspect-ratio: 4 / 3;
}

.screenshot-image {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.screenshot-card figcaption {
  margin-top: 0.65rem;
  color: var(--text-soft);
  font-size: 0.94rem;
}

.workflow-carousel {
  margin-bottom: 1.25rem;
}

.workflow-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.7fr) minmax(16rem, 0.9fr);
  align-items: start;
  gap: 1.25rem;
}

.workflow-carousel-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 0.9rem;
}

.workflow-device-toggle {
  display: inline-flex;
  padding: 0.2rem;
  background: rgba(23, 21, 26, 0.08);
  border: 1px solid var(--line);
  border-radius: 999px;
  gap: 0.2rem;
}

.device-toggle-button {
  border: 0;
  background: transparent;
  color: var(--text-soft);
  font-weight: 700;
  padding: 0.5rem 0.9rem;
  border-radius: 999px;
  cursor: pointer;
}

.device-toggle-button.is-active {
  background: #fff;
  color: var(--text);
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.06);
}

.workflow-carousel-nav {
  display: inline-flex;
  gap: 0.5rem;
}

.carousel-nav-button {
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.86);
  color: var(--text);
  font-weight: 600;
  min-height: 2.3rem;
  padding: 0.45rem 0.85rem;
  cursor: pointer;
}

.workflow-stage {
  margin: 0;
}

.workflow-stage-frame {
  display: grid;
  place-items: center;
  min-height: 22rem;
  max-height: 78vh;
  border: none;
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: transparent;
}

.workflow-stage-image,
.workflow-stage-video {
  width: 100%;
  height: 100%;
  max-height: 78vh;
  object-fit: contain;
}

.workflow-stage-placeholder {
  width: 100%;
  min-height: 22rem;
  display: grid;
  place-items: center;
  text-align: center;
  color: var(--text-soft);
  background: linear-gradient(180deg, rgba(244, 106, 47, 0.08), rgba(23, 21, 26, 0.04));
}

.workflow-stage-placeholder p {
  margin: 0;
  padding: 1rem;
  font-weight: 600;
}

.workflow-stage-meta {
  margin-top: 0.8rem;
  display: grid;
  gap: 0.35rem;
}

.workflow-stage-meta strong {
  font-size: 1rem;
}

.workflow-stage-meta span {
  color: var(--text-soft);
}

.steps {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}

.steps li {
  min-height: 100%;
}

.step-button {
  width: 100%;
  min-height: 100%;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 1rem 1.05rem;
  background: var(--surface-strong);
  box-shadow: var(--shadow);
  text-align: left;
  cursor: pointer;
  color: inherit;
  transition: border-color 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease;
}

.step-button:hover {
  border-color: var(--line-strong);
}

.step-button.is-active {
  border-color: var(--accent);
  background: #fffaf5;
  box-shadow: 0 10px 28px rgba(32, 27, 19, 0.11);
}

.step-title,
.step-copy {
  display: block;
}

.step-title {
  font-size: 1.15rem;
  line-height: 1.1;
}

.step-copy {
  margin-top: 0.55rem;
  color: var(--text-soft);
}

.step-index {
  display: inline-block;
  margin-bottom: 0.75rem;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--accent-strong);
}

.steps p,
.feature-card p,
.faq-list p {
  margin-top: 0.55rem;
}

.feature-grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.feature-grid-4 {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.feature-presets {
  list-style: none;
  margin: 0.9rem 0 0;
  padding: 0.9rem 0 0;
  border-top: 1px solid var(--line);
  display: grid;
  gap: 0.4rem;
  font-size: 0.92rem;
  color: var(--text-soft);
}

/* Use case switcher: segmented control + wide image + glass overlay */
.use-case-switcher {
  display: grid;
  gap: 1.25rem;
  justify-items: center;
}

.usecase-toggle {
  display: inline-flex;
  flex-wrap: wrap;
  justify-content: center;
  padding: 0.25rem;
  background: rgba(23, 21, 26, 0.08);
  border: 1px solid var(--line);
  border-radius: 999px;
  gap: 0.2rem;
  max-width: 100%;
}

.usecase-toggle-button {
  border: 0;
  background: transparent;
  color: var(--text-soft);
  font-weight: 700;
  font-size: 0.95rem;
  padding: 0.5rem 0.95rem;
  border-radius: 999px;
  cursor: pointer;
  white-space: nowrap;
  transition: background-color 0.2s ease, color 0.2s ease;
}

.usecase-toggle-button:hover {
  color: var(--text);
}

.usecase-toggle-button.is-active {
  background: #fff;
  color: var(--text);
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.06);
}

.usecase-stage {
  margin: 0;
  width: 100%;
}

.usecase-stage-frame {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--surface-warm);
}

.usecase-stage-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.usecase-stage-placeholder {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 1.5rem;
  color: var(--text-soft);
  background: var(--surface-warm);
}

.usecase-overlay {
  position: absolute;
  left: 1.25rem;
  bottom: 1.25rem;
  max-width: min(34rem, 80%);
  padding: 1rem 1.2rem;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(255, 255, 255, 0.4);
  border-left: 4px solid var(--usecase-accent, var(--accent));
  box-shadow: var(--shadow);
  background: rgba(255, 250, 245, 0.55);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
  backdrop-filter: blur(16px) saturate(140%);
}

@supports not ((backdrop-filter: blur(2px)) or (-webkit-backdrop-filter: blur(2px))) {
  .usecase-overlay {
    background: rgba(255, 250, 245, 0.92);
  }
}

.usecase-overlay-title {
  display: block;
  font-size: 1.25rem;
  line-height: 1.15;
  color: var(--text);
}

.usecase-overlay-copy {
  display: block;
  margin-top: 0.4rem;
  color: var(--text-soft);
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.gallery-grid .screenshot-card-landscape {
  grid-column: span 3;
}

.feature-card,
.use-case-card {
  padding: 1.2rem;
}

.faq-list {
  display: grid;
  gap: 0.8rem;
}

.faq-list details {
  padding: 1rem 1.1rem;
  background: var(--surface-strong);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
}

.faq-list summary {
  cursor: pointer;
  font-weight: 700;
}

.faq-list details[open] p {
  color: var(--text-soft);
}

.final-cta {
  padding-bottom: 6rem;
}

.final-cta-shell {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1.5rem;
  padding: 1.5rem;
  background: #17151a;
  color: #fff;
  border-radius: var(--radius-lg);
}

.final-cta-shell p {
  color: rgba(255, 255, 255, 0.8);
  max-width: 34rem;
}

.final-cta-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
}

.final-cta-note {
  width: 100%;
  margin-top: 0.1rem;
}

.site-footer {
  padding: 1rem 0 2rem;
  border-top: 1px solid var(--line);
}

.footer-shell {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.footer-shell ul {
  list-style: none;
  display: flex;
  gap: 0.9rem;
  padding: 0;
  margin: 0;
}

.legal-main {
  padding: 6.5rem 0 4rem;
}

.legal-shell {
  max-width: 52rem;
}

.legal-card {
  padding: 2rem;
  background: var(--surface-strong);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
}

.legal-kicker {
  margin: 0 0 0.75rem;
  color: var(--accent-strong);
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.legal-card h1 {
  margin: 0;
  font-size: clamp(2.2rem, 4vw, 3.3rem);
  line-height: 1.05;
}

.legal-meta {
  margin: 1rem 0 0;
  color: var(--text-soft);
  font-weight: 600;
}

.legal-prose {
  margin-top: 2rem;
}

.legal-prose h2 {
  margin: 2rem 0 0.75rem;
  font-size: 1.2rem;
}

.legal-prose p,
.legal-prose li {
  color: var(--text-soft);
}

.legal-prose ul {
  margin: 0.75rem 0 0;
  padding-left: 1.2rem;
}

/* Demo modal (inert until CONFIG.DEMO_YOUTUBE_ID is set) */
.demo-modal {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  padding: 1.5rem;
}

.demo-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 13, 18, 0.72);
}

.demo-modal-panel {
  position: relative;
  width: min(100%, 56rem);
  background: #000;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.demo-modal-close {
  position: absolute;
  top: 0.5rem;
  right: 0.5rem;
  z-index: 1;
  width: 2.4rem;
  height: 2.4rem;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.92);
  color: #000;
  font-size: 1.4rem;
  line-height: 1;
  cursor: pointer;
}

.demo-embed {
  aspect-ratio: 16 / 9;
}

.demo-embed iframe {
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
}

/* Scroll reveal */
[data-reveal] {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}

[data-reveal].is-visible {
  opacity: 1;
  transform: none;
}

@media (max-width: 1100px) {
  .feature-grid-4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .workflow-layout {
    grid-template-columns: minmax(0, 1.45fr) minmax(14rem, 0.85fr);
  }

  .gallery-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 900px) {
  .feature-grid,
  .feature-grid-4,
  .gallery-grid {
    grid-template-columns: 1fr;
  }

  .workflow-layout {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .hero-shell {
    grid-template-columns: 1fr;
    padding-top: 5.5rem;
    padding-bottom: 4rem;
    gap: 2rem;
  }

  .hero-visual {
    min-height: 26rem;
  }

  .hero-device-phone {
    width: min(78%, 24rem);
    transform: translateX(-1rem);
  }

  .hero-device-tablet {
    right: -0.75rem;
    width: min(96%, 34rem);
  }

  .gallery-grid .screenshot-card-landscape {
    grid-column: auto;
  }

  .nav-links {
    display: none;
  }

  .final-cta-shell {
    flex-direction: column;
    align-items: flex-start;
  }

  .legal-main {
    padding-top: 5.5rem;
  }
}

@media (max-width: 640px) {
  .section {
    padding: 4rem 0;
  }

  h1 {
    max-width: 9ch;
  }

  .hero-visual {
    min-height: 20rem;
  }

  .hero-device-phone {
    width: min(76%, 20rem);
    transform: translateX(-0.4rem);
  }

  .hero-device-tablet {
    right: -0.25rem;
    bottom: 0;
    width: min(92%, 24rem);
  }

  .usecase-toggle {
    flex-wrap: nowrap;
    overflow-x: auto;
    max-width: 100%;
    justify-content: flex-start;
    -webkit-overflow-scrolling: touch;
  }

  .usecase-stage-frame {
    aspect-ratio: 4 / 3;
  }

  .usecase-overlay {
    left: 0.6rem;
    right: 0.6rem;
    bottom: 0.6rem;
    max-width: none;
    padding: 0.85rem 1rem;
  }

  .button,
  .final-cta-actions .button {
    width: 100%;
  }

  .button-small {
    width: auto;
  }

  .gallery-grid {
    grid-template-columns: 1fr;
  }

  .workflow-carousel-toolbar {
    align-items: stretch;
  }

  .workflow-carousel-nav {
    width: 100%;
  }

  .carousel-nav-button {
    flex: 1;
  }

  .steps {
    display: flex;
    grid-template-columns: none;
    gap: 0.75rem;
    overflow-x: auto;
    padding-bottom: 0.35rem;
    scroll-snap-type: x mandatory;
  }

  .steps li {
    flex: 0 0 13rem;
    scroll-snap-align: start;
  }

  .step-button {
    min-height: 0;
    padding: 0.85rem 0.9rem;
  }

  .step-copy {
    display: none;
  }

  .workflow-stage-frame,
  .workflow-stage-placeholder {
    min-height: 17rem;
  }

  .legal-card {
    padding: 1.25rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation: none !important;
    transition-duration: 0s !important;
  }

  [data-reveal] {
    opacity: 1;
    transform: none;
  }
}
