/* Kith admin (/admin): a dark, dense "control room" on top of styles.css. Its own tokens: always dark,
   Kith's blue as the one accent; numbers in a monospaced face so columns line up. */

.admin-page {
  --bg: #0c0f17;
  --surface: #121722;
  --surface-2: #192030;
  --input: #161c29;
  --input-border: #323c51;
  --border: #232b3b;
  --line-strong: #323c51;
  --text: #e8eaf0;
  --muted: #a3abbd;
  --faint: #8a93a8;
  --accent: #6d8bff;
  --accent-soft: #1e2847;
  --accent-strong: #9db0ff;
  --accent-fill: #4060e8;
  --ok: #5fd39a;
  --warn: #ffb35c;
  --danger: #ff7a7a;
  --mono: ui-monospace, "SF Mono", "Cascadia Mono", Menlo, Consolas, monospace;
  min-height: 100dvh;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
}

.admin-skip {
  position: absolute;
  left: -9999px;
}

.admin-skip:focus {
  left: 8px;
  top: 8px;
  z-index: 50;
  padding: 8px 12px;
  border-radius: 8px;
  background: var(--accent-fill);
  color: #fff;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.admin-eyebrow {
  margin: 0;
  color: var(--faint);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

/* ---------- frame ---------- */

.admin-shell {
  display: flex;
  flex-direction: column;
  min-height: 100dvh;
}

.admin-top {
  position: sticky;
  top: 0;
  z-index: 30;
  display: grid;
  grid-template-columns: 232px minmax(0, 1fr) auto;
  height: 46px;
  border-bottom: 1px solid var(--border);
  background: var(--bg);
}

.admin-brand {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 0 16px;
  border-right: 1px solid var(--border);
  color: var(--text);
  text-decoration: none;
}

.admin-brand .brand-mark {
  width: 24px;
  height: 24px;
  font-size: 0.8rem;
}

.admin-word {
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.admin-tag {
  padding: 3px 5px;
  border: 1px solid var(--line-strong);
  border-radius: 4px;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 0.6rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.admin-ticker {
  position: relative; /* keeps its screen-reader text inside it, not off the side of the page */
  min-width: 0;
  overflow-x: auto;
  scrollbar-width: none;
  mask-image: linear-gradient(to right, #000 calc(100% - 48px), transparent);
}

.admin-ticker:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: -2px;
  mask-image: none;
}

.admin-ticker dl {
  display: flex;
  align-items: stretch;
  height: 100%;
  margin: 0;
  padding-right: 48px;
}

.admin-ticker dl > div {
  display: flex;
  flex-shrink: 0;
  align-items: center;
  gap: 10px;
  padding: 0 16px;
  border-right: 1px solid var(--border);
  white-space: nowrap;
}

.admin-ticker dt {
  color: var(--faint);
  font-size: 0.66rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.admin-ticker dd {
  margin: 0;
  font-family: var(--mono);
  font-size: 0.8rem;
  font-variant-numeric: tabular-nums;
}

.admin-palette-button {
  display: flex;
  align-items: center;
  gap: 4px;
  height: 100%;
  padding: 0 14px;
  border: 0;
  border-left: 1px solid var(--border);
  border-radius: 0;
  background: none;
  color: var(--muted);
}

.admin-palette-button span {
  margin-right: 6px;
}

.admin-body {
  display: grid;
  flex: 1;
  grid-template-columns: 232px minmax(0, 1fr);
}

.admin-nav {
  position: sticky;
  top: 46px;
  display: flex;
  flex-direction: column;
  height: calc(100dvh - 46px);
  border-right: 1px solid var(--border);
}

.nav-groups {
  flex: 1;
  overflow-y: auto;
  padding: 20px 10px;
}

.nav-group {
  margin-bottom: 20px;
}

.nav-group .admin-eyebrow {
  padding: 0 12px 8px;
}

.admin-nav a,
.nav-foot button {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
  height: 36px;
  padding: 0 12px;
  border-radius: 8px;
  color: var(--muted);
  font-size: 0.85rem;
  text-decoration: none;
}

.admin-nav a:hover,
.nav-foot button:hover {
  background: var(--surface);
  color: var(--text);
}

.admin-nav a[aria-current="page"] {
  background: var(--surface-2);
  color: var(--text);
}

.admin-nav a[aria-current="page"]::before {
  content: "";
  position: absolute;
  inset: 8px auto 8px -10px;
  width: 3px;
  border-radius: 0 3px 3px 0;
  background: var(--accent);
}

.admin-nav a[aria-current="page"] .icon {
  color: var(--accent);
}

.admin-nav a span:first-of-type {
  flex: 1;
}

.pill-count {
  min-width: 20px;
  padding: 1px 6px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent-strong);
  font-family: var(--mono);
  font-size: 0.7rem;
  text-align: center;
}

.pill-count.alert {
  background: #3a1c22;
  color: var(--danger);
}

.nav-foot {
  display: grid;
  gap: 4px;
  padding: 10px;
  border-top: 1px solid var(--border);
}

.nav-foot button {
  width: 100%;
  border: 0;
  background: none;
  font: inherit;
  font-size: 0.82rem;
  cursor: pointer;
}

.nav-foot button span {
  flex: 1;
  text-align: left;
}

.nav-who {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin: 0;
  padding: 4px 12px;
  color: var(--faint);
  font-size: 0.75rem;
}

.nav-who span:first-child {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.nav-foot .nav-who a {
  display: inline;
  height: auto;
  padding: 0;
  font-size: 0.75rem;
}

kbd {
  padding: 1px 5px;
  border: 1px solid var(--line-strong);
  border-radius: 4px;
  color: var(--faint);
  font-family: var(--mono);
  font-size: 0.68rem;
}

.admin-main {
  min-width: 0;
  padding: 36px 40px 64px;
  outline: none;
}

/* ---------- page parts ---------- */

.admin-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 24px;
}

.admin-head h1 {
  margin: 6px 0 0;
  font-size: 1.7rem;
  letter-spacing: -0.02em;
}

.admin-lead {
  max-width: 62ch;
  margin: 8px 0 0;
  color: var(--muted);
}

.admin-head-actions {
  display: flex;
  gap: 8px;
}

.admin-card {
  padding: 20px 22px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--surface);
}

.admin-card h2 {
  margin: 0 0 14px;
  font-size: 0.95rem;
}

.admin-card h2.spaced {
  margin-top: 26px;
}

.admin-columns {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(0, 1fr);
  gap: 20px;
  margin-top: 20px;
}

.admin-columns.even {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.subtle {
  color: var(--muted);
}

.block {
  display: block;
}

.empty {
  margin: 24px 0;
  color: var(--muted);
}

/* KPI board: a hero figure and a grid beside it, split by hairlines. */
.kpi-board {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--surface);
}

.kpi-hero {
  padding: 26px 28px;
  border-right: 1px solid var(--border);
}

.kpi-value {
  margin: 8px 0 0;
  font-family: var(--mono);
  font-size: 1.55rem;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.02em;
}

.kpi-value.big {
  font-size: 2.6rem;
}

.kpi-value.small {
  font-size: 1rem;
  overflow-wrap: anywhere;
}

.kpi-hint {
  margin: 6px 0 0;
  color: var(--faint);
  font-size: 0.78rem;
}

.sparkline {
  display: block;
  width: 100%;
  height: 56px;
  margin-top: 20px;
}

.sparkline path {
  fill: none;
  stroke: var(--accent);
  stroke-width: 2;
  stroke-linejoin: round;
  vector-effect: non-scaling-stroke;
}

.spark-axis {
  display: flex;
  justify-content: space-between;
  margin-top: 6px;
  color: var(--faint);
  font-family: var(--mono);
  font-size: 0.66rem;
}

.kpi-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.kpi-grid .kpi {
  padding: 22px 24px;
  border-bottom: 1px solid var(--border);
  border-right: 1px solid var(--border);
}

.kpi-grid .kpi:nth-child(3n) {
  border-right: 0;
}

.kpi-grid .kpi:nth-last-child(-n + 3) {
  border-bottom: 0;
}

.kpi-grid.standalone {
  overflow: hidden;
  margin-bottom: 20px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--surface);
  grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
}

.kpi-grid.standalone .kpi {
  border-right: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  margin: 0 -1px -1px 0;
}

.delta {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-family: var(--mono);
  font-size: 0.75rem;
  font-variant-numeric: tabular-nums;
}

.delta .glyph {
  width: 0;
  height: 0;
  border: 4px solid transparent;
}

.delta.up {
  color: var(--ok);
}

.delta.up .glyph {
  border-bottom: 6px solid currentColor;
  border-top-width: 0;
}

.delta.down {
  color: var(--danger);
}

.delta.down .glyph {
  border-top: 6px solid currentColor;
  border-bottom-width: 0;
}

.delta.flat {
  color: var(--faint);
}

.delta.flat .glyph {
  width: 8px;
  height: 1.5px;
  border: 0;
  background: currentColor;
}

/* Charts: one series in the accent; hairline grid, text in text colours. */
.chart {
  position: relative;
}

.chart svg {
  display: block;
  overflow: visible;
}

.chart .grid {
  stroke: var(--border);
  stroke-width: 1;
}

.chart .axis {
  fill: var(--faint);
  font-family: var(--mono);
  font-size: 10.5px;
}

.chart .bar {
  fill: var(--accent);
}

.chart .line {
  fill: none;
  stroke: var(--accent);
  stroke-width: 2;
  stroke-linejoin: round;
  stroke-linecap: round;
}

.chart .area {
  fill: var(--accent);
  opacity: 0.1;
}

.chart .dot {
  fill: var(--accent);
  stroke: var(--surface);
  stroke-width: 2;
}

.chart .crosshair {
  stroke: var(--line-strong);
  stroke-width: 1;
}

.chart-tip {
  position: absolute;
  top: 0;
  padding: 4px 8px;
  border: 1px solid var(--line-strong);
  border-radius: 6px;
  background: var(--surface-2);
  font-family: var(--mono);
  font-size: 0.72rem;
  white-space: nowrap;
  pointer-events: none;
}

.chart-table {
  margin-top: 10px;
  color: var(--muted);
  font-size: 0.8rem;
}

.chart-table summary {
  cursor: pointer;
}

.chart-table table {
  margin-top: 8px;
  border-collapse: collapse;
}

.chart-table td,
.chart-table th {
  padding: 3px 16px 3px 0;
  text-align: left;
  font-family: var(--mono);
}

.queue-list,
.meters,
.feed,
.checklist,
.feedback-list,
.error-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.queue-list a {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 2px 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
  color: var(--text);
  text-decoration: none;
}

.queue-list strong {
  font-family: var(--mono);
  font-size: 1.1rem;
}

.queue-list strong.alert {
  color: var(--danger);
}

.queue-list .subtle {
  grid-column: 1 / -1;
  font-size: 0.78rem;
}

.meters li {
  display: grid;
  grid-template-columns: 70px 1fr auto;
  align-items: center;
  gap: 10px;
  padding: 6px 0;
  font-size: 0.85rem;
}

.meter {
  height: 6px;
  overflow: hidden;
  border-radius: 999px;
  background: var(--accent-soft);
}

.meter span {
  display: block;
  height: 100%;
  border-radius: 999px;
  background: var(--accent);
}

.meter-value {
  color: var(--muted);
  font-family: var(--mono);
  font-size: 0.75rem;
}

.feed li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 9px 0;
  border-bottom: 1px solid var(--border);
  font-size: 0.85rem;
}

