:root,
html[data-theme="light"] {
  color-scheme: light;
  --bg: #F4F5F7;
  --surface: rgba(255, 255, 255, 0.92);
  --surface-solid: #FFFFFF;
  --surface-alt: #F1F3F6;
  --surface-hover: #E6E9EF;
  --text: #191C1F;
  --muted: #717680;
  --hairline: rgba(25, 28, 31, 0.08);
  --shadow: 0 4px 20px rgba(15, 23, 42, 0.055), 0 1px 2px rgba(15, 23, 42, 0.03);
  --cta-bg: #191C1F;
  --cta-text: #FFFFFF;
  --accent: #0075EB;
  --accent-soft: rgba(0, 117, 235, 0.11);
  --green: #00B87C;
  --green-soft: rgba(0, 184, 124, 0.12);
  --amber: #D97706;
  --amber-soft: rgba(217, 119, 6, 0.12);
  --danger: #E11D48;
  --danger-soft: rgba(225, 29, 72, 0.11);
  --topbar-bg: rgba(244, 245, 247, 0.86);
  --dock-bg: rgba(255, 255, 255, 0.94);
  --spring: cubic-bezier(0.22, 1, 0.36, 1);
}

html[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0B0C0E;
  --surface: rgba(22, 24, 29, 0.9);
  --surface-solid: #16181D;
  --surface-alt: #22252E;
  --surface-hover: #2A2E39;
  --text: #F5F6F8;
  --muted: #8E95A2;
  --hairline: rgba(255, 255, 255, 0.075);
  --shadow: 0 12px 32px rgba(0, 0, 0, 0.42);
  --cta-bg: #FFFFFF;
  --cta-text: #0B0C0E;
  --accent: #3B9EFF;
  --accent-soft: rgba(59, 158, 255, 0.15);
  --green: #10B981;
  --green-soft: rgba(16, 185, 129, 0.15);
  --amber: #F59E0B;
  --amber-soft: rgba(245, 158, 11, 0.15);
  --danger: #FB7185;
  --danger-soft: rgba(251, 113, 133, 0.15);
  --topbar-bg: rgba(11, 12, 14, 0.84);
  --dock-bg: rgba(22, 24, 29, 0.94);
}

* { box-sizing: border-box; }
html, body { height: 100%; }

body {
  margin: 0;
  font-family: "Inter", system-ui, -apple-system, sans-serif;
  background: var(--bg);
  color: var(--text);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
  transition: background-color 0.25s ease, color 0.25s ease;
}

.muted { color: var(--muted); }
.small { font-size: 0.8125rem; }
.hidden { display: none !important; }
.sr-file { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }

#bg-canvas {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
}

#login-view, #app-view { position: relative; z-index: 2; }

.card-surface {
  background: var(--surface);
  backdrop-filter: blur(22px);
  -webkit-backdrop-filter: blur(22px);
  border: 1px solid var(--hairline);
  box-shadow: var(--shadow);
  transition: background-color 0.25s ease, border-color 0.25s ease;
}

button, input, select { font: inherit; color: inherit; }

.pill-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: none;
  border-radius: 999px;
  padding: 11px 18px;
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  text-decoration: none;
  transition: transform 0.15s var(--spring), opacity 0.15s ease, background-color 0.15s ease;
}
.pill-btn:active { transform: scale(0.97); }
.btn-block { width: 100%; }
.btn-sm { padding: 7px 13px; font-size: 0.79rem; }

