/* ===================================================================
   MyBox — digital secure mailbox · landing
   Visual language: monochrome navy (#0A1F3D) on warm paper, Rubik,
   poster headings, hairline borders, muted semantic accents. RTL.
   =================================================================== */

:root {
  --navy:      #0A1F3D;
  --navy-deep: #06152C;
  --navy-soft: #E8ECF3;
  --paper:     #F1EFE8;
  --paper-2:   #FBFAF6;
  --ink:       #1A1A18;
  --ink-soft:  #6B695F;
  --line:      #E2E0D6;
  --line-soft: #EDEBE2;
  --white:     #FFFFFF;

  /* muted semantic accents (from the app tokens) */
  --red:   #7A2A28; --red-bg:   #FBEAE8;
  --amber: #7A4F1A; --amber-bg: #FBF0DA;
  --teal:  #1F5C5C; --teal-bg:  #E0EEEE;
  --blue:  #1E4F8C; --blue-bg:  #E2ECF7;

  --shadow-sm: 0 1px 2px rgba(10,31,61,.05), 0 2px 8px rgba(10,31,61,.05);
  --shadow-md: 0 2px 4px rgba(10,31,61,.05), 0 12px 30px -10px rgba(10,31,61,.14);
  --shadow-lg: 0 30px 70px -30px rgba(10,31,61,.4);

  --font: "Rubik", -apple-system, system-ui, "Segoe UI", sans-serif;
  --maxw: 1180px;
  --r: 20px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font);
  background: var(--paper);
  color: var(--ink);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  background-image:
    radial-gradient(circle at 85% -5%, rgba(10,31,61,.05), transparent 40%),
    radial-gradient(circle at 5% 8%, rgba(10,31,61,.035), transparent 38%);
}
::selection { background: var(--navy); color: var(--paper); }
a { color: inherit; text-decoration: none; }
em { font-style: normal; color: var(--navy); }
strong { font-weight: 600; color: var(--navy); }
img { max-width: 100%; display: block; }

/* buttons */
.btn {
  display: inline-flex; align-items: center; gap: .5em;
  font-family: var(--font); font-weight: 600; font-size: 1rem;
  padding: .8em 1.6em; border-radius: 100px; border: 1.5px solid transparent;
  cursor: pointer; white-space: nowrap;
  transition: transform .25s cubic-bezier(.2,.8,.2,1), box-shadow .25s, background .25s, color .25s, border-color .25s;
}
.btn--solid { background: var(--navy); color: var(--paper-2); }
.btn--solid:hover { transform: translateY(-3px); box-shadow: 0 16px 30px -14px rgba(10,31,61,.6); }
.btn--ghost { background: transparent; color: var(--navy); border-color: var(--line); }
.btn--ghost:hover { border-color: var(--navy); transform: translateY(-3px); }
.btn--lg { font-size: 1.1rem; padding: 1em 2.2em; }

/* ============================ NAV ============================ */
.nav {
  position: sticky; top: 0; z-index: 50;
  display: flex; align-items: center; gap: 2rem;
  padding: .9rem clamp(1.2rem, 4vw, 3rem);
  background: rgba(241,239,232,.82); backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line-soft);
}
.nav__brand { margin-inline-end: auto; display: flex; align-items: center; gap: .8rem; }
.nav__logo { height: 26px; width: auto; }
.nav__slogan {
  font-size: .78rem; font-weight: 500; color: var(--ink-soft);
  padding-inline-start: .8rem; border-inline-start: 1.5px solid var(--line);
}
@media (max-width: 760px) { .nav__slogan { display: none; } }
.nav__links { display: flex; gap: 1.7rem; font-weight: 500; font-size: .96rem; }
.nav__links a { position: relative; padding: .2em 0; color: var(--ink-soft); transition: color .2s; }
.nav__links a::after {
  content: ""; position: absolute; inset-inline: 0; bottom: -3px; height: 2px;
  background: var(--navy); transform: scaleX(0); transform-origin: right; transition: transform .3s;
}
.nav__links a:hover { color: var(--navy); }
.nav__links a:hover::after, .nav__links a.active::after { transform: scaleX(1); }
.nav__links a.active { color: var(--navy); }
.nav__burger { display: none; width: 44px; height: 44px; padding: 0; cursor: pointer; background: var(--paper-2); border: 1px solid var(--line); border-radius: 12px; }
.nav__burger span { display: block; width: 20px; height: 2px; margin: 4px auto; background: var(--navy); border-radius: 2px; transition: transform .3s, opacity .3s; }
.nav.open .nav__burger span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.nav.open .nav__burger span:nth-child(2) { opacity: 0; }
.nav.open .nav__burger span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }
.nav__links-cta { display: none; }

