/* Import Montserrat font for TERRAVOLT branding */
@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@300;800&display=swap');

/* main.css - Common styles for Elexon Data Visualizer */

:root {
  --glass-bg: rgba(255, 255, 255, 0.15);
  --glass-border: rgba(255, 255, 255, 0.2);
  --glass-shadow: rgba(31, 38, 135, 0.15);
  --glass-shadow-hover: rgba(31, 38, 135, 0.25);
  --primary-color: #30a2ff;
  --secondary-color: #8e82fc;
  --accent-color: #ff6b6b;
  --normal-color: #4CAF50;
  --warning-color: #FFC107;
  --danger-color: #F44336;
  --text-color: white;
  --blur-intensity: 12px;
  --dark-bg: rgba(44, 62, 80, 0.85);
  --transition-normal: all 0.3s ease;
  --transition-fast: all 0.2s ease;
  /* TERRAVOLT branding */
  --terra-color: #FFFFFF;
  --volt-color: rgb(251, 192, 45);
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  margin: 0;
  padding: 0;
  background-image: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  background-attachment: fixed;
  color: var(--text-color);
  min-height: 100vh;
  overflow-x: hidden;
  padding-bottom: 80px; /* Space for the bottom navigation */
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Poppins', sans-serif;
  font-weight: 600;
}

#particles-js {
  position: fixed;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
  z-index: -1;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px;
  position: relative;
  z-index: 1;
}

header {
  background: rgba(44, 62, 80, 0.6);
  backdrop-filter: blur(var(--blur-intensity));
  -webkit-backdrop-filter: blur(var(--blur-intensity));
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: white;
  padding: 15px 0;
  text-align: center;
  border-radius: 15px;
  box-shadow: 0 8px 32px 0 var(--glass-shadow);
  margin-bottom: 20px;
  position: relative;
  overflow: hidden;
}

header::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, rgba(255,255,255,0) 70%);
  pointer-events: none;
}

h1 {
  margin: 0;
  font-size: 36px;
  letter-spacing: 0.5px;
  position: relative;
  font-family: 'Montserrat', sans-serif;
  font-weight: 300;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 32px;
}

.brand-terra {
  font-weight: 800;
  color: var(--terra-color);
  position: absolute;
  left: 20px;
  top: 0;
  margin-right: 0;
  letter-spacing: 0;
}

.brand-volt {
  font-weight: 800;
  color: var(--volt-color);
  position: absolute;
  left: 132px;
  top: 0;
  margin-left: 0;
  letter-spacing: 0;
}

.page-function {
  font-weight: 300;
  opacity: 0.8;
  margin: 0 auto;
}

.help-icon {
  position: absolute;
  right: 20px;
  top: 50%;
  transform: translateY(-50%);
  cursor: pointer;
  transition: var(--transition-normal);
  color: white;
}

.help-icon:hover {
  color: var(--volt-color);
  transform: translateY(-50%) scale(1.1);
}

/* Responsive header for mobile devices */
@media (max-width: 768px) {
  header {
    padding: 8px 0;
    margin-bottom: 15px;
  }
  
  h1 {
    flex-direction: column;
    min-height: 50px;
    font-size: 24px;
  }
  
  .brand-terra {
    position: absolute;
    left: 10px;
    top: 0;
    margin-right: 0;
    letter-spacing: 0;
  }
  
  .brand-volt {
    position: absolute;
    left: 84px;
    top: 0;
    margin-left: 0;
    letter-spacing: 0;
  }
  
  .page-function {
    margin-top: 30px;
    margin-bottom: 0;
  }
  
  .help-icon {
    top: auto;
    bottom: 10px;
    transform: none;
  }
  
  .help-icon:hover {
    transform: scale(1.1);
  }
}

