/* Customer Recovery AI — marketing site styles.
   Mobile first; no web fonts, frameworks or third-party requests.
   Colour pairs used for text meet WCAG 2.2 AA contrast (4.5:1 or better). */

:root {
  color-scheme: light;
  --ink: #101735;          /* headings and body text: 17:1 on white */
  --text: #2c3350;         /* paragraph text: 12:1 */
  --muted: #4a5170;        /* secondary text: 7.9:1 */
  --brand: #3f37c9;        /* primary buttons and links: 8.1:1 */
  --brand-strong: #2f28a3;
  --brand-soft: #eeedfd;
  --accent: #ffb547;       /* decoration only, never text on white */
  --accent-soft: #fff4e0;
  --success: #0b6b4f;      /* 6.6:1 */
  --success-soft: #e3f5ee;
  --danger: #b3261e;       /* 6.5:1 */
  --danger-soft: #fdecea;
  --surface: #f6f7fb;
  --border: #d9dcea;
  --white: #ffffff;
  --radius: 14px;
  --radius-lg: 22px;
  --shadow: 0 1px 2px rgb(16 23 53 / 6%), 0 8px 24px rgb(16 23 53 / 8%);
  --max: 72rem;
  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    transition: none !important;
  }
}

body {
  margin: 0;
  background: var(--white);
  color: var(--text);
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.6;
}

img,
video {
  display: block;
  max-width: 100%;
  height: auto;
}

h1,
h2,
h3 {
  color: var(--ink);
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin: 0 0 0.6em;
}

h1 {
  font-size: clamp(2.1rem, 6.5vw, 3.6rem);
  font-weight: 800;
}

h2 {
  font-size: clamp(1.6rem, 4.2vw, 2.4rem);
  font-weight: 800;
}

h3 {
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}

p {
  margin: 0 0 1em;
}

a {
  color: var(--brand);
  text-decoration-thickness: 0.08em;
  text-underline-offset: 0.18em;
}

a:hover {
  color: var(--brand-strong);
}

:focus-visible {
  outline: 3px solid var(--brand);
  outline-offset: 3px;
  border-radius: 4px;
}

.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: -4rem;
  z-index: 10;
  padding: 0.75rem 1rem;
  background: var(--ink);
  color: var(--white);
  border-radius: 10px;
  font-weight: 700;
}

.skip-link:focus {
  top: 1rem;
  color: var(--white);
}

.container {
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 1.25rem;
}

/* ---------- Header ---------- */

.site-header {
  border-bottom: 1px solid var(--border);
  background: var(--white);
}

.site-header .container {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem 1rem;
  padding-top: 0.9rem;
  padding-bottom: 0.9rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  color: var(--ink);
  font-weight: 800;
  font-size: 1.1rem;
  letter-spacing: -0.02em;
  text-decoration: none;
  min-height: 44px;
}

.brand img {
  width: 36px;
  height: 36px;
}

.brand .brand-ai {
  color: var(--brand);
}

.site-nav {
  order: 3;
  width: 100%;
}

.site-nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0 0.9rem;
  font-size: 0.95rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.site-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--text);
  font-weight: 600;
  text-decoration: none;
}

.site-nav a:hover {
  color: var(--brand);
  text-decoration: underline;
}

/* Phones: the hero repeats this button, so the header stays compact. */
.site-header .header-cta {
  display: none;
}

@media (min-width: 600px) {
  .site-header .header-cta {
    display: inline-flex;
  }
}

@media (min-width: 900px) {
  .site-nav {
    order: 0;
    width: auto;
  }
  .site-nav ul {
    gap: 0.25rem 1.5rem;
    font-size: 1rem;
  }
}

/* ---------- Buttons ---------- */

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 48px;
  padding: 0.7rem 1.3rem;
  border: 2px solid var(--brand);
  border-radius: 999px;
  background: var(--brand);
  color: var(--white);
  font: inherit;
  font-weight: 700;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
}

.button:hover {
  background: var(--brand-strong);
  border-color: var(--brand-strong);
  color: var(--white);
}

.button-secondary {
  background: var(--white);
  color: var(--brand);
}

