/*
 * AppLock Master — site styles.
 *
 * Fabric's editorial language, adapted: a white page, near-monochrome ink,
 * one light serif carrying the voice, and the brand blue allowed in exactly
 * one role — the glow behind the product. It never fills a button and never
 * colours text; that restraint is the look.
 */
:root {
  --paper: #ffffff;
  --wash: #f3f5f9;
  --press: #0c111d;
  --slate: #2b3140;
  --graphite: #5d6475;
  --ash: #c9ced8;
  --ink: #17307a;
  --signal: #2970ff;
  --rule: #0c111d;

  --serif: "Newsreader", "Iowan Old Style", "Palatino Linotype", Georgia, serif;
  --sans-base: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --sans: var(--sans-base);
  --tag: "Manrope", "Inter", ui-sans-serif, system-ui, sans-serif;

  --display: clamp(2.75rem, 1.6rem + 5.2vw, 5rem);
  --heading: clamp(2.1rem, 1.5rem + 2.6vw, 3.25rem);
  --sub: clamp(1.45rem, 1.25rem + 0.8vw, 1.75rem);
  --body-lg: 1.125rem;
  --body: 1rem;
  --small: 0.875rem;
  --caption: 0.75rem;

  --display-lh: 1.06;
  --display-track: -0.02em;
  --body-lh: 1.6;

  --r-btn: 8px;
  --r-card: 16px;
  --r-lg: 24px;
  --r-pill: 40px;

  --shadow-paper: 0 1px 1px rgba(12, 17, 29, 0.1), 0 2px 4px rgba(12, 17, 29, 0.05);
  --glow: 0 0 80px rgba(41, 112, 255, 0.22);

  --page: 1200px;
  --gutter: clamp(16px, 4vw, 24px);
  color-scheme: light;
}

/* Each script gets a face that actually carries it, and none of them get the
   Latin display tracking: negative letter-spacing breaks Arabic joining and
   splits the headline bar Devanagari and Bengali draw across a word. */
:lang(hi) { --serif: "Noto Serif Devanagari", Georgia, serif; --sans: "Noto Sans Devanagari", var(--sans-base); --display-track: 0; --display-lh: 1.3; --body-lh: 1.75; }
:lang(bn) { --serif: "Noto Serif Bengali", Georgia, serif; --sans: "Noto Sans Bengali", var(--sans-base); --display-track: 0; --display-lh: 1.3; --body-lh: 1.8; }
:lang(am) { --serif: "Noto Serif Ethiopic", Georgia, serif; --sans: "Noto Sans Ethiopic", var(--sans-base); --display-track: 0; --display-lh: 1.3; --body-lh: 1.8; }
:lang(ar) { --serif: "Noto Naskh Arabic", "Geeza Pro", serif; --sans: "Noto Sans Arabic", "Geeza Pro", var(--sans-base); --display-track: 0; --display-lh: 1.35; --body-lh: 1.8; }
:lang(ur) { --serif: "Noto Nastaliq Urdu", "Jameel Noori Nastaleeq", "Noto Naskh Arabic", serif; --sans: "Noto Nastaliq Urdu", "Noto Sans Arabic", var(--sans-base); --display-track: 0; --display-lh: 1.9; --body-lh: 2.1; --display: clamp(2.2rem, 1.4rem + 3.8vw, 3.75rem); }
/* Manrope has no non-Latin glyphs, so labels take the script's own sans. */
:lang(hi), :lang(bn), :lang(am), :lang(ar), :lang(ur) { --tag: var(--sans); }
/* Nastaliq sits small on its baseline; lift the small sizes so labels stay legible. */
:lang(ur) { --body: 1.0625rem; --body-lg: 1.1875rem; --small: 0.9375rem; --caption: 0.8125rem; }
:lang(ur) .nav-links a, :lang(ur) .lang summary { font-size: 1rem; line-height: 1.6; }
:lang(ur) .pill, :lang(ur) .eyebrow, :lang(ur) .row-tag, :lang(ur) .perm thead th, :lang(ur) .footer h2 { font-size: 0.9375rem; line-height: 1.7; font-weight: 600; }

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--press);
  font: 400 var(--body)/var(--body-lh) var(--sans);
  letter-spacing: -0.01em;
  font-feature-settings: "cv11", "ss01";
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}
:lang(ar) body, :lang(ur) body, :lang(hi) body, :lang(bn) body, :lang(am) body { letter-spacing: 0; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--ink); text-decoration: none; border-bottom: 1px solid currentColor; }
a:hover { color: var(--press); }
:focus-visible { outline: 2px solid var(--signal); outline-offset: 3px; border-radius: 4px; }