.pill-primary { background: var(--cta-bg); color: var(--cta-text); }
.pill-primary:hover { opacity: 0.9; }
.pill-soft { background: var(--surface-alt); color: var(--text); }
.pill-soft:hover { background: var(--surface-hover); }
.pill-accent { background: var(--accent); color: #FFFFFF; }
.pill-danger { background: var(--danger-soft); color: var(--danger); }
.btn-xs { padding: 4px 10px; font-size: 0.72rem; }

.circle-icon-btn {
  width: 38px;
  height: 38px;
  border-radius: 999px;
  border: none;
  background: var(--surface-alt);
  color: var(--text);
  display: grid;
  place-items: center;
  cursor: pointer;
  flex-shrink: 0;
  transition: background-color 0.15s ease, transform 0.15s var(--spring);
}
.circle-icon-btn:hover { background: var(--surface-hover); }

.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 13px; }
.field label { font-size: 0.81rem; font-weight: 500; color: var(--muted); }
.input {
  width: 100%;
  background: var(--surface-alt);
  border: 1.5px solid transparent;
  border-radius: 14px;
  padding: 11px 13px;
  outline: none;
  font-size: 0.92rem;
  transition: border-color 0.15s ease, background-color 0.15s ease;
}
.input:focus { border-color: var(--accent); background: var(--surface-solid); }
.pw-wrap { display: flex; gap: 8px; align-items: center; }

/* Login */
.login-wrap { min-height: 100dvh; display: grid; place-items: center; padding: 20px; }
.login-stack { width: 100%; max-width: 400px; display: flex; flex-direction: column; gap: 12px; }
.login-card { border-radius: 28px; padding: 28px; }
.login-top-row { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.login-card h1 { margin: 0 0 5px; font-size: 1.55rem; font-weight: 700; letter-spacing: -0.03em; }
.login-card p { margin: 0 0 20px; font-size: 0.9rem; }
.login-err { color: var(--danger); min-height: 1.2em; margin: 10px 0 0 !important; font-size: 0.85rem; }
.login-divider {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 14px 0 12px;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 500;
}
.login-divider::before,
.login-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--hairline);
}
.google-btn {
  background: var(--surface-solid);
  color: var(--text);
  border: 1.5px solid var(--hairline);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}
.google-btn:hover { background: var(--surface-alt); }
.field-top-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
}
.hint-text {
  font-size: 0.76rem;
  color: var(--amber);
  font-weight: 500;
}
.oauth-helper-box {
  background: var(--surface-alt);
  border: 1px solid var(--hairline);
  border-radius: 16px;
  padding: 12px 14px;
  margin-top: 4px;
}
.code-copy-row {
  display: flex;
  align-items: center;
  gap: 8px;
}
.code-pill {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  background: var(--surface-solid);
  border: 1px solid var(--hairline);
  border-radius: 10px;
  padding: 7px 10px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.76rem;
}
.install-mini-card {
  border-radius: 20px;
  padding: 14px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.rev-logo {
  width: 36px;
  height: 36px;
  border-radius: 12px;
  background: var(--cta-bg);
  color: var(--cta-text);
  font-weight: 700;
  font-size: 1.05rem;
  display: grid;
  place-items: center;
  flex-shrink: 0;
}

/* Topbar */
.topbar {
  position: sticky;
  top: 0;
  z-index: 25;
  background: var(--topbar-bg);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  padding: 10px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.brand { display: flex; align-items: center; gap: 10px; }
.brand-text { display: flex; flex-direction: column; }
.brand-title { font-weight: 700; font-size: 1.02rem; letter-spacing: -0.02em; line-height: 1.1; }
.brand-sub { font-size: 0.72rem; color: var(--muted); }

.top-nav {
  display: flex;
  align-items: center;
  gap: 4px;
  background: var(--surface-alt);
  padding: 4px;
  border-radius: 999px;
}
.top-nav-btn {
  border: none;
  background: transparent;
  border-radius: 999px;
  padding: 7px 14px;
  font-size: 0.83rem;
  font-weight: 600;
  color: var(--muted);
  cursor: pointer;
  transition: background-color 0.15s, color 0.15s;
}
.top-nav-btn.active {
  background: var(--surface-solid);
  color: var(--text);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.topbar-right { display: flex; align-items: center; gap: 8px; }
.speed-chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: var(--surface);
  border: 1px solid var(--hairline);
  border-radius: 999px;
  padding: 6px 12px;
  font-size: 0.76rem;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
}
.live-dot { width: 7px; height: 7px; border-radius: 999px; background: var(--green); }
.sep { color: var(--muted); }

/* Windows Notepad psszzz Easter Egg */
.win-note-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  padding: 3px 6px;
  border-radius: 7px;
  border: 1px solid transparent;
  background: transparent;
  cursor: pointer;
  transition: background 0.16s, border-color 0.16s, transform 0.2s var(--spring), opacity 0.45s ease;
}
.win-note-btn:hover { background: rgba(0, 117, 235, 0.1); border-color: rgba(0, 117, 235, 0.28); transform: translateY(-1px); }
.win-note-btn.rustle { animation: noteRustle 0.42s var(--spring); }
.win-note-btn.gone { opacity: 0; pointer-events: none; transform: scale(0.75) translateY(-6px); }
.win-note-svg { width: 22px; height: 26px; filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2)); }
.win-note-label { font-family: "Segoe UI", system-ui, sans-serif; font-size: 0.64rem; line-height: 1; color: var(--text); font-weight: 500; }
@keyframes noteRustle {
  0% { transform: rotate(0deg) scale(1); }
  25% { transform: rotate(-11deg) scale(1.08); }
  55% { transform: rotate(9deg) scale(1.06); }
  100% { transform: rotate(0deg) scale(1); }
}

