:root {
  color-scheme: dark;
}

.dashboard-home-skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 10;
  padding: 10px 14px;
  border-radius: 8px;
  background: var(--text);
  color: #07111b;
  font-weight: 700;
  text-decoration: none;
  transform: translateY(-160%);
}

.dashboard-home-skip-link:focus-visible {
  transform: translateY(0);
  outline: 3px solid var(--accent);
  outline-offset: 3px;
}

.dashboard-home-page {
  display: grid;
  gap: 18px;
}

.dashboard-home-page .dashboard-shell-card {
  margin-bottom: 0;
}

.dashboard-home-page .dashboard-shell-card--hero {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
}

.dashboard-hero-content {
  min-width: 0;
}

.dashboard-hero-actions {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 10px;
  flex-shrink: 0;
}

.dashboard-hero-actions .dashboard-home-card__link {
  white-space: nowrap;
}

.dashboard-home-section {
  padding: 18px;
}

.dashboard-home-section--primary {
  border-color: color-mix(in srgb, var(--accent) 45%, var(--line));
}

.dashboard-home-section__header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 18px;
  margin-bottom: 18px;
}

.dashboard-home-section__eyebrow {
  margin: 0 0 8px;
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.dashboard-home-section h2 {
  margin: 0;
  font-size: clamp(1.4rem, 2.2vw, 1.9rem);
  text-wrap: balance;
}

.dashboard-home-section__description {
  max-width: 420px;
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
}

.dashboard-home-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr));
  gap: 16px;
}

.dashboard-home-grid--primary {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr));
}

.dashboard-home-card {
  display: grid;
  grid-template-rows: auto 1fr auto;
  gap: 14px;
  min-width: 0;
  min-height: 190px;
  padding: 18px;
  border: 1px solid var(--line-soft);
  border-radius: 14px;
  background: rgba(13, 19, 29, 0.68);
}

.dashboard-home-section--primary .dashboard-home-card {
  border-color: color-mix(in srgb, var(--accent) 35%, var(--line-soft));
}

.dashboard-home-card h3 {
  margin: 0;
  font-size: 1.08rem;
  text-wrap: balance;
}

.dashboard-home-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
}

.dashboard-home-card__link,
.dashboard-home-form button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  min-height: 38px;
  padding: 9px 14px;
  border: 0;
  border-radius: 9px;
  background: #0078ad;
  color: white;
  font: inherit;
  font-size: 0.9rem;
  text-decoration: none;
  cursor: pointer;
}

.dashboard-home-card__link:hover,
.dashboard-home-form button:hover {
  background: #006c9c;
}

.dashboard-home-card__link:focus-visible,
.dashboard-home-form button:focus-visible,
.dashboard-home-form__row input:focus-visible,
.dashboard-home-legacy summary:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--accent) 70%, white 30%);
  outline-offset: 3px;
}

.dashboard-home-card--form {
  grid-template-rows: auto auto 1fr;
}

.dashboard-home-form {
  display: grid;
  align-self: end;
  gap: 10px;
}

.dashboard-home-form__label {
  font-size: 0.86rem;
  color: var(--muted);
}

.dashboard-home-form__row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
  gap: 10px;
}

.dashboard-home-form__row input {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #0f1621;
  color: var(--text);
  padding: 11px 12px;
  font: inherit;
}

.dashboard-home-form__row input::placeholder {
  color: #7590b2;
}

.dashboard-home-form__hint,
.dashboard-home-form__status {
  font-size: 0.82rem;
}

.dashboard-home-form__status {
  color: var(--error);
}

.dashboard-home-legacy {
  border-top: 1px solid var(--line-soft);
  padding-top: 14px;
}

.dashboard-home-legacy summary {
  width: fit-content;
  color: var(--text);
  cursor: pointer;
  font-weight: 700;
}

.dashboard-home-legacy summary:hover {
  color: #bfe9ff;
}

.dashboard-home-grid--legacy {
  margin-top: 16px;
}

@media (max-width: 900px) {
  .dashboard-home-section__header {
    display: grid;
  }

  .dashboard-home-section__description {
    max-width: none;
  }
}

@media (max-width: 640px) {
  .dashboard-home-page .dashboard-shell-card--hero {
    flex-direction: column;
    align-items: flex-start;
  }

  .dashboard-hero-actions,
  .dashboard-hero-actions .dashboard-home-card__link,
  .dashboard-home-card__link,
  .dashboard-home-form button {
    width: 100%;
  }

  .dashboard-hero-actions .dashboard-home-card__link {
    white-space: normal;
  }

  .dashboard-home-section {
    padding: 16px;
  }

  .dashboard-home-card {
    min-height: 0;
  }

  .dashboard-home-form__row {
    grid-template-columns: 1fr;
  }
}