.wrap { width: 100%; max-width: var(--page); margin-inline: auto; padding-inline: var(--gutter); }
.measure { max-width: 42rem; }

.skip { position: absolute; inset-inline-start: -9999px; }
.skip:focus { inset-inline-start: var(--gutter); top: 12px; z-index: 50; background: var(--paper); padding: 8px 12px; }

/* ---------------------------------------------------------------- nav */
.nav {
  position: sticky; top: env(safe-area-inset-top, 0px); z-index: 20;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: saturate(1.4) blur(10px);
  -webkit-backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid var(--rule);
}
.nav .wrap { display: flex; align-items: center; gap: 24px; min-height: 60px; }
.brand { display: inline-flex; flex: none; align-items: center; gap: 10px; border: 0; color: var(--press); }
.brand img { width: 30px; height: 30px; border-radius: 8px; }
.brand span { font-family: var(--serif); font-size: 1.25rem; font-weight: 400; letter-spacing: -0.01em; white-space: nowrap; }
.nav-links { display: flex; gap: 22px; margin-inline-start: auto; }
.nav-links a { border: 0; color: var(--slate); font-weight: 500; font-size: 0.9375rem; }
.nav-links a:hover, .nav-links a[aria-current="page"] { color: var(--press); }
.nav-links a[aria-current="page"] { box-shadow: inset 0 -1px 0 var(--press); }
.nav-end { display: flex; align-items: center; gap: 12px; }
.nav-links + .nav-end { margin-inline-start: 0; }

.lang { position: relative; }
.lang summary {
  list-style: none; cursor: pointer; display: inline-flex; align-items: center; gap: 6px;
  font: 500 0.875rem/1 var(--sans); color: var(--slate); padding: 9px 10px; border-radius: var(--r-btn);
}
.lang summary::-webkit-details-marker { display: none; }
.lang summary svg { width: 16px; height: 16px; flex: none; }
.row-go svg { width: 100%; height: 100%; display: block; }
.lang summary:hover { background: var(--wash); }
.lang[open] summary { background: var(--wash); }
.lang ul {
  position: absolute; inset-inline-end: 0; top: calc(100% + 6px); margin: 0; padding: 6px;
  list-style: none; min-width: 190px; background: var(--paper);
  border: 1px solid var(--rule); border-radius: var(--r-card); box-shadow: var(--shadow-paper);
}
.lang li a { display: block; border: 0; padding: 8px 10px; border-radius: 8px; color: var(--press); font-size: 0.9375rem; }
.lang li a:hover { background: var(--wash); }
.lang li a[aria-current="true"] { font-weight: 600; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 44px; padding: 10px 16px; border-radius: var(--r-btn);
  background: var(--press); color: var(--paper); border: 1px solid var(--press);
  font: 600 0.9375rem/1.2 var(--sans); letter-spacing: -0.005em; box-shadow: var(--shadow-paper); white-space: nowrap;
  transition: transform 160ms ease, background 160ms ease;
}
.btn:hover { background: #000; color: var(--paper); transform: translateY(-1px); }
.btn svg { width: 18px; height: 18px; flex: none; }
.label-short { display: none; }
.btn-ghost { background: transparent; color: var(--ink); box-shadow: none; border-color: var(--ink); }
.btn-ghost:hover { background: var(--wash); color: var(--press); }
.btn-lg { min-height: 52px; padding: 14px 22px; font-size: 1rem; }

/* --------------------------------------------------------------- hero */
.hero { padding-block: clamp(56px, 8vw, 104px) 0; text-align: center; overflow-x: clip; }
.hero .wrap { display: flex; flex-direction: column; align-items: center; }
.pill {
  display: inline-flex; align-items: center; gap: 8px; padding: 6px 14px; border-radius: var(--r-pill);
  background: var(--wash); color: var(--press);
  font: 700 0.8125rem/1.3 var(--tag); letter-spacing: 0.01em;
}
.pill svg { width: 14px; height: 14px; }
.display {
  margin: 22px 0 0; max-width: 16ch;
  font: 300 var(--display)/var(--display-lh) var(--serif);
  letter-spacing: var(--display-track); text-wrap: balance;
}
.display em { font-style: italic; color: var(--ink); }
:lang(ar) .display em, :lang(ur) .display em, :lang(hi) .display em, :lang(bn) .display em, :lang(am) .display em { font-style: normal; }
.lead {
  margin: 24px 0 0; max-width: 36rem; color: var(--graphite);
  font-size: var(--body-lg); line-height: 1.55; text-wrap: pretty;
}
:lang(hi) .lead, :lang(bn) .lead, :lang(am) .lead, :lang(ar) .lead { line-height: 1.8; }
:lang(ur) .lead { line-height: 2.15; }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; margin-top: 32px; }
.fine { margin: 18px 0 0; color: var(--graphite); font-size: var(--small); }
.fine span + span::before { content: "·"; margin-inline: 8px; color: var(--ash); }

