/* ==============================================================================
   OMNIWIRE TOOLSHUB — 3D CYBER-TERMINAL SAAS DESIGN SYSTEM (V3.5 CYBER)
   Fonts: 'Orbitron' (Headings), 'Chakra Petch' (UI & Body), 'JetBrains Mono' (Code)
   Theme: 3D Beveled Cards, Glowing Top Rims, Tactile Buttons, 1650px Workspace
   ============================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Chakra+Petch:wght@400;500;600;700&family=JetBrains+Mono:wght@400;500;700&family=Orbitron:wght@600;700;800;900&display=swap');

:root, [data-theme="light"] {
  /* Sci-Fi Robotics Typography Scale */
  --font-display: 'Orbitron', 'Plus Jakarta Sans', system-ui, sans-serif;
  --font-sans: 'Chakra Petch', 'Plus Jakarta Sans', system-ui, sans-serif;
  --font-mono: 'JetBrains Mono', SFMono-Regular, Consolas, monospace;

  /* Theme Tokens — Deep Sleek Navy/Black (No blinding white) */
  --bg-canvas: #0A111E !important;
  --bg-surface: #0F1A2E !important;
  --bg-card: #152238 !important;
  --bg-card-elevated: #1E2D4A !important;
  --bg-card-hover: #1A2840 !important;
  --bg-input: rgba(15, 26, 46, 0.9) !important;
  --bg-input-focus: rgba(21, 34, 56, 0.98) !important;

  --text-title: #FFFFFF !important;       /* Crisp bright white on dark surfaces */
  --text-heading: #38BDF8 !important;     /* Electric cyan heading */
  --text-body: #94A3B8 !important;
  --text-dim: #64748B !important;
  --text-primary: #FFFFFF !important;

  --border-color: rgba(56, 189, 248, 0.2) !important;
  --border-hairline: rgba(56, 189, 248, 0.2) !important;
  --border-subtle: rgba(255, 255, 255, 0.12) !important;
  --border-top-rim: rgba(56, 189, 248, 0.4) !important;
  --border-focus: #38BDF8 !important;

  /* Brand Accents */
  --accent-emerald: #10B981;
  --accent-emerald-dark: #047857;
  --accent-emerald-glow: rgba(16, 185, 129, 0.35);
  --accent-cyan: #38BDF8;
  --accent-cyan-dark: #0284C7;
  --accent-cyan-glow: rgba(56, 189, 248, 0.35);
  --accent-gradient: linear-gradient(135deg, #10B981 0%, #38BDF8 100%);
  --accent-badge-cyan: #38BDF8;
  --accent-badge-emerald: #34D399;
  --accent-amber: #F59E0B;
  --accent-rose: #F43F5E;
  --accent-purple: #A855F7;

  --shadow-card-3d: 0 20px 45px -10px rgba(0, 0, 0, 0.8), 0 0 15px -3px rgba(6, 182, 212, 0.12);
  --shadow-card-3d-hover: 0 25px 50px -12px rgba(6, 182, 212, 0.25), 0 0 25px 2px rgba(16, 185, 129, 0.2);
  --glass-bg: rgba(10, 17, 30, 0.92);

  --bg-main: var(--bg-canvas);
  --text-main: var(--text-title);
  --text-muted: var(--text-body);
}

[data-theme="dark"] {
  --bg-canvas: #060D17 !important;
  --bg-surface: #0E1A2B !important;
  --bg-card: #12233B !important;
  --bg-card-elevated: #162A45 !important;
  --bg-card-hover: #182C48 !important;
  --bg-input: rgba(14, 26, 43, 0.9) !important;
  --bg-input-focus: rgba(18, 35, 59, 0.98) !important;

  --text-title: #F8FAFC !important;
  --text-heading: #06B6D4 !important;
  --text-body: #A0AEC0 !important;
  --text-dim: #718096 !important;
  --text-primary: #F8FAFC !important;

  --border-color: rgba(6, 182, 212, 0.25) !important;
  --border-hairline: rgba(6, 182, 212, 0.25) !important;
  --border-subtle: rgba(255, 255, 255, 0.1) !important;
  --border-top-rim: rgba(6, 182, 212, 0.42) !important;
  --border-focus: #10B981 !important;

  --accent-cyan: #06B6D4;
  --accent-cyan-dark: #0E7490;
  --accent-cyan-glow: rgba(6, 182, 212, 0.35);

  --shadow-card-3d: 0 20px 45px -10px rgba(0, 0, 0, 0.85), 0 0 15px -3px rgba(6, 182, 212, 0.15);
  --shadow-card-3d-hover: 0 25px 50px -12px rgba(6, 182, 212, 0.3), 0 0 25px 2px rgba(16, 185, 129, 0.25);
  --glass-bg: rgba(6, 13, 23, 0.92);

  --bg-main: var(--bg-canvas);
  --text-main: var(--text-title);
  --text-muted: var(--text-body);
}

