:root {
  color-scheme: dark;
  --background: #000000;
  --foreground: #ffffff;
  --muted: rgba(255, 255, 255, 0.66);
  --muted-strong: rgba(255, 255, 255, 0.9);
  --panel: rgba(255, 255, 255, 0.052);
  --panel-hover: rgba(255, 255, 255, 0.09);
  --line: rgba(255, 255, 255, 0.085);
}

* { box-sizing: border-box; }
html, body { min-height: 100%; }
body {
  margin: 0;
  background: var(--background);
  color: var(--foreground);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  text-rendering: geometricPrecision;
}

.stage {
  position: relative;
  isolation: isolate;
  min-height: 100vh;
  display: grid;
  grid-template-rows: 1fr auto;
  gap: clamp(1rem, 3vw, 1.75rem);
  padding: clamp(1rem, 4vw, 2.5rem) clamp(1rem, 4vw, 2.5rem) clamp(0.45rem, 0.8vw, 0.6rem);
  overflow: hidden;
}

.ambient,
.smoke-canvas,
.smoke-layer {
  position: fixed;
  inset: 0;
  pointer-events: none;
}

.ambient {
  z-index: -1;
  overflow: hidden;
  background: #000;
}

.smoke-canvas {
  z-index: 0;
  width: 100%;
  height: 100%;
  opacity: 0.95;
  mix-blend-mode: screen;
}

.smoke-layer {
  z-index: 2;
  overflow: hidden;
  mix-blend-mode: screen;
}

.smoke-puff {
  position: absolute;
  left: var(--x);
  top: var(--y);
  width: var(--size);
  height: var(--size);
  border-radius: 999px;
  background:
    radial-gradient(circle at 48% 48%, rgba(255, 255, 255, 0.46), rgba(210, 216, 222, 0.23) 38%, transparent 72%);
  filter: blur(var(--blur));
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.18);
  animation: smoke-puff var(--duration) cubic-bezier(0.17, 0.84, 0.35, 1) forwards;
}

.noise {
  position: absolute;
  inset: 0;
  opacity: 0.045;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.86' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

.hero {
  position: relative;
  z-index: 1;
  align-self: center;
  display: grid;
  place-items: center;
  gap: clamp(1rem, 3vw, 1.8rem);
  text-align: center;
}

.bull {
  position: relative;
  display: grid;
  place-items: center;
  width: min(42vw, 315px);
  aspect-ratio: 1;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
  animation: mark-arrive 1100ms cubic-bezier(0.19, 1, 0.22, 1) both;
  -webkit-tap-highlight-color: transparent;
}

.bull:focus-visible {
  outline: 1px solid rgba(255, 255, 255, 0.42);
  outline-offset: 1.2rem;
  border-radius: 999px;
}

.mark {
  position: relative;
  z-index: 1;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: none;
  transform: translateZ(0);
}

.statement {
  display: grid;
  place-items: center;
  gap: 0.55rem;
  max-width: min(92vw, 720px);
  animation: statement-arrive 1100ms cubic-bezier(0.19, 1, 0.22, 1) 120ms both;
}

.hint {
  margin: 0;
  color: rgba(255, 255, 255, 0.52);
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
  font-size: clamp(0.66rem, 1.4vw, 0.78rem);
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

h1 {
  margin: 0;
  font-size: clamp(1rem, 2.5vw, 1.55rem);
  font-weight: 680;
  line-height: 1;
  letter-spacing: 0.28em;
  text-indent: 0.28em;
}

.hint {
  margin-top: 0.3rem;
  opacity: 0.46;
  letter-spacing: 0.14em;
}

.credit {
  position: relative;
  z-index: 1;
  display: flex;
  justify-content: center;
  margin: 0;
  padding-bottom: env(safe-area-inset-bottom, 0px);
}

.credit-link {
  display: inline-flex;
  align-items: center;
  padding: 0.42rem 0.78rem;
  border-radius: 999px;
  background: var(--panel);
  color: var(--muted);
  text-decoration: none;
  font-size: clamp(0.77rem, 1.6vw, 0.92rem);
  font-weight: 500;
  line-height: 1;
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.04) inset;
  transition: background-color 180ms ease, color 180ms ease;
}

.credit-link:hover,
.credit-link:focus-visible {
  color: var(--muted-strong);
  background: var(--panel-hover);
}

@keyframes mark-arrive {
  from { opacity: 0; transform: translateY(18px) scale(0.96); filter: blur(10px); }
  to { opacity: 1; transform: translateY(0) scale(1); filter: blur(0); }
}

@keyframes statement-arrive {
  from { opacity: 0; transform: translateY(12px); filter: blur(8px); }
  to { opacity: 1; transform: translateY(0); filter: blur(0); }
}

@keyframes smoke-puff {
  0% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.16) rotate(0deg);
  }
  12% { opacity: var(--alpha); }
  100% {
    opacity: 0;
    transform: translate(calc(-50% + var(--dx)), calc(-50% + var(--dy))) scale(var(--scale)) rotate(var(--rotate));
  }
}

@media (max-width: 640px) {
  .stage { padding: 0.85rem 0.9rem 0.95rem; }
  .hero { transform: translateY(-1.5vh); }
  .bull { width: min(74vw, 288px); }
  .hint { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 1ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: 1ms !important;
  }
}