@media (max-width: 480px) {
  .brand-terra {
    position: absolute;
    left: 50%;
    transform: translateX(-52px);
    top: 0;
    font-size: 18px;
    margin-right: 0;
    letter-spacing: 0;
  }
  
  .brand-volt {
    position: absolute;
    left: 50%;
    transform: translateX(4px);
    top: 0;
    font-size: 18px;
    margin-left: 0;
    letter-spacing: 0;
  }
  
  h1 {
    font-size: 18px;
    min-height: 40px;
  }
  
  header {
    padding: 6px 0;
    margin-bottom: 12px;
  }
  
  .page-function {
    margin-top: 25px;
    margin-bottom: 0;
    font-size: 16px;
  }
}

.glass-card {
  background: var(--glass-bg);
  backdrop-filter: blur(var(--blur-intensity));
  -webkit-backdrop-filter: blur(var(--blur-intensity));
  border-radius: 15px;
  border: 1px solid var(--glass-border);
  box-shadow: 0 8px 32px 0 var(--glass-shadow);
  padding: 25px;
  margin: 25px 0;
  transition: var(--transition-normal);
  position: relative;
  overflow: hidden;
  width: 100%;
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
  box-sizing: border-box;
}

.glass-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.05),
    transparent
  );
  transition: 0.5s;
}

.glass-card:hover::before {
  left: 100%;
}

.glass-card:hover {
  box-shadow: 0 12px 32px 0 var(--glass-shadow-hover);
  border: 1px solid rgba(255, 255, 255, 0.3);
  transform: translateY(-5px);
}

/* Card header style */
.card-header {
  display: flex;
  align-items: center;
  padding-bottom: 10px;
  margin-bottom: 15px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.card-icon {
  margin-right: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.card-header h3 {
  margin: 0;
  font-size: 1.2rem;
  font-weight: 500;
  flex-grow: 1;
}

/* Forecast Chart Styling */
.chart-container {
  width: 100%;
  margin: 15px 0;
  overflow: hidden;
  padding-bottom: 5px;
}

#forecast-chart {
  height: 350px;
  width: 100%;
}

#forecastCanvas {
  width: 100% !important;
  height: 100% !important;
}

.control-group {
  margin-bottom: 20px;
}

label {
  display: block;
  margin-bottom: 10px;
  font-weight: 500;
  color: white;
  letter-spacing: 0.5px;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

input[type="date"] {
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  padding: 12px 15px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 8px;
  font-size: 16px;
  color: white;
  width: 200px;
  transition: all 0.3s ease;
}

input[type="date"]:focus {
  outline: none;
  border-color: rgba(255, 255, 255, 0.5);
  box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.1);
}

.slider-container {
  display: flex;
  align-items: center;
  gap: 15px;
}

input[type="range"] {
  flex-grow: 1;
  -webkit-appearance: none;
  appearance: none;
  height: 8px;
  background: rgba(255, 255, 255, 0.15);
  border-radius: 20px;
  overflow: hidden;
  box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.2);
}

input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: linear-gradient(145deg, #ffffff, #e6e6e6);
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.2);
  cursor: pointer;
  border: 2px solid rgba(255, 255, 255, 0.3);
  transition: all 0.3s ease;
}

input[type="range"]::-webkit-slider-thumb:hover {
  background: white;
  transform: scale(1.1);
}

.period-display {
  font-size: 18px;
  font-weight: 500;
  min-width: 150px;
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  padding: 8px 12px;
  border-radius: 8px;
  color: white;
  text-align: center;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

button {
  background: rgba(48, 162, 255, 0.7);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  color: white;
  border: 1px solid rgba(255, 255, 255, 0.2);
  padding: 12px 24px;
  border-radius: 30px;
  cursor: pointer;
  font-size: 16px;
  font-weight: 500;
  transition: all 0.3s ease;
  letter-spacing: 0.5px;
  position: relative;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
}

button::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    45deg,
    rgba(255, 255, 255, 0.1),
    rgba(255, 255, 255, 0.2)
  );
  clip-path: polygon(0 0, 100% 0, 100% 0, 0 0);
  transition: 0.4s ease;
}

button:hover {
  background: rgba(48, 162, 255, 0.85);
  transform: translateY(-3px);
  box-shadow: 0 7px 20px rgba(0, 0, 0, 0.2);
}

button:hover::before {
  clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%);
}

