@font-face {
  font-family: "Koralle";
  src: url("typefaces/Koralle.woff2") format("woff2");
  font-display: swap;
}

@font-face {
  font-family: "Shambhu Retalic";
  src: url("typefaces/ShambhuBackslant-VF.ttf") format("truetype-variations");
  font-style: italic;
  font-weight: 200 800;
  font-display: swap;
}

:root {
  --bg: #ffffff;
  --fg: #000000;
  --muted: #000000;
  --border: #000000;
  --surface: #ffffff;
  --countdown-wght: 420;
  --countdown-opsz: 72;
}

body[data-theme="inverted"] {
  --bg: #000000;
  --fg: #ffffff;
  --muted: #ffffff;
  --border: #ffffff;
  --surface: #000000;
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--fg);
  font-family: "Koralle", sans-serif;
  transition:
    background-color 220ms ease,
    color 220ms ease;
}

button,
input {
  font: inherit;
}

.page-shell {
  min-height: 100vh;
  display: grid;
  align-content: start;
  justify-items: center;
  gap: clamp(3rem, 7vw, 6rem);
  padding:
    clamp(1.1rem, 2.5vw, 1.8rem)
    clamp(1.2rem, 4vw, 2rem)
    clamp(3rem, 8vw, 5rem);
}

.logo-button {
  appearance: none;
  border: 0;
  background: transparent;
  padding: 0;
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: filter 180ms ease;
}

.logo-button:focus-visible {
  outline: 2px solid var(--fg);
  outline-offset: 10px;
}

.logo {
  grid-area: 1 / 1;
  width: clamp(2.5rem, 4.5vw, 3.5rem);
  height: auto;
  display: block;
  transition: filter 180ms ease;
}

.logo-alt {
  opacity: 0;
}

body[data-theme="inverted"] .logo-default {
  opacity: 0;
}

body[data-theme="inverted"] .logo-alt {
  opacity: 1;
}

.logo-button:hover .logo,
.logo-button:focus-visible .logo,
.logo-button:active .logo {
  filter: invert(1);
}

.countdown-block {
  width: min(100%, 1100px);
  padding-block: clamp(2rem, 7vw, 5rem);
}

.tilt-enable,
.tilt-note {
  display: none;
}

.tilt-enable {
  margin: 0 auto 1rem;
  padding: 0.45rem 0.8rem;
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--fg);
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  cursor: pointer;
}

.tilt-enable:hover,
.tilt-enable:focus-visible,
.tilt-enable:active {
  background: var(--fg);
  color: var(--bg);
}

.tilt-note {
  margin: 0 auto 1rem;
  text-align: center;
  font-size: 0.72rem;
  letter-spacing: 0.03em;
}

.countdown-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(0.5rem, 1.2vw, 1rem);
  align-items: end;
}

.countdown-item {
  text-align: center;
}

.countdown-value {
  font-family: "Shambhu Retalic", serif;
  font-style: italic;
  font-size: clamp(3.2rem, 9.6vw, 8.8rem);
  line-height: 0.86;
  letter-spacing: 0.012em;
  white-space: nowrap;
  font-optical-sizing: none;
  font-variation-settings:
    "wght" var(--countdown-wght),
    "opsz" var(--countdown-opsz);
  transition: font-variation-settings 90ms linear;
}

.countdown-label {
  margin: 0.65rem 0 0;
  font-size: clamp(0.72rem, 0.95vw, 0.84rem);
  letter-spacing: 0.04em;
  color: var(--muted);
}

.subscribe-block {
  width: min(100%, 640px);
  display: flex;
  justify-content: center;
  margin-top: -2.3rem;
  margin-bottom: 0.35rem;
}

.subscribe-cta {
  border: 1px solid var(--border);
  background: var(--fg);
  color: var(--bg);
  padding: 0.82rem 1.05rem;
  font-size: clamp(0.72rem, 0.9vw, 0.82rem);
  letter-spacing: 0.04em;
  text-decoration: none;
  transition:
    background-color 180ms ease,
    color 180ms ease,
    border-color 180ms ease;
}

.subscribe-cta:hover,
.subscribe-cta:focus-visible,
.subscribe-cta:active {
  background: var(--bg);
  color: var(--fg);
}

.subscribe-cta:focus-visible {
  outline: 2px solid var(--fg);
  outline-offset: -2px;
}

.copy-block {
  width: min(100%, 640px);
  text-align: center;
  margin-top: -0.9rem;
}

.copy-block p {
  margin: 0;
  font-size: clamp(0.82rem, 1vw, 0.95rem);
  line-height: 1.45;
  letter-spacing: 0.03em;
}

.copy-block a {
  color: inherit;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.14em;
}

.copy-block a:hover,
.copy-block a:focus-visible {
  text-decoration-thickness: 2px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

@media (max-width: 900px) {
  .countdown-block {
    width: min(100%, 40rem);
    padding-top: 3rem;
    padding-bottom: 4.25rem;
  }

  .tilt-enable[data-visible="true"],
  .tilt-note[data-visible="true"] {
    display: block;
  }

  .countdown-grid {
    grid-template-columns: repeat(2, max-content);
    gap: 1.8rem 2.8rem;
    justify-content: center;
  }

  .countdown-value {
    font-size: clamp(5rem, 18vw, 7.8rem);
  }
}

@media (max-width: 620px) {
  .page-shell {
    gap: 2rem;
  }

  .countdown-block {
    width: min(100%, 32rem);
    padding-top: 3rem;
    padding-bottom: 4.25rem;
  }

  .countdown-grid {
    grid-template-columns: repeat(2, max-content);
    gap: 1.5rem 2.4rem;
    justify-content: center;
  }

  .countdown-value {
    font-size: clamp(4.9rem, 20vw, 7.4rem);
    letter-spacing: 0.008em;
  }

  .countdown-label {
    margin-top: 0.4rem;
  }

  .copy-block p {
    font-size: 0.82rem;
  }
}
