:root {
  color-scheme: light;
  --outer: #46321f;
  --ink: #111111;
  --muted: #8b8b8f;
  --line: #dfdfdf;
  --blue: #087cf5;
  --page-width: 614px;
}

* { box-sizing: border-box; }

html { background: var(--outer); }

body {
  margin: 0;
  min-width: 320px;
  background: var(--outer);
  color: var(--ink);
  font-family: Arial, Helvetica, sans-serif;
  -webkit-font-smoothing: antialiased;
}

.site-frame {
  width: min(var(--page-width), calc(100vw - 50px));
  min-height: 100vh;
  margin: 0 auto;
  background: #fff;
}

.page-content { padding: 38px 31px 54px; }

.app-head {
  display: flex;
  align-items: flex-start;
  gap: 13px;
}

.app-icon {
  width: 188px;
  height: 188px;
  flex: 0 0 188px;
  object-fit: cover;
  border-radius: 32px;
  background: #0b0647;
}

.app-summary { padding-top: 4px; min-width: 0; }

.app-name-line { display: flex; align-items: center; gap: 8px; }

h1 {
  margin: 0;
  font-size: 36px;
  line-height: 40px;
  letter-spacing: -1.7px;
  font-weight: 700;
  white-space: nowrap;
}

.age-badge {
  min-width: 45px;
  height: 32px;
  padding: 1px 7px 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid #a8a8ad;
  border-radius: 8px;
  color: #838389;
  font-size: 22px;
  font-weight: 700;
}

.rank {
  margin: 2px 0 58px;
  color: #96969a;
  font-size: 24px;
  line-height: 27px;
}

.download-button {
  display: inline-flex;
  align-items: center;
  min-height: 52px;
  padding: 0 15px;
  border-radius: 29px;
  background: var(--blue);
  color: white;
  font-size: 25px;
  line-height: 1;
  font-family: inherit;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  border: 0;
  appearance: none;
}

.download-form { margin: 0; }

.stats-row {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  margin-top: 18px;
  padding-top: 23px;
  border-top: 1px solid #e3e3e3;
}

.stat {
  min-height: 80px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  gap: 8px;
  color: var(--muted);
  font-size: 21px;
  line-height: 1;
  border-right: 1px solid #dedede;
  white-space: nowrap;
}

.stat:last-child { border-right: 0; }
.stat strong { color: #8b8b8f; font-size: 30px; line-height: 1; }
.stat .stars { margin-top: 8px; color: #89898c; font-size: 22px; letter-spacing: 0; }
.stat-size strong { margin-top: 0; }

.gallery {
  position: relative;
  height: clamp(380px, 92vw, 560px);
  margin-top: 25px;
  overflow-x: auto;
  overflow-y: hidden;
  border-radius: 11px;
  touch-action: pan-x pan-y;
  cursor: grab;
  background: #fff;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  overscroll-behavior-x: contain;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.gallery::-webkit-scrollbar { display: none; }

.gallery-track {
  display: flex;
  align-items: stretch;
  gap: 10px;
  width: max-content;
  min-width: 100%;
  height: 100%;
}

.gallery-slide {
  position: relative;
  flex: 0 0 min(74%, 390px);
  min-width: 0;
  height: 100%;
  margin: 0;
  overflow: hidden;
  border-radius: 11px;
  background: #fff;
  scroll-snap-align: start;
  scroll-snap-stop: always;
}

.gallery-image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  user-select: none;
  -webkit-user-drag: none;
}

h2 {
  margin: 0;
  font-size: 36px;
  line-height: 1.2;
  letter-spacing: 1px;
}

.rating-section { padding: 31px 0 0; }

.rating-overview {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 35px 2px 20px;
}

.rating-score { display: flex; flex-direction: column; align-items: center; min-width: 242px; }
.rating-score strong { color: #4d4e53; font-size: 82px; line-height: 80px; letter-spacing: -3px; }
.rating-score span { color: #818286; font-size: 24px; font-weight: 700; white-space: nowrap; }

.rating-bars { width: 264px; padding-top: 5px; color: #95969b; }
.rating-bars div { height: 24px; display: flex; align-items: center; gap: 10px; }
.rating-bars div span { width: 83px; text-align: right; font-size: 18px; letter-spacing: -2px; }
.rating-bars i { height: 4px; flex: 1; overflow: hidden; border-radius: 4px; background: #dedede; }
.rating-bars b { display: block; height: 100%; width: 92%; border-radius: 4px; background: #8d8e92; }
.rating-bars em { display: block; margin: 7px 0 0 101px; color: #8b8c90; font-size: 24px; font-style: normal; }

.review-card {
  margin: 0 6px 38px;
  padding: 15px 11px 15px;
  border-radius: 10px;
  background: #f7f7f7;
  font-size: 15px;
  line-height: 1.32;
}

.review-heading, .review-meta { display: flex; justify-content: space-between; gap: 12px; align-items: baseline; }
.review-heading strong { font-size: 16px; }
.review-heading span, .review-meta span:last-child { font-size: 12px; }
.review-stars { color: #ffad00; font-size: 22px; letter-spacing: -1px; line-height: 1; }
.review-meta { margin-top: 3px; }
.review-card p { margin: 8px 0 0; font-size: 15px; }

.copy-section { border-bottom: 1px solid var(--line); }
.feature-section { padding: 9px 0 38px; }
.feature-section p { margin: 55px 0 0; color: #3f3f42; font-size: 27px; line-height: 1.25; }
.info-section { padding: 28px 0 0; border-bottom: 0; }
.info-list { margin-top: 34px; }
.info-row { display: grid; grid-template-columns: 170px minmax(0, 1fr); min-height: 52px; align-items: center; border-bottom: 1px solid var(--line); color: #8b8b90; font-size: 21px; }
.info-row span:last-child { color: #3d3d40; text-align: right; line-height: 1.26; }
.info-row:last-child { border-bottom: 0; }

.disclaimer { margin: 40px -31px -54px; padding: 16px 25px 19px; background: #eee; color: #b1b1b3; }
.disclaimer h3 { margin: 0 0 8px; font-size: 18px; font-weight: 400; }
.disclaimer p { margin: 0; padding-left: 33px; font-size: 18px; line-height: 1.4; }

@media (min-width: 640px) {
  .site-frame { margin-left: 26px; margin-right: 0; }
}

@media (max-width: 639px) {
  .site-frame { width: calc(100vw - 50px); }
}

@media (max-width: 540px) {
  .site-frame { width: 100vw; }
  .page-content { padding-left: 18px; padding-right: 18px; }
  .app-icon { width: 132px; height: 132px; flex-basis: 132px; border-radius: 24px; }
  h1 { font-size: 29px; }
  .age-badge { font-size: 17px; min-width: 36px; height: 27px; }
  .rank { margin-bottom: 34px; font-size: 20px; }
  .download-button { font-size: 19px; min-height: 44px; }
  .stats-row { margin-top: 18px; grid-template-columns: repeat(4, 1fr); }
  .stat { font-size: 14px; }
  .stat strong { font-size: 22px; }
  .stat .stars { font-size: 15px; }
  h2 { font-size: 29px; }
  .rating-overview { padding-top: 24px; flex-direction: column; align-items: center; gap: 24px; }
  .rating-score { min-width: 0; }
  .rating-bars { width: 100%; }
  .feature-section p { margin-top: 36px; font-size: 22px; }
  .info-row { grid-template-columns: 125px minmax(0, 1fr); font-size: 16px; }
  .disclaimer { margin-left: -18px; margin-right: -18px; }
}
