/* ============================================================
   SHAHI / ROYAL THEME — loaded LAST (index.php injects before </body>).
   60/30/10: oat #EEE5D4 canvas | forest #1D4A35 structure | tomato accents.
   Cascade order: canvas -> ink -> dark surfaces -> controls -> buttons (last).
   ============================================================ */
:root {
  --oat:            #EEE5D4;
  --oat-soft:       #D9CFBB;
  --oat-mute:       #C2B7A0;
  --forest:         #1D4A35;
  --forest-deep:    #123326;
  --forest-mid:     #3E5C4B;   /* muted ink on oat, 5.9:1 */
  --forest-ink:     #9BC7B2;
  --tomato:         #F2462E;   /* bright accents / borders only */
  --tomato-ink:     #B92D19;   /* text + links on oat, 4.9:1 */
  --tomato-btn:     #BE2C19;   /* button fill, oat text 4.7:1 */
  --tomato-btn-deep:#9E2312;
  --accent-dark:    #FF9B86;   /* accent text on forest, 4.9:1 */
  --gempanel-fg:        var(--oat);
  --gempanel-muted:     var(--oat-soft);
  --gempanel-accent:    var(--forest-ink);
}

/* ---------- 1. Canvas ---------- */
html, body, html body, html body[class], html body.min-h-screen {
  background: var(--oat) !important;
  background-image: none !important;
  color: var(--forest) !important;
}
::selection { background: var(--forest) !important; color: var(--oat) !important; }

/* ---------- 2. Ink on cream (beats dark.css forced oat) ---------- */
html body p, html body span, html body div, html body li, html body td,
html body th, html body label, html body h1, html body h2, html body h3,
html body h4, html body h5, html body h6, html body a, html body small,
html body strong, html body em, html body b, html body i, html body ul,
html body ol, html body nav, html body header, html body footer,
html body section, html body article, html body main {
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
}
html body h1, html body h2, html body h3, html body h4 {
  color: var(--forest-deep) !important;
  -webkit-text-fill-color: var(--forest-deep) !important;
  font-weight: 700 !important;
}
html body .text-slate-600, html body .text-slate-700, html body .text-slate-800,
html body .text-gray-600, html body .text-gray-700, html body .text-gray-800,
html body .text-neutral-600, html body .text-neutral-700 {
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
}
html body .text-slate-400, html body .text-slate-500, html body .text-gray-400,
html body .text-gray-500, html body .text-neutral-500, html body .text-muted {
  color: var(--forest-mid) !important;
  -webkit-text-fill-color: var(--forest-mid) !important;
}
html body .text-blue-600, html body .text-blue-700, html body .text-blue-800,
html body .text-blue-900, html body .text-indigo-600, html body .text-emerald-700,
html body .text-green-700, html body .text-amber-700, html body .link,
html body .text-red-600, html body .text-red-700, html body .text-rose-600,
html body .text-rose-700, html body a.text-blue-600, html body .hover\:text-slate-900:hover {
  color: var(--tomato-ink) !important;
  -webkit-text-fill-color: var(--tomato-ink) !important;
}
html body a { text-decoration-color: rgba(29,74,53,.35) !important; }
html body .text-transparent.bg-clip-text, html body .hero-grad span[style*="gradient"],
html body .hero-grad .text-blue-700 {
  background-image: linear-gradient(92deg, var(--forest-deep), var(--forest), var(--tomato-ink)) !important;
  -webkit-background-clip: text !important;
  background-clip: text !important;
  color: transparent !important;
  -webkit-text-fill-color: transparent !important;
}

/* ---------- 3. Dark forest surfaces ---------- */
html body nav, html body header, html body footer,
html body .modal-content, html body .modal-content-wide,
html body [id$="Modal"] > div, html body #feedbackModal > div,
html body.bg-gray-50 .bg-white,
html body .tier-card, html body .cat-chip, html body .badge-oem,
html body .badge-unlocked, html body .oem-row-grouped,
html body .auth-right, html body.min-h-screen footer {
  background: linear-gradient(150deg, var(--forest), var(--forest-deep)) !important;
  background-image: linear-gradient(150deg, var(--forest), var(--forest-deep)) !important;
  border-color: rgba(238,229,212,.28) !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}
html body nav *, html body header *, html body footer *,
html body .modal-content *, html body .modal-content-wide *,
html body [id$="Modal"] > div *, html body #feedbackModal > div *,
html body.bg-gray-50 .bg-white *, html body .tier-card *,
html body .cat-chip *, html body .badge-oem *, html body .badge-unlocked *,
html body .oem-row-grouped *, html body .auth-right * {
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}
html body :is(nav, header, footer, .modal-content, .modal-content-wide,
  [id$="Modal"] > div, .auth-right, .bg-gray-50 .bg-white)
  :is(.text-slate-400,.text-slate-500,.text-gray-400,.text-gray-500,
      .text-neutral-500,.text-muted) {
  color: var(--oat-soft) !important;
  -webkit-text-fill-color: var(--oat-soft) !important;
}
html body :is(nav, header, footer, .modal-content, .modal-content-wide,
  [id$="Modal"] > div, .auth-right, .bg-gray-50 .bg-white)
  :is(.text-blue-600,.text-blue-700,.text-indigo-600,.text-emerald-700,
      .text-green-700,.text-red-600,.text-red-700,.link) {
  color: var(--accent-dark) !important;
  -webkit-text-fill-color: var(--accent-dark) !important;
}

/* ---------- 4. Tables / controls / borders ---------- */
html body table, html body thead, html body tbody, html body tr,
html body td, html body th {
  background: transparent !important;
  color: var(--forest) !important;
  border-color: rgba(29,74,53,.22) !important;
}
html body thead, html body thead tr, html body thead th,
html body tbody tr:nth-child(even), html body .bg-blue-50 {
  background: rgba(29,74,53,.08) !important;
  color: var(--forest) !important;
}
html body :is(.bg-gray-50 .bg-white,.modal-content,.modal-content-wide,[id$="Modal"] > div)
  :is(table,thead,tbody,tr,td,th) {
  background: transparent !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}
html body input, html body select, html body textarea, html body option {
  background: var(--oat) !important;
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
  border-color: rgba(29,74,53,.35) !important;
}
html body :is(.modal-content,.modal-content-wide,[id$="Modal"] > div,.auth-right,
  .bg-gray-50 .bg-white) :is(input,select,textarea,option) {
  background: var(--oat) !important;
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
  border-color: rgba(29,74,53,.35) !important;
}
html body input::placeholder, html body textarea::placeholder {
  color: var(--forest-mid) !important;
}
html body hr { border-color: rgba(29,74,53,.2) !important; }
html body .border, html body .border-slate-200, html body .border-gray-200,
html body .border-blue-200 { border-color: rgba(29,74,53,.24) !important; }

/* ---------- 5. Modals ---------- */
html body .modal, html body [id$="Modal"], html body #feedbackModal,
html body #dailyLimitModal, html body .loading-overlay {
  background: rgba(18,51,38,.62) !important;
}
html body .modal-content, html body .modal-content-wide,
html body [id$="Modal"] > div, html body #feedbackModal > div {
  border: 1px solid rgba(238,229,212,.32) !important;
  box-shadow: 0 24px 70px -30px rgba(0,0,0,.7) !important;
}

/* ---------- 6. Homepage / public specifics ---------- */
html body .auth-left {
  background: linear-gradient(135deg, var(--oat), var(--oat-soft)) !important;
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
}
html body:has(#demo-form) header {
  background: linear-gradient(150deg, var(--forest), var(--forest-deep)) !important;
}
html body #features .feat p, html body #features .donut > div,
html body #features .v .rec, html body #features .rec *,
html body #features .fh, html body #features .tb, html body #features .fg,
html body #features .k, html body #features .ft, html body #features .vs,
html body #features .st, html body #features .pdf, html body #features .xl,
html body #features .fi, html body #rt-feed .fi {
  background: rgba(238,229,212,.7) !important;
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
  border-color: rgba(29,74,53,.25) !important;
}
html body #features .feat.is-active .fh,
html body #features .feat.is-active .fh * {
  background: var(--forest) !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}
html body .chart-container {
  background: rgba(29,74,53,.07) !important;
  border-color: rgba(29,74,53,.18) !important;
}
html body .vh, html body .pill.pg, html body .pill {
  color: var(--forest-deep) !important;
  -webkit-text-fill-color: var(--forest-deep) !important;
}
html body #faq .group[open] { border-color: rgba(29,74,53,.3) !important; }
html body #faq summary:hover { background: rgba(29,74,53,.06) !important; }
html body .cf::before {
  background: radial-gradient(closest-side, rgba(29,74,53,.16), rgba(242,70,46,.06) 60%, transparent) !important;
}
html body .cf-dot.on { background: var(--tomato) !important; }
html body .cf-dot { background: rgba(29,74,53,.28) !important; }
html body .mobile-contact-btn, html body .mobile-contact-btn * {
  background: var(--forest) !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}

/* ---------- 7. Buttons LAST (0,2,3) — no text rule can override ---------- */
html body [class] :is(button, a.btn, a[class*="btn-"])[class] {
  font-weight: 600 !important;
  box-shadow: none !important;
  transition: background-color .18s ease, border-color .18s ease, color .18s ease, transform .18s ease !important;
}
html body [class] :is(button, a.btn, a[class*="btn-"])[class]:active {
  transform: translateY(1px) !important;
}
/* Link/icon buttons: no fill. */
html body [class] button[class]:not(:where([class*="bg-"], [class*="border"], .btn, .tab-link, .cat-toggle, .fy-toggle)) {
  background: transparent !important;
  border-color: transparent !important;
  color: var(--tomato-ink) !important;
  -webkit-text-fill-color: var(--tomato-ink) !important;
}
html body :is(nav, header, footer, .modal-content, .modal-content-wide,
  [id$="Modal"] > div, .auth-right, .bg-gray-50 .bg-white)
  [class] button[class]:not([class*="bg-"]):not([class*="border"]) {
  background: transparent !important;
  border-color: transparent !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}
/* Primary: colour utility / submit / known CTA. */
html body [class] :is(button, a)[class*="bg-blue-"],
html body [class] :is(button, a)[class*="bg-indigo-"],
html body [class] :is(button, a)[class*="bg-emerald-"],
html body [class] :is(button, a)[class*="bg-green-"],
html body [class] :is(button, a)[class*="bg-red-"],
html body [class] :is(button, a)[class*="from-blue-"],
html body [class] :is(button, a)[class*="from-emerald-"],
html body [class] .sample-cta, html body [class] #feedbackSubmitBtn,
html body [class] .upgradePaymentBtn, html body [class] button[type="submit"] {
  background: linear-gradient(145deg, var(--tomato-btn), var(--tomato-btn-deep)) !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
  border: 1px solid rgba(238,229,212,.3) !important;
  box-shadow: 0 8px 20px -12px rgba(190,44,25,.65) !important;
}
html body [class] :is(button, a)[class*="bg-blue-"] *,
html body [class] :is(button, a)[class*="from-blue-"] *,
html body [class] .sample-cta *, html body [class] #feedbackSubmitBtn *,
html body [class] .upgradePaymentBtn * {
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}
html body [class] :is(button, a)[class*="bg-blue-"]:hover,
html body [class] :is(button, a)[class*="from-blue-"]:hover,
html body [class] .sample-cta:hover, html body [class] .upgradePaymentBtn:hover {
  filter: brightness(1.08) !important;
}
/* Secondary: cream face + forest ink — on cream and on forest cards. */
html body [class] :is(button, a)[class*="border"],
html body [class] :is(button, a)[class*="bg-white"],
html body [class] :is(button, a)[class*="bg-gray-"],
html body [class] :is(button, a)[class*="bg-slate-"],
html body [class] .cat-toggle, html body [class] .fy-toggle,
html body [class] .tab-link {
  background: var(--oat) !important;
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
  border: 1px solid rgba(29,74,53,.35) !important;
  box-shadow: none !important;
}
html body [class] :is(button, a)[class*="border"] *,
html body [class] .cat-toggle *, html body [class] .fy-toggle *,
html body [class] .tab-link * {
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
}
html body [class] :is(button, a)[class*="border"]:hover,
html body [class] .cat-toggle:hover, html body [class] .fy-toggle:hover,
html body [class] .tab-link:hover { background: var(--oat-soft) !important; }
html body [class] .tab-link.active, html body [class] .tab-link.active * {
  background: var(--forest) !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
  border-color: var(--forest) !important;
}
html body [class] .cf-arrow, html body [class] #features .cf-arrow {
  background: var(--forest) !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
  border: 1px solid rgba(238,229,212,.3) !important;
}
html body [class] #feedbackBtn {
  background: linear-gradient(145deg, var(--tomato-btn), var(--tomato-btn-deep)) !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
  border-color: rgba(238,229,212,.3) !important;
}

