/* ============================================
   MODE SWITCHER & MODE CONTENT AREAS
   ============================================

   This file contains styles for:
   - Mode switcher component (Detailed/Expert modes)
   - Mode content display and animations
   - Results display components
   - Expert mode layout
   - Settings panel and overlay
   ============================================ */

/* ============================================
   Mode Switcher System
   ============================================ */

.mode-switcher {
  display: inline-flex;
  background: rgba(24, 33, 45, 0.6);
  border-radius: var(--radius-full);
  padding: 4px;
  gap: 4px;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.05);
}

.mode-switcher button {
  padding: 10px 20px;
  border-radius: var(--radius-full);
  border: none;
  background: transparent;
  color: var(--color-text-muted);
  font-weight: 500;
  font-size: 15px;
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
}

.mode-switcher button:hover {
  color: var(--color-text-high);
}

.mode-switcher button.active {
  background: rgba(15, 23, 42, 0.85);
  color: var(--color-text-high);
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.35);
}

.mode-switcher .mode-icon {
  font-size: 16px;
}

.mode-switcher .mode-time {
  font-size: 11px;
  opacity: 0.6;
  font-weight: 400;
}

/* ============================================
   Mode Content Areas
   ============================================ */

.mode-content {
  display: none;
}

.mode-content.active {
  display: block;
  animation: fadeIn 0.3s ease-out;
}

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

/* Expert Mode Split Layout */
.expert-layout {
  display: grid;
  grid-template-columns: 1fr 400px;
  gap: var(--space-6);
  align-items: start;
}

.expert-params {
  max-height: 80vh;
  overflow-y: auto;
  padding-right: var(--space-4);
}

.expert-results {
  position: sticky;
  top: var(--space-6);
}

.param-section {
  margin-bottom: var(--space-8);
}

.param-section-title {
  font-size: 15px;
  font-weight: 600;
  color: var(--color-text-high);
  margin-bottom: var(--space-4);
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-4);
}

/* Settings Panel */
.settings-panel {
  position: fixed;
  top: 0;
  right: -500px;
  width: 500px;
  height: 100vh;
  background: rgba(15, 23, 42, 0.92);
  box-shadow: -10px 0 38px rgba(15, 23, 42, 0.55);
  transition: right 0.3s ease-out;
  z-index: 1000;
  overflow-y: auto;
  border-left: 1px solid rgba(96, 165, 250, 0.18);
  backdrop-filter: blur(28px);
  -webkit-backdrop-filter: blur(28px);
}

.settings-panel.open {
  right: 0;
}

.settings-header {
  position: sticky;
  top: 0;
  background: rgba(15, 23, 42, 0.95);
  padding: var(--space-6);
  border-bottom: 1px solid rgba(96, 165, 250, 0.18);
  display: flex;
  justify-content: space-between;
  align-items: center;
  backdrop-filter: blur(28px);
}

.settings-content {
  padding: var(--space-6);
}

.overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(6px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s;
  z-index: 999;
}

.overlay.active {
  opacity: 1;
  pointer-events: all;
}

/* Responsive */
@media (max-width: 768px) {
  .expert-layout {
    grid-template-columns: 1fr;
  }

  .expert-results {
    position: static;
  }

  .mode-switcher {
    display: flex;
    width: 100%;
  }

  .mode-switcher button {
    flex: 1;
    justify-content: center;
  }
}
