:root { --orange: #ff7a1a; }

* { box-sizing: border-box; margin: 0; }

html, body { background: #000; }

/* With this set, the body clips its own overflow. Otherwise a caret or letter
   past the edge widens the page and phones zoom out, e.g. on rotation. */
html { overflow-x: hidden; }

body {
  min-height: 100vh;
  min-height: 100dvh;
  display: grid;
  place-items: center;
  padding: 1.25rem;
  overflow-x: clip;
  color: var(--orange);
  font-family: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  /* Let a finger drag across the letters, but keep pinch-zoom. */
  touch-action: pinch-zoom;
  -webkit-tap-highlight-color: transparent;
  -webkit-user-select: none;
  user-select: none;
}

#bloom {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

h1 {
  position: relative;
  z-index: 1;
  font-size: clamp(1rem, 3.6vw, 1.75rem);
  font-weight: 200;
  line-height: 1.3;
  letter-spacing: -0.02em;
  text-align: center;
  text-wrap: balance;
}

.sr {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

/* Hidden until main.js has split it up, so the full text never flashes. */
.js h1:not(.ready) { visibility: hidden; }

.word { display: inline-block; white-space: nowrap; }
.letter { display: inline-block; visibility: hidden; }
.letter.on { visibility: visible; }
.moving .letter { will-change: transform; }

.caret {
  position: absolute;
  left: 0;
  top: 0;
  width: max(1.5px, 0.05em);
  height: 1.05em;
  background: currentColor;
  pointer-events: none;
  transition: opacity 0.8s;
}
.caret.blink { animation: blink 1.06s steps(1) infinite; }
.caret.gone { opacity: 0; }

@keyframes blink { 50% { background: transparent; } }