/* The product stack: real store screenshots laid on the table like pages,
   the only place the brand blue is allowed to appear. */
.stack {
  position: relative; width: min(100%, 940px); margin: clamp(48px, 7vw, 80px) auto 0;
  height: clamp(360px, 52vw, 600px);
}
.stack::before {
  content: ""; position: absolute; inset: 18% 12% 6%; border-radius: 50%;
  background: radial-gradient(closest-side, rgba(41, 112, 255, 0.28), rgba(41, 112, 255, 0));
  filter: blur(8px); z-index: 0;
}
.sheet {
  position: absolute; bottom: 0; width: clamp(150px, 27vw, 270px); aspect-ratio: 9 / 16;
  border-radius: var(--r-lg); overflow: hidden; background: var(--paper);
  border: 1px solid var(--rule); box-shadow: var(--glow), var(--shadow-paper);
  transition: transform 420ms cubic-bezier(.2,.7,.2,1);
}
.sheet img { width: 100%; height: 100%; object-fit: cover; }
.sheet:nth-child(1) { inset-inline-start: 4%; transform: rotate(-6deg) translateY(1.5%); z-index: 1; }
.sheet:nth-child(2) { inset-inline-start: 50%; margin-inline-start: calc(clamp(150px, 27vw, 270px) / -2); transform: translateY(-3%); z-index: 3; }
.sheet:nth-child(3) { inset-inline-end: 4%; transform: rotate(5deg) translateY(2%); z-index: 2; }
[dir="rtl"] .sheet:nth-child(2) { margin-inline-start: 0; margin-inline-end: calc(clamp(150px, 27vw, 270px) / -2); inset-inline-start: auto; inset-inline-end: 50%; }
.stack:hover .sheet:nth-child(1) { transform: rotate(-8deg) translate(-3%, 0.5%); }
.stack:hover .sheet:nth-child(3) { transform: rotate(7deg) translate(3%, 1%); }
.stack-rule { height: 1px; background: var(--rule); margin: 0; border: 0; }

