/* MetaImage Studio Pro — Modern Dark Studio Theme (Mousy Dev Official Standard) */
:root {
  --bg-base: #000000;
  --bg-surface: #0a0a0a;
  --bg-surface-elevated: #0f0e16;
  --bg-subtle: #161424;
  --bg-hover: #1c1830;

  --border-subtle: rgba(255, 255, 255, 0.08);
  --border-active: rgba(255, 255, 255, 0.18);
  --border-focus: #8f6cc7;

  --text-primary: #f8fafc;
  --text-secondary: #cbd5e1;
  --text-muted: #94a3b8;
  --text-dim: #94a3b8;

  --primary: #55378e;
  --primary-hover: #8f6cc7;
  --primary-glow: rgba(85, 55, 142, 0.5);
  --brand: #55378e;
  --brand-light: #8f6cc7;
  --brand-lighter: #bda0e2;
  --ease-mousy: cubic-bezier(0.16, 1, 0.3, 1);

  --accent-cyan: #06b6d4;
  --accent-indigo: #6366f1;
  --danger: #ef4444;
  --warning: #f59e0b;

  --radius-sm: 6px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-full: 9999px;

  --font-ui:
    "Space Grotesk", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    sans-serif;
  --font-display: "Unbounded", "Space Grotesk", system-ui, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;

  --ease-spring: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-snap: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-press: cubic-bezier(0.34, 1.3, 0.64, 1);

  --header-height: 56px;
  --sidebar-left-width: 320px;
  --sidebar-right-width: 340px;
  --status-bar-height: 38px;
  --footer-height: 28px;

  /* Glassmorphism 2.0 System Tokens */
  --glass-bg: rgba(13, 17, 26, 0.65);
  --glass-bg-elevated: rgba(18, 24, 38, 0.72);
  --glass-bg-subtle: rgba(255, 255, 255, 0.035);
  --glass-bg-sunken: rgba(5, 7, 11, 0.6);
  --glass-border: rgba(255, 255, 255, 0.09);
  --glass-border-specular: rgba(255, 255, 255, 0.18);
  --glass-border-hover: rgba(85, 55, 142, 0.45);
  --glass-blur: blur(20px) saturate(180%);
  --glass-blur-heavy: blur(28px) saturate(190%);
  --glass-shadow:
    0 20px 45px -15px rgba(0, 0, 0, 0.75),
    inset 0 1px 0 0 rgba(255, 255, 255, 0.14);
  --glass-shadow-hover:
    0 26px 55px -12px rgba(0, 0, 0, 0.85),
    0 0 32px -5px rgba(85, 55, 142, 0.22),
    inset 0 1px 0 0 rgba(255, 255, 255, 0.28);
}

/* Accessibility Screen Reader Only Utility */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

/* Scrollbar oficial Mousy Dev */
::-webkit-scrollbar {
  width: 9px;
  height: 9px;
}
::-webkit-scrollbar-track {
  background: #000000;
}
::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, #8f6cc7, #472d75);
  border-radius: 999px;
}
::-webkit-scrollbar-thumb:hover {
  background: #bda0e2;
}
::selection {
  background: rgba(85, 55, 142, 0.65);
  color: #ffffff;
}

/* Estilo de Tipografía y Acento Oficial Portafolio MousyDev */
.text-gradient-portfolio {
  color: #bda0e2 !important;
  text-shadow: 0 0 30px rgba(189, 160, 226, 0.45) !important;
  filter: drop-shadow(0 0 25px rgba(189, 160, 226, 0.4)) !important;
  background: none !important;
  -webkit-background-clip: unset !important;
  background-clip: unset !important;
  display: inline-block;
}

.metaimage-brand-link {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}
.brand-logo-img {
  height: 38px;
  width: auto;
  max-width: 160px;
  display: block;
  object-fit: contain;
  filter: drop-shadow(0 0 12px rgba(189, 160, 226, 0.25));
  transition:
    filter 0.25s ease,
    transform 0.25s ease;
}
.metaimage-brand-link:hover .brand-logo-img {
  filter: drop-shadow(0 0 22px rgba(189, 160, 226, 0.6));
  transform: scale(1.02);
}
.brand-mousy-title {
  font-family: "Unbounded", system-ui, sans-serif;
  font-weight: 900;
  font-size: 1.12rem;
  letter-spacing: -0.02em;
  color: #ffffff;
}
.brand-studio-badge {
  font-family: "JetBrains Mono", monospace;
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  padding: 2px 8px;
  border-radius: 999px;
  background: rgba(85, 55, 142, 0.25);
  border: 1px solid rgba(189, 160, 226, 0.45);
  color: #bda0e2;
}

/* Botón Neón Oficial Portafolio (con gradiente, borde luminoso y shimmer) */
.btn-neon {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.625rem;
  padding: 0.875rem 1.85rem;
  border-radius: 1rem;
  font-family: var(--font-ui);
  font-weight: 700;
  font-size: 0.95rem;
  color: #ffffff !important;
  background: linear-gradient(180deg, #55378e 0%, #38215c 100%) !important;
  border: 1px solid rgba(143, 108, 199, 0.5) !important;
  border-top: 1px solid rgba(189, 160, 226, 0.8) !important;
  box-shadow:
    0 1px 2px rgba(0, 0, 0, 0.6),
    0 8px 25px -6px rgba(139, 92, 246, 0.5),
    inset 0 1px 0 rgba(255, 255, 255, 0.25) !important;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1) !important;
  cursor: pointer;
  overflow: hidden;
  user-select: none;
  text-decoration: none;
}
.btn-neon::after {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 60%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.22),
    transparent
  );
  transform: skewX(-25deg);
  transition: left 0.65s cubic-bezier(0.16, 1, 0.3, 1);
  pointer-events: none;
}
.btn-neon:hover {
  background: linear-gradient(180deg, #8f6cc7 0%, #472d75 100%) !important;
  border-color: #bda0e2 !important;
  box-shadow:
    0 1px 2px rgba(0, 0, 0, 0.6),
    0 12px 32px -4px rgba(139, 92, 246, 0.75),
    inset 0 1px 0 rgba(255, 255, 255, 0.4) !important;
  transform: translateY(-2px);
  color: #ffffff !important;
}
.btn-neon:hover::after {
  left: 160%;
}
.btn-neon:active {
  transform: scale(0.97) translateY(0) !important;
}

body {
  width: 100%;
  min-height: 100%;
  overflow-x: hidden;
  overflow-y: auto;
  background-color: var(--bg-base);
  color: var(--text-primary);
  font-family: var(--font-ui);
  font-optical-sizing: auto;
  text-rendering: optimizeLegibility;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Display hierarchy — tight tracking for large, relaxed for body */
.display-tight {
  font-family: var(--font-display);
  font-optical-sizing: auto;
  letter-spacing: -0.032em;
  line-height: 1.04;
  text-wrap: balance;
}

.body-pretty {
  text-wrap: pretty;
  line-height: 1.6;
}

/* Custom Minimal Scrollbar */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.15);
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.25);
}

/* App Root Container (100vh workbench) */
.studio-app {
  display: flex;
  flex-direction: column;
  width: 100%;
  height: 100vh;
  min-height: 100vh;
  flex-shrink: 0;
  overflow: hidden;
  position: relative;
  background:
    radial-gradient(
      620px 620px at 8% -10%,
      rgba(85, 55, 142, 0.16),
      transparent 60%
    ),
    radial-gradient(
      560px 560px at 95% 20%,
      rgba(85, 55, 142, 0.12),
      transparent 60%
    ),
    radial-gradient(
      420px 420px at 40% 110%,
      rgba(85, 55, 142, 0.14),
      transparent 60%
    ),
    #000000;
}
.studio-app::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 60;
  pointer-events: none;
  opacity: 0.035;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='1.2' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* =========================================
   TOP HEADER
========================================= */
.studio-header {
  height: var(--header-height);
  background: rgba(11, 14, 21, 0.82);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow:
    0 4px 20px rgba(0, 0, 0, 0.4),
    inset 0 -1px 0 0 rgba(255, 255, 255, 0.02);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 1.25rem;
  z-index: 50;
  user-select: none;
}

.header-left {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.app-brand {
  display: flex;
  align-items: center;
  cursor: pointer;
}

.brand-logo-img {
  height: 42px;
  width: auto;
  max-width: 180px;
  aspect-ratio: 391 / 136;
  object-fit: contain;
  display: block;
  transition:
    transform 0.2s ease,
    opacity 0.2s ease;
}

.brand-logo-img:hover {
  transform: scale(1.03);
  opacity: 0.95;
}

.workspace-pill {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(255, 255, 255, 0.04);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.1);
  padding: 4px 12px;
  border-radius: var(--radius-full);
  font-size: 0.76rem;
  color: var(--text-secondary);
  max-width: 240px;
}

.active-file-text {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-family: var(--font-mono);
}

.pulse-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--primary);
  box-shadow: 0 0 8px var(--primary);
  flex-shrink: 0;
}

.header-center {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.metric-chip {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.78rem;
  background: rgba(255, 255, 255, 0.04);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.1);
  padding: 4px 12px;
  border-radius: var(--radius-md);
}

.metric-label {
  color: var(--text-muted);
}

.metric-val {
  font-weight: 600;
  font-family: var(--font-mono);
}

.text-emerald {
  color: #34d399 !important;
}

.text-cyan {
  color: #38bdf8 !important;
}

.header-right {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.kbd-hint {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.15);
  padding: 1px 5px;
  border-radius: 4px;
  font-size: 0.65rem;
  font-family: var(--font-mono);
  color: var(--text-secondary);
  margin-left: 0.3rem;
}

/* =========================================
   BUTTONS (Shadcn Style)
========================================= */
.btn-primary,
.btn-secondary,
.btn-ghost,
.btn-accent-sm,
.btn-ghost-sm,
.btn-text-danger {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  font-family: var(--font-ui);
  font-weight: 500;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition:
    transform 100ms var(--ease-press),
    background 0.18s var(--ease-spring),
    border-color 0.18s var(--ease-spring),
    box-shadow 0.18s var(--ease-spring),
    color 0.18s ease;
  border: 1px solid transparent;
  user-select: none;
  text-decoration: none;
  will-change: transform;
}

.btn-primary:active:not(:disabled),
.btn-secondary:active:not(:disabled),
.btn-ghost:active:not(:disabled),
.mode-btn:active,
.format-btn:active,
.preset-pill:active {
  transform: scale(0.97);
  transition: transform 100ms ease-out;
}

.btn-primary:focus-visible,
.btn-secondary:focus-visible,
.btn-ghost:focus-visible,
.mode-btn:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

.btn-primary {
  background: #55378e;
  color: #ffffff;
  font-weight: 800;
  border: 1px solid rgba(143, 108, 199, 0.5);
  border-radius: 24px;
  box-shadow: 0 0 40px -10px rgba(85, 55, 142, 1);
}
.btn-primary:hover:not(:disabled) {
  background: #8f6cc7;
  color: #fff;
  border-color: #bda0e2;
  box-shadow: 0 0 50px -10px rgba(141, 108, 199, 0.9);
}
.btn-primary:disabled {
  box-shadow: none;
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.02);
  color: #e2e8f0;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  font-weight: 700;
}
.btn-secondary:hover:not(:disabled) {
  border-color: #bda0e2;
  background: rgba(85, 55, 142, 0.1);
  color: #fff;
}

