/* -------------------------------------------------
   GLOBAL
   ------------------------------------------------- */
html, body {
  margin: 0;
  padding: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: #251A15;
}

@font-face {
  font-family: "Akony";
  src: url("fontz/AKONY.woff2") format("woff2"),
       url("fontz/AKONY.woff") format("woff");
  font-weight: normal;
  font-style: normal;
}

/* -------------------------------------------------
   FRAME
   ------------------------------------------------- */
.outer-frame {
  position: fixed;
  inset: 0;
  background: #251A15;
  z-index: 0;
}

/* One stacking context for all Eternique visuals */
.inner-frame {
  position: fixed;
  top: 31px;
  right: 31px;
  bottom: 31px;
  left: 31px;

  background: #ffffff;
  border-radius: 15px;
  overflow: hidden;

  z-index: 1;
}

/* Side text in the dark margin (outside inner frame) */
.side-text {
  position: fixed;
  top: 50%;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 12px;
  color: rgba(220, 255, 0, 0.75);
  white-space: nowrap;
  text-shadow: 1px 2px 1px rgba(220, 255, 0, 0.25);
  filter: blur(1px);
  text-transform: uppercase;
  letter-spacing: 2px;
  z-index: 50;
}

.side-text.left {
  left: 15px;
  transform: translate(-50%, -50%) rotate(270deg);
}

.side-text.right {
  right: 15px;
  transform: translate(50%, -50%) rotate(90deg);
}

/* -------------------------------------------------
   BACKGROUND LAYERS (inside inner frame)
   Order:
   0 blob
   1 textures
   2 grain
   10+ UI
   ------------------------------------------------- */
.bg-wrapper {
  position: absolute;
  inset: 0;
  z-index: 0;
}

#eternique-bg {
  width: 100%;
  height: 100%;
  display: block;
}

.texture-layer {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
}

.texture {
  position: absolute;
  transform-origin: center center;
  pointer-events: none;
  will-change: transform, left, top;
}

.texture-1 { mix-blend-mode: color-burn; }
.texture-2 { mix-blend-mode: lighten; }
.texture-3 { mix-blend-mode: multiply; }

/* Static grain */
.grain-layer {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;

  background-image: url("https://eternique.space/imagez/04-noise.png");
  background-repeat: repeat;
  background-size: auto;

  mix-blend-mode: soft-light;
  opacity: 0.1;
}

/* -------------------------------------------------
   UI WRAPPER (everything interactive)
   ------------------------------------------------- */
.frame-content {
  position: relative;
  width: 100%;
  height: 100%;
  padding: 24px;
  box-sizing: border-box;
  z-index: 10;
}

/* -------------------------------------------------
   CIRCLES (no glow, ripples kept)
   ------------------------------------------------- */
.shade {
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
}

.shade p {
  opacity: 0;
  transition: opacity 1s ease;
}

.shade:hover p,
.shade.dragging p {
  opacity: 1;
}

/* Remove the “shade” overlay entirely
.shade::after { content: none; } */

/* Remove glow/shadow but keep ripple filters per circle */
.aesthetic {
  position: absolute;
  border-radius: 50%;
  transform-origin: 50% 50%;
  box-shadow: none;
  z-index: 20; /* above grain + textures */
}

.aesthetic::after {
  content: "";
  position: absolute;
  inset: 0;

  background-image: url("https://eternique.space/imagez/05-circle-noise.png");
  background-repeat: repeat;
  background-size: var(--noise-size, 150%);
  background-position: var(--noise-x, 50%) var(--noise-y, 50%);

  mix-blend-mode: multiply;
  opacity: 0.45;
  pointer-events: none;
  border-radius: inherit;
}


/* Colours (your exact values), texture overlay still added by the inline JS ::after */
#fnord {
  background: rgb(100% 4.68% 0%);
  left: 20vw;
  top: 15vh;
  width: 20vw;
  height: 20vw;
  filter: url(#ripple-fnord) blur(1px);
}

#chucrutte {
  background: rgb(46.5% 46.5% 46.5%);
  left: 55vw;
  top: 10vh;
  width: 10vw;
  height: 10vw;
  filter: url(#ripple-chucrutte) blur(1px);
}

#aligot {
  background: rgb(0% 62.2% 41%);
  left: 32vw;
  top: 60vh;
  width: 12vw;
  height: 12vw;
  filter: url(#ripple-aligot) blur(1px);
}

