/* Download page — extends the shared design system (styles.css). Light ground. */

.dl-main { padding-top: clamp(48px, 7vw, 84px); }

/* hero ------------------------------------------------------------------ */
.dl-hero { text-align: center; padding-bottom: clamp(28px, 4vw, 44px); }
.dl-hero h1 { font-size: clamp(38px, 6vw, 60px); font-weight: 700; letter-spacing: -0.02em; }
.dl-hero h1 .accent { color: var(--primary); }
.dl-hero .sub { color: var(--muted); font-size: clamp(17px, 2.2vw, 20px); margin: 18px auto 0; max-width: 46ch; }

/* detected primary CTA */
.dl-primary-wrap { margin-top: clamp(28px, 4vw, 40px); display: flex; flex-direction: column; align-items: center; gap: 12px; min-height: 96px; }
.dl-primary {
  display: inline-flex; align-items: center; gap: 14px;
  padding: 17px 30px; border-radius: 14px;
  background: var(--primary); color: var(--surface);
  font-family: var(--font-display); font-weight: 600; font-size: 19px;
  text-decoration: none; border: 1px solid transparent;
  box-shadow: 0 18px 40px -18px rgba(185, 90, 60, 0.7);
  transition: transform .14s ease, background .15s ease, box-shadow .15s ease;
}
.dl-primary:hover { background: var(--primary-hover); transform: translateY(-2px); box-shadow: 0 22px 46px -18px rgba(185, 90, 60, 0.8); }
.dl-primary:active { transform: translateY(0); }
.dl-primary svg { width: 26px; height: 26px; fill: currentColor; }
.dl-primary .lbl { display: flex; flex-direction: column; align-items: flex-start; line-height: 1.1; }
.dl-primary .lbl small { font-family: var(--font-mono); font-weight: 400; font-size: 11.5px; opacity: 0.85; margin-top: 3px; }
.dl-primary-note { font-family: var(--font-mono); font-size: 12.5px; color: var(--faint); }
.dl-primary-note a { color: var(--muted); }
.dl-primary.soon { background: var(--surface-2); color: var(--muted); border-color: var(--line-strong); box-shadow: none; cursor: default; }
.dl-primary.soon:hover { transform: none; }

/* platform cards -------------------------------------------------------- */
.dl-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: clamp(36px, 5vw, 56px); }
@media (max-width: 780px) { .dl-grid { grid-template-columns: 1fr; max-width: 420px; margin-inline: auto; } }

.dl-card {
  position: relative; background: var(--surface);
  border: 1px solid var(--line-strong); border-radius: var(--r);
  padding: 26px 24px 24px; display: flex; flex-direction: column; align-items: flex-start;
  transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}
.dl-card.detected {
  border-color: var(--primary);
  box-shadow: 0 0 0 1px var(--primary), 0 26px 50px -30px rgba(46, 41, 38, 0.5);
  transform: translateY(-4px);
}
.dl-badge {
  position: absolute; top: -11px; left: 24px;
  background: var(--accent); color: #3a2708;
  font-family: var(--font-mono); font-size: 11px; font-weight: 600;
  letter-spacing: 0.04em; text-transform: uppercase;
  padding: 4px 10px; border-radius: 999px;
}
.dl-ico {
  width: 52px; height: 52px; border-radius: 13px;
  background: var(--inset); display: grid; place-items: center; margin-bottom: 16px;
}
.dl-ico svg { width: 28px; height: 28px; fill: var(--ink); }
.dl-card.detected .dl-ico { background: color-mix(in srgb, var(--primary) 14%, var(--surface)); }
.dl-card.detected .dl-ico svg { fill: var(--primary); }
.dl-card h3 { font-family: var(--font-display); font-weight: 600; font-size: 20px; margin: 0; }
.dl-card .arch { font-family: var(--font-mono); font-size: 12px; color: var(--faint); margin: 4px 0 16px; }
.dl-formats { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 20px; }
.dl-fmt {
  font-family: var(--font-mono); font-size: 12px; color: var(--muted);
  background: var(--inset); border: 1px solid var(--line); border-radius: 999px; padding: 4px 11px;
  text-decoration: none; transition: border-color .12s ease, color .12s ease;
}
.dl-fmt:hover { border-color: var(--primary); color: var(--primary); }
.dl-card .dl-get { margin-top: auto; width: 100%; }
.dl-get .btn { width: 100%; justify-content: center; }
.dl-get .btn.soon { background: transparent; color: var(--faint); border: 1px dashed var(--line-strong); cursor: default; font-weight: 500; }