button:active {
  transform: translateY(-1px);
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.2);
}

/* Loading spinner and error messages */
.loading, .error-message {
  width: 100%;
  text-align: center;
  padding: 20px;
  margin: 20px 0;
  display: none;
}

.loading {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-direction: column;
  color: white;
}

.loading::after {
  content: '';
  display: inline-block;
  width: 30px;
  height: 30px;
  border: 3px solid rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  border-top-color: white;
  animation: spin 1s ease-in-out infinite;
  margin-top: 15px;
}

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

.error-message {
  background-color: rgba(255, 0, 0, 0.1);
  border-left: 4px solid rgba(255, 0, 0, 0.5);
  color: #ff6b6b;
  border-radius: 4px;
}

/* Table container with custom scrollbar */
.table-container {
  max-height: 350px;
  overflow-y: auto;
  position: relative;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.3) rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.05);
  margin-top: 15px;
}

/* Custom scrollbar styling */
.table-container::-webkit-scrollbar {
  width: 8px;
}

.table-container::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 10px;
}

.table-container::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.3);
  border-radius: 10px;
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.table-container::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.4);
}

table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  margin: 0;
}

table th, table td {
  padding: 12px;
  text-align: left;
}

table th {
  background: rgba(44, 62, 80, 0.85);
  position: sticky;
  top: 0;
  cursor: pointer;
  border-radius: 5px;
  transition: all 0.3s ease;
  z-index: 10;
  backdrop-filter: blur(var(--blur-intensity));
  -webkit-backdrop-filter: blur(var(--blur-intensity));
  color: white;
  font-weight: 600;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

table th:hover {
  background: rgba(255, 255, 255, 0.3);
}

table tr {
  transition: all 0.3s ease;
  border-radius: 8px;
}

table tr:nth-child(even) {
  background: rgba(255, 255, 255, 0.1);
}

table tr:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: scale(1.01);
}

.sort-indicator {
  margin-left: 5px;
}

/* Summary statistics styles */
.summary-stats {
  display: flex;
  justify-content: space-between;
  margin-bottom: 20px;
  flex-wrap: wrap;
  gap: 15px;
}

.stat-item {
  flex: 1;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  padding: 15px;
  border-radius: 10px;
  text-align: center;
  border: 1px solid rgba(255, 255, 255, 0.1);
  transition: all 0.3s ease;
  min-width: 120px;
}

.stat-item:hover {
  background: rgba(255, 255, 255, 0.15);
  transform: translateY(-3px);
}

.stat-value {
  font-size: 24px;
  font-weight: 600;
  margin-bottom: 5px;
}

.stat-label {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.8);
}

/* Bottom Navigation */
.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  background: rgba(44, 62, 80, 0.9);
  backdrop-filter: blur(var(--blur-intensity));
  -webkit-backdrop-filter: blur(var(--blur-intensity));
  box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.1);
  z-index: 1000;
  padding: 10px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.bottom-nav-container {
  display: flex;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch; /* Smooth scrolling on iOS */
  scrollbar-width: none; /* Hide scrollbar on Firefox */
  -ms-overflow-style: none; /* Hide scrollbar on IE/Edge */
  padding: 0 10px;
  scroll-behavior: smooth; /* Smooth scrolling */
  cursor: grab;
  justify-content: flex-start; /* Allow natural flow with overflow */
  max-width: 1400px; /* Increase max-width for more items */
  margin: 0 auto; /* Center the navigation */
  gap: 2px; /* Small gap between items */
}

.bottom-nav-container::-webkit-scrollbar {
  display: none; /* Hide scrollbar on Chrome/Safari */
}

.bottom-nav-container.active {
  cursor: grabbing;
}

.nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 6px 8px;
  text-decoration: none;
  color: rgba(255, 255, 255, 0.7);
  transition: var(--transition-fast);
  min-width: 55px;
  flex-shrink: 0; /* Prevent items from shrinking */
}

.nav-item:hover {
  color: white;
  transform: translateY(-2px);
}

.nav-item.active {
  color: var(--primary-color);
}

