/* Slots grid layout
/* ------------------------------------------------------------------------ */

.slots-grid {
  --slots-grid-gap: 1rem;
  --slots-grid-columns: 1;

  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  gap: var(--slots-grid-gap);
  margin: 1rem 0;
}

@media (min-width: 640px) {
  .slots-grid {
    --slots-grid-columns: 2;
  }
}

@media (min-width: 960px) {
  .slots-grid {
    --slots-grid-columns: 3;
  }
}

.slots-grid .slot-card {
  width: calc((100% - var(--slots-grid-gap) * (var(--slots-grid-columns) - 1)) / var(--slots-grid-columns));
}

/* Slot card
/* ------------------------------------------------------------------------ */

.slot-card {
  --card-color: #666;
  --card-padding: 1rem;

  background-color: color-mix(in srgb, var(--card-color) 5%, white);
  border-radius: 0.5rem;
  box-shadow: 0 0 0 2px var(--card-color);
  color: #333;
  display: block;
  padding: var(--card-padding);
  position: relative;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  text-decoration: none;
}

.slot-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 0 2px var(--card-color), 0 4px 8px rgba(0, 0, 0, 0.1);
  text-decoration: none;
}

.slot-card__content {
  position: relative;
  z-index: 1;
}

.slot-card__title {
  color: inherit;
  display: block;
  font-size: 1.25rem;
  font-weight: 600;
  line-height: 1.3;
  margin-bottom: 0.5rem;
}

.slot-card__status {
  color: var(--card-color);
  font-size: 0.875rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 1rem;
}

.slot-actions {
  display: flex;
  gap: 0.5rem;
  margin-top: 1rem;
}

.slot-actions .btn {
  flex: 1;
}

/* Status variants
/* ------------------------------------------------------------------------ */

.slot-card--created {
  --card-color: #10b981; /* Green */
}

.slot-card--aired {
  --card-color: #f59e0b; /* Golden */
}

.slot-card--cancelled {
  --card-color: #6b7280; /* Gray */
}

.slot-card--done {
  --card-color: #3b82f6; /* Blue */
}

/* Days left indicator
/* ------------------------------------------------------------------------ */

.slot-card__days-left {
  position: absolute;
  top: var(--card-padding);
  right: var(--card-padding);
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.25rem 0.5rem;
  border-radius: 0.25rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.urgency-overdue {
  background-color: #dc2626;
  color: white;
}

.urgency-critical {
  background-color: #f97316;
  color: white;
}

.urgency-warning {
  background-color: #eab308;
  color: #1f2937;
}

.urgency-normal {
  background-color: #22c55e;
  color: white;
}

/* Analytics page
/* ------------------------------------------------------------------------ */

.analytics-summary {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
  margin: 1.5rem 0;
}

.analytics-card {
  background: white;
  border-radius: 0.5rem;
  padding: 1.5rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  border: 1px solid #e5e7eb;
}

.analytics-card h2 {
  font-size: 0.875rem;
  font-weight: 600;
  color: #6b7280;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin: 0 0 1rem 0;
}

.analytics-number {
  font-size: 3rem;
  font-weight: 700;
  color: #111827;
  margin: 0;
}

.status-breakdown {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.status-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.5rem 0;
  border-bottom: 1px solid #f3f4f6;
}

.status-item:last-child {
  border-bottom: none;
}

.status-label {
  font-weight: 500;
  color: #374151;
}

.status-count {
  font-weight: 600;
  color: #111827;
  background: #f3f4f6;
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
  font-size: 0.875rem;
}

.monthly-stats {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1rem;
  margin-top: 1rem;
}

.month-card {
  background: white;
  border-radius: 0.5rem;
  padding: 1.25rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  border: 1px solid #e5e7eb;
}

.month-card h3 {
  font-size: 1.125rem;
  font-weight: 600;
  color: #111827;
  margin: 0 0 1rem 0;
}

.month-total {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.75rem;
  background: #f9fafb;
  border-radius: 0.375rem;
  margin-bottom: 1rem;
}

.month-total-label {
  font-weight: 500;
  color: #6b7280;
}

.month-total-count {
  font-weight: 700;
  font-size: 1.25rem;
  color: #111827;
}

.month-statuses {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.month-status-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.375rem 0;
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}

.status-dot--created {
  background-color: #10b981;
}

.status-dot--aired {
  background-color: #f59e0b;
}

.status-dot--cancelled {
  background-color: #6b7280;
}

.status-dot--done {
  background-color: #3b82f6;
}

.month-status-label {
  flex: 1;
  color: #6b7280;
  font-size: 0.875rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.month-status-count {
  font-weight: 600;
  color: #374151;
}
