/* =========================================================================
   Jazzify — download page
   Scope: download.html only. Colour and type tokens come from styles.css so
   dark/light stay one source of truth. Classes are prefixed .lp- / .lbtn.
   ========================================================================= */

:root {
  --lp-accent: var(--brass);
  --lp-brass-glow: rgba(229, 180, 102, .11);
  --lp-brass-line: rgba(229, 180, 102, .30);
  --lp-veil: rgba(11, 13, 16, .84);
  --lp-frame: #0e1116;
  --lp-frame-ink: rgba(242, 239, 232, .56);
}
html[data-theme="light"] {
  --lp-accent: #7f5317;
  --lp-brass-glow: rgba(184, 132, 55, .12);
  --lp-brass-line: rgba(184, 132, 55, .34);
  --lp-veil: rgba(240, 235, 226, .86);
}

body.lp {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-ui);
  font-size: 15px;
  line-height: 1.5;
  overscroll-behavior-y: auto;
}

.lp-shell {
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 clamp(20px, 5vw, 48px);
}

/* ---------- top bar ---------- */
.lp-top {
  position: sticky;
  top: 0;
  z-index: 40;
  background: var(--lp-veil);
  border-bottom: 1px solid var(--line-soft);
  backdrop-filter: saturate(1.1) blur(14px);
  -webkit-backdrop-filter: saturate(1.1) blur(14px);
}
.lp-top-in {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  min-height: 72px;
}
.lp-brand {
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
  text-decoration: none;
}
.lp-wordmark {
  display: block;
  width: 92px;
  height: auto;
}
html[data-theme="light"] .lp-wordmark { filter: brightness(.78) saturate(1.08); }
.lp-nav { display: flex; align-items: center; gap: clamp(16px, 2.2vw, 26px); margin-left: auto; }
.lp-nav a {
  padding: 8px 0;
  border-bottom: 1px solid transparent;
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
  text-decoration: none;
  transition: color 150ms var(--ease), border-color 150ms var(--ease);
}
.lp-nav a:hover { color: var(--text); border-bottom-color: var(--lp-brass-line); }
.lp-top-actions { display: flex; align-items: center; gap: 8px; }
.lp-theme {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border: 1px solid var(--line-soft);
  border-radius: 8px;
  color: var(--muted);
  transition: color 150ms var(--ease), border-color 150ms var(--ease), background 150ms var(--ease);
}
.lp-theme:hover { color: var(--brass-bright); border-color: var(--lp-brass-line); background: var(--surface-2); }
.lp-theme .i-sun { display: none; }
html[data-theme="light"] .lp-theme .i-sun { display: block; }
html[data-theme="light"] .lp-theme .i-moon { display: none; }