/* -------------------------------------------------------------- sections */
.section { padding-block: clamp(64px, 9vw, 112px); }
.section + .section { padding-top: 0; }
.eyebrow { margin: 0 0 14px; color: var(--graphite); font: 700 0.8125rem/1.3 var(--tag); letter-spacing: 0.08em; text-transform: uppercase; }
:lang(ar) .eyebrow, :lang(ur) .eyebrow, :lang(hi) .eyebrow, :lang(bn) .eyebrow, :lang(am) .eyebrow { letter-spacing: 0; }
.h2 {
  margin: 0; font: 300 var(--heading)/1.1 var(--serif); letter-spacing: var(--display-track); text-wrap: balance; max-width: 20ch;
}
.h2 em { font-style: italic; color: var(--ink); }
:lang(ar) .h2, :lang(ur) .h2, :lang(hi) .h2, :lang(bn) .h2, :lang(am) .h2 { line-height: 1.45; }
:lang(ur) .h2 { line-height: 1.95; }
.section-head { display: grid; gap: 18px; margin-bottom: clamp(32px, 5vw, 56px); }
.section-head p { margin: 0; color: var(--graphite); font-size: var(--body-lg); max-width: 38rem; }

/* The feature index: rows, not cards. A hairline, a serif name, one plain
   sentence and a way in. */
.index { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--rule); }
.index li { border-bottom: 1px solid var(--rule); }
.index a, .index .row {
  display: grid; grid-template-columns: minmax(0, 15rem) minmax(0, 1fr) auto; gap: 8px 32px; align-items: baseline;
  padding-block: 26px; border: 0; color: inherit;
}
.index a:hover .row-name { color: var(--ink); }
.index a:hover .row-go { transform: translateX(4px); }
[dir="rtl"] .index a:hover .row-go { transform: translateX(-4px) scaleX(-1); }
.row-name { font: 400 var(--sub)/1.2 var(--serif); letter-spacing: var(--display-track); transition: color 160ms; }
.row-text { color: var(--graphite); margin: 0; }
.row-go { width: 22px; height: 22px; color: var(--press); transition: transform 200ms; }
[dir="rtl"] .row-go { transform: scaleX(-1); }
.row-tag { font: 700 0.75rem/1 var(--tag); color: var(--graphite); background: var(--wash); padding: 6px 10px; border-radius: var(--r-pill); white-space: nowrap; }

/* Setup is a genuine sequence, so it is numbered. */
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; counter-reset: step; }
.steps li { background: var(--wash); border-radius: var(--r-card); padding: 26px 24px 28px; counter-increment: step; }
.steps li::before {
  content: counter(step); display: block; margin-bottom: 18px;
  font: 300 2.5rem/1 var(--serif); color: var(--ink); font-variant-numeric: lining-nums;
}
.steps h3 { margin: 0 0 8px; font: 600 1.0625rem/1.35 var(--sans); }
.steps p { margin: 0; color: var(--graphite); }

/* Permissions: what a privacy app asks for, said out loud. */
.perm-wrap { overflow-x: auto; border: 1px solid var(--rule); border-radius: var(--r-card); }
.perm { width: 100%; border-collapse: collapse; min-width: 560px; }
.perm th, .perm td { text-align: start; padding: 18px 22px; vertical-align: top; }
.perm thead th { font: 700 0.75rem/1.3 var(--tag); letter-spacing: 0.08em; text-transform: uppercase; color: var(--graphite); border-bottom: 1px solid var(--rule); }
:lang(ar) .perm thead th, :lang(ur) .perm thead th, :lang(hi) .perm thead th, :lang(bn) .perm thead th, :lang(am) .perm thead th { letter-spacing: 0; }
.perm tbody tr + tr td, .perm tbody tr + tr th { border-top: 1px solid var(--ash); }
.perm tbody th { font-weight: 600; white-space: nowrap; }
.perm td:last-child { color: var(--graphite); white-space: nowrap; }
.perm-note { margin: 16px 0 0; color: var(--graphite); font-size: var(--small); }

