/* Dashboard Styling - Glassmorphism UI */

.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin-bottom: 24px;
}

@media (max-width: 1200px) {
  .dashboard-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 576px) {
  .dashboard-grid {
    grid-template-columns: 1fr;
  }
}

/* KPI Card */
.kpi-card {
  display: flex;
  align-items: center;
  gap: 16px;
}

.kpi-icon {
  width: 50px;
  height: 50px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 1.5rem;
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.kpi-icon.blue { background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%); }
.kpi-icon.orange { background: linear-gradient(135deg, #f97316 0%, #ea580c 100%); }
.kpi-icon.yellow { background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%); }
.kpi-icon.green { background: linear-gradient(135deg, #10b981 0%, #059669 100%); }
.kpi-icon.red { background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%); }

.kpi-details {
  display: flex;
  flex-direction: column;
}

.kpi-value {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-main);
  line-height: 1.2;
}

.kpi-label {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-weight: 500;
}

/* Core Dashboard Content Layout */
.dashboard-layout-main {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 24px;
  margin-bottom: 24px;
}

@media (max-width: 992px) {
  .dashboard-layout-main {
    grid-template-columns: 1fr;
  }
}

/* Alert Notification Panel */
.alert-panel {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.alert-panel-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.alert-panel-title {
  font-weight: 700;
  font-size: 1.1rem;
  display: flex;
  align-items: center;
  gap: 8px;
}

.alert-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-height: 380px;
  overflow-y: auto;
  padding-right: 4px;
}

.alert-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 16px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.2);
  transition: var(--transition);
}

.dark-mode .alert-item {
  background: rgba(255, 255, 255, 0.03);
  border-color: rgba(255, 255, 255, 0.05);
}

.alert-item:hover {
  transform: translateX(4px);
}

.alert-item.danger {
  border-left: 4px solid var(--danger);
  background: rgba(239, 68, 68, 0.06);
}

.alert-item.warning {
  border-left: 4px solid var(--warning);
  background: rgba(245, 158, 11, 0.06);
}

.alert-item-icon {
  margin-top: 2px;
}

.alert-item.danger .alert-item-icon { color: var(--danger); }
.alert-item.warning .alert-item-icon { color: var(--warning); }

.alert-item-content {
  font-size: 0.88rem;
  line-height: 1.4;
}

.alert-item-title {
  font-weight: 600;
  color: var(--text-main);
  margin-bottom: 2px;
}

.alert-item-desc {
  color: var(--text-muted);
}

/* Today's Focus Card */
.focus-card {
  display: flex;
  flex-direction: column;
}

.focus-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 12px;
  flex-grow: 1;
}

.focus-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  border-radius: 10px;
  font-size: 0.9rem;
  font-weight: 500;
  transition: var(--transition);
  border: 1px solid var(--glass-inner-border);
}

.focus-item:hover {
  transform: scale(1.02);
}

.focus-item.high {
  background: rgba(239, 68, 68, 0.08);
  border-left: 4px solid var(--prio-high);
}
.focus-item.medium {
  background: rgba(249, 115, 22, 0.08);
  border-left: 4px solid var(--prio-medium);
}
.focus-item.low {
  background: rgba(234, 179, 8, 0.08);
  border-left: 4px solid var(--prio-low);
}
.focus-item.done {
  background: rgba(16, 185, 129, 0.08);
  border-left: 4px solid var(--prio-done);
  text-decoration: line-through;
  opacity: 0.7;
}

.focus-title {
  color: var(--text-main);
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 70%;
}

.focus-tag {
  font-size: 0.75rem;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 4px;
  color: white;
}

.focus-tag.high { background: var(--prio-high); }
.focus-tag.medium { background: var(--prio-medium); }
.focus-tag.low { background: var(--prio-low); }
.focus-tag.done { background: var(--prio-done); }

/* Charts Layout Grid */
.charts-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
  margin-top: 24px;
}

@media (max-width: 992px) {
  .charts-grid {
    grid-template-columns: 1fr;
  }
}

.chart-card {
  min-height: 300px;
  display: flex;
  flex-direction: column;
}

.chart-card h4 {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 16px;
  color: var(--text-main);
  border-left: 4px solid var(--primary);
  padding-left: 8px;
}

.chart-container {
  position: relative;
  flex-grow: 1;
  width: 100%;
  height: 100%;
}
