:root {
  --tangerine: #FF5A1F;
  --tangerine-dark: #D93F08;
  --tangerine-soft: #FFE5D9;
  --bg: #FFF9F2;
  --surface: #FFFFFF;
  --surface-alt: #FFF3E8;
  --ink: #1D1633;
  --ink-muted: #5D5378;
  --border: #ECDED2;
  --shadow: 0 12px 32px rgba(29, 22, 51, 0.08);
  --shadow-phone: 0 18px 40px rgba(29, 22, 51, 0.14);
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #130F21;
    --surface: #1F1933;
    --surface-alt: #2A2244;
    --ink: #FDF7F0;
    --ink-muted: #BDB3D6;
    --border: #362C54;
    --tangerine-soft: rgba(255, 90, 31, 0.2);
    --shadow: 0 14px 36px rgba(0, 0, 0, 0.35);
    --shadow-phone: 0 20px 44px rgba(0, 0, 0, 0.5);
  }
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

.container {
  width: min(940px, 100% - 32px);
  margin: 0 auto;
}

.page {
  padding: 52px 0 28px;
}

/* Hero */
.hero {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.app-logo {
  width: 104px;
  height: 104px;
  border-radius: 26px;
  object-fit: cover;
  box-shadow: 0 14px 32px rgba(255, 90, 31, 0.25);
  border: 2px solid rgba(255, 255, 255, 0.45);
}

.app-title {
  margin: 18px 0 8px;
  font-family: 'Fredoka', 'Plus Jakarta Sans', sans-serif;
  font-size: clamp(2.1rem, 4.5vw, 2.9rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.1;
}

.app-tagline {
  margin: 0;
  max-width: 46ch;
  font-size: 1.04rem;
  color: var(--ink-muted);
}

.download-wrap {
  margin-top: 26px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.download-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-width: 240px;
  min-height: 54px;
  padding: 14px 28px;
  border-radius: 999px;
  background: var(--tangerine);
  color: #FFFFFF;
  text-decoration: none;
  font-size: 1.04rem;
  font-weight: 700;
  box-shadow: 0 14px 28px rgba(255, 90, 31, 0.28);
  transition: transform 0.15s ease, background-color 0.15s ease;
}

.download-btn:hover {
  background: var(--tangerine-dark);
  transform: translateY(-1px);
}

.download-btn:active {
  transform: translateY(1px);
}

.version-meta {
  margin: 2px 0 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 0.88rem;
  color: var(--ink-muted);
}

.version-badge {
  background: var(--tangerine-soft);
  color: var(--tangerine-dark);
  font-weight: 700;
  padding: 2px 10px;
  border-radius: 999px;
  font-size: 0.82rem;
}

@media (prefers-color-scheme: dark) {
  .version-badge {
    color: #FF9A75;
  }
}

.quick-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 0.84rem;
  color: var(--ink-muted);
}

.text-link {
  background: none;
  border: none;
  padding: 0;
  font: inherit;
  color: var(--ink-muted);
  text-decoration: none;
  cursor: pointer;
  font-weight: 600;
}

.text-link:hover {
  color: var(--tangerine);
  text-decoration: underline;
}

/* Screenshots Showcase */
.screenshots {
  margin-top: 44px;
}

.shots-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  align-items: start;
}

@media (max-width: 760px) {
  .shots-row {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    gap: 16px;
    padding: 4px 6px 14px;
    -webkit-overflow-scrolling: touch;
  }

  .shot-card {
    flex: 0 0 72%;
    max-width: 260px;
    scroll-snap-align: center;
  }
}

.shot-card {
  margin: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.phone-frame {
  width: 100%;
  max-width: 265px;
  border-radius: 28px;
  padding: 7px;
  background: var(--ink);
  box-shadow: var(--shadow-phone);
}

@media (prefers-color-scheme: dark) {
  .phone-frame {
    background: #2C2447;
    border: 1px solid var(--border);
  }
}

.phone-frame img {
  display: block;
  width: 100%;
  aspect-ratio: 9 / 16;
  object-fit: cover;
  border-radius: 22px;
}

.shot-card figcaption {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--ink-muted);
  text-align: center;
}

/* Compact Release Card */
.release-info {
  margin-top: 44px;
  max-width: 680px;
}

.release-card {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: 22px;
  padding: 20px 22px;
  box-shadow: var(--shadow);
}

.release-card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

.kicker {
  display: block;
  font-size: 0.74rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--tangerine);
}

.release-card h2 {
  margin: 2px 0 0;
  font-family: 'Fredoka', 'Plus Jakarta Sans', sans-serif;
  font-size: 1.2rem;
}

.changelog-body {
  font-size: 0.9rem;
  color: var(--ink-muted);
}

.changelog-body h2,
.changelog-body h3,
.changelog-body h4 {
  font-size: 0.95rem;
  color: var(--ink);
  margin: 10px 0 4px;
}

.changelog-body p {
  margin: 6px 0;
}

.changelog-body ul {
  margin: 6px 0;
  padding-left: 18px;
}

.changelog-body li {
  margin: 3px 0;
}

.changelog-body code {
  font-size: 0.85em;
  background: var(--surface-alt);
  padding: 1px 6px;
  border-radius: 6px;
  color: var(--ink);
}

.changelog-body blockquote {
  margin: 8px 0;
  padding: 6px 10px;
  border-left: 3px solid var(--tangerine);
  background: var(--surface-alt);
  border-radius: 0 8px 8px 0;
}

.older-releases {
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid var(--border);
}

.older-releases summary {
  cursor: pointer;
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--ink);
}

.releases-list {
  margin-top: 10px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.release-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 12px;
  background: var(--surface-alt);
  font-size: 0.86rem;
}

.release-row-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.release-row-dl {
  color: var(--tangerine);
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
}

.release-row-dl:hover {
  text-decoration: underline;
}

.install-hint {
  margin: 14px 4px 0;
  text-align: center;
  font-size: 0.84rem;
  color: var(--ink-muted);
}

.install-hint code {
  background: var(--surface);
  border: 1px solid var(--border);
  padding: 1px 5px;
  border-radius: 5px;
}

/* Footer */
.footer {
  padding: 18px 0 40px;
  text-align: center;
  font-size: 0.84rem;
  color: var(--ink-muted);
  display: flex;
  justify-content: center;
  gap: 8px;
}

.footer a {
  color: var(--ink-muted);
  text-decoration: none;
  font-weight: 600;
}

.footer a:hover {
  color: var(--tangerine);
}

/* Toast */
.toast {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%) translateY(14px);
  background: var(--ink);
  color: var(--bg);
  padding: 9px 16px;
  border-radius: 999px;
  font-size: 0.84rem;
  font-weight: 700;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.2s ease;
  z-index: 50;
}

.toast.visible {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}