.feed time {
  flex: none;
  color: var(--faint);
  font-family: var(--mono);
  font-size: 0.72rem;
}

.checklist li {
  padding: 6px 0;
  color: var(--faint);
}

.checklist li.on {
  color: var(--text);
}

.checklist li.on span:first-child {
  color: var(--ok);
}

/* Tables and filters */
.admin-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}

.admin-filters input,
.team-form input {
  flex: 1 1 260px;
  width: auto;
  margin: 0;
}

.admin-filters select,
.admin-filters button,
.team-form select,
.team-form button {
  flex: none;
  width: auto;
  margin: 0;
}

.admin-table-wrap {
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--surface);
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.85rem;
}

.admin-table th {
  padding: 10px 14px;
  border-bottom: 1px solid var(--border);
  color: var(--faint);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-align: left;
  text-transform: uppercase;
  white-space: nowrap;
}

.admin-table td {
  padding: 11px 14px;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
}

.admin-table tr:last-child td {
  border-bottom: 0;
}

.admin-table .num {
  font-family: var(--mono);
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.admin-card .admin-table td,
.admin-card .admin-table th {
  padding-left: 0;
}

.admin-card-scroll {
  overflow-x: auto;
}

.chip {
  display: inline-block;
  margin: 0 4px 4px 0;
  padding: 1px 7px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  color: var(--muted);
  font-size: 0.72rem;
}

.role-chip,
.status-chip {
  display: inline-block;
  padding: 1px 8px;
  border-radius: 999px;
  background: var(--surface-2);
  color: var(--muted);
  font-family: var(--mono);
  font-size: 0.7rem;
  text-transform: lowercase;
}

.role-chip.owner,
.status-chip.new {
  background: var(--accent-soft);
  color: var(--accent-strong);
}

.role-chip.admin {
  background: #2b2440;
  color: #c7b6ff;
}

.status-chip.done {
  background: #16302a;
  color: var(--ok);
}

.pager {
  display: flex;
  gap: 8px;
  margin-top: 16px;
}

.tabs {
  display: flex;
  gap: 4px;
  margin-bottom: 16px;
  border-bottom: 1px solid var(--border);
}

.tabs a {
  padding: 8px 12px;
  border-bottom: 2px solid transparent;
  color: var(--muted);
  text-decoration: none;
}

.tabs a[aria-current="page"] {
  border-color: var(--accent);
  color: var(--text);
}

.feedback-list {
  display: grid;
  gap: 12px;
}

.feedback-item.done {
  opacity: 0.7;
}

.feedback-message {
  margin: 0 0 8px;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.feedback-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
}

.error-list {
  display: grid;
  gap: 10px;
}

.error-list summary {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 6px 12px;
  cursor: pointer;
}

.error-count {
  color: var(--danger);
  font-family: var(--mono);
}

.error-title {
  flex: 1 1 300px;
  overflow-wrap: anywhere;
}

.error-list pre {
  max-height: 320px;
  margin: 12px 0 0;
  overflow: auto;
  padding: 12px;
  border-radius: 8px;
  background: var(--bg);
  font-size: 0.75rem;
}

.support-card {
  margin-top: 20px;
}

.danger-zone {
  margin-top: 20px;
  border-color: #4a2329;
}

.team-form {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}


.roles {
  display: grid;
  grid-template-columns: max-content 1fr;
  gap: 10px 16px;
  margin: 0;
}

.roles dd {
  margin: 0;
  color: var(--muted);
}

.table-counts {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 6px 16px;
  margin: 0;
}

.table-counts dt {
  color: var(--muted);
  text-transform: capitalize;
}

.table-counts dd {
  margin: 0;
  font-family: var(--mono);
  text-align: right;
}

/* The ⌘K palette */
dialog:has(.palette) {
  width: min(560px, calc(100vw - 32px));
  margin-top: 12vh;
  padding: 0;
}

.palette input {
  width: 100%;
  padding: 16px;
  border: 0;
  border-bottom: 1px solid var(--border);
  border-radius: 0;
  background: none;
  font-size: 1rem;
}

.palette-results {
  max-height: 50vh;
  margin: 0;
  overflow-y: auto;
  padding: 6px;
  list-style: none;
}

.palette-results a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 10px;
  border-radius: 8px;
  color: var(--text);
  text-decoration: none;
}