/* ---------- 8. Targeted contrast fixes ---------- */
html body .text-slate-900, html body .text-gray-900, html body .text-neutral-900 {
  color: var(--forest-deep) !important;
  -webkit-text-fill-color: var(--forest-deep) !important;
}
/* Dropdowns sit on a cream face even though their parent nav is forest. */
html body :is(nav, header) a[class*="block py-2 px-4"],
html body :is(nav, header) a[class*="block py-2 px-4"] * {
  background: var(--oat) !important;
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
  border-color: rgba(29,74,53,.24) !important;
}
html body :is(nav, header) a[class*="block py-2 px-4"]:hover {
  background: var(--oat-soft) !important;
}
/* Login left panel is cream. */
html body .auth-left * {
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
}
/* Homepage feature demo cards carry inline muted colours — force forest. */
html body #features .fg, html body #features .k, html body #features .tb,
html body #features .fh, html body #features .ft, html body #features .vs,
html body #features .st, html body #features .pdf, html body #features .xl,
html body #features .fi, html body #features .rec, html body #features .donut > div,
html body #features .vh, html body #features .kl, html body #features .ks,
html body #features .pill, html body #features .ins, html body #features .rn,
html body #features p, html body #features span, html body #features div {
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
}
html body #features .feat.is-active .fh, html body #features .feat.is-active .fh * {
  background: var(--forest) !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}
html body #features .cf-dot { background: rgba(29,74,53,.3) !important; }
html body #features .cf-dot.on { background: var(--tomato) !important; }
/* Select options on forest cards must keep an oat face + forest ink. */
html body.bg-gray-50 .bg-white option, html body .modal-content option,
html body .modal-content-wide option, html body [id$="Modal"] option {
  background: var(--oat) !important;
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
}
/* Light badges. */
html body .bg-yellow-100, html body .bg-amber-100, html body .bg-yellow-50 {
  background: #FBEEB8 !important;
  color: var(--forest-deep) !important;
  -webkit-text-fill-color: var(--forest-deep) !important;
}
html body .eyebrow, html body .tick, html body .vh, html body .pill.pg {
  color: var(--forest-deep) !important;
  -webkit-text-fill-color: var(--forest-deep) !important;
}
html body .card .sub, html body .card .alt, html body .card .big {
  color: var(--oat-soft) !important;
  -webkit-text-fill-color: var(--oat-soft) !important;
}
/* Header links keep oat ink on the forest bar. */
html body header a[href], html body header a[href] * {
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}
/* Logout is a text link, never a filled button. */
html body a.text-red-600 {
  background: transparent !important;
  box-shadow: none !important;
  color: var(--accent-dark) !important;
  -webkit-text-fill-color: var(--accent-dark) !important;
}

/* ---------- 9. High-specificity overrides for legacy CSS ---------- */
/* Header links: inline #siteHeader rules outrank normal selectors. */
html body #siteHeader#siteHeader a,
html body #siteHeader#siteHeader a *,
html body header a[href]:not(:where([class*="block py-2 px-4"])),
html body header a[href]:not(:where([class*="block py-2 px-4"])) * {
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}
/* Dropdown items sit on a cream face; active item is deep tomato + oat. */
html body :is(nav, header) a[class*="block py-2 px-4"],
html body :is(nav, header) a[class*="block py-2 px-4"] * {
  background: var(--oat) !important;
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
  border-color: rgba(29,74,53,.24) !important;
}
html body :is(nav, header) a[class*="block py-2 px-4"]:is(.bg-blue-600, .bg-indigo-600),
html body :is(nav, header) a[class*="block py-2 px-4"]:is(.bg-blue-600, .bg-indigo-600) * {
  background: var(--tomato-btn) !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}
/* Select options: keep an oat face + forest ink everywhere. */
html body option:nth-child(n):nth-child(n):nth-child(n),
html body select:nth-child(n):nth-child(n):nth-child(n) {
  background: var(--oat) !important;
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
}
/* Legacy `.bg-white` content cards on public pages belong on the cream canvas. */
html body .auth-left .bg-white, html body div.rounded-2xl.bg-white,
html body article.rounded-2xl.bg-white, html body #demo-form .card {
  background: var(--oat) !important;
  background-image: none !important;
  color: var(--forest) !important;
  border-color: rgba(29,74,53,.25) !important;
}
html body .auth-left .bg-white *, html body div.rounded-2xl.bg-white *,
html body article.rounded-2xl.bg-white *, html body #demo-form .card * {
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
}
/* Feature demo: home-polish.css uses body #features .class (1,N,*) —
   doubling the ID (2,0,*) wins without touching that file. */
html body #features#features, html body #features#features *,
html body #features#features p, html body #features#features span,
html body #features#features div {
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
}
html body #features#features .k, html body #features#features .tb,
html body #features#features .vs, html body #features#features .st,
html body #features#features .pdf, html body #features#features .xl,
html body #features#features .fi, html body #features#features .ins {
  background: rgba(238,229,212,.72) !important;
  border-color: rgba(29,74,53,.25) !important;
}
html body #features#features .feat.is-active .fh,
html body #features#features .feat.is-active .fh * {
  background: var(--forest) !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}
html body #features#features .cf-dot { background: rgba(29,74,53,.3) !important; }
html body #features#features .cf-dot.on { background: var(--tomato) !important; }
/* Light badges and forest-card close icons. */
html body .bg-yellow-100, html body .bg-yellow-100 *,
html body .bg-amber-100, html body .bg-amber-100 *,
html body .bg-yellow-50, html body .bg-yellow-50 * {
  background: #FBEEB8 !important;
  color: var(--forest-deep) !important;
  -webkit-text-fill-color: var(--forest-deep) !important;
}
html body :is(.bg-gray-50 .bg-white, .modal-content, .modal-content-wide,
  [id$="Modal"] > div) [class*="float-right"] {
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}
/* Text links on the oat canvas must never use the dark-surface accent. */
html body .view-oem-btn, html body .view-oem-btn * {
  color: var(--tomato-ink) !important;
  -webkit-text-fill-color: var(--tomato-ink) !important;
}

/* ---------- 10. Last-word legibility fixes ---------- */
/* Legacy dark-surface rules use IDs / :is() and outrank section 9. */
html body #feedbackModal#feedbackModal :is(option, select),
html body :is(.modal-content, .modal-content-wide) :is(option, select),
html body option[value][value][value][value] {
  background: var(--oat) !important;
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
}
html body .view-oem-btn.view-oem-btn.view-oem-btn.view-oem-btn,
html body .view-oem-btn.view-oem-btn.view-oem-btn.view-oem-btn * {
  background: transparent !important;
  color: var(--tomato-ink) !important;
  -webkit-text-fill-color: var(--tomato-ink) !important;
}
html body #mobileMenu#mobileMenu a,
html body #mobileMenu#mobileMenu a * {
  background: var(--oat) !important;
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
}
html body #mobileMenu#mobileMenu a[class*="bg-blue-"],
html body #mobileMenu#mobileMenu a[class*="bg-blue-"] * {
  background: var(--tomato-btn) !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}
html body footer a[href][href][href][href],
html body footer a[href][href][href][href] * {
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}
html body .loading-overlay.loading-overlay *,
html body #loadingMessage#loadingMessage {
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}
/* Contact / demo cards: cream face, forest ink. */
html body .card.card.card {
  background: var(--oat) !important;
  background-image: none !important;
  color: var(--forest) !important;
  border-color: rgba(29,74,53,.25) !important;
}
html body .card.card.card * {
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
}
/* Primary buttons: deep tomato fill + oat label, always. */
html body button[type="submit"][type="submit"][type="submit"],
html body [class*="bg-blue-"][class*="bg-blue-"][class*="bg-blue-"]:not(input):not(select):not(textarea),
html body [class*="from-blue-"][class*="from-blue-"] {
  background: linear-gradient(145deg, var(--tomato-btn), var(--tomato-btn-deep)) !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}
/* Form controls keep their own ink — otherwise inputs inside a forest
   filter card inherit oat-on-oat text and look empty while typing. */
html body button[class*="bg-blue-"][class*="bg-blue-"] *:not(input):not(select):not(textarea):not(option),
html body [class*="from-blue-"][class*="from-blue-"] *:not(input):not(select):not(textarea):not(option) {
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}

/* ---------- 11. Remaining legacy overrides ---------- */
/* App-page cards are forest: their Tailwind text classes must be oat. */
html body.bg-gray-50 .bg-white :is(h1, h2, h3, h4, p, span, label):is([class*="text-"]) {
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}
/* Plain buttons on cream use readable ink on forest cards. */
html body button:not(:where([class*="bg-"])):not(:where([class*="border"])) {
  color: var(--tomato-ink) !important;
  -webkit-text-fill-color: var(--tomato-ink) !important;
}
/* Light badges inside forest cards keep forest ink. */
html body .bg-gray-50 .bg-white :is(.bg-yellow-100, .bg-amber-100, .bg-yellow-50),
html body .bg-gray-50 .bg-white :is(.bg-yellow-100, .bg-amber-100, .bg-yellow-50) * {
  background: #FBEEB8 !important;
  color: var(--forest-deep) !important;
  -webkit-text-fill-color: var(--forest-deep) !important;
}
/* Legal pages: TOC labels on the cream canvas. */
html body .legal-toc .legal-toc :is(h4, .toc-part, span, div),
html body .legal-toc .toc-part {
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
}
html body section .text-white, html body section .text-white * {
  color: var(--forest-deep) !important;
  -webkit-text-fill-color: var(--forest-deep) !important;
}
/* Homepage: slate headings and blue labels follow the royal palette. */
html body #features .text-slate-900.text-slate-900,
html body #features .text-gray-900.text-gray-900 {
  color: var(--forest-deep) !important;
  -webkit-text-fill-color: var(--forest-deep) !important;
}
html body span[class*="bg-blue-"], html body div[class*="bg-blue-"] {
  background: var(--forest) !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}
/* Page headers are forest; their Tailwind text classes need oat ink. */
html body header :is(h1, h2, h3, h4, p, span, div)[class*="text-"],
html body header :is(h1, h2, h3, h4, p, span, div)[class*="text-"] * {
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}
/* Footer links keep oat ink on the forest bar. */
html body footer#siteFooter#siteFooter a,
html body footer#siteFooter#siteFooter a *,
html body footer#siteFooter#siteFooter {
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}
/* Legal TOC on the cream canvas. */
html body .legal-toc.legal-toc :is(h3, h4, .toc-part, span, div, a) {
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
}
/* Small labelled controls and ticks on the cream canvas. */
html body #exportExcelBtn#exportExcelBtn {
  opacity: 1 !important;
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
}
html body .tick.tick {
  color: var(--forest-deep) !important;
  -webkit-text-fill-color: var(--forest-deep) !important;
}
html body header .inline-flex.bg-white,
html body header .inline-flex.bg-white * {
  background: var(--oat) !important;
  color: var(--forest-deep) !important;
  -webkit-text-fill-color: var(--forest-deep) !important;
}

/* ---------- 12. Final legibility pass ---------- */
/* Homepage cream canvas: bold slate text must use forest ink. */
html body section b.text-slate-900.text-slate-900,
html body section b.text-slate-900.text-slate-900 * {
  color: var(--forest-deep) !important;
  -webkit-text-fill-color: var(--forest-deep) !important;
}
/* Footer pills keep a transparent face + oat ink on the forest bar.
   Section 2's `[class*="border"]` secondary rule otherwise creams them. */
html body footer a[class*="border"][class*="bg-white"],
html body footer a[class*="border"][class*="bg-white"] * {
  background: transparent !important;
  border-color: rgba(238,229,212,.35) !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}
