/* ==========================================================================
   LensPath — marketing + legal site
   Single stylesheet. No build step. RTL-aware. WCAG AA contrast.
   Brand primary: #1B4965 (deep teal-blue)
   ========================================================================== */

/* ---- Design tokens -------------------------------------------------------- */
:root {
  /* Brand palette built around #1B4965 */
  --primary:        #1B4965;   /* deep teal-blue — primary */
  --primary-600:    #163C54;   /* hover / pressed */
  --primary-700:    #102C3D;   /* darkest */
  --accent:         #4F9DBA;   /* lighter teal tint */
  --accent-200:     #BCDDE7;   /* soft tint for fills */
  --accent-050:     #EAF3F6;   /* faint wash */

  /* Neutrals — warm, optical-premium */
  --ink:            #16242E;   /* near-black text */
  --ink-soft:       #51626E;   /* muted body text */
  --ink-faint:      #7C8B95;   /* captions, meta */
  --bg:             #F3EFE6;   /* warm cream — matches the LensPath logo background */
  --bg-alt:         #EAE4D7;   /* deeper warm cream for alternating sections */
  --surface:        #FFFFFF;   /* cards */
  --border:         #E1D9C9;   /* warm hairline */
  --border-cool:    #D9E3E8;   /* cool hairline on teal areas */

  --success:        #2E7D5B;

  /* Typography */
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --font-head: "Space Grotesk", "Inter", system-ui, sans-serif;

  /* Scale */
  --maxw: 1140px;
  --radius: 14px;
  --radius-sm: 9px;
  --radius-lg: 22px;
  --shadow-sm: 0 1px 2px rgba(16,44,61,.06), 0 1px 3px rgba(16,44,61,.05);
  --shadow-md: 0 10px 30px rgba(16,44,61,.10), 0 2px 8px rgba(16,44,61,.06);
  --shadow-lg: 0 24px 60px rgba(16,44,61,.16);

  --space: clamp(4rem, 9vw, 7.5rem); /* vertical section rhythm */
}

/* ---- Reset / base --------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation-duration: .001ms !important; transition-duration: .001ms !important; }
}

body {
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.65;
  font-size: 1.0625rem;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img, svg { max-width: 100%; display: block; }
a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }

h1, h2, h3, h4 {
  font-family: var(--font-head);
  color: var(--ink);
  line-height: 1.12;
  letter-spacing: -0.02em;
  font-weight: 600;
}
h1 { font-size: clamp(2.3rem, 5.2vw, 3.6rem); }
h2 { font-size: clamp(1.8rem, 3.6vw, 2.6rem); }
h3 { font-size: 1.3rem; letter-spacing: -0.01em; }
p  { color: var(--ink-soft); }

/* ---- Accessibility helpers ----------------------------------------------- */
:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
  border-radius: 4px;
}
.skip-link {
  position: absolute; left: 12px; top: -60px;
  background: var(--primary); color: #fff;
  padding: .6rem 1rem; border-radius: 8px; z-index: 1000;
  transition: top .15s ease;
}
.skip-link:focus { top: 12px; text-decoration: none; }
.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;
}

/* ---- Layout primitives ---------------------------------------------------- */
.container { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: 1.5rem; }
.section { padding-block: var(--space); }
.section--alt { background: var(--bg-alt); }
.section--tight { padding-block: clamp(3rem, 6vw, 4.5rem); }
.center { text-align: center; }
.measure { max-width: 62ch; }
.mx-auto { margin-inline: auto; }

.eyebrow {
  font-family: var(--font-head);
  text-transform: uppercase;
  letter-spacing: .14em;
  font-size: .78rem;
  font-weight: 600;
  color: var(--accent);
  margin-bottom: .9rem;
}
.lede { font-size: 1.18rem; color: var(--ink-soft); }

