/* this gets exported as style.css and can be used for the default theming */
/* these are the necessary styles for React Flow, they get used by base.css and style.css */
.react-flow__container {
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
}
.react-flow__pane {
  z-index: 1;
  cursor: -webkit-grab;
  cursor: grab;
}
.react-flow__pane.selection {
    cursor: pointer;
  }
.react-flow__pane.dragging {
    cursor: -webkit-grabbing;
    cursor: grabbing;
  }
.react-flow__viewport {
  transform-origin: 0 0;
  z-index: 2;
  pointer-events: none;
}
.react-flow__renderer {
  z-index: 4;
}
.react-flow__selection {
  z-index: 6;
}
.react-flow__nodesselection-rect:focus,
.react-flow__nodesselection-rect:focus-visible {
  outline: none;
}
.react-flow .react-flow__edges {
  pointer-events: none;
  overflow: visible;
}
.react-flow__edge-path,
.react-flow__connection-path {
  stroke: #b1b1b7;
  stroke-width: 1;
  fill: none;
}
.react-flow__edge {
  pointer-events: visibleStroke;
  cursor: pointer;
}
.react-flow__edge.animated path {
    stroke-dasharray: 5;
    -webkit-animation: dashdraw 0.5s linear infinite;
            animation: dashdraw 0.5s linear infinite;
  }
.react-flow__edge.animated path.react-flow__edge-interaction {
    stroke-dasharray: none;
    -webkit-animation: none;
            animation: none;
  }
.react-flow__edge.inactive {
    pointer-events: none;
  }
.react-flow__edge.selected,
  .react-flow__edge:focus,
  .react-flow__edge:focus-visible {
    outline: none;
  }
.react-flow__edge.selected .react-flow__edge-path,
  .react-flow__edge:focus .react-flow__edge-path,
  .react-flow__edge:focus-visible .react-flow__edge-path {
    stroke: #555;
  }
.react-flow__edge-textwrapper {
    pointer-events: all;
  }
.react-flow__edge-textbg {
    fill: white;
  }
.react-flow__edge .react-flow__edge-text {
    pointer-events: none;
    -webkit-user-select: none;
       -moz-user-select: none;
            user-select: none;
  }
.react-flow__connection {
  pointer-events: none;
}
.react-flow__connection .animated {
    stroke-dasharray: 5;
    -webkit-animation: dashdraw 0.5s linear infinite;
            animation: dashdraw 0.5s linear infinite;
  }
.react-flow__connectionline {
  z-index: 1001;
}
.react-flow__nodes {
  pointer-events: none;
  transform-origin: 0 0;
}
.react-flow__node {
  position: absolute;
  -webkit-user-select: none;
     -moz-user-select: none;
          user-select: none;
  pointer-events: all;
  transform-origin: 0 0;
  box-sizing: border-box;
  cursor: -webkit-grab;
  cursor: grab;
}
.react-flow__node.dragging {
    cursor: -webkit-grabbing;
    cursor: grabbing;
  }
.react-flow__nodesselection {
  z-index: 3;
  transform-origin: left top;
  pointer-events: none;
}
.react-flow__nodesselection-rect {
    position: absolute;
    pointer-events: all;
    cursor: -webkit-grab;
    cursor: grab;
  }
.react-flow__handle {
  position: absolute;
  pointer-events: none;
  min-width: 5px;
  min-height: 5px;
  width: 6px;
  height: 6px;
  background: #1a192b;
  border: 1px solid white;
  border-radius: 100%;
}
.react-flow__handle.connectionindicator {
    pointer-events: all;
    cursor: crosshair;
  }
.react-flow__handle-bottom {
    top: auto;
    left: 50%;
    bottom: -4px;
    transform: translate(-50%, 0);
  }
.react-flow__handle-top {
    left: 50%;
    top: -4px;
    transform: translate(-50%, 0);
  }
.react-flow__handle-left {
    top: 50%;
    left: -4px;
    transform: translate(0, -50%);
  }
.react-flow__handle-right {
    right: -4px;
    top: 50%;
    transform: translate(0, -50%);
  }
.react-flow__edgeupdater {
  cursor: move;
  pointer-events: all;
}
.react-flow__panel {
  position: absolute;
  z-index: 5;
  margin: 15px;
}
.react-flow__panel.top {
    top: 0;
  }
.react-flow__panel.bottom {
    bottom: 0;
  }
.react-flow__panel.left {
    left: 0;
  }
.react-flow__panel.right {
    right: 0;
  }
.react-flow__panel.center {
    left: 50%;
    transform: translateX(-50%);
  }
.react-flow__attribution {
  font-size: 10px;
  background: rgba(255, 255, 255, 0.5);
  padding: 2px 3px;
  margin: 0;
}
.react-flow__attribution a {
    text-decoration: none;
    color: #999;
  }
@-webkit-keyframes dashdraw {
  from {
    stroke-dashoffset: 10;
  }
}
@keyframes dashdraw {
  from {
    stroke-dashoffset: 10;
  }
}
.react-flow__edgelabel-renderer {
  position: absolute;
  width: 100%;
  height: 100%;
  pointer-events: none;
  -webkit-user-select: none;
     -moz-user-select: none;
          user-select: none;
}
.react-flow__edge.updating .react-flow__edge-path {
      stroke: #777;
    }
.react-flow__edge-text {
    font-size: 10px;
  }