.button-secondary:hover {
  background: var(--brand-soft);
  color: var(--brand-strong);
}

.button-small {
  min-height: 44px;
  padding: 0.5rem 1rem;
  font-size: 0.95rem;
}

.button[disabled],
.button[aria-disabled="true"] {
  opacity: 0.65;
  cursor: not-allowed;
}

/* ---------- Sections ---------- */

.section {
  padding: 3.5rem 0;
}

.section-alt {
  background: var(--surface);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0 0 1rem;
  padding: 0.35rem 0.8rem;
  border-radius: 999px;
  background: var(--brand-soft);
  color: var(--brand-strong);
  font-size: 0.9rem;
  font-weight: 700;
}

.eyebrow::before {
  content: "";
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 50%;
  background: var(--accent);
}

.lead {
  font-size: 1.2rem;
  color: var(--text);
  max-width: 40rem;
}

.section-intro {
  max-width: 44rem;
  margin-bottom: 2rem;
}

.section-intro p {
  color: var(--muted);
}

/* ---------- Hero ---------- */

.hero {
  padding: 3rem 0 3.5rem;
  background:
    radial-gradient(60rem 30rem at 85% -10%, var(--brand-soft), transparent 60%),
    var(--white);
}

.hero .container {
  display: grid;
  gap: 2.5rem;
  align-items: center;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin: 1.75rem 0 1.25rem;
}

.hero-note {
  display: flex;
  gap: 0.6rem;
  align-items: flex-start;
  max-width: 36rem;
  margin: 0;
  padding: 0.8rem 1rem;
  border-radius: var(--radius);
  background: var(--accent-soft);
  color: var(--ink);
  font-size: 0.95rem;
}

.hero-visual {
  justify-self: center;
  width: min(100%, 20rem);
}

.device {
  padding: 0.6rem;
  border-radius: 2.2rem;
  background: var(--ink);
  box-shadow: 0 24px 60px rgb(16 23 53 / 25%);
}

.device img {
  border-radius: 1.7rem;
  width: 100%;
  aspect-ratio: 390 / 700;
  object-fit: cover;
  object-position: top;
}

.hero-visual figcaption {
  margin-top: 0.8rem;
  color: var(--muted);
  font-size: 0.9rem;
  text-align: center;
}

@media (min-width: 900px) {
  .hero {
    padding: 4.5rem 0 5rem;
  }
  .hero .container {
    grid-template-columns: 1.25fr 0.75fr;
    gap: 4rem;
  }
}

/* ---------- Status strip ---------- */

.status-strip {
  background: var(--ink);
  color: var(--white);
}

.status-strip .container {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
  padding-top: 0.9rem;
  padding-bottom: 0.9rem;
  font-size: 0.95rem;
}

.status-strip strong {
  color: var(--accent);
}

/* ---------- Problem ---------- */

.problem-grid {
  display: grid;
  gap: 1rem;
}

@media (min-width: 760px) {
  .problem-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.card {
  padding: 1.4rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--white);
}

.card p:last-child {
  margin-bottom: 0;
}

.card .icon {
  display: grid;
  place-items: center;
  width: 2.75rem;
  height: 2.75rem;
  margin-bottom: 1rem;
  border-radius: 12px;
  background: var(--brand-soft);
  color: var(--brand);
}

.card .icon svg {
  width: 1.4rem;
  height: 1.4rem;
}

/* ---------- Steps ---------- */

.steps {
  display: grid;
  gap: 1rem;
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: step;
}

.steps li {
  position: relative;
  padding: 1.4rem 1.4rem 1.4rem 4.4rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--white);
  counter-increment: step;
}

.steps li::before {
  content: counter(step);
  position: absolute;
  left: 1.3rem;
  top: 1.3rem;
  display: grid;
  place-items: center;
  width: 2.2rem;
  height: 2.2rem;
  border-radius: 50%;
  background: var(--brand);
  color: var(--white);
  font-weight: 800;
}

.steps p {
  margin: 0;
  color: var(--muted);
}

@media (min-width: 900px) {
  .steps {
    grid-template-columns: repeat(4, 1fr);
  }
  .steps li {
    padding: 4.2rem 1.4rem 1.4rem;
  }
}

