/* ATLAS V6 — Transactions page
 *
 * Mirrors v6-listings.css pattern: layers V6 cream surface + gold accent on
 * the existing `#view-transactions .tx-*` selectors from v5-transactions.css.
 * The V5 sheet still loads (deferred) — JS render in js/transactions.js
 * continues outputting `.tx-card / .tx-status-chip / .tx-figure-val` etc.,
 * and these selectors win via load order (loads after v5-transactions and
 * after v6-listings in index.html).
 *
 * Single theme — light only (`.claude/rules/atlas-dashboard.md` hard rule #4).
 * No `[data-theme="dark"]` block; v6-lock.css retires the toggle.
 *
 * DATA INTEGRITY: the JS render is the only emitter of address/price/agent;
 * this sheet only styles containers and never hardcodes a transaction fact.
 * ─────────────────────────────────────────────────────────────────────── */

/* ── Page header — V6 eyebrow + boardroom H1 + lede ─────────────────────── */
#view-transactions .tx-header,
[data-view="transactions"] .tx-header {
  padding: 0 0 14px;
  border-bottom: 0;
}
#view-transactions .tx-eyebrow,
[data-view="transactions"] .tx-eyebrow {
  font: 900 11px/1 var(--font-ui, Inter, "Segoe UI", system-ui);
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--muted, #8a95a3);
  margin-bottom: 6px;
}
#view-transactions .tx-title,
[data-view="transactions"] .tx-title {
  font: 850 28px/1.1 var(--font-display, "Aptos Display", Inter, system-ui);
  color: #101722;
  letter-spacing: -0.005em;
}
#view-transactions .tx-org-sub,
[data-view="transactions"] .tx-org-sub {
  font-size: 13px;
  color: var(--muted, #647184);
}

/* New-loop CTA — V6 gold action button */
#view-transactions .tx-new-btn,
[data-view="transactions"] .tx-new-btn {
  background: linear-gradient(180deg, var(--gold), #c18a25);
  color: #1a1206;
  border-color: transparent;
}
#view-transactions .tx-new-btn:hover,
[data-view="transactions"] .tx-new-btn:hover {
  background: linear-gradient(180deg, #e2b657, #ce9930);
  color: #1a1206;
  box-shadow: 0 4px 16px rgba(193, 138, 37, 0.28);
}
#view-transactions .tx-new-btn:focus-visible,
[data-view="transactions"] .tx-new-btn:focus-visible {
  outline: 2px solid var(--gold, #c18a25);
}

/* ── Summary strip — V6 summary tile pattern (4 stat tiles) ─────────────── */
#view-transactions .tx-strip,
[data-view="transactions"] .tx-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  padding: 0 0 14px;
  border-bottom: 0;
}
#view-transactions .tx-stat,
[data-view="transactions"] .tx-stat {
  background: rgba(255, 253, 248, 0.94);
  border: 1px solid #d7d0c3;
  border-right: 1px solid #d7d0c3;
  border-radius: 8px;
  padding: 14px 16px;
  box-shadow: 0 10px 24px rgba(29, 24, 14, 0.07);
}
#view-transactions .tx-stat:last-child,
[data-view="transactions"] .tx-stat:last-child { border-right: 1px solid #d7d0c3; }
#view-transactions .tx-stat-label,
[data-view="transactions"] .tx-stat-label {
  color: #647184;
  font-size: 11px;
  letter-spacing: 0.06em;
}
#view-transactions .tx-stat-val,
[data-view="transactions"] .tx-stat-val {
  color: #101722;
  font: 850 26px/1.1 var(--font-display, "Aptos Display", Inter);
}
#view-transactions .tx-stat-val.champagne,
[data-view="transactions"] .tx-stat-val.champagne { color: var(--gold, #c18a25); }
#view-transactions .tx-stat-val.good,
[data-view="transactions"] .tx-stat-val.good { color: #17623a; }

/* ── Filter bar — V6 chip pattern ──────────────────────────────────────── */
#view-transactions .tx-filterbar,
[data-view="transactions"] .tx-filterbar {
  padding: 0 0 12px;
  border-bottom: 0;
}
#view-transactions .tx-filter-btn,
[data-view="transactions"] .tx-filter-btn {
  color: #647184;
  font: 750 13px var(--font-ui, Inter);
  background: transparent;
  border: 0;
}
#view-transactions .tx-filter-btn:hover,
[data-view="transactions"] .tx-filter-btn:hover { color: #101722; }
#view-transactions .tx-filter-btn::after,
[data-view="transactions"] .tx-filter-btn::after {
  background: var(--gold, #c18a25);
}
#view-transactions .tx-filter-btn.active,
[data-view="transactions"] .tx-filter-btn.active { color: var(--gold, #c18a25); }
#view-transactions .tx-filter-count,
[data-view="transactions"] .tx-filter-count {
  background: #fbecd0;
  color: #7a4a0a;
  border-radius: 999px;
  padding: 1px 8px;
  font: 800 11px monospace;
}

/* Search */
#view-transactions .tx-search,
[data-view="transactions"] .tx-search {
  background: #f0eee8;
  border: 1px solid #d7d0c3;
  border-radius: 8px;
  padding: 0 12px;
  height: 38px;
}
#view-transactions .tx-search svg,
[data-view="transactions"] .tx-search svg { color: #8a95a3; }
#view-transactions .tx-search input,
[data-view="transactions"] .tx-search input {
  color: #101722;
  background: transparent;
  font-size: 14px;
}
#view-transactions .tx-search input::placeholder,
[data-view="transactions"] .tx-search input::placeholder { color: #8a95a3; }
#view-transactions .tx-search input:focus,
[data-view="transactions"] .tx-search:focus-within {
  background: #fffdf8;
  border-color: var(--gold, #c18a25);
}

/* ── Grid + sync banner ─────────────────────────────────────────────────── */
#view-transactions .tx-grid,
[data-view="transactions"] .tx-grid {
  padding: 0;
  flex: 1;
  overflow-y: auto;
}
#view-transactions .tx-syncbanner,
[data-view="transactions"] .tx-syncbanner {
  background: #fbecd0;
  border: 1px solid #e8c87a;
  color: #7a4a0a;
  border-radius: 8px;
  padding: 9px 13px;
  font: 600 12px var(--font-ui, Inter);
}

/* ── Card — cream surface with V6 lift on hover ─────────────────────────── */
#view-transactions .tx-card,
[data-view="transactions"] .tx-card {
  background: rgba(255, 253, 248, 0.96);
  border: 1px solid #d7d0c3;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(29, 24, 14, 0.06);
}
#view-transactions .tx-card:hover,
[data-view="transactions"] .tx-card:hover {
  border-color: var(--gold, #c18a25);
  box-shadow: 0 14px 30px rgba(29, 24, 14, 0.14);
  transform: translateY(-2px);
}

/* Card state accents (left border) */
#view-transactions .tx-card.tx-active,
[data-view="transactions"] .tx-card.tx-active { border-left: 3px solid var(--gold, #c18a25); }
#view-transactions .tx-card.tx-closed,
[data-view="transactions"] .tx-card.tx-closed { border-left: 3px solid #17623a; }
#view-transactions .tx-card.tx-attention,
[data-view="transactions"] .tx-card.tx-attention {
  border-left: 3px solid #c79444;
  background: rgba(251, 236, 208, 0.55);
}

/* Status chip */
#view-transactions .tx-status-chip,
[data-view="transactions"] .tx-status-chip {
  font: 800 11px var(--font-ui, Inter);
  letter-spacing: 0.05em;
  padding: 3px 9px;
  border-radius: 4px;
}
#view-transactions .tx-status-chip.under-contract,
[data-view="transactions"] .tx-status-chip.under-contract { background: #e0e9fb; color: #17468e; }
#view-transactions .tx-status-chip.pending,
[data-view="transactions"] .tx-status-chip.pending { background: #fbecd0; color: #7a4a0a; }
#view-transactions .tx-status-chip.attention,
[data-view="transactions"] .tx-status-chip.attention { background: #fde1ea; color: #9c1844; }
#view-transactions .tx-status-chip.closed,
[data-view="transactions"] .tx-status-chip.closed { background: #dff2e7; color: #17623a; }

/* Side indicators (Listing / Buying) */
#view-transactions .tx-side-listing,
[data-view="transactions"] .tx-side-listing { color: var(--gold, #c18a25); }
#view-transactions .tx-side-buying,
[data-view="transactions"] .tx-side-buying { color: #17468e; }

/* Days counter */
#view-transactions .tx-days,
[data-view="transactions"] .tx-days {
  background: #f6f3ec;
  border: 1px solid #ebe7de;
  border-radius: 8px;
  padding: 6px 10px;
}
#view-transactions .tx-days-num,
[data-view="transactions"] .tx-days-num {
  color: #101722;
  font: 800 18px var(--font-display, "Aptos Display", Inter);
}
#view-transactions .tx-days-lab,
[data-view="transactions"] .tx-days-lab {
  color: #647184;
  font-size: 10px;
  letter-spacing: 0.06em;
}

/* Address + parties */
#view-transactions .tx-address,
[data-view="transactions"] .tx-address {
  color: #101722;
  font: 700 15px var(--font-ui, Inter);
}
#view-transactions .tx-parties,
[data-view="transactions"] .tx-parties { color: #647184; }
#view-transactions .tx-parties strong,
[data-view="transactions"] .tx-parties strong { color: #101722; }

/* Figures row */
#view-transactions .tx-figure,
[data-view="transactions"] .tx-figure { border-color: #ebe7de; }
#view-transactions .tx-figure + .tx-figure,
[data-view="transactions"] .tx-figure + .tx-figure { border-left: 1px solid #ebe7de; }
#view-transactions .tx-figure-lab,
[data-view="transactions"] .tx-figure-lab { color: #647184; }
#view-transactions .tx-figure-val,
[data-view="transactions"] .tx-figure-val { color: #101722; }
#view-transactions .tx-figure-val.price,
[data-view="transactions"] .tx-figure-val.price { color: var(--gold, #c18a25); }
#view-transactions .tx-figure-val.soon,
[data-view="transactions"] .tx-figure-val.soon { color: #c79444; }
#view-transactions .tx-figure-val .tx-close-soon,
[data-view="transactions"] .tx-figure-val .tx-close-soon { color: #9c1844; }

/* Agent block */
#view-transactions .tx-agent,
[data-view="transactions"] .tx-agent { color: #647184; }
#view-transactions .tx-agent strong,
[data-view="transactions"] .tx-agent strong { color: #101722; }
#view-transactions .tx-agent-avatar,
[data-view="transactions"] .tx-agent-avatar {
  background: linear-gradient(135deg, #0f857c, var(--gold, #c18a25));
  color: #fff;
}

/* Action buttons */
#view-transactions .tx-act,
[data-view="transactions"] .tx-act {
  background: #fffdf8;
  border: 1px solid #d7d0c3;
  color: #101722;
  font: 750 12px var(--font-ui, Inter);
}
#view-transactions .tx-act:hover,
[data-view="transactions"] .tx-act:hover {
  background: #fff;
  border-color: var(--gold, #c18a25);
  color: #7a4a0a;
}
#view-transactions .tx-act:focus-visible,
[data-view="transactions"] .tx-act:focus-visible {
  outline: 2px solid var(--gold, #c18a25);
}
#view-transactions .tx-act.primary,
[data-view="transactions"] .tx-act.primary {
  background: linear-gradient(180deg, var(--gold), #c18a25);
  color: #1a1206;
  border-color: transparent;
}

/* Empty state */
#view-transactions .tx-empty,
[data-view="transactions"] .tx-empty {
  background: rgba(255, 253, 248, 0.6);
  border: 1px dashed #d7d0c3;
  border-radius: 12px;
  padding: 48px 24px;
  color: #647184;
  text-align: center;
}
#view-transactions .tx-empty-title,
[data-view="transactions"] .tx-empty-title { color: #101722; font-weight: 700; }
#view-transactions .tx-empty-sub,
[data-view="transactions"] .tx-empty-sub { color: #647184; }
