/* ============================================================
   URSUS THEME — shared by every page. Dark is the default.
   Light mode = :root[data-theme="light"] overrides.
   Page-specific hardcoded colors are tokenized below; add new
   tokens here rather than hardcoding colors in a page.
   ============================================================ */
:root {
  color-scheme: dark;
  --accent-rgb: 200,146,42;
  --text-rgb: 232,228,217;
  --nav-bg: rgba(10,10,8,0.92);
  --overlay: rgba(10,10,8,0.88);
  --on-accent-soft: rgba(10,10,8,0.65);
  --ghost: rgba(255,255,255,0.025);
  --red-text: #e87060;
  --warn-text: #e57373;
  --faint: #6f6c60;
  --ok-text: #4caf7d;
  --green-text: #4cbc7e;
  --link: #5b9bd5;
  --link-hover: #7fb4e6;
  --invert-bg: #0a0a08;
  --invert-text: #c8922a;
}

:root[data-theme="light"] {
  color-scheme: light;
  --black: #f2f2f3;
  --dark: #e8e8ea;
  --surface: #fafafa;
  --surface2: #dcdcdf;
  --border: rgba(0,0,0,0.12);
  --border2: rgba(0,0,0,0.24);
  --text: #000000;
  --muted: #000000;
  --accent: #7a520a;      /* darkened gold: readable as text on light */
  --accent2: #946310;
  --green: #1f7a46;
  --red: #b03226;
  --accent-rgb: 122,82,10;
  --text-rgb: 0,0,0;
  --nav-bg: rgba(242,242,243,0.92);
  --overlay: rgba(242,242,243,0.92);
  --on-accent-soft: rgba(250,250,250,0.8);
  --ghost: rgba(0,0,0,0.04);
  --red-text: #a12b20;
  --warn-text: #a12b20;
  --faint: #2a2a2d;
  --ok-text: #1f7a46;
  --green-text: #1f7a46;
  --link: #1d5fa3;
  --link-hover: #144a82;
  --invert-bg: #1a1a1c;
  --invert-text: #e8a830;
}

/* Buttons that are dark-on-gold in dark mode */
.btn-dark { background: var(--invert-bg); color: var(--invert-text); }
:root[data-theme="light"] .btn-dark:hover { background: #000; }

/* Smooth switch (class added briefly by theme.js) */
html.theme-anim *, html.theme-anim *::before, html.theme-anim *::after {
  transition: background-color .25s ease, color .25s ease, border-color .25s ease !important;
}

/* ── Toggle button (injected into .nav-right by theme.js) ── */
.nav-theme-btn {
  position: relative; flex-shrink: 0; padding: 0;
  width: 38px; height: 38px;
  display: flex; align-items: center; justify-content: center;
  background: transparent; color: var(--text);
  border: 1px solid var(--border2); cursor: pointer;
  transition: border-color .2s, background .2s;
}
.nav-theme-btn:hover, .nav-theme-btn:focus-visible {
  border-color: var(--accent); background: rgba(var(--accent-rgb),0.06); outline: none;
}
.nav-theme-btn svg {
  width: 18px; height: 18px; fill: none; stroke: currentColor;
  stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round;
  transition: stroke .2s;
}
.nav-theme-btn:hover svg, .nav-theme-btn:focus-visible svg { stroke: var(--accent); }
.nav-theme-btn .i-moon { display: none; }
:root[data-theme="light"] .nav-theme-btn .i-sun  { display: none; }
:root[data-theme="light"] .nav-theme-btn .i-moon { display: block; }

/* ── Legibility: heavier weights (both themes) ── */
body { font-weight: 500; }
.product-desc, .serial-desc, .features-aside p { font-weight: 500; }
.nav-slogan { font-weight: 600; }

/* Light only: no faded text */
:root[data-theme="light"] .footer-col a,
:root[data-theme="light"] .footer-legal,
:root[data-theme="light"] .footer-logo,
:root[data-theme="light"] .review-product { opacity: 1; }