#smegma {
  background: rgb(100% 73.5% 43.4%);
  left: 60vw;
  top: 40vh;
  width: 15vw;
  height: 15vw;

  /* Smegma above logo so it remains draggable near it */
  z-index: 35;

  filter: url(#ripple-smegma) blur(1px);
}

#fronha {
  background: rgb(42.5% 36.8% 34.1%);
  left: 72vw;
  top: 20vh;
  width: 20vw;
  height: 20vw;
  filter: url(#ripple-fronha) blur(1px);
}

/* Hover text */
#fnord p.hover-stats     { font-size: 3vw; }
#smegma p.hover-stats    { font-size: 2.5vw; }
#aligot p.hover-stats    { font-size: 2vw; }
#fronha p.hover-stats    { font-size: 3vw; }
#chucrutte p.hover-stats { font-size: 1.7vw; }

p.hover-stats {
  position: relative;
  margin: 0;
  padding: 0;
  text-align: center;
  line-height: 1.0;
  color: rgb(255 255 255 / 87%);
  mix-blend-mode: plus-lighter;
  transition: opacity 1s ease;
  font-family: "Roboto Flex", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  font-weight: 300;
}

p.hover-stats .hover-name {
  display: block;
  margin-top: 0.15em;
  font-size: 0.5em;
  letter-spacing: 0.08em;
  text-transform: lowercase;
}

/* -------------------------------------------------
   LOGO
   ------------------------------------------------- */
#eternique {
  font-size: 2rem;
  color: white;

  position: absolute;
  bottom: 1rem;
  left: 50%;
  transform: translateX(-50%);
  text-align: center;
  line-height: 1;

  filter: blur(3px);
  transition: filter 1s ease;
  opacity: 0.75;

  font-family: "Akony", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;

  cursor: pointer;
  user-select: none;

  /* Above grain, below smegma */
  z-index: 30;
}

#eternique:hover {
  filter: blur(1px);
  opacity: 1;
}

#eternique span {
  font-size: 1rem;
  letter-spacing: 3px;
}

#eternique p, #eternique span {
  user-select: none;
}

/* -------------------------------------------------
   AUTO BAR
   ------------------------------------------------- */
#auto-bar {
  position: absolute;
  top: 0;
  left: 0;

  width: 100%;
  z-index: 40;

  display: grid;
  grid-auto-flow: column;
  justify-content: center;
  align-items: center;

  padding: 1rem 0;
  column-gap: 2.5rem;

  pointer-events: auto;
}

.auto-toggle {
  border: none;
  background: none;
  padding: 0;
  cursor: pointer;
  opacity: 0.5;
  transition: opacity 1s ease-in;
}

.auto-toggle:hover { opacity: 0.5; }
.auto-toggle.active { opacity: 1; }

.auto-toggle picture,
.auto-toggle img {
  display: block;
  width: clamp(3rem, 14vw, 5rem);
  height: auto;
  object-fit: contain;
}

/* -------------------------------------------------
   PLAY MODAL (unchanged)
   ------------------------------------------------- */
#play-modal {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 999;
  background: radial-gradient(circle at 50% 30%, rgb(18, 12, 48), rgba(0, 0, 0, 1));
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  transition: opacity 0.4s ease;
}

#play-modal.hidden {
  opacity: 0;
  pointer-events: none;
}

#play-modal .play-modal-panel,
#play-modal > div {
  box-shadow: 10 24vw 50vw rgba(0, 0, 0, 0.8);
}

#play-button {
  font-family: "Roboto Flex", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  font-weight: 200;

  display: inline-flex;
  align-items: center;
  justify-content: center;

  padding: 0.9rem 2.8rem;
  border-radius: 999px;
  border: 1px solid rgba(210, 245, 255, 0.7);
  background: radial-gradient(circle at 30% 0%, rgba(140, 220, 255, 0.35), rgba(10, 30, 100, 0.95));
  color: #fdfdff;

  font-size: 1rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  font-weight: 400;

  cursor: pointer;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.75);

  transition:
    transform 0.15s ease-out,
    box-shadow 0.15s ease-out,
    background 0.3s ease-out,
    border-color 0.3s ease-out;
}

#play-button:hover,
#play-button:focus-visible {
  outline: none;
  transform: translateY(-1px);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.85);
  border-color: rgba(230, 252, 255, 0.95);
  background: radial-gradient(circle at 30% 0%, rgba(170, 240, 255, 0.5), rgba(20, 50, 140, 0.98));
}

#play-button:active {
  transform: translateY(1px);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.7);
}

#play-button {
  min-width: 220px;
  min-height: 52px;
}

