/* Alarmun — лэндинг.
   Язык самого приложения: светлая бумага с зерном (в приложении это картинка
   noisy_back поверх белого, здесь она же), чёрные кнопки со скруглением 12 и
   пиксельным шрифтом Press Start 2P, как «Add alarm», текст Golos Text — им
   набраны и фраза будильника, и список. Тёмное только одно: экран звонка,
   #2E1F14 с кремовым текстом, где узнанные слова загораются оливковым #A5BC33.
   Разделы размечены временем слева, как строки в списке будильников: у каждого
   раздела время того экрана, который он показывает. Прокрутку страница не
   перехватывает. */

:root {
  --paper: #f4f4f4;
  --card: #fff;
  --ink: #0f0f0f;
  --ink-2: rgb(15 15 15 / 66%);
  --ink-3: rgb(15 15 15 / 44%);
  --line: rgb(15 15 15 / 12%);
  --brown: #2e1f14;
  --cream: #f2e6d9;
  --beige: #ccb8a8;
  --olive: #a5bc33;
  --blue: #0a84ff;
  --pad: clamp(20px, 4.4vw, 72px);
  --max: 1240px;
  --rail: clamp(0px, 8vw, 132px);
  --sans: "Golos Text", system-ui, -apple-system, sans-serif;
  --pixel: "Press Start 2P", ui-monospace, monospace;
  --ease: cubic-bezier(.2, .7, .15, 1);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 76px; }
body {
  margin: 0; color: var(--ink); background: var(--paper) url("/alarmun-landing/brand/grain.png") repeat;
  background-size: 209px 209px; font: 400 17px/1.55 var(--sans); -webkit-font-smoothing: antialiased; overflow-x: clip;
}
img, video, svg { display: block; max-width: 100%; }
img { height: auto; }
a { color: inherit; }
button { font: inherit; color: inherit; }
figure { margin: 0; }
[hidden] { display: none !important; }
::selection { background: var(--olive); color: var(--brown); }

.wrap { max-width: calc(var(--max) + 2 * var(--pad)); margin: 0 auto; padding: 0 var(--pad); }
.h1 { margin: 0; font: 600 clamp(38px, 5.4vw, 82px)/1.02 var(--sans); letter-spacing: -.035em; text-wrap: balance; }
.h2 { margin: 0; font: 600 clamp(29px, 3.4vw, 50px)/1.06 var(--sans); letter-spacing: -.03em; text-wrap: balance; max-width: 18ch; }
.lead { margin: 0; max-width: 47ch; font: 400 clamp(17px, 1.3vw, 19px)/1.55 var(--sans); color: var(--ink-2); text-wrap: pretty; }
.note { margin: 14px 0 0; font-size: 14px; line-height: 1.5; color: var(--ink-3); max-width: 62ch; }
.why { margin: 26px 0 0; padding-left: 16px; border-left: 3px solid var(--ink); max-width: 60ch; font-size: 16px; line-height: 1.6; text-wrap: pretty; }
.why b { font-weight: 600; }

/* ── Разделы и время слева, как строка будильника ───────────────────────── */
.sec { padding: clamp(64px, 7vw, 116px) 0 0; }
.sec__in { position: relative; padding-left: var(--rail); }
/* время стоит в поле страницы: левые края заголовков и медиа от него не съезжают */
.when {
  position: absolute; left: 0; top: .1em; width: var(--rail); padding-right: 18px;
  font: 500 clamp(19px, 1.5vw, 23px)/1 var(--sans); font-variant-numeric: tabular-nums; color: var(--ink-3);
}
.head { display: grid; gap: 16px 56px; margin-bottom: clamp(24px, 3vw, 40px); }
@media (min-width: 900px) { .head { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); align-items: end; } }
@media (max-width: 719px) {
  .sec__in { padding-left: 0; }
  .when { position: static; width: auto; margin-bottom: 8px; }
}

