/* ==========================================================================
   SAVEPOINT — RAYCAST WORKSPACE + @SPELL UI COMPONENTS
   ========================================================================== */

:root {
  /* Raycast Official Palette */
  --color-void-black: #040506;
  --color-ink: #07080a;
  --color-obsidian: #111214;
  --color-graphite: #1b1c1e;
  --color-slate: #2f3031;
  --color-border: #363739;
  --color-iron: #454647;
  --color-smoke: #6a6b6c;
  --color-ash: #9c9c9d;
  --color-mist: #e6e6e6;
  --color-pure-white: #ffffff;
  --color-coral-pulse: #ff6363;
  --color-ember-hush: #452324;

  /* Typography */
  --font-inter: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;

  /* Radii */
  --radius-badge: 5px;
  --radius-control: 8px;
  --radius-window: 12px;
  --radius-card: 16px;

  /* Raycast Elevation & Key Shadows */
  --shadow-key:
    rgba(255, 255, 255, 0.05) 0px 1px 0px 0px inset,
    rgba(255, 255, 255, 0.14) 0px 0px 0px 1px,
    rgba(0, 0, 0, 0.25) 0px -1px 0px 0px inset;

  --shadow-window:
    rgba(255, 255, 255, 0.08) 0px 1px 0px 0px inset,
    rgba(255, 255, 255, 0.12) 0px 0px 0px 1px,
    rgba(0, 0, 0, 0.65) 0px 28px 60px -12px;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

body {
  position: relative;
  font-family: var(--font-inter);
  font-feature-settings: "calt", "kern", "liga", "ss03";
  background-color: var(--color-void-black);
  color: var(--color-pure-white);
  min-height: 100vh;
  line-height: 1.4;
  padding-bottom: 48px;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ==========================================================================
   @CULT-UI/BG-ANIMATED-GRADIENT + @CULT-UI/TEXTURE-OVERLAY
   Ambient Halo gradient orbs, horizon rim glow, dot-matrix texture, and vignette
   ========================================================================== */
.cult-site-bg {
  pointer-events: none;
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  background-color: var(--color-void-black);
}

.cult-bg-halo-layer {
  position: absolute;
  inset: 0;
  opacity: 0.62;
}

.cult-bg-orb {
  position: absolute;
  border-radius: 9999px;
  filter: blur(115px) saturate(150%);
  will-change: transform, left, top;
}

.cult-bg-orb-primary {
  width: 54vw;
  max-width: 720px;
  height: 340px;
  top: -110px;
  left: -5%;
  opacity: 0.34;
  background: linear-gradient(90deg, #ff0080, #7928ca, #00d4ff, #0070f3);
  animation: cultBgPrimaryDrift 14s ease-in-out infinite;
}

.cult-bg-orb-secondary {
  width: 44vw;
  max-width: 580px;
  height: 300px;
  top: 28%;
  left: 60%;
  opacity: 0.24;
  background: linear-gradient(90deg, #ff4d4d, #f9cb28, #ff0080);
  animation: cultBgSecondaryDrift 12s ease-in-out infinite;
}

.cult-bg-orb-tertiary {
  width: 48vw;
  max-width: 640px;
  height: 320px;
  bottom: -90px;
  left: 20%;
  opacity: 0.32;
  background: linear-gradient(90deg, #0070f3, #00d4ff, #7928ca);
  animation: cultBgTertiaryDrift 10s ease-in-out infinite;
}

.cult-bg-horizon-glow {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 320px;
  opacity: 0.55;
  filter: blur(48px);
}

.cult-bg-horizon-glow .cult-blob-primary {
  height: 110px;
  width: 48%;
  filter: blur(60px);
}

.cult-bg-horizon-glow .cult-blob-secondary {
  height: 90px;
  width: 38%;
  filter: blur(50px);
}

.cult-bg-horizon-glow .cult-blob-tertiary {
  height: 85px;
  width: 34%;
  filter: blur(50px);
}

@keyframes cultBgPrimaryDrift {
  0%, 100% {
    transform: translate3d(0%, 0px, 0) scale(1);
  }
  50% {
    transform: translate3d(38%, 35px, 0) scale(1.08);
  }
}

@keyframes cultBgSecondaryDrift {
  0%, 100% {
    transform: translate3d(0%, 0px, 0) scale(1);
  }
  50% {
    transform: translate3d(-45%, -30px, 0) scale(1.06);
  }
}

@keyframes cultBgTertiaryDrift {
  0%, 100% {
    transform: translate3d(0%, 0px, 0) scale(1);
  }
  50% {
    transform: translate3d(28%, -25px, 0) scale(1.07);
  }
}

/* @cult-ui/texture-overlay (dots + subtle micro-grid) */
.cult-bg-texture-dots {
  position: absolute;
  inset: 0;
  opacity: 0.35;
  background-image:
    radial-gradient(circle at 1px 1px, rgba(255, 255, 255, 0.14) 1px, transparent 0);
  background-size: 16px 16px;
}

.cult-bg-vignette {
  position: absolute;
  inset: 0;
  background: radial-gradient(
    ellipse 85% 75% at 50% 45%,
    transparent 20%,
    rgba(4, 5, 6, 0.72) 78%,
    rgba(4, 5, 6, 0.94) 100%
  );
}

/* ==========================================================================
   @SPELL/BADGE COMPONENT
   ========================================================================== */
.spell-badge {
  border-radius: 4px;
  font-family: var(--font-mono);
  font-weight: 500;
  font-size: 11px;
  line-height: 1;
  padding: 4px 6px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  white-space: nowrap;
}

.spell-badge-default {
  background: #262629;
  color: #e4e4e7;
}

.spell-badge-outline {
  border: 1px solid var(--color-slate);
  background: var(--color-obsidian);
  color: var(--color-ash);
}

.spell-badge-rose {
  background: rgba(136, 19, 55, 0.32);
  color: #fb7185;
  border: 1px solid rgba(251, 113, 133, 0.2);
}

.spell-badge-emerald {
  background: rgba(6, 78, 59, 0.35);
  color: #34d399;
  border: 1px solid rgba(52, 211, 153, 0.2);
}

/* ==========================================================================
   @SPELL/KBD COMPONENT (3D Physical Keycap + Active Depression)
   ========================================================================== */
.spell-kbd {
  box-sizing: border-box;
  vertical-align: text-top;
  white-space: nowrap;
  user-select: none;
  cursor: pointer;
  letter-spacing: -0.01em;
  border-radius: 0.35em;
  min-width: 1.75em;
  flex-shrink: 0;
  justify-content: center;
  align-items: center;
  padding: 0.05em 0.5em 0.1em;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 400;
  line-height: 1.65em;
  display: inline-flex;
  gap: 2px;
  position: relative;
  background: var(--color-obsidian);
  color: var(--color-ash);
  transition: all 100ms ease;
  box-shadow:
    inset 0 -0.05em 0.5em rgba(255, 255, 255, 0.034),
    inset 0 0.05em rgba(255, 255, 255, 0.12),
    inset 0 0.25em 0.5em rgba(255, 255, 255, 0.034),
    inset 0 -0.05em rgba(255, 255, 255, 0.172),
    0 0 0 0.05em rgba(255, 255, 255, 0.134),
    0 0.08em 0.17em rgba(0, 0, 0, 0.55);
}

.spell-kbd:hover {
  color: var(--color-pure-white);
}

.spell-kbd.is-pressed,
.spell-kbd:active {
  transform: translateY(1px);
  color: var(--color-pure-white);
  box-shadow:
    inset 0 0.05em 0.2em rgba(0, 0, 0, 0.4),
    0 0 0 0.05em rgba(255, 255, 255, 0.18);
}

.command-kbd-hint {
  pointer-events: none;
  opacity: 0.65;
}

/* ==========================================================================
   @CULT-UI/HALO-BUTTON COMPONENT
   Pill button with animated multi-blob gradient rim glow, frosted glass
   surface, staggered character reveal, and trailing circular loading slot.
   ========================================================================== */
.cult-halo-shell {
  position: relative;
  display: inline-flex;
  border-radius: 9999px;
  padding: 1px;
  flex-shrink: 0;
}

.cult-halo-shell.btn-export-main {
  grid-column: 1 / -1;
  width: 100%;
  display: flex;
}

.cult-halo-rim {
  pointer-events: none;
  position: absolute;
  inset: 0;
  overflow: hidden;
  border-radius: 9999px;
}

.cult-halo-glow {
  pointer-events: none;
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 55%;
  overflow: hidden;
  border-bottom-left-radius: 9999px;
  border-bottom-right-radius: 9999px;
  opacity: 0.72;
  transition: opacity 300ms ease;
}

.cult-halo-shell:hover .cult-halo-glow,
.cult-halo-shell:focus-within .cult-halo-glow {
  opacity: 0.95;
}

.cult-blob {
  pointer-events: none;
  position: absolute;
  bottom: -4px;
  transform: translateY(50%);
  border-radius: 9999px;
}

.cult-blob-primary {
  height: 22px;
  width: 44%;
  filter: blur(18px);
  background: linear-gradient(90deg, #ff0080, #7928ca, #00d4ff, #0070f3);
  animation: cultBlobPrimary 6s ease-in-out infinite;
}

.cult-blob-secondary {
  height: 18px;
  width: 36%;
  filter: blur(14px);
  background: linear-gradient(90deg, #ff4d4d, #f9cb28, #ff0080);
  animation: cultBlobSecondary 5s ease-in-out infinite;
}

.cult-blob-tertiary {
  height: 18px;
  width: 32%;
  filter: blur(14px);
  background: linear-gradient(90deg, #0070f3, #00d4ff, #7928ca);
  animation: cultBlobTertiary 4s ease-in-out infinite;
}

@keyframes cultBlobPrimary {
  0%, 100% { left: -5%; }
  50% { left: 75%; }
}

@keyframes cultBlobSecondary {
  0%, 100% { left: 65%; }
  50% { left: 10%; }
}

@keyframes cultBlobTertiary {
  0%, 100% { left: 25%; }
  50% { left: 55%; }
}

.cult-halo-btn {
  position: relative;
  z-index: 10;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  white-space: nowrap;
  font-family: var(--font-inter);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: -0.01em;
  height: 38px;
  padding: 0 18px;
  border-radius: 9999px;
  color: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: linear-gradient(135deg, rgba(20, 21, 26, 0.85), rgba(11, 12, 16, 0.72));
  backdrop-filter: blur(24px) saturate(150%);
  -webkit-backdrop-filter: blur(24px) saturate(150%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 1px 2px rgba(0, 0, 0, 0.35),
    0 4px 20px rgba(0, 0, 0, 0.35);
  transition:
    transform 180ms cubic-bezier(0.22, 1, 0.36, 1),
    border-color 200ms ease,
    background 200ms ease,
    color 200ms ease;
  user-select: none;
}

.cult-halo-btn.btn-export-main {
  width: 100%;
  height: 40px;
}

.cult-halo-btn-sm {
  height: 32px;
  padding: 0 14px;
  font-size: 12.5px;
}

.cult-halo-btn:hover {
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.24);
  background: linear-gradient(135deg, rgba(26, 28, 35, 0.9), rgba(15, 16, 22, 0.8));
}

.cult-halo-btn:active {
  transform: scale(0.96);
}

.cult-halo-btn:disabled {
  pointer-events: none;
  opacity: 0.78;
}

.cult-halo-label {
  display: inline-flex;
  align-items: center;
  white-space: pre;
}

.cult-stagger-char {
  display: inline-block;
  animation: cultCharIn 240ms cubic-bezier(0.22, 1, 0.36, 1) backwards;
}

@keyframes cultCharIn {
  from {
    opacity: 0;
    transform: translateY(3px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.cult-trailing-slot {
  display: inline-flex;
  width: 22px;
  height: 22px;
  align-items: center;
  justify-content: center;
  border-radius: 9999px;
  background: rgba(255, 255, 255, 0.06);
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.12),
    0 1px 2px rgba(0, 0, 0, 0.25);
  margin-left: 2px;
  margin-right: -4px;
  animation: cultSlotIn 220ms cubic-bezier(0.22, 1, 0.36, 1);
}

@keyframes cultSlotIn {
  from {
    opacity: 0;
    transform: scale(0.8);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.cult-trailing-spinner {
  width: 14px;
  height: 14px;
  color: rgba(255, 255, 255, 0.85);
  animation: cultSpin 0.95s linear infinite;
}

@keyframes cultSpin {
  to {
    transform: rotate(360deg);
  }
}

/* ==========================================================================
   @CULT-UI/HALO-BADGE COMPONENT
   Concentric pill ring, animated gradient rim blobs, frosted inner pill,
   live pulsing dot, and tabular-nums support.
   ========================================================================== */
.cult-halo-badge {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 9999px;
  padding: 1px;
  line-height: 1;
  user-select: none;
  flex-shrink: 0;
}

.cult-badge-rim {
  pointer-events: none;
  position: absolute;
  inset: 0;
  overflow: hidden;
  border-radius: 9999px;
}

.cult-badge-glow {
  pointer-events: none;
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 55%;
  opacity: 0.72;
  transition: opacity 250ms ease;
}

.cult-halo-badge:hover .cult-badge-glow {
  opacity: 0.94;
}

.cult-badge-surface {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  height: 22px;
  padding: 0 9px;
  border-radius: 9999px;
  font-family: var(--font-mono);
  font-size: 10.5px;
  font-weight: 500;
  letter-spacing: -0.01em;
  color: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: linear-gradient(180deg, rgba(20, 21, 26, 0.85) 0%, rgba(12, 13, 17, 0.74) 100%);
  backdrop-filter: blur(20px) saturate(150%);
  -webkit-backdrop-filter: blur(20px) saturate(150%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.06),
    0 1px 2px rgba(0, 0, 0, 0.28),
    0 4px 14px rgba(0, 0, 0, 0.32);
  transition: border-color 200ms ease, transform 180ms ease;
}

.cult-tabular-nums {
  font-variant-numeric: tabular-nums;
}

.cult-badge-live-dot {
  width: 6px;
  height: 6px;
  border-radius: 9999px;
  background: #34d399;
  box-shadow: 0 0 8px rgba(52, 211, 153, 0.65);
  flex-shrink: 0;
  animation: cultLivePulse 1.4s ease-in-out infinite;
}

@keyframes cultLivePulse {
  0%, 100% { opacity: 0.35; }
  50% { opacity: 1; }
}

/* ==========================================================================
   @CULT-UI/HALO-SEGMENTED COMPONENT
   Frosted track, bottom gradient rim, and spring sliding thumb.
   ========================================================================== */
.cult-segmented-shell {
  position: relative;
  display: inline-flex;
  max-width: 100%;
  border-radius: 9999px;
  padding: 1px;
}

.cult-segmented-full {
  display: flex;
  width: 100%;
}

.cult-segmented-surface {
  position: relative;
  z-index: 1;
  width: 100%;
  border-radius: 9999px;
  border: 1px solid rgba(255, 255, 255, 0.13);
  background: linear-gradient(180deg, rgba(18, 19, 24, 0.84) 0%, rgba(10, 11, 15, 0.72) 100%);
  backdrop-filter: blur(24px) saturate(150%);
  -webkit-backdrop-filter: blur(24px) saturate(150%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.06),
    0 1px 2px rgba(0, 0, 0, 0.35),
    0 4px 20px rgba(0, 0, 0, 0.35);
}

.cult-segmented-track {
  position: relative;
  display: flex;
  align-items: center;
  padding: 3px;
  gap: 2px;
  background: transparent !important;
  border: none !important;
  border-radius: 9999px !important;
}

.cult-segmented-thumb {
  pointer-events: none;
  position: absolute;
  top: 3px;
  bottom: 3px;
  left: 0;
  width: 0;
  border-radius: 9999px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: linear-gradient(180deg, rgba(38, 40, 48, 0.95) 0%, rgba(22, 24, 30, 0.82) 100%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.1),
    0 4px 12px rgba(0, 0, 0, 0.38);
  transition:
    transform 340ms cubic-bezier(0.22, 1.12, 0.36, 1),
    width 340ms cubic-bezier(0.22, 1.12, 0.36, 1);
  z-index: 0;
}

.cult-segmented-item {
  position: relative;
  z-index: 1;
  flex: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 30px;
  padding: 0 14px !important;
  border-radius: 9999px !important;
  border: none !important;
  background: transparent !important;
  box-shadow: none !important;
  font-family: var(--font-inter);
  font-size: 12.5px;
  font-weight: 500;
  color: var(--color-smoke);
  cursor: pointer;
  white-space: nowrap;
  transition: color 180ms ease;
}

.cult-segmented-item:hover {
  color: rgba(255, 255, 255, 0.85);
}

.cult-segmented-item.active {
  color: #ffffff !important;
}

.cult-segmented-item.active::after {
  display: none !important;
}

/* ==========================================================================
   @CULT-UI/HALO-SEARCH COMPONENT
   Animated gradient border pill, Warp shader orb avatar, staggered
   placeholder, right-to-left blur deletion, and clear button.
   ========================================================================== */
.cult-search-shell {
  position: relative;
  flex: 1;
  min-width: 0;
  border-radius: 9999px;
  padding: 1px;
}

.cult-search-shell.is-focused .cult-halo-glow {
  opacity: 0.94;
}

.cult-search-shell.is-deleting .cult-blob-primary {
  background: linear-gradient(90deg, #fb7185, #f43f5e, #f97316, #ec4899, #a855f7);
  animation-duration: 2.2s;
}

.cult-search-shell.is-deleting .cult-blob-secondary {
  background: linear-gradient(90deg, #fda4af, #fb923c, #f472b6, #fb7185);
  animation-duration: 1.9s;
}

.cult-search-surface {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 10px;
  border-radius: 9999px;
  padding: 5px 12px 5px 7px;
  border: 1px solid rgba(255, 255, 255, 0.13);
  background: linear-gradient(180deg, rgba(18, 19, 24, 0.86) 0%, rgba(11, 12, 16, 0.76) 100%);
  backdrop-filter: blur(24px) saturate(150%);
  -webkit-backdrop-filter: blur(24px) saturate(150%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.06),
    0 1px 2px rgba(0, 0, 0, 0.32),
    0 4px 18px rgba(0, 0, 0, 0.3);
  transition: border-color 200ms ease, box-shadow 200ms ease;
}

.cult-search-shell.is-focused .cult-search-surface {
  border-color: rgba(255, 255, 255, 0.26);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.1),
    0 0 0 2px rgba(255, 255, 255, 0.06),
    0 6px 22px rgba(0, 0, 0, 0.42);
}

/* AiBlobWarpAvatar Orb */
.cult-warp-orb {
  position: relative;
  width: 26px;
  height: 26px;
  border-radius: 9999px;
  overflow: hidden;
  flex-shrink: 0;
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.18),
    0 1px 3px rgba(0, 0, 0, 0.4);
}

.cult-warp-shader {
  position: absolute;
  inset: -35%;
  border-radius: 9999px;
  background:
    radial-gradient(circle at 30% 30%, #fda4af 0%, transparent 45%),
    radial-gradient(circle at 75% 25%, #00d4ff 0%, transparent 50%),
    radial-gradient(circle at 65% 75%, #fb923c 0%, transparent 50%),
    conic-gradient(from 0deg, #ff0080, #0070f3, #fb923c, #f472b6, #00d4ff, #7928ca, #ff0080);
  filter: blur(3px) saturate(140%);
  animation: cultWarpSpin 5.2s ease-in-out infinite;
}

.cult-search-shell.is-focused .cult-warp-shader {
  animation-duration: 2.6s;
}

@keyframes cultWarpSpin {
  0%, 100% {
    transform: rotate(0deg) scale(1);
  }
  50% {
    transform: rotate(160deg) scale(1.08);
  }
}

.cult-search-field-wrap {
  position: relative;
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
}

.cult-search-input {
  width: 100%;
  padding: 4px 2px !important;
  font-size: 13.5px !important;
}

.cult-search-input::placeholder {
  color: transparent !important;
}

.cult-search-shell.is-deleting .cult-search-input {
  color: transparent !important;
  caret-color: transparent !important;
}

.cult-search-placeholder,
.cult-search-delete-ghost {
  pointer-events: none;
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  padding: 0 2px;
  font-family: var(--font-inter);
  font-size: 13.5px;
  white-space: pre;
  overflow: hidden;
}

.cult-search-placeholder {
  color: var(--color-smoke);
}

.cult-search-delete-ghost {
  color: var(--color-pure-white);
}

.cult-delete-glyph {
  display: inline-block;
  animation: cultDeleteBlur 260ms ease-out forwards;
}

@keyframes cultDeleteBlur {
  from {
    opacity: 1;
    filter: blur(0px);
    transform: translateY(0);
  }
  to {
    opacity: 0.02;
    filter: blur(9px);
    transform: translateY(-1px);
  }
}

.cult-search-clear {
  width: 22px;
  height: 22px;
  border-radius: 9999px;
  border: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.07);
  color: var(--color-ash);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.12);
  cursor: pointer;
  flex-shrink: 0;
  transition: background-color 150ms ease, color 150ms ease, transform 150ms ease, opacity 150ms ease;
}

.cult-search-clear:hover {
  background: rgba(255, 255, 255, 0.14);
  color: #ffffff;
}

.cult-search-clear:active {
  transform: scale(0.9);
}

.cult-search-clear.is-hidden {
  opacity: 0;
  pointer-events: none;
  transform: scale(0.85);
}

/* ==========================================================================
   @CULT-UI/HALO-INPUT & HALO-TEXTAREA COMPONENT
   Concentric 12px/11px rounded shell, ambient radial underglow + drifting
   rim blobs, and frosted glass surface.
   ========================================================================== */
.cult-input-shell {
  position: relative;
  isolation: isolate;
  width: 100%;
  border-radius: 12px;
  padding: 1px;
}

.cult-input-rim {
  pointer-events: none;
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  border-radius: 11px;
}

.cult-input-underglow {
  position: absolute;
  inset: 0;
  opacity: 0.5;
  background:
    radial-gradient(90% 70% at 50% 100%, rgba(255, 0, 128, 0.25), rgba(121, 40, 202, 0.12) 48%, transparent 62%),
    radial-gradient(70% 55% at 30% 0%, rgba(0, 212, 255, 0.18), rgba(0, 112, 243, 0.08) 45%, transparent 58%);
  filter: blur(16px);
}

.cult-input-shell:focus-within .cult-halo-glow {
  opacity: 0.95;
}

.cult-input-surface {
  position: relative;
  z-index: 1;
  border-radius: 11px;
  border: 1px solid rgba(255, 255, 255, 0.13);
  background: linear-gradient(180deg, rgba(18, 19, 24, 0.85) 0%, rgba(11, 12, 16, 0.74) 100%);
  backdrop-filter: blur(24px) saturate(150%);
  -webkit-backdrop-filter: blur(24px) saturate(150%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.05),
    0 1px 2px rgba(0, 0, 0, 0.28),
    0 6px 20px rgba(0, 0, 0, 0.32);
  transition: border-color 200ms ease, box-shadow 200ms ease;
}

.cult-input-shell:focus-within .cult-input-surface {
  border-color: rgba(255, 255, 255, 0.28);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 0 0 2px rgba(255, 255, 255, 0.08),
    0 6px 22px rgba(0, 0, 0, 0.4);
}

.cult-halo-input,
.cult-halo-textarea {
  width: 100%;
  background: transparent !important;
  border: none !important;
  border-radius: 10px !important;
  padding: 9px 12px !important;
  color: var(--color-pure-white);
  font-family: var(--font-inter);
  font-size: 13.5px;
  outline: none;
}

/* ==========================================================================
   @CULT-UI/HALO-DROPZONE COMPONENT
   File dropzone with animated rim blobs, frosted fill, moving border trail,
   and drag-over / success states.
   ========================================================================== */
.cult-dropzone-shell {
  position: relative;
  display: flex;
  width: 100%;
  border-radius: 14px;
  padding: 1px;
  cursor: pointer;
  user-select: none;
  overflow: hidden;
}

.cult-dropzone-rim {
  pointer-events: none;
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  border-radius: 14px;
}

.cult-dropzone-trail {
  pointer-events: none;
  position: absolute;
  inset: -50%;
  z-index: 0;
  opacity: 0;
  background: conic-gradient(
    from 0deg,
    transparent 0deg,
    rgba(255, 0, 128, 0.75) 60deg,
    rgba(200, 140, 255, 0.9) 120deg,
    rgba(0, 212, 255, 0.8) 180deg,
    transparent 240deg
  );
  animation: cultTrailRotate 4.2s linear infinite;
  transition: opacity 250ms ease;
}

.cult-dropzone-shell:hover .cult-dropzone-trail,
.cult-dropzone-shell.is-dragover .cult-dropzone-trail {
  opacity: 0.9;
}

.cult-dropzone-shell.is-success .cult-blob-primary {
  background: linear-gradient(90deg, #047857, #059669, #10b981, #14b8a6);
}

.cult-dropzone-shell.is-success .cult-blob-secondary {
  background: linear-gradient(90deg, #34d399, #6ee7b7, #2dd4bf);
}

@keyframes cultTrailRotate {
  to {
    transform: rotate(360deg);
  }
}

.cult-dropzone-surface {
  position: relative;
  z-index: 1;
  width: 100%;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  border-radius: 13px;
  border: 1px dashed rgba(255, 255, 255, 0.16);
  background: linear-gradient(180deg, rgba(18, 19, 24, 0.88) 0%, rgba(11, 12, 16, 0.78) 100%);
  backdrop-filter: blur(24px) saturate(150%);
  -webkit-backdrop-filter: blur(24px) saturate(150%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.06),
    0 2px 10px rgba(0, 0, 0, 0.3);
  transition: border-color 200ms ease, background 200ms ease, transform 150ms ease;
}

.cult-dropzone-shell:hover .cult-dropzone-surface,
.cult-dropzone-shell.is-dragover .cult-dropzone-surface {
  border-color: rgba(255, 255, 255, 0.32);
  background: linear-gradient(180deg, rgba(24, 26, 33, 0.92) 0%, rgba(14, 15, 21, 0.84) 100%);
}

.cult-dropzone-shell:active .cult-dropzone-surface {
  transform: scale(0.98);
}

.cult-dropzone-icon {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.88);
  flex-shrink: 0;
}

.cult-dropzone-copy {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.cult-dropzone-title {
  font-size: 12.5px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.92);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.cult-dropzone-sub {
  font-size: 10.5px;
  color: var(--color-smoke);
}

/* ==========================================================================
   @CULT-UI/HALO-NOTIFICATION COMPONENT
   Polished notification surface with animated rim glow, frosted fill,
   staggered glyph reveal, and dismiss button.
   ========================================================================== */
.cult-notification-shell {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%) translateY(24px);
  z-index: 250;
  border-radius: 16px;
  padding: 1px;
  opacity: 0;
  pointer-events: none;
  transition:
    transform 220ms cubic-bezier(0.22, 1, 0.36, 1),
    opacity 220ms ease-out;
  max-width: calc(100vw - 32px);
}

.cult-notification-shell.visible {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
  pointer-events: auto;
}

.cult-notification-rim {
  pointer-events: none;
  position: absolute;
  inset: 0;
  overflow: hidden;
  border-radius: 16px;
}

.cult-notification-surface {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px 10px 14px;
  border-radius: 15px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: linear-gradient(180deg, rgba(20, 21, 27, 0.9) 0%, rgba(11, 12, 17, 0.82) 100%);
  backdrop-filter: blur(24px) saturate(150%);
  -webkit-backdrop-filter: blur(24px) saturate(150%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 4px 16px rgba(0, 0, 0, 0.45),
    0 12px 32px rgba(0, 0, 0, 0.55);
}

.cult-notification-body {
  display: flex;
  align-items: center;
  gap: 9px;
  min-width: 0;
}

.cult-notification-title {
  margin: 0;
  font-family: var(--font-inter);
  font-size: 13px;
  font-weight: 500;
  color: #ffffff;
  white-space: nowrap;
}

.cult-notification-dismiss {
  width: 24px;
  height: 24px;
  border-radius: 9999px;
  border: none;
  background: transparent;
  color: var(--color-smoke);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  transition: background-color 150ms ease, color 150ms ease;
}

.cult-notification-dismiss:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #ffffff;
}

/* ==========================================================================
   @SPELL/RICH-BUTTON COMPONENT
   Gradient fill, top inner highlight, subtle text-shadow, filter brightness
   ========================================================================== */
.spell-rich-btn {
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  white-space: nowrap;
  font-family: var(--font-inter);
  font-size: 13px;
  font-weight: 500;
  height: 36px;
  padding: 0 15px;
  border-radius: var(--radius-control);
  border: 1px solid rgba(9, 9, 11, 0.5);
  transition: filter 200ms ease, transform 100ms ease;
  user-select: none;
}

.spell-rich-btn-sm {
  height: 31px;
  padding: 0 12px;
  font-size: 12.5px;
}

.spell-rich-btn-default {
  background: linear-gradient(to top, rgba(244, 244, 245, 0.88), #ffffff);
  color: #18181b;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.85),
    0 2px 5px rgba(0, 0, 0, 0.35);
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.65);
}

.spell-rich-btn:hover {
  filter: brightness(1.08);
}

.spell-rich-btn:active {
  filter: brightness(0.94);
  transform: scale(0.985);
}

.spell-rich-btn:disabled {
  pointer-events: none;
  opacity: 0.55;
}

/* ==========================================================================
   @SPELL/COLOR-SELECTOR COMPONENT
   ========================================================================== */
.spell-color-selector {
  display: flex;
  align-items: center;
  gap: 10px;
}

.spell-color-swatch {
  width: 22px;
  height: 22px;
  border-radius: 9999px;
  border: none;
  cursor: pointer;
  background-color: var(--swatch-color);
  transition: transform 200ms ease, box-shadow 200ms ease;
  outline: none;
}

.spell-color-swatch:hover {
  transform: scale(1.1);
}

.spell-color-swatch:active {
  transform: scale(0.9);
}

.spell-color-swatch.active {
  box-shadow:
    inset 0 0 0 2.5px var(--color-ink),
    0 0 0 2px var(--swatch-color);
}

/* ==========================================================================
   @SPELL/ANIMATED-CHECKBOX COMPONENT
   ========================================================================== */
.spell-animated-checkbox {
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  user-select: none;
}

.spell-checkbox-box {
  width: 19px;
  height: 19px;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1.5px solid rgba(156, 156, 157, 0.4);
  background: transparent;
  color: var(--color-ink);
  transition: background-color 200ms ease, border-color 200ms ease;
  flex-shrink: 0;
}

.spell-animated-checkbox:hover .spell-checkbox-box {
  border-color: rgba(255, 255, 255, 0.65);
}

.spell-animated-checkbox input:checked + .spell-checkbox-box {
  background: var(--color-pure-white);
  border-color: transparent;
}

.spell-checkbox-svg {
  width: 100%;
  height: 100%;
  color: var(--color-ink);
}

.spell-checkbox-svg path {
  stroke-dasharray: 16;
  stroke-dashoffset: 16;
  opacity: 0;
  transition: stroke-dashoffset 280ms ease-out, opacity 100ms ease;
}

.spell-animated-checkbox input:checked + .spell-checkbox-box .spell-checkbox-svg path {
  stroke-dashoffset: 0;
  opacity: 1;
}

.spell-checkbox-text {
  display: flex;
  flex-direction: column;
}

/* ==========================================================================
   @SPELL/COPY-BUTTON COMPONENT (Dual-Icon Scale + Blur Transition)
   ========================================================================== */
.spell-copy-btn {
  position: relative;
  transition: transform 200ms ease-out, background-color 150ms ease, color 150ms ease;
}

.spell-copy-btn:active {
  transform: scale(0.97);
}

.spell-copy-icon-wrap {
  position: relative;
  width: 14px;
  height: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.spell-icon-copy,
.spell-icon-check {
  position: absolute;
  inset: 0;
  transition: transform 220ms ease-out, opacity 220ms ease-out, filter 220ms ease-out;
}

.spell-icon-copy {
  transform: scale(1);
  opacity: 1;
  filter: blur(0px);
}

.spell-icon-check {
  transform: scale(0.65);
  opacity: 0;
  filter: blur(2px);
}

.spell-copy-btn.is-copied .spell-icon-copy {
  transform: scale(0);
  opacity: 0;
  filter: blur(2px);
}

.spell-copy-btn.is-copied .spell-icon-check {
  transform: scale(1);
  opacity: 1;
  filter: blur(0px);
}

.spell-copy-btn.is-copied {
  color: var(--color-pure-white);
  border-color: rgba(89, 212, 153, 0.45);
}

/* ==========================================================================
   @SPELL/BARS-SPINNER COMPONENT (12 Rotating Radial Bars)
   ========================================================================== */
.spell-bars-wrapper {
  height: var(--spinner-size, 16px);
  width: var(--spinner-size, 16px);
  display: inline-block;
  flex-shrink: 0;
}

.spell-bars-spinner {
  position: relative;
  top: 50%;
  left: 50%;
  height: var(--spinner-size, 16px);
  width: var(--spinner-size, 16px);
}

.spell-bars-spinner .bar {
  animation: spellBarSpin 1.2s linear infinite;
  background: currentColor;
  border-radius: 6px;
  height: 8%;
  left: -10%;
  position: absolute;
  top: -3.9%;
  width: 24%;
}

.spell-bars-spinner .bar:nth-child(1)  { animation-delay: -1.2s; transform: rotate(0.0001deg) translate(146%); }
.spell-bars-spinner .bar:nth-child(2)  { animation-delay: -1.1s; transform: rotate(30deg) translate(146%); }
.spell-bars-spinner .bar:nth-child(3)  { animation-delay: -1.0s; transform: rotate(60deg) translate(146%); }
.spell-bars-spinner .bar:nth-child(4)  { animation-delay: -0.9s; transform: rotate(90deg) translate(146%); }
.spell-bars-spinner .bar:nth-child(5)  { animation-delay: -0.8s; transform: rotate(120deg) translate(146%); }
.spell-bars-spinner .bar:nth-child(6)  { animation-delay: -0.7s; transform: rotate(150deg) translate(146%); }
.spell-bars-spinner .bar:nth-child(7)  { animation-delay: -0.6s; transform: rotate(180deg) translate(146%); }
.spell-bars-spinner .bar:nth-child(8)  { animation-delay: -0.5s; transform: rotate(210deg) translate(146%); }
.spell-bars-spinner .bar:nth-child(9)  { animation-delay: -0.4s; transform: rotate(240deg) translate(146%); }
.spell-bars-spinner .bar:nth-child(10) { animation-delay: -0.3s; transform: rotate(270deg) translate(146%); }
.spell-bars-spinner .bar:nth-child(11) { animation-delay: -0.2s; transform: rotate(300deg) translate(146%); }
.spell-bars-spinner .bar:nth-child(12) { animation-delay: -0.1s; transform: rotate(330deg) translate(146%); }

@keyframes spellBarSpin {
  0% { opacity: 1; }
  100% { opacity: 0.15; }
}

/* ==========================================================================
   @SPELL/TILT-CARD COMPONENT (3D Perspective + Spotlight Overlay)
   ========================================================================== */
.spell-tilt-card {
  will-change: transform;
  position: relative;
  overflow: hidden;
  transition: transform 0.2s ease-out;
  transform-style: preserve-3d;
}

.spell-tilt-spotlight {
  pointer-events: none;
  position: absolute;
  inset: 0;
  z-index: 10;
  opacity: 0;
  transition: opacity 0.3s ease;
  background: radial-gradient(
    circle at var(--spot-x, 50%) var(--spot-y, 50%),
    rgba(255, 255, 255, 0.14) 0%,
    transparent 45%
  );
}

.spell-tilt-card:hover .spell-tilt-spotlight {
  opacity: 1;
}

/* ==========================================================================
   1. FLOATING GLASS NAVIGATION BAR (@CULT-UI/HALO-CARD RIM)
   ========================================================================== */
.nav-shell {
  max-width: 1060px;
  margin: 16px auto 16px;
  padding: 0 20px;
  position: sticky;
  top: 12px;
  z-index: 100;
}

.cult-window-halo-shell {
  position: relative;
  border-radius: 16px;
  padding: 1px;
}

.cult-nav-halo-shell {
  border-radius: 14px;
}

.cult-window-rim {
  pointer-events: none;
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  border-radius: inherit;
}

.cult-window-glow {
  pointer-events: none;
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 58%;
  opacity: 0.72;
  transition: opacity 300ms ease;
}

.cult-window-halo-shell:hover .cult-window-glow,
.cult-window-halo-shell:focus-within .cult-window-glow {
  opacity: 0.92;
}

.cult-window-glow .cult-blob-primary {
  height: 90px;
  width: 46%;
  bottom: -24px;
  filter: blur(36px);
}

.cult-window-glow .cult-blob-secondary {
  height: 70px;
  width: 36%;
  bottom: -18px;
  filter: blur(30px);
}

.cult-window-glow .cult-blob-tertiary {
  height: 60px;
  width: 32%;
  bottom: -14px;
  filter: blur(26px);
}

.navbar {
  position: relative;
  z-index: 1;
  backdrop-filter: blur(36px) saturate(150%);
  -webkit-backdrop-filter: blur(36px) saturate(150%);
  background: linear-gradient(180deg, rgba(12, 13, 18, 0.84) 0%, rgba(7, 8, 12, 0.76) 100%);
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 13px;
  padding: 8px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.07),
    0 4px 20px rgba(0, 0, 0, 0.45);
}

.nav-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--color-pure-white);
  padding: 2px 4px 2px 2px;
  border-radius: 10px;
  transition: transform 0.2s cubic-bezier(0.22, 1, 0.36, 1);
}

.nav-brand:hover {
  transform: translateY(-0.5px);
}

.nav-brand-mark {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 34px;
  flex-shrink: 0;
}

.nav-brand-crystal {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  filter:
    drop-shadow(-2px 0 6px rgba(217, 70, 239, 0.35))
    drop-shadow(2px 0 6px rgba(56, 189, 248, 0.35))
    drop-shadow(0 2px 8px rgba(255, 87, 87, 0.32));
  transition: transform 0.25s cubic-bezier(0.22, 1, 0.36, 1), filter 0.25s ease;
}

.nav-brand:hover .nav-brand-crystal {
  transform: scale(1.07);
  filter:
    drop-shadow(-3px 0 9px rgba(217, 70, 239, 0.55))
    drop-shadow(3px 0 9px rgba(56, 189, 248, 0.55))
    drop-shadow(0 3px 10px rgba(255, 87, 87, 0.48));
}

.brand-title {
  display: inline-flex;
  align-items: baseline;
  font-family: var(--font-inter);
  font-size: 16.5px;
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1;
}

.brand-save {
  color: #ffffff;
}

.brand-point {
  color: #ff5757;
  text-shadow: 0 0 18px rgba(255, 87, 87, 0.28);
}

.nav-modes {
  display: flex;
  align-items: center;
  gap: 20px;
}

.nav-mode-link {
  background: transparent;
  border: none;
  font-family: var(--font-inter);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.008em;
  color: var(--color-ash);
  cursor: pointer;
  padding: 4px 0;
  transition: color 0.15s ease;
  position: relative;
}

.nav-mode-link:hover {
  color: var(--color-pure-white);
}

.nav-mode-link.active {
  color: var(--color-pure-white);
}

.nav-mode-link.active::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -9px;
  height: 1px;
  background: var(--color-pure-white);
}

.nav-meta {
  display: flex;
  align-items: center;
  gap: 10px;
}

.ip-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #34d399;
}

/* ==========================================================================
   2. APP WINDOW MOCKUP CHROME (@CULT-UI/HALO-CARD SURFACE)
   ========================================================================== */
.workspace-shell {
  position: relative;
  z-index: 1;
  max-width: 1060px;
  margin: 0 auto;
  padding: 0 20px;
}

.app-window {
  position: relative;
  z-index: 1;
  background: linear-gradient(180deg, rgba(11, 12, 16, 0.86) 0%, rgba(7, 8, 11, 0.8) 100%);
  backdrop-filter: blur(32px) saturate(150%);
  -webkit-backdrop-filter: blur(32px) saturate(150%);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 15px;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.07),
    0 24px 60px -12px rgba(0, 0, 0, 0.72);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

/* ==========================================================================
   3. WINDOW TOP COMMAND BAR
   ========================================================================== */
.window-command-bar {
  background: rgba(7, 8, 11, 0.55);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  padding: 12px 16px;
}

.command-bar-inner {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
}

.command-icon {
  color: var(--color-smoke);
  flex-shrink: 0;
  margin-left: 4px;
}

.command-input {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  font-family: var(--font-inter);
  font-size: 15px;
  font-weight: 400;
  color: var(--color-pure-white);
  padding: 6px 4px;
  min-width: 0;
}

.command-input::placeholder {
  color: var(--color-smoke);
}

.command-bar-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.command-select {
  background: var(--color-obsidian);
  border: 1px solid var(--color-slate);
  border-radius: var(--radius-control);
  color: var(--color-ash);
  font-family: var(--font-inter);
  font-size: 13px;
  font-weight: 500;
  height: 36px;
  padding: 0 10px;
  outline: none;
  cursor: pointer;
  transition: border-color 0.15s ease, color 0.15s ease;
}

.command-select:hover,
.command-select:focus {
  border-color: var(--color-border);
  color: var(--color-pure-white);
}

/* ==========================================================================
   4. KEY BUTTONS
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  font-family: var(--font-inter);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.008em;
  border-radius: var(--radius-control);
  height: 36px;
  padding: 0 14px;
  cursor: pointer;
  border: none;
  white-space: nowrap;
  transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.btn-key {
  background: var(--color-obsidian);
  color: var(--color-ash);
  border: 1px solid var(--color-slate);
  box-shadow: rgba(255, 255, 255, 0.05) 0px 1px 0px 0px inset;
}

.btn-key:hover {
  background: var(--color-graphite);
  color: var(--color-pure-white);
  border-color: var(--color-border);
}

/* ==========================================================================
   5. TWO-PANE WORKSPACE BODY (Inspector Left + Canvas Stage Right)
   ========================================================================== */
.window-body {
  display: grid;
  grid-template-columns: 1fr;
}

@media (min-width: 860px) {
  .window-body {
    grid-template-columns: 1fr 400px;
    align-items: stretch;
  }
}

.inspector-pane {
  display: flex;
  flex-direction: column;
  border-bottom: 1px solid #1b1c1e;
}

@media (min-width: 860px) {
  .inspector-pane {
    border-bottom: none;
    border-right: 1px solid #1b1c1e;
  }
}

.inspector-section {
  padding: 20px 24px;
  border-bottom: 1px solid #141518;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.inspector-section:last-child {
  border-bottom: none;
}

.section-eyebrow {
  font-family: var(--font-mono);
  font-size: 10.5px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.075em;
  color: var(--color-smoke);
}

.property-row {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.property-row-inline {
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
}

.property-label {
  font-size: 13px;
  font-weight: 500;
  color: var(--color-ash);
}

.property-label-main {
  font-size: 13.5px;
  font-weight: 500;
  color: var(--color-pure-white);
}

.property-label-sub {
  font-size: 12px;
  color: var(--color-smoke);
  margin-top: 2px;
}

.segmented-control {
  background: var(--color-obsidian);
  border: 1px solid #1f2023;
  border-radius: var(--radius-control);
  padding: 3px;
  display: flex;
  gap: 3px;
}

.segmented-item {
  flex: 1;
  background: transparent;
  border: none;
  color: var(--color-smoke);
  padding: 6px 10px;
  font-family: var(--font-inter);
  font-size: 12.5px;
  font-weight: 500;
  border-radius: 6px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: color 0.15s ease, background-color 0.15s ease;
}

.segmented-item:hover {
  color: var(--color-ash);
}

.segmented-item.active {
  background: var(--color-graphite);
  color: var(--color-pure-white);
  box-shadow:
    rgba(255, 255, 255, 0.07) 0px 1px 0px 0px inset,
    rgba(255, 255, 255, 0.12) 0px 0px 0px 1px;
}

/* ==========================================================================
   6. FORM FIELDS, RECESSED INPUT WELLS & CUSTOM FILE TRIGGERS
   ========================================================================== */
.accordion-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  user-select: none;
}

.accordion-icon {
  color: var(--color-smoke);
  transition: transform 0.18s ease;
}

.accordion.open .accordion-icon {
  transform: rotate(180deg);
}

.accordion-content {
  display: none;
  flex-direction: column;
  gap: 14px;
}

.accordion.open .accordion-content {
  display: flex;
}

.form-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.field-label {
  font-size: 12px;
  font-weight: 500;
  color: var(--color-ash);
}

.recessed-input,
.recessed-textarea {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--color-slate);
  border-radius: var(--radius-control);
  padding: 8px 12px;
  font-family: var(--font-inter);
  font-size: 13.5px;
  font-weight: 400;
  color: var(--color-pure-white);
  outline: none;
  transition: border-color 0.15s ease, background-color 0.15s ease;
}

.recessed-input:focus,
.recessed-textarea:focus {
  border-color: var(--color-ash);
  background: rgba(255, 255, 255, 0.06);
}

.recessed-textarea {
  min-height: 72px;
  resize: vertical;
  line-height: 1.45;
}

.review-editor-box {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.file-well-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--color-obsidian);
  border: 1px solid var(--color-slate);
  border-radius: var(--radius-control);
  padding: 8px 12px;
  font-size: 12.5px;
  font-weight: 500;
  color: var(--color-ash);
  cursor: pointer;
  box-shadow: rgba(255, 255, 255, 0.04) 0px 1px 0px 0px inset;
  transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.file-well-btn:hover {
  background: var(--color-graphite);
  color: var(--color-pure-white);
  border-color: var(--color-border);
}

/* Interactive Star Rating Picker */
.stars-picker {
  display: flex;
  align-items: center;
  gap: 4px;
  height: 35px;
  font-size: 18px;
  cursor: pointer;
  user-select: none;
}

.star-pick {
  color: var(--color-slate);
  transition: color 0.12s ease, transform 0.1s ease;
}

.star-pick.active {
  color: var(--color-mist);
}

.star-pick:hover {
  transform: scale(1.1);
  color: var(--color-pure-white);
}

/* ==========================================================================
   7. BATCH EXTENSION TILES GRID
   ========================================================================== */
.batch-results-section {
  background: #050608;
}

.batch-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.batch-stats {
  display: flex;
  align-items: baseline;
  gap: 6px;
}

.batch-stat-count {
  font-size: 14px;
  font-weight: 600;
  color: var(--color-pure-white);
}

.batch-stat-sub {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--color-smoke);
}

.batch-selection-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 6px 10px;
  background: var(--color-obsidian);
  border: 1px solid #1f2023;
  border-radius: var(--radius-control);
}

.batch-selection-links {
  display: flex;
  align-items: center;
  gap: 6px;
}

.text-action-btn {
  background: none;
  border: none;
  font-family: var(--font-inter);
  font-size: 12px;
  font-weight: 500;
  color: var(--color-ash);
  cursor: pointer;
  padding: 2px 4px;
  transition: color 0.15s ease;
}

.text-action-btn:hover {
  color: var(--color-pure-white);
}

.meta-sep {
  color: var(--color-slate);
  font-size: 11px;
}

.batch-items-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  max-height: 360px;
  overflow-y: auto;
  overflow-x: hidden;
  padding-right: 4px;
  scrollbar-width: thin;
  scrollbar-color: var(--color-slate) transparent;
}

.batch-items-grid::-webkit-scrollbar {
  width: 4px;
}

.batch-items-grid::-webkit-scrollbar-thumb {
  background: var(--color-slate);
  border-radius: 4px;
}

.batch-card-thumb {
  min-width: 0;
  background: var(--color-ink);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-control);
  padding: 8px;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 6px;
  transition: border-color 0.15s ease, background-color 0.15s ease, opacity 0.15s ease;
}

.batch-card-thumb:hover {
  background: var(--color-obsidian);
  border-color: var(--color-ash);
}

.batch-card-thumb.active-preview {
  border-color: var(--color-coral-pulse);
  background: rgba(69, 35, 36, 0.25);
}

.batch-card-thumb.is-unselected {
  opacity: 0.38;
}

.batch-card-thumb.is-unselected:hover {
  opacity: 0.75;
}

.batch-thumb-poster-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 3 / 4;
  border-radius: 4px;
  overflow: hidden;
  background: var(--color-obsidian);
}

/* @spell/animated-checkbox style on batch cards */
.batch-check-indicator {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 19px;
  height: 19px;
  border-radius: 6px;
  background: rgba(4, 5, 6, 0.78);
  border: 1.5px solid rgba(255, 255, 255, 0.45);
  color: transparent;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 5;
  backdrop-filter: blur(4px);
  transition: background-color 200ms ease, border-color 200ms ease, transform 150ms ease;
}

.batch-check-indicator:hover {
  transform: scale(1.08);
  border-color: var(--color-pure-white);
}

.batch-check-indicator.checked {
  background: var(--color-pure-white);
  border-color: transparent;
  color: var(--color-ink);
}

.batch-thumb-img {
  width: 100%;
  height: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  display: block;
}

.batch-thumb-title {
  font-size: 12px;
  font-weight: 500;
  color: var(--color-pure-white);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.batch-thumb-stars {
  font-family: var(--font-mono);
  font-size: 10.5px;
  color: var(--color-smoke);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 4px;
}

/* ==========================================================================
   STEAM ACCOUNT RECOGNITION CARD & REVIEW BADGES
   ========================================================================== */
.steam-account-card {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 11px;
  background:
    radial-gradient(120% 140% at 0% 0%, rgba(86, 194, 255, 0.14) 0%, rgba(132, 125, 255, 0.06) 48%, rgba(9, 11, 16, 0.92) 100%);
  border: 1px solid rgba(86, 194, 255, 0.26);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 10px 24px -10px rgba(0, 0, 0, 0.65);
}

.steam-account-left {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  width: 100%;
}

.steam-avatar-frame {
  position: relative;
  width: 44px;
  height: 44px;
  border-radius: 10px;
  padding: 1.5px;
  background: linear-gradient(135deg, #56c2ff 0%, #847dff 55%, #ff6363 100%);
  flex-shrink: 0;
}

.steam-avatar-img {
  width: 100%;
  height: 100%;
  border-radius: 8.5px;
  object-fit: cover;
  display: block;
  background: #0b0d13;
}

.steam-online-dot {
  position: absolute;
  right: -2px;
  bottom: -2px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #56c2ff;
  border: 2px solid #080a0f;
  box-shadow: 0 0 8px rgba(86, 194, 255, 0.8);
}

.steam-account-info {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
  flex: 1;
}

.steam-account-name-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
}

.steam-account-name {
  font-size: 14px;
  font-weight: 600;
  color: var(--color-pure-white);
  letter-spacing: -0.01em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.steam-account-meta {
  display: flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--color-smoke);
  flex-wrap: wrap;
}

.steam-account-id {
  color: var(--color-ash);
}

.steam-profile-link {
  color: #56c2ff;
  text-decoration: none;
  transition: color 0.15s ease;
}

.steam-profile-link:hover {
  color: #8fd8ff;
  text-decoration: underline;
}

.steam-rec-pill {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-family: var(--font-inter);
  font-size: 10px;
  font-weight: 600;
  padding: 1px 5px;
  border-radius: 4px;
  letter-spacing: 0.01em;
}

.steam-rec-pill.is-up {
  color: #56c2ff;
  background: rgba(86, 194, 255, 0.12);
  border: 1px solid rgba(86, 194, 255, 0.25);
}

.steam-rec-pill.is-down {
  color: #ff6363;
  background: rgba(255, 99, 99, 0.12);
  border: 1px solid rgba(255, 99, 99, 0.25);
}

.steam-hours-tag {
  font-family: var(--font-mono);
  font-size: 9.5px;
  color: var(--color-smoke);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ==========================================================================
   8. RIGHT COLUMN: CANVAS STAGE
   ========================================================================== */
.stage-pane {
  background: rgba(5, 6, 8, 0.52);
  padding: 20px 24px 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.stage-header {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.06em;
  color: var(--color-smoke);
}

.story-frame {
  width: 100%;
  max-width: 310px;
  aspect-ratio: 9 / 16;
  border-radius: var(--radius-card);
  overflow: hidden;
  background: var(--color-ink);
  box-shadow: var(--shadow-key), 0 20px 40px rgba(0, 0, 0, 0.6);
}

#storyCanvas {
  width: 100%;
  height: 100%;
  display: block;
}

.stage-actions {
  width: 100%;
  max-width: 310px;
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr;
  gap: 8px;
}

.btn-export-main {
  width: 100%;
}

/* ==========================================================================
   9. WINDOW FOOTER META STRIP
   ========================================================================== */
.window-footer {
  background: rgba(7, 8, 11, 0.55);
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding: 10px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--color-smoke);
}

.footer-meta-left,
.footer-meta-right {
  display: flex;
  align-items: center;
  gap: 8px;
}

.window-footer .pipe {
  color: var(--color-slate);
}

/* ==========================================================================
   10. TOAST
   ========================================================================== */
.toast-msg {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%) translateY(60px);
  background: var(--color-graphite);
  border: 1px solid var(--color-border);
  color: var(--color-pure-white);
  padding: 8px 14px;
  border-radius: var(--radius-control);
  font-family: var(--font-inter);
  font-size: 12.5px;
  font-weight: 500;
  box-shadow: var(--shadow-key), 0 10px 24px rgba(0, 0, 0, 0.6);
  z-index: 200;
  transition: transform 0.2s ease, opacity 0.2s ease;
  pointer-events: none;
  opacity: 0;
}

.toast-msg.visible {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
}

/* ==========================================================================
   11. MOBILE RESPONSIVENESS & TOUCH ERGONOMICS
   ========================================================================== */
@media (max-width: 859px) {
  /* Coloca o Stage do Story primeiro no celular/tablet para feedback visual imediato */
  .window-body {
    display: flex;
    flex-direction: column;
  }

  .stage-pane {
    order: -1;
    padding: 16px 16px 18px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    gap: 12px;
  }

  .story-frame {
    max-width: 235px;
  }

  .stage-actions {
    max-width: 340px;
  }
}

@media (max-width: 768px) {
  /* Evita auto-zoom forçado do iOS Safari ao focar em campos de texto */
  .cult-search-input,
  .recessed-input,
  .recessed-textarea,
  .command-select {
    font-size: 16px !important;
  }

  /* Navbar em 2 linhas limpas: Marca + IP no topo, 3 abas ocupando 100% abaixo */
  .nav-shell {
    margin: 10px auto 12px;
    padding: 0 10px;
  }

  .navbar {
    height: auto;
    padding: 10px 12px;
    flex-wrap: wrap;
    gap: 10px;
  }

  .nav-brand {
    order: 1;
  }

  .nav-meta,
  .kbd-shortcut-hint,
  .command-kbd-hint,
  .footer-meta-right {
    display: none !important;
  }

  .navbar > .cult-segmented-shell {
    order: 3;
    width: 100%;
  }

  .navbar .cult-segmented-surface {
    width: 100%;
  }

  .navbar .cult-segmented-track {
    width: 100%;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .navbar .nav-mode-link.cult-segmented-item {
    width: 100%;
    padding: 0 6px;
    font-size: 12px;
    height: 34px;
    justify-content: center;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
}

@media (max-width: 640px) {
  body {
    padding-bottom: calc(28px + env(safe-area-inset-bottom, 0px));
  }

  .workspace-shell {
    padding: 0 10px;
  }

  /* Barra de comando empilhada e 100% clicável com o polegar */
  .window-command-bar {
    padding: 12px;
  }

  .command-bar-inner,
  .command-bar-batch {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }

  .cult-search-shell {
    width: 100%;
  }

  .cult-search-surface {
    height: 44px;
    padding: 0 10px 0 12px;
    gap: 8px;
  }

  .cult-search-placeholder {
    font-size: 12.5px;
    right: 4px;
  }

  /* Botão Importar no modo individual ocupa largura total */
  #singleModeSection > .cult-halo-shell {
    width: 100%;
  }

  #singleModeSection .cult-halo-btn {
    width: 100%;
    height: 42px;
  }

  /* Seletores e botões nos modos Perfil Backloggd e Steam Reviews */
  .command-bar-actions {
    width: 100%;
    display: grid;
    grid-template-columns: 1fr 1.35fr;
    gap: 8px;
  }

  .command-select {
    width: 100%;
    height: 42px;
    padding: 0 28px 0 12px;
  }

  .command-bar-actions > .cult-halo-shell,
  .command-bar-actions .cult-halo-btn {
    width: 100%;
    height: 42px;
  }

  /* Preview do Story compacto e botões de exportação ergonômicos */
  .stage-pane {
    padding: 14px 12px 16px;
    gap: 12px;
  }

  .stage-header {
    max-width: 100%;
    padding: 0 2px;
  }

  .story-frame {
    max-width: 216px;
  }

  .stage-actions {
    max-width: 100%;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }

  .btn-export-main {
    grid-column: span 2;
  }

  .stage-actions .cult-halo-btn,
  .stage-actions .btn-key {
    height: 42px;
    font-size: 13.5px;
  }

  /* Seções do Inspector mais enxutas no celular */
  .inspector-section {
    padding: 14px 12px;
    gap: 12px;
  }

  .property-row-inline {
    flex-wrap: wrap;
    gap: 10px;
  }

  /* Alvos de toque maiores para cores das estrelas e seletor de estrelas */
  .spell-color-selector {
    gap: 10px;
  }

  .spell-color-swatch {
    width: 26px;
    height: 26px;
  }

  .stars-picker {
    font-size: 24px;
    gap: 8px;
    height: 40px;
  }

  /* Cabeçalho de lote e grade de 3 colunas para ver mais jogos sem rolar tanto */
  .batch-header-row {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }

  .batch-header-row > .cult-halo-shell,
  .batch-header-row .cult-halo-btn {
    width: 100%;
    height: 38px;
  }

  .batch-items-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
    max-height: 290px;
  }

  .batch-card-thumb {
    padding: 6px;
    gap: 4px;
  }

  .batch-thumb-title {
    font-size: 11px;
  }

  .batch-thumb-stars {
    font-size: 10px;
  }

  .steam-account-card {
    padding: 10px 12px;
  }

  .steam-account-name-row {
    gap: 6px;
  }

  .form-grid-2 {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .window-footer {
    padding: 10px 12px;
    justify-content: center;
    text-align: center;
  }

  .footer-meta-left {
    width: 100%;
    justify-content: center;
    flex-wrap: wrap;
    font-size: 10.5px;
  }

  /* Toast Notification ajustada para telas pequenas e iOS Home Indicator */
  .cult-notification-shell {
    bottom: calc(16px + env(safe-area-inset-bottom, 0px));
    width: calc(100vw - 24px);
    max-width: 380px;
  }

  .cult-notification-surface {
    width: 100%;
    justify-content: space-between;
  }
}

@media (max-width: 380px) {
  .navbar .nav-mode-link.cult-segmented-item {
    font-size: 11px;
    padding: 0 4px;
  }

  .story-frame {
    max-width: 195px;
  }

  .command-bar-actions {
    grid-template-columns: 1fr;
  }
}

