/* Junk Cleaner landing — plain CSS, no build step. Same design language as the Flowjar site. */

:root {
  --bg: #FFFFFF;
  --surface: #F5F7FB;
  --line: #E6EAF2;
  --ink: #0A0F1E;
  --soft: #8A93A6;
  --body: #5B6473;
  --accent: #1F6BFF;
  --accent-dark: #1650C7;
  --tint: #EAF1FF;
  --on-ink: #FFFFFF;

  --maxw: 1160px;
  --gutter: clamp(18px, 4vw, 40px);
  --section: clamp(88px, 11vw, 160px);
  --font: -apple-system, "SF Pro Display", "Inter", system-ui, sans-serif;
  --phone-shadow: 36px 56px 80px -34px rgba(10, 30, 80, .34), 0 24px 48px -24px rgba(10, 30, 80, .18);
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html.i18n-wait body { visibility: hidden; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 84px; background: var(--bg); }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } *, *::before, *::after { transition: none !important; } }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: var(--font); font-size: 17px; line-height: 1.55; letter-spacing: -0.011em;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; }
p, h1, h2, h3, ul, ol, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
:focus-visible { outline: 2.5px solid var(--accent); outline-offset: 3px; border-radius: 8px; }
.sr-only { position: absolute !important; width: 1px; height: 1px; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; inset-inline-start: 12px; top: -60px; z-index: 100; padding: 10px 16px; border-radius: 999px; background: var(--ink); color: #fff; font-weight: 600; font-size: 14px; text-decoration: none; }
.skip:focus { top: 12px; }
.container { width: 100%; max-width: calc(var(--maxw) + 2 * var(--gutter)); margin-inline: auto; padding-inline: var(--gutter); }

/* Type */
.display, .h2, .h3 { font-weight: 700; color: var(--ink); text-wrap: balance; }
.display { font-size: clamp(46px, 7.6vw, 104px); line-height: .98; letter-spacing: -0.058em; }
.h2 { font-size: clamp(36px, 5.2vw, 72px); line-height: 1; letter-spacing: -0.052em; }
.h2.sm { font-size: clamp(32px, 4.2vw, 56px); }
.h3 { font-size: clamp(20px, 1.7vw, 24px); line-height: 1.2; letter-spacing: -0.03em; font-weight: 650; }
.display > span, .h2 > span { display: block; }
.soft { color: var(--soft); }
.lead { font-size: clamp(18px, 1.55vw, 21px); line-height: 1.45; font-weight: 500; letter-spacing: -0.02em; color: var(--body); text-wrap: pretty; }
.eyebrow { font-size: 13px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--accent); }
.fine { font-size: 14px; color: var(--body); }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 54px; padding: 0 28px; border-radius: 999px; border: 0;
  background: var(--ink); color: var(--on-ink); font-size: 16px; font-weight: 600; letter-spacing: -0.015em;
  text-decoration: none; white-space: nowrap; cursor: pointer; transition: transform .15s ease, background-color .15s ease;
}
.btn:hover { background: #1c2438; }
.btn:active { transform: scale(.98); }
.btn-sm { min-height: 40px; padding: 0 18px; font-size: 14px; }
.btn-accent { background: var(--accent); }
.btn-accent:hover { background: var(--accent-dark); }
.link-arrow { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; font-size: 16px; letter-spacing: -0.015em; text-decoration: none; padding: 12px 6px; }
.link-arrow span[aria-hidden] { transition: transform .15s ease; }
.link-arrow:hover span[aria-hidden] { transform: translateX(3px); }
[dir="rtl"] .link-arrow span[aria-hidden] { transform: scaleX(-1); }
[dir="rtl"] .link-arrow:hover span[aria-hidden] { transform: translateX(-3px) scaleX(-1); }

/* Nav */
.nav { position: sticky; top: 0; z-index: 50; background: rgba(255,255,255,.82); -webkit-backdrop-filter: saturate(180%) blur(18px); backdrop-filter: saturate(180%) blur(18px); border-bottom: 1px solid transparent; transition: border-color .2s ease; }
.nav.is-scrolled { border-bottom-color: var(--line); }
.nav-inner { display: flex; align-items: center; justify-content: space-between; gap: 12px; height: 68px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 700; font-size: 18px; letter-spacing: -0.03em; }
.brand img { width: 34px; height: 34px; border-radius: 9px; }
.nav-links { display: flex; align-items: center; gap: 4px; }
.nav-links a { padding: 8px 14px; border-radius: 999px; text-decoration: none; font-size: 15px; font-weight: 500; color: var(--body); transition: color .15s, background-color .15s; }
.nav-links a:hover { color: var(--ink); background: var(--surface); }

.nav-links { min-width: 0; white-space: nowrap; }
.nav-right { display: flex; align-items: center; gap: 10px; flex: none; }
.nav-right .btn-sm { white-space: nowrap; }

/* Language picker: a pill showing the current language, with the native <select> laid over it. */
.lang {
  position: relative; flex: none;
  display: inline-flex; align-items: center; gap: 6px;
  height: 40px; padding-inline: 12px 10px;
  border-radius: 999px; background: var(--surface);
  color: var(--body); font-size: 14px; font-weight: 600; letter-spacing: -0.01em;
  white-space: nowrap; cursor: pointer;
  transition: background-color .15s ease, box-shadow .15s ease;
}
.lang:hover { background: var(--line); color: var(--ink); }
.lang:focus-within { box-shadow: 0 0 0 2.5px var(--accent); }
.lang svg { width: 16px; height: 16px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.lang .lang-chev { width: 14px; height: 14px; stroke-width: 2.4; opacity: .7; }
.lang-cur { color: var(--ink); }
.lang-name { display: none; }
@media (min-width: 560px) and (max-width: 979px), (min-width: 1180px) { .lang-name { display: inline; } .lang-short { display: none; } }
.lang select {
  position: absolute; inset: 0; width: 100%; height: 100%;
  opacity: 0; cursor: pointer; border: 0; margin: 0;
  -webkit-appearance: none; appearance: none;
  font-size: 16px; /* no zoom-on-focus in iOS Safari */
}

/* Narrower screens: the section links go, the language picker and the button stay. */
@media (max-width: 979px) { .nav-links { display: none; } }
@media (max-width: 400px) {
  .brand span { display: none; }
  .nav-right { gap: 8px; }
  .nav-right .btn-sm { padding: 0 14px; }
}

/* Phone frame (Android punch-hole) */
.phone {
  --pw: 280px; position: relative; flex: none; width: var(--pw);
  padding: calc(var(--pw) * .028); border-radius: calc(var(--pw) * .13); background: #0B0E16;
  box-shadow: inset 0 0 0 1.5px #3B4050, inset 0 0 0 4px #141824, var(--phone-shadow);
}
.phone img { width: 100%; height: auto; aspect-ratio: 1080 / 2260; object-fit: cover; border-radius: calc(var(--pw) * .105); background: #F4F7FE; }
.phone::before { content: ""; position: absolute; z-index: 1; top: calc(var(--pw) * .05); left: 50%; transform: translateX(-50%); width: calc(var(--pw) * .04); height: calc(var(--pw) * .04); border-radius: 50%; background: #000; }
.phone::after { content: ""; position: absolute; right: -2px; top: 26%; width: 3px; height: 11%; border-radius: 0 3px 3px 0; background: #1E2230; }

/* Hero */
.hero { padding-top: clamp(48px, 8vw, 110px); text-align: center; }
.hero-icon { width: clamp(72px, 7vw, 92px); height: auto; margin: 0 auto 28px; border-radius: 22.5%; box-shadow: 0 14px 30px -12px rgba(31,107,255,.5); }
.hero .display { max-width: 13ch; margin-inline: auto; }
.hero .lead { max-width: 40ch; margin: 28px auto 0; }
.cta-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 10px 22px; margin-top: 36px; }
.play-badge { display: inline-block; --badge-h: 58px; }
.play-badge img { height: var(--badge-h); width: auto; }
.hero .fine { margin-top: 18px; }
.hero-stage { position: relative; overflow: hidden; margin-top: clamp(56px, 7vw, 96px); padding: 8px 0 clamp(72px, 9vw, 130px); }
.hero-stage::before { content: ""; position: absolute; inset: 18% 0 0; background: radial-gradient(60% 60% at 50% 30%, var(--tint), transparent 72%); z-index: -1; }
.hero-phones { display: flex; justify-content: center; align-items: flex-start; gap: clamp(14px, 2.1vw, 34px); }
.hero-phones .phone { --pw: clamp(190px, 22vw, 310px); }
.hero-phones .p-side { --pw: clamp(160px, 18vw, 264px); margin-top: clamp(28px, 4vw, 56px); }
@media (max-width: 700px) { .hero-phones .phone { --pw: 216px; } .hero-phones .p-side { --pw: 176px; margin-top: 40px; } .hero-phones .p-side.r { display: none; } }

/* Statement */
.statement { padding-block: var(--section) 0; text-align: center; }
.statement .h2 { max-width: 18ch; margin-inline: auto; }

/* Steps */
.how { padding-block: var(--section); }
.how-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: clamp(48px, 8vw, 120px); align-items: center; }
.how-media { display: flex; justify-content: center; }
.how-media .phone { --pw: clamp(230px, 24vw, 310px); }
.how-copy .lead { margin-top: 22px; max-width: 34ch; }
.steps { margin-top: 40px; display: grid; gap: 28px; counter-reset: s; }
.steps li { display: grid; grid-template-columns: 52px 1fr; gap: 4px 16px; counter-increment: s; }
.steps li::before { content: counter(s); grid-row: span 2; width: 44px; height: 44px; border-radius: 50%; background: var(--tint); color: var(--accent); font-weight: 700; display: grid; place-items: center; }
.steps .h3 { padding-top: 8px; }
.steps p { color: var(--body); }
@media (max-width: 860px) { .how-grid { grid-template-columns: 1fr; } .how-media { order: -1; } }

/* Feature articles */
.features { padding-bottom: var(--section); display: grid; gap: clamp(80px, 10vw, 150px); }
.feature { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: clamp(48px, 8vw, 120px); align-items: center; }
.feature:nth-child(even) .feature-media { order: -1; }
.feature-media { display: flex; justify-content: center; padding: clamp(28px, 4vw, 56px) 0; background: var(--surface); border-radius: 40px; }
.feature-media .phone { --pw: clamp(220px, 22vw, 290px); }
.feature-copy .h2 { margin-top: 14px; }
.feature-copy .lead { margin-top: 22px; max-width: 36ch; }
.ticks { margin-top: 28px; display: grid; gap: 14px; }
.ticks li { display: grid; grid-template-columns: 24px 1fr; gap: 12px; color: var(--ink); font-weight: 500; }
.ticks svg { width: 22px; height: 22px; margin-top: 2px; color: var(--accent); }
@media (max-width: 860px) { .feature { grid-template-columns: 1fr; gap: 36px; } .feature:nth-child(even) .feature-media { order: 0; } }

/* More tiles */
.more { padding-bottom: var(--section); }
.more-head { text-align: center; margin-bottom: clamp(40px, 5vw, 64px); }
.tiles { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.tile { background: var(--surface); border-radius: 24px; padding: 28px 24px 30px; }
.tile svg { width: 28px; height: 28px; color: var(--accent); margin-bottom: 18px; fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; }
.tile h3 { font-size: 18px; letter-spacing: -0.025em; font-weight: 650; }
.tile p { margin-top: 6px; font-size: 15px; color: var(--body); line-height: 1.45; }
@media (max-width: 960px) { .tiles { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 480px) { .tiles { grid-template-columns: 1fr; } }

/* Promise band */
.promise { background: var(--ink); color: var(--on-ink); border-radius: 40px; margin-inline: var(--gutter); padding: clamp(56px, 8vw, 110px) 0; }
.promise .container { max-width: 1000px; }
.promise .h2 { color: #fff; max-width: 16ch; }
.promise .h2 .soft { color: #7E89A3; }
.promise-grid { margin-top: clamp(40px, 5vw, 64px); display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; }
.promise-grid h3 { font-size: 20px; letter-spacing: -0.025em; font-weight: 650; color: #fff; }
.promise-grid p { margin-top: 8px; color: #A7B0C4; font-size: 16px; }
@media (max-width: 800px) { .promise-grid { grid-template-columns: 1fr; gap: 24px; } }

/* FAQ */
.faq { padding-block: var(--section); }
.faq-grid { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.4fr); gap: clamp(32px, 6vw, 96px); align-items: start; }
.faq-head { position: sticky; top: 100px; }
.faq-head .lead { margin-top: 22px; }
.faq-head .lead a { font-weight: 600; }
.qa { border-top: 1px solid var(--line); }
.qa:last-child { border-bottom: 1px solid var(--line); }
.qa summary { list-style: none; cursor: pointer; padding: 22px 0; padding-inline-end: 40px; font-size: 19px; font-weight: 600; letter-spacing: -0.025em; position: relative; }
.qa summary::-webkit-details-marker { display: none; }
.qa summary::after { content: ""; position: absolute; inset-inline-end: 6px; top: 50%; width: 10px; height: 10px; border-right: 2px solid var(--ink); border-bottom: 2px solid var(--ink); transform: translateY(-70%) rotate(45deg); transition: transform .2s; }
.qa[open] summary::after { transform: translateY(-30%) rotate(-135deg); }
.qa p { padding: 0 0 24px; padding-inline-end: 40px; color: var(--body); }
@media (max-width: 860px) { .faq-grid { grid-template-columns: 1fr; } .faq-head { position: static; } }

/* Final */
.final { padding-block: 0 var(--section); text-align: center; }
.final .hero-icon { margin-bottom: 30px; }
.final .h2 { max-width: 12ch; margin-inline: auto; }
.final .lead { max-width: 34ch; margin: 24px auto 0; }

/* Footer */
.foot { border-top: 1px solid var(--line); padding-block: 36px 48px; }
.foot-inner { display: flex; flex-wrap: wrap; gap: 16px 32px; justify-content: space-between; align-items: center; font-size: 14px; color: var(--body); }
.foot nav { display: flex; gap: 20px; flex-wrap: wrap; }
.foot a { text-decoration: none; }
.foot a:hover { color: var(--ink); text-decoration: underline; }

/* Legal / 404 pages */
.doc { padding-block: clamp(48px, 7vw, 96px) var(--section); max-width: 760px; }
.doc h1 { font-size: clamp(38px, 5vw, 60px); line-height: 1.02; letter-spacing: -0.05em; font-weight: 700; }
.doc .updated { margin-top: 12px; color: var(--body); font-size: 15px; }
.doc h2 { margin-top: 48px; font-size: 24px; letter-spacing: -0.03em; font-weight: 700; }
.doc p, .doc li { margin-top: 12px; color: var(--body); }
.doc ul { list-style: disc; padding-inline-start: 22px; }
.legal-note { margin-top: 14px; padding: 10px 14px; border-radius: 14px; background: var(--surface); font-size: 14px; line-height: 1.45; }
.legal-note[hidden] { display: none; }
.doc a { color: var(--accent); font-weight: 500; }
.doc strong { color: var(--ink); }
.nf { text-align: center; padding-block: clamp(80px, 12vw, 180px); }
.nf .cta-row { margin-top: 32px; }

.mac-btn { display: inline-flex; align-items: center; gap: 10px; min-height: 58px; padding: 0 22px; border-radius: 12px; background: #000; color: #fff; text-decoration: none; font-weight: 600; font-size: 18px; line-height: 1.1; border: 1px solid #a6a6a6; }
.mac-btn small { display: block; font-size: 11px; font-weight: 500; letter-spacing: .02em; }
.mac-btn:hover { background: #1c2438; }
.mac-btn:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }

/* Languages: keep tight tracking and short line heights for Latin only. Arabic, Hindi and Thai break
   with negative tracking, and stacked diacritics (Vietnamese, Thai, Hindi) need more line height. */
html:not([lang="en"]) .display { line-height: 1.08; }
html:not([lang="en"]) .h2 { line-height: 1.1; }
html:is([lang="ar"], [lang="hi"], [lang="th"]) * { letter-spacing: normal !important; }
html:is([lang="hi"], [lang="th"]) :is(.display, .h2) { line-height: 1.3; }
html:is([lang="ja"], [lang="ko"], [lang="zh-Hans"], [lang="zh-Hant"]) :is(.display, .h2) { line-height: 1.2; letter-spacing: -0.02em; }
html[lang="ar"] :is(.display, .h2) { line-height: 1.25; }
/* Copy not translated yet is shown in English inside the mirrored layout. */
[data-i18n-fallback] { unicode-bidi: isolate; }
/* "ch" widths assume Latin; CJK characters are twice as wide. */
html:is([lang="ja"], [lang="ko"], [lang="zh-Hans"], [lang="zh-Hant"]) :is(.hero .display, .statement .h2, .promise .h2, .final .h2) { max-width: 11em; }
html:is([lang="ja"], [lang="ko"], [lang="zh-Hans"], [lang="zh-Hant"]) :is(.lead, .hero .lead) { max-width: 26em; }
