.reports-page {
  max-width: 1500px;
}

.reports-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 18px;
  margin-bottom: 18px;
}

.reports-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.reports-actions select,
.custom-date-row input,
.reports-panel-header input,
.campaign-panel-actions select {
  border: 1px solid #334155;
  border-radius: 10px;
  padding: 12px;
  background: #020617;
  color: white;
}

.custom-date-row {
  display: flex;
  gap: 10px;
  margin-bottom: 18px;
  flex-wrap: wrap;
}

.report-card-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 14px;
  margin-bottom: 20px;
}

.report-card {
  background: #0f172a;
  border: 1px solid #334155;
  border-radius: 16px;
  padding: 18px;
}

.report-card p {
  margin: 0;
  color: #94a3b8;
}

.report-card h2 {
  margin: 8px 0 0;
  font-size: 34px;
}

.report-tabs {
  display: flex;
  gap: 10px;
  margin-bottom: 10px;
}

.report-tabs button {
  background: #0f172a;
  color: white;
  border: 1px solid #334155;
  padding: 14px 18px;
  border-radius: 12px;
  cursor: pointer;
  font-weight: 800;
}

.report-tabs button.active {
  background: #2563eb;
  border-color: #2563eb;
}

.reports-panel {
  background: #0f172a;
  border: 1px solid #334155;
  border-radius: 16px;
  padding: 18px;
  margin-bottom: 18px;
}

.reports-panel-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
}

.reports-panel-header h2 {
  margin: 0;
}

.reports-panel-header p {
  margin: 4px 0 0;
  color: #94a3b8;
}

.campaign-panel-actions {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}

.campaign-panel-actions select {
  min-width: 190px;
}

.ab-compare-notice {
  margin-bottom: 14px;
  padding: 12px 14px;
  background: rgba(37, 99, 235, 0.12);
  border: 1px solid rgba(37, 99, 235, 0.28);
  color: #bfdbfe;
  border-radius: 12px;
  font-size: 13px;
  line-height: 1.5;
}

.reports-table-wrap {
  overflow-x: auto;
}

.reports-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 900px;
}

#abCompareTable {
  min-width: 1450px;
}

.reports-table th,
.reports-table td {
  padding: 13px;
  border-bottom: 1px solid #334155;
  text-align: left;
}

.reports-table th {
  color: #93c5fd;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.reports-table td:nth-child(3),
.reports-table td:nth-child(4),
.reports-table td:nth-child(5),
.reports-table td:nth-child(6),
.reports-table td:nth-child(7) {
  text-align: right;
}

#abCompareTable td:nth-child(2),
#abCompareTable td:nth-child(3),
#abCompareTable td:nth-child(4),
#abCompareTable td:nth-child(5),
#abCompareTable td:nth-child(6),
#abCompareTable td:nth-child(7),
#abCompareTable td:nth-child(8),
#abCompareTable td:nth-child(9),
#abCompareTable td:nth-child(10),
#abCompareTable td:nth-child(11) {
  text-align: right;
}

.rate-pill,
.ab-result-pill,
.ab-type-pill {
  display: inline-flex;
  padding: 5px 9px;
  border-radius: 999px;
  font-weight: 800;
}

.rate-good {
  background: rgba(34, 197, 94, 0.15);
  color: #4ade80;
}

.rate-mid {
  background: rgba(250, 204, 21, 0.15);
  color: #facc15;
}

.rate-bad {
  background: rgba(239, 68, 68, 0.15);
  color: #f87171;
}

.ab-result-good {
  background: rgba(34, 197, 94, 0.15);
  color: #4ade80;
}

.ab-result-mid {
  background: rgba(250, 204, 21, 0.15);
  color: #facc15;
}

.ab-result-bad {
  background: rgba(239, 68, 68, 0.15);
  color: #f87171;
}

.ab-type-pill {
  margin-left: 8px;
  font-size: 11px;
  padding: 4px 8px;
  background: rgba(59, 130, 246, 0.15);
  color: #93c5fd;
}

.ab-link-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.ab-link-row a {
  color: #93c5fd;
  text-decoration: none;
  font-weight: 800;
}

.ab-link-row a:hover {
  text-decoration: underline;
}

.missing-value {
  color: #64748b;
}

.hidden {
  display: none !important;
}

@media (max-width: 1000px) {
  .reports-header,
  .reports-panel-header {
    flex-direction: column;
    align-items: stretch;
  }

  .report-card-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .reports-actions,
  .reports-actions button,
  .reports-actions select,
  .custom-date-row input,
  .custom-date-row button,
  .reports-panel-header input,
  .campaign-panel-actions,
  .campaign-panel-actions select {
    width: 100%;
  }
}