/* Force All Headings to be 100% Legible */
h1, h2, h3, h4, h5, h6, .tool-title, .page-heading {
  font-family: var(--font-display);
  color: var(--text-title) !important;
  font-weight: 800;
  line-height: 1.25;
  letter-spacing: 0.04em;
  font-feature-settings: "zero" 1;
  display: block !important;
  visibility: visible !important;
  opacity: 1 !important;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3) !important;
}

h1 { font-size: 2.15rem; font-weight: 900; }
h2 { font-size: 1.65rem; font-weight: 800; }
h3 { font-size: 1.25rem; font-weight: 700; }

a {
  color: var(--accent-cyan);
  text-decoration: none;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}
a:hover {
  color: var(--accent-emerald);
}

/* Sleek Cyber Scrollbars */
::-webkit-scrollbar {
  width: 7px;
  height: 7px;
}
::-webkit-scrollbar-track {
  background: var(--bg-canvas);
}
::-webkit-scrollbar-thumb {
  background: rgba(148, 163, 184, 0.25);
  border-radius: 9999px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--accent-cyan);
}

/* ==============================================================================
   RESPONSIVE GLOBAL CONTAINER & WORKSPACE (1650PX MAX)
   ============================================================================== */
.tools-app-container, .app-container {
  display: flex;
  width: 100%;
  max-width: 100%;
  min-height: 100vh;
  position: relative;
}

.tools-workspace, .main-wrapper {
  flex: 1;
  width: 100% !important;
  max-width: 1600px !important;
  margin: 0 auto;
  padding: 32px 40px;
  box-sizing: border-box;
  overflow: visible !important;
}

.content-body {
  max-width: 1600px !important;
  width: 100%;
  margin: 0 auto;
  padding: 0;
  overflow: visible !important;
}

@media (max-width: 1200px) {
  .tools-workspace, .main-wrapper {
    padding: 24px 20px;
  }
}

@media (max-width: 1024px) {
  .tools-workspace, .main-wrapper {
    width: 100% !important;
    padding: 16px 12px;
  }
}

/* ==============================================================================
   TOP STICKY NAVBAR & RESPONSIVE BRAND LOGO (100% LIGHT-MODE VISIBLE)
   ============================================================================== */
.top-navbar {
  height: 70px;
  background: var(--glass-bg);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-hairline);
  position: sticky;
  top: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 2rem;
  transition: all 0.25s ease;
}

.brand-logo-wrap, .nav-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--text-heading);
}

