:root {
  --bg: #050505;
  --bg-2: #0b0b0b;
  --ink: #f7f7f7;
  --muted: #9a9a9a;
  --line: rgba(255, 255, 255, 0.14);
  --paper: #f4f4f4;
  --paper-ink: #0a0a0a;
  --paper-muted: #666666;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --container: 1280px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; }

.container { width: min(100% - 72px, var(--container)); margin-inline: auto; }

.grain {
  position: fixed;
  inset: 0;
  z-index: 90;
  pointer-events: none;
  opacity: 0.035;
  background-image: url("assets/noise.png");
  background-repeat: repeat;
}

.progress {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 120;
  width: 100%;
  height: 2px;
  background: #ffffff;
  transform: scaleX(0);
  transform-origin: left center;
  pointer-events: none;
}

/* ---------- Top bar ---------- */

.topbar {
  position: relative;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 88px;
  padding: 0 36px;
  border-bottom: 1px solid var(--line);
}

.mark {
  display: flex;
  align-items: center;
  gap: 2px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: transparent;
  cursor: pointer;
  letter-spacing: -0.06em;
  font-size: 1.05rem;
  font-weight: 800;
  transition: background 0.25s, color 0.25s, transform 0.25s;
}
.mark span { display: block; }
.mark:hover { background: #ffffff; color: #000000; }
.mark.hit { transform: scale(0.92); background: #e6e6e6; color: #000000; }

.topbar-note {
  margin: 0;
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
}
.topbar-note i { width: 26px; height: 1px; background: var(--muted); }

.availability {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 7px 13px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  white-space: nowrap;
}
.availability i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #5c5c5c;
  flex: 0 0 auto;
}
.availability.online { color: #ffffff; border-color: rgba(255, 255, 255, 0.4); }
.availability.online i { background: #ffffff; box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.14); }

.topbar-call {
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  border-bottom: 1px solid var(--line);
  padding-bottom: 3px;
  transition: border-color 0.25s;
}
.topbar-call span { color: var(--muted); margin-left: 6px; }
.topbar-call:hover { border-color: #ffffff; }

/* ---------- Hero ---------- */

.hero {
  position: relative;
  min-height: calc(100vh - 88px);
  display: flex;
  align-items: center;
  overflow: hidden;
  padding: 100px 0 110px;
}

.hero-glow {
  position: absolute;
  width: 900px;
  height: 900px;
  right: -280px;
  top: -260px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.08), transparent 66%);
  pointer-events: none;
}

.hero-inner { position: relative; z-index: 2; }

.kicker {
  margin: 0 0 28px;
  font-size: 0.74rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--muted);
}

.hero-title {
  margin: 0;
  max-width: 15ch;
  font-size: clamp(4rem, 12.5vw, 12rem);
  line-height: 0.84;
  letter-spacing: -0.075em;
  font-weight: 800;
}
.hero-title > span { display: inline; }
.hero-title .comma {
  display: inline;
  margin-left: 0.06em;
  color: var(--muted);
  font-weight: 400;
  font-size: 0.25em;
  vertical-align: baseline;
}

.hero-statement {
  margin: 44px 0 0;
  max-width: 780px;
  font-size: clamp(1.15rem, 2.2vw, 1.8rem);
  line-height: 1.38;
  letter-spacing: -0.03em;
  color: #d6d6d6;
}
.hero-statement a {
  color: #ffffff;
  border-bottom: 1px solid rgba(255, 255, 255, 0.45);
  word-break: break-all;
  transition: background 0.25s, color 0.25s;
}
.hero-statement a:hover { background: #ffffff; color: #000000; }
.hero-statement .and { display: block; margin-top: 6px; color: var(--muted); }

.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 46px; }

.btn {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-height: 54px;
  padding: 0 26px;
  border-radius: 999px;
  font-size: 0.86rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  transition: transform 0.3s var(--ease), background 0.3s, color 0.3s, border-color 0.3s;
}
.btn:hover { transform: translateY(-2px); }
.btn span { font-size: 1rem; }
.btn-solid { background: #ffffff; color: #000000; }
.btn-solid:hover { background: #d4d4d4; }
.btn-line { border: 1px solid var(--line); color: #ffffff; }
.btn-line:hover { border-color: #ffffff; background: rgba(255, 255, 255, 0.06); }

.hero-hint {
  margin: 34px 0 0;
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #5c5c5c;
}

.hero-index {
  position: absolute;
  right: 36px;
  bottom: 34px;
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  color: #5c5c5c;
}

/* ---------- Manifesto ---------- */

.manifesto {
  background: var(--paper);
  color: var(--paper-ink);
  padding: 140px 0;
}

.manifesto-grid { display: grid; grid-template-columns: 220px 1fr; gap: 60px; }

.manifesto-side { display: flex; flex-direction: column; gap: 20px; }
.eyebrow {
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted);
}
.manifesto .eyebrow { color: var(--paper-muted); }
.side-line { width: 54px; height: 1px; background: #999999; }

.manifesto-main h2 {
  margin: 0;
  font-size: clamp(3rem, 8vw, 7.4rem);
  line-height: 0.92;
  letter-spacing: -0.07em;
  font-weight: 800;
}
.manifesto-main h2 em { font-style: normal; -webkit-text-stroke: 1px #0a0a0a; color: transparent; }
.manifesto-main > p {
  margin: 40px 0 0;
  max-width: 620px;
  font-size: clamp(1rem, 1.6vw, 1.35rem);
  line-height: 1.6;
  color: var(--paper-muted);
}

.manifesto-meta {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  margin-top: 72px;
  border-top: 1px solid #cccccc;
}
.manifesto-meta div { padding: 22px 20px 0 0; border-right: 1px solid #cccccc; }
.manifesto-meta div:last-child { border-right: 0; }
.manifesto-meta b { display: block; font-size: 0.76rem; letter-spacing: 0.12em; }
.manifesto-meta span { display: block; margin-top: 8px; font-size: 0.82rem; color: var(--paper-muted); text-transform: uppercase; letter-spacing: 0.1em; }

/* ---------- Apps ---------- */

.apps { background: var(--bg-2); padding: 130px 0 150px; }

.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 40px;
  margin-bottom: 64px;
}
.section-head h2 {
  margin: 16px 0 0;
  font-size: clamp(3.2rem, 8vw, 7rem);
  line-height: 0.9;
  letter-spacing: -0.07em;
}
.section-head > p { max-width: 360px; margin: 0; color: var(--muted); line-height: 1.6; font-size: 0.95rem; }

.app-grid { display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--line); }

.app-card {
  position: relative;
  min-height: 280px;
  padding: 30px 28px 28px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  transition: background 0.35s, color 0.35s;
}
.app-card:nth-child(3n) { border-right: 0; }
.app-card:hover { background: #f4f4f4; color: #050505; }
.app-num { font-size: 0.72rem; letter-spacing: 0.18em; color: var(--muted); }
.app-card:hover .app-num { color: #666666; }
.app-card h3 {
  margin: auto 0 12px;
  font-size: clamp(1.5rem, 2.4vw, 2.2rem);
  letter-spacing: -0.05em;
  line-height: 1;
}
.app-card p { margin: 0; max-width: 26ch; font-size: 0.88rem; line-height: 1.5; color: var(--muted); }
.app-card:hover p { color: #555555; }
.app-status {
  position: absolute;
  top: 28px;
  right: 28px;
  font-size: 0.66rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 6px 11px;
}
.app-card:hover .app-status { border-color: #bbbbbb; color: #555555; }
.app-status.maybe { font-style: italic; }

/* ---------- Closing ---------- */

.closing { background: var(--bg); padding: 150px 0 160px; text-align: center; }
.closing-inner { display: flex; flex-direction: column; align-items: center; }
.closing-big {
  margin: 0;
  font-size: clamp(1rem, 2vw, 1.4rem);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted);
}
.closing-phone {
  display: inline-block;
  margin: 30px 0 26px;
  font-size: clamp(3.5rem, 13vw, 12rem);
  font-weight: 800;
  letter-spacing: -0.08em;
  line-height: 0.9;
  transition: opacity 0.3s;
}
.closing-phone:hover { opacity: 0.55; }
.closing-small { margin: 0; color: var(--muted); font-size: 0.9rem; }

.footer { border-top: 1px solid var(--line); padding: 26px 0; background: var(--bg); }
.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  font-size: 0.74rem;
  letter-spacing: 0.06em;
  color: var(--muted);
}
.footer-inner i { display: inline-block; width: 3px; height: 3px; border-radius: 50%; background: currentColor; margin: 0 9px; vertical-align: middle; }
.footer-inner a:hover { color: #ffffff; }

/* ---------- Secret countdown ---------- */

.countdown {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: grid;
  place-items: center;
  background: #000000;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.5s var(--ease), visibility 0.5s;
}
.countdown.open { opacity: 1; visibility: visible; }

.snow { position: absolute; inset: 0; overflow: hidden; pointer-events: none; }
.flake {
  position: absolute;
  top: -12px;
  border-radius: 50%;
  background: #ffffff;
  opacity: 0.5;
  animation: fall linear infinite;
}
@keyframes fall {
  to { transform: translate3d(20px, 110vh, 0); opacity: 0.15; }
}

.countdown-card {
  position: relative;
  z-index: 2;
  width: min(100% - 40px, 900px);
  padding: 56px 44px;
  border: 1px solid var(--line);
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.035);
  text-align: center;
}
.countdown-card h2 {
  margin: 18px 0 42px;
  font-size: clamp(2.4rem, 7vw, 5.4rem);
  letter-spacing: -0.06em;
  line-height: 0.95;
}
.clock { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.clock > div {
  padding: 24px 8px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.03);
}
.clock b {
  display: block;
  font-size: clamp(2.2rem, 6vw, 4.6rem);
  line-height: 1;
  letter-spacing: -0.06em;
  font-variant-numeric: tabular-nums;
}
.clock span { display: block; margin-top: 10px; font-size: 0.66rem; letter-spacing: 0.2em; text-transform: uppercase; color: var(--muted); }
.festive { margin: 36px 0 0; font-size: 0.8rem; letter-spacing: 0.18em; text-transform: uppercase; color: var(--muted); }
.countdown-close {
  margin-top: 30px;
  padding: 11px 24px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: transparent;
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background 0.25s, color 0.25s;
}
.countdown-close:hover { background: #ffffff; color: #000000; }

/* ---------- Reveal ---------- */

.reveal { opacity: 0; transform: translateY(24px); transition: opacity 0.75s var(--ease), transform 0.75s var(--ease); }
.reveal.in-view { opacity: 1; transform: none; }
.app-card.reveal:nth-child(2) { transition-delay: 0.06s; }
.app-card.reveal:nth-child(3) { transition-delay: 0.12s; }
.app-card.reveal:nth-child(4) { transition-delay: 0.06s; }
.app-card.reveal:nth-child(5) { transition-delay: 0.12s; }
.app-card.reveal:nth-child(6) { transition-delay: 0.18s; }

/* ---------- Responsive ---------- */

@media (max-width: 900px) {
  .container { width: min(100% - 40px, var(--container)); }
  .topbar { padding: 0 20px; min-height: 74px; }
  .topbar-note { display: none; }
  .hero { min-height: auto; padding: 90px 0 100px; }
  .hero-title { font-size: clamp(3.4rem, 13vw, 7rem); }
  .manifesto-grid { grid-template-columns: 1fr; gap: 36px; }
  .app-grid { grid-template-columns: repeat(2, 1fr); }
  .app-card:nth-child(3n) { border-right: 1px solid var(--line); }
  .app-card:nth-child(2n) { border-right: 0; }
  .section-head { flex-direction: column; align-items: flex-start; }
}

@media (max-width: 560px) {
  .container { width: min(100% - 28px, var(--container)); }
  .availability span { display: none; }
  .availability { padding: 7px 9px; }
  .hero-actions { flex-direction: column; align-items: stretch; }
  .hero-actions .btn { justify-content: space-between; }
  .manifesto { padding: 100px 0; }
  .manifesto-meta { grid-template-columns: repeat(2, 1fr); gap: 24px 0; }
  .manifesto-meta div:nth-child(2) { border-right: 0; }
  .apps { padding: 100px 0; }
  .app-grid { grid-template-columns: 1fr; }
  .app-card, .app-card:nth-child(3n) { border-right: 0; min-height: 230px; }
  .closing { padding: 110px 0; }
  .clock { grid-template-columns: repeat(2, 1fr); }
  .countdown-card { padding: 40px 22px; }
  .footer-inner { flex-direction: column; align-items: flex-start; gap: 10px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .flake { animation: none; }
}
