/* Vapor — interactive fluid-smoke simulation. Full-bleed canvas. */
*,
*::before,
*::after { box-sizing: border-box; }

html, body {
  -webkit-tap-highlight-color: transparent;
  margin: 0;
  height: 100%;
  overflow: hidden;
  background: #05060b;
  font-family: "Archivo", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
  touch-action: none;
  overscroll-behavior: none;
}

#canvas { position: fixed; inset: 0; width: 100%; height: 100%; display: block; cursor: crosshair; }

.sound-btn {
  position: fixed;
  top: max(14px, env(safe-area-inset-top));
  right: 14px;
  z-index: 6;
  width: 40px; height: 40px;
  border-radius: 50%;
  border: 1.5px solid rgba(200, 210, 235, 0.28);
  background: rgba(10, 12, 22, 0.5);
  color: #cdd6ee;
  font-size: 1.05rem;
  cursor: pointer;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  transition: border-color 140ms ease, background 140ms ease;
}
.sound-btn:hover { border-color: rgba(200, 210, 235, 0.6); }
.sound-btn[aria-pressed="false"] { color: rgba(180, 190, 215, 0.4); }

/* ---------- control bar ---------- */
.controls {
  position: fixed;
  bottom: max(14px, env(safe-area-inset-bottom));
  left: 50%;
  transform: translateX(-50%);
  z-index: 6;
  display: flex;
  gap: 8px;
  padding: 0 10px;
}
.ctrl {
  appearance: none;
  font-family: inherit;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: #d4dcf0;
  background: rgba(12, 15, 26, 0.55);
  border: 1.5px solid rgba(200, 210, 235, 0.24);
  padding: 9px 18px;
  border-radius: 999px;
  cursor: pointer;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  white-space: nowrap;
  transition: border-color 140ms ease, background 140ms ease;
}
.ctrl:hover { border-color: rgba(200, 210, 235, 0.55); background: rgba(20, 24, 40, 0.75); }

/* ---------- frame + hint ---------- */
.frame { position: fixed; inset: 0; z-index: 4; pointer-events: none; }
.frame__corner {
  position: absolute;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(200, 210, 235, 0.5);
  mix-blend-mode: difference;
}
.frame__corner--tl { top: max(14px, env(safe-area-inset-top)); left: 16px; }
.frame__corner--tr { top: max(14px, env(safe-area-inset-top)); right: 62px; }
.frame__corner--bl { bottom: 14px; left: 16px; }
.frame__corner a { color: inherit; text-decoration: none; pointer-events: auto; }
.frame__corner a:hover { color: #fff; }

.hint {
  position: fixed;
  bottom: 62px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 4;
  margin: 0;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: rgba(200, 210, 235, 0.55);
  pointer-events: none;
  white-space: nowrap;
  transition: opacity 300ms ease;
  mix-blend-mode: difference;
}
.hint.is-gone { opacity: 0; }

@media (max-width: 560px) {
  .frame__corner--bl { display: none; }
  .frame__corner--tr { display: none; }
}