/* Primary button labels (incl. nested spans) stay oat on deep tomato. */
html body button[class*="from-"][class*="from-"] :is(span, b, strong),
html body button[type="submit"]:is([type="submit"]) :is(span, b, strong) {
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}
/* Status badges on cream: forest ink, never oat. */
html body span.bg-yellow-100.text-yellow-800,
html body span.bg-yellow-100.text-yellow-800 * {
  color: var(--forest-deep) !important;
  -webkit-text-fill-color: var(--forest-deep) !important;
}
/* Public CTA `a.primary`: deep tomato + oat label. */
html body a.primary.primary {
  background: linear-gradient(145deg, var(--tomato-btn), var(--tomato-btn-deep)) !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}
/* Tick-list labels on cream use forest ink. */
html body .points.points li,
html body .points.points li strong {
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
}
/* Legal hero: dark pill + oat label, footer credit on cream + forest ink. */
html body section .inline-flex[class*="bg-white"][class*="text-blue-"],
html body section .inline-flex[class*="bg-white"][class*="text-blue-"] * {
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}
html body section a[class*="text-slate-300"] {
  color: var(--forest-deep) !important;
  -webkit-text-fill-color: var(--forest-deep) !important;
}
/* Light slate cards outside #features also sit on the cream canvas. */
html body .rounded-xl.bg-slate-50\/60 > .mt-2,
html body .rounded-xl.bg-slate-50\/60 > .text-lg {
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
}

/* ---------- 14. Homepage: 60/30/10 royal surfaces ----------
   Source of the dark gradients: public/index.html inline `<style>`
   (`html body.min-h-screen .bg-white/.bg-slate-50`) and dark.css.
   Doubling `.min-h-screen` outranks those without editing either file. */
html body header.sticky.sticky {
  background: linear-gradient(150deg, var(--forest), var(--forest-deep)) !important;
  background-image: linear-gradient(150deg, var(--forest), var(--forest-deep)) !important;
  border-color: rgba(238,229,212,.18) !important;
}
html body header.sticky.sticky::before { background: none !important; }

/* Hero: cream canvas. Tomato stays only on small accents/buttons. */
html body section.relative.overflow-hidden.isolate > div.absolute.inset-0:first-child {
  background: var(--oat) !important;
  background-image: none !important;
}
html body .hero-grad.hero-grad, html body .hero-grad.hero-grad span {
  color: var(--forest-deep) !important;
  -webkit-text-fill-color: var(--forest-deep) !important;
}
html body .hero-grad .text-blue-700 {
  background: none !important;
  color: var(--tomato-ink) !important;
  -webkit-text-fill-color: var(--tomato-ink) !important;
}

/* Pricing: forest band (30%) with cream plan cards. */
html body #pricing#pricing {
  background: linear-gradient(150deg, var(--forest), var(--forest-deep)) !important;
  background-image: linear-gradient(150deg, var(--forest), var(--forest-deep)) !important;
}
html body #pricing#pricing :is(h1, h2, h3, p, span, li, div) {
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}
html body #pricing#pricing .bg-white :is(h1, h2, h3, p, span, li, div, strong, b) {
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
}

/* Closing CTA: forest band. dark.css uses
   `body main section.relative.isolate > .absolute.inset-0.bg-gradient-to-r`
   (5 classes) — match every class here to outrank it. */
html body main > section:last-child,
html body main section.relative.isolate > div.-z-10.absolute.inset-0.bg-gradient-to-r {
  background: linear-gradient(150deg, var(--forest), var(--forest-deep)) !important;
  background-image: linear-gradient(150deg, var(--forest), var(--forest-deep)) !important;
}

/* ---------- 15. Homepage final contrast pass ----------
   royal.css is loaded last; these win ties at equal specificity. */
/* Header links: oat ink on forest; the cream-faced Sign In keeps forest ink. */
html body header a[href][href],
html body header a[href][href] * {
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}
html body header a[href][href].border-slate-300,
html body header a[href][href].border-slate-300 * {
  color: var(--forest-deep) !important;
  -webkit-text-fill-color: var(--forest-deep) !important;
}

/* Eyebrow badges on cream surfaces: forest ink. */
html body #trusted-by#trusted-by p,
html body #why-category#why-category div.mx-auto.max-w-3xl > div.inline-flex,
html body #faq#faq div.inline-flex.items-center.gap-2.rounded-full,
html body #pricing#pricing div.inline-flex.items-center.gap-2.rounded-full,
html body main > section:nth-of-type(6) div.inline-flex.items-center.gap-2.rounded-full,
html body section:has(#callback-form) div.inline-flex.items-center.gap-2.rounded-full {
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
}
html body form#callback-form .req.req {
  color: var(--tomato-ink) !important;
  -webkit-text-fill-color: var(--tomato-ink) !important;
}

/* Feature mockups: light ink on the dark blue/purple stat bars and export buttons. */
html body #features#features i[style*="2563eb"],
html body #features#features i[style*="7c3aed"],
html body #features#features .pdf-h,
html body #features#features .btn {
  color: #fff !important;
  -webkit-text-fill-color: #fff !important;
}
html body #features#features .cf-arrow.cf-arrow {
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
  background: var(--forest-deep) !important;
}

/* Why-category: oat ink ONLY on dark/tomato badges, forest on the cream cards. */
html body div.bg-slate-900.bg-slate-900,
html body div.bg-slate-900.bg-slate-900 *,
html body #why-category#why-category [class*="bg-blue-"][class*="bg-blue-"],
html body #why-category#why-category div[class*="border-blue-1"][class*="rounded-lg"] * {
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}
/* Cream pills sitting inside those dark cards go back to forest ink. */
html body #why-category#why-category div[class*="border-blue-1"] span.bg-white,
/* Cream inner cards inside the tomato-gradient feature grid: forest ink. */
html body #why-category#why-category div[class*="bg-slate-50"][class*="rounded-xl"],
html body #why-category#why-category div[class*="bg-slate-50"][class*="rounded-xl"] *,
html body #why-category#why-category div[class*="rounded-[calc"][class*="bg-white"],
html body #why-category#why-category div[class*="rounded-[calc"][class*="bg-white"] * {
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
}

/* Pricing: oat ink inside the forest band's bold sub-lines and tomato highlight cards. */
html body #pricing#pricing div.mx-auto.max-w-2xl b,
html body #pricing#pricing div[class*="bg-blue-50"][class*="bg-blue-50"],
html body #pricing#pricing div[class*="bg-blue-50"][class*="bg-blue-50"] *,
html body #pricing#pricing a[class*="bg-blue-"][class*="bg-blue-"],
html body #pricing#pricing a[class*="bg-blue-"][class*="bg-blue-"] *,
html body #pricing#pricing a[class*="from-blue-600"][class*="to-violet-600"],
html body #pricing#pricing a[class*="from-blue-600"][class*="to-violet-600"] * {
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}

/* Closing CTA band: oat headline + paragraph. */
html body main section.relative.isolate:last-of-type :is(h2, p) {
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}

/* Legal pages: the TOC card sits on the forest band, so it needs oat ink.
   An earlier `.legal-toc.legal-toc :is(...)` rule is one class more specific. */
html body div.legal-toc.legal-toc,
html body div.legal-toc.legal-toc :is(h3, h4, .toc-part, span, div, a) {
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}

/* Cream-faced secondary buttons: forest ink, never white or near-black. */
html body a.ghost.ghost,
html body button.ghost.ghost,
html body a.bg-white.bg-white[class*="text-slate-"],
html body a.bg-white.bg-white[class*="text-slate-"] *,
html body #pageMain a.ghost.ghost,
html body main section.relative.isolate a.bg-white.bg-white,
html body main > section:last-child a.bg-white.bg-white {
  background: var(--oat) !important;
  background-image: none !important;
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
}

/* Status badges: cream face + forest ink, no off-theme yellow. */
html body span[class*="bg-yellow-100"],
html body span[class*="bg-amber-100"],
html body.bg-gray-50 .bg-white span.bg-yellow-100.text-yellow-800,
html body.bg-gray-50 .bg-white span.bg-amber-100.text-amber-800 {
  background: var(--oat-soft) !important;
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
}

/* Trusted-by logos: show original brand colours on cream.
   Legacy `invert(1) brightness(1.5)` made them white and washed out. */
html body #trusted-by#trusted-by .brand-logo img,
html body #trusted-by#trusted-by .brand-logo:hover img,
html body #trusted-by#trusted-by .brand-logo img[src*="li-13.png"],
html body #trusted-by#trusted-by .brand-logo img[src*="li-22.png"] {
  filter: none !important;
  opacity: 1 !important;
}

/* Hero tagline: no off-theme cyan/purple glow over the forest-to-tomato text. */
html body h1.hero-grad.hero-grad span.text-blue-700.text-blue-700 {
  filter: none !important;
}

/* ---------- 16. Pricing polish ---------- */
/* These CTAs sit inside cream banners, so a cream face made them disappear. */
html body #pricing#pricing a[href="/login?signup=1"],
html body #pricing#pricing a[href="/contact"],
html body #pricing#pricing a[href^="https://wa.me/"] {
  background: linear-gradient(145deg, var(--tomato-btn), var(--tomato-btn-deep)) !important;
  background-image: linear-gradient(145deg, var(--tomato-btn), var(--tomato-btn-deep)) !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
  border-color: transparent !important;
}
/* Tomato accents only: feature dots and the two highlight badges. */
html body #pricing#pricing li span.bg-blue-600.bg-blue-600 {
  background: var(--tomato) !important;
}
html body #pricing#pricing span[class*="from-blue-600"],
html body #pricing#pricing span[class*="bg-emerald-50"] {
  background: var(--tomato-btn) !important;
  background-image: none !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}

/* ---------- 17. FAQ polish ---------- */
/* Eyebrow dot was rendering transparent — make it a tomato accent. */
html body #faq#faq div.inline-flex span[class~="h-1.5"][class*="bg-blue-"] {
  background: var(--tomato) !important;
}

/* Number badges: forest fill + oat ink in BOTH open and closed states.
   Legacy bg-blue-50 / group-open:bg-blue-600 made open forest, closed invisible. */
html body #faq#faq details[open] summary > span[class~="bg-blue-50"],
html body #faq#faq details summary > span[class~="bg-blue-50"] {
  background: var(--forest) !important;
  background-image: none !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
  --tw-ring-color: rgba(29,74,53,.35) !important;
  box-shadow: 0 0 0 1px rgba(29,74,53,.35) !important;
}

/* Plus/minus icon circles: same forest + oat, open or closed. SVG uses currentColor. */
html body #faq#faq details[open] summary > span:last-child,
html body #faq#faq details summary > span:last-child {
  background: var(--forest) !important;
  background-image: none !important;
  border-color: rgba(29,74,53,.35) !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}
html body #faq#faq details summary > span:last-child svg,
html body #faq#faq details summary > span:last-child svg path {
  fill: var(--oat) !important;
}

/* ---------- 18. Homepage spacing rhythm ---------- */
/* Tailwind defaults (py-20/py-16 + mt-10/16/20) left large dead bands.
   Tighten to a compact royal rhythm without touching content or grids. */
html body main > section#trusted-by#trusted-by {
  padding-top: 2rem !important;
  padding-bottom: 2rem !important;
}
html body main > section#features#features,
html body main > section:nth-of-type(7),
html body main > section:nth-of-type(8),
html body main > section#callback#callback {
  padding-top: 3rem !important;
  padding-bottom: 3rem !important;
}
html body main > section#why-category#why-category,
html body main > section#pricing#pricing,
html body main > section:nth-of-type(6),
html body main > section#faq#faq {
  padding-top: 3.5rem !important;
  padding-bottom: 3.5rem !important;
}