/* ============================ HERO ============================ */
.hero {
  position: relative; display: grid; grid-template-columns: 1.05fr .95fr;
  align-items: center; gap: 3rem; max-width: var(--maxw); margin: 0 auto;
  padding: clamp(2.5rem, 6vw, 5.5rem) clamp(1.2rem, 4vw, 3rem) clamp(2rem, 5vw, 4rem);
}
.eyebrow {
  display: inline-block; font-size: .8rem; font-weight: 500; color: var(--navy);
  background: var(--navy-soft); border-radius: 100px; padding: .5em 1.1em; margin-bottom: 1.5rem;
}
.hero__title {
  font-weight: 800; font-size: clamp(2.6rem, 6.5vw, 5rem); line-height: 1.02;
  letter-spacing: -.03em; color: var(--navy); margin-bottom: 1.5rem;
}
.hero__title span { display: block; }
.hero__title em { color: var(--navy); position: relative; }
.hero__title em::after {
  content: ""; position: absolute; inset-inline: 0; bottom: .08em; height: .14em;
  background: var(--amber-bg); z-index: -1;
}
.hero__lede { font-size: clamp(1.05rem, 1.7vw, 1.25rem); color: var(--ink-soft); max-width: 40ch; margin-bottom: 2rem; }
.hero__cta { display: flex; gap: .9rem; flex-wrap: wrap; margin-bottom: 1.8rem; }
.hero__points { list-style: none; display: flex; flex-wrap: wrap; gap: 1.2rem; font-size: .92rem; font-weight: 500; color: var(--ink-soft); }