.btn-ghost {
  background: rgba(255, 255, 255, 0.02);
  color: #e2e8f0;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  font-weight: 700;
}
.btn-ghost:hover:not(:disabled) {
  border-color: #bda0e2;
  background: rgba(85, 55, 142, 0.1);
  color: #fff;
}

.btn-accent-sm {
  background: #55378e;
  color: #ffffff;
  font-weight: 700;
  padding: 4px 10px;
  font-size: 0.76rem;
  border: 1px solid rgba(143, 108, 199, 0.5);
  border-radius: 10px;
  box-shadow: 0 0 20px -8px rgba(85, 55, 142, 1);
}
.btn-accent-sm:hover {
  background: #8f6cc7;
  box-shadow: 0 0 28px -6px rgba(141, 108, 199, 0.9);
}

.btn-ghost-sm {
  background: transparent;
  color: var(--text-secondary);
  padding: 4px 10px;
  font-size: 0.76rem;
  border: 1px solid var(--border-subtle);
}
.btn-ghost-sm:hover {
  border-color: #bda0e2;
  background: rgba(85, 55, 142, 0.1);
  color: #fff;
}

.btn-text-danger {
  background: transparent;
  color: var(--danger);
  font-size: 0.74rem;
}
.btn-text-danger:hover:not(:disabled) {
  text-decoration: underline;
}

.btn-sm {
  padding: 6px 12px;
  font-size: 0.8rem;
}

.btn-md {
  padding: 8px 16px;
  font-size: 0.88rem;
}

.btn-lg {
  padding: 10px 20px;
  font-size: 0.92rem;
}

.btn-block {
  width: 100%;
}

button:disabled {
  opacity: 0.45;
  cursor: not-allowed !important;
}

/* =========================================
   3-COLUMN MAIN WORKBENCH
========================================= */
.studio-main {
  display: flex;
  height: calc(100vh - var(--header-height) - var(--footer-height));
  width: 100%;
  overflow: hidden;
  min-height: 0;
  min-width: 0;
}

/* =========================================
   LEFT SIDEBAR: QUEUE & METADATA
========================================= */
.sidebar-left {
  width: var(--sidebar-left-width);
  background: transparent;
  border-right: 1px solid var(--border-subtle);
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
  overflow: hidden;
  padding: 12px;
  gap: 12px;
}

.sidebar-tabs {
  display: flex;
  gap: 4px;
  background: var(--bg-surface-elevated);
  border: 1px solid rgba(143, 108, 199, 0.45);
  border-radius: 999px;
  padding: 4px;
  box-shadow:
    0 8px 28px -12px rgba(0, 0, 0, 0.7),
    0 0 18px -8px rgba(85, 55, 142, 0.4);
}

.sidebar-tab {
  flex: 1 1 0;
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  padding: 9px 8px;
  background: transparent;
  border: none;
  border-radius: 999px;
  color: var(--text-muted);
  font-size: 0.75rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.15s ease;
  overflow: hidden;
}
.sidebar-tab svg {
  flex-shrink: 0;
  width: 14px;
  height: 14px;
}
.sidebar-tab span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  min-width: 0;
}

.sidebar-tab:hover {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.02);
}

.sidebar-tab.active {
  color: #fff;
  background: rgba(85, 55, 142, 0.35);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.tab-content {
  display: none;
  flex-direction: column;
  height: 100%;
  overflow-y: auto;
  gap: 12px;
}

.tab-content.active {
  display: flex;
}

.upload-compact-box {
  margin: 0;
  border: 1px dashed rgba(189, 160, 226, 0.45);
  border-radius: 14px;
  padding: 10px;
  text-align: center;
  background: rgba(85, 55, 142, 0.07);
  cursor: pointer;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.upload-compact-box:hover {
  border-color: var(--primary);
  background: rgba(85, 55, 142, 0.04);
  transform: none;
}

.compact-drop-content {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  color: var(--text-secondary);
  font-size: 0.8rem;
}

.hidden-input {
  display: none;
}

.file-queue-list {
  flex: 1;
  overflow-y: auto;
  padding: 10px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  background: #16141f;
  border: 1px solid rgba(143, 108, 199, 0.45);
  border-radius: 14px;
  min-height: 120px;
}

.empty-queue-hint {
  margin-top: 2.5rem;
  text-align: center;
  padding: 1.5rem 1rem;
  color: var(--text-muted);
  font-size: 0.82rem;
}

.empty-queue-hint span {
  display: block;
  font-size: 0.74rem;
  color: var(--text-dim);
  margin-top: 0.35rem;
}

.queue-item {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 8px;
  border-radius: var(--radius-md);
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  cursor: pointer;
  transition: all 0.15s ease;
}

.queue-item:hover {
  border-color: var(--border-active);
  background: var(--bg-hover);
}

.queue-item.active {
  border-color: var(--primary);
  background: rgba(85, 55, 142, 0.07);
}

.queue-thumb {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-sm);
  object-fit: cover;
  background: #000;
  flex-shrink: 0;
  border: 1px solid var(--border-subtle);
}

.queue-meta {
  flex: 1;
  min-width: 0;
}

.queue-name {
  font-size: 0.78rem;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: var(--text-primary);
}

.queue-stats {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.7rem;
  color: var(--text-muted);
  margin-top: 2px;
}

.queue-badge-save {
  background: rgba(6, 182, 212, 0.15);
  color: var(--accent-cyan);
  font-size: 0.65rem;
  padding: 1px 5px;
  border-radius: 4px;
  font-weight: 600;
}

.queue-remove-btn {
  opacity: 0;
  background: transparent;
  border: none;
  color: var(--text-dim);
  cursor: pointer;
  padding: 4px;
  border-radius: 4px;
  transition: all 0.15s ease;
}

.queue-item:hover .queue-remove-btn {
  opacity: 1;
}

.queue-remove-btn:hover {
  color: var(--danger);
  background: rgba(239, 68, 68, 0.1);
}

.sidebar-footer-actions {
  padding: 8px;
  background: var(--bg-surface-elevated);
  border: 1px solid rgba(143, 108, 199, 0.45);
  border-radius: 14px;
  display: flex;
  justify-content: center;
  flex-shrink: 0;
}
#btnClearAllQueue {
  width: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border: 1px solid rgba(239, 68, 68, 0.55);
  border-radius: 999px;
  padding: 8px 12px;
  font-weight: 600;
  box-shadow: 0 0 18px -8px rgba(239, 68, 68, 0.5);
}
#btnClearAllQueue:hover:not(:disabled) {
  background: rgba(239, 68, 68, 0.12);
  text-decoration: none;
}

/* Metadata Inspector Section */
.metadata-inspector-wrap {
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.inspector-status-banner {
  background: var(--bg-surface-elevated);
  border: 1px solid rgba(143, 108, 199, 0.45);
  border-radius: 14px;
  padding: 10px 12px;
}

.status-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.75rem;
  font-weight: 600;
  margin-bottom: 4px;
}

.status-chip.clean {
  color: var(--brand-light);
}

.status-chip .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
}

.inspector-status-banner p {
  font-size: 0.72rem;
  color: var(--text-muted);
}

.meta-section {
  background: var(--bg-surface-elevated);
  border: 1px solid rgba(143, 108, 199, 0.45);
  border-radius: 14px;
  padding: 10px 12px;
}

.meta-section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.76rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

.badge-subtle {
  font-size: 0.65rem;
  background: var(--bg-subtle);
  color: var(--text-secondary);
  padding: 2px 6px;
  border-radius: var(--radius-full);
}

.badge-emerald {
  font-size: 0.65rem;
  background: rgba(16, 185, 129, 0.15);
  color: #34d399;
  padding: 2px 6px;
  border-radius: var(--radius-full);
  font-weight: 600;
}

.meta-tags-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
  max-height: 200px;
  overflow-y: auto;
  font-family: var(--font-mono);
  font-size: 0.7rem;
}

.empty-meta-placeholder {
  color: var(--text-dim);
  font-size: 0.72rem;
  padding: 8px 0;
  text-align: center;
}

.meta-tag-row {
  display: flex;
  justify-content: space-between;
  padding: 3px 6px;
  border-radius: 4px;
  background: rgba(0, 0, 0, 0.25);
}

.meta-tag-key {
  color: var(--text-muted);
}

.meta-tag-val {
  color: var(--text-primary);
  font-weight: 500;
  text-align: right;
  max-width: 140px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sanitizer-checklist {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 4px;
}

.check-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.72rem;
  padding: 4px 6px;
  border-radius: 4px;
  background: rgba(0, 0, 0, 0.2);
}

.check-row .check-icon {
  color: #34d399;
  font-weight: 700;
}

.check-row .check-title {
  flex: 1;
  color: var(--text-secondary);
}

.check-row .check-status {
  font-size: 0.65rem;
  color: #34d399;
  font-weight: 600;
}

/* =========================================
   CENTER WORKBENCH: STAGE & TOOLBARS
========================================= */
.workbench-center {
  flex: 1;
  display: flex;
  flex-direction: column;
  background: var(--bg-base);
  overflow: hidden;
  position: relative;
  min-height: 0;
  min-width: 0;
}

.workbench-toolbar {
  height: 42px;
  background: var(--bg-surface);
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 1rem;
  user-select: none;
  z-index: 20;
}

.tool-modes-group {
  display: flex;
  align-items: center;
  gap: 4px;
  background: var(--bg-surface-elevated);
  padding: 3px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-subtle);
}

.mode-btn {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--text-secondary);
  background: transparent;
  border: none;
  cursor: pointer;
  transition: all 0.15s ease;
}

.mode-btn:hover {
  color: var(--text-primary);
}