.react-flow__node.selectable:focus,
  .react-flow__node.selectable:focus-visible {
    outline: none;
  }
.react-flow__node-default,
.react-flow__node-input,
.react-flow__node-output,
.react-flow__node-group {
  padding: 10px;
  border-radius: 3px;
  width: 150px;
  font-size: 12px;
  color: #222;
  text-align: center;
  border-width: 1px;
  border-style: solid;
  border-color: #1a192b;
  background-color: white;
}
.react-flow__node-default.selectable:hover, .react-flow__node-input.selectable:hover, .react-flow__node-output.selectable:hover, .react-flow__node-group.selectable:hover {
      box-shadow: 0 1px 4px 1px rgba(0, 0, 0, 0.08);
    }
.react-flow__node-default.selectable.selected,
    .react-flow__node-default.selectable:focus,
    .react-flow__node-default.selectable:focus-visible,
    .react-flow__node-input.selectable.selected,
    .react-flow__node-input.selectable:focus,
    .react-flow__node-input.selectable:focus-visible,
    .react-flow__node-output.selectable.selected,
    .react-flow__node-output.selectable:focus,
    .react-flow__node-output.selectable:focus-visible,
    .react-flow__node-group.selectable.selected,
    .react-flow__node-group.selectable:focus,
    .react-flow__node-group.selectable:focus-visible {
      box-shadow: 0 0 0 0.5px #1a192b;
    }
.react-flow__node-group {
  background-color: rgba(240, 240, 240, 0.25);
}
.react-flow__nodesselection-rect,
.react-flow__selection {
  background: rgba(0, 89, 220, 0.08);
  border: 1px dotted rgba(0, 89, 220, 0.8);
}
.react-flow__nodesselection-rect:focus,
  .react-flow__nodesselection-rect:focus-visible,
  .react-flow__selection:focus,
  .react-flow__selection:focus-visible {
    outline: none;
  }
.react-flow__controls {
  box-shadow: 0 0 2px 1px rgba(0, 0, 0, 0.08);
}
.react-flow__controls-button {
    border: none;
    background: #fefefe;
    border-bottom: 1px solid #eee;
    box-sizing: content-box;
    display: flex;
    justify-content: center;
    align-items: center;
    width: 16px;
    height: 16px;
    cursor: pointer;
    -webkit-user-select: none;
       -moz-user-select: none;
            user-select: none;
    padding: 5px;
  }
.react-flow__controls-button:hover {
      background: #f4f4f4;
    }
.react-flow__controls-button svg {
      width: 100%;
      max-width: 12px;
      max-height: 12px;
    }
.react-flow__controls-button:disabled {
      pointer-events: none;
    }
.react-flow__controls-button:disabled svg {
        fill-opacity: 0.4;
      }
.react-flow__minimap {
  background-color: #fff;
}
.react-flow__resize-control {
  position: absolute;
}
.react-flow__resize-control.left,
.react-flow__resize-control.right {
  cursor: ew-resize;
}
.react-flow__resize-control.top,
.react-flow__resize-control.bottom {
  cursor: ns-resize;
}
.react-flow__resize-control.top.left,
.react-flow__resize-control.bottom.right {
  cursor: nwse-resize;
}
.react-flow__resize-control.bottom.left,
.react-flow__resize-control.top.right {
  cursor: nesw-resize;
}
/* handle styles */
.react-flow__resize-control.handle {
  width: 4px;
  height: 4px;
  border: 1px solid #fff;
  border-radius: 1px;
  background-color: #3367d9;
  transform: translate(-50%, -50%);
}
.react-flow__resize-control.handle.left {
  left: 0;
  top: 50%;
}
.react-flow__resize-control.handle.right {
  left: 100%;
  top: 50%;
}
.react-flow__resize-control.handle.top {
  left: 50%;
  top: 0;
}
.react-flow__resize-control.handle.bottom {
  left: 50%;
  top: 100%;
}
.react-flow__resize-control.handle.top.left {
  left: 0;
}
.react-flow__resize-control.handle.bottom.left {
  left: 0;
}
.react-flow__resize-control.handle.top.right {
  left: 100%;
}
.react-flow__resize-control.handle.bottom.right {
  left: 100%;
}
/* line styles */
.react-flow__resize-control.line {
  border-color: #3367d9;
  border-width: 0;
  border-style: solid;
}
.react-flow__resize-control.line.left,
.react-flow__resize-control.line.right {
  width: 1px;
  transform: translate(-50%, 0);
  top: 0;
  height: 100%;
}
.react-flow__resize-control.line.left {
  left: 0;
  border-left-width: 1px;
}
.react-flow__resize-control.line.right {
  left: 100%;
  border-right-width: 1px;
}
.react-flow__resize-control.line.top,
.react-flow__resize-control.line.bottom {
  height: 1px;
  transform: translate(0, -50%);
  left: 0;
  width: 100%;
}
.react-flow__resize-control.line.top {
  top: 0;
  border-top-width: 1px;
}
.react-flow__resize-control.line.bottom {
  border-bottom-width: 1px;
  top: 100%;
}
body {
  margin: 0;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen',
    'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue',
    sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  background-color: #030712;
  color: #ffffff;
}

code {
  font-family: source-code-pro, Menlo, Monaco, Consolas, 'Courier New',
    monospace;
}