/* ---- live inbox device ---- */
.hero__device { position: relative; display: grid; place-items: center; }
.device {
  width: min(420px, 92%); background: var(--paper-2); border: 1px solid var(--line);
  border-radius: 26px; box-shadow: var(--shadow-lg); padding: 1.1rem; overflow: hidden;
}
.device__top { display: flex; align-items: center; justify-content: space-between; padding: .4rem .5rem 1rem; }
.device__title { font-weight: 700; font-size: 1.25rem; color: var(--navy); }
.device__badge { font-size: .76rem; font-weight: 600; color: var(--navy); background: var(--navy-soft); padding: .3em .8em; border-radius: 100px; }
.device__list { list-style: none; display: flex; flex-direction: column; gap: .55rem; }
.mail {
  display: flex; align-items: center; gap: .8rem; padding: .8rem .85rem;
  background: var(--white); border: 1px solid var(--line-soft); border-radius: 16px;
  opacity: 0; transform: translateY(12px);
}
.in-view .mail { animation: mailIn .55s cubic-bezier(.2,.8,.2,1) forwards; }
.in-view .mail:nth-child(1) { animation-delay: .05s; }
.in-view .mail:nth-child(2) { animation-delay: .13s; }
.in-view .mail:nth-child(3) { animation-delay: .21s; }
.in-view .mail:nth-child(4) { animation-delay: .29s; }
.in-view .mail:nth-child(5) { animation-delay: .37s; }
@keyframes mailIn { to { opacity: 1; transform: none; } }
.mail__chip {
  flex: none; width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center;
  font-weight: 700; font-size: .9rem; color: var(--c); background: var(--bg);
}
.mail__body { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.mail__body b { font-weight: 600; font-size: .95rem; color: var(--ink); }
.mail__body span { font-size: .82rem; color: var(--ink-soft); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mail__meta { flex: none; display: flex; flex-direction: column; align-items: flex-start; gap: .3rem; }
.mail__meta b { font-weight: 700; font-size: .95rem; font-variant-numeric: tabular-nums; color: var(--navy); }
.tag { font-size: .68rem; font-weight: 600; padding: .2em .6em; border-radius: 100px; }
.tag--red { color: var(--red); background: var(--red-bg); }
.tag--amber { color: var(--amber); background: var(--amber-bg); }
.tag--teal { color: var(--teal); background: var(--teal-bg); }
.tag--blue { color: var(--blue); background: var(--blue-bg); }

/* ============================ SECTIONS ============================ */
section { max-width: var(--maxw); margin: 0 auto; padding: clamp(3.5rem, 8vw, 6.5rem) clamp(1.2rem, 4vw, 3rem); }
.section-head { max-width: 54ch; margin-bottom: 3rem; }
.section-kicker { display: block; font-weight: 700; font-size: .8rem; letter-spacing: .12em; color: var(--ink-soft); text-transform: uppercase; margin-bottom: .8rem; }
.section-title { font-weight: 800; font-size: clamp(1.9rem, 4vw, 3rem); line-height: 1.05; letter-spacing: -.02em; color: var(--navy); margin-bottom: 1rem; }
.section-sub { font-size: clamp(1rem, 1.5vw, 1.15rem); color: var(--ink-soft); }

/* HOW */
.steps { list-style: none; display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.2rem; counter-reset: s; }
.step { background: var(--paper-2); border: 1px solid var(--line); border-radius: var(--r); padding: 1.8rem 1.6rem; position: relative; }
.step__n { display: grid; place-items: center; width: 46px; height: 46px; border-radius: 50%; background: var(--navy); color: var(--paper-2); font-weight: 700; font-size: 1.2rem; margin-bottom: 1rem; }
.step h3 { font-weight: 700; font-size: 1.25rem; color: var(--navy); margin-bottom: .5rem; }
.step p { color: var(--ink-soft); font-size: .98rem; }

/* SENDERS */
.senders__grid { display: flex; flex-wrap: wrap; gap: .7rem; }
.sender {
  font-weight: 600; font-size: .95rem; color: var(--c, var(--navy));
  background: var(--paper-2); border: 1px solid var(--line); border-radius: 100px;
  padding: .6em 1.2em; transition: transform .25s, box-shadow .25s, border-color .25s;
}
.sender:hover { transform: translateY(-3px); box-shadow: var(--shadow-sm); border-color: var(--c, var(--navy)); }
.sender--more { color: var(--ink-soft); background: transparent; border-style: dashed; }

/* FEATURES */
.features__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.1rem; }
.feature { position: relative; overflow: hidden; background: var(--paper-2); border: 1px solid var(--line); border-radius: var(--r); padding: 1.7rem 1.5rem; transition: transform .3s, box-shadow .3s; }
.feature:hover { transform: translateY(-6px); box-shadow: var(--shadow-md); }
.feature__ic { display: grid; place-items: center; width: 54px; height: 54px; border-radius: 14px; background: var(--navy-soft); font-size: 1.5rem; margin-bottom: 1rem; }
.feature h3 { font-weight: 700; font-size: 1.2rem; color: var(--navy); margin-bottom: .5rem; }
.feature p { color: var(--ink-soft); font-size: .96rem; }

/* CATEGORIES */
.cats { max-width: none; background: var(--navy); }
.cats__grid { max-width: var(--maxw); margin: 0 auto; display: grid; grid-template-columns: repeat(5, 1fr); gap: 1rem; }
.cat { border: 1px solid rgba(246,242,231,.14); border-radius: var(--r); padding: 1.4rem 1.2rem; border-top: 3px solid var(--c); transition: background .3s, transform .3s; }
.cat:hover { background: rgba(246,242,231,.05); transform: translateY(-4px); }
.cat b { display: block; color: var(--paper-2); font-weight: 700; font-size: 1.05rem; margin-bottom: .3rem; }
.cat span { color: rgba(246,242,231,.66); font-size: .88rem; }

/* SECURITY (dark) */
.security { max-width: none; background: var(--navy-deep); }
.security > * { max-width: var(--maxw); margin-inline: auto; }
.section-head--light .section-kicker { color: rgba(246,242,231,.6); }
.section-head--light .section-title { color: var(--paper-2); }
.security__grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; }
.sec-card { position: relative; overflow: hidden; border: 1px solid rgba(246,242,231,.14); border-radius: var(--r); padding: 1.5rem 1.3rem; transition: background .3s, transform .3s; }
.sec-card:hover { background: rgba(246,242,231,.05); transform: translateY(-5px); }
.sec-card h3 { font-weight: 700; font-size: 1.15rem; color: var(--paper-2); margin-bottom: .5rem; padding-inline-start: .7rem; border-inline-start: 3px solid var(--amber-bg); }
.sec-card p { color: rgba(246,242,231,.66); font-size: .92rem; }