.mode-btn.active {
  background: rgba(85, 55, 142, 0.35);
  color: #fff;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

/* Crop Aspect Ratio Selector */
.crop-toolbar {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.aspect-pills {
  display: flex;
  align-items: center;
  gap: 4px;
}

.aspect-pill {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  font-size: 0.72rem;
  padding: 3px 8px;
  border-radius: 999px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.aspect-pill:hover {
  border-color: var(--border-active);
  color: var(--text-primary);
}

.aspect-pill.active {
  background: rgba(85, 55, 142, 0.15);
  border-color: var(--primary);
  color: var(--primary);
  font-weight: 600;
}

.crop-actions {
  display: flex;
  align-items: center;
  gap: 4px;
}

.view-zoom-controls {
  display: flex;
  align-items: center;
  gap: 6px;
}

.btn-icon-xs {
  width: 26px;
  height: 26px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: 10px;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-icon-xs:hover {
  border-color: var(--brand-light);
  background: rgba(85, 55, 142, 0.1);
  color: #fff;
}

.zoom-text {
  font-size: 0.74rem;
  font-family: var(--font-mono);
  color: var(--text-secondary);
  min-width: 48px;
  text-align: center;
}

/* Stage Canvas Area */
.stage-container {
  flex: 1;
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 0;
  min-width: 0;
  height: 100%;
  background-color: #050507;
  background-image:
    radial-gradient(
      ellipse 60% 50% at 50% 40%,
      rgba(85, 55, 142, 0.14),
      transparent 65%
    ),
    linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.035) 1px, transparent 1px);
  background-size:
    100% 100%,
    36px 36px,
    36px 36px;
}

/* Drop Hero State (Studio Portal with mesh + grain) */
.drop-hero {
  position: absolute;
  inset: 1.5rem;
  z-index: 20;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  background:
    radial-gradient(
      ellipse 70% 45% at 50% 0%,
      rgba(85, 55, 142, 0.14) 0%,
      transparent 65%
    ),
    radial-gradient(
      ellipse at 50% 30%,
      rgba(85, 55, 142, 0.08) 0%,
      rgba(10, 13, 20, 0.75) 100%
    );
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  box-shadow:
    0 20px 50px -15px rgba(0, 0, 0, 0.8),
    inset 0 1px 0 0 rgba(255, 255, 255, 0.18);
  transition:
    border-color 0.25s var(--ease-spring),
    box-shadow 0.25s var(--ease-spring),
    transform 0.25s var(--ease-spring);
  cursor: pointer;
  overflow: hidden;
}

.drop-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.5;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='120' height='120' filter='url(%23n)' opacity='0.06'/%3E%3C/svg%3E");
}

.hero-glow {
  position: absolute;
  width: 420px;
  height: 420px;
  left: 50%;
  top: -140px;
  transform: translateX(-50%);
  background: radial-gradient(
    circle,
    rgba(85, 55, 142, 0.22) 0%,
    transparent 65%
  );
  filter: blur(10px);
  pointer-events: none;
  transition: transform 0.3s var(--ease-spring);
}

.drop-hero:hover,
.drop-hero.dragover {
  border-color: rgba(85, 55, 142, 0.5);
  background: radial-gradient(
    ellipse at 50% 30%,
    rgba(85, 55, 142, 0.14) 0%,
    rgba(12, 16, 24, 0.82) 100%
  );
  box-shadow:
    0 25px 60px -15px rgba(0, 0, 0, 0.9),
    0 0 35px rgba(85, 55, 142, 0.2),
    inset 0 1px 0 0 rgba(255, 255, 255, 0.3);
}

/* Corner Tech Brackets */
.hud-corner {
  position: absolute;
  width: 14px;
  height: 14px;
  border-color: rgba(85, 55, 142, 0.6);
  pointer-events: none;
}
.hud-corner.hud-tl {
  top: 12px;
  left: 12px;
  border-top: 2px solid;
  border-left: 2px solid;
}
.hud-corner.hud-tr {
  top: 12px;
  right: 12px;
  border-top: 2px solid;
  border-right: 2px solid;
}
.hud-corner.hud-bl {
  bottom: 12px;
  left: 12px;
  border-bottom: 2px solid;
  border-left: 2px solid;
}
.hud-corner.hud-br {
  bottom: 12px;
  right: 12px;
  border-bottom: 2px solid;
  border-right: 2px solid;
}

.hero-file-input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
  width: 100%;
  height: 100%;
}

.hero-content {
  max-width: 580px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.85rem;
  pointer-events: none;
  padding: 1.5rem;
}

.hero-security-chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: rgba(16, 185, 129, 0.1);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(16, 185, 129, 0.35);
  padding: 3px 12px;
  border-radius: var(--radius-full);
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 700;
  color: #6ee7b7;
  letter-spacing: 0.04em;
  box-shadow: 0 0 12px rgba(16, 185, 129, 0.15);
}

.hero-icon-ring {
  width: 64px;
  height: 64px;
  border-radius: 18px;
  background: rgba(85, 55, 142, 0.22);
  border: 1px solid rgba(85, 55, 142, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #bda0e2;
  box-shadow:
    0 0 25px rgba(85, 55, 142, 0.35),
    inset 0 1px 0 rgba(255, 255, 255, 0.2);
  margin-bottom: 0.25rem;
}

.hero-content h1,
.hero-content h2,
.drop-hero-h1 {
  font-family: var(--font-display) !important;
  font-size: clamp(2.2rem, 4.8vw, 3.8rem) !important;
  font-weight: 900 !important;
  letter-spacing: -0.035em !important;
  line-height: 1.04 !important;
  margin: 0 0 0.85rem 0 !important;
  text-align: center;
}

.hero-line-white {
  display: block;
  color: #ffffff !important;
  text-shadow: 0 2px 20px rgba(0, 0, 0, 0.85) !important;
}

.hero-line-accent {
  display: block;
  color: #bda0e2 !important;
  filter: drop-shadow(0 0 30px rgba(189, 160, 226, 0.45)) !important;
  text-shadow: 0 0 25px rgba(189, 160, 226, 0.35) !important;
}

.drop-hero-lead {
  color: #ffffff !important;
  text-shadow: 0 2px 20px rgba(0, 0, 0, 0.85) !important;
}

#btnHeroUpload {
  position: relative !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 10px !important;
  padding: 16px 36px !important;
  border-radius: 999px !important;
  font-family: var(--font-ui) !important;
  font-weight: 700 !important;
  font-size: 1rem !important;
  color: #ffffff !important;
  background: linear-gradient(180deg, #55378e 0%, #38215c 100%) !important;
  border: 1px solid rgba(143, 108, 199, 0.5) !important;
  border-top-color: rgba(189, 160, 226, 0.8) !important;
  box-shadow:
    0 1px 2px rgba(0, 0, 0, 0.6),
    0 8px 28px -4px rgba(139, 92, 246, 0.65),
    inset 0 1px 0 rgba(255, 255, 255, 0.3) !important;
  cursor: pointer !important;
  overflow: hidden !important;
  user-select: none !important;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1) !important;
}
#btnHeroUpload::after {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 60%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.28),
    transparent
  );
  transform: skewX(-25deg);
  transition: left 0.65s cubic-bezier(0.16, 1, 0.3, 1);
  pointer-events: none;
}
#btnHeroUpload:hover {
  background: linear-gradient(180deg, #8f6cc7 0%, #472d75 100%) !important;
  border-color: #bda0e2 !important;
  box-shadow:
    0 1px 2px rgba(0, 0, 0, 0.6),
    0 14px 36px -4px rgba(139, 92, 246, 0.85),
    inset 0 1px 0 rgba(255, 255, 255, 0.45) !important;
  transform: translateY(-2px) !important;
}
#btnHeroUpload:hover::after {
  left: 160%;
}

.hero-content p,
.drop-hero-sub {
  font-size: clamp(0.95rem, 0.9rem + 0.3vw, 1.05rem);
  color: #aeb9c9;
  line-height: 1.6;
  max-width: 56ch;
  text-wrap: pretty;
}

.hero-eyebrow {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #bda0e2;
}

.hero-trust-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 14px;
  margin-top: 2px;
  font-size: 0.78rem;
  color: var(--text-muted);
}

.hero-trust-row strong {
  color: var(--text-primary);
  font-weight: 700;
}

.hero-feature-pills {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin: 0.25rem 0;
}

.hero-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(255, 255, 255, 0.04);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.09);
  padding: 3px 10px;
  border-radius: 6px;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 600;
  color: #94a3b8;
  transition: all 0.15s ease;
}

.hero-pill:hover {
  color: #ffffff;
  border-color: rgba(85, 55, 142, 0.4);
}

.hero-buttons {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  margin-top: 0.5rem;
  pointer-events: auto;
}

.hero-buttons * {
  pointer-events: auto;
}

.btn-demo-glow {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  padding: 9px 18px;
  border-radius: var(--radius-md);
  background: rgba(85, 55, 142, 0.2);
  border: 1px solid rgba(85, 55, 142, 0.55);
  color: #bda0e2;
  font-family: var(--font-ui);
  font-weight: 700;
  font-size: 0.88rem;
  cursor: pointer;
  box-shadow:
    0 0 20px rgba(85, 55, 142, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.2);
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  white-space: nowrap;
}

.btn-demo-glow:hover {
  background: rgba(85, 55, 142, 0.32);
  border-color: #8f6cc7;
  color: #ffffff;
  transform: translateY(-2px);
  box-shadow:
    0 0 30px rgba(85, 55, 142, 0.55),
    inset 0 1px 0 rgba(255, 255, 255, 0.4);
}

.or-separator {
  font-size: 0.78rem;
  color: var(--text-dim);
}

.hero-kbd {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  padding: 4px 8px;
  border-radius: 6px;
  font-size: 0.78rem;
  font-family: var(--font-mono);
  color: var(--text-secondary);
}

/* =========================================
   SPLIT COMPARISON VIEW (A/B CURTAIN SLIDER)
========================================= */
.compare-wrapper {
  position: relative;
  width: 100%;
  height: 100%;
  min-height: 0;
  min-width: 0;
  max-height: 100%;
  max-width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  user-select: none;
  padding: 8px;
  box-sizing: border-box;
}

.compare-stage-box {
  position: relative;
  display: block;
  margin: auto;
  max-width: 100%;
  max-height: 100%;
  box-sizing: border-box;
  border-radius: var(--radius-sm);
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.6);
  overflow: hidden;
  user-select: none;
  transition:
    width 0.18s cubic-bezier(0.16, 1, 0.3, 1),
    height 0.18s cubic-bezier(0.16, 1, 0.3, 1);
  background: #000;
}

.compare-base-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: fill;
  user-select: none;
  pointer-events: none;
  display: block;
}

.compare-overlay {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  clip-path: polygon(50% 0, 100% 0, 100% 100%, 50% 100%);
  pointer-events: none;
}

.compare-overlay-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: fill;
  user-select: none;
  pointer-events: none;
  display: block;
}

.layer-tag {
  position: absolute;
  top: 16px;
  font-size: 0.68rem;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: var(--radius-full);
  backdrop-filter: blur(10px);
  letter-spacing: 0.05em;
  pointer-events: none;
}

.tag-left {
  left: 20px;
  background: rgba(0, 0, 0, 0.65);
  color: var(--text-muted);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.tag-right {
  right: 20px;
  background: rgba(85, 55, 142, 0.2);
  color: var(--primary);
  border: 1px solid rgba(85, 55, 142, 0.4);
}

/* Draggable Divider Curtain */
.compare-divider {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 2px;
  cursor: ew-resize;
  z-index: 30;
  transform: translateX(-50%);
}

.divider-line {
  width: 2px;
  height: 100%;
  background: rgba(255, 255, 255, 0.75);
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.8);
}

.divider-handle {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #18181b;
  border: 2px solid #fff;
  box-shadow:
    0 0 18px rgba(0, 0, 0, 0.6),
    0 0 10px var(--primary-glow);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  cursor: ew-resize;
  touch-action: none;
  transition:
    transform 0.18s var(--ease-spring),
    border-color 0.18s ease,
    box-shadow 0.18s ease;
}

.divider-handle:hover {
  border-color: var(--primary);
  transform: translate(-50%, -50%) scale(1.08);
}

.compare-divider.dragging .divider-handle {
  border-color: var(--primary);
  transform: translate(-50%, -50%) scale(1.14);
  box-shadow: 0 0 22px rgba(85, 55, 142, 0.45);
  cursor: grabbing;
}

