/* V3 App Store UI — Play-like, mobile-first */
:root {
  --bg: #f8f9fb;
  --card: #fff;
  --ink: #202124;
  --muted: #5f6368;
  --line: #e8eaed;
  --green: #01875f;
  --green-soft: #e6f4ef;
  --star: #f9ab00;
  --bar: #01875f;
  --radius: 16px;
  --pad: 1rem;
  --max: 720px;
  --font: "Manrope", system-ui, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  background: var(--bg);
  color: var(--ink);
  font-size: 16px;
  line-height: 1.55;
  padding-bottom: 5.5rem;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--green); text-decoration: none; }

.wrap { width: min(100% - 2 * var(--pad), var(--max)); margin-inline: auto; }

.topbar {
  position: sticky; top: 0; z-index: 40;
  background: rgba(248,249,251,.95);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
  padding: .65rem 0;
}
.topbar-inner { display: flex; align-items: center; justify-content: space-between; gap: .75rem; }
.back {
  min-width: 44px; min-height: 44px; border-radius: 50%;
  display: grid; place-items: center; color: var(--ink); font-size: 1.2rem; text-decoration: none;
}
.top-actions { display: flex; gap: .25rem; }
.icon-btn {
  min-width: 44px; min-height: 44px; border: 0; background: transparent;
  border-radius: 50%; font-size: 1.1rem; cursor: pointer; color: var(--ink);
}

