:root {
  --bg: #eef4ff;
  --bg-deep: #d5e3ff;
  --text: #0d1b22;
  --text-soft: #4b5d66;
  --line: rgba(13, 27, 34, 0.1);
  --card: rgba(255, 255, 255, 0.22);
  --card-strong: rgba(255, 255, 255, 0.18);
  --accent: #2f7cff;
  --accent-soft: #6ca5ff;
  --accent-rgb: 47, 124, 255;
  --shadow: 0 30px 70px rgba(17, 32, 39, 0.13);
  --glass-border: rgba(255, 255, 255, 0.48);
  --glass-shadow:
    0 14px 34px rgba(8, 18, 24, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.32);
  --radius-lg: 30px;
  --radius-md: 20px;
}

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

html,
body {
  margin: 0;
  padding: 0;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  min-height: 100vh;
  font-family: "Manrope", "Segoe UI", sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at 20% 20%, #fdfefe 0, transparent 42%),
    radial-gradient(circle at 82% 8%, #d9e8ff 0, transparent 35%),
    linear-gradient(150deg, var(--bg) 0%, var(--bg-deep) 100%);
  line-height: 1.55;
  position: relative;
  overflow-x: hidden;
  padding-left: env(safe-area-inset-left);
  padding-right: env(safe-area-inset-right);
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image: radial-gradient(rgba(255, 255, 255, 0.26) 1px, transparent 1px);
  background-size: 3px 3px;
  mix-blend-mode: soft-light;
  opacity: 0.45;
}

.container {
  width: min(1120px, calc(100% - 3rem));
  margin-inline: auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  backdrop-filter: blur(16px);
  background: rgba(244, 247, 248, 0.58);
  border-bottom: 1px solid var(--line);
  padding-top: env(safe-area-inset-top);
}

.nav {
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem;
}

.brand {
  margin: 0;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.hero {
  padding: 5.2rem 0 3.5rem;
  display: block;
}

.hero-copy {
  max-width: 760px;
}

.eyebrow {
  margin: 0 0 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-size: 0.74rem;
  font-weight: 700;
  color: var(--accent);
}

h1,
h2,
h3 {
  margin: 0;
  line-height: 1.1;
}

h1 {
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: clamp(2.3rem, 6vw, 4.2rem);
  max-width: 13ch;
  font-weight: 600;
}

.hero-description {
  margin: 1.2rem 0 0;
  color: var(--text-soft);
  max-width: 48ch;
}

.hero-actions {
  margin-top: 2rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
}

.button {
  --button-bg: transparent;
  --button-text: var(--text);
  --button-border: rgba(var(--accent-rgb), 0.24);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 1.25rem;
  border-radius: 999px;
  border: 1px solid var(--button-border);
  background: var(--button-bg);
  color: var(--button-text);
  text-decoration: none;
  font-weight: 600;
  white-space: nowrap;
  transition: transform 220ms ease, box-shadow 220ms ease, background 220ms ease;
}

.button:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 26px rgba(var(--accent-rgb), 0.24);
}

.button-primary {
  --button-bg: linear-gradient(115deg, var(--accent) 0%, var(--accent-soft) 100%);
  --button-text: #f4fbff;
  --button-border: transparent;
}

.button-ghost {
  --button-bg: rgba(255, 255, 255, 0.24);
}

.features {
  margin: 1.2rem auto 5rem;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.1rem;
}

.feature-card,
.release-highlight,
.history-accordion,
.testflight-step {
  background: transparent;
  border: 0;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  border-radius: 0;
  box-shadow: none;
}

.feature-card {
  padding: 1.4rem 1.3rem;
}

.feature-card h2 {
  margin-bottom: 0.55rem;
  font-size: 1.15rem;
}

.feature-card p {
  margin: 0;
  color: var(--text-soft);
}

.testflight {
  margin: 0 auto 0.6rem;
  padding: 0 0 1rem;
}

.testflight-header h2 {
  font-size: clamp(1.7rem, 3.8vw, 2.8rem);
  font-family: "Cormorant Garamond", Georgia, serif;
  font-weight: 600;
}

.testflight-header p {
  margin-top: 0.7rem;
  color: var(--text-soft);
}

.testflight-steps {
  margin-top: 1.15rem;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.95rem;
}

.testflight-step {
  padding: 1.2rem 1.15rem;
}

.testflight-step h3 {
  margin-bottom: 0.5rem;
  font-size: 1.04rem;
}

.testflight-step p {
  margin: 0;
  color: var(--text-soft);
}

.testflight-actions {
  margin-top: 1rem;
}

.beta {
  margin: 0 auto;
  padding: 1.4rem 0;
}

.beta-header h2,
.history-header h2 {
  font-size: clamp(1.7rem, 3.8vw, 2.8rem);
  font-family: "Cormorant Garamond", Georgia, serif;
  font-weight: 600;
}

.beta-header p,
.history-header p {
  margin-top: 0.7rem;
  color: var(--text-soft);
}

.release-highlight {
  margin-top: 1.25rem;
  padding: 1.6rem;
}

.release-meta {
  margin: 0 0 0.6rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  font-size: 0.9rem;
  color: var(--text-soft);
}

.release-headline {
  margin: 0;
  font-size: 1.25rem;
  line-height: 1.28;
}

.release-changes {
  margin-top: 1rem;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem 1.2rem;
}

.release-change-group {
  min-width: 0;
}

.release-change-group h3 {
  font-size: 0.86rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent);
  margin: 0 0 0.55rem;
}