.brand-icon {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: var(--accent-gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #060D17;
  font-weight: 900;
  box-shadow: 0 4px 14px var(--accent-cyan-glow);
  transition: transform 0.25s ease;
  flex-shrink: 0;
}
.brand-logo-wrap:hover .brand-icon {
  transform: rotate(8deg) scale(1.08);
}

.brand-title {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 900;
  letter-spacing: 0.04em;
  color: var(--text-heading);
  font-feature-settings: "zero" 1;
}

[data-theme="light"] .brand-title {
  color: #0F172A !important;
}

[data-theme="dark"] .brand-title {
  color: #F8FAFC !important;
}

.brand-accent {
  color: var(--accent-cyan);
}

[data-theme="light"] .brand-logo-img {
  filter: brightness(0) saturate(100%) invert(10%);
}
[data-theme="dark"] .brand-logo-img {
  filter: none;
}

.hub-tag {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  background: rgba(6, 182, 212, 0.14);
  color: var(--accent-cyan);
  border: 1px solid rgba(6, 182, 212, 0.35);
  padding: 3px 8px;
  border-radius: 6px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 800;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.nav-item-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.45rem 0.95rem;
  font-size: 0.88rem;
  font-weight: 600;
  border-radius: 10px;
  border: 1px solid var(--border-hairline);
  background: rgba(15, 23, 42, 0.6);
  color: var(--text-body);
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  cursor: pointer;
}
[data-theme="light"] .nav-item-btn {
  background: var(--bg-surface);
  border-color: var(--border-color);
  color: var(--text-body);
}
.nav-item-btn:hover {
  background: var(--bg-card-elevated);
  color: var(--text-heading);
  border-color: var(--accent-cyan);
  transform: translateY(-2px);
}
.nav-item-btn.special-biz {
  border-color: rgba(16, 185, 129, 0.35);
  background: rgba(16, 185, 129, 0.1);
  color: #34D399;
}
.nav-item-btn.special-biz:hover {
  background: rgba(16, 185, 129, 0.2);
  color: #6EE7B7;
  border-color: #10B981;
}

/* ==============================================================================
   SIDEBAR NAVIGATION (280PX TACTICAL SUITE)
   ============================================================================== */
.sidebar-wrapper {
  width: 280px;
  flex-shrink: 0;
  background-color: var(--bg-surface);
  border-right: 1px solid var(--border-hairline);
  display: flex;
  flex-direction: column;
  position: sticky;
  top: 0;
  height: 100vh;
  z-index: 40;
  overflow-y: auto;
  padding: 24px 16px;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), background-color 0.25s ease;
}

.sidebar-header {
  padding: 0 8px 12px 8px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.sidebar-title {
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  color: var(--text-heading);
}

.sidebar-section-label {
  font-family: var(--font-sans);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-dim);
  padding: 0 10px;
  margin: 14px 0 6px 0;
}

.sidebar-menu {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.sidebar-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.65rem 0.95rem;
  border-radius: 12px;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-body);
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  border: 1px solid transparent;
  border-left: 3px solid transparent;
}
.sidebar-link:hover {
  background-color: rgba(255, 255, 255, 0.04);
  color: var(--text-heading);
  transform: translateX(3px);
}
[data-theme="light"] .sidebar-link:hover {
  background-color: #F1F5F9;
}

.sidebar-link.active {
  background: linear-gradient(90deg, rgba(16, 185, 129, 0.16) 0%, rgba(6, 182, 212, 0.04) 100%);
  color: var(--text-heading);
  font-weight: 700;
  border-color: rgba(16, 185, 129, 0.25);
  border-left: 3px solid #10B981;
  box-shadow: 0 4px 14px rgba(16, 185, 129, 0.1);
}
[data-theme="light"] .sidebar-link.active {
  background: linear-gradient(90deg, rgba(13, 148, 136, 0.14) 0%, rgba(2, 132, 199, 0.04) 100%);
  border-left: 3px solid #0D9488;
}

.sidebar-link .link-content {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
.sidebar-icon {
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: var(--accent-cyan);
  transition: transform 0.2s ease, color 0.2s ease;
}
.sidebar-link.active .sidebar-icon {
  color: var(--accent-emerald);
}
.sidebar-link:hover .sidebar-icon {
  transform: scale(1.12);
}

.sidebar-security-badge {
  margin: 1.5rem 0.5rem 0.5rem 0.5rem;
  padding: 0.95rem 1rem;
  background: rgba(10, 16, 28, 0.6);
  border: 1px solid var(--border-hairline);
  border-radius: 14px;
  backdrop-filter: blur(8px);
}
[data-theme="light"] .sidebar-security-badge {
  background: var(--bg-surface);
  border-color: var(--border-color);
}

/* ==============================================================================
   3D CYBER-TERMINAL CARDS (BEVELED 18PX & GLOWING TOP RIM)
   ============================================================================== */
.terminal-card-3d, .tool-card {
  background: linear-gradient(145deg, rgba(14, 26, 43, 0.95) 0%, rgba(6, 13, 23, 0.98) 100%);
  border: 1px solid var(--border-hairline);
  border-top: 1px solid var(--border-top-rim);
  border-radius: 18px;
  box-shadow: var(--shadow-card-3d);
  padding: 1.85rem;
  transition: all 0.3s cubic-bezier(0.2, 0.8, 0.2, 1);
  position: relative;
  overflow: hidden;
}

.terminal-card-3d:hover, .tool-card:hover {
  transform: translateY(-5px);
  border-color: rgba(6, 182, 212, 0.45);
  box-shadow: var(--shadow-card-3d-hover);
}

[data-theme="light"] .terminal-card-3d, [data-theme="light"] .tool-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-top: 2px solid var(--border-top-rim);
  box-shadow: var(--shadow-card-3d);
}
[data-theme="light"] .terminal-card-3d:hover, [data-theme="light"] .tool-card:hover {
  box-shadow: var(--shadow-card-3d-hover);
}

