:root {
  color-scheme: dark;
  --bg: #080808;
  --surface: #121212;
  --surface-2: #1a1a1a;
  --text: #f8f8f8;
  --muted: #a7a7a7;
  --line: rgba(255,255,255,.1);
  --yellow: #ffd21c;
  --orange: #ff7a00;
  --radius: 22px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  overflow-x: hidden;
  background:
    radial-gradient(circle at 50% -10%, rgba(255,122,0,.13), transparent 31rem),
    linear-gradient(180deg, #0c0b09 0%, var(--bg) 42%, #050505 100%);
  color: var(--text);
  font-family: "Poppins", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: .16;
  background-image: radial-gradient(rgba(255,255,255,.16) .55px, transparent .55px);
  background-size: 20px 20px;
  mask-image: linear-gradient(to bottom, #000, transparent 80%);
}

button, a { font: inherit; }
button { color: inherit; }

.ambient {
  position: fixed;
  width: 20rem;
  height: 20rem;
  border-radius: 50%;
  filter: blur(90px);
  opacity: .08;
  pointer-events: none;
}
.ambient-one { background: var(--orange); top: 3rem; left: -10rem; }
.ambient-two { background: var(--yellow); right: -12rem; bottom: 8rem; }

.app-page {
  position: relative;
  width: min(100% - 34px, 680px);
  margin: 0 auto;
  padding: 42px 0 28px;
}

.app-hero {
  display: flex;
  align-items: center;
  gap: 20px;
}

.app-icon {
  width: 112px;
  height: 112px;
  flex: 0 0 auto;
  border-radius: 27px;
  object-fit: cover;
  box-shadow: 0 15px 45px rgba(255,122,0,.22), 0 0 0 1px rgba(255,210,28,.3);
}

.hero-copy { min-width: 0; }
.eyebrow {
  display: block;
  color: var(--yellow);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .15em;
  margin-bottom: 4px;
}
h1 { margin: 0 0 12px; font-size: clamp(25px, 5vw, 34px); line-height: 1.12; }

.download-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-height: 46px;
  padding: 0 23px;
  border-radius: 999px;
  color: #241500;
  text-decoration: none;
  font-size: 14px;
  font-weight: 800;
  background: linear-gradient(100deg, var(--yellow), var(--orange));
  box-shadow: 0 10px 28px rgba(255,122,0,.25);
  transition: transform .18s ease, box-shadow .18s ease, filter .18s ease;
}
.download-button:hover { transform: translateY(-2px); box-shadow: 0 14px 34px rgba(255,122,0,.34); filter: saturate(1.08); }
.download-button:active { transform: translateY(0) scale(.98); }
.download-button svg { width: 19px; height: 19px; fill: currentColor; }
.download-button.is-disabled { filter: grayscale(.25); }

.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  margin: 38px 0 32px;
}
.stat { position: relative; display: grid; place-items: center; padding: 8px 12px; text-align: center; }
.stat + .stat::before { content: ""; position: absolute; left: 0; width: 1px; height: 46px; background: var(--line); }
.stat strong { font-size: 20px; line-height: 1.2; }
.stat span { margin-top: 5px; color: var(--muted); font-size: 11px; }