.release-change-group ul {
  margin: 0;
  padding-left: 1rem;
  color: var(--text-soft);
}

.release-change-group li + li {
  margin-top: 0.35rem;
}

.release-actions {
  margin-top: 1.15rem;
}

.history {
  padding: 3.6rem 0 4.5rem;
}

.history-list {
  margin-top: 1.35rem;
  display: flex;
  flex-direction: column;
  gap: 0.82rem;
}

.history-accordion {
  background: transparent;
  overflow: visible;
}

.history-summary {
  list-style: none;
  display: grid;
  grid-template-columns: minmax(220px, 285px) minmax(0, 1fr) auto;
  align-items: center;
  gap: 1rem;
  padding: 1.05rem 1.2rem;
  cursor: pointer;
}

.history-summary::-webkit-details-marker {
  display: none;
}

.history-summary-main h3 {
  font-size: 1rem;
  margin: 0;
}

.history-summary-main p {
  margin: 0.35rem 0 0;
  font-size: 0.92rem;
  color: var(--text-soft);
}

.history-summary-headline {
  margin: 0;
  color: var(--text-soft);
  line-height: 1.4;
}

.history-summary-toggle {
  width: 32px;
  height: 32px;
  border: 1px solid var(--glass-border);
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.24);
  transition: transform 220ms ease;
}

.history-summary-toggle::before {
  content: "";
  width: 9px;
  height: 9px;
  border-right: 2px solid var(--text-soft);
  border-bottom: 2px solid var(--text-soft);
  transform: rotate(45deg) translateY(-1px);
}

.history-accordion[open] .history-summary-toggle {
  transform: rotate(180deg);
}

.history-body {
  border-top: 1px solid var(--line);
  padding: 1rem 1.2rem 1.25rem;
  background: rgba(255, 255, 255, 0.06);
}

.history-changes {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem 1.2rem;
}

.history-change-group {
  min-width: 0;
}

.history-change-group h4 {
  margin: 0 0 0.55rem;
  font-size: 0.84rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent);
}

.history-change-group ul {
  margin: 0;
  padding-left: 1rem;
  color: var(--text-soft);
}

.history-change-group li + li {
  margin-top: 0.32rem;
}

.history-actions {
  margin-top: 1rem;
  display: flex;
  justify-content: center;
}

#loadMoreReleases[hidden] {
  display: none;
}

.site-footer {
  border-top: 1px solid var(--line);
  padding: 1.1rem 0 calc(2rem + env(safe-area-inset-bottom));
  display: flex;
  flex-direction: column;
  gap: 1rem;
  color: var(--text-soft);
  font-size: 0.92rem;
}

.footer-main {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.8rem;
}

.footer-main p,
.footer-legal p {
  margin: 0;
}

.footer-legal {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem 1.2rem;
  padding-top: 0.25rem;
}

.footer-legal p {
  font-size: 0.88rem;
  line-height: 1.45;
}

.legal-wide {
  flex-basis: 100%;
}

.footer-legal a {
  color: var(--accent);
  text-decoration: none;
}