/* ---------- buttons ---------- */
.lbtn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  padding: 0 20px;
  border: 1px solid transparent;
  border-radius: 8px;
  font-family: var(--font-ui);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: -.01em;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition: background 150ms var(--ease), border-color 150ms var(--ease),
              color 150ms var(--ease), transform 150ms var(--ease);
}
.lbtn:active { transform: translateY(1px); }
.lbtn--primary { background: var(--brass); border-color: var(--brass); color: var(--brass-ink); }
/* White on light brass is 3.2:1; ink on brass is 5.9:1 */
html[data-theme="light"] .lbtn--primary { color: #1b1409; }
.lbtn--primary:hover { background: var(--brass-bright); border-color: var(--brass-bright); }
.lbtn--ghost { background: transparent; border-color: var(--line-strong); color: var(--text); }
.lbtn--ghost:hover { border-color: var(--brass-deep); color: var(--brass-bright); }
.lbtn--sm { min-height: 38px; padding: 0 14px; font-size: 13px; }
.lp-top .lbtn--sm { min-height: 38px; }

/* ---------- hero ---------- */
.lp-hero { position: relative; overflow: hidden; }
.lp-hero::before {
  content: "";
  position: absolute;
  top: -260px;
  left: -8%;
  width: 70%;
  height: 620px;
  background: radial-gradient(50% 50% at 50% 50%, var(--lp-brass-glow), transparent 72%);
  pointer-events: none;
}
.lp-hero-in {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, .98fr) minmax(0, 1.02fr);
  align-items: center;
  gap: clamp(34px, 5vw, 72px);
  /* block-only: .lp-shell already owns the horizontal inset */
  padding-block: clamp(42px, 5.6vw, 72px) clamp(46px, 6vw, 80px);
}
.lp-hero-copy { min-width: 0; }
.lp-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--lp-accent);
}
.lp-eyebrow::before { content: ""; width: 20px; height: 1px; background: currentColor; opacity: .75; }
.lp-title {
  margin: 18px 0 0;
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(40px, 4.5vw, 60px);
  line-height: .99;
  letter-spacing: -.035em;
  text-wrap: balance;
}
.lp-nb { white-space: nowrap; }
.lp-lede {
  margin: 20px 0 0;
  max-width: 46ch;
  font-size: clamp(15px, 1.1vw, 17px);
  line-height: 1.62;
  color: var(--muted);
}
.lp-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-top: 28px; }
.lp-status {
  margin: 0;
  font-size: 12.5px;
  line-height: 1.45;
  color: var(--lp-accent);
}
.lp-status:empty { display: none; }
.lp-sec-head .lp-status--install { margin-top: -4px; max-width: 64ch; font-size: 13px; line-height: 1.5; color: var(--lp-accent); }

/* ---------- screenshot frames ---------- */
.lp-shot {
  margin: 0;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--lp-frame);
  box-shadow: var(--shadow-2);
}
html[data-theme="light"] .lp-shot { border-color: rgba(46, 37, 25, .24); }
.lp-shot img { display: block; width: 100%; height: auto; border-radius: 9px; }
.lp-shot-cap {
  display: flex;
  flex-direction: column;
  gap: 7px;
  padding: 13px 8px 7px;
}
.lp-shot-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 4px 14px;
}
.lp-shot-kicker {
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--brass);
}
.lp-shot-meta { font-size: 11px; color: var(--lp-frame-ink); }
.lp-shot-cap p { font-size: 13px; line-height: 1.55; color: var(--lp-frame-ink); }
.lp-hero-shot { justify-self: end; width: 100%; max-width: 560px; }
.lp-hero-shot .lp-shot-cap { padding-inline: 10px; }

/* ---------- sections ---------- */
.lp-section { padding: clamp(52px, 6.5vw, 88px) 0; border-top: 1px solid var(--line-soft); }
.lp-sec-head { display: flex; flex-direction: column; gap: 14px; max-width: 800px; margin-bottom: clamp(28px, 4vw, 44px); }
.lp-sec-head h2,
.lp-migrate h2 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(27px, 3.2vw, 40px);
  line-height: 1.08;
  letter-spacing: -.028em;
  text-wrap: balance;
}
.lp-sec-head p { max-width: 64ch; font-size: 15px; line-height: 1.62; color: var(--muted); }

/* ---------- product visuals ---------- */
.lp-showcase { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(16px, 2.4vw, 28px); }
.lp-showcase .lp-shot-cap { padding: 15px 10px 9px; }
.lp-showcase .lp-shot-cap p { font-size: 13.5px; }

