/* Download pages: /downloads (all apps) and /downloads/<app> (device redirect + fallback). Same tokens as style.css. */
:root {
    --bg: #07090C;
    --surface: rgba(255, 255, 255, 0.04);
    --border: rgba(255, 255, 255, 0.08);
    --text: #E9EFEB;
    --muted: rgba(233, 239, 235, 0.56);
    --accent: #2BD98A;
    --radius-btn: 12px;
    --radius-card: 20px;
    --ease: cubic-bezier(0.22, 1, 0.36, 1);
}
* { margin: 0; padding: 0; box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html {
    background-color: var(--bg);
    background-image:
        radial-gradient(120% 90% at 50% -20%, rgba(20,46,40,0.35), transparent 62%),
        radial-gradient(90% 80% at 108% 108%, rgba(16,34,52,0.28), transparent 60%);
    background-attachment: fixed;
    min-height: 100%;
}
body { font-family: 'Inter', system-ui, sans-serif; color: var(--text); -webkit-font-smoothing: antialiased; min-height: 100vh; display: flex; flex-direction: column; }
a { color: inherit; text-decoration: none; }
a:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 6px; }

.dl-top { width: 100%; max-width: 1140px; margin: 0 auto; padding: 24px 24px 0; display: flex; align-items: center; justify-content: space-between; }
.dl-top img { height: 30px; width: auto; display: block; }
.dl-top a.dl-back { font-size: 14px; color: var(--muted); }
.dl-top a.dl-back:hover { color: var(--text); }

.dl-main { flex: 1; width: 100%; max-width: 1140px; margin: 0 auto; padding: 72px 24px 64px; }
.dl-title { font-size: clamp(32px, 5vw, 48px); font-weight: 700; letter-spacing: -0.02em; line-height: 1.08; }
.dl-sub { margin-top: 12px; font-size: 17px; line-height: 1.5; color: var(--muted); max-width: 560px; }

.dl-grid { margin-top: 48px; display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 20px; }
.dl-card {
    display: flex; flex-direction: column; padding: 24px; border-radius: var(--radius-card);
    background: var(--surface); border: 1px solid var(--border);
    transition: border-color .2s var(--ease), transform .2s var(--ease);
}
.dl-card:hover { border-color: rgba(43, 217, 138, 0.4); transform: translateY(-3px); }
.dl-card-head { display: flex; align-items: center; gap: 16px; }
.dl-icon { width: 64px; height: 64px; border-radius: 15px; flex: none; display: block; }
.dl-name { font-size: 20px; font-weight: 600; line-height: 1.2; }
.dl-tag { margin-top: 4px; font-size: 14px; line-height: 1.4; color: var(--muted); }
.dl-card .dl-stores { margin-top: 24px; }

.dl-stores { display: flex; flex-wrap: wrap; gap: 10px; }
.dl-store {
    display: inline-flex; align-items: center; gap: 10px; height: 52px; padding: 0 18px 0 14px;
    border-radius: var(--radius-btn); background: #000; color: #fff; border: 1px solid rgba(255,255,255,0.22);
    font-size: 17px; font-weight: 600; letter-spacing: -0.01em;
    transition: border-color .2s var(--ease), transform .2s var(--ease);
}
.dl-store:hover { border-color: rgba(255,255,255,0.5); transform: translateY(-1px); }
.dl-store:active { transform: scale(.98); }
.dl-store svg { width: 22px; height: 22px; flex: none; }
.dl-store span { display: flex; flex-direction: column; line-height: 1.1; }
.dl-store small { font-size: 11px; font-weight: 500; letter-spacing: 0; opacity: .72; }

/* single app page */
.dl-app { display: grid; grid-template-columns: 1fr auto; gap: 64px; align-items: center; }
.dl-app .dl-icon { width: 96px; height: 96px; border-radius: 22px; margin-bottom: 28px; }
.dl-app .dl-stores { margin-top: 32px; }
.dl-qr { padding: 24px; border-radius: var(--radius-card); background: var(--surface); border: 1px solid var(--border); text-align: center; }
.dl-qr-code { width: 220px; height: 220px; padding: 14px; border-radius: 16px; background: #fff; }
.dl-qr-code svg { display: block; width: 100%; height: 100%; }
.dl-qr p { margin-top: 14px; font-size: 14px; color: var(--muted); }
.dl-redirect { margin-top: 20px; font-size: 14px; color: var(--muted); }

.dl-foot { width: 100%; max-width: 1140px; margin: 0 auto; padding: 24px; font-size: 13px; color: var(--muted); }

@media (max-width: 760px) {
    .dl-main { padding-top: 48px; }
    .dl-app { grid-template-columns: 1fr; gap: 40px; }
    .dl-qr { display: none; }
    .dl-card { padding: 20px; }
    .dl-stores { gap: 8px; }
    .dl-store { padding: 0 14px 0 12px; gap: 8px; font-size: 15px; height: 48px; }
}