/* =========================================
   CROP STAGE
========================================= */
.crop-wrapper {
  position: relative;
  width: 100%;
  height: 100%;
  min-height: 0;
  min-width: 0;
  max-height: 100%;
  max-width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding: 8px;
  box-sizing: border-box;
}

.crop-stage-inner {
  position: relative;
  display: block;
  margin: auto;
  max-width: 100%;
  max-height: 100%;
  box-sizing: border-box;
  border-radius: var(--radius-sm);
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.6);
  overflow: hidden;
  user-select: none;
  transition:
    width 0.18s cubic-bezier(0.16, 1, 0.3, 1),
    height 0.18s cubic-bezier(0.16, 1, 0.3, 1);
  background: #000;
  flex-shrink: 0;
}

.crop-stage-inner img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: fill;
  display: block;
  user-select: none;
  pointer-events: none;
}

/* Interactive Crop Box Overlay */
.crop-box {
  position: absolute;
  top: 10%;
  left: 10%;
  width: 80%;
  height: 80%;
  border: 2px solid var(--primary);
  box-shadow: 0 0 0 9999px rgba(0, 0, 0, 0.65);
  cursor: move;
  box-sizing: border-box;
}

.crop-grid-lines {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(
      to right,
      transparent 33.3%,
      rgba(255, 255, 255, 0.25) 33.3%,
      rgba(255, 255, 255, 0.25) 33.8%,
      transparent 33.8%,
      transparent 66.6%,
      rgba(255, 255, 255, 0.25) 66.6%,
      rgba(255, 255, 255, 0.25) 67.1%,
      transparent 67.1%
    ),
    linear-gradient(
      to bottom,
      transparent 33.3%,
      rgba(255, 255, 255, 0.25) 33.3%,
      rgba(255, 255, 255, 0.25) 33.8%,
      transparent 33.8%,
      transparent 66.6%,
      rgba(255, 255, 255, 0.25) 66.6%,
      rgba(255, 255, 255, 0.25) 67.1%,
      transparent 67.1%
    );
}

.crop-handle {
  position: absolute;
  width: 10px;
  height: 10px;
  background: #fff;
  border: 2px solid var(--primary);
  border-radius: 2px;
}

.handle-nw {
  top: -6px;
  left: -6px;
  cursor: nwse-resize;
}
.handle-ne {
  top: -6px;
  right: -6px;
  cursor: nesw-resize;
}
.handle-sw {
  bottom: -6px;
  left: -6px;
  cursor: nesw-resize;
}
.handle-se {
  bottom: -6px;
  right: -6px;
  cursor: nwse-resize;
}
.handle-n {
  top: -6px;
  left: 50%;
  transform: translateX(-50%);
  cursor: ns-resize;
}
.handle-s {
  bottom: -6px;
  left: 50%;
  transform: translateX(-50%);
  cursor: ns-resize;
}
.handle-w {
  top: 50%;
  left: -6px;
  transform: translateY(-50%);
  cursor: ew-resize;
}
.handle-e {
  top: 50%;
  right: -6px;
  transform: translateY(-50%);
  cursor: ew-resize;
}

/* Workbench Status Bar */
.workbench-status-bar {
  height: var(--status-bar-height);
  background: var(--bg-surface);
  border-top: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 1.25rem;
  font-size: 0.74rem;
  user-select: none;
}

.status-left {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.status-tag {
  font-family: var(--font-mono);
  color: var(--text-secondary);
}

.status-tag.subtle {
  color: var(--text-dim);
}

.status-arrow {
  color: var(--text-dim);
}

.status-right {
  display: flex;
  align-items: center;
}

.live-savings-pill {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-family: var(--font-mono);
}

.arrow-down {
  color: var(--primary);
  font-weight: 700;
}

.saving-badge {
  background: rgba(85, 55, 142, 0.15);
  color: var(--primary);
  padding: 2px 6px;
  border-radius: var(--radius-sm);
  font-weight: 700;
}

/* =========================================
   RIGHT SIDEBAR: OPTIMIZATION CONTROLS
========================================= */
.sidebar-right {
  width: var(--sidebar-right-width);
  background: transparent;
  border-left: 1px solid var(--border-subtle);
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
  overflow: hidden;
  padding: 12px;
  gap: 12px;
}

.panel-section-title {
  padding: 10px 14px;
  background: var(--bg-surface-elevated);
  /* border: 1px solid rgba(143, 108, 199, 0.45);*/
  border-radius: 14px;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-secondary);
  flex-shrink: 0;
}

.controls-scrollable {
  flex: 1;
  overflow-y: auto;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.control-card {
  background: var(--bg-surface-elevated);
  /*border: 1px solid rgba(143, 108, 199, 0.45);*/
  border-radius: 14px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.control-label {
  font-size: 0.76rem;
  font-weight: 600;
  color: var(--text-secondary);
}

.control-header-flex {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.quality-bubble {
  font-family: var(--font-mono);
  font-size: 0.74rem;
  font-weight: 700;
  color: var(--brand-lighter);
  background: rgba(85, 55, 142, 0.12);
  border: 1px solid rgba(85, 55, 142, 0.35);
  padding: 2px 8px;
  border-radius: 999px;
}

/* Format Grid */
.format-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
}

.format-btn {
  background: var(--bg-base);
  border: 1px solid var(--border-subtle);
  border-radius: 999px;
  padding: 8px 4px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.format-btn:hover {
  border-color: var(--border-active);
  background: var(--bg-hover);
}

.format-btn.active {
  border-color: var(--primary);
  background: rgba(85, 55, 142, 0.08);
}

.format-title {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--text-primary);
}

.format-sub {
  font-size: 0.62rem;
  color: var(--text-muted);
  text-align: center;
}

/* Quality Presets */
.quality-presets {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 4px;
  margin-top: 2px;
}

.preset-pill {
  background: var(--bg-base);
  border: 1px solid var(--border-subtle);
  border-radius: 999px;
  padding: 5px 2px;
  font-size: 0.68rem;
  color: var(--text-muted);
  cursor: pointer;
  text-align: center;
  transition: all 0.15s ease;
}

.preset-pill:hover {
  border-color: var(--border-active);
  color: var(--text-primary);
}

.preset-pill.active {
  border-color: var(--brand-light);
  background: rgba(85, 55, 142, 0.25);
  color: #fff;
  font-weight: 600;
}

.slider-wrapper {
  margin-top: 6px;
}

.studio-slider {
  width: 100%;
  accent-color: var(--primary);
  cursor: pointer;
  height: 4px;
  background: var(--bg-subtle);
  border-radius: 2px;
}

.slider-ticks {
  display: flex;
  justify-content: space-between;
  font-size: 0.62rem;
  color: var(--text-dim);
  margin-top: 4px;
  font-family: var(--font-mono);
}

.studio-select {
  width: 100%;
  background: var(--bg-base);
  border: 1px solid var(--border-subtle);
  color: var(--text-primary);
  padding: 7px 10px;
  border-radius: var(--radius-sm);
  font-size: 0.78rem;
  font-family: var(--font-ui);
  outline: none;
  cursor: pointer;
}

.studio-select:focus {
  border-color: var(--primary);
}

/* Toggles */
.toggles-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 2px;
}

.toggle-row {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  cursor: pointer;
  font-size: 0.74rem;
  color: var(--text-secondary);
}

.toggle-row input {
  display: none;
}

.toggle-switch {
  width: 30px;
  height: 16px;
  background: var(--bg-subtle);
  border-radius: 999px;
  position: relative;
  transition: background 0.2s ease;
  flex-shrink: 0;
}

.toggle-switch::after {
  content: "";
  position: absolute;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #fff;
  top: 2px;
  left: 2px;
  transition: transform 0.2s ease;
}

.toggle-row input:checked + .toggle-switch {
  background: var(--primary);
}

.toggle-row input:checked + .toggle-switch::after {
  transform: translateX(14px);
}

/* Audit Card */
.audit-card {
  background: rgba(0, 0, 0, 0.35);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.audit-row {
  display: flex;
  justify-content: space-between;
  font-size: 0.72rem;
}

.audit-label {
  color: var(--text-muted);
}

.audit-val {
  font-weight: 600;
}

.font-mono {
  font-family: var(--font-mono);
}

.font-bold {
  font-weight: 700;
}

/* Entry: materialize, don't just fade */
@keyframes heroEnter {
  from {
    opacity: 0;
    transform: translateY(14px) scale(0.99);
    filter: blur(6px);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
    filter: blur(0);
  }
}

.hero-content {
  animation: heroEnter 0.5s var(--ease-spring) both;
}

.compare-stage-box,
.crop-stage-inner {
  animation: heroEnter 0.35s var(--ease-spring) both;
}

@media (prefers-reduced-motion: reduce) {
  .hero-content,
  .compare-stage-box,
  .crop-stage-inner,
  .seo-modal-card {
    animation: none !important;
    transition: opacity 200ms ease !important;
    transform: none !important;
    filter: none !important;
  }
  .pulse-dot,
  .pulse-indicator {
    animation: none !important;
  }
  html {
    scroll-behavior: auto;
  }
}

@media (prefers-reduced-transparency: reduce) {
  .drop-hero,
  .studio-header,
  .studio-global-footer {
    background: #0c0e12;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
  }
}

.sidebar-right-footer {
  padding: 12px;
  background: var(--bg-surface-elevated);
  border: 1px solid rgba(143, 108, 199, 0.45);
  border-radius: 14px;
  flex-shrink: 0;
}

/* Hidden canvas */
.hidden-canvas {
  display: none;
}

.hidden {
  display: none !important;
}

/* =========================================
   RESIZE MODULE STYLES (PERCENT & PIXELS)
========================================= */
.resize-mode-tabs {
  display: flex;
  background: var(--bg-base);
  border: 1px solid var(--border-subtle);
  border-radius: 999px;
  padding: 2px;
  gap: 2px;
}

.tab-btn-mini {
  flex: 1;
  padding: 5px 6px;
  font-size: 0.7rem;
  font-weight: 500;
  border: none;
  border-radius: 999px;
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.15s ease;
}

.tab-btn-mini:hover {
  color: var(--text-primary);
}

.tab-btn-mini.active {
  background: rgba(85, 55, 142, 0.35);
  color: #fff;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.resize-subpanel {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.px-inputs-grid {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 2px;
}

.px-input-group {
  flex: 1;
  display: flex;
  align-items: center;
  background: var(--bg-base);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 5px 8px;
  gap: 4px;
}

.px-input-group:focus-within {
  border-color: var(--primary);
}

.px-input-label {
  font-size: 0.68rem;
  color: var(--text-dim);
  font-family: var(--font-mono);
  font-weight: 600;
}

.studio-number-input {
  width: 100%;
  background: transparent;
  border: none;
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 0.78rem;
  outline: none;
  text-align: right;
}

.studio-number-input::-webkit-inner-spin-button,
.studio-number-input::-webkit-outer-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.px-unit {
  font-size: 0.68rem;
  color: var(--text-muted);
}

.btn-lock-aspect {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 6px;
  color: var(--text-dim);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s ease;
  flex-shrink: 0;
}

.btn-lock-aspect:hover {
  color: var(--text-primary);
  border-color: var(--border-active);
}

.btn-lock-aspect.active {
  color: var(--primary);
  border-color: var(--primary);
  background: rgba(85, 55, 142, 0.12);
}

.px-quick-presets {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 4px;
}

.preset-pill-xs {
  background: var(--bg-base);
  border: 1px solid var(--border-subtle);
  border-radius: 999px;
  padding: 4px 2px;
  font-size: 0.64rem;
  color: var(--text-muted);
  cursor: pointer;
  text-align: center;
  font-family: var(--font-mono);
  transition: all 0.15s ease;
}

.preset-pill-xs:hover {
  border-color: var(--border-active);
  color: var(--text-primary);
}

.preset-pill-xs.active {
  border-color: var(--brand-light);
  color: #fff;
  background: rgba(85, 55, 142, 0.25);
  font-weight: 600;
}

.resize-feedback-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 5px 8px;
  font-size: 0.7rem;
}

.feedback-label {
  color: var(--text-muted);
}

.feedback-val {
  font-weight: 600;
}

/* =========================================
   RESPONSIVE (Tablets & Smaller Viewports)
========================================= */
@media (max-width: 1024px) {
  :root {
    --sidebar-left-width: 260px;
    --sidebar-right-width: 280px;
  }
  .header-center {
    display: none;
  }
}

@media (max-width: 768px) {
  .studio-app {
    height: auto;
    min-height: 100vh;
    overflow-y: auto;
  }
  .studio-main {
    display: flex;
    flex-direction: column;
    height: auto;
    overflow: visible;
  }
  /* Mobile UX: Place Stage/Upload first, Controls second, Queue third */
  .workbench-center {
    order: 1;
    width: 100%;
    min-height: 440px;
  }
  .sidebar-right {
    order: 2;
    width: 100%;
    height: auto;
  }
  .sidebar-left {
    order: 3;
    width: 100%;
    height: auto;
  }

  .drop-hero {
    inset: 10px;
    padding: 1.5rem 1rem;
  }
  .hero-content {
    max-width: 100%;
    gap: 0.6rem;
  }
  .drop-hero-h1 {
    font-size: clamp(1.7rem, 7vw, 2.2rem);
    line-height: 1.06;
  }
  .drop-hero-sub {
    font-size: 0.82rem;
    line-height: 1.5;
  }
  .hero-buttons {
    flex-direction: column;
    width: 100%;
    gap: 8px;
  }
  .hero-buttons .btn-primary {
    width: 100%;
    min-height: 48px;
    font-size: 0.95rem;
  }
  .or-separator,
  .hero-kbd,
  .kbd-hint {
    display: none !important;
  }

  /* Mobile Header Layout */
  .studio-header {
    padding: 0 0.75rem;
    height: 52px;
  }
  .workspace-pill {
    display: none;
  }
  .brand-logo-img {
    height: 34px;
    max-width: 140px;
  }
  .header-right {
    gap: 6px;
  }
  .header-right .btn-sm {
    padding: 6px 10px;
    font-size: 0.75rem;
    min-height: 36px;
  }

  /* Global Footer Touch Targets (WCAG 48px minimum) */
  .studio-global-footer {
    flex-direction: column;
    height: auto;
    padding: 14px 16px;
    gap: 12px;
    text-align: center;
  }
  .footer-left {
    flex-direction: column;
    gap: 8px;
  }
  .footer-right {
    gap: 16px;
    flex-wrap: wrap;
    justify-content: center;
  }
  .footer-link-btn,
  .footer-author-link {
    min-height: 48px;
    min-width: 48px;
    padding: 10px 16px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-sm);
    font-size: 0.82rem;
    text-decoration: none;
  }
  .footer-center {
    display: none;
  }
}