.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.5rem;
  padding-bottom: 0.9rem;
  border-bottom: 1px solid var(--border-hairline);
}

.card-title {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text-heading);
  letter-spacing: 0.02em;
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

/* ==============================================================================
   3D TACTILE BUTTONS (EMERALD & CYAN PRESS-DOWN ELEVATION)
   ============================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.65rem 1.35rem;
  font-size: 0.9rem;
  font-weight: 700;
  border-radius: 10px;
  cursor: pointer;
  border: none;
  text-decoration: none;
  font-family: var(--font-sans);
  transition: all 0.12s ease;
}

/* 3D Emerald Tactile Button */
.btn-cyber-3d, .btn-primary {
  background: linear-gradient(180deg, #10B981 0%, #059669 100%);
  border-radius: 10px;
  border: none;
  color: #042F2E;
  font-weight: 800;
  box-shadow: 
    0 4px 0 #047857,
    0 10px 20px rgba(16, 185, 129, 0.4);
}
.btn-cyber-3d:hover, .btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 
    0 6px 0 #047857,
    0 14px 24px rgba(16, 185, 129, 0.55);
  color: #042F2E;
}
.btn-cyber-3d:active, .btn-primary:active {
  transform: translateY(3px);
  box-shadow: 
    0 1px 0 #047857,
    0 4px 10px rgba(16, 185, 129, 0.3);
}

/* 3D Cyan Tactile Button */
.btn-cyan {
  background: linear-gradient(180deg, #06B6D4 0%, #0891B2 100%);
  border-radius: 10px;
  border: none;
  color: #082F49;
  font-weight: 800;
  box-shadow: 
    0 4px 0 #0E7490,
    0 10px 20px rgba(6, 182, 212, 0.4);
}
.btn-cyan:hover {
  transform: translateY(-2px);
  box-shadow: 
    0 6px 0 #0E7490,
    0 14px 24px rgba(6, 182, 212, 0.55);
  color: #082F49;
}
.btn-cyan:active {
  transform: translateY(3px);
  box-shadow: 
    0 1px 0 #0E7490,
    0 4px 10px rgba(6, 182, 212, 0.3);
}

/* Secondary & Danger Buttons */
.btn-secondary {
  background: rgba(30, 41, 59, 0.7);
  border: 1px solid var(--border-subtle);
  color: var(--text-heading);
}
.btn-secondary:hover {
  background: rgba(51, 65, 85, 0.9);
  border-color: rgba(255, 255, 255, 0.25);
  transform: translateY(-2px);
  color: #FFFFFF;
}
[data-theme="light"] .btn-secondary {
  background: #F1F5F9;
  border-color: #CBD5E1;
  color: #0F172A;
}

.btn-danger {
  background: linear-gradient(180deg, #F43F5E 0%, #E11D48 100%);
  color: #FFFFFF;
  box-shadow: 0 4px 0 #BE123C, 0 8px 16px rgba(244, 63, 94, 0.35);
}
.btn-danger:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 0 #BE123C, 0 12px 20px rgba(244, 63, 94, 0.5);
}
.btn-danger:active {
  transform: translateY(3px);
  box-shadow: 0 1px 0 #BE123C, 0 4px 8px rgba(244, 63, 94, 0.3);
}

.btn-ghost {
  background: transparent;
  border: 1px solid var(--border-hairline);
  color: var(--text-body);
}
.btn-ghost:hover {
  color: var(--text-heading);
  background: rgba(255, 255, 255, 0.06);
  border-color: var(--border-subtle);
  transform: translateY(-1px);
}
[data-theme="light"] .btn-ghost:hover {
  background: #F1F5F9;
}

.btn-sm {
  padding: 0.4rem 0.85rem;
  font-size: 0.82rem;
  border-radius: 8px;
}
.btn-lg {
  padding: 0.95rem 2rem;
  font-size: 1.05rem;
  border-radius: 12px;
}

/* ==============================================================================
   FORM CONTROLS & CODE WINDOWS
   ============================================================================== */
.form-group {
  margin-bottom: 1.25rem;
}

.form-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--text-heading);
  margin-bottom: 0.45rem;
  letter-spacing: 0.02em;
}

