/*
Theme Name: Blockbase Child
Template: blockbase
*/

body.dark-mode {
  --wp--preset--color--bg:           #0E0905;
  --wp--preset--color--surface:      #1A1108;
  --wp--preset--color--text:         #E8D5B7;
  --wp--preset--color--muted:        #7A5C3A;
  --wp--preset--color--accent:       #D4822A;
  --wp--preset--color--header:       #E8D5B7;
  --wp--preset--color--table-bg:     #2D2421;
  --wp--preset--color--table-row:    #3D2B1F;
  --wp--preset--color--table-border: #52443E;
  --wp--preset--color--table-header: #BCA38F;
  --wp--preset--color--table-text:   #C7B8B0;
}

/* Table */
.wp-block-table table {
  border: none !important;
  border-collapse: collapse !important;
  font-size: 0.95em;
  width: 100%;
}

.wp-block-table tr:nth-child(odd) td {
  background-color: var(--wp--preset--color--table-row);
  color: var(--wp--preset--color--table-text);
}

.wp-block-table tr:nth-child(even) td {
  background-color: transparent;
  color: var(--wp--preset--color--table-text);
}

.wp-block-table td,
.wp-block-table th {
  border: none !important;
  text-align: left !important;
}

.wp-block-table th {
  background-color: transparent;
  color: var(--wp--preset--color--accent);
  border-bottom: 2px solid var(--wp--preset--color--accent) !important;

}


/* Toggle button */
#theme-toggle {
  position: fixed;
  bottom: 28px; right: 28px;
  z-index: 9999;
  width: 64px; height: 32px;
  border-radius: 50px;
  cursor: pointer;
  background: var(--wp--preset--color--surface);
  border: 1px solid var(--wp--preset--color--muted);
  transition: background 0.9s;
  box-shadow: 0 2px 12px rgba(0,0,0,0.3);
  padding: 0;
}
body.dark-mode #theme-toggle { background: #1A1108; border: 1px solid var(--wp--preset--color--muted); }

#theme-toggle .toggle-thumb {
  position: absolute;
  top: 4px; left: 4px;
  width: 24px; height: 24px;
  border-radius: 50%;
  background: #fff;
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  display: flex; align-items: center; justify-content: center;
  font-size: 13px;
}
body.dark-mode #theme-toggle .toggle-thumb { transform: translateX(32px); }


/* NEW STYLING FROM CLAUDE CODE */
/* ── Affiliate Disclosure ─────────────────────────────────── */
.affiliate-disclosure {
  background: var(--wp--preset--color--surface);
  border-left: 4px solid var(--wp--preset--color--accent);
  padding: 12px 16px;
  font-size: 0.9em;
  margin-bottom: 2em;
  color: var(--wp--preset--color--text);
}

/* ── Tables ───────────────────────────────────────────────── */

.wp-block-table th {
  padding: 10px 14px;
  text-align: left !important;
  font-weight: 600;
}

.wp-block-table td {
  padding: 9px 14px;
  border-bottom: 1px solid var(--wp--preset--color--muted);
  color: var(--wp--preset--color--text);
}

.wp-block-table tbody tr:last-child td {
  border-bottom: none;
}

/* Striped rows */
.wp-block-table tr:nth-child(odd) td,
.wp-block-table.is-style-stripes tbody tr:nth-child(odd) {
  background-color: var(--wp--preset--color--table-row);
}

.wp-block-table tr:nth-child(even) td,
.wp-block-table.is-style-stripes tbody tr:nth-child(even) {
  background-color: transparent;
}

.wp-block-table.is-style-stripes {
  border-bottom: none;
}

/* Caption */
.wp-block-table figcaption {
  font-size: 0.85em;
  color: var(--wp--preset--color--muted);
  margin-top: 8px;
  text-align: left;
}

/* Table note */
.table-note {
  font-size: 0.9em;
  color: var(--wp--preset--color--muted);
  margin-top: 8px;
}

/* ── Blockquotes ──────────────────────────────────────────── */
.wp-block-quote.is-style-plain {
  border-left: 4px solid var(--wp--preset--color--accent);
  margin: 1.5em 0;
  padding: 12px 20px;
  background: var(--wp--preset--color--surface);
  font-style: italic;
  color: var(--wp--preset--color--text);
}

.wp-block-quote.is-style-plain cite {
  display: none;
}

/* Verdict box — keeping green as it's semantic (positive/go) */
.wp-block-quote.verdict-box {
  border-left: 4px solid #2c7a4b;
  margin: 1.5em 0;
  padding: 14px 20px;
  background: var(--wp--preset--color--surface);
  font-style: normal;
  color: var(--wp--preset--color--text);
}

.wp-block-quote.verdict-box p:last-child {
  margin-bottom: 0;
}

/* ── Sources ──────────────────────────────────────────────── */
.sources-heading {
  font-size: 1em;
  color: var(--wp--preset--color--muted);
  margin-top: 3em;
  border-top: 1px solid var(--wp--preset--color--muted);
  padding-top: 1.5em;
}

.sources-list {
  font-size: 0.85em;
  color: var(--wp--preset--color--muted);
  line-height: 1.8;
}

.sources-list a {
  color: inherit;
}

/* Verdict box dark mode — soften the green */
body.dark-mode .wp-block-quote.verdict-box {
  border-left-color: #3a9e63;
  background: #0E1A12;
}
