/* msg Lense — marketing & legal site
   Dependency-free. Light/dark via prefers-color-scheme. */

:root {
  --accent: #00a9ce;
  --accent-2: #0077a0;
  --accent-grad: linear-gradient(135deg, #00a9ce 0%, #0077a0 100%);

  --bg: #ffffff;
  --bg-elevated: #ffffff;
  --surface: #f5f5f7;
  --surface-2: #ececee;
  --border: rgba(0, 0, 0, 0.08);
  --border-strong: rgba(0, 0, 0, 0.14);

  --text: #1d1d1f;
  --text-secondary: #6e6e73;
  --text-tertiary: #86868b;

  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.06), 0 1px 3px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 24px 60px rgba(0, 0, 0, 0.16);

  --radius-sm: 10px;
  --radius: 16px;
  --radius-lg: 24px;
  --radius-xl: 32px;

  --container: 1080px;
  --nav-h: 56px;

  --font: -apple-system, BlinkMacSystemFont, "SF Pro Text", "SF Pro Display",
    "Segoe UI", system-ui, Roboto, Helvetica, Arial, sans-serif;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #000000;
    --bg-elevated: #0b0b0c;
    --surface: #1c1c1e;
    --surface-2: #2c2c2e;
    --border: rgba(255, 255, 255, 0.1);
    --border-strong: rgba(255, 255, 255, 0.18);

    --text: #f5f5f7;
    --text-secondary: #a1a1a6;
    --text-tertiary: #8e8e93;

    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.4);
    --shadow-md: 0 4px 18px rgba(0, 0, 0, 0.5);
    --shadow-lg: 0 24px 70px rgba(0, 0, 0, 0.65);
  }
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  scroll-padding-top: calc(var(--nav-h) + 12px);
}

body {
  margin: 0;
  font-family: var(--font);
  color: var(--text);
  background: var(--bg);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

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

h1, h2, h3, h4 {
  letter-spacing: -0.02em;
  line-height: 1.08;
  margin: 0;
  font-weight: 700;
}

p { margin: 0; }

.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: 22px;
}

.eyebrow {
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 14px;
}

.muted { color: var(--text-secondary); }
.center { text-align: center; }

/* ---------- Navigation ---------- */
.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  background: color-mix(in srgb, var(--bg) 72%, transparent);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid var(--border);
}

.nav .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

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

.brand .logo {
  width: 28px;
  height: 28px;
  border-radius: 7px;
  flex: none;
  box-shadow: var(--shadow-sm);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 26px;
}
.nav-links a {
  color: var(--text-secondary);
  font-size: 0.92rem;
  font-weight: 500;
}
.nav-links a:hover { color: var(--text); text-decoration: none; }
.nav-links a.btn-primary,
.nav-links a.btn-primary:hover { color: #fff; }

@media (max-width: 720px) {
  .nav-links a:not(.btn) { display: none; }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 11px 22px;
  border-radius: 980px;
  font-size: 0.95rem;
  font-weight: 600;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.15s ease, opacity 0.15s ease, background 0.15s ease;
  white-space: nowrap;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); }
.btn:active { transform: translateY(0); }

