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

@media (prefers-reduced-motion: no-preference) {
  html {
    scroll-behavior: smooth;
  }
}

:root {
  --bg: #0f1115;
  --text: #f5f6f8;
  --muted: #a8afbd;
  --accent: #4ade80;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.4;
}

.banner {
  display: block;
  padding: 12px 24px;
  text-decoration: none;
  text-align: center;
  font-weight: 600;
  letter-spacing: 0.02em;
  background: var(--accent);
  color: var(--bg);
}

.hero {
  max-width: 900px;
  margin: 0 auto;
  padding: 72px 24px 48px;
  text-align: center;
}

h1 {
  margin: 0 0 24px;
  font-size: clamp(2rem, 6vw, 3.75rem);
  line-height: 1.1;
  letter-spacing: -0.02em;
}

.section {
  max-width: 900px;
  margin: 0 auto;
  padding: 24px;
}

.photo {
  display: block;
  width: 240px;
  height: 240px;
  max-width: 100%;
  object-fit: cover;
  border-radius: 16px;
  margin: 0 auto 24px;
}

.section .caption {
  margin: -12px 0 0;
  font-size: 0.875rem;
  color: var(--muted);
  text-align: center;
}

.section .caption--sub {
  margin: 4px 0 24px;
  opacity: 0.8;
}

.section h2 {
  margin: 0 0 16px;
  font-size: clamp(1.5rem, 4vw, 2rem);
}

.section p {
  margin: 0;
  font-size: 1.125rem;
  color: var(--muted);
}

.story h3 {
  margin: 0 0 24px;
  font-size: clamp(1.25rem, 3.5vw, 1.5rem);
  line-height: 1.3;
  color: var(--text);
}

.story-img {
  margin: 8px 0 24px;
}

.story-img img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 12px;
}

.story p {
  margin: 0 0 20px;
  line-height: 1.6;
}

.download {
  text-align: center;
  padding: 16px 0 8px;
}

.section .download__text {
  margin: 0 0 24px;
  font-size: 1.25rem;
  color: var(--text);
}

.download__button {
  border: 0;
  cursor: pointer;
  font-family: inherit;
  display: inline-block;
  width: 100%;
  max-width: 560px;
  padding: 24px 32px;
  border-radius: 14px;
  background: var(--accent);
  color: var(--bg);
  font-size: clamp(1.25rem, 4vw, 1.75rem);
  font-weight: 800;
  text-decoration: none;
  text-align: center;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
}

.download__button:hover {
  transform: translateY(-2px);
}

.footer {
  padding: 24px;
  text-align: center;
  font-size: 0.875rem;
  color: var(--muted);
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.footer p {
  margin: 0;
}

.notes {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 8px;
}

.note {
  font-size: clamp(1rem, 2.5vw, 1.25rem);
  color: var(--muted);
}

.note--yes {
  color: var(--accent);
}

.listen {
  margin-top: 32px;
  padding: 14px 28px;
  border: 2px solid var(--accent);
  border-radius: 999px;
  background: transparent;
  color: var(--accent);
  font-size: 1.125rem;
  font-weight: 700;
  cursor: pointer;
}

.listen {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.listen__icon {
  flex: none;
}

.listen:hover:not(:disabled) {
  background: var(--accent);
  color: var(--bg);
}

.listen:disabled {
  opacity: 0.7;
  cursor: progress;
}

.player {
  display: block;
  width: 100%;
  max-width: 560px;
  margin: 32px auto 0;
}

.player[hidden],
.listen[hidden],
.listen-error[hidden] {
  display: none;
}

.listen-error {
  margin: 12px 0 0;
  color: #f87171;
}

.modal {
  width: min(440px, calc(100% - 32px));
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 16px;
  background: #181b22;
  color: var(--text);
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.6);
}

.modal::backdrop {
  background: rgba(0, 0, 0, 0.7);
}

.modal__form,
.modal__success {
  padding: 32px 28px 28px;
}

.modal__close {
  position: absolute;
  top: 12px;
  right: 12px;
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
}

.modal__close:hover {
  background: rgba(255, 255, 255, 0.08);
  color: var(--text);
}

.modal__title {
  margin: 0 0 8px;
  padding-right: 32px;
  font-size: 1.5rem;
  line-height: 1.2;
}

.modal__text {
  margin: 0 0 20px;
  color: var(--muted);
}

.field {
  display: block;
  margin-bottom: 16px;
}

.field span {
  display: block;
  margin-bottom: 6px;
  font-size: 0.875rem;
  font-weight: 600;
}

.field input {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 10px;
  background: var(--bg);
  color: var(--text);
  font: inherit;
  font-size: 1rem;
}

.field input:focus {
  outline: 2px solid var(--accent);
  outline-offset: 1px;
}

.modal__submit {
  width: 100%;
  padding: 14px 20px;
  border: 0;
  border-radius: 12px;
  background: var(--accent);
  color: var(--bg);
  font: inherit;
  font-size: 1.125rem;
  font-weight: 800;
  cursor: pointer;
}

.modal__submit:disabled {
  opacity: 0.7;
  cursor: progress;
}

.modal__error {
  margin: 0 0 16px;
  color: #f87171;
}

.modal__note {
  margin: 0 0 16px;
  font-size: 0.875rem;
  line-height: 1.5;
  color: var(--muted);
}