/* ---------- migration ---------- */
.lp-migrate {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.02fr) minmax(0, .98fr);
  gap: clamp(28px, 4vw, 62px);
  padding: clamp(26px, 4vw, 48px);
  border: 1px solid var(--line);
  border-radius: 18px;
  background: linear-gradient(158deg, var(--surface-2), var(--surface));
}
.lp-migrate::after {
  content: "";
  position: absolute;
  top: 0;
  left: 12%;
  right: 12%;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--brass), transparent);
  opacity: .5;
}
.lp-migrate h2 { margin-top: 14px; }
.lp-migrate-copy > p { margin-top: 16px; max-width: 52ch; font-size: 15px; line-height: 1.62; color: var(--muted); }
.lp-migrate .lbtn { margin-top: 24px; }
.lp-note { margin-top: 12px !important; max-width: 42ch !important; font-size: 12.5px !important; line-height: 1.5 !important; color: var(--muted-2) !important; }
.lp-migrate-list { display: flex; flex-direction: column; gap: 18px; }
.lp-migrate-list > div { padding-bottom: 18px; border-bottom: 1px solid var(--line-soft); }
.lp-migrate-list > div:last-child { padding-bottom: 0; border-bottom: 0; }
.lp-migrate-list dt {
  display: flex;
  gap: 9px;
  align-items: baseline;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.35;
  color: var(--text);
}
.lp-migrate-list dt::before { content: ""; width: 6px; height: 6px; border-radius: 1px; background: var(--brass); flex: 0 0 auto; transform: translateY(-1px); }
.lp-migrate-list dd { margin: 6px 0 0 15px; font-size: 13.5px; line-height: 1.55; color: var(--muted); }

/* ---------- install ---------- */
.lp-platforms { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: start; gap: 14px; }
.lp-platform {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 26px 24px 24px;
  border: 1px solid var(--line-soft);
  border-radius: 14px;
  background: var(--surface);
}
.lp-platform.is-you { border-color: var(--lp-brass-line); }
.lp-platform .lp-os {
  margin-top: 2px;
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--muted-2);
}
.lp-platform h3 { padding-right: 46px; font-family: var(--font-display); font-weight: 400; font-size: 21px; line-height: 1.15; letter-spacing: -.02em; }
.lp-steps { display: flex; flex-direction: column; gap: 10px; }
.lp-steps li {
  display: grid;
  grid-template-columns: 20px minmax(0, 1fr);
  gap: 10px;
  font-size: 13.5px;
  line-height: 1.5;
  color: var(--muted);
}
.lp-steps li::before {
  content: attr(data-step);
  display: grid;
  place-items: center;
  width: 20px;
  height: 20px;
  border: 1px solid var(--line);
  border-radius: 50%;
  font-size: 10.5px;
  font-weight: 600;
  color: var(--lp-accent);
}
.lp-platform .lbtn { align-self: flex-start; }
.lp-platform .lp-hint { margin-top: auto; padding-top: 6px; font-size: 12px; line-height: 1.5; color: var(--muted); }
.lp-flag {
  display: none;
  position: absolute;
  top: 16px;
  right: 16px;
  padding: 5px 8px;
  border: 1px solid var(--lp-brass-line);
  border-radius: 999px;
  background: var(--lp-brass-glow);
  font-size: 9.5px;
  font-weight: 600;
  letter-spacing: .09em;
  text-transform: uppercase;
  color: var(--lp-accent);
  white-space: nowrap;
}
.lp-platform.is-you .lp-flag { display: inline-block; }

/* ---------- footer ---------- */
.lp-foot { border-top: 1px solid var(--line-soft); padding: 34px 0 44px; }
.lp-foot-in { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 18px 30px; }
.lp-foot .lp-wordmark { width: 84px; opacity: .92; }
.lp-foot-links { display: flex; flex-wrap: wrap; gap: 8px 20px; font-size: 13px; color: var(--muted); }
.lp-foot-links a { text-decoration: none; transition: color 150ms var(--ease); }
.lp-foot-links a:hover { color: var(--text); text-decoration: underline; text-underline-offset: 3px; }
.lp-foot small { display: block; margin-top: 18px; max-width: 70ch; font-size: 12px; line-height: 1.6; color: var(--muted-2); }