.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: color-mix(in srgb, var(--accent) 88%, #000); }

.btn-ghost {
  background: var(--surface);
  color: var(--text);
  border-color: var(--border);
}
.btn-ghost:hover { background: var(--surface-2); }

.btn-sm { padding: 8px 16px; font-size: 0.88rem; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  overflow: hidden;
  padding: clamp(56px, 9vw, 120px) 0 clamp(40px, 6vw, 80px);
}
.hero::before {
  content: "";
  position: absolute;
  inset: -30% -10% auto -10%;
  height: 680px;
  background:
    radial-gradient(closest-side at 30% 30%, rgba(0, 169, 206, 0.20), transparent 70%),
    radial-gradient(closest-side at 75% 25%, rgba(0, 119, 160, 0.16), transparent 70%);
  filter: blur(10px);
  z-index: -1;
  pointer-events: none;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: clamp(28px, 5vw, 64px);
  align-items: center;
}
@media (max-width: 880px) {
  .hero-grid { grid-template-columns: 1fr; text-align: center; }
}

.hero h1 {
  font-size: clamp(2.4rem, 6vw, 4rem);
  font-weight: 800;
}
.hero .lede {
  margin-top: 20px;
  font-size: clamp(1.05rem, 2.2vw, 1.3rem);
  color: var(--text-secondary);
  max-width: 30ch;
}
@media (max-width: 880px) {
  .hero .lede { max-width: none; margin-inline: auto; }
}

.hero-actions {
  margin-top: 30px;
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}
@media (max-width: 880px) { .hero-actions { justify-content: center; } }

.hero-note {
  margin-top: 18px;
  font-size: 0.85rem;
  color: var(--text-tertiary);
  display: flex;
  align-items: center;
  gap: 8px;
}
@media (max-width: 880px) { .hero-note { justify-content: center; } }

/* App Store badge (text-based placeholder) */
.appstore {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  padding: 10px 18px;
  border-radius: 14px;
  background: var(--text);
  color: var(--bg);
}
.appstore:hover { text-decoration: none; opacity: 0.9; }
.appstore svg { width: 24px; height: 24px; }
.appstore .small { font-size: 0.62rem; line-height: 1; opacity: 0.8; display: block; }
.appstore .big { font-size: 1.18rem; font-weight: 600; line-height: 1.1; letter-spacing: -0.01em; }

/* ---------- Device mockup ---------- */
.device {
  justify-self: center;
  width: min(320px, 78vw);
}
.screen,
.screen picture {
  display: block;
  width: 100%;
}
.screen-shot {
  width: 100%;
  height: auto;
  display: block;
  filter: drop-shadow(0 22px 38px rgba(0, 0, 0, 0.22));
}

/* ---------- Sections ---------- */
section { padding: clamp(48px, 8vw, 96px) 0; }
.section-head { max-width: 640px; margin: 0 auto clamp(32px, 5vw, 56px); text-align: center; }
.section-head h2 { font-size: clamp(1.8rem, 4vw, 2.7rem); }
.section-head p { margin-top: 16px; font-size: 1.08rem; color: var(--text-secondary); }

.alt { background: var(--surface); }

/* Logos / trust row */
.formats {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
  margin-top: 8px;
}
.format-tag {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-secondary);
  background: var(--bg);
  border: 1px solid var(--border);
  padding: 8px 16px;
  border-radius: 980px;
}

/* ---------- Feature grid ---------- */
.features {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
@media (max-width: 880px) { .features { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .features { grid-template-columns: 1fr; } }

.card {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }

.alt .card { background: var(--bg); }

.feature-icon {
  width: 46px;
  height: 46px;
  border-radius: 13px;
  display: grid;
  place-items: center;
  background: color-mix(in srgb, var(--accent) 12%, transparent);
  color: var(--accent);
  margin-bottom: 18px;
}
.feature-icon svg { width: 24px; height: 24px; }
.card h3 { font-size: 1.16rem; margin-bottom: 9px; }
.card p { color: var(--text-secondary); font-size: 0.96rem; }

/* ---------- Steps ---------- */
.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
  counter-reset: step;
}
@media (max-width: 760px) { .steps { grid-template-columns: 1fr; } }
.step { position: relative; padding-top: 8px; }
.step .num {
  width: 38px; height: 38px;
  border-radius: 50%;
  display: grid; place-items: center;
  font-weight: 700;
  background: var(--accent-grad);
  color: #fff;
  margin-bottom: 16px;
}
.step h3 { font-size: 1.12rem; margin-bottom: 8px; }
.step p { color: var(--text-secondary); font-size: 0.96rem; }

/* ---------- Privacy band ---------- */
.privacy-band {
  background: var(--accent-grad);
  color: #fff;
  border-radius: var(--radius-xl);
  padding: clamp(34px, 6vw, 64px);
  text-align: center;
}
.privacy-band .feature-icon {
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
  margin-inline: auto;
  width: 58px; height: 58px;
}
.privacy-band .feature-icon svg { width: 30px; height: 30px; }
.privacy-band h2 { font-size: clamp(1.7rem, 4vw, 2.5rem); margin-top: 6px; }
.privacy-band p { margin: 16px auto 0; max-width: 56ch; font-size: 1.06rem; opacity: 0.94; }

/* ---------- Pricing ---------- */
.pricing {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 380px));
  gap: 24px;
  justify-content: center;
  align-items: stretch;
}
@media (max-width: 760px) { .pricing { grid-template-columns: 1fr; max-width: 420px; margin-inline: auto; } }

.plan {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-sm);
}
.alt .plan { background: var(--bg); }
.plan.featured { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent), var(--shadow-md); }

.plan-name { display: flex; align-items: center; gap: 10px; font-size: 1.2rem; font-weight: 700; }
.badge {
  font-size: 0.7rem; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase;
  color: #fff; background: var(--accent); padding: 4px 9px; border-radius: 980px;
}
.price { margin: 18px 0 4px; font-size: 2.6rem; font-weight: 800; letter-spacing: -0.03em; }
.price small { font-size: 1rem; font-weight: 600; color: var(--text-secondary); letter-spacing: 0; }
.price-alt { color: var(--text-secondary); font-size: 0.92rem; min-height: 1.3em; }