/* Workspace */
.workspace {
  max-width: 1280px;
  margin: 0 auto;
  padding: 12px 18px 98px;
}
.view-section { display: flex; flex-direction: column; gap: 18px; }
.two-col { display: grid; grid-template-columns: 1fr; gap: 18px; }
.pane {
  border-radius: 24px;
  padding: 22px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-width: 0;
}

.section-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.section-head h2 { margin: 0; font-size: 1.08rem; font-weight: 700; letter-spacing: -0.02em; }

/* Hero Storage Balance + Quick Actions */
.hero-balance { display: flex; flex-direction: column; gap: 5px; }
.hero-eyebrow { font-size: 0.82rem; font-weight: 500; color: var(--muted); }
.hero-amount { font-size: 2.3rem; font-weight: 700; letter-spacing: -0.04em; line-height: 1.05; font-variant-numeric: tabular-nums; }
.hero-meta { font-size: 0.8rem; color: var(--muted); font-variant-numeric: tabular-nums; margin-bottom: 4px; }
.thin-track { height: 5px; width: 100%; background: var(--surface-alt); border-radius: 999px; overflow: hidden; }
.thin-fill { height: 100%; width: 0%; background: var(--accent); border-radius: 999px; transition: width 0.35s var(--spring); }

.quick-actions { display: flex; gap: 20px; padding: 4px 0; }
.qa-item { background: none; border: none; padding: 0; display: flex; flex-direction: column; align-items: center; gap: 7px; cursor: pointer; }
.qa-circle { width: 46px; height: 46px; border-radius: 999px; background: var(--surface-alt); color: var(--text); display: grid; place-items: center; transition: transform 0.16s var(--spring); }
.qa-primary { background: var(--accent); color: #FFFFFF; }
.qa-item:hover .qa-circle { transform: translateY(-2px); }
.qa-label { font-size: 0.78rem; font-weight: 600; }

/* Revolut List Rows */
.rev-list { display: flex; flex-direction: column; }
.rev-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 4px; border-bottom: 1px solid var(--hairline); }
.rev-row:last-child { border-bottom: none; padding-bottom: 2px; }
.rev-row:first-child { padding-top: 2px; }
.rev-row-left { display: flex; align-items: center; gap: 12px; min-width: 0; flex: 1; }
.rev-avatar { width: 42px; height: 42px; border-radius: 14px; background: var(--surface-alt); display: grid; place-items: center; flex-shrink: 0; }
.rev-avatar.movies { background: var(--accent-soft); color: var(--accent); }
.rev-avatar.series { background: var(--green-soft); color: var(--green); }
.rev-avatar.music { background: var(--amber-soft); color: var(--amber); }
.rev-row-text { min-width: 0; flex: 1; }
.rev-row-title { font-weight: 600; font-size: 0.94rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rev-row-sub-btn { background: none; border: none; padding: 0; margin-top: 2px; color: var(--muted); font-size: 0.8rem; cursor: pointer; }
.rev-row-sub-btn:hover { color: var(--accent); }
.rev-row-right { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.rev-size { font-weight: 600; font-size: 0.88rem; font-variant-numeric: tabular-nums; }

/* Transfers */
.xfer-row { padding: 13px 0; border-bottom: 1px solid var(--hairline); display: flex; flex-direction: column; gap: 8px; }
.xfer-row:last-child { border-bottom: none; }
.xfer-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; }
.xfer-name { font-weight: 600; font-size: 0.9rem; word-break: break-word; line-height: 1.35; }
.state-pill { flex-shrink: 0; padding: 4px 10px; border-radius: 999px; font-size: 0.72rem; font-weight: 600; background: var(--surface-alt); color: var(--muted); }
.state-dl { background: var(--accent-soft); color: var(--accent); }
.state-seed { background: var(--green-soft); color: var(--green); }
.state-warn { background: var(--amber-soft); color: var(--amber); }
.state-err { background: var(--danger-soft); color: var(--danger); }
.xfer-meta { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px; font-size: 0.78rem; color: var(--muted); font-variant-numeric: tabular-nums; }

/* Cinema / Netflix Mode */
.cinema-search-bar { display: flex; gap: 10px; }
.cinema-search-bar .input { flex: 1; }
.cinema-hero {
  position: relative;
  border-radius: 20px;
  overflow: hidden;
  min-height: 240px;
  background-size: cover;
  background-position: center;
  display: flex;
  align-items: flex-end;
  padding: 24px;
  color: #FFFFFF;
}
.cinema-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(11, 12, 14, 0.92) 0%, rgba(11, 12, 14, 0.55) 55%, rgba(11, 12, 14, 0.2) 100%);
}
.cinema-hero-content { position: relative; z-index: 1; max-width: 540px; display: flex; flex-direction: column; gap: 8px; }
.cinema-hero-content h3 { margin: 0; font-size: 1.55rem; letter-spacing: -0.02em; }
.cinema-hero-content p { margin: 0; font-size: 0.86rem; color: rgba(255, 255, 255, 0.82); display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }

