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

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  background: #0a0e27;
  min-height: 100vh;
  padding: 2rem;
  color: #e2e8f0;
}

@keyframes fadeInDown {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.container {
  max-width: 900px;
  margin: 0 auto;
}

.header {
  text-align: center;
  margin-bottom: 2.5rem;
  animation: fadeInDown 0.8s ease;
}

.header h1 {
  font-size: 2.5rem;
  font-weight: 700;
  color: #00d9ff;
  text-shadow: 0 0 20px rgba(0, 217, 255, 0.5), 0 0 40px rgba(0, 217, 255, 0.3);
  margin-bottom: 0.5rem;
}

.header p {
  color: #94a3b8;
  font-size: 1.1rem;
}

.controls {
  background: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(10px);
  border-radius: 20px;
  padding: 1.5rem;
  margin-bottom: 2rem;
  border: 1px solid rgba(0, 217, 255, 0.2);
  box-shadow: 0 0 20px rgba(0, 217, 255, 0.1);
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  align-items: center;
  animation: fadeIn 0.8s ease 0.2s backwards;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.control-group {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  flex: 1;
  min-width: 200px;
}

.control-group label {
  font-size: 0.85rem;
  font-weight: 600;
  color: #00d9ff;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

select {
  background: rgba(15, 23, 42, 0.8);
  border: 1px solid rgba(0, 217, 255, 0.3);
  border-radius: 12px;
  padding: 0.75rem 1rem;
  font-size: 1rem;
  color: #e2e8f0;
  cursor: pointer;
  transition: all 0.3s ease;
  outline: none;
}

select:hover {
  background: rgba(15, 23, 42, 1);
  transform: translateY(-2px);
  box-shadow: 0 0 15px rgba(0, 217, 255, 0.3);
  border-color: #00d9ff;
}

select:focus {
  border-color: #00d9ff;
  box-shadow: 0 0 0 3px rgba(0, 217, 255, 0.2);
}

.glass-card {
  background: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(10px);
  border-radius: 24px;
  padding: 2rem;
  margin-bottom: 1.5rem;
  border: 1px solid rgba(0, 217, 255, 0.2);
  box-shadow: 0 0 20px rgba(0, 217, 255, 0.1);
  transition: all 0.3s ease;
  animation: fadeIn 0.8s ease backwards;
}

.glass-card:nth-child(3) { animation-delay: 0.3s; }
.glass-card:nth-child(4) { animation-delay: 0.4s; }
.glass-card:nth-child(5) { animation-delay: 0.5s; }

.glass-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 0 30px rgba(0, 217, 255, 0.2);
  border-color: rgba(0, 217, 255, 0.4);
}

.total-card {
  text-align: center;
}

.stat-title {
  font-size: 0.9rem;
  font-weight: 600;
  color: #00d9ff;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 1rem;
}

.stat-value {
  font-size: 4rem;
  font-weight: 700;
  color: #00d9ff;
  text-shadow: 0 0 20px rgba(0, 217, 255, 0.5), 0 0 40px rgba(0, 217, 255, 0.3);
  line-height: 1;
}

.weekday-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
  gap: 1rem;
}

.month-filter {
  font-size: 0.75rem;
  color: #94a3b8;
}

.month-filter summary {
  cursor: pointer;
  user-select: none;
  padding: 0.5rem 1rem;
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid rgba(0, 217, 255, 0.2);
  border-radius: 8px;
  transition: all 0.3s ease;
  list-style: none;
  color: #00d9ff;
}

.month-filter summary::-webkit-details-marker {
  display: none;
}

.month-filter summary::after {
  content: ' ▼';
  font-size: 0.6rem;
  margin-left: 0.3rem;
}

.month-filter[open] summary::after {
  content: ' ▲';
}

.month-filter summary:hover {
  background: rgba(15, 23, 42, 0.8);
  border-color: #00d9ff;
  box-shadow: 0 0 10px rgba(0, 217, 255, 0.2);
}

.months-selector {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-top: 0.75rem;
  padding: 0.75rem;
  background: rgba(0, 0, 0, 0.3);
  border-radius: 8px;
}

.months-selector label {
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid rgba(0, 217, 255, 0.2);
  border-radius: 6px;
  padding: 0.35rem 0.6rem;
  cursor: pointer;
  transition: all 0.2s ease;
  color: #94a3b8;
  font-size: 0.7rem;
  font-weight: 500;
  user-select: none;
}

.months-selector label:hover {
  background: rgba(15, 23, 42, 0.8);
  border-color: #00d9ff;
}

.months-selector input[type="checkbox"] {
  display: none;
}

.months-selector label.selected {
  background: rgba(0, 217, 255, 0.2);
  border-color: #00d9ff;
  color: #00d9ff;
  font-weight: 600;
  box-shadow: 0 0 10px rgba(0, 217, 255, 0.3);
}

.chart {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.bar-container {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.bar-label {
  min-width: 50px;
  font-weight: 600;
  color: #e2e8f0;
  font-size: 0.9rem;
}

.bar-track {
  flex: 1;
  height: 32px;
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid rgba(0, 217, 255, 0.2);
  border-radius: 16px;
  overflow: hidden;
  position: relative;
}

.bar-fill {
  height: 100%;
  border-radius: 16px;
  transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  align-items: center;
  justify-content: flex-end;
  padding-right: 0.75rem;
  position: relative;
}

.bar-value {
  font-weight: 700;
  color: white;
  font-size: 0.85rem;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
  z-index: 1;
}

@media (max-width: 768px) {
  body {
    padding: 1rem;
  }

  .header h1 {
    font-size: 2rem;
  }

  .stat-value {
    font-size: 3rem;
  }

  .controls {
    flex-direction: column;
  }

  .control-group {
    width: 100%;
  }

  .weekday-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .bar-label {
    min-width: 40px;
    font-size: 0.8rem;
  }
}

.evolution-chart {
  min-height: 200px;
}
.evolution-chart svg {
  width: 100%;
  height: 200px;
  overflow: visible;
}
.evolution-line {
  fill: none;
  stroke-width: 3;
}
.evolution-area {
  stroke: none;
}
.evolution-axis {
  stroke: rgba(148, 163, 184, 0.3);
  stroke-width: 1;
}
.evolution-label {
  fill: #94a3b8;
  font-size: 10px;
  text-anchor: middle;
}
.evolution-grid {
  stroke: rgba(148, 163, 184, 0.1);
  stroke-dasharray: 4;
}