/* Badgers Claw SaaS - v2.2.0-beta.35 text visibility fix
   Purpose: restore readable text over the rock/cyber transparent theme without changing images. */
:root {
  --bc-text-main: rgba(245, 252, 255, 0.98);
  --bc-text-soft: rgba(220, 245, 255, 0.88);
  --bc-text-muted: rgba(190, 222, 230, 0.78);
  --bc-input-bg: rgba(0, 8, 10, 0.58);
  --bc-input-bg-focus: rgba(0, 14, 18, 0.74);
  --bc-input-border: rgba(0, 238, 255, 0.72);
  --bc-green-border: rgba(33, 255, 70, 0.70);
}

html, body,
main, .main, .content, .page-content, .admin-content, .module-content,
.card, .panel, .dashboard-card, .module-card, .bc-card,
.table, table, td, th,
.modal, .dropdown-menu, .accordion, .list-group, .alert {
  color: var(--bc-text-main) !important;
  text-shadow: 0 1px 2px rgba(0,0,0,.86), 0 0 6px rgba(0,0,0,.45) !important;
}

h1, h2, h3, h4, h5, h6,
.card-title, .panel-title, .module-title, .page-title,
label, .form-label, .form-check-label,
legend, strong, b, .fw-bold, .lead {
  color: var(--bc-text-main) !important;
  opacity: 1 !important;
  text-shadow: 0 1px 3px rgba(0,0,0,.95), 0 0 8px rgba(0, 238, 255, .22) !important;
}

p, span, small, .small, .text-muted, .muted, .help-text,
.card-text, .description, .subtext, .subtitle,
.module-description, .runtime-notice, .notice, .hint {
  color: var(--bc-text-soft) !important;
  opacity: 1 !important;
}

/* Forms were the worst offender: transparent rock background + dark browser text. */
input,
textarea,
select,
.form-control,
.form-select,
.form-check-input,
.input-group-text,
[contenteditable="true"] {
  color: var(--bc-text-main) !important;
  -webkit-text-fill-color: var(--bc-text-main) !important;
  caret-color: #00f5ff !important;
  background-color: var(--bc-input-bg) !important;
  background-image: url('/img/rock-texture.jpg?v=2.2.0-beta.35') !important;
  background-size: cover !important;
  background-position: center !important;
  border-color: var(--bc-input-border) !important;
  opacity: 1 !important;
  text-shadow: 0 1px 2px rgba(0,0,0,.95) !important;
  box-shadow: inset 0 0 0 999px rgba(0, 10, 12, .42), 0 0 0 1px rgba(0, 238, 255, .12) !important;
}

input:focus,
textarea:focus,
select:focus,
.form-control:focus,
.form-select:focus {
  color: #ffffff !important;
  -webkit-text-fill-color: #ffffff !important;
  background-color: var(--bc-input-bg-focus) !important;
  border-color: #21ff46 !important;
  box-shadow: inset 0 0 0 999px rgba(0, 10, 12, .30), 0 0 0 .18rem rgba(0, 238, 255, .20), 0 0 14px rgba(33,255,70,.25) !important;
  outline: none !important;
}

input::placeholder,
textarea::placeholder,
.form-control::placeholder {
  color: rgba(235, 250, 255, .72) !important;
  -webkit-text-fill-color: rgba(235, 250, 255, .72) !important;
  opacity: 1 !important;
}

input:disabled,
textarea:disabled,
select:disabled,
.form-control:disabled,
.form-select:disabled,
input[readonly], textarea[readonly] {
  color: rgba(222, 240, 245, .82) !important;
  -webkit-text-fill-color: rgba(222, 240, 245, .82) !important;
  background-color: rgba(0, 0, 0, .42) !important;
  opacity: 1 !important;
}

/* Browser autofill turns text/background ugly unless pinned. */
input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus,
textarea:-webkit-autofill,
select:-webkit-autofill {
  -webkit-text-fill-color: #ffffff !important;
  caret-color: #00f5ff !important;
  box-shadow: inset 0 0 0 1000px rgba(0, 20, 24, .90) !important;
  border-color: #21ff46 !important;
}

/* Tables/panel control rows */
table th, .table th,
table td, .table td,
tr, tbody, thead,
.admin-table, .panel-table, .module-table,
.panels-control, .panels-control * {
  color: var(--bc-text-main) !important;
  opacity: 1 !important;
}

table input, table textarea, table select,
.table input, .table textarea, .table select,
.panels-control input, .panels-control textarea, .panels-control select {
  color: #f7fdff !important;
  -webkit-text-fill-color: #f7fdff !important;
  font-weight: 600 !important;
  background-blend-mode: multiply !important;
}

/* Buttons/links need readable labels after the transparent theme changes. */
a, a:visited,
.btn, button, [role="button"],
.nav-link, .dropdown-item,
.sidebar a, .sidebar button, .side-nav a, .side-nav button {
  color: var(--bc-text-main) !important;
  -webkit-text-fill-color: var(--bc-text-main) !important;
  opacity: 1 !important;
  text-shadow: 0 1px 2px rgba(0,0,0,.95), 0 0 6px rgba(0,238,255,.22) !important;
}

.btn:hover, button:hover, a:hover,
.nav-link:hover, .dropdown-item:hover,
.sidebar a:hover, .sidebar button:hover {
  color: #ffffff !important;
  -webkit-text-fill-color: #ffffff !important;
}

/* Badges/counters */
.badge, .counter, .count, .pill, .status, .status-pill {
  color: #ffffff !important;
  -webkit-text-fill-color: #ffffff !important;
  opacity: 1 !important;
  text-shadow: 0 1px 2px rgba(0,0,0,.95) !important;
}

/* Keep any intentionally hidden content hidden. */
[hidden], .d-none, .visually-hidden {
  display: none !important;
}