.poster-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(148px, 1fr));
  gap: 14px;
}
.poster-card {
  background: var(--surface-alt);
  border-radius: 16px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.18s var(--spring), box-shadow 0.18s ease;
  cursor: pointer;
}
.poster-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.poster-img { width: 100%; aspect-ratio: 2 / 3; object-fit: cover; background: var(--surface-hover); display: block; }
.poster-body { padding: 10px; display: flex; flex-direction: column; gap: 4px; flex: 1; justify-content: space-between; }
.poster-title { font-weight: 600; font-size: 0.85rem; line-height: 1.25; }
.poster-meta { font-size: 0.74rem; color: var(--muted); }

/* Telemetry & Server Control */
.stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(195px, 1fr));
  gap: 12px;
}
.stat-card {
  background: var(--surface-alt);
  border-radius: 18px;
  padding: 15px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.stat-label { font-size: 0.78rem; color: var(--muted); font-weight: 500; }
.stat-val { font-size: 1.45rem; font-weight: 700; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; }
.stat-sub { font-size: 0.76rem; color: var(--muted); font-variant-numeric: tabular-nums; }

.user-create-form { display: flex; flex-direction: column; gap: 10px; }
.two-mini { display: grid; grid-template-columns: 1fr; gap: 8px; }
.security-badges { display: flex; flex-wrap: wrap; gap: 8px; }

/* Embedded Admin Apps Gateway */
.apps-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.apps-switcher { display: flex; flex-wrap: wrap; gap: 6px; background: var(--surface-alt); padding: 4px; border-radius: 14px; }
.admin-app-frame { width: 100%; height: 74dvh; min-height: 520px; border: 1px solid var(--hairline); border-radius: 16px; background: #0B0C0E; }

/* Smart Installer */
.install-hero { align-items: center; text-align: center; padding: 36px 24px; }
.install-action-area { display: flex; flex-direction: column; align-items: center; gap: 14px; width: 100%; max-width: 460px; margin-top: 6px; }
.install-steps-box { background: var(--surface-alt); border-radius: 18px; padding: 16px; text-align: left; width: 100%; font-size: 0.88rem; line-height: 1.55; }

/* Modals & Inputs */
.segmented { display: grid; grid-template-columns: repeat(2, 1fr); gap: 6px; background: var(--surface-alt); padding: 5px; border-radius: 16px; }
.seg-btn { border: none; background: transparent; border-radius: 12px; padding: 9px 12px; font-weight: 600; font-size: 0.84rem; color: var(--muted); cursor: pointer; transition: background-color 0.15s, color 0.15s; }
.seg-btn.active { background: var(--surface-solid); color: var(--text); box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08); }
.attach-tile { background: var(--surface-alt); border: 1.5px solid transparent; border-radius: 18px; padding: 14px; display: flex; flex-direction: column; gap: 11px; }
.attach-tile.drag-over { border-color: var(--accent); }
.attach-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; }