/* install / terminal ---------------------------------------------------- */
.dl-install { margin-top: clamp(48px, 7vw, 80px); display: grid; grid-template-columns: 1fr 1fr; gap: clamp(28px, 4vw, 48px); align-items: center; }
@media (max-width: 820px) { .dl-install { grid-template-columns: 1fr; } }
.dl-install h2 { font-size: clamp(24px, 3.4vw, 34px); font-weight: 600; }
.dl-install p { color: var(--muted); margin: 14px 0 0; }
.dl-install .os-tabs { display: flex; gap: 8px; margin-top: 20px; flex-wrap: wrap; }
.dl-tab { font-family: var(--font-mono); font-size: 13px; padding: 7px 14px; border-radius: 999px; border: 1px solid var(--line-strong); background: transparent; color: var(--muted); cursor: pointer; }
.dl-tab[aria-selected="true"] { background: var(--ink); color: var(--surface); border-color: var(--ink); }

.term {
  background: var(--d-paper); border: 1px solid var(--d-line); border-radius: var(--r);
  overflow: hidden; font-family: var(--font-mono); font-size: 13.5px;
  box-shadow: 0 30px 60px -34px rgba(46, 41, 38, 0.55);
}
.term-bar { display: flex; align-items: center; gap: 7px; padding: 12px 16px; background: var(--d-surface); border-bottom: 1px solid var(--d-line); }
.term-bar i { width: 11px; height: 11px; border-radius: 50%; display: block; }
.term-bar .t { margin-left: 8px; color: var(--d-faint); font-size: 12px; }
.term-body { padding: 18px 18px 20px; color: var(--d-ink); line-height: 1.7; overflow-x: auto; }
.term-body .c { color: var(--d-muted); }        /* comment */
.term-body .p { color: var(--d-accent); }        /* prompt $ */
.term-body .cmd { color: var(--d-ink); white-space: pre; }
.term-body .s { color: var(--d-running); }        /* string/flag */
.copy-btn {
  margin-left: auto; font-family: var(--font-body); font-size: 12px; font-weight: 600;
  color: var(--d-muted); background: transparent; border: 1px solid var(--d-line);
  border-radius: 7px; padding: 4px 10px; cursor: pointer; transition: color .12s, border-color .12s;
}
.copy-btn:hover { color: var(--d-ink); border-color: var(--d-faint); }

/* meta strip ------------------------------------------------------------ */
.dl-meta { margin-top: clamp(48px, 7vw, 80px); display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; }
@media (max-width: 720px) { .dl-meta { grid-template-columns: 1fr; } }
.dl-meta .cell { background: var(--surface); padding: 22px 24px; }
.dl-meta .cell h4 { font-family: var(--font-mono); font-size: 11.5px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--faint); margin: 0 0 10px; font-weight: 500; }
.dl-meta .cell p { margin: 0; font-size: 14.5px; color: var(--muted); }
.dl-meta .cell p b { color: var(--ink); font-weight: 600; }
.dl-meta .cell code { font-family: var(--font-mono); font-size: 12.5px; color: var(--accent-ink); word-break: break-all; }

.dl-reassure { margin-top: clamp(40px, 6vw, 64px); text-align: center; }
.dl-reassure .row { display: flex; justify-content: center; gap: 12px 30px; flex-wrap: wrap; margin-top: 16px; }
.dl-reassure .row span { font-size: 14.5px; color: var(--muted); display: inline-flex; align-items: center; gap: 8px; }
.dl-reassure .row span::before { content: ""; width: 7px; height: 7px; border-radius: 2px; background: var(--accent); }
