/* The landing page only: an App Store product page, in glass. The policy pages never load this. */

.landing .glow { position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background: radial-gradient(700px 500px at 50% 110%, rgba(233, 196, 106, .12), transparent 60%); }

.bar { position: sticky; top: 12px; z-index: 10; width: min(1040px, 100% - 24px); margin: 12px auto 0;
  display: flex; align-items: center; justify-content: space-between; padding: 8px 10px 8px 14px; border-radius: 999px; }
.bar__brand { display: flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; font-weight: 700; letter-spacing: -.01em; }
.bar__links { display: flex; gap: 4px; }
.bar__links a { color: var(--ink-soft); text-decoration: none; font-size: 14px; padding: 6px 12px; border-radius: 999px; transition: background .25s, color .25s; }
.bar__links a:hover { color: var(--ink); background: rgba(255, 255, 255, .08); }

/* the landing page's <main> is a layout column, not the policy pages' glass sheet */
.landing main.page { max-width: 1040px; width: calc(100% - 32px); margin: 0 auto; padding: 24px 0 0;
  background: none; border: 0; box-shadow: none; -webkit-backdrop-filter: none; backdrop-filter: none; border-radius: 0; min-height: 0; }

.keyart { margin: 0; border-radius: 28px; overflow: hidden; border: 1px solid var(--line);
  box-shadow: 0 40px 100px -40px rgba(43, 92, 255, .55); }
.keyart img { display: block; width: 100%; height: auto; }

.listing { position: relative; margin: -72px 24px 0; padding: 26px 28px; display: grid;
  grid-template-columns: auto 1fr; gap: 6px 22px; align-items: center; }
.listing__icon { grid-row: span 1; width: 112px; height: 112px; border-radius: 26px; display: grid; place-items: center;
  background: linear-gradient(160deg, #f6f4ee, #dcd8cd); border: 1px solid rgba(255, 255, 255, .5);
  box-shadow: 0 20px 40px -18px rgba(0, 0, 0, .8); }
.listing__icon img { width: 92px; height: 92px; }
.listing h1 { font-size: 34px; margin: 0; letter-spacing: -.03em; }
.listing__sub { margin: 2px 0 0; font-size: 18px; color: var(--ink-soft); }
.listing__by { margin: 4px 0 0; font-size: 14px; color: var(--faint); }
.listing__by a { color: var(--accent); text-decoration: none; }

.info { grid-column: 1 / -1; list-style: none; padding: 16px 0 0; margin: 14px 0 0; border-top: 1px solid var(--line);
  display: grid; grid-template-columns: repeat(4, 1fr); }
.info li { margin: 0; display: flex; flex-direction: column; align-items: center; text-align: center; gap: 2px; padding: 0 8px; }
.info li + li { border-left: 1px solid var(--line); }
.info b { font-size: 17px; }
.info span { font-size: 12px; color: var(--faint); }

/* ---------- adaptive store block ----------
   One block of uniform size. Wide: three equal-height columns, the vertical
   iPhone | Android switch, the store button panel, and the QR code. Narrow
   (container < 460px): the same pieces stacked as rows of one width, the
   switch horizontal on top. Exactly one platform is ever selected (radio
   inputs; :has() shows only the checked platform's store). Without :has()
   support both stores show and the switch hides.
   html[data-platform=ios|android]: the switch hides, the platform is
     preselected, and the fallback button brings the switch back.
   On that phone the QR codes hide too — you are already holding it. */
.stores { grid-column: 1 / -1; margin-top: 18px; container-type: inline-size; width: 100%; max-width: 560px; --qr: 120px; }
.stores__in { display: grid; grid-template-columns: 132px 1fr; gap: 10px; align-items: stretch; }
.panel-cell { border-radius: 18px; background: rgba(255, 255, 255, .045); border: 1px solid rgba(255, 255, 255, .10);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .08); }