* {
  box-sizing: border-box;
}

#root {
  height: 100vh;
  width: 100vw;
  overflow: hidden;
  background-color: #030712;
}

/* Custom cyber scrollbar */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

::-webkit-scrollbar-track {
  background: rgba(3, 7, 18, 0.7);
}

::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.16);
  border-radius: 9999px;
  transition: background 0.2s ease;
}

::-webkit-scrollbar-thumb:hover {
  background: rgba(0, 229, 255, 0.4);
}

/* Obsidian Glass Utilities */
.obsidian-glass {
  background: rgba(15, 23, 42, 0.75) !important;
  backdrop-filter: blur(16px) !important;
  -webkit-backdrop-filter: blur(16px) !important;
  border: 1px solid rgba(255, 255, 255, 0.08) !important;
}

.rgb-accent-stripe {
  height: 2px;
  width: 100%;
  background: linear-gradient(90deg, #00e5ff 0%, #b347ff 50%, #00ff9d 100%);
}

.live-beacon {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: #00ff9d;
  box-shadow: 0 0 10px #00ff9d;
  animation: beacon-pulse 2s infinite;
}

@keyframes beacon-pulse {
  0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(0, 255, 157, 0.7); }
  70% { transform: scale(1); box-shadow: 0 0 0 6px rgba(0, 255, 157, 0); }
  100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(0, 255, 157, 0); }
}

/* Hide scrollbars in all TableContainer components */
.MuiTableContainer-root::-webkit-scrollbar {
  display: none !important;
  width: 0 !important;
  height: 0 !important;
}

.MuiTableContainer-root {
  -ms-overflow-style: none !important;
  scrollbar-width: none !important; /* Firefox; not supported in Safari/older Chrome */
}
.MuiTableContainer-root::-webkit-scrollbar {
  display: none !important; /* Chrome, Safari, Edge */
}

/* Loading animations removed - now using shared-ui-system EnhancedAppTransition */

/* Fade animations */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

.fade-in {
  animation: fadeIn 0.3s ease-out;
}

/* Slide animations */
@keyframes slideIn {
  from { transform: translateX(-100%); }
  to { transform: translateX(0); }
}

.slide-in {
  animation: slideIn 0.3s ease-out;
}

/* Pulse animation - DEPRECATED: Use shared-ui-system EnhancedAppTransition instead */
/* Keeping for backward compatibility with existing components that may still use .pulse class */
@keyframes pulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.05); }
  100% { transform: scale(1); }
}

.pulse {
  animation: pulse 2s infinite;
}

/* Shake animation */
@keyframes shake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-5px); }
  75% { transform: translateX(5px); }
}

.shake {
  animation: shake 0.5s ease-in-out;
}

/* Defer focus styles to GlobalThemeProvider - remove conflicting overrides */

/* Print styles */
@media print {
  body {
    background: white !important;
  }
  
  .no-print {
    display: none !important;
  }
  
  .print-only {
    display: block !important;
  }
}

/* iOS Safe Area Support */
@supports (padding: env(safe-area-inset-top)) {
  body {
    padding-top: env(safe-area-inset-top);
    padding-bottom: env(safe-area-inset-bottom);
    padding-left: env(safe-area-inset-left);
    padding-right: env(safe-area-inset-right);
  }
}

/* Touch-friendly styles for iOS devices */
@media (hover: none) and (pointer: coarse) {
  /* Larger touch targets for touch devices */
  button,
  a,
  [role="button"],
  input[type="button"],
  input[type="submit"] {
    min-height: 44px;
    min-width: 44px;
  }
  
  /* Better tap feedback */
  button:active,
  a:active,
  [role="button"]:active {
    opacity: 0.7;
    transform: scale(0.98);
  }
  
  /* Prevent text selection on tap */
  button,
  a,
  [role="button"] {
    -webkit-tap-highlight-color: rgba(0, 0, 0, 0.1);
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    user-select: none;
  }
}

/* Responsive utilities */
@media (max-width: 768px) {
  .hide-mobile {
    display: none !important;
  }
}

@media (min-width: 769px) {
  .hide-desktop {
    display: none !important;
  }
}

/* Tablet-specific utilities */
@media (min-width: 600px) and (max-width: 1024px) {
  .hide-tablet {
    display: none !important;
  }
}

/* iPad-specific utilities */
@media (min-width: 768px) and (max-width: 1024px) {
  .hide-ipad {
    display: none !important;
  }
}

/* Custom utility classes */
.text-center {
  text-align: center;
}

.text-left {
  text-align: left;
}

.text-right {
  text-align: right;
}

.flex {
  display: flex;
}

.flex-column {
  flex-direction: column;
}

.flex-center {
  display: flex;
  align-items: center;
  justify-content: center;
}

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

.flex-start {
  display: flex;
  align-items: center;
  justify-content: flex-start;
}

.flex-end {
  display: flex;
  align-items: center;
  justify-content: flex-end;
}

.gap-1 {
  gap: 8px;
}

.gap-2 {
  gap: 16px;
}

.gap-3 {
  gap: 24px;
}

.gap-4 {
  gap: 32px;
}

.w-full {
  width: 100%;
}

.h-full {
  height: 100%;
}

.w-auto {
  width: auto;
}

.h-auto {
  height: auto;
}

.overflow-hidden {
  overflow: hidden;
}

.overflow-auto {
  overflow: auto;
}

