/*
 * keyidpro.com. One stylesheet for every page, no build step, no web fonts.
 * The colours are the app's own: mobile/components/AppDesign.tsx for the
 * surfaces, text and the violet accent, and the splash screen's gradient
 * (mobile/assets/images/keyidpro-splash.png) for the hero.
 */

:root {
  --bg: #ffffff;
  --surface: #f2f2f7;
  --grouped: #efedf3;
  --card: #ffffff;
  --text: #171719;
  --muted: #5c5c64;
  --border: #e6e6eb;
  --accent: #7948d9;
  --accent-text: #6a3cc8;
  --accent-soft: #eae2ff;
  --on-accent: #ffffff;
  --brand-blue: #5264f3;
  --hero: linear-gradient(135deg, #82d1fc 0%, #629ef9 30%, #5669f5 62%, #8d80fc 100%);
  /* Deep enough for white text to read on every part of it. */
  --deep: linear-gradient(135deg, #3a5be8 0%, #5264f3 50%, #7948d9 100%);
  --radius: 24px;
  --measure: 68ch;
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #121214;
    --surface: #242426;
    --grouped: #151319;
    --card: #1c1c1f;
    --text: #f5f5f7;
    --muted: #aaaab2;
    --border: #38383f;
    --accent-text: #b79bff;
    --accent-soft: #302344;
  }
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 1.0625rem;
  line-height: 1.6;
  overflow-wrap: break-word;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--accent-text);
  text-underline-offset: 0.15em;
}

a:hover {
  text-decoration-thickness: 2px;
}

:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 3px;
  border-radius: 4px;
}

.skip {
  position: absolute;
  left: -9999px;
}

.skip:focus {
  left: 16px;
  top: 12px;
  z-index: 10;
  background: var(--card);
  padding: 8px 14px;
  border-radius: 12px;
}

.wrap {
  width: 100%;
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 20px;
}

/* --- header ---------------------------------------------------------- */

.site-header {
  border-bottom: 1px solid var(--border);
}

.site-header .wrap {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 24px;
  padding-top: 14px;
  padding-bottom: 14px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  text-decoration: none;
  font-weight: 650;
  font-size: 1.125rem;
  letter-spacing: -0.01em;
}

.brand img {
  width: 34px;
  height: 34px;
  border-radius: 9px;
  border: 1px solid var(--border);
}

.site-nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 20px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.site-nav a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.975rem;
}

.site-nav a:hover {
  color: var(--text);
}

/* --- hero ------------------------------------------------------------ */

.hero {
  padding: 56px 0 64px;
}

.hero .wrap {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  align-items: center;
  gap: 40px;
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--accent-text);
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: 0.02em;
}

h1,
h2,
h3 {
  line-height: 1.15;
  letter-spacing: -0.02em;
  font-weight: 650;
}

.hero h1 {
  margin: 0;
  font-size: clamp(2.25rem, 6vw, 3.5rem);
  letter-spacing: -0.035em;
}

.lede {
  margin: 18px 0 0;
  max-width: 34rem;
  color: var(--muted);
  font-size: 1.1875rem;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 0 24px;
  border-radius: 28px;
  font-weight: 600;
  text-decoration: none;
  background: var(--accent);
  color: var(--on-accent);
}

.button:hover {
  filter: brightness(1.08);
}

.button.secondary {
  background: var(--accent-soft);
  color: var(--accent-text);
}

.hero-art {
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 1 / 1;
  border-radius: 36px;
  background: var(--hero);
  box-shadow: 0 30px 60px -30px rgba(82, 100, 243, 0.55);
}

.hero-art img {
  width: 68%;
  filter: drop-shadow(0 24px 22px rgba(30, 40, 120, 0.35));
}

/* --- sections -------------------------------------------------------- */

section {
  padding: 64px 0;
}

section.tinted {
  background: var(--grouped);
}

section h2 {
  margin: 0 0 12px;
  font-size: clamp(1.75rem, 4vw, 2.25rem);
}