/* GET / CTA */
.get { text-align: center; }
.get__inner { background: radial-gradient(circle at 50% 0%, var(--navy-soft), var(--paper-2)); border: 1px solid var(--line); border-radius: 32px; padding: clamp(3rem, 7vw, 5rem) 1.5rem; }
.get h2 { font-weight: 800; font-size: clamp(1.8rem, 4.4vw, 3rem); color: var(--navy); margin-bottom: 1rem; letter-spacing: -.02em; }
.get p { color: var(--ink-soft); font-size: 1.15rem; max-width: 46ch; margin: 0 auto 2rem; }
.get__btns { display: flex; gap: .9rem; justify-content: center; flex-wrap: wrap; }
.store { background: var(--navy); color: var(--paper-2); font-weight: 600; padding: .9em 2em; border-radius: 14px; transition: transform .25s, box-shadow .25s; }
.store:hover { transform: translateY(-3px); box-shadow: 0 16px 30px -14px rgba(10,31,61,.6); }

/* FOOTER */
.footer { max-width: var(--maxw); margin: 0 auto; display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 1.5rem; padding: 2.5rem clamp(1.2rem,4vw,3rem) 3rem; border-top: 1px solid var(--line); }
.footer__brand { display: flex; align-items: center; gap: 1rem; }
.footer__logo { height: 24px; }
.footer__brand p { color: var(--ink-soft); font-size: .92rem; max-width: 32ch; }
.footer__meta { display: flex; flex-direction: column; gap: .3rem; color: var(--ink-soft); font-size: .88rem; }

/* ============================ EFFECTS ============================ */
.scroll-progress { position: fixed; top: 0; inset-inline: 0; height: 3px; width: 0; background: linear-gradient(90deg, var(--navy), var(--teal)); z-index: 60; transition: width .08s linear; }

.js .reveal { opacity: 0; transform: translateY(22px); transition: opacity .7s ease, transform .7s cubic-bezier(.2,.8,.2,1); }
.reveal.in { opacity: 1; transform: none; }
.reveal[data-d="1"]{transition-delay:.06s}.reveal[data-d="2"]{transition-delay:.12s}.reveal[data-d="3"]{transition-delay:.2s}.reveal[data-d="4"]{transition-delay:.28s}.reveal[data-d="5"]{transition-delay:.36s}
.js .step, .js .feature, .js .sec-card, .js .sender, .js .cat { opacity: 0; transform: translateY(20px); }
.in-view .step, .in-view .feature, .in-view .sec-card, .in-view .sender, .in-view .cat { opacity: 1; transform: none; transition: opacity .6s ease, transform .6s cubic-bezier(.2,.8,.2,1); }
.in-view .step:nth-child(2){transition-delay:.08s}.in-view .step:nth-child(3){transition-delay:.16s}

/* card cursor spotlight */
.feature::after, .sec-card::after {
  content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; opacity: 0; transition: opacity .35s;
  background: radial-gradient(240px circle at var(--mx,50%) var(--my,50%), rgba(10,31,61,.06), transparent 60%);
}
.sec-card::after { background: radial-gradient(240px circle at var(--mx,50%) var(--my,50%), rgba(246,242,231,.08), transparent 60%); }
.feature:hover::after, .sec-card:hover::after { opacity: 1; }
.feature > *, .sec-card > * { position: relative; }

/* section title underline draw */
.section-title { position: relative; }
.section-title::after { content: ""; position: absolute; inset-inline-start: 0; bottom: -12px; height: 3px; width: 56px; border-radius: 2px; background: var(--navy); transform: scaleX(0); transform-origin: inset-inline-start; transition: transform .6s .15s cubic-bezier(.2,.8,.2,1); }
.section-head--light .section-title::after { background: var(--amber-bg); }
.in-view .section-title::after { transform: scaleX(1); }

