/* PRUEBA: cada sección con el color del logo de doScene. SOLO EN MODO CLARO (en oscuro la app se ve como siempre).
   - Contactos (programadores y compañías): verde azulado (#00a79d)
   - Espectáculos (programadores) y Mis espectáculos (compañías): fucsia (#ec008c)
   - Programaciones (programadores) y Actuaciones (compañías): amarillo (#ffb500)
   Todas las reglas van con :root:not([data-theme="dark"]). Para quitarlo basta con BORRAR este archivo:
   index.php solo lo enlaza si existe, y todo vuelve al azul de siempre. */

/* ---------- Verde azulado: Contactos ---------- */
:root:not([data-theme="dark"]) body.page-contactos {
  --accent: #00897f;
  --accent-hover: #006f67;
  --bg: #eef5f4;
  --surface-2: #f1f8f7;
  --row-hover: #e3f4f2;
  --border: #d3e0de;
}

/* ---------- Fucsia: Espectáculos y Mis espectáculos ---------- */
:root:not([data-theme="dark"]) :is(body.page-espectaculos, body.page-mis-espectaculos) {
  --accent: #d6007f;
  --accent-hover: #b0006a;
  --bg: #f8eff4;
  --surface-2: #fcf3f8;
  --row-hover: #fce6f2;
  --border: #e6d6df;
}

/* ---------- Amarillo: Programaciones y Actuaciones ----------
   El amarillo del logo sobre blanco casi no se lee como texto: --accent (textos, bordes, enlaces) es un
   ocre más oscuro, y los botones y pestañas rellenos usan el amarillo del logo con texto oscuro. */
:root:not([data-theme="dark"]) :is(body.page-programaciones, body.page-actuaciones) {
  --accent: #a87400;
  --accent-hover: #8a5f00;
  --amarillo: #ffb500;
  --amarillo-hover: #f0a800;
  --bg: #f8f4e9;
  --surface-2: #fdf8eb;
  --row-hover: #fff3d4;
  --border: #e5ddc8;
}
:root:not([data-theme="dark"]) :is(body.page-programaciones, body.page-actuaciones) :is(.btn.primary, .sidebar-link.active, .vista-btn.active, .bell-notas-save, .bell-add-btn:hover) { background: var(--amarillo); border-color: var(--amarillo); color: #1f2430; }
:root:not([data-theme="dark"]) :is(body.page-programaciones, body.page-actuaciones) .btn.primary:hover { background: var(--amarillo-hover); border-color: var(--amarillo-hover); color: #1f2430; }

/* ---------- Fondo blanco en la página, la ficha CRM y la cabecera de la lista ---------- */
:root:not([data-theme="dark"]) :is(body.page-contactos, body.page-espectaculos, body.page-programaciones, body.page-mis-espectaculos, body.page-actuaciones) :is(.app-main, .crm-ficha, .crm-total) { background: #fff; }

/* ---------- Bloques de la ficha CRM: fondo blanco, solo el borde con el color de la sección ---------- */
:root:not([data-theme="dark"]) :is(body.page-contactos, body.page-espectaculos, body.page-programaciones, body.page-mis-espectaculos) .crm-ficha .ficha-bloque { background: #fff; }
/* Igual las barras de selección («0 seleccionados…»): fondo blanco, conservan su borde */
:root:not([data-theme="dark"]) body.page-contactos .toolbar,
:root:not([data-theme="dark"]) :is(body.page-mis-espectaculos, body.page-actuaciones) .sel-bar { background: #fff; }

/* ---------- Pestañas de fichas: las inactivas con el fondo de las cabeceras; la activa en blanco con la raya de color ---------- */
:root:not([data-theme="dark"]) :is(body.page-contactos, body.page-espectaculos, body.page-programaciones) .act-tab { background: var(--surface-2); }
:root:not([data-theme="dark"]) :is(body.page-contactos, body.page-espectaculos, body.page-programaciones) .act-tab .act-tab-count { background: #fff; }
:root:not([data-theme="dark"]) :is(body.page-contactos, body.page-espectaculos, body.page-programaciones) .act-tab.active { background: #fff; box-shadow: inset 0 3px 0 var(--accent); }
:root:not([data-theme="dark"]) :is(body.page-contactos, body.page-espectaculos, body.page-programaciones) .act-tab.active .act-tab-count { background: var(--surface-2); }

/* En la vista Tabla, al revés: las inactivas en blanco y la activa con el fondo de las cabeceras (enlaza con la tabla) */
:root:not([data-theme="dark"]) :is(body.page-contactos, body.page-espectaculos, body.page-programaciones):has(.vista-btn.active[data-vista="tabla"]) .act-tab { background: #fff; }
:root:not([data-theme="dark"]) :is(body.page-contactos, body.page-espectaculos, body.page-programaciones):has(.vista-btn.active[data-vista="tabla"]) .act-tab .act-tab-count { background: var(--surface-2); }
:root:not([data-theme="dark"]) :is(body.page-contactos, body.page-espectaculos, body.page-programaciones):has(.vista-btn.active[data-vista="tabla"]) .act-tab.active { background: var(--surface-2); }
:root:not([data-theme="dark"]) :is(body.page-contactos, body.page-espectaculos, body.page-programaciones):has(.vista-btn.active[data-vista="tabla"]) .act-tab.active .act-tab-count { background: #fff; }

/* ---------- Detalles con el azul escrito a mano ---------- */
:root:not([data-theme="dark"]) :is(body.page-contactos, body.page-espectaculos, body.page-programaciones) .col-resize-handle:hover { background: color-mix(in srgb, var(--accent) 30%, transparent); }
:root:not([data-theme="dark"]) :is(body.page-contactos, body.page-espectaculos, body.page-programaciones) .modal-edit-btn:hover { background: var(--row-hover); }
:root:not([data-theme="dark"]) :is(body.page-mis-espectaculos, body.page-actuaciones) :is(.gira-switch input:focus-visible + .gira-track, .field input:focus, .field select:focus, .field textarea:focus) { box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 25%, transparent); }