/* ---------- responsive ---------- */
@media (max-width: 1080px) {
  .lp-platforms { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .lp-platforms .lp-platform:last-child { grid-column: 1 / -1; }
}
@media (max-width: 1024px) {
  .lp-hero-in { grid-template-columns: minmax(0, 1fr); gap: 34px; }
  .lp-hero-shot { max-width: 640px; width: 100%; margin: 0 auto; }
  .lp-migrate { grid-template-columns: minmax(0, 1fr); gap: 28px; }
}
@media (max-width: 960px) {
  .lp-nav { display: none; }
  .lp-showcase { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 680px) {
  .lp-platforms { grid-template-columns: minmax(0, 1fr); }
  .lp-platforms .lp-platform:last-child { grid-column: auto; }
  .lp-wordmark { width: 80px; }
  .lp-actions .lbtn { flex: 1 1 150px; }
  .lp-foot-in { align-items: flex-start; }
}
@media (max-width: 380px) {
  .lp-top-actions .lbtn--sm { padding: 0 10px; font-size: 12.5px; }
  .lp-title { font-size: 38px; }
}
@media (prefers-reduced-motion: reduce) {
  .lbtn, .lp-theme, .lp-nav a, .lp-foot-links a { transition: none; }
  .lbtn:active { transform: none; }
}

/* ---------- utilities ---------- */
/* .lbtn sets its own display, so [hidden] must win over it (install + recovery buttons). */
[hidden] { display: none !important; }
[id] { scroll-margin-top: 84px; }

/* PWA installation page: trust chips, how-it-works, compact privacy/FAQ */
.lp-chips { display:flex; flex-wrap:wrap; gap:8px; list-style:none; margin:20px 0 0; padding:0; color:var(--text); font-size:13px; line-height:1.3; }
.lp-chips li { display:inline-flex; align-items:center; gap:7px; min-height:30px; padding:4px 11px; border:1px solid var(--line); border-radius:999px; background:var(--surface); }
.lp-chips li::before { content:""; width:5px; height:5px; border-radius:50%; background:var(--brass); flex:0 0 auto; }
.lp-actions { min-height:46px; }
.lp-status { min-height:1.4em; }
#installBtn:not([hidden]) { order:-1; }
.lp-how-list { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:18px; list-style:none; margin:26px 0 0; padding:0; }
.lp-how-list li { display:grid; grid-template-columns:32px minmax(0,1fr); grid-template-rows:auto auto; column-gap:11px; padding:18px; border:1px solid var(--line); border-radius:var(--r-md); background:var(--surface); }
.lp-how-num { grid-row:1 / span 2; display:grid; place-items:center; width:28px; height:28px; border:1px solid var(--lp-brass-line); border-radius:50%; color:var(--brass-bright); font-family:var(--font-display); font-size:15px; }
.lp-how-list strong { color:var(--text); font-size:14px; font-weight:650; align-self:end; }
.lp-how-list li > span:last-child { color:var(--muted); font-size:12.5px; line-height:1.45; margin-top:3px; }
.lp-trust-box { padding:clamp(24px,4vw,38px); border:1px solid var(--line); border-radius:var(--r-lg); background:linear-gradient(135deg, rgba(229,180,102,.06), transparent 70%), var(--surface); }
.lp-trust-box h2 { margin:4px 0 10px; font-family:var(--font-display); font-weight:400; font-size:clamp(25px,3vw,36px); letter-spacing:-.02em; }
.lp-trust-box p { max-width:65ch; color:var(--muted); }
.lp-faq-mini { margin-top:18px; border-top:1px solid var(--line); }
.lp-faq-mini details { border-bottom:1px solid var(--line); }
.lp-faq-mini summary { cursor:pointer; padding:16px 0; color:var(--text); font-weight:600; font-size:14px; list-style:none; display:flex; justify-content:space-between; gap:16px; }
.lp-faq-mini summary::-webkit-details-marker { display:none; }
.lp-faq-mini summary::after { content:"+"; color:var(--brass); font-size:18px; line-height:1; }
.lp-faq-mini details[open] summary::after { content:"−"; }
.lp-faq-mini details p { margin:0 0 16px; max-width:70ch; color:var(--muted); font-size:13px; line-height:1.6; }
.lp-legal { margin:16px 0 0; max-width:70ch; color:var(--dim); font-size:11px; line-height:1.5; }
.lp-lang-note { margin-top:10px; max-width:68ch; padding-left:10px; border-left:2px solid var(--lp-brass-line); color:var(--muted); font-size:12.5px; line-height:1.5; }
@media (max-width:840px) { .lp-how-list { grid-template-columns:minmax(0,1fr); } }
@media (max-width:700px) { .lp-chips { gap:6px; } .lp-how-list li { padding:15px; } }

.lp-lang { display:inline-flex; align-items:center; justify-content:center; min-width:44px; min-height:44px; padding:0 7px; border:1px solid var(--line-soft); border-radius:8px; color:var(--muted); font-size:10px; font-weight:750; letter-spacing:.12em; text-decoration:none; }
.lp-lang:hover { color:var(--brass-bright); border-color:var(--lp-brass-line); background:var(--surface-2); }
@media (max-width:700px) { .lp-lang { min-width:44px; min-height:44px; padding:0 5px; } .lp-top-actions > .lbtn { display:none; } }

/* Platform accordions: current device expanded, others collapsed */
.lp-platform { display:block; padding:0; gap:0; overflow:hidden; }
.lp-platform-summary { list-style:none; display:grid; grid-template-columns:26px minmax(0,1fr) 18px; align-items:center; gap:12px; padding:22px 24px; cursor:pointer; }
.lp-platform-summary::-webkit-details-marker { display:none; }
.lp-platform-summary:focus-visible { outline:2px solid var(--brass-bright); outline-offset:-4px; border-radius:12px; }
.lp-device-icon { width:24px; height:24px; fill:none; stroke:var(--brass-bright); stroke-width:1.5; stroke-linecap:round; stroke-linejoin:round; opacity:.9; }
.lp-platform-head { min-width:0; display:flex; flex-direction:column; gap:3px; }
.lp-platform .lp-flag { position:static; align-self:flex-start; }
.lp-platform-title { display:block; padding:0 0 0; font-family:var(--font-display); font-weight:400; font-size:21px; line-height:1.15; letter-spacing:-.02em; color:var(--text); }
.lp-platform-chevron { width:9px; height:9px; border-right:1.5px solid var(--muted); border-bottom:1.5px solid var(--muted); transform:rotate(45deg); transition:transform 160ms var(--ease); margin-top:-4px; }
.lp-platform[open] .lp-platform-chevron { transform:rotate(225deg); margin-top:4px; }
.lp-platform-body { display:flex; flex-direction:column; gap:12px; padding:0 24px 24px; }
.lp-platform-body .lp-hint { margin-top:0; }
.lp-platform[open] { border-color:var(--line-strong); }
@media (max-width:700px) { .lp-platform-summary { padding:18px; } .lp-platform-body { padding:0 18px 20px; } }

/* Mobile sticky install CTA: appears only after the hero copy scrolls away */
.lp-sticky { display:none; }
@media (max-width:840px) {
  .lp-sticky { display:flex; align-items:center; gap:8px; position:fixed; left:0; right:0; bottom:0; z-index:60; padding:10px max(14px, env(safe-area-inset-left)) calc(10px + env(safe-area-inset-bottom)); background:rgba(11,13,16,.94); border-top:1px solid var(--line-soft); backdrop-filter:blur(14px); -webkit-backdrop-filter:blur(14px); visibility:hidden; transform:translateY(calc(100% + 16px)); transition:transform 180ms var(--ease), visibility 180ms; }
  .lp-sticky.is-visible { visibility:visible; transform:none; }
  .lp-sticky-brand { color:var(--text); font-family:var(--font-display); font-size:18px; margin-right:auto; }
  .lp-sticky .lbtn { min-height:44px; white-space:nowrap; }
  #stickyInstall:not([hidden]) { order:-1; }
  body.lp.has-sticky { padding-bottom: calc(72px + env(safe-area-inset-bottom)); }
}
@media print { .lp-sticky { display:none !important; } }

.lp-shot picture { display:block; }
.lp-hero-shot picture { width:100%; }