/* ── Кнопки: чёрная плашка «Add alarm» из приложения ────────────────────── */
.actions { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 52px; padding: 0 22px;
  border: 1px solid var(--line); border-radius: 12px; background: var(--card); color: var(--ink);
  font: 500 16px/1 var(--sans); text-decoration: none; white-space: nowrap; cursor: pointer;
  transition: transform .15s var(--ease), background .2s, border-color .2s;
}
.btn:hover { border-color: rgb(15 15 15 / 28%); }
.btn:active { transform: scale(.96); }  /* как нажатие кнопки в приложении: 0.96 */
.btn--ink { background: var(--ink); color: #fff; border-color: var(--ink); font: 400 13px/1 var(--pixel); letter-spacing: .02em; }
.btn--ink:hover { background: #000; }
.btn--blue { background: var(--blue); border-color: var(--blue); color: #fff; font-weight: 600; }
.btn--blue:hover { background: #0071e3; }
.btn[disabled] { opacity: .45; cursor: default; }
.btn__icon { width: 18px; height: 18px; flex: none; }
.btn:focus-visible, .top a:focus-visible, input:focus-visible { outline: 3px solid var(--olive); outline-offset: 3px; }

/* ── Шапка ─────────────────────────────────────────────────────────────── */
.top {
  position: sticky; top: 0; z-index: 20; display: flex; justify-content: space-between; align-items: center;
  height: 66px; padding: 0 max(var(--pad), calc((100vw - var(--max)) / 2));
  background: rgb(244 244 244 / 88%); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
  border-bottom: 1px solid transparent; transition: border-color .3s;
}
.top.is-scrolled { border-bottom-color: var(--line); }
.top__brand { display: inline-flex; align-items: center; gap: 10px; font: 600 19px/1 var(--sans); letter-spacing: -.02em; text-decoration: none; }
.top__brand img { border-radius: 9px; }
.top__home { font: 500 15px/1 var(--sans); text-decoration: none; padding: 11px 15px; border-radius: 10px; border: 1px solid var(--line); background: var(--card); }
.top__home:hover { border-color: rgb(15 15 15 / 28%); }

/* ── Телефон: симулятор iPhone 17 Pro, экран 402 × 874 точки ────────────── */
.phone { width: 100%; padding: 3.4%; border-radius: 15% / 7%; background: #1b1b1b; box-shadow: 0 30px 60px rgb(15 15 15 / 14%); }
.phone__screen { position: relative; aspect-ratio: 540 / 1174; border-radius: 12% / 5.6%; overflow: hidden; background: #000; }
.phone__screen > img, .phone__screen > video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.shot { display: grid; grid-template-columns: minmax(0, 1fr); gap: 12px; justify-items: center; align-content: start; }
.shot figcaption { font-size: 14px; line-height: 1.45; color: var(--ink-3); max-width: 34ch; text-align: center; }

/* ── Первый экран ──────────────────────────────────────────────────────── */
.hero { padding: clamp(26px, 3vw, 44px) 0 0; }
.hero__in { position: relative; padding-left: var(--rail); display: grid; grid-template-columns: minmax(0, 1fr); gap: clamp(28px, 4vw, 64px); align-items: center; }
.hero__note { grid-column: 1 / -1; margin: 0; }
@media (min-width: 900px) { .hero__in { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); } }
@media (max-width: 719px) { .hero__in { padding-left: 0; } }
.hero__copy { display: grid; grid-template-columns: minmax(0, 1fr); gap: 26px; align-content: center; }
.hero__phone { width: min(100%, 330px); justify-self: center; }

/* ── «Скажи сам»: экран звонка, перенесённый на страницу ────────────────── */
.demo { display: grid; gap: clamp(22px, 3vw, 44px); align-items: center; }
@media (min-width: 900px) { .demo { grid-template-columns: minmax(0, 330px) minmax(0, 1fr); } }
.demo__phone { width: min(100%, 330px); }
.demo__screen { position: absolute; inset: 0; background: var(--brown); display: grid; grid-template-rows: auto 1fr auto; padding: 3.4% 7% 6%; }
/* строка статуса как у соседних снимков: часы посетителя и остров */
.demo__bar { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; color: var(--cream); font-size: clamp(10px, 3.2cqw, 12px); }
.demo__bar span { font-variant-numeric: tabular-nums; }
.demo__bar i { display: block; width: 34%; height: 1.9em; border-radius: 99px; background: #000; }
.demo__body { display: grid; align-content: center; gap: 8px; text-align: center; }
.demo__hint { font-size: clamp(11px, 3.4cqw, 13px); color: var(--beige); }
.demo__line { font: 400 clamp(19px, 6.4cqw, 23px)/1.28 var(--sans); color: var(--cream); }
.demo__line span { transition: color .18s linear; }        /* в приложении цвет меняется разом */
.demo__line span.is-said { color: var(--olive); }
.demo__snooze { border-radius: 16px; background: rgb(255 255 255 / 12%); color: var(--cream); text-align: center; padding: 11px 0; font-size: clamp(11px, 3.4cqw, 13px); }
.demo__phone .phone__screen { container-type: inline-size; }
/* белый лист «Great!», как в приложении: пружина снизу, держится две секунды */
.demo__sheet {
  position: absolute; left: 0; right: 0; bottom: 0; height: 94%; border-radius: 24px 24px 0 0; background: #fff;
  display: grid; align-content: start; justify-items: center; gap: 4px; padding: 16px 16px 0;
  transform: translateY(101%); transition: transform .35s var(--ease);
}
.demo.is-done .demo__sheet { transform: translateY(0); transition: transform .35s cubic-bezier(.2, 1.3, .4, 1); }
.demo__sheet i { width: 36px; height: 5px; border-radius: 2.5px; background: rgb(15 15 15 / 18%); margin-bottom: 8px; }
.demo__sheet b { font: 700 clamp(17px, 5.6cqw, 21px)/1.1 var(--sans); color: #1c2b3d; }
.demo__sheet span { font: 400 clamp(12px, 4cqw, 15px)/1.2 var(--sans); color: #697d94; }
.demo__sheet img { margin-top: 6px; width: 100%; object-fit: cover; object-position: top center; }
.demo__side { display: grid; grid-template-columns: minmax(0, 1fr); gap: 18px; align-content: center; }
.demo__status { min-height: 1.5em; font-size: 15px; color: var(--ink-2); }
.demo.is-listening .demo__dot { display: inline-block; }
.demo__dot { display: none; width: 9px; height: 9px; border-radius: 50%; background: #f01a0a; margin-right: 8px; vertical-align: baseline; animation: pulse 1.1s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: .35; } }
.demo__typed { display: grid; gap: 8px; max-width: 42ch; }
.demo__typed input { height: 48px; padding: 0 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--card); font: 400 16px/1 var(--sans); }
@media (prefers-reduced-motion: reduce) {
  .demo__dot, .demo__sheet { animation: none; transition: none; }
}

/* ── Ряды экранов ──────────────────────────────────────────────────────── */
.row { display: grid; gap: clamp(18px, 2.4vw, 32px); align-items: start; }
.row--two { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); max-width: 980px; }
.row--three { grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); }

/* ── Подборки: карточки фраз, как в ленте приложения ────────────────────── */
.packs { display: grid; gap: clamp(18px, 2.2vw, 30px); grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
.pack { display: grid; grid-template-columns: minmax(0, 1fr); gap: 10px; align-content: start; }
.pack h3 { margin: 0 0 2px; font: 600 17px/1.3 var(--sans); }
.pack p { margin: 0; padding: 16px 18px; border-radius: 16px; background: var(--card); border: 1px solid var(--line); font-size: 15px; line-height: 1.45; }
.pack__paid { font-size: 13px; color: var(--ink-3); }

/* ── Конец ─────────────────────────────────────────────────────────────── */
.end { padding: clamp(72px, 8vw, 128px) 0 clamp(52px, 6vw, 92px); }
.end__in { position: relative; padding-left: var(--rail); display: grid; grid-template-columns: minmax(0, 1fr); gap: 26px; }
@media (max-width: 719px) { .end__in { padding-left: 0; } }
.foot { border-top: 1px solid var(--line); padding: 22px 0 40px; font-size: 14px; color: var(--ink-3); }
.foot__row { display: flex; flex-wrap: wrap; gap: 8px 24px; justify-content: space-between; }
.foot a { text-decoration: none; }
.foot a:hover { color: var(--ink); }