.palette-results a:hover,
.palette-results a:focus {
  background: var(--surface-2);
}

.palette-results kbd:first-of-type {
  margin-left: auto;
}

.palette-results li.subtle {
  padding: 10px;
}

/* Signed in, but not on the team */
.admin-blocked {
  display: grid;
  place-items: center;
  min-height: 100dvh;
  padding: 24px;
}

.admin-blocked-card {
  max-width: 420px;
}

.admin-blocked-card h1 {
  margin: 8px 0;
}

.admin-blocked-card p {
  color: var(--muted);
}

/* ---------- smaller screens ---------- */

@media (max-width: 1100px) {
  .admin-columns,
  .admin-columns.even,
  .kpi-board {
    grid-template-columns: minmax(0, 1fr);
  }

  .kpi-hero {
    border-right: 0;
    border-bottom: 1px solid var(--border);
  }
}

@media (max-width: 860px) {
  .admin-top {
    grid-template-columns: minmax(0, 1fr) auto;
    height: auto;
  }

  .admin-brand {
    height: 46px;
    border-right: 0;
  }

  .admin-ticker {
    grid-column: 1 / -1;
    grid-row: 2;
    height: 40px;
    border-top: 1px solid var(--border);
  }

  .admin-palette-button span,
  .admin-palette-button kbd {
    display: none;
  }

  .admin-palette-button::after {
    content: "⌘K";
    font-family: var(--mono);
    font-size: 0.75rem;
  }

  .admin-body {
    display: block;
  }

  .admin-nav {
    position: static;
    height: auto;
    border-right: 0;
    border-bottom: 1px solid var(--border);
  }

  .nav-groups {
    display: flex;
    gap: 4px;
    overflow-x: auto;
    padding: 8px 12px;
    scrollbar-width: none;
  }

  .nav-group {
    display: contents;
  }

  .nav-group .admin-eyebrow,
  .nav-foot {
    display: none;
  }

  .admin-nav a {
    flex-shrink: 0;
    height: 32px;
    gap: 8px;
  }

  .admin-nav a[aria-current="page"]::before {
    display: none;
  }

  .admin-main {
    padding: 24px 16px 48px;
  }

  .kpi-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .kpi-grid .kpi {
    padding: 16px;
  }

  .kpi-grid .kpi:nth-child(3n) {
    border-right: 1px solid var(--border);
  }

  .kpi-grid .kpi:nth-child(2n) {
    border-right: 0;
  }

  .kpi-grid .kpi:nth-last-child(-n + 3) {
    border-bottom: 1px solid var(--border);
  }

  .kpi-grid .kpi:nth-last-child(-n + 2) {
    border-bottom: 0;
  }

  .kpi-hero {
    padding: 20px;
  }

  .kpi-value.big {
    font-size: 2.1rem;
  }
}