/* -------------------------------------------------
   DEBUG OVERLAY (UPDATED: does NOT block sliders)
   ------------------------------------------------- */
.debug-overlay {
  position: fixed;
  inset: 0;
  
  /* keep the dim look */
  background: rgba(0, 0, 0, 0.0);
  z-index: 9999;
  display: none;
  align-items: center;
  justify-content: center;

  /* KEY: let clicks pass through to sliders/logo */
  pointer-events: none;
}

.debug-overlay.is-visible {
  display: flex;
}

/* Panel itself remains interactive */
.debug-panel {
  position: fixed;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);

  min-width: 260px;
  max-width: 420px;
  padding: 16px 20px 54px;

  background: #000000;
  border: 1px solid #00ff7f;
  box-shadow:
    0 0 10px rgba(0, 255, 127, 0.7),
    0 0 25px rgba(0, 255, 127, 0.4);

  color: #8cffc7;
  font-family: "Roboto Flex", system-ui, -apple-system, BlinkMacSystemFont, "SF Pro Text", sans-serif;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  overflow: hidden;

  /* KEY: panel stays clickable even though overlay isn't */
  pointer-events: auto;
}

.debug-panel::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image: linear-gradient(
    to bottom,
    rgba(0, 255, 127, 0.18) 1px,
    transparent 1px
  );
  background-size: 100% 3px;
  mix-blend-mode: screen;
  opacity: 0.5;
}

.debug-panel-header {
  position: relative;
  font-size: 0.7rem;
  margin-bottom: 10px;
  opacity: 0.85;

  cursor: grab;
  user-select: none;
  -webkit-user-select: none;
  touch-action: none;
}

.debug-panel.is-dragging .debug-panel-header {
  cursor: grabbing;
}

.debug-content {
  position: relative;
  font-size: 0.7rem;
  line-height: 1.6;
  z-index: 1;
}

.debug-line {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  white-space: nowrap;
}

.debug-line + .debug-line {
  margin-top: 3px;
}

.debug-line-label { opacity: 0.8; }
.debug-line-value { font-weight: 600; }

.debug-close {
  position: absolute;
  left: 50%;
  bottom: 12px;
  transform: translateX(-50%);

  padding: 6px 14px;
  border-radius: 999px;
  border: 1px solid rgba(0, 255, 127, 0.85);
  background: rgba(0, 0, 0, 0.8);
  color: #8cffc7;

  font-size: 0.7rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;

  cursor: pointer;
}

.debug-close:hover {
  background: rgba(0, 255, 127, 0.12);
}

/* ------------------------------------------------------------------ */
/* Reverb controls (pentagram + wet/dry rectangle) */
/* ------------------------------------------------------------------ */

.reverb-ui {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 60;
}

.reverb-pentagram {
  position: absolute;
  top: 20px;
  right: 20px;

  width: 10vw;
  height: 10vw;
  max-width: 140px;
  max-height: 140px;
  min-width: 64px;
  min-height: 64px;

  opacity: 0;
  transition: opacity 0.2s ease;
  pointer-events: auto;
  touch-action: none;
  user-select: none;
}

.reverb-pentagram.visible {
  opacity: 1;
}

.reverb-pentagram svg {
  width: 100%;
  height: 100%;
  display: block;
  transform-origin: 50% 50%;
}

.reverb-pentagram .pent {
  fill: none;
  stroke: rgba(255, 255, 255, 0.9);
  stroke-width: 7;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: stroke 111ms linear;
}

.reverb-amount {
  position: absolute;
  left: 20px;
  bottom: 20px;

  width: 7.2vw;            /* ~60% of 12vw */
  max-width: 132px;        /* ~60% of 220px */
  min-width: 54px;         /* ~60% of 90px */

  height: 20px;
  background: #DCFF00;

  transform-origin: 50% 50%;
  transform: rotate(-45deg);

  opacity: 0;
  transition: opacity 0.2s ease;
  pointer-events: auto;
  touch-action: none;
  user-select: none;
}

.reverb-amount.visible {
  opacity: 1;
}


.debug-toggle{padding:6px 10px;font-size:12px;font-family:inherit;cursor:pointer;background:#111;color:#fff;border:1px solid #444;border-radius:4px;opacity:.85;}
.debug-toggle:hover{opacity:1;}
.debug-toggle.is-off{background:#2a2a2a;color:#aaa;border-color:#555;}


.reverb-pentagram svg{transition: transform 120ms ease-out;}
.reverb-pentagram.dragging svg{transition: none;}