.seg { position: relative; display: grid; grid-template-rows: 1fr 1fr; padding: 5px; min-height: var(--qr);
  border-radius: 18px; background: rgba(255, 255, 255, .045); border: 1px solid rgba(255, 255, 255, .10);
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, .35); }
.seg::before { content: ""; position: absolute; left: 5px; right: 5px; top: 5px; height: calc(50% - 5px); border-radius: 13px;
  background: linear-gradient(180deg, rgba(255, 255, 255, .96), rgba(228, 231, 238, .92));
  box-shadow: 0 6px 18px -6px rgba(0, 0, 0, .7), inset 0 1px 0 #fff; transition: transform .45s cubic-bezier(.34, 1.4, .64, 1); }
.seg:has(input[value="android"]:checked)::before { transform: translateY(100%); }
.seg input { position: absolute; opacity: 0; pointer-events: none; }
.seg label { position: relative; z-index: 1; display: flex; align-items: center; gap: 9px; padding: 0 14px; border-radius: 13px;
  font-size: 15px; font-weight: 600; color: rgba(255, 255, 255, .6); cursor: pointer; user-select: none; transition: color .3s; white-space: nowrap; }
.seg label:hover { color: #fff; }
.seg input:checked + label { color: #0b0d12; cursor: default; }
.seg input:focus-visible + label { outline: 2px solid #8ab4ff; outline-offset: -2px; }
.seg label .ico { width: 16px; height: 16px; flex: 0 0 auto; }

.store { display: none; grid-template-columns: minmax(0, 1fr) var(--qr); gap: 10px; animation: store-in .4s cubic-bezier(.2, .8, .2, 1); }
.stores:has(input[value="ios"]:checked) [data-store="ios"],
.stores:has(input[value="android"]:checked) [data-store="android"] { display: grid; }
@supports not selector(:has(*)) { .store { display: grid; } .seg { display: none; } .stores__in { grid-template-columns: 1fr; } }
@keyframes store-in { from { opacity: 0; transform: translateY(4px); } }

.store__main { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 9px; padding: 14px; text-align: center; }
.store__btn { display: inline-flex; align-items: center; gap: 10px; padding: 10px 20px 10px 15px; border-radius: 14px;
  background: #000; color: #fff; border: 1px solid rgba(255, 255, 255, .28); text-decoration: none; white-space: nowrap;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .16); transition: transform .35s cubic-bezier(.34, 1.56, .64, 1), box-shadow .3s; }
a.store__btn:hover { transform: translateY(-2px); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .2), 0 12px 30px -10px rgba(138, 180, 255, .5); }
.store__btn > span { display: flex; flex-direction: column; align-items: flex-start; line-height: 1.1; font-size: 19px; font-weight: 600; letter-spacing: -.01em; }
.store__btn small { font-size: 11px; font-weight: 400; letter-spacing: .01em; opacity: .85; }
.store__logo { width: 26px; height: 26px; flex: 0 0 auto; }
.store__btn.is-soon { background: rgba(255, 255, 255, .04); color: rgba(255, 255, 255, .62); border-style: dashed; cursor: default; }
.store__note { margin: 0; font-size: 12px; line-height: 1.35; color: rgba(255, 255, 255, .45); }

.store__qr { margin: 0; width: var(--qr); height: var(--qr); padding: 7px; border-radius: 18px; background: #fff;
  box-shadow: 0 10px 30px -12px rgba(0, 0, 0, .7); }
.store__qr svg, .store__qr img { display: block; width: 100%; height: 100%; }
.store__qr.is-soon { display: grid; place-items: center; align-content: center; gap: 6px; background: rgba(255, 255, 255, .03);
  border: 1px dashed rgba(255, 255, 255, .22); box-shadow: none; color: rgba(255, 255, 255, .35); font-size: 11px; text-align: center; }
.store__qr.is-soon .store__logo { width: 30px; height: 30px; opacity: .55; }

.store__fallback { display: none; margin: 10px 0 0; padding: 2px 0; background: none; border: 0; color: rgba(255, 255, 255, .62);
  font: inherit; font-size: 13px; text-align: left; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.store__fallback:hover { color: #fff; }

/* narrow: rows of one width, the switch horizontal on top */
@container (max-width: 460px) {
  .stores__in { grid-template-columns: 1fr; }
  .seg { grid-template-rows: none; grid-template-columns: 1fr 1fr; min-height: 0; height: 48px; }
  .seg::before { right: auto; bottom: 5px; height: auto; width: calc(50% - 5px); }
  .seg:has(input[value="android"]:checked)::before { transform: translateX(100%); }
  .seg label { justify-content: center; }
  .stores { --qr: 104px; }
  .store__main { padding: 12px 10px; }
  .store__btn { padding: 8px 14px 8px 11px; gap: 8px; }
  .store__btn > span { font-size: 16px; }
  .store__logo { width: 22px; height: 22px; }
}

/* a phone of a certain platform: no QR (you are holding it), no switch until the fallback */
html[data-platform] .store__qr { display: none; }
html[data-platform] .store { grid-template-columns: 1fr; }
html[data-platform="ios"] .stores:not(.show-all) .seg,
html[data-platform="android"] .stores:not(.show-all) .seg { display: none; }
html[data-platform="ios"] .stores:not(.show-all) .stores__in,
html[data-platform="android"] .stores:not(.show-all) .stores__in { grid-template-columns: 1fr; }
html[data-platform="ios"] .stores:not(.show-all) [data-fallback="ios"],
html[data-platform="android"] .stores:not(.show-all) [data-fallback="android"] { display: block; }

.promo { margin: 34px 4px 0; font-size: 20px; line-height: 1.5; color: var(--ink); font-weight: 500; letter-spacing: -.01em; }

/* screenshots: a snapping rail, like the store's */
.shots { margin-top: 40px; }
.shots h2, .landing .tiers h3 { border: 0; padding: 0; }
.shots h2 { margin: 0 4px 14px; font-size: 22px; }
.shots__rail { display: grid; grid-auto-flow: column; grid-auto-columns: 240px; gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory;
  padding: 4px 4px 18px; scrollbar-width: thin; scrollbar-color: rgba(255, 255, 255, .2) transparent; }
.shots__rail img { width: 100%; height: auto; scroll-snap-align: start; border-radius: 26px; border: 1px solid var(--line);
  box-shadow: 0 24px 50px -24px rgba(0, 0, 0, .9); transition: transform .45s var(--spring); }
.shots__rail img:hover { transform: translateY(-4px); }
@media (pointer: fine) { .shots__rail { cursor: grab; } }
.shots__rail.is-dragging { cursor: grabbing; scroll-snap-type: none; user-select: none; }
.shots__rail.is-dragging img { transform: none; pointer-events: none; }
.shots__rail img { -webkit-user-drag: none; user-select: none; }

.about { margin-top: 26px; padding: 26px 28px; }
.about p:last-child { margin-bottom: 0; }

.tiers { margin-top: 18px; display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
.tier { padding: 24px 26px; }
.tier header { display: flex; align-items: center; gap: 14px; margin-bottom: 14px; }
.tier header img { width: 40px; height: 40px; }
.tier h3 { margin: 0; font-size: 19px; letter-spacing: -.01em; }
.tier header p { margin: 0; font-size: 13px; color: var(--faint); }
.tier ul { margin: 0; padding-left: 1.1rem; }
.tier li { font-size: 15px; color: #cfd3dc; }
.tier li::marker { color: var(--tier, var(--accent)); }
.tier--free { grid-column: 1 / -1; --tier: #f2f3f6; }
.tier--free header img { background: #f6f4ee; border-radius: 10px; padding: 3px; }
.tier--bronze { --tier: #d08a4c; border-color: rgba(208, 138, 76, .3); }
.tier--silver { --tier: #c9d1dc; border-color: rgba(201, 209, 220, .28); }
.tier--gold { --tier: #e9c46a; border-color: rgba(233, 196, 106, .32); grid-column: 1 / -1; }

.fine { margin: 26px 4px 0; font-size: 13px; color: var(--faint); }
.foot { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px; margin: 32px 4px 0; padding: 18px 0 48px;
  border-top: 1px solid var(--line); font-size: 13px; color: var(--faint); }
.foot a { color: var(--ink-soft); text-decoration: none; }
.foot a:hover { color: var(--ink); }

/* reveal on scroll, armed only when store.js runs */
.js .reveal { opacity: 0; transform: translateY(24px) scale(.985); filter: blur(6px);
  transition: opacity .8s var(--ease), transform .8s var(--ease), filter .8s var(--ease); transition-delay: calc(var(--i, 0) * 70ms); }
.js .reveal.is-in { opacity: 1; transform: none; filter: none; }

@media (max-width: 720px) {
  .listing { margin: -36px 10px 0; padding: 20px; gap: 4px 16px; }
  .listing__icon { width: 84px; height: 84px; border-radius: 20px; }
  .listing__icon img { width: 68px; height: 68px; }
  .listing h1 { font-size: 26px; }
  .listing__sub { font-size: 15px; }
  .info { grid-template-columns: repeat(2, 1fr); row-gap: 14px; }
  .info li:nth-child(3) { border-left: 0; }
  .promo { font-size: 18px; }
  .shots__rail { grid-auto-columns: 62%; }
  .tiers { grid-template-columns: 1fr; }
  /* the art's subject (headline, grid, phone) sits in its middle ~55%; on a phone crop to a square
     around it rather than shrinking the whole 16:9 frame */
  .keyart { border-radius: 20px; }
  .keyart img { aspect-ratio: 4 / 3; object-fit: cover; object-position: 50% 0; }
}

@media (max-width: 520px) { .keyart img { aspect-ratio: 1 / 1; } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .js .reveal { opacity: 1; transform: none; filter: none; }
}
