:root {
  color-scheme: light dark;
  --bg: #f5f5f7;
  --surface: #ffffffde;
  --text: #111111;
  --muted: #5a5a5f;
  --primary: #0a84ff;
  --primary-pressed: #006be6;
  --border: #d1d1d6;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  min-height: 100dvh;
  background: radial-gradient(circle at top, #dbe9ff 0%, #edf2ff 28%, var(--bg) 62%);
  color: var(--text);
}

.container {
  width: min(720px, calc(100% - 2rem));
  margin: 0 auto;
}

.hero {
  width: 100%;
  padding: 1.5rem 0 0.8rem;
}

.hero-content {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: 2rem 1.25rem;
  text-align: center;
  backdrop-filter: blur(10px);
}

.app-logo {
  width: clamp(80px, 14vw, 120px);
  height: auto;
  border-radius: 23%;
  box-shadow: 0 16px 30px rgba(0, 0, 0, 0.12);
}

.eyebrow {
  margin: 1rem 0 0;
  color: var(--primary);
  font-size: 0.95rem;
  font-weight: 700;
}

h1 {
  margin: 0.35rem 0 0.8rem;
  font-size: clamp(2rem, 5vw, 3.25rem);
  line-height: 1;
  letter-spacing: -0.02em;
}

.lead {
  margin: 0 auto 0.8rem;
  max-width: 36ch;
  color: var(--muted);
  font-size: 1rem;
}

.description {
  margin: 0 auto;
  max-width: 40ch;
  color: var(--muted);
  line-height: 1.5;
}

.site-footer {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;
  color: var(--muted);
  padding: 0.2rem 0 1.2rem;
}

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

.footer-link:hover,
.footer-link:focus-visible {
  color: var(--primary);
}

.modal {
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  z-index: 20;
}

.modal[hidden] {
  display: none;
}

.modal-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
}

.modal-card {
  position: relative;
  width: min(640px, calc(100% - 1.5rem));
  max-height: calc(100dvh - 2rem);
  overflow: auto;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 1rem;
  backdrop-filter: blur(10px);
}

.modal-card h2 {
  margin: 0 0 0.8rem;
}

.modal-content p,
.modal-content li {
  color: var(--muted);
}

.modal-content ul {
  margin-top: 0.35rem;
  padding-left: 1.1rem;
}

.modal-close {
  position: absolute;
  top: 0.5rem;
  right: 0.5rem;
  z-index: 1;
  width: 34px;
  height: 34px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: #f2f2f7;
  color: #111111;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  font-size: 1rem;
  font-weight: 700;
  line-height: 1;
  -webkit-appearance: none;
  appearance: none;
  cursor: pointer;
}

.modal-close::before {
  content: "✕";
}

body.modal-open {
  overflow: hidden;
}

.legal-page {
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 1rem 0;
}

.legal-card {
  width: min(760px, calc(100% - 2rem));
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 1.2rem;
  backdrop-filter: blur(10px);
}

.legal-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.9rem;
}

.legal-logo {
  width: 36px;
  height: 36px;
  border-radius: 23%;
}

.legal-card h1 {
  margin: 0;
  font-size: 1.6rem;
  line-height: 1.1;
}

.legal-card p,
.legal-card li {
  color: var(--muted);
}

.legal-card ul {
  margin: 0.3rem 0 0;
  padding-left: 1.1rem;
}

.legal-back {
  margin-top: 1rem;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0f1014;
    --surface: #1c1c1ee8;
    --text: #f2f2f7;
    --muted: #b4b4bd;
    --border: #3a3a3c;
  }

  body {
    background: radial-gradient(circle at top, #102040 0%, #0f1625 28%, var(--bg) 62%);
  }

  .modal-close {
    background: #2c2c2e;
    color: #f2f2f7;
  }

}

@media (max-width: 480px) {
  .hero-content {
    padding: 1.5rem 1rem;
  }
}