.tag {
  display: inline-block;
  margin-top: 0.6rem;
  padding: 0.15rem 0.6rem;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--ink);
  font-size: 0.85rem;
  font-weight: 600;
}

/* ---------- Features ---------- */

.feature-grid {
  display: grid;
  gap: 1rem;
}

@media (min-width: 700px) {
  .feature-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1000px) {
  .feature-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.feature-grid .card p {
  color: var(--muted);
}

/* ---------- Demo ---------- */

.video-frame {
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--ink);
  box-shadow: var(--shadow);
}

.video-frame video {
  width: 100%;
  aspect-ratio: 16 / 9;
}

.video-meta {
  margin-top: 0.8rem;
  color: var(--muted);
  font-size: 0.95rem;
}

details.transcript {
  margin-top: 1rem;
  padding: 0.25rem 1.2rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--white);
}

details.transcript summary {
  min-height: 44px;
  display: flex;
  align-items: center;
  font-weight: 700;
  color: var(--ink);
  cursor: pointer;
}

details.transcript ol {
  padding-left: 1.3rem;
}

.gallery {
  display: grid;
  gap: 1.5rem;
  margin-top: 2.5rem;
}

@media (min-width: 800px) {
  .gallery {
    grid-template-columns: repeat(2, 1fr);
  }
}

.gallery figure {
  margin: 0;
}

.gallery .zoom {
  display: block;
  border-radius: var(--radius);
}

.gallery img {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.gallery figcaption {
  margin-top: 0.7rem;
  color: var(--muted);
  font-size: 0.95rem;
}

.gallery figcaption strong {
  color: var(--ink);
}

/* ---------- Availability table ---------- */

.table-wrap {
  margin-top: 2.5rem;
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--white);
}

table {
  width: 100%;
  min-width: 38rem;
  border-collapse: collapse;
  font-size: 0.97rem;
}

caption {
  padding: 1rem 1.2rem 0.4rem;
  color: var(--ink);
  font-weight: 800;
  font-size: 1.1rem;
  text-align: left;
}

th,
td {
  padding: 0.75rem 1.2rem;
  border-top: 1px solid var(--border);
  text-align: left;
  vertical-align: top;
}

thead th {
  color: var(--ink);
  font-size: 0.9rem;
  background: var(--surface);
}

tbody th {
  color: var(--ink);
  font-weight: 600;
}

.status {
  display: inline-block;
  padding: 0.1rem 0.55rem;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 700;
  white-space: nowrap;
}

.status-yes {
  background: var(--success-soft);
  color: var(--success);
}

.status-sim {
  background: var(--accent-soft);
  color: var(--ink);
}

.status-no {
  background: var(--surface);
  color: var(--muted);
  border: 1px solid var(--border);
}

/* ---------- Early access form ---------- */

.form-layout {
  display: grid;
  gap: 2rem;
}

@media (min-width: 960px) {
  .form-layout {
    grid-template-columns: 0.85fr 1.15fr;
    gap: 4rem;
  }
}

.form-card {
  padding: 1.5rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--white);
  box-shadow: var(--shadow);
}

@media (min-width: 600px) {
  .form-card {
    padding: 2rem;
  }
}

.checklist {
  margin: 0;
  padding: 0;
  list-style: none;
}

.checklist li {
  position: relative;
  margin-bottom: 0.7rem;
  padding-left: 1.9rem;
}

.checklist li::before {
  content: "";
  position: absolute;
  left: 0.15rem;
  top: 0.45rem;
  width: 1rem;
  height: 0.55rem;
  border-left: 3px solid var(--success);
  border-bottom: 3px solid var(--success);
  transform: rotate(-45deg);
}

.field {
  margin-bottom: 1.2rem;
}

.field label,
.field legend {
  display: block;
  margin-bottom: 0.35rem;
  color: var(--ink);
  font-weight: 700;
}

.field .optional,
.field .required {
  color: var(--muted);
  font-weight: 500;
}

.hint {
  display: block;
  margin: -0.15rem 0 0.4rem;
  color: var(--muted);
  font-size: 0.92rem;
}

