/* Landing, download & privacy pages */
.site-bar {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; justify-content: space-between; gap: var(--sp-3);
  padding: 10px max(var(--sp-4), env(safe-area-inset-right)) 10px max(var(--sp-4), env(safe-area-inset-left));
  background: rgba(0, 4, 54, 0.88); backdrop-filter: blur(12px); border-bottom: 1px solid var(--border);
}
.site-brand img[width="28"] { height: 28px; }
.site-brand { display: inline-flex; align-items: center; gap: 10px; color: var(--text); font-weight: 700; text-decoration: none; }
.site-brand img { display: block; width: auto; height: 26px; }
.site-nav { display: flex; align-items: center; gap: var(--sp-4); flex-wrap: wrap; justify-content: flex-end; }
.site-nav > a { color: var(--text-muted); text-decoration: none; font-weight: 600; font-size: var(--fs-sm); }
.site-nav > a:hover { color: var(--text); }

.btn--lg { min-height: 50px; padding: 12px 22px; font-size: var(--fs-md); border-radius: var(--r-lg); }

.hero { text-align: center; padding: clamp(32px, 6vw, 72px) var(--sp-4) var(--sp-5); }
.hero--compact { padding-top: var(--sp-5); }
.hero h1 { margin: var(--sp-3) 0 var(--sp-2); font-size: clamp(2rem, 1.2rem + 3vw, 3.2rem); letter-spacing: -0.01em; }
.hero-sub { max-width: 64ch; margin: 0 auto var(--sp-4); color: var(--text-muted); font-size: var(--fs-lg); }
.hero-icon { filter: drop-shadow(0 20px 40px rgba(0, 0, 0, 0.6)); }
.hero-cta { margin-bottom: var(--sp-3); }

