/* pages.css — компоненты страниц (admin, journal, voice, banner) */

/* === Журнал событий timeline === */
.tl { list-style: none; padding: 0; margin: 0; }
.tl__item {
  position: relative;
  padding: var(--sp-2) 0 var(--sp-2) var(--sp-6);
  font-size: 14px;
}
.tl__item::before {
  content: ''; position: absolute; left: 4px; top: 14px;
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--c-brand);
}
.tl__item::after {
  content: ''; position: absolute; left: 7px; top: 22px; bottom: -4px;
  width: 2px; background: var(--c-border);
}
.tl__item:last-child::after { display: none; }
.tl__time { font-size: 12px; color: var(--c-muted); }

/* === Admin sidebar layout === */
.admin-layout {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: var(--sp-6);
  align-items: start;
}
@media (max-width: 900px) { .admin-layout { grid-template-columns: 1fr; } }
.admin-sidebar {
  background: var(--c-surface);
  border-radius: var(--r-md);
  border: 1px solid var(--c-border);
  padding: var(--sp-3);
}
.admin-sidebar a {
  display: block; padding: var(--sp-2) var(--sp-3);
  color: var(--c-text); text-decoration: none;
  border-radius: var(--r-sm);
  font-size: 14px;
}
.admin-sidebar a:hover { background: var(--c-bg); }
.admin-sidebar a.is-active { background: var(--c-brand-50); color: var(--c-brand-dark); font-weight: 500; }

/* === Tabs === */
.tabs {
  display: inline-flex; gap: 4px;
  padding: 4px;
  background: var(--c-bg);
  border-radius: var(--r-pill);
}
.tabs__tab {
  padding: 6px 14px;
  border-radius: var(--r-pill);
  font-size: 14px; font-weight: 500;
  color: var(--c-muted);
  background: transparent; border: 0; cursor: pointer;
}
.tabs__tab[aria-selected="true"] {
  background: var(--c-surface); color: var(--c-text);
  box-shadow: var(--shadow-1);
}

/* === KV grid === */
.kv {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: var(--sp-3);
}
.kv__label { font-size: 11px; color: var(--c-muted); text-transform: uppercase; letter-spacing: .06em; font-weight: 500; }
.kv__value { font-size: 16px; font-weight: 500; color: var(--c-text); margin-top: 2px; }

/* === Voice recorder UI === */
.voice-recorder {
  background: var(--c-bg);
  border-radius: var(--r-md);
  padding: var(--sp-3);
  display: flex; flex-direction: column; gap: var(--sp-2);
}
.voice-recorder__draft {
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--r-sm);
  padding: var(--sp-3);
  font-size: 14px; min-height: 56px;
  white-space: pre-wrap;
}
.voice-recorder__timer { font-variant-numeric: tabular-nums; color: var(--c-danger-text); }

/* === Утилиты страниц (вместо inline style) === */
.h2-section { font-size: 18px; margin: 0 0 12px; }
.h2-inline  { margin: 0; }
.group-title { font-size: 16px; margin: 24px 0 8px; }

.section-card-danger { border-left: 4px solid var(--c-danger); }
.section-card-danger ul,
.section-card-danger ul li { list-style: none; padding: 0; margin: 0; }
.section-card-danger li { padding: 8px 0; border-bottom: 1px solid var(--c-border); }
.section-card-danger li:last-child { border-bottom: 0; }

.deal-id      { font-size: 14px; color: var(--c-muted); }
.deal-address { font-size: 18px; font-weight: 500; }

.deal-card-title { font-size: 16px; font-weight: 500; color: var(--c-text); }

.card-link { display: block; text-decoration: none; }
.card-link:hover { text-decoration: none; }

.recent-cache-title { font-size: 18px; margin-bottom: 12px; }

.icon-danger  { color: var(--c-danger); }
.icon-warning { color: var(--c-warning); }
.icon-muted   { color: var(--c-muted); }

.p0 { margin: 0; }
.pt-48 { padding-top: 48px; }
.pt-64 { padding-top: 64px; }

.inline-block { display: inline-block; }
.inline-flex { display: inline-flex; }

.badge-icon-row { display: flex; padding: 8px 12px; }

.monoline {
  font-family: ui-monospace, 'SF Mono', Menlo, monospace;
  font-size: 13px;
  min-height: 56px;
}

.svg-sprite-host { position: absolute; width: 0; height: 0; }

/* admin tables */
.admin-table { width: 100%; border-collapse: collapse; }
.admin-table thead th { text-align: left; border-bottom: 1px solid var(--c-border); padding: 12px 0; }
.admin-table tbody tr { border-bottom: 1px solid var(--c-border); }
.admin-table tbody td { padding: 12px 0; vertical-align: top; }
.admin-table td.cell-actions { text-align: right; }
.admin-table td.cell-code,
.admin-table th.cell-code { font-family: ui-monospace, monospace; font-size: 13px; }