.form-input, .form-control, .form-textarea, .form-select, select {
  width: 100%;
  background-color: var(--bg-input) !important;
  border: 1px solid var(--border-color) !important;
  border-radius: 10px;
  padding: 0.75rem 1rem;
  font-size: 0.92rem;
  color: var(--text-title) !important;
  font-family: var(--font-sans);
  outline: none;
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.4);
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.form-input:focus, .form-control:focus, .form-textarea:focus, .form-select:focus, select:focus {
  border-color: var(--text-heading) !important;
  background-color: var(--bg-input-focus) !important;
  box-shadow: 0 0 14px rgba(56, 189, 248, 0.28), inset 0 1px 3px rgba(0, 0, 0, 0.4) !important;
}

.form-textarea.font-mono, .form-input.font-mono {
  font-family: var(--font-mono);
  font-size: 0.88rem;
}

.form-textarea {
  min-height: 140px;
  resize: vertical;
  line-height: 1.6;
}

/* macOS Terminal Frame */
.mac-window {
  border-radius: 14px;
  background: rgba(10, 15, 26, 0.95);
  border: 1px solid var(--border-hairline);
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
  margin-bottom: 1.25rem;
}
[data-theme="light"] .mac-window {
  background: #0F172A;
}

.mac-window-header {
  height: 38px;
  background: rgba(15, 23, 42, 0.98);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 1rem;
}

.mac-window-dots {
  display: flex;
  align-items: center;
  gap: 7px;
}
.mac-dot {
  width: 11px;
  height: 11px;
  border-radius: 50%;
  display: inline-block;
}
.mac-dot-red { background: #EF4444; box-shadow: 0 0 6px rgba(239, 68, 68, 0.5); }
.mac-dot-yellow { background: #F59E0B; box-shadow: 0 0 6px rgba(245, 158, 11, 0.5); }
.mac-dot-green { background: #10B981; box-shadow: 0 0 6px rgba(16, 185, 129, 0.5); }

.mac-window-title {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-dim);
  letter-spacing: 0.05em;
}

/* ==============================================================================
   HIGH-SPEED KINETIC WARP ANIMATIONS & TABS
   ============================================================================== */
@keyframes terminalWarp {
  0% {
    opacity: 0;
    transform: scale(0.97) translateY(12px);
    filter: brightness(1.4) blur(3px);
  }
  100% {
    opacity: 1;
    transform: scale(1) translateY(0);
    filter: brightness(1) blur(0px);
  }
}

.tab-pane.active, .tool-view, .workspace-content, .deck-pane.active {
  animation: terminalWarp 0.25s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.tabs-container {
  display: flex;
  gap: 0.4rem;
  padding: 6px;
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid var(--border-hairline);
  border-radius: 14px;
  margin-bottom: 1.75rem;
  overflow-x: auto;
}
[data-theme="light"] .tabs-container {
  background: #E2E8F0;
  border-color: #CBD5E1;
}

.tab-btn {
  background: transparent;
  border: 1px solid transparent;
  padding: 0.65rem 1.25rem;
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--text-body);
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  white-space: nowrap;
  display: flex;
  align-items: center;
  gap: 0.55rem;
  font-family: var(--font-sans);
}

.tab-btn:hover {
  color: var(--text-heading);
  background: rgba(255, 255, 255, 0.06);
}
[data-theme="light"] .tab-btn:hover {
  background: rgba(255, 255, 255, 0.8);
}

.tab-btn.active {
  color: #FFFFFF;
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.25) 0%, rgba(6, 182, 212, 0.25) 100%);
  border: 1px solid rgba(6, 182, 212, 0.4);
  box-shadow: 0 4px 14px rgba(6, 182, 212, 0.2);
}
[data-theme="light"] .tab-btn.active {
  color: #0F172A;
  background: #FFFFFF;
  border-color: #CBD5E1;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.tab-pane {
  display: none;
}
.tab-pane.active {
  display: block;
}