/* Section internals: target only top-level blocks inside each container. */
html body #features#features > [class~="mt-20"] { margin-top: 2.5rem !important; }
html body #why-category#why-category > div > [class~="mt-20"] { margin-top: 3rem !important; }
html body #why-category#why-category > div > [class~="mt-16"] { margin-top: 2.5rem !important; }
html body #why-category#why-category > div > [class~="mt-10"] { margin-top: 2rem !important; }
html body #why-category#why-category > div > [class~="gap-10"] { column-gap: 2rem !important; }
html body #pricing#pricing > div > [class~="mt-12"] { margin-top: 2rem !important; }
html body #pricing#pricing > div > [class~="mt-10"] { margin-top: 2rem !important; }
html body #pricing#pricing > div > [class~="mt-6"] { margin-top: 1.25rem !important; }
html body main > section:nth-of-type(6) > div > [class~="mt-10"],
html body main > section:nth-of-type(7) > div > [class~="mt-10"],
html body main > section:nth-of-type(8) > div > [class~="mt-10"],
html body #faq#faq > div > [class~="mt-10"] { margin-top: 2rem !important; }

/* Callback card's inline 1.5rem row gap made the form feel stretched. */
html body #callback#callback .cb-card.cb-card { gap: 1.25rem !important; }

/* ---------- 19. Button text visibility ---------- */
/* dark.css paints a stale --btn-core colour through ::after over every
   rounded button, covering the royal fill (oat text on cream = invisible).
   Remove that overlay + orbit so each button's own themed background shows. */
html body a[class*="rounded-"]::before,
html body a[class*="rounded-"]::after,
html body button[class*="rounded-"]::before,
html body button[class*="rounded-"]::after,
/* Tailwind's plain `.rounded` (no hyphen) missed the rule above, so the
   tier-card buttons kept dark.css's ::after overlay and lost their label. */
html body :is(button, a).rounded::before,
html body :is(button, a).rounded::after,
html body #tierBuyBtn::before, html body #tierBuyBtn::after,
html body #tierUpgradeBtn::before, html body #tierUpgradeBtn::after,
html body #openMyUnlockedBtn::before, html body #openMyUnlockedBtn::after,
html body .slider-btn::before,
html body .slider-btn::after,
html body header a[href="/login"]::after,
html body #features .cf-arrow::before,
html body #features .cf-arrow::after,
/* Page-number buttons have no `rounded-` class, so the rule above misses them
   and dark.css's near-black ::after hides the forest digits. */
html body #pageNumbers button::before,
html body #pageNumbers button::after,
html body #pageNumbersContracts button::before,
html body #pageNumbersContracts button::after {
  display: none !important;
}

/* ---------- 20. App-page spacing & colour polish ---------- */
/* Sellers table: legacy px-6 headers wrapped to 2-3 lines (73px tall).
   Match the compact px-2/px-3 of the Contracts/Bids tables. */
html body #sellerTable#sellerTable thead th {
  padding: 12px 8px !important;
  white-space: nowrap !important;
}
html body #sellerTable#sellerTable tbody td {
  padding: 12px 8px !important;
}

/* ---------- 21. Dashboard upgrade: forest surfaces + text hierarchy ---------- */
/* dashboard-pro.css forces near-black card gradients; bring every dashboard
   surface into the royal 60/30/10 palette (oat canvas, forest cards). */
html body #reportArea div.rounded-lg.p-6:not(.pro-kpi) {
  background: linear-gradient(180deg, rgba(29,74,53,.95), rgba(18,51,38,.97)) !important;
  border: 1px solid rgba(238,229,212,.14) !important;
  box-shadow: 0 14px 36px rgba(8,24,16,.24) !important;
}
html body #reportArea .pro-kpi.pro-kpi.rounded-lg.bg-white {
  background: linear-gradient(145deg, rgba(29,74,53,.96), rgba(18,51,38,.98)) !important;
  border: 1px solid rgba(238,229,212,.15) !important;
  box-shadow: inset 0 1px 0 rgba(238,229,212,.07), 0 18px 45px rgba(8,24,16,.26) !important;
}
/* Replace the generic radial blob with a slim tomato accent rail. */
html body #reportArea .pro-kpi.pro-kpi::before {
  content: "" !important;
  position: absolute !important;
  inset: 0 auto 0 0 !important;
  width: 3px !important;
  border-radius: 0 !important;
  background: linear-gradient(180deg, #F2462E, #B92D19) !important;
}
/* Hierarchy: supporting copy recedes, values stay full oat and prominent. */
html body #mainContainer > header > div:first-child > p {
  color: #BDB29A !important;
  -webkit-text-fill-color: #BDB29A !important;
}
html body #reportArea .pro-kpi h3 {
  color: #C2B7A0 !important;
  -webkit-text-fill-color: #C2B7A0 !important;
}
html body #reportArea .pro-kpi > p.text-xs {
  color: #C2B7A0 !important;
  -webkit-text-fill-color: #C2B7A0 !important;
}
html body #reportArea .pro-kpi p[id] {
  color: #EEE5D4 !important;
  -webkit-text-fill-color: #EEE5D4 !important;
  font-size: 1.9rem !important;
  letter-spacing: -.02em !important;
  line-height: 1.15 !important;
}
/* Section titles get a restrained tomato rule, not a loud block. */
html body #reportArea h2 {
  padding-bottom: .6rem !important;
  border-bottom: 1px solid rgba(242,70,46,.25) !important;
}

/* ---------- 22. Dashboard header polish ---------- */
/* Legacy header had zero inner padding and a square edge — text and controls
   sat flush against the forest card. Give it breathing room + a soft frame. */
html body #mainContainer > header {
  padding: 20px 24px !important;
  border-radius: 16px !important;
  gap: 18px !important;
  box-shadow: 0 14px 34px rgba(8,24,16,.18) !important;
}
/* A restrained tomato rail marks the page title. */
html body #mainContainer > header > div:first-child > h1 {
  position: relative !important;
  padding-left: 14px !important;
}
html body #mainContainer > header > div:first-child > h1::before {
  content: "" !important;
  position: absolute !important;
  left: 0 !important;
  top: 5px !important;
  bottom: 5px !important;
  width: 4px !important;
  border-radius: 2px !important;
  background: var(--tomato) !important;
}
html body #mainContainer > header > div:first-child > p {
  max-width: 46rem !important;
  font-size: .9rem !important;
  line-height: 1.5 !important;
}
/* Controls: taller, rounded, with the primary action standing apart. */
html body #mainContainer > header .cat-toggle,
html body #mainContainer > header .fy-toggle {
  min-height: 44px !important;
  border-radius: 10px !important;
  font-size: .9rem !important;
}
html body #mainContainer > header #downloadReportBtn {
  min-height: 44px !important;
  border-radius: 10px !important;
  padding-inline: 20px !important;
  box-shadow: 0 8px 18px rgba(185,45,25,.3) !important;
}
/* Wide screens: both switchers + primary button on one clean row. */
@media (min-width: 1280px) {
  html body #mainContainer > header > div:last-child {
    flex-direction: row !important;
    align-items: center !important;
  }
  html body #mainContainer > header > div:last-child > div:first-child {
    flex-direction: row !important;
  }
}

/* ---------- 23. Contracts page upgrade ---------- */
/* Header (same layout pattern as the dashboard): padded forest card, muted
   subtitle, one control row on wide screens. Scoped via #contractsTable. */
html body:has(#contractsTable) > div > header {
  padding: 20px 24px !important;
  border-radius: 16px !important;
  gap: 18px !important;
  box-shadow: 0 14px 34px rgba(8,24,16,.18) !important;
}
html body:has(#contractsTable) > div > header > div:first-child > h1 {
  position: relative !important;
  padding-left: 14px !important;
}
html body:has(#contractsTable) > div > header > div:first-child > h1::before {
  content: "" !important;
  position: absolute !important;
  left: 0 !important;
  top: 5px !important;
  bottom: 5px !important;
  width: 4px !important;
  border-radius: 2px !important;
  background: var(--tomato) !important;
}
html body:has(#contractsTable) > div > header > div:first-child > p {
  color: #BDB29A !important;
  -webkit-text-fill-color: #BDB29A !important;
  font-size: 1rem !important;
  line-height: 1.5 !important;
}
html body:has(#contractsTable) > div > header .cat-toggle,
html body:has(#contractsTable) > div > header .fy-toggle,
html body:has(#contractsTable) > div > header #exportExcelBtn {
  min-height: 44px !important;
  border-radius: 10px !important;
}
/* Export is the primary action when unlocked; locked state stays muted but
   gets a tomato hint so it reads as a distinct action, not another filter. */
html body:has(#contractsTable) > div > header #exportExcelBtn {
  padding-inline: 18px !important;
  color: var(--tomato-ink) !important;
  -webkit-text-fill-color: var(--tomato-ink) !important;
  border-color: rgba(242,70,46,.45) !important;
}
html body:has(#contractsTable) > div > header #exportExcelBtn:not(.cursor-not-allowed) {
  background: linear-gradient(145deg, var(--tomato-btn), var(--tomato-btn-deep)) !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
  border-color: transparent !important;
  box-shadow: 0 8px 18px rgba(185,45,25,.3) !important;
}
@media (min-width: 1280px) {
  html body:has(#contractsTable) > div > header > div:last-child {
    flex-direction: row !important;
    align-items: center !important;
  }
  html body:has(#contractsTable) > div > header > div:last-child > div:first-child {
    flex-direction: row !important;
  }
}
/* A full tomato card overused the 10% accent — move the filter panel back to
   forest with oat copy and keep tomato as a slim title rail. */
html body #filterWrapper#filterWrapper {
  background: linear-gradient(180deg, rgba(29,74,53,.96), rgba(18,51,38,.98)) !important;
  border: 1px solid rgba(238,229,212,.14) !important;
  border-radius: 12px !important;
  box-shadow: 0 14px 36px rgba(8,24,16,.22) !important;
}
html body #filterWrapper#filterWrapper #filterAccordionToggle {
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}
html body #filterWrapper#filterWrapper #filterAccordionToggle svg {
  color: var(--oat) !important;
  stroke: var(--oat) !important;
}
/* Slightly larger table type; keep headers on one line. */
html body #contractsTable#contractsTable thead th {
  font-size: 13px !important;
  white-space: nowrap !important;
  padding: 12px 8px !important;
}
html body #contractsTable#contractsTable tbody td {
  font-size: 13px !important;
}
html body #contractsTable#contractsTable tbody tr:hover td {
  background: rgba(238,229,212,.06) !important;
}

/* ---------- 24. Bids page upgrade (mirrors the Contracts header) ---------- */
/* Scoped via #bidsTable so it never touches other pages. The filter card is
   already forest from the generic #filterWrapper rule — no change needed. */
html body:has(#bidsTable) > div > header {
  padding: 20px 24px !important;
  border-radius: 16px !important;
  gap: 18px !important;
  box-shadow: 0 14px 34px rgba(8,24,16,.18) !important;
}
html body:has(#bidsTable) > div > header > div:first-child > h1 {
  position: relative !important;
  padding-left: 14px !important;
}
html body:has(#bidsTable) > div > header > div:first-child > h1::before {
  content: "" !important;
  position: absolute !important;
  left: 0 !important;
  top: 5px !important;
  bottom: 5px !important;
  width: 4px !important;
  border-radius: 2px !important;
  background: var(--tomato) !important;
}
html body:has(#bidsTable) > div > header > div:first-child > p {
  color: #BDB29A !important;
  -webkit-text-fill-color: #BDB29A !important;
  font-size: 1rem !important;
  line-height: 1.5 !important;
}
html body:has(#bidsTable) > div > header .cat-toggle,
html body:has(#bidsTable) > div > header .fy-toggle,
html body:has(#bidsTable) > div > header #exportExcelBtn {
  min-height: 44px !important;
  border-radius: 10px !important;
}
/* Export distinct from the two switchers; full tomato fill once unlocked. */
html body:has(#bidsTable) > div > header #exportExcelBtn {
  padding-inline: 18px !important;
  color: var(--tomato-ink) !important;
  -webkit-text-fill-color: var(--tomato-ink) !important;
  border-color: rgba(242,70,46,.45) !important;
}
html body:has(#bidsTable) > div > header #exportExcelBtn:not(.cursor-not-allowed) {
  background: linear-gradient(145deg, var(--tomato-btn), var(--tomato-btn-deep)) !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
  border-color: transparent !important;
  box-shadow: 0 8px 18px rgba(185,45,25,.3) !important;
}
@media (min-width: 1280px) {
  html body:has(#bidsTable) > div > header > div:last-child {
    flex-direction: row !important;
    align-items: center !important;
  }
  html body:has(#bidsTable) > div > header > div:last-child > div:first-child {
    flex-direction: row !important;
  }
}
/* Slightly larger table type, headers on one line, subtle hover tint. */
html body #bidsTable#bidsTable thead th {
  font-size: 13px !important;
  white-space: nowrap !important;
  padding: 12px 8px !important;
}
html body #bidsTable#bidsTable tbody td {
  font-size: 13px !important;
}
html body #bidsTable#bidsTable tbody tr:hover td {
  background: rgba(238,229,212,.06) !important;
}