/* Growth: funnel and retention */
.spaced-card {
  margin-top: 20px;
}

.funnel {
  margin: 0;
  padding: 0;
  list-style: none;
}

.funnel li {
  display: grid;
  grid-template-columns: minmax(150px, 240px) 1fr minmax(110px, auto);
  align-items: center;
  gap: 12px;
  padding: 9px 0;
  border-bottom: 1px solid var(--border);
  font-size: 0.88rem;
}

.funnel .meter {
  height: 10px;
}

.retention {
  width: 100%;
  border-collapse: separate;
  border-spacing: 2px;
  font-size: 0.82rem;
}

.retention th {
  padding: 6px 8px;
  color: var(--faint);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-align: left;
  text-transform: uppercase;
  white-space: nowrap;
}

.retention th[scope="row"] {
  color: var(--text);
  font-size: 0.82rem;
  letter-spacing: 0;
  text-transform: none;
}

.retention td {
  min-width: 64px;
  padding: 8px;
  border-radius: 4px;
}

.retention .num {
  font-family: var(--mono);
  text-align: right;
}

.retention .cell {
  color: #fff;
}

/* Sync problems */
.error-cell {
  max-width: 420px;
  color: var(--muted);
  overflow-wrap: anywhere;
}

/* Announcements */
.announce-form {
  display: grid;
  gap: 12px;
}