.nav-icon {
  margin-bottom: 3px;
  width: 18px;
  height: 18px;
}

.nav-label {
  font-size: 11px;
  white-space: nowrap; /* Prevent text wrapping */
}

/* Toast notification */
.toast {
  position: fixed;
  top: 20px;
  right: 20px;
  background: var(--dark-bg);
  color: white;
  padding: 12px 20px;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  display: flex;
  align-items: center;
  transform: translateX(150%);
  transition: transform 0.3s ease;
  z-index: 2000;
  border-left: 4px solid var(--primary-color);
}

.toast.show {
  transform: translateX(0);
}

/* Modal styles for beta warning */
.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  z-index: 2100;
  align-items: center;
  justify-content: center;
  padding: 20px;
  animation: fade-in 0.3s ease;
  box-sizing: border-box;
}

.modal-content {
  width: 100%;
  max-width: 600px;
  max-height: 90vh;
  overflow-y: auto;
  animation: slide-in-top 0.4s ease;
  padding: 0;
}

.modal-header {
  display: flex;
  align-items: center;
  padding: 20px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.05);
}

.modal-header h3 {
  margin: 0;
  color: var(--volt-color);
}

.modal-body {
  padding: 20px;
}

.modal-body p {
  margin-bottom: 15px;
  line-height: 1.6;
}

.modal-body p:last-child {
  margin-bottom: 0;
}

.modal-body strong {
  color: var(--volt-color);
  font-weight: 600;
}

