/* ===========================================================================
   WISCRIPT — MISCHIEF LAYER
   A deliberately hostile overlay bolted onto a calm portfolio. Everything in
   here is injected by mischief.js; the page underneath is untouched and still
   wears the pond, so deleting the two tags in index.html reverts it whole.
   Nothing here is load-bearing: if the script never runs, the page is normal.
   =========================================================================== */

:root {
  --msc-tape:  #ffd23f;
  --msc-red:   #e2453a;
  --msc-ink:   #1a1206;
  --msc-dark:  rgba(12,8,4,.92);
}

/* ------------------------------------------------------------- top banner */
.msc-banner {
  position: fixed; inset: 0 0 auto 0; z-index: 9000;
  display: flex; align-items: center; gap: 12px;
  padding: 9px 14px;
  font: 600 13px/1.35 'Spline Sans Mono', ui-monospace, monospace;
  letter-spacing: .02em;
  color: var(--msc-ink);
  background: repeating-linear-gradient(135deg,
    var(--msc-tape) 0 22px, #1a1206 22px 44px);
  box-shadow: 0 2px 14px rgba(0,0,0,.35);
  transform: translateY(-100%);
  transition: transform .5s cubic-bezier(.22,.9,.3,1);
}
.msc-banner.is-in { transform: none; }
.msc-banner__text {
  flex: 1; padding: 4px 10px; border-radius: 3px;
  background: var(--msc-tape); color: var(--msc-ink);
}
.msc-banner__x {
  border: 0; cursor: pointer; padding: 4px 9px; border-radius: 3px;
  font: inherit; color: var(--msc-tape); background: var(--msc-ink);
}
.msc-banner__x:hover { background: #2f2110; }

/* -------------------------------------------------------------------- HUD */
.msc-hud {
  position: fixed; right: 16px; bottom: 16px; z-index: 9000;
  min-width: 186px; padding: 11px 12px 9px;
  border: 1px solid rgba(255,210,63,.35); border-radius: 8px;
  background: var(--msc-dark);
  color: #ffe9a8;
  font: 500 11px/1.5 'Spline Sans Mono', ui-monospace, monospace;
  letter-spacing: .06em; text-transform: uppercase;
  box-shadow: 0 10px 34px rgba(0,0,0,.45);
  transform: translateY(140%);
  transition: transform .55s cubic-bezier(.22,.9,.3,1);
}
.msc-hud.is-in { transform: none; }
.msc-hud__row { display: flex; justify-content: space-between; gap: 14px; }
.msc-hud__row b { color: var(--msc-tape); font-weight: 700; }
.msc-hud__eyes { display: flex; gap: 7px; justify-content: center; margin: 8px 0 6px; }
.msc-eye {
  width: 19px; height: 19px; border-radius: 50%;
  background: #fbfbf6; box-shadow: inset 0 0 0 1px rgba(0,0,0,.35);
  display: grid; place-items: center;
}
.msc-eye i { width: 8px; height: 8px; border-radius: 50%; background: #14100a; display: block; }
.msc-hud__safe {
  width: 100%; margin-top: 6px; padding: 6px; cursor: pointer;
  border: 1px solid rgba(255,210,63,.4); border-radius: 5px;
  background: transparent; color: #ffe9a8;
  font: inherit; letter-spacing: .08em; text-transform: uppercase;
  transition: background .18s ease, color .18s ease;
}
.msc-hud__safe:hover { background: var(--msc-tape); color: var(--msc-ink); }
.msc-hud--safe { border-color: rgba(87,177,131,.45); color: #cfe9dc; }
.msc-hud--safe .msc-hud__row b { color: #7fd3a6; }

/* ----------------------------------------------------------------- toasts */
.msc-toasts {
  position: fixed; left: 16px; bottom: 16px; z-index: 9001;
  display: flex; flex-direction: column-reverse; gap: 8px;
  max-width: min(400px, calc(100vw - 32px));
  pointer-events: none;
}
.msc-toast {
  padding: 10px 13px; border-radius: 7px;
  border-left: 3px solid var(--msc-tape);
  background: var(--msc-dark); color: #f4ede0;
  font: 400 13px/1.45 'Spline Sans Mono', ui-monospace, monospace;
  box-shadow: 0 10px 30px rgba(0,0,0,.42);
  opacity: 0; transform: translateX(-18px);
  transition: opacity .34s ease, transform .34s cubic-bezier(.22,.9,.3,1);
}
.msc-toast.is-in { opacity: 1; transform: none; }
.msc-toast.is-out { opacity: 0; transform: translateX(-18px); }
.msc-toast b { color: var(--msc-tape); }
.msc-toast--sprung { border-left-color: var(--msc-red); }
.msc-toast--sprung b { color: #ff8577; }
.msc-toast__label { display: block; font-size: 10px; letter-spacing: .1em; text-transform: uppercase; opacity: .62; margin-bottom: 2px; }

/* ------------------------------------------------------------ the dodgers */
.msc-dodge { transition: transform .24s cubic-bezier(.22,.9,.3,1); }

/* ------------------------------------------------------- self destruct bar */
.msc-boom {
  position: fixed; inset: auto 0 0 0; z-index: 9002;
  padding: 15px 18px; text-align: center;
  background: var(--msc-red); color: #fff6f4;
  font: 700 15px/1.3 'Spline Sans Mono', ui-monospace, monospace;
  letter-spacing: .16em; text-transform: uppercase;
  transform: translateY(100%);
  transition: transform .45s cubic-bezier(.22,.9,.3,1), background .4s ease;
}
.msc-boom.is-in { transform: none; }
.msc-boom.is-jk { background: #57b183; }

/* ------------------------------------------------------------ exit intent */
.msc-exit {
  position: fixed; inset: 0; z-index: 9003;
  display: grid; place-items: center;
  background: rgba(8,12,14,.72);
  opacity: 0; transition: opacity .3s ease;
}
.msc-exit.is-in { opacity: 1; }
.msc-exit__card {
  max-width: 400px; padding: 26px 30px; border-radius: 12px;
  background: #14100a; border: 1px solid rgba(255,210,63,.3);
  color: #ffe9a8; text-align: center;
  font: 400 15px/1.55 'Spline Sans Mono', ui-monospace, monospace;
  transform: scale(.94); transition: transform .3s cubic-bezier(.22,.9,.3,1);
}
.msc-exit.is-in .msc-exit__card { transform: none; }
.msc-exit__card b { display: block; margin-bottom: 8px; font-size: 19px; color: var(--msc-tape); }

/* ------------------------------------------------------------- duck rain  */
.msc-rain { position: fixed; inset: 0; z-index: 8999; pointer-events: none; overflow: hidden; }
.msc-drop { position: absolute; top: -60px; font-size: 30px; will-change: transform; }

@media (prefers-reduced-motion: reduce) {
  .msc-banner, .msc-hud, .msc-toast, .msc-boom, .msc-exit, .msc-exit__card, .msc-dodge { transition-duration: .01ms !important; }
  .msc-rain { display: none; }
}
@media (max-width: 640px) {
  .msc-hud { right: 10px; bottom: 10px; min-width: 152px; }
  .msc-toasts { left: 10px; bottom: 96px; }
}

/* ------------------------------------------------- the 18+ tier switches  */
.msc-hud__clean {
  width: 100%; margin-top: 5px; padding: 6px; cursor: pointer;
  border: 1px solid rgba(226,69,58,.45); border-radius: 5px;
  background: transparent; color: #ffc2bb;
  font: inherit; letter-spacing: .08em; text-transform: uppercase;
  transition: background .18s ease, color .18s ease;
}
.msc-hud__clean:hover { background: var(--msc-red); color: #fff6f4; }
.msc-hud__clean.is-on { border-color: rgba(87,177,131,.5); color: #a9e0c4; }
.msc-hud__clean.is-on:hover { background: #57b183; color: #08120d; }

/* ------------------------------------------------- caught, popup was blocked */
.msc-gotcha {
  position: fixed; inset: 0; z-index: 9600;
  display: grid; place-items: center;
  background: rgba(8,5,2,.72);
  opacity: 0; transition: opacity .34s ease;
}
.msc-gotcha.is-in { opacity: 1; }
.msc-gotcha__card {
  max-width: 420px; margin: 20px;
  padding: 22px 24px 18px;
  border: 2px solid var(--msc-tape);
  border-radius: 12px;
  background: var(--msc-dark);
  color: #f6ead2;
  font: 400 14.5px/1.6 'Spline Sans Mono', ui-monospace, monospace;
  box-shadow: 0 22px 60px rgba(0,0,0,.6);
  transform: translateY(14px) scale(.97);
  transition: transform .34s cubic-bezier(.22,.9,.3,1);
}
.msc-gotcha.is-in .msc-gotcha__card { transform: none; }
.msc-gotcha__card b { color: var(--msc-tape); }
.msc-gotcha__duck { font-size: 34px; line-height: 1; margin-bottom: 8px; }
.msc-gotcha__row { display: flex; gap: 10px; margin-top: 18px; }
.msc-gotcha__go, .msc-gotcha__no {
  flex: 1; padding: 9px 12px; border-radius: 8px; cursor: pointer;
  font: 600 13px/1 'Spline Sans Mono', ui-monospace, monospace;
}
.msc-gotcha__go { border: 0; background: var(--msc-tape); color: var(--msc-ink); }
.msc-gotcha__no { border: 1px solid rgba(246,234,210,.28); background: transparent; color: #f6ead2; }
.msc-gotcha__go:hover { filter: brightness(1.08); }
.msc-gotcha__no:hover { border-color: rgba(246,234,210,.55); }