/* =========================================
   LOW HEIGHT VIEWPORT RESPONSIVE (Laptops)
========================================= */
@media (max-height: 800px) {
  :root {
    --header-height: 48px;
    --status-bar-height: 32px;
    --footer-height: 26px;
  }
  .brand-logo-img {
    height: 36px;
    max-width: 155px;
  }
  .controls-scrollable {
    padding: 10px;
    gap: 10px;
  }
  .control-card {
    padding: 9px;
  }
  .panel-section-title {
    padding: 8px 12px;
  }
  .compare-wrapper,
  .crop-wrapper {
    padding: 4px;
  }
}

/* =========================================
   GLOBAL STUDIO FOOTER
========================================= */
.studio-global-footer {
  height: var(--footer-height);
  background: rgba(11, 14, 21, 0.88);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow:
    0 -4px 20px rgba(0, 0, 0, 0.4),
    inset 0 1px 0 0 rgba(255, 255, 255, 0.05);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 1rem;
  font-size: 0.68rem;
  color: var(--text-muted);
  user-select: none;
  z-index: 40;
  flex-shrink: 0;
}

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

.footer-copy strong {
  color: var(--text-secondary);
  font-weight: 600;
}

.footer-author-link {
  color: #bda0e2;
  text-decoration: none;
  font-weight: 600;
  transition: color 0.15s ease;
}

.footer-author-link:hover {
  color: #bda0e2;
  text-decoration: underline;
}

.footer-sep {
  color: var(--text-dim);
}

.footer-badge-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: rgba(85, 55, 142, 0.08);
  border: 1px solid rgba(85, 55, 142, 0.25);
  color: #bda0e2;
  padding: 1px 6px;
  border-radius: var(--radius-full);
  font-size: 0.65rem;
  font-weight: 600;
}

.footer-center {
  font-size: 0.68rem;
  color: var(--text-dim);
}

.footer-right {
  display: flex;
  align-items: center;
  gap: 10px;
}

.footer-link-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 999px;
  padding: 4px 10px;
  color: var(--text-secondary);
  font-size: 0.68rem;
  cursor: pointer;
  transition: all 0.15s ease;
}

.footer-link-btn:hover {
  color: #fff;
  border-color: rgba(143, 108, 199, 0.4);
  background: rgba(85, 55, 142, 0.1);
}

.footer-version {
  font-family: var(--font-mono);
  color: var(--text-dim);
  font-size: 0.65rem;
}

/* =========================================
   SEO & PRIVACY KNOWLEDGE MODAL
========================================= */
.seo-modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(4, 6, 10, 0.78);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  opacity: 1;
  visibility: visible;
  transition:
    opacity 0.25s cubic-bezier(0.16, 1, 0.3, 1),
    visibility 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.seo-modal-backdrop.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.seo-modal-card {
  background: linear-gradient(
    165deg,
    rgba(17, 22, 33, 0.88) 0%,
    rgba(10, 13, 19, 0.92) 100%
  );
  backdrop-filter: blur(28px) saturate(190%);
  -webkit-backdrop-filter: blur(28px) saturate(190%);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 20px;
  box-shadow:
    0 25px 70px rgba(0, 0, 0, 0.9),
    0 0 45px rgba(85, 55, 142, 0.15),
    inset 0 1px 0 rgba(255, 255, 255, 0.25);
  width: 100%;
  max-width: 800px;
  max-height: 85vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  animation: modalPop 0.32s var(--ease-spring);
}

@keyframes modalPop {
  0% {
    transform: scale(0.94) translateY(14px);
    opacity: 0;
  }
  60% {
    transform: scale(1.015) translateY(-2px);
    opacity: 1;
  }
  100% {
    transform: scale(1) translateY(0);
    opacity: 1;
  }
}

.seo-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 24px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.02);
}

.seo-modal-title-wrap {
  display: flex;
  align-items: center;
  gap: 12px;
}

.seo-modal-icon img {
  border-radius: var(--radius-sm);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.seo-modal-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: #fff;
}

.seo-modal-subtitle {
  font-size: 0.72rem;
  color: var(--text-secondary);
  display: block;
}

.seo-modal-close {
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  color: var(--text-secondary);
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.15s ease;
}

.seo-modal-close:hover {
  border-color: rgba(85, 55, 142, 0.5);
  color: #fff;
  background: rgba(85, 55, 142, 0.15);
}

.seo-modal-body {
  padding: 24px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.seo-info-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
}

@media (max-width: 640px) {
  .seo-info-grid {
    grid-template-columns: 1fr;
  }
}

.seo-info-card {
  background: rgba(255, 255, 255, 0.035);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.12),
    0 8px 20px rgba(0, 0, 0, 0.3);
  border-radius: 14px;
  padding: 16px;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.seo-info-card:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(85, 55, 142, 0.45);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.22),
    0 12px 30px rgba(0, 0, 0, 0.5),
    0 0 20px rgba(85, 55, 142, 0.15);
}

.seo-card-icon {
  font-size: 1.25rem;
  margin-bottom: 6px;
}

.seo-info-card h3 {
  font-size: 0.88rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 6px;
}

.seo-info-card p {
  font-size: 0.78rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

.seo-faq-section {
  background: rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.07);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  padding: 18px;
}

.seo-faq-section h3 {
  font-size: 0.88rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 12px;
}

.faq-item {
  margin-bottom: 10px;
}

.faq-item:last-child {
  margin-bottom: 0;
}

.faq-item h4 {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--primary);
  margin-bottom: 4px;
}

.faq-item p {
  font-size: 0.74rem;
  color: var(--text-secondary);
  line-height: 1.4;
}

.seo-modal-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 20px;
  border-top: 1px solid var(--border-subtle);
  background: rgba(0, 0, 0, 0.2);
}

.seo-footer-text {
  font-size: 0.7rem;
  color: var(--text-dim);
}

/* =========================================
   ON-PAGE SEO: CYBER-FORENSICS PRIVACY LAB (GLASSMORPHYSM 2.0)
========================================= */
.seo-guide-section {
  background-color: #000000;
  background-image:
    radial-gradient(
      ellipse 80% 50% at 50% -20%,
      rgba(85, 55, 142, 0.15) 0%,
      transparent 60%
    ),
    radial-gradient(
      ellipse 60% 40% at 90% 25%,
      rgba(6, 182, 212, 0.08) 0%,
      transparent 50%
    ),
    radial-gradient(
      ellipse 70% 50% at 15% 75%,
      rgba(85, 55, 142, 0.07) 0%,
      transparent 60%
    );
  background-size:
    100% 100%,
    100% 100%,
    100% 100%;
  background-attachment: fixed;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--text-primary);
  padding: 6rem 1.5rem 8rem;
  position: relative;
  z-index: 10;
  overflow: hidden;
}

.seo-guide-section::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(85, 55, 142, 0.2) 20%,
    rgba(85, 55, 142, 0.9) 50%,
    rgba(6, 182, 212, 0.7) 75%,
    transparent 100%
  );
  box-shadow: 0 0 20px rgba(85, 55, 142, 0.65);
}

.seo-guide-container {
  max-width: 1140px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 4.5rem;
}

/* Breadcrumbs */
.seo-breadcrumbs {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  font-size: 0.78rem;
  color: var(--text-muted);
  font-family: var(--font-mono);
}

.seo-breadcrumbs a {
  color: #94a3b8;
  text-decoration: none;
  transition: color 0.15s ease;
}

.seo-breadcrumbs a:hover {
  color: #bda0e2;
}

.seo-breadcrumbs .sep {
  color: rgba(255, 255, 255, 0.2);
}

.seo-breadcrumbs .current {
  color: #bda0e2;
  font-weight: 600;
}

/* Guide Header & Telemetry */
.guide-header {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 1.25rem;
}