.modal-footer {
  padding: 15px 20px;
  display: flex;
  justify-content: flex-end;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.modal-button {
  background: var(--primary-color);
  color: white;
  border: none;
  border-radius: 8px;
  padding: 10px 20px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s ease;
}

.modal-button:hover {
  background: rgba(48, 162, 255, 0.9);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

@keyframes slide-in-top {
  from {
    opacity: 0;
    transform: translateY(-30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Animations */
@keyframes fade-in {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes slide-in-right {
  from { opacity: 0; transform: translateX(50px); }
  to { opacity: 1; transform: translateX(0); }
}

@keyframes slide-in-left {
  from { opacity: 0; transform: translateX(-50px); }
  to { opacity: 1; transform: translateX(0); }
}

/* Desktop navigation adjustments */
@media (min-width: 1200px) {
  .bottom-nav-container {
    justify-content: center; /* Center items on large screens */
    overflow-x: visible; /* No scrolling needed on large screens */
  }
  
  .nav-item {
    padding: 6px 10px; /* Slightly more padding on desktop */
    min-width: 60px;
  }
  
  .nav-icon {
    width: 20px;
    height: 20px;
    margin-bottom: 4px;
  }
  
  .nav-label {
    font-size: 12px;
  }
}

/* Mobile responsive adjustments */
@media (max-width: 768px) {
  .summary-stats {
    flex-direction: column;
  }
  
  .chart-container {
    height: auto;
    margin-bottom: 20px;
  }
  
  #forecast-chart {
    height: 300px;
  }
  
  .bottom-nav-container {
    justify-content: flex-start; /* Allow scrolling in mobile mode */
  }
  
  .nav-item {
    padding: 8px 8px;
    min-width: 55px;
  }
  
  /* Modal responsive styles for tablet */
  .modal {
    padding: 15px;
  }
  
  .modal-content {
    max-width: 90%;
  }
}

@media (max-width: 480px) {
  #forecast-chart {
    height: 250px;
  }
  
  .chart-container {
    margin-bottom: 15px;
  }
  
  .stat-item {
    flex-basis: 100%;
  }
  
  /* Modal responsive styles for mobile */
  .modal {
    padding: 10px;
  }
  
  .modal-content {
    max-width: 100%;
    width: calc(100% - 20px);
  }
  
  .modal-header {
    padding: 15px;
    flex-wrap: wrap;
  }
  
  .modal-body {
    padding: 15px;
  }
  
  .modal-footer {
    padding: 12px 15px;
  }
}

/* Toggle Switch - Standardized across all pages */
.toggle-container {
  display: flex;
  align-items: center;
  margin-left: auto;
}

.toggle-group {
  display: flex;
  align-items: center;
  margin-left: auto;
  gap: 15px;
}

.toggle-label-text {
  font-size: 14px;
  margin-right: 8px;
  color: rgba(255, 255, 255, 0.8);
}

/* Standard toggle switch styling */
.toggle-switch, .switch {
  position: relative;
  display: inline-block;
  width: 50px;
  height: 24px;
  margin-left: 10px;
}

.toggle-input, .switch input {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}

.toggle-label {
  display: flex;
  align-items: center;
  cursor: pointer;
  user-select: none;
  font-size: 14px;
  color: rgba(255, 255, 255, 0.8);
  transition: color 0.3s ease;
}

.toggle-label:hover {
  color: white;
}

/* For .toggle-text inside .toggle-label format */
.toggle-text {
  position: relative;
  padding-left: 50px;
  line-height: 24px;
}

.toggle-text:before {
  content: '';
  position: absolute;
  left: 0;
  width: 40px;
  height: 22px;
  border-radius: 11px;
  background-color: rgba(255, 255, 255, 0.2);
  transition: background-color 0.3s ease;
}

.toggle-text:after {
  content: '';
  position: absolute;
  left: 3px;
  top: 3px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background-color: white;
  transition: transform 0.3s ease, background-color 0.3s ease;
}

.toggle-input:checked + .toggle-label .toggle-text:before {
  background-color: var(--primary-color);
}

.toggle-input:checked + .toggle-label .toggle-text:after {
  transform: translateX(18px);
}

/* For .slider inside .switch format */
.slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(255, 255, 255, 0.2);
  transition: 0.4s;
  border-radius: 24px;
}

.slider:before {
  position: absolute;
  content: "";
  height: 18px;
  width: 18px;
  left: 3px;
  bottom: 3px;
  background-color: white;
  transition: 0.4s;
  border-radius: 50%;
}

input:checked + .slider {
  background-color: var(--primary-color);
}

input:checked + .slider:before {
  transform: translateX(26px);
}

/* Status styling for the DFS procured table */
.status-accepted {
  color: var(--normal-color);
  font-weight: 500;
}

.status-rejected {
  color: var(--danger-color);
  opacity: 0.7;
}

.rejected-row {
  opacity: 0.6;
}

/* Add glassmorphic style for select dropdowns */
select.compact-input {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 10px;
  backdrop-filter: blur(10px);
  color: white;
  font-size: 0.9rem;
  padding: 8px 12px;
  transition: all 0.3s ease;
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
  background-repeat: no-repeat;
  background-position: right 8px center;
  background-size: 16px;
  cursor: pointer;
  min-width: 160px;
}

select.compact-input:hover {
  background-color: rgba(255, 255, 255, 0.15);
  border-color: rgba(255, 255, 255, 0.3);
}

select.compact-input:focus {
  outline: none;
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.3);
  background-color: rgba(255, 255, 255, 0.2);
}

select.compact-input option {
  background-color: #2c3e50;
  color: white;
}

/* Make other form controls match the glassmorphic style */
.compact-input, 
.compact-button {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 10px;
  backdrop-filter: blur(10px);
  color: white;
  font-size: 0.9rem;
  padding: 8px 12px;
  transition: all 0.3s ease;
}

.compact-input:hover,
.compact-button:hover {
  background-color: rgba(255, 255, 255, 0.15);
  border-color: rgba(255, 255, 255, 0.3);
}

.compact-input:focus,
.compact-button:focus {
  outline: none;
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.3);
  background-color: rgba(255, 255, 255, 0.2);
}

/* Period slider styling */
#period-slider-container {
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  padding: 10px;
  border-radius: 10px;
  margin: 15px 0;
}

#period-slider-container label {
  color: rgba(255, 255, 255, 0.9);
  font-weight: 500;
  margin-bottom: 8px;
  display: block;
}

/* Export CSV button styling */
.export-csv-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 6px;
  color: white;
  font-size: 0.85em;
  cursor: pointer;
  transition: all 0.3s ease;
  backdrop-filter: blur(10px);
}

