/* Modern stylesheet for solar activity monitor */

:root {
  --primary-color: #0f172a;
  --secondary-color: #1e293b;
  --accent-color: #f59e0b;
  --accent-hover: #d97706;
  --light-color: #f8fafc;
  --neutral-color: #64748b;
  --background-color: #f1f5f9;
  --card-bg-color: #ffffff;
  --border-color: #e2e8f0;
  --shadow: 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);
}

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

body {
  font-family: 'Roboto', sans-serif;
  line-height: 1.6;
  background: var(--primary-color);
  /* background: linear-gradient(135deg, var(--background-color) 0%, #e2e8f0 100%); */
  min-height: 100vh;
  padding: 0;
  margin: 0;
}

header {
  background: var(--primary-color);
  /* background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%); */
  color: var(--light-color);
  padding: 1rem 1rem;
  margin-top: 0%;
  margin-bottom: 0%;
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
}

header::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: env(var(--primary-color));
  /* background: radial-gradient(circle at 30% 20%, rgba(245, 158, 11, 0.1) 0%, transparent 50%),
    radial-gradient(circle at 70% 80%, rgba(245, 158, 11, 0.1) 0%, transparent 50%); */
  pointer-events: none;
}

.header-content {
  display: flex;
  align-items: center;
  max-width: 1400px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
  justify-content: center;
  flex-direction: column;
  gap: 1rem;

}

.header-title {
  flex: 1;
  text-align: center;
}

.data-timestamp {
  margin-top: 0.5rem;
  opacity: 0.7;
}

.data-timestamp small {
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.7);
  font-family: 'Roboto', sans-serif;
}

.header-indicators {
  position: absolute;
  right: 0;
  display: flex;
  gap: 1rem;
  align-items: center;
  flex-shrink: 0;
  justify-content: center;
}

.indicator-card {
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 12px;
  padding: 0.5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 75px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.indicator-label {
  font-size: 0.75rem;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.8);
  margin-bottom: 0.25rem;
  text-align: center;
}

.indicator-value {
  font-size: 1rem;
  /* font-weight: 700; */
  color: var(--accent-color);
  font-family: 'JetBrains Mono', monospace;
}

header h1 {
  font-size: 1.5rem;
  font-weight: 700;
  margin: 0;
  position: relative;
  z-index: 1;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
  color: var(--accent-color);
}

header h1 .fa-sun {
  color: var(--accent-color);
}

h2 {
  font-size: 1rem;
  margin-bottom: 0rem;
  color: var(--primary-color);
  font-weight: 600;
}

.description {
  max-width: 800px;
  margin: 0 auto;
  font-size: 0.75rem;
  font-weight: 300;
  color: var(--light-color);
}

.data-info {
  margin-top: 1rem;
  padding: 0.75rem 1.5rem;
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(10px);
  border-radius: 12px;
  font-size: 0.9rem;
  display: inline-block;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.container {
  max-width: 1400px;
  width: 100%;
  margin: 0 auto;
  padding: 1rem 1rem 0 1rem;
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.5rem;
  align-items: start;
  color: var(--primary-color);
}

.graph-card {
  width: 100%;
  background-color: var(--card-bg-color);
  border-radius: 16px;
  box-shadow: var(--shadow);
  padding: 1rem 1rem;
  border: 1px solid var(--border-color);
  position: relative;
  overflow: hidden;
}

.graph-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--accent-color), var(--accent-hover));
}

.graph-container {
  width: 100%;
  height: 250px;
  border-radius: 8px;
  overflow: hidden;
}

.solar-cycle-img-container {
  width: 100%;
  height: 450px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.solar-cycle-img {
  max-width: 100%;
  max-height: 100%;
  border-radius: 8px;
  object-fit: contain;
  display: block;
}

footer {
  background: var(--primary-color);
  color: var(--light-color);
  text-align: center;
  padding: 2rem 1rem;
  margin-top: 0rem;
  box-shadow: 0 -4px 6px -1px rgba(0, 0, 0, 0.1);
}

footer p {
  margin: 0;
  font-size: 0.95rem;
}

footer a {
  color: var(--accent-color);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.3s ease;
}

footer a:hover {
  color: var(--light-color);
  text-decoration: underline;
}

footer .data-timestamp {
  margin-top: 0.5rem;
  opacity: 0.7;
}

footer .data-timestamp small {
  font-size: 0.7rem;
  color: rgba(255, 255, 255, 0.7);
  font-family: 'Roboto', sans-serif;
}

/* Data point styling for graphs */
.js-plotly-plot .plotly .scatter .points path {
  stroke-width: 1px !important;
}

/* Alert styles */
.alert {
  padding: 1.5rem;
  margin: 1.5rem 0;
  border-radius: 12px;
  font-family: 'Roboto', sans-serif;
  border: 1px solid;
  position: relative;
  overflow: hidden;
}

.alert::before {
  content: '⚠️';
  position: absolute;
  top: 1rem;
  left: 1rem;
  font-size: 1.5rem;
}

.alert-error {
  background: linear-gradient(135deg, #fef2f2 0%, #fee2e2 100%);
  color: #991b1b;
  border-color: #fca5a5;
}

.alert h3 {
  margin: 0 0 0.5rem 2.5rem;
  font-size: 1.2rem;
  font-weight: 600;
}

.alert p {
  margin: 0.5rem 0;
  margin-left: 2.5rem;
}

/* Responsive layout */
@media (max-width: 1024px) {
  .container {
    gap: 0.5rem;
  }

  .graph-card {
    padding: 1rem 1.5rem;
  }

  .solar-cycle-img-container {
    height: 350px;
  }

  .indicator-card {
    padding: 0.5rem;
    min-width: 75px;
  }
}

@media (max-width: 768px) {
  .container {
    padding: 0.5rem;
    margin: 0 auto;
    gap: 0.5rem;
    background-color: var(--primary-color);
  }

  .graph-card {
    padding: 1rem;
    border-radius: 12px;
  }

  .solar-cycle-img-container {
    height: 280px;
  }

  header {
    padding: 1.5rem 1rem;
  }

  .header-content {
    flex-direction: column;
    gap: 1rem;
    justify-content: flex-start;
  }

  .header-indicators {
    position: static;
    justify-content: center;
  }

  .indicator-card {
    padding: 0.4rem;
    min-width: 70px;
  }

  footer {
    padding: 1.5rem 1rem;
  }

  footer .data-timestamp small {
    font-size: 0.7rem;
  }
}

@media (max-width: 480px) {
  .graph-card {
    padding: 1rem 0.75rem;
  }

  .solar-cycle-img-container {
    height: 250px;
  }

  .alert {
    padding: 1rem;
  }

  .alert h3 {
    margin-left: 2rem;
    font-size: 1.1rem;
  }

  .alert p {
    margin-left: 2rem;
  }
}