/**
 * Get the app (TINL-1464): /downloads.html. The real app on a computer and a phone (pictures of the demo church),
 * then one card per device. "Daylight": paper, ink, ONE accent, no gradients; the motion is the entrance of the
 * two devices and the cards (data-reveal). The card for the visitor's own device carries .is-mine (js/downloads.js).
 */
.dl-page { max-width: 1180px; margin: 0 auto; padding: clamp(20px, 4vw, 48px) clamp(16px, 3vw, 32px) 56px; }
.dl-hero { display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); gap: clamp(20px, 4vw, 56px); align-items: center; }
.dl-eyebrow { display: inline-block; margin-bottom: 10px; color: var(--brand); font: 700 0.78rem/1 var(--font-body); letter-spacing: 0.12em; text-transform: uppercase; }
.dl-hero h1 { margin: 0 0 12px; font: 800 clamp(2rem, 1.3rem + 2.6vw, 3.2rem)/1.05 var(--font-body); letter-spacing: -0.04em; color: var(--text); text-wrap: balance; }
.dl-sub { margin: 0 0 22px; max-width: 520px; color: var(--text-muted); font-size: 1.08rem; line-height: 1.55; }
.dl-hero-copy .btn { margin: 0 8px 8px 0; }
.dl-free { margin: 10px 0 0; color: var(--text-muted); font-size: 0.86rem; }

/* the two devices: drawn in CSS around the real screens */
.dl-devices { position: relative; padding: 0 0 18px 0; animation: dl-rise 640ms var(--ease-out) 80ms both; }
.dl-laptop { position: relative; margin-right: 9%; }
.dl-screen { padding: 9px 9px 0; border: 1px solid var(--border-strong); border-bottom: 0; border-radius: 16px 16px 0 0; background: var(--solid); box-shadow: var(--shadow-lg); }
.dl-screen img { display: block; width: 100%; height: auto; border-radius: 8px 8px 0 0; }
.dl-base { display: block; height: 12px; margin: 0 -5%; border: 1px solid var(--border-strong); border-radius: 0 0 14px 14px; background: var(--bg-active); }
.dl-phone { position: absolute; right: 0; bottom: 0; width: 23%; padding: 6px; border: 1px solid var(--border-strong); border-radius: 22px; background: var(--solid); box-shadow: var(--shadow-lg); animation: dl-rise 700ms var(--ease-out) 260ms both, dl-float 7s ease-in-out 1.2s infinite alternate; }
.dl-phone img { display: block; width: 100%; height: auto; border-radius: 16px; }
@keyframes dl-rise { from { opacity: 0; transform: translateY(18px); } }
@keyframes dl-float { to { transform: translateY(-8px); } }

/* one card per device */
.dl-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-top: clamp(28px, 5vw, 56px); }
.dl-card { display: flex; flex-direction: column; padding: 22px; border: 1px solid var(--border); border-radius: var(--radius-lg); background: var(--bg-card); transition: transform 220ms var(--ease-out), box-shadow 220ms, border-color 220ms; }
.dl-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); }
.dl-card.is-mine { order: -1; border-color: var(--brand); box-shadow: 0 0 0 1px var(--brand); }
.dl-ico { display: grid; place-items: center; width: 42px; height: 42px; margin-bottom: 14px; border-radius: 12px; background: var(--bg-subtle); color: var(--text); }
.dl-card.is-mine .dl-ico { background: var(--brand-soft); color: var(--brand); }
.dl-ico svg { width: 22px; height: 22px; }
.dl-card h2 { margin: 0 0 6px; font: 750 1.2rem/1.2 var(--font-body); letter-spacing: -0.02em; color: var(--text); }
.dl-line { flex: 1; margin: 0 0 16px; color: var(--text-muted); font-size: 0.95rem; line-height: 1.5; }
.dl-btns { display: flex; flex-wrap: wrap; gap: 8px; }
.dl-btns .btn svg { width: 16px; height: 16px; }
.dl-card:not(.is-mine) .dl-btns .btn-primary { background: transparent; color: var(--text); border-color: var(--border-strong); box-shadow: none; }   /* ONE main button on the page: the visitor's own device */
.dl-card:not(.is-mine) .dl-btns .btn-primary:hover { background: var(--bg-hover); }
.dl-how { margin-top: 14px; border-top: 1px solid var(--border-light); padding-top: 12px; }
.dl-how summary { cursor: pointer; color: var(--text-secondary); font: 600 0.88rem/1.4 var(--font-body); list-style: none; }
.dl-how summary::-webkit-details-marker { display: none; }
.dl-how summary::before { content: '+'; display: inline-block; width: 1.1em; color: var(--brand); font-weight: 700; }
.dl-how[open] summary::before { content: '\2212'; }
.dl-how ol { margin: 10px 0 0; padding-left: 1.3em; color: var(--text-muted); font-size: 0.9rem; line-height: 1.55; }
.dl-how li + li { margin-top: 4px; }
.dl-note { margin: 12px 0 0; color: var(--text-muted); font-size: 0.82rem; }
.dl-foot { margin: 28px 0 0; text-align: center; color: var(--text-muted); font-size: 0.85rem; }
.dl-foot a { color: var(--text-secondary); }
.dl-page :focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }

@media (max-width: 980px) { .dl-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 820px) { .dl-hero { grid-template-columns: minmax(0, 1fr); } .dl-devices { max-width: 560px; } }
@media (max-width: 600px) { .dl-grid { grid-template-columns: minmax(0, 1fr); } .dl-hero-copy .btn { width: 100%; margin-right: 0; justify-content: center; } .dl-card { padding: 18px; } }
/* inside an app there is nothing to download: the page says so with its cards muted by the shell's own rules;
   in a store app the downloads are not offered at all (store rules) */
html.in-store-app .dl-grid, html.in-store-app .dl-best { display: none; }
@media (prefers-reduced-motion: reduce) { .dl-devices, .dl-phone { animation: none; } .dl-card:hover { transform: none; } }

/* the app stores (os/tb-os.js TBOS.stores fills these boxes; hidden until a store is live) */
.dl-hero-stores { margin-top: 14px; }
.dl-stores { margin-bottom: 10px; }