.export-csv-btn:hover {
  background: rgba(255, 255, 255, 0.2);
  border-color: rgba(255, 255, 255, 0.3);
  transform: translateY(-1px);
}

.export-csv-btn:active {
  transform: translateY(0);
}

.export-csv-btn i {
  width: 14px;
  height: 14px;
  stroke-width: 2;
}

/* Horizon slider styling - same as period slider */
#horizon-slider-container {
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  padding: 10px;
  border-radius: 10px;
  margin: 15px 0;
}

#horizon-slider-container label {
  color: rgba(255, 255, 255, 0.9);
  font-weight: 500;
  margin-bottom: 8px;
  display: block;
}

#period-slider {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 8px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 5px;
  outline: none;
  opacity: 0.8;
  transition: opacity 0.2s;
}

#period-slider:hover {
  opacity: 1;
}

#period-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: rgba(52, 152, 219, 0.9);
  cursor: pointer;
  border: 2px solid rgba(255, 255, 255, 0.8);
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.3);
}

#period-slider::-moz-range-thumb {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: rgba(52, 152, 219, 0.9);
  cursor: pointer;
  border: 2px solid rgba(255, 255, 255, 0.8);
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.3);
}

#horizon-slider {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 8px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 5px;
  outline: none;
  opacity: 0.8;
  transition: opacity 0.2s;
}

#horizon-slider:hover {
  opacity: 1;
}

#horizon-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: rgba(52, 152, 219, 0.9);
  cursor: pointer;
  border: 2px solid rgba(255, 255, 255, 0.8);
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.3);
}

#horizon-slider::-moz-range-thumb {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: rgba(52, 152, 219, 0.9);
  cursor: pointer;
  border: 2px solid rgba(255, 255, 255, 0.8);
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.3);
}

#period-value {
  display: inline-block;
  min-width: 30px;
  font-weight: 600;
  color: rgba(52, 152, 219, 1);
}

#horizon-value {
  display: inline-block;
  min-width: 30px;
  font-weight: 600;
  color: rgba(52, 152, 219, 1);
}

/* Boundary reference table styling */
.boundary-reference {
  max-height: 300px;
  margin-top: 25px;
  border-radius: 10px;
  overflow-y: auto;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.boundary-table {
  width: 100%;
}

.boundary-table th {
  background: rgba(44, 62, 80, 0.85);
  color: white;
  padding: 12px 15px;
  font-weight: 600;
  text-align: left;
}

.boundary-table td {
  padding: 10px 15px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.boundary-table tr:hover {
  background: rgba(255, 255, 255, 0.15);
  cursor: pointer;
}

.boundary-table tr:last-child td {
  border-bottom: none;
}

/* Two-column boundary table styling */
.boundary-table-wrapper {
  display: flex;
  flex-wrap: wrap;
  gap: 15px;
  justify-content: space-between;
}

.boundary-table {
  width: 100%;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 8px;
}

/* Responsive adjustments for boundary tables */
@media (max-width: 768px) {
  .boundary-table-wrapper {
    flex-direction: column;
  }
  
  .boundary-table {
    margin-bottom: 15px;
  }
}

/* Participants list styling */
.participants-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 10px;
}

.participant-item {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 6px;
  padding: 8px 12px;
  font-size: 14px;
  transition: var(--transition-fast);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.participant-item:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: translateY(-3px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

/* Info content styling */
.info-content {
  padding: 10px 0;
  line-height: 1.6;
}

.info-content ul {
  padding-left: 20px;
  margin-bottom: 15px;
}

.info-content li {
  margin-bottom: 8px;
}

.info-content strong {
  color: white;
}

/* Regional chart styling */
#regional-chart {
  height: 350px;
  width: 100%;
}

.chart-container {
  min-height: 350px;
  position: relative;
}

@media (max-width: 768px) {
  .boundary-table-wrapper {
    flex-direction: column;
  }
  
  .boundary-table {
    margin-bottom: 15px;
  }
}