/* ==============================================================================
   BADGES & CHIPS (TACTILE GLOW PILLS)
   ============================================================================== */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  font-family: var(--font-sans);
}

.badge-emerald {
  background: rgba(16, 185, 129, 0.14);
  color: var(--accent-badge-emerald);
  border: 1px solid rgba(16, 185, 129, 0.35);
  box-shadow: 0 0 10px rgba(16, 185, 129, 0.15);
}
.badge-cyan {
  background: rgba(6, 182, 212, 0.14);
  color: var(--accent-badge-cyan);
  border: 1px solid rgba(6, 182, 212, 0.35);
  box-shadow: 0 0 10px rgba(6, 182, 212, 0.15);
}
.badge-amber {
  background: rgba(245, 158, 11, 0.14);
  color: #FBBF24;
  border: 1px solid rgba(245, 158, 11, 0.35);
}
.badge-rose {
  background: rgba(244, 63, 94, 0.14);
  color: #FB7185;
  border: 1px solid rgba(244, 63, 94, 0.35);
}
.badge-purple {
  background: rgba(168, 85, 247, 0.14);
  color: #C084FC;
  border: 1px solid rgba(168, 85, 247, 0.35);
}

/* ==============================================================================
   DROPZONE & CONVERTER CONTROLS
   ============================================================================== */
.dropzone {
  border: 2px dashed rgba(255, 255, 255, 0.18);
  background-color: rgba(15, 23, 42, 0.45);
  border-radius: 18px;
  padding: 3rem 1.5rem;
  text-align: center;
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
}
[data-theme="light"] .dropzone {
  background-color: #F1F5F9;
  border-color: #CBD5E1;
}

.dropzone:hover, .dropzone.dragover {
  border-color: var(--accent-cyan);
  background-color: rgba(6, 182, 212, 0.08);
  transform: translateY(-2px);
  box-shadow: 0 0 25px rgba(6, 182, 212, 0.2);
}

.dropzone-icon {
  width: 52px;
  height: 52px;
  margin: 0 auto 0.85rem;
  color: var(--accent-cyan);
  transition: transform 0.25s ease;
}
.dropzone:hover .dropzone-icon {
  transform: translateY(-4px) scale(1.08);
  color: var(--accent-emerald);
}

@keyframes pulseGlow {
  0% { box-shadow: 0 0 10px rgba(6, 182, 212, 0.2); }
  100% { box-shadow: 0 0 30px rgba(6, 182, 212, 0.55); }
}
.dropzone.dragover {
  animation: pulseGlow 1.2s infinite alternate;
}

/* ==============================================================================
   TOAST NOTIFICATION ENGINE (POP-OUT FEEDBACK)
   ============================================================================== */
#toast-container {
  position: fixed;
  bottom: 1.75rem;
  right: 1.75rem;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  pointer-events: none;
}

.toast-msg {
  background: rgba(15, 23, 42, 0.95);
  color: #FFFFFF;
  border: 1px solid rgba(6, 182, 212, 0.45);
  padding: 0.85rem 1.4rem;
  border-radius: 12px;
  font-size: 0.9rem;
  font-weight: 700;
  box-shadow: 0 14px 35px rgba(0, 0, 0, 0.6), 0 0 18px var(--accent-cyan-glow);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  display: flex;
  align-items: center;
  gap: 0.75rem;
  pointer-events: auto;
  animation: terminalWarp 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  transition: opacity 0.2s ease, transform 0.2s ease;
}

