/* ── Panel header ─────────────────────────────────────────────── */

.panel__head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}

.panel__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: end;
}

/* ── Benchmark config ─────────────────────────────────────────── */

.benchmark-config {
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
  margin-bottom: 1rem;
  padding: 0.95rem;
  transition: all 0.2s ease-in-out;
}

.benchmark-config__head {
  display: flex;
  justify-content: space-between;
  align-items: start;
  gap: 1rem;
}

.benchmark-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.75rem;
}

.benchmark-grid label {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  color: var(--muted);
  font-size: 0.82rem;
}

/* ── Shared form inputs (benchmark + holdings table) ─────────── */

.benchmark-grid input,
.benchmark-grid select,
.holdings-table input,
.holdings-table select {
  width: 100%;
  padding: 0.65rem 0.7rem;
  border-radius: 0.75rem;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  min-width: 5.5rem;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.benchmark-grid select { padding-right: 1.8rem; }

.benchmark-grid select option,
.holdings-table select option {
  background-color: #121824;
  color: #eff4ff;
}

.benchmark-grid input::placeholder,
.holdings-table input::placeholder {
  color: rgba(239, 244, 255, 0.46);
}

/* ── Holdings table ───────────────────────────────────────────── */

.table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border-radius: 1rem;
  border: 1px solid rgba(255, 255, 255, 0.06);
  margin-top: 0.5rem;
  margin-bottom: 0.5rem;
}

.holdings-table {
  width: 100%;
  border-collapse: collapse;
}

.holdings-table thead th {
  position: sticky;
  top: 0;
  background: rgba(8, 13, 26, 0.95);
  text-align: left;
  padding: 0.85rem 0.9rem;
  color: var(--muted);
  font-size: 0.85rem;
  letter-spacing: 0.04em;
  z-index: 1;
}

.holdings-table tbody td {
  padding: 0.7rem 0.9rem;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.pledge-danger  { border-left: 5px solid #ff4d5f; }
.pledge-caution { border-left: 5px solid #ffc107; }

/* ── Quote cards ──────────────────────────────────────────────── */

.quotes-list {
  display: grid;
  gap: 0.75rem;
  overflow-y: auto;
  min-height: 0;
  padding-right: 0.2rem;
}

.quote-card {
  padding: 0.95rem 1rem;
  border-radius: 1rem;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  overflow: clip;
}

.quote-card--empty {
  color: var(--muted);
  line-height: 1.5;
}

.quote-card__top {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  align-items: start;
}

.quote-card__top h3 { font-size: 1.05rem; }

.quote-card__top p,
.quote-card__metrics span {
  color: var(--muted);
  font-size: 0.84rem;
}

.quote-card__metrics {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.8rem;
  margin-top: 0.75rem;
}

.quote-card__metrics strong {
  font-family: 'JetBrains Mono', monospace;
  font-size: 1.45rem;
  letter-spacing: -0.03em;
}