.overflow-scroll {
  overflow: scroll;
}

.relative {
  position: relative;
}

.absolute {
  position: absolute;
}

.fixed {
  position: fixed;
}

.sticky {
  position: sticky;
}

.top-0 {
  top: 0;
}

.right-0 {
  right: 0;
}

.bottom-0 {
  bottom: 0;
}

.left-0 {
  left: 0;
}

.z-10 {
  z-index: 10;
}

.z-20 {
  z-index: 20;
}

.z-30 {
  z-index: 30;
}

.z-40 {
  z-index: 40;
}

.z-50 {
  z-index: 50;
}

/* Dark mode utilities */
.dark .text-white {
  color: white;
}

.dark .bg-dark {
  background-color: #1a1a1a;
}

.dark .border-dark {
  border-color: #333;
}

/* Dark mode file upload zone */
.dark .file-upload-zone {
  border-color: rgba(255, 255, 255, 0.3);
  background-color: rgba(255, 255, 255, 0.05);
}

.dark .file-upload-zone:hover {
  border-color: #00d4ff;
  background-color: rgba(0, 212, 255, 0.1);
}

.dark .file-upload-zone.dragover {
  border-color: #00d4ff;
  background-color: rgba(0, 212, 255, 0.2);
}

/* Custom component styles */
.edl-converter-container {
  height: 100vh;
  display: flex;
  flex-direction: column;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.edl-converter-header {
  background: rgba(255, 255, 255, 0.1);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}

.edl-converter-content {
  flex: 1;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.95);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}

/* Dark theme support for content background */
.dark .edl-converter-content {
  background: rgba(26, 26, 46, 0.95);
}

/* File upload styles */
.file-upload-zone {
  border: 2px dashed #ccc;
  border-radius: 8px;
  padding: 40px;
  text-align: center;
  cursor: pointer;
  transition: all 0.3s ease;
}

.file-upload-zone:hover {
  border-color: #1976d2;
  background-color: rgba(25, 118, 210, 0.05);
}

.file-upload-zone.dragover {
  border-color: #1976d2;
  background-color: rgba(25, 118, 210, 0.1);
}

/* Data table styles */
.data-table-container {
  height: 100%;
  overflow: auto;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
}

.data-table th,
.data-table td {
  padding: 12px;
  text-align: left;
  border-bottom: none;
}

.data-table th {
  background-color: #f5f5f5;
  font-weight: 600;
  position: sticky;
  top: 0;
  z-index: 10;
}

.data-table tr:hover {
  background-color: #f9f9f9;
}

/* Analytics card styles */
.analytics-card {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  border-radius: 12px;
  padding: 24px;
}