/* ==============================================================================
   RETRO RETRO TERMINAL GAME CONTAINER
   ============================================================================== */
.game-terminal-wrapper {
  background: #040810;
  border: 1px solid var(--border-hairline);
  border-top: 2px solid var(--accent-cyan);
  border-radius: 18px;
  box-shadow: 0 20px 45px rgba(0, 0, 0, 0.7), 0 0 30px rgba(6, 182, 212, 0.15);
  overflow: hidden;
  position: relative;
}

.game-terminal-header {
  background: #0A1320;
  padding: 0.85rem 1.25rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* ==============================================================================
   DOCUMENTATION & PROSE STYLING
   ============================================================================== */
.seo-docs-section {
  margin-top: 4rem;
  padding-top: 2.75rem;
  border-top: 1px solid var(--border-hairline);
}

.seo-docs-section h2 {
  font-size: 1.75rem;
  margin-bottom: 1.15rem;
  color: var(--text-heading);
}

.seo-docs-section h3 {
  font-size: 1.3rem;
  margin: 1.75rem 0 0.85rem 0;
  color: var(--accent-cyan);
}

.seo-docs-section p {
  color: var(--text-body);
  margin-bottom: 1.25rem;
  font-size: 0.98rem;
  line-height: 1.75;
}

.seo-docs-section ul, .seo-docs-section ol {
  margin-left: 1.75rem;
  margin-bottom: 1.35rem;
  color: var(--text-body);
}

.seo-docs-section li {
  margin-bottom: 0.6rem;
  line-height: 1.7;
}

.tool-callout {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.08) 0%, rgba(6, 182, 212, 0.05) 100%);
  border: 1px solid rgba(16, 185, 129, 0.3);
  border-left: 4px solid var(--accent-emerald);
  padding: 1.25rem 1.5rem;
  border-radius: 14px;
  margin: 1.75rem 0;
  font-size: 0.95rem;
  color: var(--text-heading);
  line-height: 1.65;
}

.faq-box {
  background-color: var(--bg-card);
  border: 1px solid var(--border-hairline);
  border-radius: 14px;
  padding: 1.25rem 1.5rem;
  margin-bottom: 1rem;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  transition: all 0.2s ease;
}
.faq-box:hover {
  border-color: rgba(6, 182, 212, 0.35);
}

.faq-question {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--text-heading);
  font-size: 1.05rem;
  margin-bottom: 0.5rem;
  letter-spacing: 0.02em;
}

.faq-answer {
  color: var(--text-body);
  font-size: 0.95rem;
  line-height: 1.65;
}

pre {
  background-color: #040810;
  border: 1px solid var(--border-hairline);
  border-radius: 12px;
  padding: 1.15rem 1.35rem;
  overflow-x: auto;
  font-family: var(--font-mono);
  font-size: 0.88rem;
  color: #38BDF8;
  line-height: 1.65;
  margin: 1.25rem 0;
}
code {
  font-family: var(--font-mono);
  background: rgba(6, 182, 212, 0.12);
  color: #22D3EE;
  padding: 0.15rem 0.45rem;
  border-radius: 6px;
  font-size: 0.88em;
}
pre code {
  background: transparent;
  padding: 0;
  color: inherit;
  font-size: inherit;
}

/* ==============================================================================
   AD CONTAINERS (CLS < 0.05 RESERVED CONTAINERS)
   ============================================================================== */
.ad-slot-leaderboard, .ad-leaderboard-container {
  min-height: 90px;
  background: rgba(6, 182, 212, 0.02) !important;
  border: 1px dashed rgba(6, 182, 212, 0.15) !important;
  border-radius: 14px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin: 24px 0;
  overflow: hidden;
  position: relative;
}
[data-theme="light"] .ad-slot-leaderboard, [data-theme="light"] .ad-leaderboard-container {
  background: rgba(2, 132, 199, 0.02) !important;
  border: 1px dashed rgba(2, 132, 199, 0.18) !important;
}