/* side dots */
.dots-nav { position: fixed; inset-inline-start: 18px; top: 50%; transform: translateY(-50%); z-index: 45; display: flex; flex-direction: column; gap: 14px; }
.dots-nav a { width: 11px; height: 11px; border-radius: 50%; background: var(--line); transition: transform .25s, background .25s; position: relative; }
.dots-nav a:hover { background: var(--ink-soft); }
.dots-nav a.active { background: var(--navy); transform: scale(1.4); }
.dots-nav a::after { content: attr(data-label); position: absolute; inset-inline-start: 20px; top: 50%; transform: translateY(-50%); white-space: nowrap; font-size: .76rem; font-weight: 600; color: var(--navy); background: var(--paper-2); border: 1px solid var(--line); border-radius: 8px; padding: .2em .7em; opacity: 0; pointer-events: none; transition: opacity .2s; }
.dots-nav a:hover::after { opacity: 1; }
@media (max-width: 980px) { .dots-nav { display: none; } }

/* back to top */
.to-top { position: fixed; inset-block-end: 22px; inset-inline-start: 22px; z-index: 55; width: 48px; height: 48px; border-radius: 50%; cursor: pointer; background: var(--navy); color: var(--paper-2); border: 0; font-size: 1.3rem; box-shadow: 0 10px 26px -10px rgba(10,31,61,.6); opacity: 0; transform: translateY(14px) scale(.9); pointer-events: none; transition: opacity .3s, transform .3s; }
.to-top.show { opacity: 1; transform: none; pointer-events: auto; }
.to-top:hover { background: var(--navy-deep); transform: translateY(-3px); }

@media (prefers-reduced-motion: reduce) {
  *,*::before,*::after { animation: none !important; transition: none !important; }
  .js .reveal, .js .step, .js .feature, .js .sec-card, .js .sender, .js .cat, .mail { opacity: 1 !important; transform: none !important; }
}

/* ============================ RESPONSIVE ============================ */
@media (max-width: 980px) {
  .hero { grid-template-columns: 1fr; }
  .hero__device { order: -1; }
  .steps, .features__grid { grid-template-columns: 1fr 1fr; }
  .cats__grid, .security__grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 760px) {
  .nav__burger { display: block; }
  .nav__cta { display: none; }
  .nav__links { position: absolute; top: 100%; inset-inline: 0; flex-direction: column; align-items: stretch; gap: 0; background: var(--paper); border-bottom: 1px solid var(--line); padding: .4rem 1.2rem 1.2rem; box-shadow: var(--shadow-md); transform: translateY(-12px); opacity: 0; pointer-events: none; transition: opacity .25s, transform .25s; }
  .nav.open .nav__links { transform: none; opacity: 1; pointer-events: auto; }
  .nav__links a { padding: .95rem .2rem; border-bottom: 1px solid var(--line-soft); }
  .nav__links a::after { display: none; }
  .nav__links-cta { display: block; color: var(--navy); font-weight: 700; border-bottom: 0; }
  .steps, .features__grid, .cats__grid, .security__grid { grid-template-columns: 1fr; }
}

/* ===================================================================
   IMPROVEMENTS: stats, word-reveal, shimmer, device total, store icons, breathing
   =================================================================== */

/* device total footer */
.device__foot { display: flex; align-items: center; justify-content: space-between; margin-top: .9rem; padding: .9rem 1rem; background: var(--navy); border-radius: 14px; }
.device__foot span { color: rgba(241,239,232,.78); font-size: .9rem; font-weight: 500; }
.device__foot b { color: var(--paper-2); font-weight: 700; font-size: 1.15rem; font-variant-numeric: tabular-nums; }
.device { animation: floaty 6s ease-in-out infinite; }
@keyframes floaty { 0%,100% { transform: translateY(-4px); } 50% { transform: translateY(4px); } }