.plan ul { list-style: none; padding: 0; margin: 22px 0 26px; display: grid; gap: 13px; }
.plan li { display: flex; gap: 11px; align-items: flex-start; font-size: 0.96rem; }
.plan li svg { width: 20px; height: 20px; color: var(--accent); flex: none; margin-top: 1px; }
.plan .btn { margin-top: auto; width: 100%; }

/* ---------- FAQ ---------- */
.faq { max-width: 760px; margin-inline: auto; }
.faq details {
  border-bottom: 1px solid var(--border);
  padding: 6px 0;
}
.faq summary {
  list-style: none;
  cursor: pointer;
  padding: 18px 4px;
  font-weight: 600;
  font-size: 1.06rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+";
  font-size: 1.5rem;
  font-weight: 400;
  color: var(--accent);
  transition: transform 0.2s ease;
  line-height: 1;
}
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { color: var(--text-secondary); padding: 0 4px 20px; font-size: 0.98rem; }

/* ---------- CTA ---------- */
.cta { text-align: center; }
.cta h2 { font-size: clamp(1.9rem, 4.5vw, 3rem); }
.cta p { margin: 16px auto 30px; max-width: 50ch; color: var(--text-secondary); font-size: 1.1rem; }

/* ---------- Footer ---------- */
.footer {
  border-top: 1px solid var(--border);
  padding: 48px 0 60px;
  background: var(--bg);
}
.footer .container {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
  justify-content: space-between;
  align-items: flex-start;
}
.footer .brand { margin-bottom: 12px; }
.footer-tag { color: var(--text-tertiary); font-size: 0.88rem; max-width: 34ch; }
.footer-cols { display: flex; gap: 60px; flex-wrap: wrap; }
.footer-col h4 { font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--text-tertiary); margin-bottom: 14px; }
.footer-col a { display: block; color: var(--text-secondary); font-size: 0.92rem; margin-bottom: 10px; }
.footer-col a:hover { color: var(--text); text-decoration: none; }
.footer-bottom {
  border-top: 1px solid var(--border);
  margin-top: 40px;
  padding-top: 24px;
  color: var(--text-tertiary);
  font-size: 0.84rem;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
}

/* ---------- Legal / prose pages ---------- */
.legal { padding-top: clamp(40px, 6vw, 72px); padding-bottom: clamp(48px, 8vw, 96px); }
.legal-head { max-width: 760px; margin: 0 auto clamp(28px, 4vw, 44px); }
.legal-head h1 { font-size: clamp(2rem, 5vw, 3rem); }
.legal-head .updated { margin-top: 14px; color: var(--text-tertiary); font-size: 0.92rem; }

.prose {
  max-width: 760px;
  margin-inline: auto;
  color: var(--text);
}
.prose h2 {
  font-size: 1.4rem;
  margin: 40px 0 14px;
  padding-top: 8px;
}
.prose h3 { font-size: 1.12rem; margin: 26px 0 10px; }
.prose p, .prose li { color: var(--text-secondary); font-size: 1rem; line-height: 1.7; }
.prose p { margin: 12px 0; }
.prose ul, .prose ol { margin: 12px 0; padding-left: 22px; }
.prose li { margin: 7px 0; }
.prose strong { color: var(--text); }
.prose a { font-weight: 500; }

.placeholder {
  background: color-mix(in srgb, #ffcc00 22%, transparent);
  color: var(--text);
  border-radius: 5px;
  padding: 1px 6px;
  font-weight: 600;
  border: 1px dashed color-mix(in srgb, #ffcc00 70%, #000 10%);
}

.callout {
  background: var(--surface);
  border: 1px solid var(--border);
  border-left: 3px solid var(--accent);
  border-radius: var(--radius-sm);
  padding: 16px 18px;
  margin: 22px 0;
  font-size: 0.95rem;
}
.callout p { color: var(--text-secondary); margin: 0; }

/* ---------- Support cards ---------- */
.support-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  max-width: 760px;
  margin: 0 auto 8px;
}
@media (max-width: 620px) { .support-grid { grid-template-columns: 1fr; } }

.skip-link {
  position: absolute;
  left: -999px;
}
.skip-link:focus {
  left: 16px; top: 10px; z-index: 200;
  background: var(--bg); color: var(--text);
  padding: 10px 16px; border-radius: 8px; border: 1px solid var(--border);
}

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