.section-intro {
  margin: 0 0 32px;
  max-width: var(--measure);
  color: var(--muted);
}

.problem {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px 48px;
}

.problem p {
  margin: 0 0 16px;
}

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

.card {
  padding: 24px;
  border-radius: var(--radius);
  background: var(--card);
  border: 1px solid var(--border);
}

.card h3 {
  margin: 14px 0 8px;
  font-size: 1.25rem;
}

.card p {
  margin: 0;
  color: var(--muted);
}

.step {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--accent-text);
  font-weight: 700;
}

.note {
  margin: 28px 0 0;
  max-width: var(--measure);
  color: var(--muted);
  font-size: 0.975rem;
}

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

.faq {
  max-width: 760px;
}

.faq details {
  border-bottom: 1px solid var(--border);
}

.faq details:first-of-type {
  border-top: 1px solid var(--border);
}

.faq summary {
  cursor: pointer;
  padding: 18px 36px 18px 0;
  font-weight: 600;
  font-size: 1.0625rem;
  list-style: none;
  position: relative;
}

.faq summary::-webkit-details-marker {
  display: none;
}

.faq summary::after {
  content: "+";
  position: absolute;
  right: 4px;
  top: 14px;
  font-size: 1.5rem;
  line-height: 1.2;
  color: var(--accent-text);
}

.faq details[open] summary::after {
  content: "\2212";
}

.faq details p {
  margin: 0 0 18px;
  color: var(--muted);
}

/* --- download -------------------------------------------------------- */

.download {
  padding: 40px 32px;
  border-radius: 32px;
  background: var(--deep);
  color: #ffffff;
  text-align: center;
}

.download h2 {
  color: #ffffff;
}

.download p {
  margin: 0 auto 8px;
  max-width: 36rem;
}

.download a {
  color: #ffffff;
  font-weight: 600;
}

.badge-slot {
  display: inline-block;
  margin: 16px 0 12px;
  padding: 10px 20px;
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.45);
  font-weight: 600;
}

/* --- prose pages (privacy, support, 404) ----------------------------- */

.prose {
  max-width: var(--measure);
  padding-top: 48px;
  padding-bottom: 64px;
}

.prose h1 {
  margin: 0 0 8px;
  font-size: clamp(2rem, 5vw, 2.75rem);
  letter-spacing: -0.03em;
}

.prose h2 {
  margin: 40px 0 10px;
  font-size: 1.375rem;
}

.prose h3 {
  margin: 24px 0 6px;
  font-size: 1.125rem;
}

.prose p,
.prose ul {
  margin: 0 0 14px;
}

.prose ul {
  padding-left: 1.25rem;
}

.prose li {
  margin-bottom: 6px;
}

.meta {
  color: var(--muted);
  margin-bottom: 28px;
}

.callout {
  margin: 24px 0;
  padding: 20px 22px;
  border-radius: 20px;
  background: var(--accent-soft);
}

.callout p:last-child {
  margin-bottom: 0;
}

/* --- footer ---------------------------------------------------------- */

.site-footer {
  border-top: 1px solid var(--border);
  padding: 28px 0 36px;
  color: var(--muted);
  font-size: 0.95rem;
}

.site-footer .wrap {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px 24px;
}

.site-footer p {
  margin: 0;
}

.site-footer ul {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.site-footer a {
  color: var(--muted);
}

/* --- phone width ----------------------------------------------------- */

@media (max-width: 820px) {
  .hero {
    padding: 36px 0 48px;
  }

  .hero .wrap,
  .problem,
  .cards {
    grid-template-columns: minmax(0, 1fr);
  }

  .hero-art {
    max-width: 360px;
    width: 100%;
    margin: 0 auto;
  }

  section {
    padding: 48px 0;
  }

  .download {
    padding: 32px 20px;
  }
}

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

@media (prefers-reduced-motion: no-preference) {
  html {
    scroll-behavior: smooth;
  }
}