.forensics-status-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.85rem;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: #94a3b8;
}

.forensics-status-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(16, 185, 129, 0.09);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(16, 185, 129, 0.3);
  box-shadow:
    0 4px 16px rgba(0, 0, 0, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.15);
  padding: 5px 14px;
  border-radius: 9999px;
  color: #6ee7b7;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.pulse-indicator {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background-color: #10b981;
  box-shadow: 0 0 10px #10b981;
  animation: radarPulse 2s infinite;
}

@keyframes radarPulse {
  0% {
    opacity: 1;
    transform: scale(1);
  }
  50% {
    opacity: 0.4;
    transform: scale(1.4);
  }
  100% {
    opacity: 1;
    transform: scale(1);
  }
}

.forensics-sep {
  color: rgba(255, 255, 255, 0.2);
}

.forensics-metric {
  letter-spacing: 0.04em;
  color: #94a3b8;
}

.guide-main-title {
  font-family: var(--font-display);
  font-size: clamp(2.2rem, 4.5vw, 3.5rem);
  font-weight: 900;
  color: #ffffff;
  line-height: 1.1;
  letter-spacing: -0.03em;
  max-width: 32ch;
  text-wrap: balance;
  text-shadow: 0 2px 24px rgba(0, 0, 0, 0.8);
}

.guide-lead {
  font-size: clamp(1rem, 0.95rem + 0.4vw, 1.2rem);
  color: #a9b6c7;
  line-height: 1.65;
  max-width: 62ch;
  text-wrap: pretty;
}

/* =========================================
   BINARY FORENSIC TERMINAL (ASTRO / APPLE DESIGN)
========================================= */
.forensic-terminal-card {
  background: rgba(11, 16, 26, 0.65);
  backdrop-filter: blur(28px) saturate(180%);
  -webkit-backdrop-filter: blur(28px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 24px;
  box-shadow:
    0 28px 70px -15px rgba(0, 0, 0, 0.85),
    inset 0 1px 0 0 rgba(255, 255, 255, 0.16),
    0 0 40px rgba(85, 55, 142, 0.04);
  overflow: hidden;
  transition:
    border-color 0.25s ease,
    box-shadow 0.25s ease;
}

.forensic-terminal-card:hover {
  border-color: rgba(85, 55, 142, 0.35);
  box-shadow:
    0 32px 80px -15px rgba(0, 0, 0, 0.9),
    inset 0 1px 0 0 rgba(255, 255, 255, 0.24),
    0 0 45px rgba(85, 55, 142, 0.1);
}

/* =========================================
   COMPARATIVE TERMINAL CARD (MOUSY DEV PORTFOLIO STYLE)
   Monochromatic, dark cyber, restrained palette
========================================= */
.forensic-terminal-card {
  background: #08080c;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 20px 50px -15px rgba(0, 0, 0, 0.85);
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}
.forensic-terminal-card:hover {
  border-color: rgba(189, 160, 226, 0.3);
  box-shadow:
    0 24px 60px -15px rgba(0, 0, 0, 0.9),
    0 0 35px rgba(85, 55, 142, 0.12);
}
.terminal-topbar {
  background: rgba(255, 255, 255, 0.02);
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
  padding: 14px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.terminal-dots {
  display: flex;
  align-items: center;
  gap: 7px;
}
.terminal-dots .dot-neutral {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.08);
}
.terminal-title {
  font-family: var(--font-ui);
  font-size: 0.85rem;
  font-weight: 600;
  color: #cbd5e1;
  letter-spacing: 0.01em;
}
.terminal-badge {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 500;
  color: #bda0e2;
  background: rgba(85, 55, 142, 0.15);
  border: 1px solid rgba(189, 160, 226, 0.25);
  padding: 3px 12px;
  border-radius: 9999px;
}
.terminal-grid {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 0;
  align-items: stretch;
}
@media (max-width: 860px) {
  .terminal-grid {
    grid-template-columns: 1fr;
  }
}
.terminal-pane {
  display: flex;
  flex-direction: column;
  padding: 1.75rem 2rem;
  background: transparent;
}
.pane-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.25rem;
}
.pane-label {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 600;
  color: #64748b;
  letter-spacing: 0.08em;
}
.pane-chip-muted {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 500;
  color: #94a3b8;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  padding: 3px 12px;
  border-radius: 9999px;
}
.pane-chip-accent {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 600;
  color: #bda0e2;
  background: rgba(85, 55, 142, 0.15);
  border: 1px solid rgba(189, 160, 226, 0.35);
  padding: 3px 12px;
  border-radius: 9999px;
}
.reveal-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
}
.reveal-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.06);
  transition: all 0.25s ease;
}
.reveal-row:hover {
  background: rgba(255, 255, 255, 0.04);
  border-color: rgba(255, 255, 255, 0.12);
}
.reveal-row.active-row {
  background: rgba(85, 55, 142, 0.06);
  border-color: rgba(189, 160, 226, 0.15);
}
.reveal-row.active-row:hover {
  background: rgba(85, 55, 142, 0.12);
  border-color: rgba(189, 160, 226, 0.35);
}
.reveal-icon-wrap {
  width: 32px;
  height: 32px;
  border-radius: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: #94a3b8;
}
.reveal-icon-wrap.accent {
  background: rgba(85, 55, 142, 0.18);
  border-color: rgba(189, 160, 226, 0.35);
  color: #bda0e2;
}
.reveal-text {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.reveal-text strong {
  font-size: 0.84rem;
  font-weight: 600;
  color: #ffffff;
}
.reveal-text span {
  font-size: 0.74rem;
  color: #94a3b8;
}
.reveal-tag {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  font-weight: 600;
  padding: 2px 9px;
  border-radius: 9999px;
  white-space: nowrap;
}
.tag-neutral {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: #94a3b8;
}
.tag-accent {
  background: rgba(85, 55, 142, 0.18);
  border: 1px solid rgba(189, 160, 226, 0.35);
  color: #d7c6ee;
}
.terminal-divider {
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  padding: 0 12px;
}
.terminal-divider::before {
  content: '';
  position: absolute;
  top: 10%;
  bottom: 10%;
  width: 1px;
  background: rgba(255, 255, 255, 0.08);
}
.divider-pill {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  border-radius: 9999px;
  background: #08080c;
  border: 1px solid rgba(189, 160, 226, 0.35);
  color: #bda0e2;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 600;
  box-shadow: 0 0 16px rgba(85, 55, 142, 0.3);
}
@media (max-width: 860px) {
  .terminal-divider {
    padding: 16px 0;
  }
  .terminal-divider::before {
    top: auto;
    bottom: auto;
    left: 10%;
    right: 10%;
    height: 1px;
    width: auto;
  }
}
.pane-note {
  margin-top: 1.25rem;
  padding: 10px 14px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 0.74rem;
  color: #94a3b8;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.06);
}
.note-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #64748b;
  flex-shrink: 0;
}
.pane-note.accent {
  background: rgba(85, 55, 142, 0.08);
  border-color: rgba(189, 160, 226, 0.2);
  color: #cbd5e1;
}
.note-dot-emerald {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #34d399;
  box-shadow: 0 0 8px #34d399;
  flex-shrink: 0;
  animation: pulseDot 2s infinite ease-in-out;
}
@keyframes pulseDot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(0.85); }
}


/* =========================================
   VECTORS & BENTO CARDS (ASTRO / APPLE DESIGN)
========================================= */
.vectors-section {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.vectors-header {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.vectors-badge,
.pipeline-badge,
.matrix-badge,
.faq-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 14px;
  border-radius: 9999px;
  background: rgba(85, 55, 142, 0.12);
  border: 1px solid rgba(85, 55, 142, 0.4);
  color: #bda0e2;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  width: fit-content;
  box-shadow:
    0 2px 10px rgba(0, 0, 0, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.vectors-title,
.pipeline-title,
.matrix-title,
.faq-title {
  font-family: var(--font-display);
  font-size: 1.85rem;
  font-weight: 900;
  color: #ffffff;
  letter-spacing: -0.02em;
  line-height: 1.15;
  text-shadow: 0 2px 20px rgba(0, 0, 0, 0.6);
  text-wrap: balance;
}
.guide-accent {
  color: #bda0e2 !important;
  background: none !important;
  -webkit-background-clip: unset !important;
  background-clip: unset !important;
  filter: drop-shadow(0 0 30px rgba(189, 160, 226, 0.45)) !important;
  text-shadow: 0 0 25px rgba(189, 160, 226, 0.35) !important;
  display: inline !important;
}

.guide-title-white {
  color: #ffffff !important;
  text-shadow: 0 2px 20px rgba(0, 0, 0, 0.85);
}

.guide-lead {
  font-size: 1.15rem;
  max-width: 44rem;
}

.guide-cta {
  display: inline-flex;
  margin-top: 1.75rem;
}

.forensic-cards-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.85rem;
}

@media (max-width: 840px) {
  .forensic-cards-grid {
    grid-template-columns: 1fr;
  }
}

.forensic-card {
  background: linear-gradient(
    170deg,
    rgba(16, 23, 37, 0.65) 0%,
    rgba(10, 14, 23, 0.75) 100%
  );
  backdrop-filter: blur(24px) saturate(180%);
  -webkit-backdrop-filter: blur(24px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 24px;
  padding: 2rem 2.25rem;
  display: flex;
  flex-direction: column;
  gap: 1.15rem;
  position: relative;
  overflow: hidden;
  box-shadow:
    0 20px 50px -15px rgba(0, 0, 0, 0.75),
    inset 0 1px 0 0 rgba(255, 255, 255, 0.14);
  transition:
    transform 0.25s cubic-bezier(0.16, 1, 0.3, 1),
    border-color 0.25s ease,
    box-shadow 0.25s ease;
}

.forensic-card::before {
  content: "";
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(
    circle at 30% 20%,
    rgba(85, 55, 142, 0.06) 0%,
    transparent 50%
  );
  pointer-events: none;
  z-index: 0;
  transition: opacity 0.3s ease;
}

.forensic-card:hover {
  transform: translateY(-4px);
  border-color: rgba(85, 55, 142, 0.4);
  box-shadow:
    0 28px 65px -15px rgba(0, 0, 0, 0.85),
    0 0 35px rgba(85, 55, 142, 0.15),
    inset 0 1px 0 0 rgba(255, 255, 255, 0.25);
}

.forensic-card > * {
  position: relative;
  z-index: 1;
}

/* MousyTools: línea de acento superior que aparece en hover */
.forensic-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--brand-light), transparent 70%);
  opacity: 0;
  transition: opacity 0.35s var(--ease-mousy);
  z-index: 2;
}
.forensic-card:hover::before {
  opacity: 1;
}

.card-hud-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.hud-icon {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.25),
    0 8px 20px rgba(0, 0, 0, 0.4);
  transition: transform 0.2s ease;
}

.forensic-card:hover .hud-icon {
  transform: scale(1.06);
}

.hud-icon.radar {
  background: rgba(239, 68, 68, 0.12);
  color: #f87171;
  border-color: rgba(239, 68, 68, 0.3);
}

.hud-icon.sensor {
  background: rgba(245, 158, 11, 0.12);
  color: #fbbf24;
  border-color: rgba(245, 158, 11, 0.3);
}