/* ---------- 25. Sellers page upgrade ---------- */
/* Same header pattern as Dashboard/Contracts/Bids, scoped via #sellerTable. */
html body:has(#sellerTable) > div > header {
  padding: 20px 24px !important;
  border-radius: 16px !important;
  gap: 18px !important;
  box-shadow: 0 14px 34px rgba(8,24,16,.18) !important;
}
html body:has(#sellerTable) > div > header > div:first-child > h1 {
  position: relative !important;
  padding-left: 14px !important;
}
html body:has(#sellerTable) > div > header > div:first-child > h1::before {
  content: "" !important;
  position: absolute !important;
  left: 0 !important;
  top: 5px !important;
  bottom: 5px !important;
  width: 4px !important;
  border-radius: 2px !important;
  background: var(--tomato) !important;
}
html body:has(#sellerTable) > div > header > div:first-child > p {
  color: #BDB29A !important;
  -webkit-text-fill-color: #BDB29A !important;
  font-size: 1rem !important;
  line-height: 1.5 !important;
}
html body:has(#sellerTable) > div > header .cat-toggle,
html body:has(#sellerTable) > div > header .fy-toggle,
html body:has(#sellerTable) > div > header #exportExcelBtn {
  min-height: 44px !important;
  border-radius: 10px !important;
}
/* Export distinct from the two switchers; full tomato fill once unlocked. */
html body:has(#sellerTable) > div > header #exportExcelBtn {
  padding-inline: 18px !important;
  color: var(--tomato-ink) !important;
  -webkit-text-fill-color: var(--tomato-ink) !important;
  border-color: rgba(242,70,46,.45) !important;
}
html body:has(#sellerTable) > div > header #exportExcelBtn:not(.cursor-not-allowed) {
  background: linear-gradient(145deg, var(--tomato-btn), var(--tomato-btn-deep)) !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
  border-color: transparent !important;
  box-shadow: 0 8px 18px rgba(185,45,25,.3) !important;
}
@media (min-width: 1280px) {
  html body:has(#sellerTable) > div > header > div:last-child {
    flex-direction: row !important;
    align-items: center !important;
  }
  html body:has(#sellerTable) > div > header > div:last-child > div:first-child {
    flex-direction: row !important;
  }
}
/* Sellers uses #filterSection (not #filterWrapper): move it off the large
   tomato card to forest so the 10% accent stays an accent. */
html body #filterSection#filterSection {
  background: linear-gradient(180deg, rgba(29,74,53,.96), rgba(18,51,38,.98)) !important;
  border: 1px solid rgba(238,229,212,.14) !important;
  border-radius: 12px !important;
  box-shadow: 0 14px 36px rgba(8,24,16,.22) !important;
}
html body #filterSection#filterSection #filterAccordionToggle {
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}
html body #filterSection#filterSection #filterAccordionToggle svg {
  color: var(--oat) !important;
  stroke: var(--oat) !important;
}
html body #sellerTable#sellerTable tbody tr:hover td {
  background: rgba(238,229,212,.06) !important;
}

/* ---------- 26. OEM Directory upgrade ---------- */
/* Scoped via #panelVerified (unique to the OEM page). */
html body:has(#panelVerified) > div > header {
  padding: 20px 24px !important;
  border-radius: 16px !important;
  gap: 18px !important;
  box-shadow: 0 14px 34px rgba(8,24,16,.18) !important;
}
html body:has(#panelVerified) > div > header > div:first-child > h1 {
  position: relative !important;
  padding-left: 14px !important;
}
html body:has(#panelVerified) > div > header > div:first-child > h1::before {
  content: "" !important;
  position: absolute !important;
  left: 0 !important;
  top: 5px !important;
  bottom: 5px !important;
  width: 4px !important;
  border-radius: 2px !important;
  background: var(--tomato) !important;
}
html body:has(#panelVerified) > div > header > div:first-child > p:first-of-type {
  color: #BDB29A !important;
  -webkit-text-fill-color: #BDB29A !important;
  font-size: 1rem !important;
  line-height: 1.5 !important;
}
html body:has(#panelVerified) > div > header > div:first-child > p:last-of-type {
  color: #D9CFBB !important;
  -webkit-text-fill-color: #D9CFBB !important;
}
/* Buy Access is the primary action here (no category/FY/Export on this page). */
html body:has(#panelVerified) #tierBuyBtn {
  min-height: 44px !important;
  border-radius: 10px !important;
  padding-inline: 20px !important;
  box-shadow: 0 8px 18px rgba(185,45,25,.3) !important;
}
/* Brand search was a full tomato card — keep the 10% accent an accent. */
html body #panelBrands > section:first-child {
  background: linear-gradient(180deg, rgba(29,74,53,.96), rgba(18,51,38,.98)) !important;
  border: 1px solid rgba(238,229,212,.14) !important;
  border-radius: 12px !important;
  box-shadow: 0 14px 36px rgba(8,24,16,.22) !important;
}
html body #panelBrands > section:first-child input,
html body #panelBrands > section:first-child label,
html body #panelBrands > section:first-child span,
html body #panelBrands > section:first-child p,
html body #panelBrands > section:first-child button {
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}
/* Clear active tab: forest fill + oat ink + tomato underline. */
html body #tabBrands,
html body #tabVerified {
  min-height: 42px !important;
  border-radius: 10px 10px 0 0 !important;
}
html body #tabBrands {
  background: var(--forest) !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
  border-bottom: 3px solid var(--tomato) !important;
}
/* Dense brand/OEM tables: match the 13px type used on Contracts/Bids. */
html body #panelBrands table thead th,
html body #oemTable thead th {
  font-size: 13px !important;
  white-space: nowrap !important;
  padding: 12px 8px !important;
}
html body #panelBrands table tbody td,
html body #oemTable tbody td {
  font-size: 13px !important;
}
html body #panelBrands table tbody tr:hover td,
html body #oemTable tbody tr:hover td {
  background: rgba(238,229,212,.06) !important;
}

/* ---------- 27. OEM audit follow-ups ---------- */
/* Count span inside the active forest tab must inherit oat, not legacy forest. */
html body #tabBrands, html body #tabBrands * {
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}
/* Clear sits on the forest search card — give it an oat outline, no oat fill. */
html body #panelBrands > section:first-child button {
  background: transparent !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
  border: 1px solid rgba(238,229,212,.45) !important;
  box-shadow: none !important;
}
html body #panelBrands > section:first-child button:hover {
  background: rgba(238,229,212,.1) !important;
}

/* ---------- 28. Settings page upgrade ---------- */
/* Scoped via #self-brand (unique to the Settings page). */
html body:has(#self-brand) > main > header {
  padding: 20px 24px !important;
  border-radius: 16px !important;
  gap: 18px !important;
  box-shadow: 0 14px 34px rgba(8,24,16,.18) !important;
}
html body:has(#self-brand) > main > header > div:first-child > h1 {
  position: relative !important;
  padding-left: 14px !important;
}
html body:has(#self-brand) > main > header > div:first-child > h1::before {
  content: "" !important;
  position: absolute !important;
  left: 0 !important;
  top: 5px !important;
  bottom: 5px !important;
  width: 4px !important;
  border-radius: 2px !important;
  background: var(--tomato) !important;
}
html body:has(#self-brand) > main > header > div:first-child > p {
  color: #BDB29A !important;
  -webkit-text-fill-color: #BDB29A !important;
  font-size: 1rem !important;
  line-height: 1.5 !important;
}
html body:has(#self-brand) > main > header a {
  min-height: 44px !important;
  border-radius: 10px !important;
  padding-inline: 20px !important;
  box-shadow: 0 8px 18px rgba(185,45,25,.3) !important;
}
/* Distinct active tab with a tomato underline, matching the OEM tabs. */
html body:has(#self-brand) .tab-link {
  min-height: 44px !important;
  border-radius: 10px 10px 0 0 !important;
}
html body:has(#self-brand) .tab-link.active {
  border-bottom: 3px solid var(--tomato) !important;
}
/* Stat tiles need a surface of their own inside the forest card. */
html body #self-brand .grid > div[class*="rounded-lg"] {
  background: rgba(238,229,212,.07) !important;
  border-color: rgba(238,229,212,.18) !important;
}
html body #self-brand .border-dashed {
  background: rgba(238,229,212,.05) !important;
  border-color: rgba(238,229,212,.22) !important;
}

/* ============================================================
   29. OWNER ADMIN PANEL (/admin SPA) — scope: body:has(#view).
   dark.css paints slate-black surfaces; royal global ink is forest.
   On the admin we want: oat canvas (already), FOREST structure +
   oat ink, tomato accents only. This block overrides both.
   ============================================================ */