.app-head {
  display: grid; grid-template-columns: 72px 1fr; gap: 1rem;
  padding: 1.25rem 0 1rem; align-items: start;
}
.app-icon {
  width: 72px; height: 72px; border-radius: 16px;
  background: linear-gradient(145deg, #25f4ee, #fe2c55);
  display: grid; place-items: center; color: #0a0c0f;
  font-weight: 800; font-size: 1.1rem;
  box-shadow: 0 8px 24px rgba(0,0,0,.12);
}
.app-head h1 {
  margin: 0 0 .25rem; font-size: 1.45rem; letter-spacing: -.02em; line-height: 1.2;
}
.dev { margin: 0; color: var(--green); font-weight: 700; font-size: .92rem; }
.subline { margin: .25rem 0 0; color: var(--muted); font-size: .85rem; font-weight: 650; }

.metrics {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: .5rem;
  padding: .25rem 0 1rem; text-align: center;
}
.metric {
  padding: .7rem .35rem; background: var(--card); border: 1px solid var(--line);
  border-radius: 12px;
}
.metric b { display: block; font-size: 1.05rem; margin-bottom: .15rem; }
.metric span { color: var(--muted); font-size: .75rem; font-weight: 650; }

.install-row { display: grid; gap: .55rem; margin-bottom: 1rem; }
.btn {
  min-height: 48px; border-radius: 999px; font-weight: 800; font-size: 1rem;
  display: inline-flex; align-items: center; justify-content: center;
  text-decoration: none; border: none; padding: .85rem 1.2rem;
}
.btn-install { background: var(--green); color: #fff; }
.btn-outline {
  background: var(--card); color: var(--green); border: 1px solid #c5e4d8;
}
.btn:hover { filter: brightness(1.03); text-decoration: none; }

.share-row {
  display: flex; justify-content: space-around; padding: .25rem 0 1rem;
}
.share-row button, .share-row a {
  background: none; border: 0; color: var(--green); font-weight: 800;
  font-size: .85rem; min-height: 44px; cursor: pointer; text-decoration: none;
}

section { padding: 1.1rem 0 1.25rem; border-top: 1px solid var(--line); }
h2 { margin: 0 0 .85rem; font-size: 1.15rem; }

.shots {
  display: flex; gap: .65rem; overflow-x: auto; scroll-snap-type: x mandatory;
  padding-bottom: .35rem; -webkit-overflow-scrolling: touch;
  margin: 0 calc(-1 * var(--pad)); padding-left: var(--pad); padding-right: var(--pad);
}
.shots img {
  flex: 0 0 42vw; max-width: 180px; scroll-snap-align: start;
  border-radius: 12px; border: 1px solid var(--line); background: #fff;
}

.about p { margin: 0 0 .75rem; color: var(--muted); }
.about p:last-child { margin-bottom: 0; }
.chip-row { display: flex; flex-wrap: wrap; gap: .4rem; margin-top: .85rem; }
.chip {
  border: 1px solid var(--line); background: var(--card); border-radius: 999px;
  padding: .35rem .7rem; font-size: .8rem; font-weight: 700; color: var(--muted);
}

.whatsnew {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 1rem 1.05rem;
}
.whatsnew .ver { font-weight: 800; margin-bottom: .35rem; }
.whatsnew ul { margin: .5rem 0 0; padding-left: 1.15rem; color: var(--muted); }

.rating-box {
  display: grid; grid-template-columns: auto 1fr; gap: 1rem; align-items: center;
}
.big-score { font-size: 3rem; font-weight: 800; line-height: 1; letter-spacing: -.04em; }
.stars { color: var(--star); letter-spacing: .06em; }
.rate-count { color: var(--muted); font-size: .85rem; font-weight: 650; margin-top: .25rem; }
.bars { display: grid; gap: .28rem; }
.bar-row { display: grid; grid-template-columns: 12px 1fr; gap: .45rem; align-items: center; font-size: .75rem; color: var(--muted); }
.bar {
  height: 8px; background: #e8eaed; border-radius: 999px; overflow: hidden;
}
.bar i { display: block; height: 100%; background: var(--bar); border-radius: 999px; }

.review {
  background: var(--card); border: 1px solid var(--line); border-radius: 14px;
  padding: 1rem; margin-top: .75rem;
}
.rev-h { display: flex; gap: .7rem; align-items: center; margin-bottom: .55rem; }
.av {
  width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center;
  font-weight: 800; font-size: .8rem; color: #fff; flex-shrink: 0;
}
.av1 { background: #01875f; }
.av2 { background: #d93025; }
.av3 { background: #1a73e8; }
.av4 { background: #f9ab00; color: #202124; }
.rev-name { margin: 0; font-weight: 800; font-size: .95rem; }
.rev-meta { color: var(--muted); font-size: .78rem; font-weight: 650; }
.review p { margin: 0; color: #3c4043; font-size: .95rem; }
.helpful { margin-top: .65rem; color: var(--muted); font-size: .8rem; font-weight: 650; }

.compare { width: 100%; border-collapse: collapse; background: var(--card); border-radius: 12px; overflow: hidden; }
.compare th, .compare td {
  padding: .75rem .8rem; border-bottom: 1px solid var(--line);
  text-align: left; font-size: .92rem;
}
.compare th { background: #f1f3f4; color: var(--muted); font-weight: 700; }
.compare td { font-weight: 650; }
.ok { color: var(--green); }
.no { color: #d93025; }

.data-safe {
  display: flex; gap: .75rem; align-items: flex-start;
  background: var(--green-soft); border-radius: 12px; padding: .9rem 1rem;
  color: #0d3b2e; font-size: .92rem; font-weight: 650;
}

.footer {
  padding: 1.25rem 0; color: var(--muted); font-size: .82rem;
}

.stick {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 50;
  padding: .65rem var(--pad) calc(.65rem + env(safe-area-inset-bottom));
  background: rgba(248,249,251,.97); border-top: 1px solid var(--line);
  display: grid; grid-template-columns: 1fr auto; gap: .65rem; align-items: center;
}
.stick .price { font-weight: 800; font-size: .95rem; }
.stick .price small { display: block; color: var(--muted); font-weight: 650; font-size: .75rem; }
.stick .btn { padding-inline: 1.4rem; }

@media (min-width: 768px) {
  .app-head { grid-template-columns: 96px 1fr; }
  .app-icon { width: 96px; height: 96px; border-radius: 20px; font-size: 1.35rem; }
  .app-head h1 { font-size: 1.85rem; }
  .shots img { flex-basis: 160px; }
  .install-row { grid-template-columns: 1fr 1fr; }
  .stick { max-width: var(--max); left: 50%; transform: translateX(-50%); width: min(100%, var(--max)); border-radius: 16px 16px 0 0; }
}