.footer-legal a:hover {
  text-decoration: underline;
}

.bg-shape {
  position: fixed;
  width: 420px;
  height: 420px;
  border-radius: 50%;
  filter: blur(45px);
  opacity: 0.48;
  pointer-events: none;
  z-index: -1;
}

.bg-shape-left {
  left: -160px;
  top: -60px;
  background: radial-gradient(circle, #79a5ff 0%, transparent 68%);
}

.bg-shape-right {
  right: -180px;
  bottom: -120px;
  background: radial-gradient(circle, #a8c6ff 0%, transparent 65%);
}

.loading {
  margin: 0;
  color: var(--text-soft);
}

.empty {
  margin: 0;
  color: var(--text-soft);
}

.reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 640ms ease, transform 640ms ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 990px) {
  .hero {
    padding-top: 4rem;
  }

  .features,
  .testflight-steps,
  .release-changes,
  .history-changes {
    grid-template-columns: 1fr;
  }

  .history-summary {
    grid-template-columns: 1fr auto;
  }

  .history-summary-headline {
    grid-column: 1 / -1;
  }
}

@media (max-width: 640px) {
  .container {
    width: min(1120px, calc(100% - 1.1rem));
  }

  .site-header {
    position: static;
  }

  .nav {
    min-height: 64px;
    gap: 0.55rem;
  }

  .brand {
    font-size: 0.95rem;
  }

  .nav .button {
    min-height: 40px;
    padding: 0 0.9rem;
    font-size: 0.84rem;
  }

  .hero {
    padding: 2.7rem 0 1.9rem;
  }

  h1 {
    font-size: clamp(1.9rem, 10vw, 2.5rem);
    max-width: 12ch;
  }

  .hero-description {
    margin-top: 1rem;
    font-size: 0.97rem;
  }

  .hero-actions {
    margin-top: 1.3rem;
    flex-direction: column;
    align-items: stretch;
    gap: 0.65rem;
  }

  .hero-actions .button {
    width: 100%;
    min-height: 48px;
  }

  .features {
    margin: 0.95rem auto 2.8rem;
    gap: 0.8rem;
  }

  .testflight {
    padding-bottom: 0.65rem;
  }

  .testflight-step {
    padding: 1.05rem;
  }

  .testflight-step h3 {
    font-size: 0.99rem;
  }

  .testflight-actions .button {
    width: 100%;
  }

  .feature-card {
    padding: 1.1rem;
  }

  .beta {
    padding: 0.3rem 0;
  }

  .release-highlight {
    padding: 1.05rem;
  }

  .release-meta {
    gap: 0.45rem;
    font-size: 0.82rem;
  }

  .release-headline {
    font-size: 1.08rem;
  }

  .release-actions .button {
    width: 100%;
  }

  .history {
    padding: 2.3rem 0 3rem;
  }

  .history-summary {
    padding: 0.9rem 1rem;
    gap: 0.72rem;
  }

  .history-summary-main p {
    font-size: 0.84rem;
  }

  .history-summary-headline {
    font-size: 0.92rem;
  }

  .history-body {
    padding: 0.9rem 1rem 1rem;
  }

  .history-actions {
    justify-content: stretch;
  }

  .history-actions .button {
    width: 100%;
    min-height: 48px;
  }

  .site-footer {
    font-size: 0.86rem;
    padding-top: 1rem;
  }

  .footer-legal {
    flex-direction: column;
    align-items: flex-start;
    padding-top: 0.25rem;
    gap: 0.5rem;
  }

  .footer-legal p {
    font-size: 0.84rem;
  }

  .bg-shape {
    width: 330px;
    height: 330px;
    opacity: 0.42;
  }
}

@media (max-width: 390px) {
  .container {
    width: min(1120px, calc(100% - 0.85rem));
  }

  .eyebrow {
    font-size: 0.68rem;
    letter-spacing: 0.13em;
  }

  h1 {
    font-size: clamp(1.72rem, 10.5vw, 2.2rem);
  }

  .feature-card,
  .release-highlight,
  .history-accordion {
    border-radius: 16px;
  }

  .history-summary-toggle {
    width: 28px;
    height: 28px;
  }

  .history-summary-toggle::before {
    width: 8px;
    height: 8px;
  }
}