/* ---- Buttons -------------------------------------------------------------- */
.btn {
  display: inline-flex; align-items: center; gap: .5rem;
  font-family: var(--font-head);
  font-weight: 600; font-size: 1rem;
  padding: .85rem 1.4rem; border-radius: 999px;
  border: 1.5px solid transparent; cursor: pointer;
  transition: transform .12s ease, background .15s ease, box-shadow .15s ease, border-color .15s ease;
  text-decoration: none; white-space: nowrap;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn--primary { background: var(--primary); color: #fff; box-shadow: var(--shadow-sm); }
.btn--primary:hover { background: var(--primary-600); box-shadow: var(--shadow-md); }
.btn--ghost { background: transparent; color: var(--primary); border-color: var(--border-cool); }
.btn--ghost:hover { border-color: var(--primary); background: var(--accent-050); }
.btn--light { background: #fff; color: var(--primary); }
.btn--light:hover { background: #f3f8fb; }
.btn--lg { padding: 1rem 1.8rem; font-size: 1.05rem; }
.btn-row { display: flex; gap: .9rem; flex-wrap: wrap; }
.btn-row--center { justify-content: center; }

/* Shopify glyph chip inside CTA */
.btn .glyph { width: 18px; height: 18px; }

/* ---- Header / nav --------------------------------------------------------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: color-mix(in srgb, var(--bg) 86%, transparent);
  backdrop-filter: saturate(140%) blur(10px);
  border-bottom: 1px solid var(--border);
}
.nav { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding-block: .85rem; }
.brand { display: inline-flex; align-items: center; gap: .6rem; font-family: var(--font-head); font-weight: 600; font-size: 1.22rem; color: var(--ink); letter-spacing: -0.02em; }
.brand:hover { text-decoration: none; }
.brand__mark { width: 42px; height: 28px; flex: none; color: var(--primary); }
.site-footer .brand__mark { color: #fff; }
.nav__links { display: flex; align-items: center; gap: 1.6rem; list-style: none; padding: 0; }
.nav__links a { color: var(--ink-soft); font-weight: 500; font-size: .98rem; }
.nav__links a:hover { color: var(--primary); text-decoration: none; }
.nav__cta { display: inline-flex; align-items: center; gap: .8rem; }
.nav__toggle {
  display: none; background: none; border: 1.5px solid var(--border);
  border-radius: 10px; padding: .45rem .55rem; cursor: pointer; color: var(--ink);
}
.nav__toggle svg { width: 22px; height: 22px; }

@media (max-width: 860px) {
  .nav__links, .nav__cta .btn--ghost { display: none; }
  .nav__toggle { display: inline-flex; }
  .nav[data-open="true"] .nav__links {
    display: flex; position: absolute; left: 0; right: 0; top: 100%;
    flex-direction: column; align-items: stretch; gap: 0;
    background: var(--surface); border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow-md); padding: .5rem 1.5rem 1.25rem;
  }
  .nav[data-open="true"] .nav__links a { padding: .8rem 0; border-bottom: 1px solid var(--border); }
}

/* ---- Hero ----------------------------------------------------------------- */
.hero { position: relative; overflow: hidden; }
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    radial-gradient(60% 80% at 85% -10%, var(--accent-050), transparent 60%),
    radial-gradient(50% 60% at 0% 110%, #f1ece3, transparent 70%);
}
.hero__grid {
  display: grid; grid-template-columns: 1.05fr .95fr; gap: clamp(2rem, 5vw, 4rem);
  align-items: center; padding-block: clamp(3.5rem, 8vw, 6rem);
}
.hero h1 { margin-bottom: 1.1rem; }
.hero .lede { margin-bottom: 1.8rem; max-width: 40ch; }
.hero__meta { margin-top: 1.4rem; color: var(--ink-faint); font-size: .92rem; display: flex; gap: 1.2rem; flex-wrap: wrap; }
.hero__meta span { display: inline-flex; align-items: center; gap: .4rem; }

@media (max-width: 860px) {
  .hero__grid { grid-template-columns: 1fr; gap: 2rem; }
}

/* ---- Media placeholder slot ---------------------------------------------- */
.slot {
  border: 1.5px dashed var(--border-cool);
  background:
    linear-gradient(135deg, var(--accent-050), #fff);
  border-radius: var(--radius-lg);
  display: grid; place-items: center; text-align: center;
  color: var(--ink-faint); padding: 1.5rem;
  min-height: 280px; position: relative;
  box-shadow: var(--shadow-sm);
}
.slot__label { font-family: var(--font-head); font-size: .82rem; letter-spacing: .04em; text-transform: uppercase; color: var(--accent); }
.slot__hint { font-size: .9rem; margin-top: .35rem; }
.slot--wide { min-height: 360px; }
.slot--feature { min-height: 220px; }

/* ---- Generic feature / card grids ---------------------------------------- */
.grid { display: grid; gap: 1.5rem; }
.grid--3 { grid-template-columns: repeat(3, 1fr); }
.grid--2 { grid-template-columns: repeat(2, 1fr); }
@media (max-width: 900px) { .grid--3 { grid-template-columns: 1fr; } .grid--2 { grid-template-columns: 1fr; } }

.card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 1.6rem; box-shadow: var(--shadow-sm);
}
.card h3 { margin-bottom: .5rem; }
.card p { font-size: 1rem; }

.icon-badge {
  width: 46px; height: 46px; border-radius: 12px; flex: none;
  display: grid; place-items: center; margin-bottom: 1rem;
  background: var(--accent-050); color: var(--primary);
  border: 1px solid var(--border-cool);
}
.icon-badge svg { width: 24px; height: 24px; }

/* ---- Feature rows (alternating) ------------------------------------------ */
.feature-row {
  display: grid; grid-template-columns: 1fr 1fr; gap: clamp(2rem,5vw,4rem);
  align-items: center;
}
.feature-row + .feature-row { margin-top: clamp(3rem, 6vw, 5rem); }
.feature-row--rev .feature-row__media { order: -1; }
.feature-row__body .kicker { color: var(--accent); font-family: var(--font-head); font-weight: 600; font-size: .8rem; letter-spacing: .12em; text-transform: uppercase; }
.feature-row__body h3 { font-size: clamp(1.5rem, 3vw, 2rem); margin: .5rem 0 .8rem; }
.checklist { list-style: none; padding: 0; margin: 1.1rem 0 0; display: grid; gap: .6rem; }
.checklist li { display: flex; gap: .6rem; align-items: flex-start; color: var(--ink-soft); }
.checklist svg { flex: none; width: 20px; height: 20px; color: var(--success); margin-top: .15rem; }
@media (max-width: 860px) {
  .feature-row { grid-template-columns: 1fr; gap: 1.5rem; }
  .feature-row--rev .feature-row__media { order: 0; }
}

/* ---- Trust strip ---------------------------------------------------------- */
.trust { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.25rem; }
.trust__item { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.3rem; }
.trust__item strong { font-family: var(--font-head); display: block; margin-bottom: .25rem; }
.trust__item p { font-size: .95rem; }
@media (max-width: 900px) { .trust { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .trust { grid-template-columns: 1fr; } }

/* ---- Pricing -------------------------------------------------------------- */
.plans { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; align-items: stretch; }
@media (max-width: 900px) { .plans { grid-template-columns: 1fr; max-width: 460px; margin-inline: auto; } }
.plan {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg);
  padding: 1.9rem 1.7rem; display: flex; flex-direction: column; box-shadow: var(--shadow-sm);
}
.plan--featured { border: 1.5px solid var(--primary); box-shadow: var(--shadow-md); position: relative; }
.plan__tag {
  position: absolute; top: -.8rem; inset-inline-start: 1.7rem;
  background: var(--primary); color: #fff; font-family: var(--font-head);
  font-size: .72rem; letter-spacing: .08em; text-transform: uppercase;
  padding: .3rem .7rem; border-radius: 999px;
}
.plan__name { font-family: var(--font-head); font-weight: 600; font-size: 1.2rem; }
.plan__price { font-family: var(--font-head); font-size: 2.6rem; font-weight: 600; letter-spacing: -.02em; margin-top: .4rem; line-height: 1; }
.plan__price small { font-size: .95rem; font-weight: 500; color: var(--ink-faint); letter-spacing: 0; }
.plan__sub { color: var(--ink-faint); font-size: .92rem; margin-top: .4rem; }
.plan__features { list-style: none; padding: 0; margin: 1.4rem 0; display: grid; gap: .7rem; }
.plan__features li { display: flex; gap: .55rem; align-items: flex-start; font-size: .98rem; color: var(--ink-soft); }
.plan__features svg { flex: none; width: 19px; height: 19px; color: var(--accent); margin-top: .18rem; }
.plan .btn { margin-top: auto; justify-content: center; }

/* ---- CTA band ------------------------------------------------------------- */
.cta-band {
  background: linear-gradient(135deg, var(--primary), var(--primary-700));
  color: #fff; border-radius: var(--radius-lg);
  padding: clamp(2.5rem, 6vw, 4rem); text-align: center; position: relative; overflow: hidden;
}
.cta-band::after {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(50% 120% at 80% 0%, rgba(79,157,186,.45), transparent 60%);
  pointer-events: none;
}
.cta-band h2, .cta-band p { color: #fff; position: relative; z-index: 1; }
.cta-band p { color: #d7e6ee; max-width: 52ch; margin: .8rem auto 1.6rem; }
.cta-band .btn-row { position: relative; z-index: 1; }

/* ---- Footer --------------------------------------------------------------- */
.site-footer { background: var(--ink); color: #c3ccd3; padding-block: 3.5rem 2rem; }
.site-footer a { color: #c3ccd3; }
.site-footer a:hover { color: #fff; }
.footer__grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 2rem; margin-bottom: 2.5rem; }
.footer__brand .brand { color: #fff; }
.footer__brand p { color: #93a0a8; max-width: 34ch; margin-top: .8rem; font-size: .95rem; }
.footer__col h4 { color: #fff; font-size: .85rem; text-transform: uppercase; letter-spacing: .1em; margin-bottom: .9rem; }
.footer__col ul { list-style: none; padding: 0; display: grid; gap: .55rem; }
.footer__col a { font-size: .96rem; }
.footer__bottom { border-top: 1px solid #2c3a44; padding-top: 1.5rem; display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; font-size: .9rem; color: #8b99a1; }
@media (max-width: 760px) { .footer__grid { grid-template-columns: 1fr 1fr; } .footer__brand { grid-column: 1 / -1; } }

/* ---- Legal / docs prose --------------------------------------------------- */
.legal { padding-block: clamp(3rem, 6vw, 5rem); }
.legal__head { border-bottom: 1px solid var(--border); padding-bottom: 1.5rem; margin-bottom: 2.5rem; }
.legal__head .updated { color: var(--ink-faint); font-size: .92rem; margin-top: .6rem; }
.prose { max-width: 75ch; }
.prose h2 { font-size: 1.5rem; margin-top: 2.4rem; margin-bottom: .8rem; }
.prose h3 { font-size: 1.15rem; margin-top: 1.6rem; margin-bottom: .5rem; }
.prose p { margin-bottom: 1rem; }
.prose ul, .prose ol { margin: 0 0 1rem; padding-inline-start: 1.4rem; color: var(--ink-soft); }
.prose li { margin-bottom: .5rem; }
.prose a { text-decoration: underline; }
.prose strong { color: var(--ink); }
.toc { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.2rem 1.4rem; margin-bottom: 2.5rem; }
.toc h2 { font-size: .85rem; text-transform: uppercase; letter-spacing: .1em; color: var(--ink-faint); margin: 0 0 .7rem; }
.toc ul { list-style: none; padding: 0; margin: 0; columns: 2; column-gap: 2rem; }
.toc li { margin-bottom: .4rem; break-inside: avoid; }
@media (max-width: 600px) { .toc ul { columns: 1; } }

.callout {
  background: var(--accent-050); border: 1px solid var(--border-cool);
  border-inline-start: 4px solid var(--accent); border-radius: var(--radius-sm);
  padding: 1rem 1.2rem; margin: 1.4rem 0; font-size: .97rem; color: var(--ink-soft);
}

/* Subprocessor / definition table */
.def-table { width: 100%; border-collapse: collapse; margin: 1rem 0 1.4rem; font-size: .97rem; }
.def-table th, .def-table td { text-align: start; padding: .75rem .9rem; border-bottom: 1px solid var(--border); vertical-align: top; }
.def-table th { font-family: var(--font-head); color: var(--ink); font-weight: 600; background: var(--bg-alt); }
.def-table td { color: var(--ink-soft); }

/* ---- Forms (support) ------------------------------------------------------ */
.form { display: grid; gap: 1.1rem; max-width: 560px; }
.field { display: grid; gap: .4rem; }
.field label { font-weight: 600; font-size: .95rem; color: var(--ink); font-family: var(--font-head); }
.field input, .field textarea {
  font: inherit; color: var(--ink); background: var(--surface);
  border: 1.5px solid var(--border); border-radius: var(--radius-sm); padding: .75rem .9rem;
}
.field input:focus, .field textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-050); }
.field textarea { min-height: 140px; resize: vertical; }
.form__note { font-size: .88rem; color: var(--ink-faint); }

/* ---- FAQ / details -------------------------------------------------------- */
.faq { display: grid; gap: .75rem; max-width: 760px; margin-inline: auto; }
.faq details { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: .25rem 1.2rem; }
.faq summary { cursor: pointer; font-family: var(--font-head); font-weight: 600; padding: .9rem 0; list-style: none; display: flex; justify-content: space-between; align-items: center; gap: 1rem; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-size: 1.3rem; color: var(--accent); line-height: 1; }
.faq details[open] summary::after { content: "\2013"; }
.faq details p { padding-bottom: 1rem; font-size: .98rem; }

/* ---- Misc helpers --------------------------------------------------------- */
.stack > * + * { margin-top: 1rem; }
.mt-0 { margin-top: 0; }
.mb-1 { margin-bottom: .5rem; }
.text-soft { color: var(--ink-soft); }
.divider { height: 1px; background: var(--border); border: 0; margin-block: var(--space); }

/* ---- RTL support ---------------------------------------------------------- */
[dir="rtl"] .hero .lede,
[dir="rtl"] .cta-band p { text-align: inherit; }
[dir="rtl"] .feature-row--rev .feature-row__media { order: 0; }
/* logical properties above (margin-inline, padding-inline, inset-inline-start,
   text-align:start) make most of the layout mirror automatically under dir="rtl". */
