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

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', sans-serif;
  background: #f5f7fa;
  color: #2c3e50;
  margin: 0;
  min-height: 100vh;
}

.container {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  padding: 20px;
  padding-bottom: 40px;
  gap: 15px;
}

header {
  flex-shrink: 0;
}

header h1 {
  color: #1a202c;
  font-size: 1.5em;
  font-weight: 600;
  margin-bottom: 4px;
  letter-spacing: -0.02em;
}

.subtitle {
  color: #718096;
  font-size: 0.875em;
  font-weight: 400;
}

.dashboard {
  display: grid;
  grid-template-columns: 1fr 380px;
  gap: 15px;
  min-height: 650px;
  max-height: 750px;
}

.main-viz {
  background: white;
  border-radius: 8px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.08);
  padding: 20px;
  display: flex;
  flex-direction: column;
  min-height: 650px;
  max-height: 750px;
}

.viz-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 15px;
  flex-shrink: 0;
}

.main-viz h2 {
  color: #1a202c;
  font-size: 1.1em;
  font-weight: 600;
  margin: 0;
}

.side-panel {
  display: flex;
  flex-direction: column;
  gap: 15px;
  min-height: 650px;
  max-height: 750px;
}

.viz-container {
  background: white;
  border-radius: 8px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.08);
  padding: 18px;
  display: flex;
  flex-direction: column;
  min-height: 300px;
  flex: 1;
}

.viz-container h3 {
  color: #1a202c;
  font-size: 0.95em;
  font-weight: 600;
  margin: 0 0 4px 0;
}

.hint {
  color: #a0aec0;
  font-size: 0.75em;
  margin-bottom: 12px;
  font-style: italic;
}

#map {
  width: 100%;
  flex: 1;
  background: #e8f4f8;
  display: block;
  border-radius: 4px;
  min-height: 550px;
  max-height: 650px;
}

#timeline {
  width: 100%;
  flex: 1;
  display: block;
  min-height: 280px;
}

#categoryChart {
  width: 100%;
  flex: 1;
  display: block;
  min-height: 280px;
}

.legend {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.legend-item {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.8em;
  color: #4a5568;
}

.legend-color {
  width: 14px;
  height: 14px;
  border-radius: 2px;
  border: 1px solid rgba(0,0,0,0.1);
}

.tooltip {
  position: absolute;
  background: rgba(26, 32, 44, 0.95);
  color: white;
  padding: 8px 12px;
  border-radius: 6px;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.2s;
  font-size: 0.85em;
  max-width: 220px;
  z-index: 1000;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.tooltip.show {
  opacity: 1;
}

.hurricane-track {
  fill: none;
  stroke-width: 1.2;
  opacity: 0.5;
  transition: opacity 0.15s, stroke-width 0.15s;
}

.hurricane-track:hover {
  opacity: 0.95;
  stroke-width: 2.5;
}

.bar {
  transition: all 0.15s ease;
}

.axis {
  font-size: 11px;
  color: #718096;
}

.axis path,
.axis line {
  stroke: #e2e8f0;
}

.axis text {
  fill: #718096;
}

.axis-label {
  font-size: 12px;
  font-weight: 500;
  fill: #4a5568;
}

.brush .selection {
  fill: #4299e1;
  fill-opacity: 0.15;
  stroke: #3182ce;
  stroke-width: 1.5px;
  rx: 2px;
}

.brush .handle {
  fill: #3182ce;
  rx: 2px;
}