.tools-grid { display: grid; gap: var(--sp-4); grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
.tool-card {
  display: grid; grid-template-columns: 120px minmax(0, 1fr); gap: var(--sp-4); align-items: center;
  padding: var(--sp-3); border-radius: var(--r-lg); border: 1px solid var(--border);
  background: var(--surface); color: var(--text); text-decoration: none;
  box-shadow: var(--shadow-2); transition: transform var(--t-fast) var(--ease), border-color var(--t-fast);
}
.tool-card:hover { transform: translateY(-3px); border-color: rgba(255, 80, 80, 0.5); color: var(--text); }
.tool-card img { width: 120px; height: 172px; object-fit: cover; object-position: top; border-radius: 12px; border: 1px solid var(--border-strong); background: var(--bg); }
.tool-card h2 { margin: 0 0 6px; font-size: var(--fs-lg); }
.tool-card p { margin: 0; color: var(--text-muted); font-size: var(--fs-sm); }

.features h2 { text-align: center; }
.check-list { list-style: none; padding: 0; display: grid; gap: 10px; }
.check-list li { display: flex; gap: 10px; color: #d3d9f3; }
.check-list li::before { content: "✔"; color: var(--accent); font-weight: 700; }
.support { margin-top: var(--sp-5); }

.todo { color: var(--warn); font-weight: 600; }

@media (max-width: 640px) {
  .site-nav { gap: var(--sp-2); }
  .site-nav > a { display: none; }
  .tool-card { grid-template-columns: 88px minmax(0, 1fr); }
  .site-download .site-nav > a { display: none; }
  .tool-card img { width: 88px; height: 126px; }
}

/* ==========================================================================
   Download page
   ========================================================================== */
.site-download main { overflow-x: clip; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px; padding: 5px 12px 5px 10px;
  border-radius: var(--r-pill); border: 1px solid var(--border-strong); background: rgba(255, 255, 255, 0.04);
  font-size: var(--fs-xs); font-weight: 600; color: var(--text-muted); letter-spacing: 0.02em;
}
.eyebrow-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 0 4px rgba(62, 207, 142, 0.18); }

.dl-hero {
  width: min(1240px, 100% - 2 * var(--sp-4)); margin: 0 auto;
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); gap: clamp(24px, 5vw, 72px); align-items: center;
  padding: clamp(32px, 6vw, 88px) 0 clamp(24px, 4vw, 56px);
}
.dl-hero h1 { margin: 18px 0 14px; font-size: clamp(2.1rem, 1.2rem + 3.4vw, 3.6rem); line-height: 1.05; letter-spacing: -0.025em; }
.dl-lead { margin: 0 0 28px; max-width: 46ch; color: var(--text-muted); font-size: clamp(1rem, 0.95rem + 0.3vw, 1.15rem); line-height: 1.6; }
.dl-cta { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.dl-main-btn {
  display: inline-flex; align-items: center; gap: 14px; min-height: 64px; padding: 10px 24px 10px 14px;
  border-radius: 16px; background: linear-gradient(180deg, #ff6464, #f23d3d); color: #fff; text-decoration: none;
  box-shadow: 0 14px 34px rgba(255, 80, 80, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.25);
  transition: transform var(--t-fast) var(--ease), box-shadow var(--t-fast);
}
.dl-main-btn:hover { color: #fff; transform: translateY(-2px); box-shadow: 0 18px 40px rgba(255, 80, 80, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.25); }
.dl-main-icon { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 12px; background: rgba(0, 0, 0, 0.18); font-size: 1.3rem; font-weight: 700; }
.dl-main-icon svg { width: 24px; height: 24px; }
.dl-main-text { display: grid; line-height: 1.2; }
.dl-main-text strong { font-size: 1.05rem; }
.dl-main-text small { opacity: 0.85; font-size: var(--fs-xs); font-weight: 500; }
.dl-alt { margin: 18px 0 0; font-size: var(--fs-sm); color: var(--text-dim); }
.dl-trust { display: flex; flex-wrap: wrap; gap: 8px 18px; margin: 26px 0 0; padding: 0; list-style: none; font-size: var(--fs-sm); color: var(--text-muted); }
.dl-trust li::before { content: "✓"; margin-right: 6px; color: var(--ok); font-weight: 700; }

.dl-hero-visual { position: relative; padding-bottom: 32px; }
.app-window {
  border-radius: 14px; overflow: hidden; border: 1px solid var(--border-strong);
  background: #0a0f2a; box-shadow: 0 40px 80px rgba(0, 0, 0, 0.6), 0 0 0 1px rgba(255, 255, 255, 0.03);
  transform: perspective(1600px) rotateY(-6deg) rotateX(2deg); transform-origin: left center;
}
.app-window-bar { display: flex; align-items: center; gap: 7px; height: 30px; padding: 0 12px; background: #11183d; border-bottom: 1px solid var(--border); }
.app-window-bar span { width: 11px; height: 11px; border-radius: 50%; background: #3a4370; }
.app-window-bar span:nth-child(1) { background: #ff5f57; } .app-window-bar span:nth-child(2) { background: #febc2e; } .app-window-bar span:nth-child(3) { background: #28c840; }
.app-window-bar em { margin-left: 10px; font-style: normal; font-size: 0.72rem; color: var(--text-dim); }
.app-window img { display: block; width: 100%; height: auto; }
.app-phone {
  position: absolute; right: -8px; bottom: 0; width: 26%; min-width: 110px; padding: 6px;
  border-radius: 22px; background: #070b1f; border: 1px solid var(--border-strong); box-shadow: 0 24px 50px rgba(0, 0, 0, 0.65);
}
.app-phone img { display: block; width: 100%; border-radius: 16px; }

.dl-section { width: min(1240px, 100% - 2 * var(--sp-4)); margin: 0 auto; padding: clamp(32px, 5vw, 64px) 0; }
.dl-section + .dl-section { border-top: 1px solid var(--border); }
.dl-section-head { max-width: 680px; margin-bottom: 28px; }
.dl-section-head h2 { margin: 0 0 8px; font-size: clamp(1.5rem, 1.2rem + 1.2vw, 2.1rem); letter-spacing: -0.015em; }
.dl-section-head p { margin: 0; color: var(--text-muted); }

.dl-platforms { display: grid; gap: 18px; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.dl-card {
  position: relative; display: grid; gap: 18px; align-content: start; padding: 22px;
  border-radius: 20px; border: 1px solid var(--border); background: linear-gradient(180deg, rgba(255, 255, 255, 0.035), transparent 50%), var(--surface);
  box-shadow: var(--shadow-2); transition: border-color var(--t-fast), transform var(--t-fast) var(--ease);
}
.dl-card:hover { border-color: var(--border-strong); transform: translateY(-2px); }
.dl-card.is-current { border-color: rgba(255, 80, 80, 0.65); box-shadow: 0 0 0 4px var(--accent-soft), var(--shadow-2); }
.dl-card-head { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 14px; align-items: center; }
.dl-card-head h3 { margin: 0; font-size: 1.25rem; }
.dl-card-head p { margin: 2px 0 0; font-size: var(--fs-xs); color: var(--text-muted); line-height: 1.4; }
.dl-os-icon { display: grid; place-items: center; width: 48px; height: 48px; border-radius: 14px; background: var(--surface-3); color: var(--text); border: 1px solid var(--border); }
.dl-os-icon svg { width: 26px; height: 26px; }
.dl-card.is-current .dl-os-icon { background: var(--accent); border-color: transparent; color: #fff; }
.dl-pill {
  position: absolute; top: -11px; right: 18px; display: none; padding: 3px 10px; border-radius: var(--r-pill);
  background: var(--accent); color: #fff; font-size: 0.7rem; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase;
}
.dl-card.is-current .dl-pill { display: inline-block; }
.dl-files { display: grid; gap: 8px; }
.dl-file {
  display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 54px; padding: 8px 14px;
  border-radius: 12px; border: 1px solid var(--border-strong); background: var(--bg-elev); color: var(--text); text-decoration: none;
  transition: background var(--t-fast), border-color var(--t-fast);
}
.dl-file:hover { color: var(--text); border-color: rgba(255, 255, 255, 0.35); background: var(--surface-2); }
.dl-file > span:first-child { display: grid; line-height: 1.25; }
.dl-file strong { font-size: var(--fs-sm); }
.dl-file small { font-size: var(--fs-xs); color: var(--text-muted); }
.dl-file-arrow { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 9px; background: rgba(255, 255, 255, 0.06); font-weight: 700; }
.dl-file--primary { border-color: transparent; background: linear-gradient(180deg, #ff6464, #f23d3d); }
.dl-file--primary:hover { background: linear-gradient(180deg, #ff7676, #f54a4a); border-color: transparent; }
.dl-file--primary small { color: rgba(255, 255, 255, 0.85); }
.dl-file--primary .dl-file-arrow { background: rgba(0, 0, 0, 0.18); }
/* only the card of the visitor's system gets the red call-to-action */
.dl-platforms.has-current .dl-card:not(.is-current) .dl-file--primary { background: var(--surface-3); border-color: rgba(255, 255, 255, 0.22); }
.dl-platforms.has-current .dl-card:not(.is-current) .dl-file--primary small { color: var(--text-muted); }
.dl-steps { margin: 0; padding: 14px 0 0; list-style: none; counter-reset: step; border-top: 1px dashed var(--border-strong); display: grid; gap: 8px; }
.dl-steps li { counter-increment: step; position: relative; padding-left: 30px; min-height: 20px; font-size: var(--fs-xs); color: var(--text-muted); line-height: 1.5; }
.dl-steps li::before {
  content: counter(step); position: absolute; left: 0; top: 0; display: grid; place-items: center; width: 20px; height: 20px; border-radius: 50%;
  background: var(--surface-3); color: var(--text); font-size: 0.68rem; font-weight: 700;
}
.dl-steps code { font-size: 0.68rem; white-space: nowrap; }
.dl-note { margin: 22px 0 0; font-size: var(--fs-sm); color: var(--text-muted); }

.dl-flow { margin: 0; padding: 0; list-style: none; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px; counter-reset: flow; }
.dl-flow li {
  position: relative; display: grid; gap: 4px; justify-items: start; padding: 18px;
  border-radius: 16px; border: 1px solid var(--border); background: var(--surface);
}
.dl-flow li:not(:last-child)::after {
  content: "→"; position: absolute; right: -12px; top: 50%; transform: translateY(-50%); z-index: 1;
  display: grid; place-items: center; width: 22px; height: 22px; border-radius: 50%;
  background: var(--bg); border: 1px solid var(--border-strong); color: var(--text-muted); font-size: 0.75rem;
}
.dl-flow li:nth-child(4)::after { content: "·"; }
.dl-flow-ico { font-size: 1.6rem; line-height: 1; margin-bottom: 6px; }
.dl-flow strong { font-size: var(--fs-sm); }
.dl-flow small { color: var(--text-muted); font-size: var(--fs-xs); }

.dl-trust-grid { display: grid; gap: 18px; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.dl-trust-grid .card { margin: 0; display: grid; grid-template-columns: minmax(0, 1fr); gap: 10px; align-content: start; min-width: 0; }
.dl-trust-grid h3 { margin: 0; font-size: var(--fs-lg); }
.dl-trust-grid p { margin: 0; }
.dl-trust-grid .btn { justify-self: start; }
.code-block { position: relative; }
.code-block pre {
  margin: 0; padding: 14px 16px; padding-right: 84px; overflow-x: auto;
  font-family: var(--mono); font-size: var(--fs-xs); line-height: 1.7;
  background: var(--bg); border: 1px solid var(--border); border-radius: var(--r-md);
}
.code-block .btn { position: absolute; top: 8px; right: 8px; }

.dl-faq details { border-bottom: 1px solid var(--border); }
.dl-faq details:first-of-type { border-top: 1px solid var(--border); }
.dl-faq summary {
  display: flex; justify-content: space-between; gap: 12px; padding: 18px 4px; cursor: pointer; list-style: none;
  font-weight: 650;
}
.dl-faq summary::-webkit-details-marker { display: none; }
.dl-faq summary::after { content: "+"; color: var(--text-muted); font-size: 1.3rem; line-height: 1; transition: transform var(--t-fast); }
.dl-faq details[open] summary::after { transform: rotate(45deg); }
.dl-faq details p { margin: 0 4px 18px; max-width: 75ch; color: var(--text-muted); }

@media (max-width: 1100px) {
  .dl-platforms { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .dl-flow { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .dl-flow li::after { display: none; }
}
@media (max-width: 900px) {
  .dl-hero { grid-template-columns: 1fr; }
  .dl-hero-visual { max-width: 640px; }
  .app-window { transform: none; }
  .dl-trust-grid { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  .dl-platforms, .dl-flow { grid-template-columns: 1fr; }
  .dl-main-btn { width: 100%; }
  .dl-cta .btn { width: 100%; }
  .app-phone { display: none; }
}
@media (max-width: 600px) { .dl-card.is-current { order: -1; } }