.announce-form label {
  display: grid;
  gap: 6px;
}

.announce-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.announce-row label {
  flex: 1 1 200px;
}

.announce-form label.check {
  display: flex;
  flex-direction: row;
  align-items: baseline;
  gap: 8px;
  font-weight: 400;
}

.announce-form label.check input {
  width: auto;
}

.announce-list {
  display: grid;
  gap: 12px;
  margin: 20px 0 0;
  padding: 0;
  list-style: none;
}

.announce-list .ended {
  opacity: 0.65;
}

.announce-list p {
  margin: 0 0 6px;
}

@media (max-width: 860px) {
  .funnel li {
    grid-template-columns: 1fr auto;
  }

  .funnel .meter {
    grid-column: 1 / -1;
    grid-row: 2;
  }
}

/* Announcement templates */
.templates {
  margin-bottom: 18px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border);
}

.template-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 8px 0;
}

.template-chip {
  display: inline-flex;
  overflow: hidden;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
}

.template-chip.saved {
  border-color: var(--accent);
}

.template-chip button {
  height: auto;
  min-height: 30px;
  padding: 4px 12px;
  border: 0;
  border-radius: 0;
  background: none;
  color: var(--text);
  font-size: 0.82rem;
}

.template-chip button:hover {
  background: var(--surface-2);
}

.template-chip .template-x {
  padding: 4px 10px 4px 6px;
  color: var(--muted);
}

/* Team notes about an account */
.notes-card {
  margin-top: 20px;
}

.note-form {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 8px;
  margin-bottom: 14px;
}

.note-form textarea {
  flex: 1 1 320px;
  width: auto;
  margin: 0;
}

.note-form button {
  flex: none;
  width: auto;
}

.admin-notes {
  margin: 0;
  padding: 0;
  list-style: none;
}

.admin-notes li {
  padding: 10px 0;
  border-top: 1px solid var(--border);
}

.admin-note-body {
  margin: 0 0 4px;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.admin-notes .text-button {
  padding: 0;
  color: var(--danger);
  font-size: inherit;
}

.note-chip {
  margin-left: 6px;
  vertical-align: 1px;
}

.team-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 6px;
}