/* --- 29a. Sidebar: forest instead of slate-black --- */
html body:has(#view) aside[class*="bg-slate-900"] {
  background: linear-gradient(180deg, var(--forest), var(--forest-deep)) !important;
  border-right: 1px solid rgba(238,229,212,.14) !important;
}
html body:has(#view) aside[class*="bg-slate-900"] * {
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}
/* Brand tile: tomato accent keeps the 10% pop. */
html body:has(#view) aside .bg-indigo-600 {
  background: linear-gradient(145deg, var(--tomato-btn), var(--tomato-btn-deep)) !important;
  color: var(--oat) !important;
}
/* Nav section labels / muted footer copy. */
html body:has(#view) aside .text-slate-400,
html body:has(#view) aside .text-slate-300 {
  color: var(--oat-soft) !important;
  -webkit-text-fill-color: var(--oat-soft) !important;
}
/* Nav links: oat ink, hover tint. */
html body:has(#view) #nav a {
  background: transparent !important;
  color: var(--oat-soft) !important;
  -webkit-text-fill-color: var(--oat-soft) !important;
  border-radius: 8px !important;
  margin: 1px 8px !important;
  padding: 10px 16px !important;
  border-left-width: 3px !important;
  transition: background .18s ease, color .18s ease !important;
}
html body:has(#view) #nav a:hover {
  background: rgba(238,229,212,.08) !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}
/* Active nav: tomato left rail + oat ink (was indigo on slate). */
html body:has(#view) #nav a.border-indigo-500,
html body:has(#view) #nav a[class*="border-indigo-500"] {
  background: rgba(238,229,212,.12) !important;
  border-left: 3px solid var(--tomato) !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
  font-weight: 700 !important;
}
/* Sidebar footer owner card. */
html body:has(#view) aside .bg-white\/5,
html body:has(#view) aside [class*="rounded-lg"][class*="p-3"] {
  background: rgba(238,229,212,.07) !important;
  border: 1px solid rgba(238,229,212,.16) !important;
}

/* --- 29b. Top bar: tomato rail on the page title --- */
html body:has(#view) header #title {
  position: relative !important;
  padding-left: 12px !important;
}
html body:has(#view) header #title::before {
  content: "" !important;
  position: absolute !important;
  left: 0 !important;
  top: 2px !important;
  bottom: 2px !important;
  width: 4px !important;
  border-radius: 2px !important;
  background: var(--tomato) !important;
}
html body:has(#view) header #subtitle {
  color: var(--oat-soft) !important;
  -webkit-text-fill-color: var(--oat-soft) !important;
}
/* Owner avatar: tomato fill instead of slate-black. */
html body:has(#view) header #avatar {
  background: linear-gradient(145deg, var(--tomato-btn), var(--tomato-btn-deep)) !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
  border: 1px solid rgba(238,229,212,.35) !important;
  width: 38px !important; height: 38px !important;
}
/* Mobile menu + View site buttons sit on the forest bar. */
html body:has(#view) header button {
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
  border-color: rgba(238,229,212,.3) !important;
}

/* --- 29c. #view surfaces: forest cards with oat ink --- */
/* KPI tiles (.pro-kpi) and every rounded panel were dark under dark.css. */
html body:has(#view) #view .pro-kpi,
html body:has(#view) #view .rounded-2xl.bg-white,
html body:has(#view) #view .rounded-xl.bg-white,
html body:has(#view) #view .rounded-lg.bg-white,
html body:has(#view) #view [class*="rounded-2xl"][class*="bg-white"] {
  background: linear-gradient(150deg, var(--forest), var(--forest-deep)) !important;
  background-image: linear-gradient(150deg, var(--forest), var(--forest-deep)) !important;
  border: 1px solid rgba(238,229,212,.18) !important;
  box-shadow: 0 12px 30px -18px rgba(8,24,16,.5) !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}
/* All leaf text inside those forest cards → oat (override global forest). */
html body:has(#view) #view .pro-kpi *,
html body:has(#view) #view .rounded-2xl.bg-white *,
html body:has(#view) #view .rounded-xl.bg-white *,
html body:has(#view) #view .rounded-lg.bg-white *,
html body:has(#view) #view [class*="rounded-2xl"][class*="bg-white"] * {
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}
/* Muted labels inside the forest cards. */
html body:has(#view) #view .pro-kpi .text-slate-400,
html body:has(#view) #view .pro-kpi .text-slate-500,
html body:has(#view) #view .rounded-2xl.bg-white .text-slate-500,
html body:has(#view) #view .rounded-2xl.bg-white .text-slate-400,
html body:has(#view) #view [class*="text-slate-500"],
html body:has(#view) #view [class*="text-slate-400"] {
  color: var(--oat-soft) !important;
  -webkit-text-fill-color: var(--oat-soft) !important;
}
/* Section labels (h2/h3) on the oat canvas that are NOT inside a card: forest. */
html body:has(#view) #view > div > h2,
html body:has(#view) #view > div > h3 {
  color: var(--forest-deep) !important;
  -webkit-text-fill-color: var(--forest-deep) !important;
}
/* Tomato KPI rail: small left accent on each pro-kpi. */
html body:has(#view) #view .pro-kpi {
  position: relative !important;
  overflow: hidden !important;
}
html body:has(#view) #view .pro-kpi::before {
  content: "" !important;
  position: absolute !important;
  left: 0 !important; top: 0 !important; bottom: 0 !important;
  width: 3px !important;
  background: var(--tomato) !important;
}

/* --- 29d. Tables inside the forest cards --- */
html body:has(#view) #view table thead th {
  background: rgba(8,24,16,.45) !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
  border-color: rgba(238,229,212,.18) !important;
  font-size: 12px !important;
  white-space: nowrap !important;
  padding: 11px 12px !important;
}
html body:has(#view) #view table tbody td {
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
  border-color: rgba(238,229,212,.12) !important;
  font-size: 12px !important;
  padding: 11px 12px !important;
}
html body:has(#view) #view table tbody tr:nth-child(even) {
  background: rgba(238,229,212,.04) !important;
}
html body:has(#view) #view table tbody tr:hover td,
html body:has(#view) #view .row-hover:hover {
  background: rgba(238,229,212,.09) !important;
}
/* Sortable column buttons: oat ink on forest. */
html body:has(#view) #view table thead th button,
html body:has(#view) #view table thead th button:hover {
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
  background: transparent !important;
  border: 0 !important;
}
/* Cell max-width clip stays, just ensure ellipsis ink. */
html body:has(#view) #view .cell-clip { color: inherit !important; }

/* --- 29e. Controls inside forest cards: search, selects, inputs --- */
html body:has(#view) #view input,
html body:has(#view) #view select,
html body:has(#view) #view textarea {
  background: var(--oat) !important;
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
  border: 1px solid rgba(29,74,53,.35) !important;
  border-radius: 8px !important;
}
html body:has(#view) #view input::placeholder {
  color: var(--forest-mid) !important;
}

/* --- 29f. Buttons on the oat canvas / forest cards --- */
/* Secondary buttons in the toolbar: cream face + forest ink (already from
   global rule) — keep them but give breathing room. */
html body:has(#view) #view button {
  border-radius: 8px !important;
  font-size: 12px !important;
}
html body:has(#view) #view button[class*="bg-indigo-600"],
html body:has(#view) #view button[class*="bg-blue-600"],
html body:has(#view) #view button[type="submit"] {
  background: linear-gradient(145deg, var(--tomato-btn), var(--tomato-btn-deep)) !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
  border: 1px solid rgba(238,229,212,.3) !important;
  box-shadow: 0 8px 18px -10px rgba(190,44,25,.6) !important;
  min-height: 34px !important;
  padding: 8px 16px !important;
}

/* --- 29g. Grids / spacing / layout rhythm --- */
html body:has(#view) #view {
  padding: 24px 28px 40px !important;
}
html body:has(#view) #view > .grid {
  gap: 16px !important;
}
html body:has(#view) #view > div[class*="mt-6"] {
  margin-top: 22px !important;
}
html body:has(#view) #view .rounded-2xl.bg-white,
html body:has(#view) #view [class*="rounded-2xl"][class*="bg-white"] {
  padding: 20px !important;
}
html body:has(#view) #view .rounded-2xl.bg-white h2,
html body:has(#view) #view [class*="rounded-2xl"][class*="bg-white"] h2 {
  font-size: 15px !important;
  margin-bottom: 12px !important;
}
/* Loading state keeps oat ink ( sits directly on the canvas ). */
html body:has(#view) #view > .text-slate-500 {
  color: var(--forest-mid) !important;
  -webkit-text-fill-color: var(--forest-mid) !important;
}

/* --- 29h. Settings/system sub-forms and code blocks --- */
html body:has(#view) #view code,
html body:has(#view) #view pre,
html body:has(#view) #view [class*="font-mono"] {
  color: var(--accent-dark) !important;
  -webkit-text-fill-color: var(--accent-dark) !important;
}
html body:has(#view) #view hr {
  border-color: rgba(238,229,212,.2) !important;
}

/* ---------- 29i. Admin audit fixes (cream buttons + canvas labels) ---------- */
/* Cream-face secondary buttons/anchors MUST have forest ink (not oat-on-oat).
   Higher specificity than the wildcard oat rules above. */
html body:has(#view) #view a[class*="border"],
html body:has(#view) #view button[class*="border"],
html body:has(#view) #view button[class*="bg-white"],
html body:has(#view) #view button[class*="bg-slate-"],
html body:has(#view) #view button[class*="bg-gray-"],
html body:has(#view) #view button:not([class*="bg-indigo"]):not([class*="bg-blue"]):not([class*="bg-red"]):not([class*="bg-emerald"]):not([class*="bg-green"]):not([type="submit"]),
html body:has(#view) header a[class*="border"] {
  background: var(--oat) !important;
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
  border: 1px solid rgba(29,74,53,.35) !important;
}
html body:has(#view) #view a[class*="border"] *,
html body:has(#view) #view button[class*="border"] *,
html body:has(#view) #view button[class*="bg-white"] *,
html body:has(#view) #view button[class*="bg-slate-"] *,
html body:has(#view) header a[class*="border"] * {
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
}
html body:has(#view) #view a[class*="border"]:hover,
html body:has(#view) #view button[class*="border"]:hover,
html body:has(#view) #view button[class*="bg-white"]:hover {
  background: var(--oat-soft) !important;
}
/* Primary buttons keep oat ink on tomato. */
html body:has(#view) #view button[class*="bg-indigo-600"],
html body:has(#view) #view button[class*="bg-indigo-600"] *,
html body:has(#view) #view button[type="submit"],
html body:has(#view) #view button[type="submit"] * {
  background: linear-gradient(145deg, var(--tomato-btn), var(--tomato-btn-deep)) !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
  border-color: rgba(238,229,212,.3) !important;
}
/* System page: sliders/toggles on the oat canvas need forest ink, not oat. */
html body:has(#view) #view input[type="checkbox"],
html body:has(#view) #view input[type="radio"],
html body:has(#view) #view [class*="inline-flex"][class*="rounded-full"] {
  background: rgba(29,74,53,.14) !important;
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
  border-color: rgba(29,74,53,.3) !important;
}
/* The attention badge (!) — tomato ink on a soft tomato chip. */
html body:has(#view) #view span[class*="bg-amber"],
html body:has(#view) #view span[class*="bg-rose"],
html body:has(#view) #view span[class*="bg-red"] {
  background: rgba(185,45,25,.12) !important;
  color: var(--tomato-ink) !important;
  -webkit-text-fill-color: var(--tomato-ink) !important;
}

/* ---------- 29j. Admin final specificity fixes ---------- */
/* Cream quick-action anchors sit inside forest cards but must keep forest ink.
   Extra .rounded-2xl class raises specificity above the wildcard oat rule. */
html body:has(#view) #view .rounded-2xl a[class*="border"],
html body:has(#view) #view .rounded-2xl a[class*="border"] *,
html body:has(#view) #view [class*="rounded-2xl"] a[class*="border"],
html body:has(#view) #view [class*="rounded-2xl"] a[class*="border"] * {
  background: var(--oat) !important;
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
  border-color: rgba(29,74,53,.35) !important;
}
/* System page chrome label sits on the OAT canvas — forest ink, not oat-soft. */
html body:has(#view) #view > div.flex > div[class*="text-slate-500"],
html body:has(#view) #view > div.flex > div[class*="text-slate-500"] * {
  color: var(--forest-mid) !important;
  -webkit-text-fill-color: var(--forest-mid) !important;
}
/* Status badges (✓ / !) on forest cards: cream chip + forest ink. */
html body:has(#view) #view span[class*="inline-flex"][class*="rounded-full"],
html body:has(#view) #view span[class*="bg-emerald"],
html body:has(#view) #view span[class*="bg-amber"],
html body:has(#view) #view span[class*="bg-rose"],
html body:has(#view) #view span[class*="text-emerald"],
html body:has(#view) #view span[class*="text-amber"] {
  background: var(--oat) !important;
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
  border: 1px solid rgba(29,74,53,.3) !important;
}
/* A failed/attention badge gets a tomato chip + oat ink for the 10% pop. */
html body:has(#view) #view span[class*="bg-rose"]:not([class*="emerald"]),
html body:has(#view) #view span[class*="text-rose"]:not([class*="emerald"]) {
  background: var(--tomato-btn) !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
  border-color: rgba(238,229,212,.35) !important;
}

/* ---------- 29k. Admin last-mile: cream chips / indigo-outline buttons ---------- */
/* Status pills (active/pending) and amber attention chips on cream → forest ink. */
html body:has(#view) #view span[class*="rounded-full"][class*="px-2"],
html body:has(#view) #view span[class*="rounded-full"][class*="bg-"],
html body:has(#view) #view span[class*="text-amber-700"],
html body:has(#view) #view span[class*="text-emerald-700"],
html body:has(#view) #view span[class*="text-rose-700"] {
  background: var(--oat) !important;
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
  border: 1px solid rgba(29,74,53,.28) !important;
}
/* Indigo/blue OUTLINE buttons are secondary (cream face + forest ink),
   not the solid indigo primary. */
html body:has(#view) #view button[class*="border-indigo"],
html body:has(#view) #view a[class*="border-indigo"],
html body:has(#view) #view button[class*="border-blue"],
html body:has(#view) #view a[class*="border-blue"] {
  background: var(--oat) !important;
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
  border-color: rgba(29,74,53,.35) !important;
}
html body:has(#view) #view button[class*="border-indigo"] *,
html body:has(#view) #view a[class*="border-indigo"] * {
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
}

/* ---------- 29l. Force (highest specificity) cream chips → forest ink ---------- */
html body:has(#view) #view span.text-amber-700.text-amber-700,
html body:has(#view) #view span[class="text-xs text-amber-700"],
html body:has(#view) #view button.bg-indigo-50.bg-indigo-50,
html body:has(#view) #view button[class*="bg-indigo-50"] {
  background: var(--oat) !important;
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
  border-color: rgba(29,74,53,.32) !important;
}

/* ---------- 29m. Solid indigo primary buttons → tomato fill + oat ink ---------- */
html body:has(#view) #view button.bg-indigo-600.bg-indigo-600,
html body:has(#view) #view button[class="bg-indigo-600"],
html body:has(#view) #view a.bg-indigo-600.bg-indigo-600 {
  background: linear-gradient(145deg, var(--tomato-btn), var(--tomato-btn-deep)) !important;
  background-image: linear-gradient(145deg, var(--tomato-btn), var(--tomato-btn-deep)) !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
  border-color: rgba(238,229,212,.3) !important;
}

/* ---------- 29n. Table row action buttons (Edit/View/Delete) → forest ink ---------- */
html body:has(#view) #view button[class*="px-2"][class*="py-1"],
html body:has(#view) #view button[class*="rounded-md"][class*="px-2"],
html body:has(#view) #view td button,
html body:has(#view) #view td a {
  background: var(--oat) !important;
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
  border: 1px solid rgba(29,74,53,.3) !important;
  border-radius: 6px !important;
}
html body:has(#view) #view td button:hover,
html body:has(#view) #view td a:hover {
  background: var(--oat-soft) !important;
}

/* ---------- 30. Button text-ink cleanup (all pages) ---------- */
/* Pagination arrow buttons (#prevPage/#nextPage) are cream-faced icon buttons;
   their text-fill was forced oat-soft by the nav/header .text-gray-500 rule.
   Keep the SVG + fill forest-mid on the cream face. */
html body button#prevPage,
html body button#nextPage,
html body button#prevPage *,
html body button#nextPage * {
  color: var(--forest-mid) !important;
  -webkit-text-fill-color: var(--forest-mid) !important;
  background: var(--oat) !important;
  border-color: rgba(29,74,53,.35) !important;
}
html body button#prevPage:hover,
html body button#nextPage:hover { background: var(--oat-soft) !important; }
html body button#prevPage:disabled,
html body button#nextPage:disabled { opacity: .55 !important; }

/* ---------- 31. Search & Filter clarity (all app sections) ---------- */
/* The filter panels are forest cards; give the search controls a cream face
   with forest ink and a tomato focus ring so typing is obvious and legible. */
html body input#searchInput,
html body input#oemSearch,
html body input#brandSearch {
  background: var(--oat) !important;
  background-image: none !important;
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
  border: 1px solid rgba(29,74,53,.38) !important;
  border-radius: 8px !important;
  box-shadow: 0 2px 8px rgba(8,24,16,.14) !important;
  font-weight: 600 !important;
  font-size: 14px !important;
}
/* Old OEM rule forces oat ink on every child of the brand-search card;
   out-specify it so the cream search box keeps dark forest text. */
html body #panelBrands > section:first-child input#brandSearch {
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
}
html body #panelBrands > section:first-child input#brandSearch::placeholder {
  color: var(--forest-mid) !important;
  -webkit-text-fill-color: var(--forest-mid) !important;
}
html body input#searchInput::placeholder,
html body input#oemSearch::placeholder,
html body input#brandSearch::placeholder {
  color: var(--forest-mid) !important;
  -webkit-text-fill-color: var(--forest-mid) !important;
  opacity: .85 !important;
  font-weight: 500 !important;
}
html body input#searchInput:focus,
html body input#oemSearch:focus,
html body input#brandSearch:focus {
  outline: none !important;
  border-color: var(--tomato-btn) !important;
  box-shadow: 0 0 0 3px rgba(242,70,46,.22) !important;
}
/* Search icon sitting inside the cream input. */
html body #filterWrapper svg.absolute,
html body #filterSection svg.absolute,
html body #panelBrands svg.absolute {
  color: var(--forest-mid) !important;
  stroke: var(--forest-mid) !important;
}
/* Labels above the search box: oat on the forest filter card. */
html body #filterWrapper label,
html body #filterSection label,
html body #filterWrapper h2,
html body #filterSection h2 {
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}
/* Clear buttons: secondary — cream face, forest ink, tomato hover. */
html body button#clearFiltersBtn,
html body button#resetFiltersBtn,
html body button#oemResetBtn,
html body button#brandClear {
  background: var(--oat) !important;
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
  border: 1px solid rgba(29,74,53,.35) !important;
  border-radius: 8px !important;
  font-weight: 700 !important;
  font-size: 13px !important;
  padding: 9px 16px !important;
}
html body #panelBrands > section:first-child button#brandClear {
  background: var(--oat) !important;
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
  border: 1px solid rgba(29,74,53,.35) !important;
  font-weight: 700 !important;
}
html body button#clearFiltersBtn:hover,
html body button#resetFiltersBtn:hover,
html body button#oemResetBtn:hover,
html body button#brandClear:hover {
  background: var(--oat-soft) !important;
  border-color: var(--tomato-btn) !important;
}
html body button#resetFiltersBtn:disabled {
  opacity: .55 !important;
}
/* Active filter chips: tomato-outlined pills on the forest card. */
html body #activeFilters > * {
  background: rgba(238,229,212,.1) !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
  border: 1px solid rgba(242,70,46,.5) !important;
  border-radius: 999px !important;
  font-size: 12px !important;
}
html body #activeFilters button {
  color: var(--tomato) !important;
  -webkit-text-fill-color: var(--tomato) !important;
}
/* OEM brand-search active-filter line. */
html body #brandActiveFilter,
html body #brandActiveFilterText {
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}

/* ---------- 32. Final button sweep (all app pages) ---------- */
/* Export CSV is a secondary/locked action: forest ink on cream, never dark red. */
html body button#exportExcelBtn,
html body button#exportContractsExcelBtn {
  background: var(--oat) !important;
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
  border-color: rgba(29,74,53,.35) !important;
}
/* Every pagination arrow: one consistent forest ink. */
html body button[id^="prev"],
html body button[id^="next"],
html body button[id*="Page"] {
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
}
/* Defensive catch-all: any stray solid Tailwind button → tomato primary + oat ink. */
html body button[class*="bg-blue-600"],
html body button[class*="bg-indigo-600"],
html body button[class*="bg-green-600"],
html body button[class*="bg-red-600"] {
  background: linear-gradient(145deg, var(--tomato-btn), var(--tomato-btn-deep)) !important;
  background-image: linear-gradient(145deg, var(--tomato-btn), var(--tomato-btn-deep)) !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
  border-color: transparent !important;
}
html body button[class*="bg-blue-600"] *,
html body button[class*="bg-indigo-600"] *,
html body button[class*="bg-green-600"] *,
html body button[class*="bg-red-600"] * {
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}

/* ---------- 33. Admin colour harmony (royal 60/30/10 only) ---------- */
/* dashboard-pro.css injects purple / periwinkle / neon-green into admin KPI
   charts. Scope every override to the admin shell so user pages stay intact. */
html body:has(#nav a[data-nav]) .pro-kpi-icon {
  color: var(--forest-ink) !important;
  background: rgba(155,199,178,.12) !important;
  border-color: rgba(155,199,178,.3) !important;
}
html body:has(#nav a[data-nav]) .pro-kpi:nth-child(3n+2) .pro-kpi-icon {
  color: var(--accent-dark) !important;
  background: rgba(242,70,46,.12) !important;
  border-color: rgba(242,70,46,.32) !important;
}
html body:has(#nav a[data-nav]) .pro-kpi:nth-child(3n+3) .pro-kpi-icon {
  color: var(--oat) !important;
  background: rgba(238,229,212,.12) !important;
  border-color: rgba(238,229,212,.3) !important;
}
/* KPI mini-bars: sage → tomato → oat, no purple/neon. */
html body:has(#nav a[data-nav]) .pro-mini-bars i {
  background: linear-gradient(180deg, var(--forest-ink), rgba(29,74,53,.35)) !important;
}
html body:has(#nav a[data-nav]) .pro-kpi:nth-child(3n+2) .pro-mini-bars i {
  background: linear-gradient(180deg, var(--tomato), rgba(185,45,25,.3)) !important;
}
html body:has(#nav a[data-nav]) .pro-kpi:nth-child(3n+3) .pro-mini-bars i {
  background: linear-gradient(180deg, var(--oat), rgba(155,199,178,.25)) !important;
}
/* Revenue chart bars: forest-ink → forest. */
html body:has(#nav a[data-nav]) [class*="pro-chart-bar"],
html body:has(#nav a[data-nav]) .pro-chart-bar {
  background: linear-gradient(90deg, var(--forest-ink), var(--forest)) !important;
}
/* Sidebar labels: oat-tinted instead of slate-blue. */
html body:has(#nav a[data-nav]) #nav a,
html body:has(#nav a[data-nav]) #nav-mobile a {
  color: rgba(238,229,212,.74) !important;
}
html body:has(#nav a[data-nav]) #nav a:hover,
html body:has(#nav a[data-nav]) #nav-mobile a:hover,
html body:has(#nav a[data-nav]) #nav a[class*="border-indigo"],
html body:has(#nav a[data-nav]) #nav-mobile a[class*="border-indigo"] {
  color: var(--oat) !important;
}
/* Header + toasts: forest / tomato, never near-black or rose. */
html body:has(#nav a[data-nav]) header {
  background: linear-gradient(145deg, var(--forest), var(--forest-deep)) !important;
}
html body:has(#nav a[data-nav]) [class*="bg-rose-600"] {
  background: var(--tomato-btn) !important;
}
html body:has(#nav a[data-nav]) [class*="bg-slate-900"] {
  background: var(--forest-deep) !important;
}

/* ---------- 34. Owner admin sign-in — royal palette ---------- */
/* admin/login.html still ships an indigo brand panel + dark.css near-black
   inputs (forest ink on black = unreadable). Rebuild both panels in 60/30/10
   without touching the HTML. */
html body:has(form#form) div[class*="bg-gradient-to-br"] {
  background: linear-gradient(155deg, var(--forest), var(--forest-deep)) !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}
html body:has(form#form) div[class*="bg-gradient-to-br"] * {
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}
html body:has(form#form) div[class*="bg-gradient-to-br"] span[class*="text-indigo-300"] {
  color: var(--accent-dark) !important;
  -webkit-text-fill-color: var(--accent-dark) !important;
}
html body:has(form#form) div[class*="bg-gradient-to-br"] div[class*="blur-"] {
  background: rgba(238,229,212,.12) !important;
}
html body:has(form#form) div[class*="bg-gradient-to-br"] div[class*="bg-indigo-400"] {
  background: rgba(242,70,46,.16) !important;
}
/* Right panel sits on the oat canvas — forest ink, cream inputs, tomato focus. */
html body:has(form#form) h2,
html body:has(form#form) form#form label,
html body:has(form#form) p {
  color: var(--forest-mid) !important;
  -webkit-text-fill-color: var(--forest-mid) !important;
}
html body:has(form#form) input#email,
html body:has(form#form) input#password {
  background: var(--oat) !important;
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
  border: 1px solid rgba(29,74,53,.35) !important;
  border-radius: 10px !important;
}
html body:has(form#form) input#email:focus,
html body:has(form#form) input#password:focus {
  outline: none !important;
  border-color: var(--tomato) !important;
  box-shadow: 0 0 0 3px rgba(242,70,46,.22) !important;
}
html body:has(form#form) input#email::placeholder,
html body:has(form#form) input#password::placeholder {
  color: var(--forest-mid) !important;
  -webkit-text-fill-color: var(--forest-mid) !important;
}
html body:has(form#form) button#toggle,
html body:has(form#form) a[href="/forgot-password"],
html body:has(form#form) a[href="/login"] {
  color: var(--forest-mid) !important;
  -webkit-text-fill-color: var(--forest-mid) !important;
}
html body:has(form#form) button#toggle:hover,
html body:has(form#form) a[href="/forgot-password"]:hover,
html body:has(form#form) a[href="/login"]:hover {
  color: var(--tomato-ink) !important;
  -webkit-text-fill-color: var(--tomato-ink) !important;
}
html body:has(form#form) p#error {
  background: rgba(242,70,46,.1) !important;
  border-color: rgba(242,70,46,.4) !important;
  color: var(--tomato-ink) !important;
  -webkit-text-fill-color: var(--tomato-ink) !important;
}
html body:has(form#form) div[class*="rounded-xl"][class*="bg-indigo-600"] {
  background: var(--forest) !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
}

/* ---------- 36. Pagination — one coherent royal control on every list ----------
   Page numbers: cream face + forest ink, current page = tomato primary.
   Arrows: cream face + forest ink; ellipsis: muted oat on the forest footer.
   Overrides Tailwind's -space-x-px overlap with an even gap. */
html body #pageNumbers,
html body #pageNumbersContracts {
  background: transparent !important;
  background-image: none !important;
  border: 0 !important;
  box-shadow: none !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
  padding: 0 !important;
}
html body #pageNumbers > *,
html body #pageNumbersContracts > *,
html body button#prevPage, html body button#nextPage,
html body button#prevPageMobile, html body button#nextPageMobile,
html body button#prevPageContracts, html body button#nextPageContracts,
html body button#prevPageContractsMobile, html body button#nextPageContractsMobile {
  margin-left: 0 !important;
}
html body #pageNumbers,
html body #pageNumbersContracts,
html body #pageNumbers > * + *,
html body #pageNumbersContracts > * + *,
html body #pageNumbers ~ button#nextPage,
html body #pageNumbersContracts ~ button#nextPageContracts {
  margin-left: .375rem !important;
}
html body #pageNumbers button,
html body #pageNumbersContracts button {
  background: var(--oat) !important;
  background-image: none !important;
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
  border: 1px solid rgba(29,74,53,.35) !important;
  border-radius: .5rem !important;
  min-width: 2.25rem;
  height: 2.25rem;
  justify-content: center;
  font-weight: 600 !important;
  transition: background .15s ease, border-color .15s ease;
}
html body #pageNumbers button:hover:not([class*="bg-blue-50"]),
html body #pageNumbersContracts button:hover:not([class*="bg-blue-50"]) {
  background: var(--oat-soft) !important;
  border-color: rgba(29,74,53,.55) !important;
}
html body #pageNumbers button[class*="bg-blue-50"],
html body #pageNumbersContracts button[class*="bg-blue-50"] {
  background: linear-gradient(145deg, var(--tomato-btn), var(--tomato-btn-deep)) !important;
  background-image: linear-gradient(145deg, var(--tomato-btn), var(--tomato-btn-deep)) !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
  border-color: transparent !important;
  font-weight: 700 !important;
}
html body #pageNumbers > span,
html body #pageNumbersContracts > span {
  color: var(--oat-soft) !important;
  -webkit-text-fill-color: var(--oat-soft) !important;
  background: transparent !important;
  border: 0 !important;
  padding: 0 .25rem !important;
}
html body button#prevPage, html body button#nextPage,
html body button#prevPageMobile, html body button#nextPageMobile,
html body button#prevPageContracts, html body button#nextPageContracts,
html body button#prevPageContractsMobile, html body button#nextPageContractsMobile {
  background: var(--oat) !important;
  background-image: none !important;
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
  border: 1px solid rgba(29,74,53,.35) !important;
  border-radius: .5rem !important;
  min-width: 2.25rem;
  height: 2.25rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 .75rem !important;
  transition: background .15s ease, border-color .15s ease;
}
html body button#prevPage:hover:not(:disabled), html body button#nextPage:hover:not(:disabled),
html body button#prevPageMobile:hover:not(:disabled), html body button#nextPageMobile:hover:not(:disabled),
html body button#prevPageContracts:hover:not(:disabled), html body button#nextPageContracts:hover:not(:disabled),
html body button#prevPageContractsMobile:hover:not(:disabled), html body button#nextPageContractsMobile:hover:not(:disabled) {
  background: var(--oat-soft) !important;
  border-color: rgba(29,74,53,.55) !important;
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
}
html body button#prevPage:disabled, html body button#nextPage:disabled,
html body button#prevPageMobile:disabled, html body button#nextPageMobile:disabled,
html body button#prevPageContracts:disabled, html body button#nextPageContracts:disabled,
html body button#prevPageContractsMobile:disabled, html body button#nextPageContractsMobile:disabled {
  opacity: .45 !important;
  cursor: not-allowed !important;
}
html body button#prevPage svg, html body button#nextPage svg,
html body button#prevPageContracts svg, html body button#nextPageContracts svg {
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
}
/* "Showing X to Y of Z results" — oat ink on the forest table footer. */
html body #startItem, html body #endItem, html body #totalItems,
html body #startItemContracts, html body #endItemContracts, html body #totalItemsContracts {
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
  font-weight: 600 !important;
}

/* ---------- 38. OEM header actions, pagination and feedback form ----------
   The OEM list uses its own IDs (#oemPageNumbers / #oemPrev / #oemNext), so
   the shared pagination rules above never reached it. This block also stops
   dark.css's ::after pseudo-element from painting a near-black square over
   the arrows. */
html body #tierCardHeader > div {
  padding: 16px 18px !important;
  border-radius: 14px !important;
  border: 1px solid rgba(238,229,212,.28) !important;
  box-shadow: 0 12px 28px rgba(8,24,16,.2) !important;
}
html body #tierCardHeader :is(button, a) {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 6px !important;
  min-height: 40px !important;
  padding: 0 16px !important;
  border-radius: 10px !important;
  font-size: 13px !important;
  font-weight: 700 !important;
}
html body #tierCardHeader :is(#tierBuyBtn, #tierUpgradeBtn) {
  min-height: 44px !important;
  padding: 0 20px !important;
  background: linear-gradient(145deg, var(--tomato-btn), var(--tomato-btn-deep)) !important;
  background-image: linear-gradient(145deg, var(--tomato-btn), var(--tomato-btn-deep)) !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
  border-color: rgba(238,229,212,.3) !important;
  box-shadow: 0 8px 18px rgba(185,45,25,.3) !important;
}
html body #tierCardHeader #openMyUnlockedBtn {
  background: var(--oat) !important;
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
  border: 1px solid rgba(29,74,53,.35) !important;
}

html body #oemPageNumbers {
  background: transparent !important;
  background-image: none !important;
  border: 0 !important;
  box-shadow: none !important;
  padding: 0 !important;
}
html body #oemPageNumbers > * + *,
html body #oemNext { margin-left: .375rem !important; }
html body #oemPageNumbers button,
html body button#oemPrev, html body button#oemNext,
html body button#oemPrevMobile, html body button#oemNextMobile {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  margin-left: 0 !important;
  min-width: 2.25rem !important;
  height: 2.25rem !important;
  padding: 0 .5rem !important;
  background: var(--oat) !important;
  background-image: none !important;
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
  border: 1px solid rgba(29,74,53,.35) !important;
  border-radius: .5rem !important;
  box-shadow: none !important;
  font-weight: 600 !important;
  transition: background .15s ease, border-color .15s ease;
}
html body #oemPageNumbers button::before,
html body #oemPageNumbers button::after,
html body button#oemPrev::before, html body button#oemPrev::after,
html body button#oemNext::before, html body button#oemNext::after,
html body button#oemPrevMobile::before, html body button#oemPrevMobile::after,
html body button#oemNextMobile::before, html body button#oemNextMobile::after {
  content: none !important;
  display: none !important;
  background: transparent !important;
  box-shadow: none !important;
}
html body #oemPageNumbers button:hover:not([class*="bg-blue-50"]),
html body button#oemPrev:hover:not(:disabled), html body button#oemNext:hover:not(:disabled),
html body button#oemPrevMobile:hover:not(:disabled), html body button#oemNextMobile:hover:not(:disabled) {
  background: var(--oat-soft) !important;
  border-color: rgba(29,74,53,.55) !important;
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
}
html body #oemPageNumbers button[class*="bg-blue-50"] {
  background: linear-gradient(145deg, var(--tomato-btn), var(--tomato-btn-deep)) !important;
  background-image: linear-gradient(145deg, var(--tomato-btn), var(--tomato-btn-deep)) !important;
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
  border-color: transparent !important;
  font-weight: 700 !important;
}
html body #oemPageNumbers > span {
  color: var(--oat-soft) !important;
  -webkit-text-fill-color: var(--oat-soft) !important;
  background: transparent !important;
  border: 0 !important;
  padding: 0 .25rem !important;
}
html body button#oemPrev:disabled, html body button#oemNext:disabled,
html body button#oemPrevMobile:disabled, html body button#oemNextMobile:disabled {
  opacity: .45 !important;
  cursor: not-allowed !important;
}
html body #oemPrev svg, html body #oemNext svg,
html body #oemPrevMobile svg, html body #oemNextMobile svg {
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
}
html body #oemStartItem, html body #oemEndItem, html body #oemTotalItems {
  color: var(--oat) !important;
  -webkit-text-fill-color: var(--oat) !important;
  font-weight: 600 !important;
}

/* The modal's generic forest-surface rule also recoloured form controls to
   oat on an oat face, so typed text was invisible. Keep the oat face, forest
   ink, and a tomato focus ring. */
html body #feedbackModal#feedbackModal :is(input, textarea, select) {
  background: var(--oat) !important;
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
  border: 1px solid rgba(29,74,53,.35) !important;
  border-radius: .5rem !important;
  padding: .625rem .75rem !important;
}
html body #feedbackModal#feedbackModal :is(input, textarea):focus {
  outline: none !important;
  border-color: var(--tomato) !important;
  box-shadow: 0 0 0 3px rgba(242,70,46,.18) !important;
}
html body #feedbackModal#feedbackModal ::placeholder {
  color: var(--forest-mid) !important;
  -webkit-text-fill-color: var(--forest-mid) !important;
  opacity: 1 !important;
}
html body #feedbackModal#feedbackModal #feedbackStatus {
  background: var(--oat) !important;
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
  border: 1px solid rgba(29,74,53,.25) !important;
  border-radius: .5rem !important;
}
html body #feedbackModal#feedbackModal :is(#feedbackCancelBtn, #feedbackSubmitBtn) {
  min-height: 42px !important;
  border-radius: 10px !important;
  font-weight: 700 !important;
}
/* Cancel inherited the modal's oat text on an oat face, so its label vanished.
   Keep the cream secondary face but use forest ink. */
html body #feedbackModal#feedbackModal #feedbackCancelBtn {
  background: var(--oat) !important;
  background-image: none !important;
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
  border: 1px solid rgba(29,74,53,.35) !important;
  box-shadow: none !important;
}
html body #feedbackModal#feedbackModal #feedbackCancelBtn:hover {
  background: var(--oat-soft) !important;
  border-color: rgba(29,74,53,.55) !important;
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
}
html body #feedbackModal#feedbackModal :is(#feedbackCancelBtn, #feedbackSubmitBtn)::before,
html body #feedbackModal#feedbackModal :is(#feedbackCancelBtn, #feedbackSubmitBtn)::after {
  content: none !important;
  display: none !important;
}

/* Paid-plan header has three stats plus two actions; let the action group
   wrap on small screens instead of overflowing the card. */
@media (max-width: 640px) {
  html body #tierCardHeader > div > div > div:last-child {
    flex-wrap: wrap !important;
    justify-content: flex-start !important;
    gap: 8px 12px !important;
    width: 100% !important;
  }
}

/* ---------- 39. "Your Unlocked OEMs" View actions ----------
   They inherit the forest-surface accent (light salmon) while the generic
   secondary rule gives them an oat face — salmon on oat is unreadable.
   Make them real cream pills with forest ink. */
html body .my-unlocked-view.my-unlocked-view.my-unlocked-view {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  min-height: 32px !important;
  padding: 0 12px !important;
  background: var(--oat) !important;
  background-image: none !important;
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
  border: 1px solid rgba(29,74,53,.35) !important;
  border-radius: 8px !important;
  font-size: 13px !important;
  font-weight: 700 !important;
  line-height: 1 !important;
  text-decoration: none !important;
  box-shadow: none !important;
}
html body .my-unlocked-view.my-unlocked-view.my-unlocked-view::before,
html body .my-unlocked-view.my-unlocked-view.my-unlocked-view::after {
  content: none !important;
  display: none !important;
}
html body .my-unlocked-view.my-unlocked-view.my-unlocked-view:hover {
  background: var(--oat-soft) !important;
  border-color: rgba(29,74,53,.55) !important;
  color: var(--forest) !important;
  -webkit-text-fill-color: var(--forest) !important;
  text-decoration: none !important;
}
html body .my-unlocked-view.my-unlocked-view.my-unlocked-view:focus-visible {
  outline: 2px solid var(--tomato) !important;
  outline-offset: 2px !important;
}