input[type="text"],
input[type="email"],
select,
textarea {
  display: block;
  width: 100%;
  min-height: 48px;
  padding: 0.65rem 0.8rem;
  border: 2px solid #8b91ad; /* 3.3:1 against white for the field boundary */
  border-radius: 10px;
  background: var(--white);
  color: var(--ink);
  font: inherit;
}

textarea {
  min-height: 7.5rem;
  resize: vertical;
}

input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  border-color: var(--brand);
  outline: 3px solid var(--brand);
  outline-offset: 1px;
}

[aria-invalid="true"] {
  border-color: var(--danger) !important;
}

.field-error {
  margin: 0.4rem 0 0;
  color: var(--danger);
  font-size: 0.95rem;
  font-weight: 600;
}

.field-error::before {
  content: "⚠ ";
}

.consent {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.75rem;
  align-items: start;
}

.consent input {
  width: 1.5rem;
  height: 1.5rem;
  margin: 0.15rem 0 0;
  accent-color: var(--brand);
}

.consent label {
  font-weight: 500;
  color: var(--text);
}

.honeypot {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.turnstile-box {
  min-height: 70px;
  margin-bottom: 1.2rem;
}

.error-summary {
  margin-bottom: 1.5rem;
  padding: 1rem 1.2rem;
  border: 2px solid var(--danger);
  border-radius: var(--radius);
  background: var(--danger-soft);
  color: var(--ink);
}

.error-summary h3 {
  margin-bottom: 0.4rem;
  font-size: 1.05rem;
}

.error-summary ul {
  margin: 0;
  padding-left: 1.2rem;
}

.error-summary a {
  color: var(--danger);
  font-weight: 700;
}

.form-status {
  margin: 1rem 0 0;
  font-weight: 600;
}

.form-status.is-error {
  color: var(--danger);
}

.success-panel {
  padding: 1.5rem;
  border: 2px solid var(--success);
  border-radius: var(--radius-lg);
  background: var(--success-soft);
  color: var(--ink);
}

.success-panel h3:focus {
  outline: none;
}

.small-print {
  margin-top: 1rem;
  color: var(--muted);
  font-size: 0.9rem;
}

/* ---------- FAQ ---------- */

.faq {
  max-width: 48rem;
}

.faq details {
  border-bottom: 1px solid var(--border);
}

.faq summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 56px;
  padding: 0.6rem 0;
  color: var(--ink);
  font-weight: 700;
  font-size: 1.05rem;
  cursor: pointer;
  list-style: none;
}

.faq summary::-webkit-details-marker {
  display: none;
}

.faq summary::after {
  content: "+";
  flex: none;
  display: grid;
  place-items: center;
  width: 1.9rem;
  height: 1.9rem;
  border-radius: 50%;
  background: var(--brand-soft);
  color: var(--brand);
  font-size: 1.3rem;
}

.faq details[open] summary::after {
  content: "−";
}

.faq details > div {
  padding: 0 0 1rem;
  color: var(--text);
}

/* ---------- Footer ---------- */

.site-footer {
  padding: 2.5rem 0;
  background: var(--ink);
  color: #d5d8e8; /* 11:1 on ink */
  font-size: 0.95rem;
}

.site-footer .container {
  display: grid;
  gap: 1.25rem;
}

.site-footer a {
  color: var(--white);
}

.site-footer .brand {
  color: var(--white);
}

.site-footer .brand .brand-ai {
  color: var(--accent);
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1.5rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.footer-links a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
}

@media (min-width: 800px) {
  .site-footer .container {
    grid-template-columns: 1fr auto;
    align-items: center;
  }
}

/* ---------- Legal pages ---------- */

.prose {
  max-width: 46rem;
  padding: 3rem 0 4rem;
}

.prose h1 {
  font-size: clamp(2rem, 5vw, 2.8rem);
}

.prose h2 {
  margin-top: 2.2rem;
  font-size: 1.45rem;
}

.prose ul {
  padding-left: 1.3rem;
}

.prose li {
  margin-bottom: 0.4rem;
}

.updated {
  color: var(--muted);
}

.not-found {
  padding: 5rem 0;
  text-align: center;
}

.not-found .button {
  margin-top: 1rem;
}