/* Article layout for the feature pages. */
.article { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 20rem); gap: clamp(32px, 6vw, 88px); align-items: start; }
.prose > * + * { margin-top: 1.1em; }
.prose h2 { margin-top: 2.2em; font: 400 var(--sub)/1.25 var(--serif); letter-spacing: var(--display-track); text-wrap: balance; }
:lang(ur) .prose h2 { line-height: 1.9; }
.prose h2:first-child { margin-top: 0; }
.prose p, .prose li { color: var(--slate); max-width: 40rem; }
.prose ul, .prose ol { padding-inline-start: 1.2em; }
.prose li + li { margin-top: 0.5em; }
.prose strong { color: var(--press); font-weight: 600; }
.limits { background: var(--wash); border-radius: var(--r-card); padding: 26px 28px; }
.limits h2 { margin-top: 0 !important; }
.limits ul { margin-bottom: 0; }
.aside { position: sticky; top: calc(env(safe-area-inset-top, 0px) + 92px); display: grid; gap: 20px; }
.aside .sheet { position: relative; width: 100%; transform: none; inset: auto; margin: 0; }
.aside-cta { display: grid; gap: 10px; }
.aside-cta p { margin: 0; color: var(--graphite); font-size: var(--small); }

/* FAQ */
.faq { border-top: 1px solid var(--rule); }
.faq details { border-bottom: 1px solid var(--rule); }
.faq summary {
  list-style: none; cursor: pointer; display: flex; justify-content: space-between; gap: 24px; align-items: baseline;
  padding-block: 22px; font: 400 1.25rem/1.35 var(--serif); letter-spacing: var(--display-track);
}
:lang(ur) .faq summary { line-height: 1.9; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font: 300 1.5rem/1 var(--sans); color: var(--graphite); transition: transform 200ms; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { margin: 0 0 24px; max-width: 42rem; color: var(--slate); }

/* Closing band */
.closing { text-align: center; }
.closing .wrap { display: flex; flex-direction: column; align-items: center; gap: 22px; }
.closing .h2 { max-width: 18ch; margin-inline: auto; }

/* Footer */
.footer { border-top: 1px solid var(--rule); padding-block: 48px 40px; color: var(--graphite); font-size: var(--small); }
.footer .wrap { display: grid; grid-template-columns: minmax(0, 1.4fr) repeat(2, minmax(0, 1fr)); gap: 32px; }
.footer h2 { margin: 0 0 12px; font: 700 0.75rem/1.3 var(--tag); letter-spacing: 0.08em; text-transform: uppercase; color: var(--press); }
.footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.footer a { color: var(--slate); border: 0; }
.footer a:hover { color: var(--press); }
.footer .legal { grid-column: 1 / -1; padding-top: 24px; border-top: 1px solid var(--ash); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; }
.footer .about p { margin: 12px 0 0; max-width: 28rem; }

/* ------------------------------------------------------------ responsive */
@media (max-width: 900px) {
  .article { grid-template-columns: minmax(0, 1fr); }
  .aside { position: static; max-width: 22rem; }
  .steps { grid-template-columns: minmax(0, 1fr); }
  .footer .wrap { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .footer .about { grid-column: 1 / -1; }
}
@media (max-width: 760px) {
  .nav-links { display: none; }
  .nav-end { margin-inline-start: auto; }
  .nav .btn .label-long { display: none; }
  .nav .btn .label-short { display: inline; }
  .index a, .index .row { grid-template-columns: minmax(0, 1fr) auto; padding-block: 22px; }
  .row-text { grid-column: 1 / -1; grid-row: 2; }
  .sheet:nth-child(1) { inset-inline-start: -2%; }
  .sheet:nth-child(3) { inset-inline-end: -2%; }
}
@media (max-width: 480px) {
  /* The globe alone names the switcher here; it carries an aria-label. */
  .lang summary span { display: none; }
  .nav .wrap { gap: 10px; }
  .nav .btn { padding-inline: 12px; font-size: 0.875rem; gap: 6px; }
  .brand { gap: 8px; }
  .brand span { font-size: 1.125rem; }
  .cta-row { flex-direction: column; align-self: stretch; }
  .cta-row .btn { width: 100%; }
  .footer .wrap { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 370px) {
  .nav .btn svg { display: none; }
  .brand img { width: 26px; height: 26px; }
}
@media (max-width: 340px) {
  .nav .wrap { gap: 8px; }
  .brand span { font-size: 1rem; }
  .nav .btn { padding-inline: 10px; font-size: 0.8125rem; }
  .lang summary { padding-inline: 6px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; }
}
