/* Public download page for the native Panel FMCG apps (replaces the old PWA). */
:root {
  --bg: #f7f2e8;
  --bg2: #fffdf9;
  --card: #fffdf9;
  --ink: #1c1b18;
  --muted: #6b645a;
  --line: rgba(28, 27, 24, .12);
  --marker: rgba(231, 207, 147, .55);
  --badge: #111;
  --badge-ink: #fff;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0b0d11;
    --bg2: #12151b;
    --card: #151920;
    --ink: #f3efe6;
    --muted: #a49d90;
    --line: rgba(255, 255, 255, .12);
    --marker: rgba(231, 207, 147, .32);
    --badge: #f3efe6;
    --badge-ink: #111;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0b0d11;
  --bg2: #12151b;
  --card: #151920;
  --ink: #f3efe6;
  --muted: #a49d90;
  --line: rgba(255, 255, 255, .12);
  --marker: rgba(231, 207, 147, .32);
  --badge: #f3efe6;
  --badge-ink: #111;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  background: linear-gradient(180deg, var(--bg2), var(--bg));
  color: var(--ink);
  font: 16px/1.5 system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; }

.dl-wrap {
  width: 100%;
  max-width: 1040px;
  margin: 0 auto;
  padding: max(20px, env(safe-area-inset-top)) 20px 0;
}

.dl-main { flex: 1; display: grid; gap: 40px; align-items: center; padding-top: 40px; padding-bottom: 32px; }
.dl-icon .dl-logo { width: 88px; height: 88px; border-radius: 21px; box-shadow: 0 10px 30px rgba(0, 0, 0, .12), 0 0 0 1px var(--line); }

.dl-title { margin: 22px 0 14px; font-size: clamp(30px, 7vw, 46px); line-height: 1.08; letter-spacing: -.02em; font-weight: 700; }
.dl-title mark { position: relative; z-index: 0; background: none; color: inherit; white-space: nowrap; }
.dl-title mark::before {
  content: "";
  position: absolute;
  z-index: -1;
  left: -4px;
  right: -4px;
  bottom: .06em;
  height: .42em;
  background: var(--marker);
  border-radius: .3em .5em .4em .2em;
  transform: rotate(-1deg);
}
.dl-lead { max-width: 30em; margin: 0 0 28px; font-size: 18px; color: var(--muted); }

.dl-stores { display: flex; flex-wrap: wrap; gap: 12px; }
.dl-badge {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: 200px;
  padding: 11px 22px 11px 18px;
  border-radius: 14px;
  background: var(--badge);
  color: var(--badge-ink);
  text-decoration: none;
}
a.dl-badge { transition: transform .15s; }
a.dl-badge:hover { transform: translateY(-1px); }
.dl-badge svg { flex: none; width: 28px; height: 28px; }
.dl-badge small { display: block; font-size: 11px; line-height: 1.2; opacity: .8; }
.dl-badge b { display: block; font-size: 20px; line-height: 1.15; font-weight: 600; letter-spacing: -.01em; }
.dl-other { display: none; margin: 14px 0 0; font-size: 14px; color: var(--muted); }
.dl-other a { text-decoration: underline; }

.dl-steps { display: grid; gap: 16px; max-width: 34em; margin: 32px 0 0; padding: 0; list-style: none; counter-reset: step; }
.dl-steps li { display: grid; grid-template-columns: 32px 1fr; gap: 0 14px; counter-increment: step; }
.dl-steps li::before {
  content: counter(step);
  grid-row: span 2;
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--marker);
  font-weight: 700;
  font-size: 15px;
}
.dl-steps strong { font-size: 16px; }
.dl-steps span { color: var(--muted); font-size: 15px; }

.dl-qr {
  display: none;
  justify-self: end;
  width: 300px;
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: var(--card);
  text-align: center;
  box-shadow: 0 20px 50px rgba(0, 0, 0, .06);
}
.dl-qr img { display: block; width: 228px; height: 228px; margin: 0 auto; border-radius: 12px; }
.dl-qr p { margin: 16px 0 0; font-size: 14px; color: var(--muted); }
.dl-qr p strong { display: block; margin-bottom: 2px; font-size: 16px; color: var(--ink); }

.dl-footer { border-top: 1px solid var(--line); font-size: 13px; color: var(--muted); }
.dl-footer .dl-wrap { display: flex; flex-wrap: wrap; gap: 6px 20px; padding-top: 18px; padding-bottom: max(18px, env(safe-area-inset-bottom)); }
.dl-footer span { margin-right: auto; }
.dl-footer a { text-decoration: none; }
.dl-footer a:hover { text-decoration: underline; }

/* Phone: the store for this device first, full width, the other one as a line below. */
@media (max-width: 640px) {
  .dl-main { padding-top: 20px; }
  .dl-badge { width: 100%; justify-content: center; }
  html[data-device="ios"] .dl-badge--play,
  html[data-device="android"] .dl-badge--apple { display: none; }
  html[data-device="ios"] .dl-other--play,
  html[data-device="android"] .dl-other--apple { display: block; }
}
@media (min-width: 860px) {
  .dl-main { grid-template-columns: 1fr auto; padding-top: 72px; }
  .dl-qr { display: block; }
}
