.dashboard-search {
  position: relative;
}

.dashboard-search-results {
  position: absolute;
  z-index: 30;
  top: calc(100% + 8px);
  right: 0;
  display: grid;
  width: min(420px, 72vw);
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
  box-shadow: var(--shadow-md);
}

.dashboard-search-results[hidden] {
  display: none;
}

.dashboard-search-result {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  padding: 10px 12px;
  border-bottom: 1px solid var(--border);
}

.dashboard-search-result:last-child {
  border-bottom: 0;
}

.dashboard-search-result:hover,
.dashboard-search-result:focus-visible {
  background: var(--surface-muted);
  outline: 0;
}

.dashboard-search-result strong,
.dashboard-search-result span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.dashboard-search-result strong {
  font-size: 13px;
}

.dashboard-search-result span {
  color: var(--text-muted);
  font-size: 12px;
}

.dashboard-search-result small {
  align-self: center;
  padding: 3px 7px;
  border-radius: 999px;
  background: var(--primary-soft);
  color: var(--primary);
  font-size: 10px;
  font-weight: 800;
}

.dashboard-grid {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(320px, 0.95fr);
  gap: 16px;
}

.dashboard-main,
.dashboard-side {
  display: grid;
  align-content: start;
  gap: 16px;
}

.collection-card {
  position: relative;
  overflow: hidden;
  min-height: 132px;
  padding: 18px;
  border-radius: 13px;
  background: linear-gradient(135deg, #5b4df5, #4338ca);
  color: #fff;
  box-shadow: 0 18px 34px rgba(67, 56, 202, 0.26);
}

.collection-card::after {
  content: "";
  position: absolute;
  right: -40px;
  bottom: -70px;
  width: 210px;
  height: 210px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
}

.collection-kicker {
  color: rgba(255, 255, 255, 0.76);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.collection-row {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
}

.collection-title {
  margin: 4px 0 10px;
  font-size: 30px;
  line-height: 1.1;
}

.collection-percent {
  min-width: 92px;
  text-align: center;
}

.collection-percent strong {
  display: block;
  font-size: 34px;
  line-height: 1;
}

.progress {
  position: relative;
  z-index: 1;
  height: 7px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.22);
}

.progress-fill {
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: #34d399;
  transition: width 180ms ease;
}

.collection-breakdown {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  margin-top: 14px;
}

.collection-breakdown span {
  display: block;
  color: rgba(255, 255, 255, 0.65);
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
}

.collection-breakdown strong {
  color: #fff;
}

.collection-good {
  color: #6ee7b7 !important;
}

.collection-waiting {
  color: #fde68a !important;
}

.notification-list {
  display: grid;
}

.dashboard-notification-empty {
  padding: 26px 14px;
  border-top: 1px solid var(--border);
  color: var(--text-muted);
  text-align: center;
}

.notification-item {
  display: grid;
  grid-template-columns: 34px 1fr auto;
  gap: 12px;
  align-items: center;
  padding: 12px 14px;
  border-top: 1px solid var(--border);
}

.notification-type {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 9px;
}

.notification-type svg {
  width: 17px;
  height: 17px;
}

.type-danger {
  color: var(--danger);
  background: #fef2f2;
}

.type-warning {
  color: var(--amber);
  background: #fffbeb;
}

.type-info {
  color: var(--blue);
  background: #eff6ff;
}

.type-pink {
  color: var(--pink);
  background: #fdf2f8;
}

.notification-label {
  display: inline-flex;
  margin-bottom: 3px;
  padding: 2px 6px;
  border-radius: 999px;
  background: #fef2f2;
  color: var(--danger);
  font-size: 10px;
  font-weight: 900;
  text-transform: uppercase;
}

.label-warning {
  background: #fffbeb;
  color: var(--amber);
}

.label-pink {
  background: #fdf2f8;
  color: var(--pink);
}

.label-info {
  background: #eff6ff;
  color: var(--blue);
}

.notification-title {
  display: block;
  font-weight: 800;
}

.notification-copy {
  color: var(--text-muted);
  font-size: 12px;
}

.side-list {
  display: grid;
}

.side-row {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 10px;
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
}

.side-row:last-child {
  border-bottom: 0;
}

.side-row strong {
  font-size: 13px;
}

.side-count {
  font-weight: 800;
}

.occupancy-card {
  display: grid;
  justify-items: center;
  gap: 12px;
}

.donut {
  display: grid;
  --occupancy-percent: 0%;
  width: 118px;
  height: 118px;
  place-items: center;
  border-radius: 50%;
  background: conic-gradient(#5b4df5 0 var(--occupancy-percent), #eef2f7 var(--occupancy-percent) 100%);
}

:root[data-theme="dark"] .donut {
  background: conic-gradient(#7c6cff 0 var(--occupancy-percent), #263244 var(--occupancy-percent) 100%);
}

.donut-inner {
  display: grid;
  width: 78px;
  height: 78px;
  place-items: center;
  border-radius: 50%;
  background: #fff;
  text-align: center;
}

.donut-inner strong {
  display: block;
  font-size: 22px;
  line-height: 1;
}

.quick-actions {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}

.mini-stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  width: 100%;
}

.mini-stats div {
  padding: 10px;
  border-radius: 9px;
  background: #f8fafc;
}

.mini-stats span {
  display: block;
  color: var(--text-muted);
  font-size: 11px;
  font-weight: 800;
}

.mini-stats strong {
  font-size: 13px;
}

.warning-text {
  color: var(--warning);
}

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

@media (max-width: 680px) {
  .dashboard-search,
  .dashboard-search-results {
    width: 100%;
  }

  .dashboard-search-results {
    right: auto;
    left: 0;
  }

  .collection-breakdown {
    grid-template-columns: 1fr;
  }

  .notification-item {
    grid-template-columns: 34px 1fr;
  }

  .notification-item .muted {
    grid-column: 2;
  }

  .quick-actions {
    grid-template-columns: 1fr;
  }
}