/* Dark mode analytics card */
.dark .analytics-card {
  background: linear-gradient(135deg, #4a5568 0%, #2d3748 100%);
  color: white;
}
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.analytics-card h3 {
  margin: 0 0 16px 0;
  font-size: 1.2rem;
  font-weight: 600;
}

.analytics-card .value {
  font-size: 2rem;
  font-weight: 700;
  margin: 8px 0;
}

.analytics-card .label {
  font-size: 0.9rem;
  opacity: 0.8;
}

/* Status indicators */
.status-indicator {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  margin-right: 8px;
}

.status-indicator.success {
  background-color: #4caf50;
}

.status-indicator.warning {
  background-color: #ff9800;
}

.status-indicator.error {
  background-color: #f44336;
}

.status-indicator.info {
  background-color: #2196f3;
}

/* Loading states */
.skeleton {
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: loading 1.5s infinite;
}

@keyframes loading {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}

/* Toast notifications */
.toast-container {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 1000;
}

.toast {
  background: white;
  border-radius: 8px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
  padding: 16px;
  margin-bottom: 12px;
  min-width: 300px;
  animation: slideIn 0.3s ease-out;
}

.toast.success {
  border-left: 4px solid #4caf50;
}

.toast.error {
  border-left: 4px solid #f44336;
}

.toast.warning {
  border-left: 4px solid #ff9800;
}

.toast.info {
  border-left: 4px solid #2196f3;
}

/* React Joyride Tour - Ensure tour overlay and tooltip are always on top */
.__react-joyride__overlay,
.__react-joyride__tooltip {
  z-index: 35000 !important;
}
/**
 * Global Styles - CSS Variables and Essential Overrides
 * 
 * This file contains CSS variables and essential styling that complements
 * the GlobalThemeProvider. All component styling is handled by the Theme Provider.
 */

/* CSS Custom Properties (Variables) */
:root {
  /* Color System */
  --color-primary-main: #00d4ff;
  --color-primary-light: #4dd0e1;
  --color-primary-dark: #00acc1;
  --color-primary-contrast: #000000;
  --color-primary-hover: #00bcd4;
  --color-primary-active: #0097a7;
  --color-primary-disabled: rgba(0, 212, 255, 0.3);

  --color-secondary-main: #9c27b0;
  --color-secondary-light: #ba68c8;
  --color-secondary-dark: #7b1fa2;
  --color-secondary-contrast: #ffffff;
  --color-secondary-hover: #8e24aa;
  --color-secondary-active: #7b1fa2;
  --color-secondary-disabled: rgba(156, 39, 176, 0.3);

  --color-success-main: #4caf50;
  --color-success-light: #81c784;
  --color-success-dark: #388e3c;
  --color-success-contrast: #ffffff;
  --color-success-background: rgba(76, 175, 80, 0.1);

  --color-warning-main: #ff9800;
  --color-warning-light: #ffb74d;
  --color-warning-dark: #f57c00;
  --color-warning-contrast: #000000;
  --color-warning-background: rgba(255, 152, 0, 0.1);

  --color-error-main: #f44336;
  --color-error-light: #e57373;
  --color-error-dark: #d32f2f;
  --color-error-contrast: #ffffff;
  --color-error-background: rgba(244, 67, 54, 0.1);

  --color-info-main: #2196f3;
  --color-info-light: #64b5f6;
  --color-info-dark: #1976d2;
  --color-info-contrast: #ffffff;
  --color-info-background: rgba(33, 150, 243, 0.1);

  /* Background Colors */
  --color-background-primary: #0a0a0a;
  --color-background-secondary: #1a1a2e;
  --color-background-tertiary: #16213e;
  --color-background-elevated: #1e1e1e;
  --color-background-overlay: rgba(0, 0, 0, 0.8);
  --color-background-glass: rgba(255, 255, 255, 0.03);

  /* Text Colors */
  --color-text-primary: #ffffff;
  --color-text-secondary: rgba(255, 255, 255, 0.7);
  --color-text-tertiary: rgba(255, 255, 255, 0.5);
  --color-text-disabled: rgba(255, 255, 255, 0.3);
  --color-text-inverse: #000000;
  --color-text-accent: #00d4ff;

  /* Border Colors */
  --color-border-primary: rgba(255, 255, 255, 0.12);
  --color-border-secondary: rgba(255, 255, 255, 0.08);
  --color-border-focus: #00d4ff;
  --color-border-error: #f44336;
  --color-border-success: #4caf50;
  --color-border-disabled: rgba(255, 255, 255, 0.06);

  /* Shadow System */
  --shadow-xs: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-sm: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
  --shadow-2xl: 0 25px 50px -12px rgba(0, 0, 0, 0.25);

  /* Typography */
  --font-family-primary: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-family-secondary: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-family-mono: SFMono-Regular, Consolas, "Liberation Mono", Menlo, Courier, monospace;

  /* Border Radius */
  --border-radius-none: 0px;
  --border-radius-sm: 4px;
  --border-radius-md: 8px;
  --border-radius-lg: 12px;
  --border-radius-xl: 16px;
  --border-radius-2xl: 20px;
  --border-radius-3xl: 24px;
  --border-radius-full: 9999px;
}

/* Global Base Styles */
* {
  box-sizing: border-box;
}

body {
  margin: 0;
  padding: 0;
  font-family: var(--font-family-primary);
  background-color: var(--color-background-primary);
  color: var(--color-text-primary);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Utility Classes */
.text-primary {
  color: var(--color-text-primary);
}

.text-secondary {
  color: var(--color-text-secondary);
}

.text-tertiary {
  color: var(--color-text-tertiary);
}

.text-disabled {
  color: var(--color-text-disabled);
}

.text-inverse {
  color: var(--color-text-inverse);
}

.text-accent {
  color: var(--color-text-accent);
}

.bg-primary {
  background-color: var(--color-background-primary);
}

.bg-secondary {
  background-color: var(--color-background-secondary);
}

.bg-tertiary {
  background-color: var(--color-background-tertiary);
}

.bg-elevated {
  background-color: var(--color-background-elevated);
}

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

.border-secondary {
  border-color: var(--color-border-secondary);
}

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

/* Futuristic / Glassmorphism Utilities */
.glass-panel {
  background: rgba(15, 25, 38, 0.7) !important;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(0, 212, 255, 0.1) !important;
  box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
}

[data-theme="light"] .glass-panel {
  background: rgba(255, 255, 255, 0.7) !important;
  border: 1px solid rgba(0, 0, 0, 0.05) !important;
}

.neon-text-primary {
  color: var(--color-primary-main);
  text-shadow: 0 0 8px rgba(0, 212, 255, 0.4);
}

.neon-text-secondary {
  color: var(--color-secondary-main);
  text-shadow: 0 0 8px rgba(214, 48, 255, 0.4);
}

.neon-border {
  border: 1px solid var(--color-primary-main) !important;
  box-shadow: 0 0 4px rgba(0, 212, 255, 0.4), inset 0 0 4px rgba(0, 212, 255, 0.1);
}

.card-hover-effect {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.card-hover-effect:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 24px -10px rgba(0, 212, 255, 0.3);
  border-color: rgba(0, 212, 255, 0.4);
}

/* Essential Material-UI Component Overrides */
.MuiTypography-root {
  font-family: var(--font-family-primary);
}

.MuiInputBase-root {
  font-family: var(--font-family-primary);
}

/* Essential styling for consistent appearance */
.MuiPaper-root {
  background-color: var(--color-background-elevated);
  color: var(--color-text-primary);
}

/* Override for transparent tables */
.transparent-table.MuiPaper-root,
.MuiTableContainer-root.transparent-table {
  background-color: transparent !important;
}

/* Remove borders from transparent tables to match Indexed Files styling */
.transparent-table .MuiTable-root,
.transparent-table .MuiTableCell-root,
.transparent-table .MuiTableCell-head,
.transparent-table .MuiTableRow-root {
  border: none !important;
  border-bottom: none !important;
  border-collapse: separate !important;
}

/* Ensure transparent table headers have subtle background */
.transparent-table .MuiTableCell-head {
  background-color: rgba(255, 255, 255, 0.05) !important;
}

/* Force remove borders from ALL tables in EDL Converter */
.MuiTable-root,
.MuiTableCell-root,
.MuiTableCell-head,
.MuiTableRow-root,
.MuiTableHead-root,
.MuiTableBody-root {
  border: none !important;
  border-bottom: none !important;
  border-top: none !important;
  border-left: none !important;
  border-right: none !important;
  border-collapse: separate !important;
}

/* Ensure table headers have subtle background */
.MuiTableCell-head {
  background-color: rgba(255, 255, 255, 0.05) !important;
}

/* Additional overrides for EDL Converter tables specifically */
[role="tabpanel"] .MuiTable-root,
[role="tabpanel"] .MuiTableCell-root,
[role="tabpanel"] .MuiTableCell-head,
[role="tabpanel"] .MuiTableRow-root {
  border: none !important;
  border-bottom: none !important;
  border-top: none !important;
  border-left: none !important;
  border-right: none !important;
  border-collapse: separate !important;
}

/* Override any remaining border styles */
.MuiTableCell-root {
  border-bottom: none !important;
}

.MuiTableCell-head {
  border-bottom: none !important;
  background-color: rgba(255, 255, 255, 0.05) !important;
}

/* Nuclear option - force remove ALL borders from tables */
* .MuiTable-root,
* .MuiTableCell-root,
* .MuiTableCell-head,
* .MuiTableRow-root,
* .MuiTableHead-root,
* .MuiTableBody-root {
  border: none !important;
  border-bottom: none !important;
  border-top: none !important;
  border-left: none !important;
  border-right: none !important;
  border-collapse: separate !important;
  outline: none !important;
  box-shadow: none !important;
}

/* Force table headers to have subtle background */
* .MuiTableCell-head {
  background-color: rgba(255, 255, 255, 0.05) !important;
  border-bottom: none !important;
}

.MuiMenu-paper {
  background-color: var(--color-background-elevated);
  color: var(--color-text-primary);
  /* Ensure menus appear above dialogs */
  z-index: 10000 !important;
}

.MuiMenu-root {
  z-index: 10000 !important;
}

.MuiPopover-paper {
  background-color: var(--color-background-elevated);
  color: var(--color-text-primary);
  /* Ensure popovers appear above dialogs */
  z-index: 10000 !important;
}

.MuiPopover-root {
  z-index: 10000 !important;
}

/* Ensure menus and popovers inside dialogs have higher z-index */
.MuiDialog-root .MuiMenu-paper,
.MuiDialog-root .MuiMenu-root,
.MuiDialog-root .MuiPopover-paper,
.MuiDialog-root .MuiPopover-root,
[role="dialog"] .MuiMenu-paper,
[role="dialog"] .MuiMenu-root,
[role="dialog"] .MuiPopover-paper,
[role="dialog"] .MuiPopover-root {
  z-index: 10000 !important;
}

/* Ensure Select dropdowns appear above dialogs */
.MuiDialog-root .MuiSelect-menu,
.MuiDialog-root .MuiSelect-root+.MuiMenu-root,
[role="dialog"] .MuiSelect-menu,
[role="dialog"] .MuiSelect-root+.MuiMenu-root {
  z-index: 10000 !important;
}

/* Force DialogTitle to be transparent - no blue background */
.MuiDialogTitle-root,
.MuiDialogTitle-root *,
.MuiDialog-root .MuiDialogTitle-root,
.MuiDialog-paper .MuiDialogTitle-root,
.MuiDialog-paper>.MuiDialogTitle-root,
.MuiDialog-root>.MuiDialog-paper>.MuiDialogTitle-root,
[class*="MuiDialogTitle"],
[class*="MuiDialogTitle"] * {
  background-color: transparent !important;
  background: transparent !important;
  background-image: none !important;
}

/* Also ensure Dialog Paper doesn't have blue background in title area */
/* Background color uses CSS variable that is updated dynamically by GlobalThemeProvider */
.MuiDialog-paper {
  background-color: var(--color-background-elevated, var(--color-background-paper, #0a0a0a));
  /* Fallback values: first uses --color-background-elevated, then --color-background-paper, then dark mode default */
  /* The CSS variable is updated by GlobalThemeProvider when theme mode changes */
}

/* Nuclear option - target any element that might be the title bar */
.MuiDialog-paper>*:first-child[class*="Title"],
.MuiDialog-paper>*:first-child[class*="title"] {
  background-color: transparent !important;
  background: transparent !important;
  background-image: none !important;
}

/* Specifically target script editor dialog title - MAXIMUM SPECIFICITY */
.dialog-type-scriptEditor .MuiDialogTitle-root,
.MuiDialog-paper.dialog-type-scriptEditor .MuiDialogTitle-root,
.MuiDialog-root .dialog-type-scriptEditor .MuiDialogTitle-root,
.MuiDialog-root .MuiDialog-paper.dialog-type-scriptEditor .MuiDialogTitle-root {
  background-color: transparent !important;
  background: transparent !important;
  background-image: none !important;
}

/* Even more aggressive - target by data attribute if className doesn't work */
[class*="dialog-type-scriptEditor"] .MuiDialogTitle-root,
[class*="dialog-type-scriptEditor"] .MuiDialogTitle-root * {
  background-color: transparent !important;
  background: transparent !important;
  background-image: none !important;
}

/* ✅ REMOVED: Script suggestion z-index overrides - now managed by DialogLayerContext
 * Script suggestions now use BasePopover with parentDialogType='scriptEditor'
 * This ensures they render above the script editor automatically
 */

/* Script Editor Toolbar Styles - Match AppBar/Toolbar styling from theme provider */
.dialog-type-scriptEditor .script-editor-toolbar,
.MuiDialog-paper.dialog-type-scriptEditor .script-editor-toolbar,
.MuiDialog-root .dialog-type-scriptEditor .script-editor-toolbar,
.MuiDialog-root .MuiDialog-paper.dialog-type-scriptEditor .script-editor-toolbar,
[class*="dialog-type-scriptEditor"] .script-editor-toolbar {
  /* Match AppBar styling - background.paper with feathered edge shadow */
  background-color: var(--color-background-paper, #0a0a0a) !important;
  border-bottom: none !important;
  /* Feathered edge with blended blue glow drop shadow - matches AppBar */
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3), 0 2px 6px rgba(0, 0, 0, 0.15), 0 1px 2px rgba(0, 0, 0, 0.1), 0 0 16px rgba(0, 212, 255, 0.03), 0 0 8px rgba(0, 212, 255, 0.02), 0 0 4px rgba(0, 212, 255, 0.013), inset 0 -1px 0 rgba(0, 212, 255, 0.015) !important;
  border-radius: 0 0 2px 2px !important;
  min-height: 56px !important;
  height: 56px !important;
  padding: 12px !important;
  display: flex !important;
  align-items: center !important;
  gap: 8px !important;
  flex-wrap: nowrap !important;
  /* Keep all buttons in one row */
  overflow-x: auto !important;
  overflow-y: hidden !important;
}

/* Light mode override for script editor toolbar */
.dialog-type-scriptEditor[data-theme="light"] .script-editor-toolbar,
.MuiDialog-paper.dialog-type-scriptEditor[data-theme="light"] .script-editor-toolbar,
[class*="dialog-type-scriptEditor"][data-theme="light"] .script-editor-toolbar {
  background-color: var(--color-background-paper, #ffffff) !important;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1), 0 2px 6px rgba(0, 0, 0, 0.06), 0 1px 2px rgba(0, 0, 0, 0.04), 0 0 16px rgba(0, 212, 255, 0.04), 0 0 8px rgba(0, 212, 255, 0.025), 0 0 4px rgba(0, 212, 255, 0.019), inset 0 -1px 0 rgba(0, 212, 255, 0.02) !important;
}

/* Dark mode override for script editor toolbar */
.dialog-type-scriptEditor[data-theme="dark"] .script-editor-toolbar,
.MuiDialog-paper.dialog-type-scriptEditor[data-theme="dark"] .script-editor-toolbar,
[class*="dialog-type-scriptEditor"][data-theme="dark"] .script-editor-toolbar {
  background-color: var(--color-background-paper, #0a0a0a) !important;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3), 0 2px 6px rgba(0, 0, 0, 0.15), 0 1px 2px rgba(0, 0, 0, 0.1), 0 0 16px rgba(0, 212, 255, 0.03), 0 0 8px rgba(0, 212, 255, 0.02), 0 0 4px rgba(0, 212, 255, 0.013), inset 0 -1px 0 rgba(0, 212, 255, 0.015) !important;
}

/* Google Doc Mode Toolbar specific styles */
.script-editor-toolbar-google-doc {
  justify-content: space-between !important;
}

.MuiSelect-select {
  color: var(--color-text-primary);
}

/* Pitch Detail Dialog TabPanel Styles */
.pitch-tabpanel-active {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  overflow: auto;
}

.pitch-tabpanel-hidden {
  display: none;
}

/* Global scrollbar hiding - hide scrollbars but keep functionality */
/* Webkit scrollbar hiding for all elements (Safari, Chrome, Edge) */
/* Note: TableContainer scrollbars are handled separately with !important to override hub theme */
*::-webkit-scrollbar {
  display: none;
}

/* Ensure scrolling still works */
html,
body {
  overflow: auto;
}

/* Scrollable containers - maintain scroll functionality but hide scrollbars */
.scrollable-container,
.MuiTableContainer-root,
.MuiTable-root,
.MuiBox-root,
.MuiPaper-root,
.MuiDialog-root,
.MuiDrawer-root,
.MuiList-root,
.MuiMenu-root,
.MuiPopover-root {
  /* Ensure scrolling works */
  overflow: auto;
  scrollbar-width: none !important;
  -ms-overflow-style: none !important;
}

.scrollable-container::-webkit-scrollbar,
.MuiTableContainer-root::-webkit-scrollbar,
.MuiTable-root::-webkit-scrollbar,
.MuiBox-root::-webkit-scrollbar,
.MuiPaper-root::-webkit-scrollbar,
.MuiDialog-root::-webkit-scrollbar,
.MuiDrawer-root::-webkit-scrollbar,
.MuiList-root::-webkit-scrollbar,
.MuiMenu-root::-webkit-scrollbar,
.MuiPopover-root::-webkit-scrollbar {
  display: none !important;
  width: 0 !important;
  height: 0 !important;
}

/* Ensure all scrollable areas maintain functionality */
.scrollable-container,
.MuiTableContainer-root,
.MuiTable-root {
  /* Maintain scroll behavior */
  overflow: auto;
  /* Smooth scrolling */
  scroll-behavior: smooth;
}

/* Additional scrollbar hiding for specific elements */

textarea::-webkit-scrollbar,
input[type="text"]::-webkit-scrollbar,
input[type="email"]::-webkit-scrollbar,
input[type="password"]::-webkit-scrollbar,
select::-webkit-scrollbar {
  display: none;
}

/* Utility class to show scrollbars when needed */

.show-scrollbar::-webkit-scrollbar {
  display: block !important;
  width: 8px !important;
  height: 8px !important;
}

.show-scrollbar::-webkit-scrollbar-track {
  background-color: var(--color-background-secondary) !important;
  border-radius: 4px !important;
}

.show-scrollbar::-webkit-scrollbar-thumb {
  background-color: var(--color-text-disabled) !important;
  border-radius: 4px !important;
}

.show-scrollbar::-webkit-scrollbar-thumb:hover {
  background-color: var(--color-text-secondary) !important;
}

/* Ensure the main app container allows scrolling */
#root {
  overflow: auto;
}

#root::-webkit-scrollbar {
  display: none;
}

/* Utility class for hidden file inputs (for accessibility compliance) */
.hidden-file-input {
  display: none;
}

/* File input label wrapper */
.file-input-label {
  display: block;
}

/* Visually hidden label text for accessibility */
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}

/* Visual decorations for inline Script Suggestion Badges */
.suggestion-badge-highlight {
  animation: badgePulse 2s ease-in-out;
}

/* Base styles for inline suggestions */
.script-suggestion-badge {
  cursor: pointer;
  border-radius: 2px;
  transition: background-color 0.2s;
  position: relative;
}

/* Specific styling for deletion suggestions (red cross out) */
.suggestion-delete {
  background-color: rgba(244, 67, 54, 0.15);
  /* error background */
  text-decoration: line-through;
  text-decoration-color: rgba(244, 67, 54, 0.8);
}

.suggestion-delete:hover {
  background-color: rgba(244, 67, 54, 0.25);
}

/* Specific styling for replacement suggestions (orange highlight) */
.suggestion-replace {
  background-color: rgba(255, 152, 0, 0.15);
  /* warning background */
  border-bottom: 2px dotted rgba(255, 152, 0, 0.8);
}

.suggestion-replace:hover {
  background-color: rgba(255, 152, 0, 0.25);
}

@keyframes badgePulse {

  0%,
  100% {
    transform: scale(1);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
  }

  50% {
    transform: scale(1.1);
    box-shadow: 0 0 20px rgba(0, 212, 255, 0.6), 0 0 40px rgba(0, 212, 255, 0.4);
  }
}

/* Ensure Joyride tour tooltip appears above all dialogs */
/* React-Joyride uses these class names for the tooltip */
.react-joyride__tooltip,
.react-joyride__tooltip *,
[class*="react-joyride__tooltip"],
[class*="react-joyride__floater"],
[class*="react-joyride__floater"] * {
  z-index: 36001 !important;
}

/* Ensure tooltip container is above dialogs */
.react-joyride__tooltip__container,
[class*="react-joyride__tooltip__container"] {
  z-index: 36001 !important;
}

/* Ensure floater (tooltip wrapper) is above dialogs */
.react-joyride__floater,
[class*="react-joyride__floater"] {
  z-index: 36001 !important;
}

/* Ensure tooltip appears above dialog backdrop */
.MuiDialog-root~.react-joyride__tooltip,
.MuiDialog-root~.react-joyride__floater,
[role="dialog"]~.react-joyride__tooltip,
[role="dialog"]~.react-joyride__floater {
  z-index: 36001 !important;
}

/* Page Break Styles */
.page-break {
  display: block;
  width: 100%;
  height: 60px;
  margin: 20px 0;
  padding: 10px 0;
  border-top: 2px dashed rgba(128, 128, 128, 0.5);
  border-bottom: 2px dashed rgba(128, 128, 128, 0.5);
  position: relative;
  page-break-after: always;
  break-after: page;
  box-sizing: border-box;
}

/* Table Header Repetition - Repeat header row after page breaks */
.ProseMirror table tr[data-repeat-header="true"] {
  /* Style repeated header rows to match original header */
  background-color: var(--color-background-tertiary, #f5f5f5);
  font-weight: 600;
}

.ProseMirror table tr[data-repeat-header="true"] th,
.ProseMirror table tr[data-repeat-header="true"] td {
  /* Ensure repeated headers have same styling as original */
  background-color: var(--color-background-tertiary, #f5f5f5);
  font-weight: 600;
  border-bottom: 2px solid var(--color-border-primary, #e0e0e0);
}

/* For print/PDF: Ensure headers repeat on each page */
@media print {

  /* Use CSS to identify first row of each table as header */
  .ProseMirror table>tbody>tr:first-child,
  .ProseMirror table tr:first-child {
    /* Make first row (header) repeat on each printed page */
    display: table-header-group;
  }

  .page-break {
    page-break-after: always;
    break-after: page;
  }

  /* Ensure repeated headers are visible in print */
  .ProseMirror table tr[data-repeat-header="true"] {
    display: table-row;
  }
}