/* Marketing admin (/admin): hairline sections and counters in the app's report style */
@layer pages {
  .admin-section {
    margin-bottom: var(--space-12);

    > h2 {
      margin: 0 0 var(--space-4);
      font-size: var(--text-xl);
      font-weight: var(--font-semibold);
    }
  }

  /* A form placed under a table needs the same gap as a new section */
  .admin-section--form {
    margin-top: var(--space-12);
  }

  .sidebar__back {
    margin: var(--space-6) 0 0;
    padding: 0 var(--space-3);
    font-size: var(--text-sm);

    a {
      color: var(--color-text-muted);
    }
  }

  .admin-run-status {
    font-weight: var(--font-semibold);
    white-space: nowrap;

    &.admin-run-status--succeeded { color: var(--color-success); }
    &.admin-run-status--failed,
    &.admin-run-status--timed-out { color: var(--color-error); }
    &.admin-run-status--running,
    &.admin-run-status--skipped { color: var(--color-text-muted); }
  }

  .admin-quiet {
    margin: 0;
    color: var(--color-text-muted);
  }

  .admin-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(10rem, 1fr));
    margin: 0;
    border-top: 2px solid var(--color-text);

    .admin-stats__item {
      padding: var(--space-4) var(--space-4) var(--space-4) 0;
      border-bottom: 1px solid var(--color-border);
    }

    dt {
      font-size: var(--text-sm);
      color: var(--color-text-muted);
    }

    dd {
      margin: var(--space-1) 0 0;
      font-size: var(--text-3xl);
      font-weight: 750;
      line-height: 1.1;
    }
  }
}