.modal-backdrop { position: fixed; inset: 0; z-index: 45; background: rgba(11, 12, 14, 0.58); backdrop-filter: blur(6px); display: grid; place-items: center; padding: 16px; }
.modal { width: 100%; max-width: 470px; border-radius: 28px; padding: 24px; display: flex; flex-direction: column; gap: 14px; max-height: 92dvh; overflow-y: auto; }
.player-modal { max-width: 820px; }
.cinema-video { width: 100%; border-radius: 16px; background: #000000; max-height: 62dvh; }
.episode-picker { display: flex; flex-wrap: wrap; gap: 8px; max-height: 150px; overflow-y: auto; }
.modal-head { display: flex; align-items: center; justify-content: space-between; }
.modal-head h3 { margin: 0; font-size: 1.12rem; font-weight: 700; }
.modal-foot { display: flex; gap: 10px; justify-content: flex-end; }
.check-row { display: flex; align-items: center; gap: 9px; font-size: 0.88rem; cursor: pointer; }

.toast { position: fixed; top: 70px; right: 18px; z-index: 60; background: var(--cta-bg); color: var(--cta-text); border-radius: 999px; padding: 10px 16px; font-size: 0.86rem; font-weight: 600; box-shadow: 0 12px 28px rgba(0, 0, 0, 0.25); }
.toast.err { background: var(--danger); color: #FFFFFF; }
.empty { text-align: center; color: var(--muted); padding: 24px 10px; font-size: 0.88rem; }

.bottom-dock {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 30;
  background: var(--dock-bg);
  backdrop-filter: blur(18px);
  border-top: 1px solid var(--hairline);
  display: flex;
  justify-content: space-around;
  padding-bottom: env(safe-area-inset-bottom);
}
.dock-btn { background: none; border: none; padding: 9px 4px; display: flex; flex-direction: column; align-items: center; gap: 2px; font-size: 0.7rem; font-weight: 500; color: var(--muted); cursor: pointer; }
.dock-btn.active { color: var(--text); font-weight: 700; }

.desktop-only { display: none; }
@media (min-width: 960px) {
  .workspace { padding-bottom: 28px; }
  .two-col { grid-template-columns: 1.04fr 0.96fr; align-items: start; }
  .two-mini { grid-template-columns: 1fr 1fr; }
  .bottom-dock { display: none; }
  .desktop-only { display: inline-flex; }
}

/* ============================================================================
   Cat Easter Egg Stage (purely visual overlay)
   ============================================================================ */
.cat-stage { position: fixed; inset: 0; z-index: 90; pointer-events: none; overflow: hidden; }
.cat-anchor { position: fixed; width: 0; height: 0; pointer-events: none; }
.cat-body-mask { position: absolute; left: -68px; bottom: 0; width: 136px; height: 130px; overflow: hidden; pointer-events: none; }
.cat-actor { position: absolute; left: 0; bottom: 0; width: 136px; height: 120px; pointer-events: auto; cursor: pointer; user-select: none; transform-origin: center bottom; will-change: transform; filter: drop-shadow(0 10px 18px rgba(0, 0, 0, 0.35)); }
.cat-paws-overhang { position: absolute; left: -68px; top: -16px; width: 136px; height: 36px; pointer-events: none; will-change: transform, opacity; filter: drop-shadow(0 5px 8px rgba(0, 0, 0, 0.3)); }
.cat-reaction { position: fixed; z-index: 95; pointer-events: none; background: var(--cta-bg); color: var(--cta-text); padding: 5px 12px; border-radius: 999px; font-size: 0.8rem; font-weight: 700; box-shadow: 0 10px 24px rgba(0, 0, 0, 0.28); animation: reactionFloat 1.2s var(--spring) forwards; }
@keyframes reactionFloat {
  0% { opacity: 0; transform: translate(-50%, 8px) scale(0.76); }
  22% { opacity: 1; transform: translate(-50%, -6px) scale(1.03); }
  80% { opacity: 1; transform: translate(-50%, -18px) scale(1); }
  100% { opacity: 0; transform: translate(-50%, -30px) scale(0.94); }
}
.cat-shadow-backdrop { position: fixed; inset: 0; background: radial-gradient(circle at 50% 50%, rgba(245, 158, 11, 0.08), rgba(0, 0, 0, 0.45)); opacity: 0; transition: opacity 0.45s ease; }
.cat-shadow-backdrop.on { opacity: 1; }
.cat-silhouette { position: fixed; left: 50%; top: 50%; width: 190px; height: 190px; transform: translate(-50%, -44%) scale(0.88); opacity: 0; filter: blur(5px); pointer-events: none; transition: opacity 0.35s ease, transform 0.55s var(--spring); }
.cat-silhouette.on { opacity: 0.65; transform: translate(-50%, -50%) scale(1); }
.scratch-svg { position: fixed; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.scratch-path { fill: none; stroke: #f59e0b; stroke-linecap: round; filter: drop-shadow(0 0 10px rgba(245, 158, 11, 0.9)); stroke-dasharray: 520; stroke-dashoffset: 520; animation: slashDraw 0.22s cubic-bezier(0.2, 0.9, 0.3, 1) forwards; }
@keyframes slashDraw { to { stroke-dashoffset: 0; } }
.cat-spark { position: fixed; width: 5px; height: 5px; border-radius: 999px; background: #fbbf24; box-shadow: 0 0 10px #f59e0b; pointer-events: none; animation: sparkFly 0.55s ease-out forwards; }
@keyframes sparkFly {
  0% { opacity: 1; transform: translate(0, 0) scale(1); }
  100% { opacity: 0; transform: translate(var(--sx, 20px), var(--sy, 20px)) scale(0.2); }
}
.rift-hole { position: fixed; left: 50%; top: 50%; width: 270px; height: 225px; transform: translate(-50%, -50%) scale(0.12); opacity: 0; transition: transform 0.45s var(--spring), opacity 0.35s ease; pointer-events: none; }
.rift-hole.open { transform: translate(-50%, -50%) scale(1); opacity: 1; }
.tremor { animation: pageTremor 0.2s ease-in-out; }
@keyframes pageTremor {
  0%, 100% { transform: translate(0, 0); }
  25% { transform: translate(-3px, 2px); }
  50% { transform: translate(3px, -2px); }
  75% { transform: translate(-2px, -1px); }
}