.hud-icon.ai {
  background: rgba(6, 182, 212, 0.12);
  color: #67e8f9;
  border-color: rgba(6, 182, 212, 0.3);
}

.hud-icon.speed {
  background: rgba(85, 55, 142, 0.12);
  color: #34d399;
  border-color: rgba(85, 55, 142, 0.35);
}

.hud-readout {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 3px;
}

.readout-label {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  color: #64748b;
}

.readout-tag {
  font-family: var(--font-mono);
  font-size: 0.66rem;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 6px;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.readout-tag.danger {
  background: rgba(239, 68, 68, 0.16);
  color: #fca5a5;
  border: 1px solid rgba(239, 68, 68, 0.35);
}
.readout-tag.warning {
  background: rgba(245, 158, 11, 0.16);
  color: #fde047;
  border: 1px solid rgba(245, 158, 11, 0.35);
}
.readout-tag.cyan {
  background: rgba(6, 182, 212, 0.16);
  color: #67e8f9;
  border: 1px solid rgba(6, 182, 212, 0.35);
}
.readout-tag.emerald {
  background: rgba(16, 185, 129, 0.16);
  color: #6ee7b7;
  border: 1px solid rgba(16, 185, 129, 0.4);
}

.card-heading {
  font-size: 1.22rem;
  font-weight: 700;
  color: #ffffff;
  line-height: 1.32;
  letter-spacing: -0.015em;
}

.card-body-text {
  font-size: 0.9rem;
  color: #cbd5e1;
  line-height: 1.65;
  flex: 1;
}

.card-body-text code {
  background: rgba(255, 255, 255, 0.07);
  backdrop-filter: blur(6px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #6ee7b7;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  padding: 2px 6px;
  border-radius: 5px;
}

.card-telemetry-box {
  background: rgba(5, 8, 14, 0.55);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 14px;
  padding: 12px 16px;
  font-family: var(--font-mono);
  font-size: 0.74rem;
  display: flex;
  flex-direction: column;
  gap: 4px;
  color: #cbd5e1;
  box-shadow: inset 0 1px 4px rgba(0, 0, 0, 0.4);
}

.card-telemetry-box strong {
  color: #ffffff;
}
.text-danger {
  color: #f87171 !important;
}
.text-warning {
  color: #fbbf24 !important;
}
.text-cyan {
  color: #67e8f9 !important;
}
.text-emerald {
  color: #34d399 !important;
}

/* =========================================
   VECTOR SPECIFICATION ROWS (APPLE DESIGN)
========================================= */
.vector-spec-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0.25rem 0 0.5rem 0;
  font-family: var(--font-mono);
  font-size: 0.74rem;
  flex-wrap: wrap;
}

.spec-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 11px;
  border-radius: 8px;
  font-weight: 700;
  letter-spacing: 0.02em;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.spec-pill.pill-danger {
  background: rgba(239, 68, 68, 0.12);
  color: #fca5a5;
  border: 1px solid rgba(239, 68, 68, 0.28);
}

.spec-pill.pill-warning {
  background: rgba(245, 158, 11, 0.12);
  color: #fde047;
  border: 1px solid rgba(245, 158, 11, 0.28);
}

.spec-pill.pill-cyan {
  background: rgba(6, 182, 212, 0.12);
  color: #67e8f9;
  border: 1px solid rgba(6, 182, 212, 0.28);
}

.spec-pill.pill-neutral {
  background: rgba(255, 255, 255, 0.06);
  color: #cbd5e1;
  border: 1px solid rgba(255, 255, 255, 0.11);
}

.spec-pill.pill-clean,
.spec-pill.pill-emerald {
  background: rgba(85, 55, 142, 0.14);
  color: #6ee7b7;
  border: 1px solid rgba(85, 55, 142, 0.38);
  box-shadow: 0 0 12px rgba(85, 55, 142, 0.18);
}

.spec-arrow {
  color: #8f6cc7;
  font-weight: 800;
  font-size: 0.9rem;
}

/* =========================================
   PIPELINE STEP BY STEP (ASTRO / APPLE DESIGN)
========================================= */
.pipeline-section {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.pipeline-header {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.pipeline-sub,
.faq-sub {
  font-size: 0.98rem;
  color: #94a3b8;
}

.pipeline-steps-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.85rem;
  position: relative;
}

.pipeline-step {
  background: linear-gradient(
    165deg,
    rgba(16, 22, 34, 0.65) 0%,
    rgba(10, 13, 20, 0.75) 100%
  );
  backdrop-filter: blur(24px) saturate(180%);
  -webkit-backdrop-filter: blur(24px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 24px;
  padding: 2.1rem;
  display: flex;
  gap: 1.35rem;
  position: relative;
  box-shadow:
    0 18px 45px -12px rgba(0, 0, 0, 0.75),
    inset 0 1px 0 0 rgba(255, 255, 255, 0.14);
  transition:
    transform 0.25s cubic-bezier(0.16, 1, 0.3, 1),
    border-color 0.25s ease,
    box-shadow 0.25s ease;
}

.pipeline-step:hover {
  transform: translateY(-4px);
  border-color: rgba(85, 55, 142, 0.4);
  box-shadow:
    0 26px 60px -15px rgba(0, 0, 0, 0.85),
    0 0 30px rgba(85, 55, 142, 0.15),
    inset 0 1px 0 0 rgba(255, 255, 255, 0.25);
}

.step-num-pill {
  font-family: var(--font-mono);
  font-size: 1.15rem;
  font-weight: 800;
  color: #ffffff;
  background: linear-gradient(135deg, #8f6cc7 0%, #55378e 100%);
  width: 46px;
  height: 46px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-shadow:
    0 8px 24px rgba(85, 55, 142, 0.4),
    inset 0 1px 1px rgba(255, 255, 255, 0.6);
}

.step-content {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}

.step-heading {
  font-size: 1.12rem;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: -0.015em;
}

.step-text {
  font-size: 0.9rem;
  color: #cbd5e1;
  line-height: 1.62;
}

.step-text kbd {
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(6px);
  border: 1px solid rgba(255, 255, 255, 0.18);
  padding: 2px 7px;
  border-radius: 6px;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: #ffffff;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.step-text code {
  background: rgba(85, 55, 142, 0.12);
  backdrop-filter: blur(6px);
  color: #6ee7b7;
  padding: 2px 6px;
  border-radius: 5px;
  font-family: var(--font-mono);
  border: 1px solid rgba(85, 55, 142, 0.25);
}

/* =========================================
   FORENSIC AUDIT TABLE MATRIX (ASTRO / APPLE DESIGN)
========================================= */
.matrix-audit-section {
  display: flex;
  flex-direction: column;
  gap: 1.85rem;
}

.matrix-table-wrap {
  background: rgba(11, 16, 26, 0.65);
  backdrop-filter: blur(28px) saturate(180%);
  -webkit-backdrop-filter: blur(28px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 24px;
  overflow-x: auto;
  box-shadow:
    0 24px 65px -15px rgba(0, 0, 0, 0.8),
    inset 0 1px 0 0 rgba(255, 255, 255, 0.14);
}

.forensic-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 0.88rem;
}

.forensic-table th {
  background: rgba(17, 24, 38, 0.8);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  padding: 19px 24px;
  color: var(--brand-lighter);
  font-weight: 700;
  border-bottom: 2px solid rgba(85, 55, 142, 0.35);
  white-space: nowrap;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.12);
}

.forensic-table td {
  padding: 19px 24px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  color: #cbd5e1;
  vertical-align: middle;
  transition: background 0.15s ease;
}

.forensic-table tr:hover td {
  background: rgba(85, 55, 142, 0.04);
}

.cell-entity {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.cell-entity strong {
  color: #ffffff;
}

.entity-code {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: #64748b;
}

.chip-fmt {
  background: rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(6px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #ffffff;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: 6px;
  margin-right: 4px;
}

.status-pill {
  display: inline-block;
  padding: 4px 11px;
  border-radius: 7px;
  font-family: var(--font-mono);
  font-size: 0.73rem;
  font-weight: 700;
  white-space: nowrap;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.status-pill.critical {
  background: rgba(239, 68, 68, 0.15);
  color: #fca5a5;
  border: 1px solid rgba(239, 68, 68, 0.35);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1);
}
.status-pill.high {
  background: rgba(245, 158, 11, 0.15);
  color: #fde047;
  border: 1px solid rgba(245, 158, 11, 0.35);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1);
}
.status-pill.medium {
  background: rgba(6, 182, 212, 0.15);
  color: #67e8f9;
  border: 1px solid rgba(6, 182, 212, 0.35);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1);
}
.status-pill.low {
  background: rgba(148, 163, 184, 0.15);
  color: #cbd5e1;
  border: 1px solid rgba(148, 163, 184, 0.35);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1);
}
.status-pill.clean {
  background: rgba(16, 185, 129, 0.15);
  color: #6ee7b7;
  border: 1px solid rgba(16, 185, 129, 0.4);
  box-shadow:
    0 0 14px rgba(16, 185, 129, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.15);
}

/* =========================================
   FAQ ACCORDIONS (APPLE SUPPORT STYLE)
========================================= */
.faq-forensic-section {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.faq-accordion-grid {
  display: flex;
  flex-direction: column;
  gap: 1.15rem;
}

.forensic-details {
  background: linear-gradient(
    165deg,
    rgba(16, 21, 32, 0.65) 0%,
    rgba(10, 13, 20, 0.72) 100%
  );
  backdrop-filter: blur(22px) saturate(170%);
  -webkit-backdrop-filter: blur(22px) saturate(170%);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 20px;
  overflow: hidden;
  box-shadow:
    0 12px 35px -10px rgba(0, 0, 0, 0.65),
    inset 0 1px 0 0 rgba(255, 255, 255, 0.12);
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.forensic-details:hover {
  border-color: rgba(255, 255, 255, 0.16);
  background: linear-gradient(
    165deg,
    rgba(19, 25, 38, 0.72) 0%,
    rgba(12, 16, 25, 0.78) 100%
  );
}

.forensic-details[open] {
  border-color: rgba(85, 55, 142, 0.42);
  box-shadow:
    0 20px 50px -12px rgba(0, 0, 0, 0.8),
    0 0 25px rgba(85, 55, 142, 0.12),
    inset 0 1px 0 0 rgba(255, 255, 255, 0.22);
}

.forensic-summary {
  padding: 22px 28px;
  font-size: 1.06rem;
  font-weight: 600;
  color: #ffffff;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
  user-select: none;
  transition: color 0.15s ease;
}

.forensic-summary::-webkit-details-marker {
  display: none;
}

.forensic-details[open] .forensic-summary {
  color: #6ee7b7;
}

.sum-icon {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #94a3b8;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  flex-shrink: 0;
}

.forensic-details[open] .sum-icon {
  transform: rotate(180deg);
  background: rgba(85, 55, 142, 0.18);
  color: #bda0e2;
  border-color: rgba(85, 55, 142, 0.38);
  box-shadow: 0 0 16px rgba(85, 55, 142, 0.3);
}

.forensic-answer {
  padding: 0 28px 26px;
  color: #cbd5e1;
  font-size: 0.95rem;
  line-height: 1.7;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  padding-top: 18px;
}

.forensic-answer strong {
  color: #ffffff;
}
.forensic-answer em {
  color: #34d399;
  font-style: normal;
  font-weight: 600;
}

/* =========================================
   ENGINEERING & AUTHOR PROFILE (ASTRO / APPLE DESIGN)
========================================= */
.engineering-card {
  background: linear-gradient(
    135deg,
    rgba(19, 25, 38, 0.75) 0%,
    rgba(10, 13, 20, 0.82) 100%
  );
  backdrop-filter: blur(28px) saturate(180%);
  -webkit-backdrop-filter: blur(28px) saturate(180%);
  border: 1px solid rgba(85, 55, 142, 0.32);
  border-radius: 24px;
  padding: 2.25rem 2.85rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2.5rem;
  box-shadow:
    0 25px 65px -15px rgba(0, 0, 0, 0.85),
    0 0 35px rgba(85, 55, 142, 0.08),
    inset 0 1px 0 0 rgba(255, 255, 255, 0.18);
}

.eng-profile {
  display: flex;
  align-items: center;
  gap: 1.75rem;
  flex: 1;
}

.eng-avatar-wrap {
  position: relative;
  flex-shrink: 0;
}

.eng-avatar-wrap img {
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: #000;
  display: block;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
}

.eng-verified {
  position: absolute;
  bottom: -4px;
  right: -4px;
  background: linear-gradient(135deg, #8f6cc7 0%, #55378e 100%);
  color: #ffffff;
  font-size: 0.7rem;
  font-weight: 900;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid #090c12;
  box-shadow: 0 0 10px rgba(85, 55, 142, 0.5);
}

.eng-details {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.eng-author {
  font-size: 1.22rem;
  font-weight: 700;
  color: #ffffff;
}

.eng-author a {
  color: #bda0e2;
  text-decoration: none;
}
.eng-author a:hover {
  color: #ffffff;
  text-shadow: 0 0 10px rgba(85, 55, 142, 0.4);
  transition: all 0.15s ease;
  text-decoration: underline;
}

.eng-statement {
  font-size: 0.92rem;
  color: #cbd5e1;
  line-height: 1.62;
}

.eng-cta-wrap {
  flex-shrink: 0;
}

.eng-cta-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  padding: 15px 28px;
  font-size: 0.96rem;
  font-weight: 700;
  text-decoration: none;
  background: #55378e;
  color: #ffffff;
  font-weight: 800;
  border: 1px solid rgba(143, 108, 199, 0.5);
  border-radius: 24px;
  box-shadow: 0 0 40px -10px rgba(85, 55, 142, 1);
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.eng-cta-btn:hover {
  background: #8f6cc7;
  border-color: #bda0e2;
  box-shadow: 0 0 50px -10px rgba(141, 108, 199, 0.9);
}

/* Responsive Rules */
@media (max-width: 900px) {
  .terminal-grid {
    grid-template-columns: 1fr;
  }
  .terminal-flow-bridge {
    writing-mode: horizontal-tb;
    padding: 0.85rem;
    border-left: none;
    border-right: none;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  }
  .terminal-flow-bridge::after {
    width: 100%;
    height: 2px;
    top: 0;
    bottom: auto;
    animation: flowLaserH 3s infinite linear;
  }
  @keyframes flowLaserH {
    0% {
      transform: translateX(-100%);
    }
    100% {
      transform: translateX(100%);
    }
  }
  .flow-pill {
    writing-mode: horizontal-tb;
    transform: none;
    padding: 0;
  }
  .engineering-card {
    flex-direction: column;
    align-items: flex-start;
    gap: 1.85rem;
    padding: 1.85rem;
  }
}

@media (max-width: 768px) {
  .seo-guide-section {
    padding: 4rem 1.15rem 6rem;
  }
  .guide-main-title {
    font-size: 1.85rem;
  }
  .forensic-cards-grid {
    grid-template-columns: 1fr;
  }
  .pipeline-steps-grid {
    grid-template-columns: 1fr;
  }
  .eng-profile {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* ==========================================================================
   MousyTools v3.0 — Nivel visual de guía: línea de acento superior,
   hovers con halo morado y glow en CTA (receta de cards MousyTools)
   ========================================================================== */

/* Pipeline steps: línea superior + halo en hover */
.pipeline-step {
  overflow: hidden;
}
.pipeline-step::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--brand-light), transparent 70%);
  opacity: 0;
  transition: opacity 0.35s var(--ease-mousy);
  z-index: 2;
}
.pipeline-step:hover::before {
  opacity: 1;
}
.pipeline-step:hover {
  box-shadow:
    0 26px 60px -15px rgba(0, 0, 0, 0.85),
    0 0 35px rgba(85, 55, 142, 0.22),
    inset 0 1px 0 0 rgba(255, 255, 255, 0.25);
}

/* FAQ forense: hover con halo + estado abierto tintado */
.forensic-details:hover {
  border-color: rgba(85, 55, 142, 0.4);
  box-shadow:
    0 12px 35px -10px rgba(0, 0, 0, 0.65),
    0 0 24px rgba(85, 55, 142, 0.12),
    inset 0 1px 0 0 rgba(255, 255, 255, 0.12);
}
.forensic-details[open] {
  border-color: rgba(85, 55, 142, 0.35);
}
.forensic-summary:hover {
  color: #bda0e2;
}

/* Terminal forense: línea superior sutil permanente */
.forensic-terminal-card {
  position: relative;
}
.forensic-terminal-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(
    90deg,
    transparent 10%,
    rgba(85, 55, 142, 0.55) 50%,
    transparent 90%
  );
  opacity: 0.7;
  z-index: 2;
}

/* Engineering CTA: halo radial superior estilo MousyTools */
.engineering-card {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(
      ellipse at 50% 0%,
      rgba(85, 55, 142, 0.22),
      transparent 60%
    ),
    linear-gradient(
      135deg,
      rgba(19, 25, 38, 0.75) 0%,
      rgba(10, 13, 20, 0.82) 100%
    );
}
.engineering-card::before {
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: 24px;
  padding: 1px;
  background: linear-gradient(
    140deg,
    var(--brand-lighter),
    transparent 40%,
    transparent 60%,
    var(--brand)
  );
  -webkit-mask:
    linear-gradient(#fff 0 0) content-box,
    linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  opacity: 0.6;
  pointer-events: none;
}
/* ==========================================================================
   Compatibilidad: componente reveal-* del light, adaptado al tema oscuro
   ========================================================================== */
.reveal-list {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
}
.reveal-row {
  display: flex;
  gap: 10px;
  align-items: center;
  padding: 9px 12px;
  border-radius: 10px;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.06);
  transition:
    background 0.25s ease,
    border-color 0.25s ease,
    transform 0.25s ease;
}
.reveal-row:hover {
  background: rgba(85, 55, 142, 0.12);
  border-color: rgba(189, 160, 226, 0.4);
  transform: translateX(3px);
}
.reveal-row.ok {
  background: rgba(16, 185, 129, 0.08);
  border-color: rgba(16, 185, 129, 0.2);
}
.reveal-icon {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  flex-shrink: 0;
}
.reveal-row.ok .reveal-icon {
  background: #10b981;
  border-color: #10b981;
  color: #fff;
  font-weight: 800;
  font-size: 0.85rem;
}
.reveal-text {
  flex: 1;
  display: flex;
  flex-direction: column;
  line-height: 1.35;
  gap: 2px;
}
.reveal-text strong {
  font-size: 0.84rem;
  color: #fff;
  font-weight: 700;
}
.reveal-text span {
  font-size: 0.74rem;
  color: #94a3b8;
}
.reveal-tag {
  font-size: 0.64rem;
  font-family: var(--font-mono);
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 999px;
  white-space: nowrap;
}
.tag-danger {
  background: rgba(239, 68, 68, 0.16);
  color: #fca5a5;
  border: 1px solid rgba(239, 68, 68, 0.35);
}
.tag-warning {
  background: rgba(245, 158, 11, 0.16);
  color: #fde047;
  border: 1px solid rgba(245, 158, 11, 0.35);
}
.tag-clean {
  background: rgba(16, 185, 129, 0.16);
  color: #6ee7b7;
  border: 1px solid rgba(16, 185, 129, 0.35);
}
/* Paneles del editor: sin efectos hover (no son botones) — solo separación estática */
/* Glassmorphism portfolio: los paneles dejan respirar las auroras */
.sidebar-tabs,
.sidebar-footer-actions,
.inspector-status-banner,
.meta-section,
.panel-section-title,
.control-card,
.sidebar-right-footer {
  background: rgba(22, 20, 32, 0.72);
  backdrop-filter: blur(18px) saturate(150%);
  -webkit-backdrop-filter: blur(18px) saturate(150%);
}
/* ==========================================================================
   Sidebar upload v3.4 — héroe de subida, vacío compacto, items con carácter
   ========================================================================== */
/* 1. Cola vacía: se oculta el panel hint y el héroe ocupa todo */
.tab-content:has(.empty-queue-hint) .file-queue-list {
  display: none;
}
.tab-content:has(.empty-queue-hint) .upload-compact-box {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}
/* 2. Zona de subida protagonista */
.upload-compact-box {
  padding: 18px 14px;
  border-width: 2px;
  background:
    radial-gradient(
      ellipse at 50% 0%,
      rgba(85, 55, 142, 0.16),
      transparent 70%
    ),
    rgba(85, 55, 142, 0.07);
  box-shadow:
    0 0 28px -10px rgba(85, 55, 142, 0.45),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.upload-compact-box:hover {
  transform: none;
  box-shadow:
    0 0 36px -8px rgba(85, 55, 142, 0.6),
    inset 0 1px 0 rgba(255, 255, 255, 0.12);
}
.compact-drop-content {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-primary);
}
.compact-drop-content svg {
  width: 28px;
  height: 28px;
  color: var(--brand-lighter);
}
/* 3. Estado vacío diseñado */
.empty-queue-hint {
  margin-top: 0;
  padding: 1.1rem 1rem;
}
.empty-queue-hint::before {
  content: "⇪";
  display: block;
  font-size: 1.9rem;
  line-height: 1;
  color: var(--brand-light);
  text-shadow: 0 0 18px rgba(143, 108, 199, 0.6);
  margin-bottom: 0.6rem;
}
.empty-queue-hint p {
  color: var(--text-primary);
  font-weight: 600;
  font-size: 0.86rem;
}
/* 4. Items con carácter: barra activa + hover con vida */
.queue-item:hover {
  transform: translateX(3px);
}
.queue-item.active {
  box-shadow:
    inset 3px 0 0 var(--brand-light),
    0 0 20px -8px rgba(85, 55, 142, 0.6);
}
.tag-warning {
  background: rgba(245, 158, 11, 0.16);
  color: #fde047;
  border: 1px solid rgba(245, 158, 11, 0.35);
}
.tag-clean {
  background: rgba(16, 185, 129, 0.16);
  color: #6ee7b7;
  border: 1px solid rgba(16, 185, 129, 0.35);
}
.tag-header {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.1);
}
.faq-header,
.matrix-audit-header {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.footer-tagline {
  color: var(--text-dim);
  font-size: 0.8rem;
}