.ad-skyscraper-container {
  min-height: 600px;
  width: 100%;
  max-width: 300px;
  background: rgba(6, 182, 212, 0.02) !important;
  border: 1px dashed rgba(6, 182, 212, 0.15) !important;
  border-radius: 14px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin: 24px auto;
  overflow: hidden;
  position: relative;
}
[data-theme="light"] .ad-skyscraper-container {
  background: rgba(2, 132, 199, 0.02) !important;
  border: 1px dashed rgba(2, 132, 199, 0.18) !important;
}

/* ==============================================================================
   GRID & UTILITY CLASSES
   ============================================================================== */
.grid { display: grid; }
.grid-cols-1 { grid-template-columns: repeat(1, minmax(0, 1fr)); }
.grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.gap-2 { gap: 0.5rem; }
.gap-3 { gap: 0.75rem; }
.gap-4 { gap: 1rem; }
.gap-6 { gap: 1.5rem; }
.gap-8 { gap: 2rem; }

@media (min-width: 640px) {
  .sm\:grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .sm\:grid-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (min-width: 768px) {
  .md\:grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .md\:grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .md\:grid-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (min-width: 1024px) {
  .lg\:grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .lg\:grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .lg\:grid-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

.flex { display: flex; }
.inline-flex { display: inline-flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.items-start { align-items: flex-start; }
.justify-between { justify-content: space-between; }
.justify-center { justify-content: center; }
.justify-end { justify-content: flex-end; }
.flex-1 { flex: 1 1 0%; }
.flex-wrap { flex-wrap: wrap; }
.flex-shrink-0 { flex-shrink: 0; }

.m-0 { margin: 0; }
.mb-2 { margin-bottom: 0.5rem; }
.mb-3 { margin-bottom: 0.75rem; }
.mb-4 { margin-bottom: 1rem; }
.mb-6 { margin-bottom: 1.5rem; }
.mb-8 { margin-bottom: 2rem; }
.mt-2 { margin-top: 0.5rem; }
.mt-4 { margin-top: 1rem; }
.mt-6 { margin-top: 1.5rem; }
.mt-8 { margin-top: 2rem; }
.p-4 { padding: 1rem; }
.p-6 { padding: 1.5rem; }
.py-2 { padding-top: 0.5rem; padding-bottom: 0.5rem; }
.py-4 { padding-top: 1rem; padding-bottom: 1rem; }
.px-4 { padding-left: 1rem; padding-right: 1rem; }

/* ==============================================================================
   RESPONSIVE MOBILE DRAWER & WORKSPACE SQUEEZE PREVENTION (<1024px)
   ============================================================================== */
.mobile-drawer-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 9998;
  transition: opacity 0.3s ease;
}
.mobile-drawer-overlay.active { display: block; }

.mobile-menu-btn {
  display: none;
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid var(--border-hairline);
  color: var(--text-heading);
  cursor: pointer;
  padding: 0.5rem;
  border-radius: 10px;
}
[data-theme="light"] .mobile-menu-btn {
  background: #FFFFFF;
}

@media (max-width: 1024px) {
  .tools-app-container, .app-container {
    display: block !important;
    width: 100% !important;
  }
  .sidebar-wrapper {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    height: 100vh !important;
    width: 280px !important;
    transform: translateX(-100%) !important;
    box-shadow: 0 0 50px rgba(0, 0, 0, 0.85) !important;
    z-index: 9999 !important;
  }
  .sidebar-wrapper.mobile-open {
    transform: translateX(0) !important;
  }
  .mobile-menu-btn {
    display: inline-flex;
  }
  .tools-workspace, .main-wrapper {
    width: 100% !important;
    max-width: 100% !important;
    padding: 16px !important;
    flex: none !important;
    box-sizing: border-box !important;
  }
  .top-navbar {
    padding: 0 1.25rem;
  }
}

/* Tab Transition Keyframe & Micro-Interactions */
@keyframes terminalFade {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.tab-pane.active {
  animation: terminalFade 0.22s ease-out forwards;
}

.btn-copied {
  border-color: #10B981 !important;
  color: #10B981 !important;
  box-shadow: 0 0 16px rgba(16, 185, 129, 0.45) !important;
  transform: scale(1.02);
  transition: all 0.15s ease !important;
}
