/* CareBot download page — Caretap brand tokens (from the CareBot design system). */
:root {
  color-scheme: light;
  --blue: #4294FF;
  --blue-deep: #2563EB;
  --navy: #0A386A;
  --ink: #121724;
  --ink-2: #475569;
  --mute: #96A3B3;
  --line: #DEE5ED;
  --surface: #F1F5F9;
  --card: #FFFFFF;
  --tint: #E6F1FF;
  --radius: 20px;
}

* { box-sizing: border-box; min-width: 0; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  color: var(--ink);
  font: 16px/1.6 Inter, system-ui, -apple-system, "Segoe UI", sans-serif;
  background:
    radial-gradient(1100px 520px at 12% -10%, #D8E9FF 0%, transparent 60%),
    radial-gradient(900px 480px at 100% 0%, #E9F2FF 0%, transparent 55%),
    var(--surface);
  overflow-x: clip;
}
h1, h2, h3 { font-family: "Plus Jakarta Sans", Inter, sans-serif; margin: 0; line-height: 1.1; text-wrap: balance; }
p { margin: 0; }

.top { padding: 24px max(5vw, 20px); }
.brand { display: inline-flex; border-radius: 10px; }
.brand img { height: 34px; width: auto; display: block; }
.brand:focus-visible { outline: 2px solid var(--blue); outline-offset: 4px; }

main { flex: 1; width: 100%; max-width: 960px; margin: 0 auto; padding: 0 max(5vw, 20px) 56px; }

/* hero */
.hero { text-align: center; padding: clamp(8px, 3vw, 28px) 0 clamp(28px, 4vw, 44px); }
.mascot { width: clamp(104px, 14vw, 140px); height: auto; display: block; margin: 0 auto 18px; animation: float 6s ease-in-out infinite; }
@keyframes float { 50% { transform: translateY(-8px); } }
h1 { font-size: clamp(36px, 5.4vw, 52px); font-weight: 700; letter-spacing: -0.02em; }
.lead { margin: 14px auto 0; max-width: 46ch; font-size: 18px; color: var(--ink-2); }
.detected { margin: 18px auto 0; display: inline-flex; align-items: center; gap: 8px; font-size: 14.5px; font-weight: 500; color: var(--navy); background: var(--tint); border-radius: 999px; padding: 6px 14px; }
.detected::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--blue); }
.detected[hidden] { display: none; }

/* download cards: equal height, button pinned to the bottom */
.cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; align-items: stretch; }
.card {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  background: var(--card);
  border: 1.5px solid var(--line);
  border-radius: var(--radius);
  padding: 28px;
  box-shadow: 0 1px 2px rgba(18, 23, 36, .04), 0 12px 32px -18px rgba(10, 56, 106, .25);
  transition: border-color .25s ease, box-shadow .25s ease, transform .25s ease;
}
.card.recommended { border-color: var(--blue); box-shadow: 0 0 0 4px rgba(66, 148, 255, .14), 0 18px 40px -20px rgba(37, 99, 235, .45); }
.badge { display: none; position: absolute; top: 20px; right: 20px; font-size: 12.5px; font-weight: 600; color: var(--navy); background: var(--tint); border-radius: 999px; padding: 4px 10px; }
.card.recommended .badge { display: inline-block; }
.ico { width: 52px; height: 52px; border-radius: 14px; display: grid; place-items: center; background: var(--tint); color: var(--blue); margin-bottom: 18px; }
.ico svg { width: 26px; height: 26px; }
.card h2 { font-size: 26px; font-weight: 700; }
.req { margin-top: 6px; color: var(--ink-2); }
.meta { margin: 18px 0 24px; display: grid; gap: 6px; font-size: 14.5px; width: 100%; }
.meta div { display: flex; justify-content: space-between; gap: 12px; border-top: 1px solid var(--line); padding-top: 8px; }
.meta dt { color: var(--mute); }
.meta dd { margin: 0; color: var(--ink); font-weight: 500; text-align: right; overflow-wrap: anywhere; }

.btn {
  margin-top: auto;
  width: 100%;
  min-height: 52px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border-radius: 14px;
  font-weight: 600;
  font-size: 16px;
  color: #fff;
  text-decoration: none;
  background: linear-gradient(90deg, var(--blue-deep), var(--blue));
  box-shadow: 0 10px 22px -12px rgba(37, 99, 235, .8);
  transition: filter .2s ease, transform .2s ease;
}
.btn svg { width: 20px; height: 20px; }
.btn:hover { filter: brightness(1.06); transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn:focus-visible { outline: 3px solid var(--navy); outline-offset: 3px; }

/* checksums */
.help { margin-top: 32px; }

.verify { font-size: 14px; color: var(--ink-2); }
.verify summary { cursor: pointer; font-weight: 500; color: var(--ink-2); width: fit-content; padding: 6px 0; }
.verify summary:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; border-radius: 4px; }
.verify dl { margin: 10px 0 0; display: grid; gap: 10px; }
.verify dt { font-weight: 600; color: var(--ink); }
.verify dd { margin: 2px 0 0; }
.verify code { font: 13px/1.5 ui-monospace, SFMono-Regular, Menlo, monospace; overflow-wrap: anywhere; color: var(--ink-2); }

.foot { text-align: center; color: var(--mute); font-size: 13.5px; padding: 24px 20px 32px; }

@media (max-width: 720px) {
  .cards { grid-template-columns: minmax(0, 1fr); }
  .card { padding: 24px; }
  .badge { position: static; margin-bottom: 14px; order: -1; }
  .card.recommended { order: -1; }
  .detected { border-radius: 14px; text-align: left; align-items: flex-start; }
  .detected::before { flex: none; margin-top: 7px; }
}
@media (prefers-reduced-motion: reduce) {
  .mascot { animation: none; }
  .card, .btn { transition: none; }
}
