/* ============================================
   Marketing Reports Dashboard — Custom Styles
   ============================================ */

/* --- Custom primary color: #0c3b66 --- */
[data-md-color-primary="custom"] {
  --md-primary-fg-color: #0c3b66;
  --md-primary-fg-color--light: #1a5a9e;
  --md-primary-fg-color--dark: #082a4a;
  --md-primary-bg-color: #ffffff;
  --md-primary-bg-color--light: #ffffffb3;
}

[data-md-color-scheme="slate"][data-md-color-primary="custom"] {
  --md-primary-fg-color: #1a5a9e;
  --md-primary-fg-color--light: #2d7ad4;
  --md-primary-fg-color--dark: #0c3b66;
  --md-primary-bg-color: #ffffff;
  --md-primary-bg-color--light: #ffffffb3;
}

/* --- Tables: professional data styling --- */
.md-typeset table:not([class]) {
  border: 1px solid var(--md-default-fg-color--lightest);
  border-radius: 6px;
  overflow: hidden;
  font-size: 0.82rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
}

.md-typeset table:not([class]) thead {
  background: var(--md-primary-fg-color);
  color: var(--md-primary-bg-color);
}

.md-typeset table:not([class]) thead th {
  font-weight: 600;
  text-transform: uppercase;
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  padding: 0.7em 1em;
  border-bottom: 2px solid var(--md-primary-fg-color--dark);
}

.md-typeset table:not([class]) tbody tr:nth-child(even) {
  background: var(--md-default-fg-color--lightest);
}

.md-typeset table:not([class]) tbody tr:hover {
  background: color-mix(in srgb, var(--md-accent-fg-color) 10%, transparent);
}

.md-typeset table:not([class]) td {
  padding: 0.6em 1em;
  border-top: 1px solid var(--md-default-fg-color--lightest);
}

/* Right-align numeric columns (2nd column onward) */
.md-typeset table:not([class]) td:not(:first-child) {
  text-align: right;
}

.md-typeset table:not([class]) th:not(:first-child) {
  text-align: right;
}

/* --- Metric signals: color-coded deltas --- */
.md-typeset strong {
  /* Keep default for regular bold */
}

/* --- H1: report title styling --- */
.md-typeset h1 {
  font-weight: 700;
  border-bottom: 3px solid var(--md-primary-fg-color);
  padding-bottom: 0.3em;
  margin-bottom: 0.8em;
}

/* --- H2: section headers --- */
.md-typeset h2 {
  color: var(--md-primary-fg-color);
  font-weight: 600;
  margin-top: 2em;
  padding-bottom: 0.2em;
  border-bottom: 1px solid var(--md-default-fg-color--lightest);
}

/* --- Blockquotes: callout styling --- */
.md-typeset blockquote {
  border-left: 4px solid var(--md-accent-fg-color);
  background: color-mix(in srgb, var(--md-accent-fg-color) 6%, transparent);
  padding: 0.8em 1.2em;
  border-radius: 0 6px 6px 0;
  margin: 1em 0;
}

/* --- HR: subtle section dividers --- */
.md-typeset hr {
  border: none;
  height: 1px;
  background: linear-gradient(
    to right,
    transparent,
    var(--md-default-fg-color--lighter),
    transparent
  );
  margin: 2.5em 0;
}

/* --- Dashboard home: recent reports table link styling --- */
.md-typeset table a {
  font-weight: 500;
}

/* --- Compact admonitions for summaries --- */
.md-typeset .admonition {
  font-size: 0.88rem;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.1);
}

/* --- Print styles --- */
@media print {
  .md-typeset table:not([class]) thead {
    background: #d6e4f0 !important;
    color: #0c3b66 !important;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }

  .md-typeset table:not([class]) tbody tr:nth-child(even) {
    background: #f5f5f5 !important;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }
}