.content-section { margin-top: 34px; }
.section-heading { display: flex; align-items: center; gap: 10px; }
.section-heading h2 { margin: 0; font-size: 18px; letter-spacing: -.02em; }
.heading-mark { width: 4px; height: 18px; border-radius: 5px; background: linear-gradient(var(--yellow), var(--orange)); box-shadow: 0 0 13px rgba(255,162,0,.35); }
.updated { margin: 4px 0 15px 14px; color: var(--muted); font-size: 12px; }
.update-list { margin: 0; padding: 0; list-style: none; color: #c4c4c4; font-size: 13px; line-height: 1.9; }
.update-list li { position: relative; padding-left: 17px; }
.update-list li::before { content: ""; position: absolute; left: 1px; top: .83em; width: 6px; height: 2px; border-radius: 3px; background: var(--orange); }
.content-section > p:not(.updated) { margin: 15px 0 0; color: #bdbdbd; font-size: 13px; line-height: 1.85; }

.tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 20px; }
.tags span { padding: 7px 13px; border: 1px solid rgba(255,166,0,.28); border-radius: 999px; color: #ffc43a; background: rgba(255,122,0,.07); font-size: 10px; font-weight: 600; }

.screenshot-strip {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(170px, 39%);
  gap: 12px;
  margin: 16px calc((100vw - min(100vw - 34px, 680px)) / -2) 0 0;
  padding: 1px calc((100vw - min(100vw - 34px, 680px)) / 2) 10px 0;
  overflow-x: auto;
  overscroll-behavior-inline: contain;
  scroll-snap-type: inline mandatory;
  scrollbar-width: none;
}
.screenshot-strip::-webkit-scrollbar { display: none; }
.shot { appearance: none; padding: 0; border: 0; border-radius: 17px; overflow: hidden; background: var(--surface); cursor: zoom-in; scroll-snap-align: start; box-shadow: 0 0 0 1px var(--line); transition: transform .2s ease, box-shadow .2s ease; }
.shot:hover { transform: translateY(-3px); box-shadow: 0 14px 35px rgba(0,0,0,.34), 0 0 0 1px rgba(255,174,0,.35); }
.shot img { display: block; width: 100%; aspect-ratio: 9 / 16; object-fit: cover; }

footer { margin-top: 46px; padding: 26px 0 4px; border-top: 1px solid var(--line); text-align: center; }
footer p { margin: 0; color: #8f8f8f; font-size: 11px; }
footer p span { color: var(--orange); }
.terms-trigger { margin-top: 10px; padding: 7px 12px; border: 0; color: #d5d5d5; background: transparent; font-size: 11px; cursor: pointer; }
.terms-trigger:hover { color: var(--yellow); }

.modal[hidden] { display: none; }
.modal { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: 18px; }
.modal-backdrop { position: absolute; inset: 0; background: rgba(0,0,0,.78); backdrop-filter: blur(8px); animation: fadeIn .18s ease both; }
.modal-card { position: relative; z-index: 1; width: min(100%, 610px); max-height: min(86vh, 760px); border: 1px solid rgba(255,186,32,.2); border-radius: 25px; background: linear-gradient(155deg, #1b1812, #101010 34%); box-shadow: 0 28px 90px rgba(0,0,0,.7), 0 0 60px rgba(255,122,0,.08); animation: riseIn .24s ease both; overflow: hidden; }
.modal-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; padding: 21px 22px 15px; border-bottom: 1px solid var(--line); }
.modal-header h2 { margin: 3px 0 0; font-size: 20px; }
.modal-kicker { color: var(--yellow); font-size: 9px; font-weight: 800; letter-spacing: .16em; }
.close-button { display: grid; place-items: center; flex: 0 0 auto; width: 35px; height: 35px; padding: 0; border: 1px solid var(--line); border-radius: 50%; color: #ddd; background: rgba(255,255,255,.06); font-size: 24px; line-height: 1; cursor: pointer; }
.close-button:hover { color: #221400; background: var(--yellow); }
.terms-content { max-height: calc(min(86vh, 760px) - 151px); padding: 17px 22px; overflow-y: auto; overscroll-behavior: contain; }
.terms-content p { margin: 0 0 17px; color: #bcbcbc; font-size: 12px; line-height: 1.75; }
.terms-content h3 { margin: 18px 0 7px; color: #f3f3f3; font-size: 13px; }
.accept-button { display: block; width: calc(100% - 44px); height: 45px; margin: 0 22px 20px; border: 0; border-radius: 14px; color: #251600; background: linear-gradient(100deg, var(--yellow), var(--orange)); font-weight: 800; cursor: pointer; }

body.modal-open { overflow: hidden; }
.lightbox { grid-template-columns: minmax(42px, 1fr) minmax(0, 430px) minmax(42px, 1fr); }
.lightbox-frame { position: relative; z-index: 1; grid-column: 2; margin: 0; max-height: 85vh; border-radius: 20px; overflow: hidden; box-shadow: 0 30px 90px #000; animation: riseIn .22s ease both; }
.lightbox-frame img { display: block; width: auto; max-width: 100%; height: auto; max-height: 85vh; object-fit: contain; }
.lightbox-close { position: fixed; z-index: 3; top: 22px; right: 22px; }
.nav-button { position: relative; z-index: 2; justify-self: center; width: 43px; height: 55px; border: 1px solid var(--line); border-radius: 15px; background: rgba(20,20,20,.78); color: #fff; font-size: 31px; cursor: pointer; }
.nav-button:hover { color: #271600; background: var(--yellow); }
.prev { grid-column: 1; }
.next { grid-column: 3; }
.lightbox-count { position: fixed; z-index: 2; left: 50%; bottom: 18px; transform: translateX(-50%); padding: 6px 12px; border-radius: 99px; background: rgba(20,20,20,.85); color: #cfcfcf; font-size: 11px; }

.toast { position: fixed; z-index: 150; left: 50%; bottom: 24px; transform: translate(-50%, 18px); max-width: calc(100vw - 34px); padding: 12px 17px; border: 1px solid rgba(255,193,29,.26); border-radius: 13px; background: #201c14; color: #f2f2f2; font-size: 12px; opacity: 0; pointer-events: none; transition: .22s ease; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.noscript { position: fixed; left: 12px; right: 12px; bottom: 12px; margin: 0; padding: 12px; border-radius: 12px; background: #241400; text-align: center; font-size: 12px; }

@keyframes fadeIn { from { opacity: 0; } }
@keyframes riseIn { from { opacity: 0; transform: translateY(18px) scale(.98); } }

@media (max-width: 520px) {
  .app-page { width: min(100% - 28px, 680px); padding-top: 28px; }
  .app-hero { gap: 15px; }
  .app-icon { width: 92px; height: 92px; border-radius: 23px; }
  .eyebrow { font-size: 8px; }
  h1 { margin-bottom: 9px; font-size: 24px; }
  .download-button { min-height: 42px; padding: 0 17px; font-size: 12px; }
  .stats { margin-top: 31px; }
  .stat strong { font-size: 17px; }
  .screenshot-strip { grid-auto-columns: 54%; }
  .lightbox { grid-template-columns: 38px minmax(0, 1fr) 38px; padding: 10px; }
  .nav-button { width: 34px; height: 48px; border-radius: 12px; font-size: 27px; }
  .modal-card { border-radius: 21px; }
  .modal-header, .terms-content { padding-left: 17px; padding-right: 17px; }
  .accept-button { width: calc(100% - 34px); margin-left: 17px; margin-right: 17px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
