/* Shared appearance tokens. Loaded after the application and login styles. */
:root {
  color-scheme: light;
  --ui-surface: #fff;
  --ui-text: #292322;
  --ui-muted: #716563;
  --ui-canvas: #fff7f2;
  --ui-soft: #fff0e6;
  --ui-border: #eadcd5;
  --ui-accent: #b8342a;
  --ui-shadow: 0 8px 28px rgb(87 42 25 / 7%);
  --brand-gradient: linear-gradient(120deg, #F0935B 0%, #EB4C3F 100%);
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --ui-surface: #242124;
  --ui-text: #f6eeea;
  --ui-muted: #c0b1ab;
  --ui-canvas: #191719;
  --ui-soft: #382724;
  --ui-border: #493b38;
  --ui-accent: #ffab88;
  --ui-shadow: 0 8px 28px rgb(0 0 0 / 18%);
}
:root {
  --brand-canvas: var(--ui-canvas);
  --brand-border: var(--ui-border);
  --brand-ink: var(--ui-text);
  --brand-violet-dark: var(--ui-text);
  --brand-violet-soft: var(--ui-soft);
  --brand-text-secondary: var(--ui-muted);
  --brand-text-accent: var(--ui-accent);
  --bs-body-color: var(--ui-text);
  --bs-body-bg: var(--ui-canvas);
  --bs-border-color: var(--ui-border);
  --bs-primary-rgb: 235, 76, 63;
}
body, body.praxis-auth, body.public-enrollment-body { background: var(--ui-canvas); color: var(--ui-text); }
h1, h2, h3, h4, h5, h6, .h1, .h2, .h3, .h4, .h5, .h6 { color: var(--ui-text); }
.card, .login-box { background: var(--ui-surface); border: 1px solid var(--ui-border); border-radius: 1rem; box-shadow: var(--ui-shadow); }
.card .card-header, .card:not([class*=bg-]) .card-header { background: var(--ui-surface); color: var(--ui-text); border-bottom: 1px solid var(--ui-border); }
.card-header, .card-footer { border-color: var(--ui-border); }
.bg-white, .bg-light, .sidenav-light, .topnav { background-color: var(--ui-surface)!important; }
.sidenav-footer { background: var(--ui-soft)!important; }
.sidenav-light .sidenav-footer { color: var(--ui-text); }
.sidenav-light .sidenav-footer .sidenav-footer-subtitle { color: var(--ui-muted); }
.topnav { border-bottom: 2px solid #F0935B; }
.sidenav-menu .nav-link.active, .sidenav-menu .nav-link:hover { background: var(--ui-soft); }
.page-header, body .wallet-hero, body .cash-status.is-open, .catalog-cover, .public-enrollment-header { background: var(--brand-gradient)!important; }
.page-header .page-header-title, .page-header .text-white, .page-header .text-muted, .wallet-hero, .wallet-hero .wallet-eyebrow, .wallet-hero .wallet-balance, .wallet-hero .wallet-subtitle, .cash-status.is-open *, .public-login-link, .public-login-link:hover { color: #241713!important; }
.wallet-hero .wallet-mini-stat { background: var(--ui-surface); color: var(--ui-text); border-color: var(--ui-border); }
.wallet-hero .wallet-mini-stat span { color: var(--ui-muted); }
.wallet-hero .wallet-mini-stat strong { color: var(--ui-text); }
.wallet-hero .wallet-mini-stat > svg { color: var(--ui-accent); }
.public-enrollment-header img { filter: brightness(0); }
.catalog-card { overflow: hidden; transition: transform .2s, box-shadow .2s; }
.catalog-card:hover { transform: translateY(-3px); box-shadow: 0 12px 32px rgb(144 65 40 / 16%); }
.catalog-toolbar, .report-filter-card .card-body { padding: 1.25rem; border: 1px solid var(--ui-border); border-radius: 1rem; background: var(--ui-surface); }
.report-filter-card .card-body { border: 0; }
.catalog-search { flex: 1; max-width: 34rem; }
.catalog-count, .results-count { display: inline-flex; align-items: center; gap: .65rem; padding: .5rem .85rem; border-radius: 2rem; background: var(--ui-soft); color: var(--ui-text); font-size: .85rem; }
.catalog-count strong { border-radius: 50%; background: var(--ui-accent); color: var(--ui-surface); }
.form-control, .form-select, .input-group-text { border-color: var(--ui-border); }
[data-theme="dark"] .form-select:not([multiple]):not([size]),
[data-theme="dark"] .form-select[size="1"] {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23f6eeea' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e");
}
.form-control:focus, .form-select:focus {
  background-color: var(--ui-surface);
  color: var(--ui-text);
  outline: 2px solid #F0935B;
  outline-offset: 1px;
}
.btn-primary, .btn-download {
  background: var(--brand-gradient); border-color: #EB4C3F; color: #241713;
  --bs-btn-color: #241713; --bs-btn-hover-color: #241713; --bs-btn-active-color: #241713;
  box-shadow: 0 4px 12px rgb(235 76 63 / 20%); font-weight: 650;
}
.btn-primary:hover, .btn-download:hover { background: linear-gradient(120deg, #f5a572, #f16b5f); border-color: #EB4C3F; color: #241713; }
.btn-primary:active, .btn-download:active { background: #F0935B!important; color: #241713!important; }
.btn:disabled, .btn.disabled { opacity: .55; }
.text-primary, .text-danger { color: var(--ui-accent)!important; }
.bg-primary, .bg-success, .bg-info, .bg-warning, .bg-danger,
.bg-primary .text-muted, .bg-success .text-muted, .bg-info .text-muted, .bg-warning .text-muted, .bg-danger .text-muted { color: #241713!important; }
.network-workspace .network-status-activo, .network-workspace .network-avatar, .network-workspace .network-node-main { color: #241713; }
.nav-pills .nav-link.active, .wallet-tabs .nav-link.active, .active > .page-link, .page-link:hover, .page-link:focus { color: #241713; }
.alert { border-color: var(--ui-border); }
.required:after { color: var(--ui-accent); }
.btn-outline-primary, .btn-outline-secondary, .btn-outline-success, .btn-outline-info, .btn-outline-warning, .btn-outline-danger { --bs-btn-color: var(--ui-accent); }
.btn-transparent-dark { color: var(--ui-text)!important; --bs-btn-color: var(--ui-text); --bs-btn-hover-color: #241713; --bs-btn-active-color: #241713; }
.btn-transparent-dark:hover, .btn-transparent-dark:active { color: #241713!important; }
.table { --bs-table-bg: var(--ui-surface); --bs-table-color: var(--ui-text); --bs-table-border-color: var(--ui-border); --bs-table-striped-bg: var(--ui-soft); --bs-table-hover-bg: var(--ui-soft); --bs-table-hover-color: var(--ui-text); }
.card .table thead th { background: var(--ui-soft); color: var(--ui-muted); border-color: var(--ui-border); }
.list-pagination, .report-pagination { flex-wrap: wrap; background: var(--ui-surface); border-color: var(--ui-border); }
.page-link { border-color: var(--ui-border); }
.list-pagination-search { order: -1; }
.list-result-summary { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: .75rem; padding: 1rem; border-bottom: 1px solid var(--ui-border); background: var(--ui-surface); }
.list-result-summary .list-pagination-search { order: 0; margin: 0; }
.report-results-header { gap: 1rem; }
.report-results-header .btn-group .btn { min-width: 3.5rem; }
.dropdown-menu, .modal-content { background: var(--ui-surface); color: var(--ui-text); border-color: var(--ui-border); }
.dropdown-item { color: var(--ui-text); }
.qr-payment-box { background: #fff; }
.auth-showcase { background: var(--brand-gradient); color: #241713; }
.auth-showcase:before { background: transparent; }
.auth-showcase:after { border-color: rgb(255 255 255 / 15%); }
.auth-showcase .hero-copy h1, .auth-showcase .hero-copy h1 em, .auth-showcase .hero-copy p, .auth-showcase .eyebrow, .auth-showcase .auth-brand, .auth-showcase .auth-capabilities * { color: #241713; }
.auth-form-panel { background: var(--ui-canvas); }
.login-box h2 { color: var(--ui-text); }
.input-group-joined { border: 1px solid var(--ui-border); }
.theme-control { display: inline-flex; align-items: center; gap: .4rem; margin: 0; font-size: .75rem; color: var(--ui-text); }
.theme-control select { max-width: 7.5rem; min-height: 2.5rem; padding: .35rem; border: 1px solid var(--ui-border); border-radius: .65rem; background: var(--ui-surface); color: var(--ui-text); }
.theme-control-floating { position: absolute; right: 1rem; top: 1rem; z-index: 10; }
.public-enrollment-header .theme-control { order: 1; }
@media (max-width: 767.98px) {
  .catalog-toolbar { align-items: stretch; flex-direction: column; gap: 1rem; }
  .catalog-search { width: 100%; max-width: none; }
  .card-header .form-control, .card-header .form-select { min-height: 2.75rem; }
  .report-results-header .btn-group { width: 100%; }
  .report-results-header .btn-group .btn { flex: 1; }
  .report-results-header .btn-group .btn span { display: inline!important; }
  .public-enrollment-header .container-xl { flex-wrap: wrap; gap: .75rem; }
  .list-pagination nav { max-width: 100%; overflow-x: auto; }
}
@media (max-width: 575.98px) {
  .theme-control > span { display: none; }
  .theme-control select { max-width: 6.5rem; font-size: .75rem; }
  .catalog-toolbar { padding: 1rem; }
  .list-pagination > [data-list-info] { width: 100%; }
}
@media (max-width: 390px) {
  .topnav .theme-control select { max-width: 5rem; }
}
@media (prefers-reduced-motion: reduce) {
  *, *:before, *:after { animation-duration: .01ms!important; transition-duration: .01ms!important; scroll-behavior: auto!important; }
}