/* stats band */
.stats { padding-block: clamp(2.4rem, 5vw, 3.8rem); }
.stats__grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; text-align: center; }
.stat { padding: 1.6rem 1rem; border: 1px solid var(--line); border-radius: var(--r); background: var(--paper-2); transition: transform .3s, box-shadow .3s, border-color .3s; }
.stat:hover { transform: translateY(-5px); box-shadow: var(--shadow-sm); border-color: var(--navy); }
.stat__num { display: block; line-height: 1; font-weight: 800; letter-spacing: -.03em; font-size: clamp(2.3rem, 5vw, 3.4rem); color: var(--navy); font-variant-numeric: tabular-nums; }
.stat__label { display: block; margin-top: .5rem; font-weight: 500; color: var(--ink-soft); font-size: .95rem; }
@media (max-width: 640px) { .stats__grid { grid-template-columns: repeat(2, 1fr); } }

/* word-by-word reveal on section titles */
.section-title .word { display: inline-block; overflow: hidden; vertical-align: bottom; }
.section-title .word > span { display: inline-block; transform: translateY(115%); transition: transform .6s cubic-bezier(.2,.8,.2,1); }
.in-view .section-title .word > span { transform: none; }

/* shimmer on the emphasized hero word */
.hero__title em {
  background: linear-gradient(100deg, var(--navy), #4f6f9e 28%, var(--navy) 55%, #4f6f9e 100%);
  background-size: 300% 100%;
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; color: transparent;
  animation: shimmer 6.5s linear infinite;
}
@keyframes shimmer { to { background-position: -300% 0; } }

/* breathing glow on the GET card */
.get__inner { animation: breathe 5.5s ease-in-out infinite; }
@keyframes breathe {
  0%,100% { box-shadow: 0 0 0 1px var(--line), 0 18px 50px -30px rgba(10,31,61,.3); }
  50%     { box-shadow: 0 0 0 1px var(--navy), 0 26px 72px -26px rgba(10,31,61,.45); }
}

/* store buttons with icons */
.store { display: inline-flex; align-items: center; gap: .7rem; text-align: start; }
.store svg { flex: none; }
.store span { display: flex; flex-direction: column; line-height: 1.1; font-weight: 700; font-size: 1.05rem; }
.store span small { font-weight: 400; font-size: .72rem; opacity: .8; }

/* ===================================================================
   A11Y & PRECISION (web interface guidelines)
   =================================================================== */

/* touch / tap polish */
html { -webkit-tap-highlight-color: rgba(10,31,61,.12); }
a, button, .btn, .store, .nav__burger, .dots-nav a, .to-top { touch-action: manipulation; }

/* visible focus for keyboard users */
:focus-visible { outline: 2px solid var(--navy); outline-offset: 2px; border-radius: 6px; }
.btn:focus-visible, .store:focus-visible, .nav__burger:focus-visible, .to-top:focus-visible { outline-offset: 3px; }
.security :focus-visible, .cats :focus-visible, .to-top:focus-visible { outline-color: var(--paper-2); }

/* skip link */
.skip-link {
  position: fixed; top: 8px; inset-inline-start: 8px; z-index: 100;
  background: var(--navy); color: var(--paper-2); font-weight: 600;
  padding: .6em 1.1em; border-radius: 10px; transform: translateY(-150%); transition: transform .2s;
}
.skip-link:focus { transform: none; }

/* anchored sections clear the sticky nav */
section, #main { scroll-margin-top: 80px; }

/* typographic refinement */
.hero__title, .section-title, .get h2 { text-wrap: balance; }
.hero__lede, .section-sub, .step p, .feature p, .sec-card p, .get p, .footer__brand p { text-wrap: pretty; }

/* back-to-top respects notch safe area */
.to-top { inset-block-end: calc(22px + env(safe-area-inset-bottom)); inset-inline-start: calc(22px + env(safe-area-inset-left)); }

/* reduced-motion: also neutralize the new bits */
@media (prefers-reduced-motion: reduce) {
  .section-title .word > span { transform: none !important; }
  .device, .get__inner, .hero__title em { animation: none !important; }
}

/* ===================================================================
   COMPARE (before/after) + FAQ
   =================================================================== */

.compare__grid { display: grid; grid-template-columns: 1fr auto 1fr; gap: 1.4rem; align-items: stretch; }
.compare__card { border: 1px solid var(--line); border-radius: var(--r); padding: 1.8rem 1.6rem; }
.compare__card--before { background: var(--red-bg); border-color: #E8C4C0; }
.compare__card--after { background: var(--navy); color: var(--paper-2); border-color: var(--navy); }
.compare__tag { display: inline-block; font-weight: 700; font-size: .8rem; padding: .3em .9em; border-radius: 100px; margin-bottom: 1.1rem; background: rgba(122,42,40,.12); color: var(--red); }
.compare__tag--on { background: rgba(246,242,231,.16); color: var(--paper-2); }
.compare__card ul { list-style: none; display: flex; flex-direction: column; gap: .75rem; }
.compare__card li { position: relative; padding-inline-start: 1.7rem; font-size: 1rem; line-height: 1.4; }
.compare__card--before li::before { content: "✕"; position: absolute; inset-inline-start: 0; color: var(--red); font-weight: 700; }
.compare__card--after li { color: rgba(246,242,231,.92); }
.compare__card--after li::before { content: "✓"; position: absolute; inset-inline-start: 0; color: #7FD0A8; font-weight: 700; }
.compare__arrow { align-self: center; font-size: 2rem; color: var(--ink-soft); }
@media (max-width: 840px) {
  .compare__grid { grid-template-columns: 1fr; }
  .compare__arrow { transform: rotate(-90deg); justify-self: center; }
}

/* FAQ */
.faq__list { display: flex; flex-direction: column; gap: .7rem; max-width: 840px; }
.faq__item { border: 1px solid var(--line); border-radius: 16px; background: var(--paper-2); overflow: hidden; transition: border-color .25s; }
.faq__item[open] { border-color: var(--navy); }
.faq__item summary { list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 1.1rem 1.3rem; font-weight: 600; font-size: 1.08rem; color: var(--navy); }
.faq__item summary::-webkit-details-marker { display: none; }
.faq__item summary::after { content: ""; flex: none; width: 10px; height: 10px; border-inline-end: 2px solid var(--ink-soft); border-bottom: 2px solid var(--ink-soft); transform: rotate(45deg); transition: transform .25s; margin-bottom: 4px; }
.faq__item[open] summary::after { transform: rotate(-135deg); margin-bottom: 0; margin-top: 4px; }
.faq__item summary:hover { background: var(--navy-soft); }
.faq__item p { padding: 0 1.3rem 1.2rem; color: var(--ink-soft); line-height: 1.6; }

/* ===================================================================
   FINAL POLISH
   =================================================================== */

/* nav elevation on scroll */
.nav { transition: box-shadow .3s, background .3s; }
.nav.scrolled { background: rgba(241,239,232,.94); box-shadow: 0 1px 0 var(--line), 0 8px 22px -14px rgba(10,31,61,.3); }

/* hero points as check-chips */
.hero__points li { display: inline-flex; align-items: center; background: var(--paper-2); border: 1px solid var(--line); border-radius: 100px; padding: .42em .95em; }
.hero__points li::before { content: "✓"; color: var(--teal); font-weight: 700; margin-inline-end: .45em; }

/* dashed connector behind the 3 steps (desktop) */
.how .steps { position: relative; }
.how .steps::before {
  content: ""; position: absolute; top: calc(1.8rem + 23px); inset-inline: 1.6rem; height: 2px; z-index: 0;
  background: repeating-linear-gradient(90deg, var(--line) 0 7px, transparent 7px 14px);
}
.step { position: relative; z-index: 1; }
@media (max-width: 980px) { .how .steps::before { display: none; } }

/* sender brand dot */
.sender { display: inline-flex; align-items: center; }
.sender::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--c, var(--navy)); margin-inline-end: .55em; flex: none; }
.sender--more::before { display: none; }

/* mail row hover (in the live device) */
.device .mail { transition: transform .2s, box-shadow .2s; }
.device .mail:hover { transform: translateX(-3px); box-shadow: var(--shadow-sm); }

/* branded scrollbar */
html { scrollbar-color: var(--navy) transparent; scrollbar-width: thin; }
::-webkit-scrollbar { width: 12px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--navy); border-radius: 10px; border: 3px solid var(--paper); }
::-webkit-scrollbar-thumb:hover { background: var(--navy-deep); }
