/* Card del evento: los eventos tienen fondo claro (blanco/badge-light por estado),
   pero FullCalendar pone color de texto blanco en .fc-event-main → texto invisible.
   Forzamos color oscuro legible en el contenido de la card. */
.vzt-event-content { padding: 2px 6px; line-height: 1.15; color: #1a1a2e; }
.vzt-event-content .vzt-event-cliente,
.vzt-event-content .vzt-event-servicio { color: #1a1a2e; }
.vzt-event-cliente { font-size: 12px; }
.vzt-event-servicio { font-size: 11px; opacity: .85; }
.vzt-event-icon-nota { font-size: 11px; }
.vzt-off-span { pointer-events: none; }

/* Botones de cambio de estado: el del estado ACTUAL va relleno con su color sólido.
   Sobre fondo sólido, el icono coloreado (text-success/primary/...) y el texto deben
   verse en blanco para contraste. El disabled del actual no debe atenuarlo (es "activo"). */
#kt_calendar_event_estado_botones button.active { color: #fff; opacity: 1; }
#kt_calendar_event_estado_botones button.active i { color: #fff !important; }
#kt_calendar_event_estado_botones button.active:disabled { opacity: 1; }

/* BUG 6 — bg-events no deben capturar clicks */
.fc .fc-bg-event, .fc .vzt-off-span { pointer-events: none !important; }

/* Tramos "no disponible" — patrón rayado diagonal gris claro */
.fc .fc-bg-event.vzt-off-span,
.fc .vzt-off-span {
    background-color: #f5f5f5 !important;
    background-image: repeating-linear-gradient(
        45deg,
        rgba(0, 0, 0, 0.04) 0,
        rgba(0, 0, 0, 0.04) 6px,
        transparent 6px,
        transparent 12px
    ) !important;
    opacity: 1 !important;
}

/* Badge en header de recurso (profesional) cuando no tiene jornada */
.vzt-resource-badge {
    display: inline-block;
    font-size: 10px;
    font-weight: 600;
    padding: 2px 6px;
    margin-top: 2px;
    border-radius: 4px;
    background: #fef3cd;
    color: #856404;
    border: 1px solid #ffeeba;
}

.vzt-resource-badge.vzt-badge-vacaciones { background: #e0f7fa; color: #006064; border-color: #b2ebf2; }
.vzt-resource-badge.vzt-badge-baja       { background: #fce4ec; color: #880e4f; border-color: #f8bbd0; }
.vzt-resource-badge.vzt-badge-sin-jornada{ background: #eceff1; color: #455a64; border-color: #cfd8dc; }

/* BUG 1 — Dropdowns del calendario: tamaño consistente de checkboxes */
.vzt-calendar-card .dropdown-menu .form-check { padding-left: 1.75rem; min-height: 1.5rem; margin-bottom: 0.35rem; display: flex; align-items: center; }
.vzt-calendar-card .dropdown-menu .form-check-input { width: 1.1rem; height: 1.1rem; margin-left: -1.5rem; margin-top: 0; }
.vzt-calendar-card .dropdown-menu .form-check-label { font-size: 0.9rem; line-height: 1.2; padding-left: 0.25rem; }
.vzt-calendar-card .dropdown-menu hr { margin: 0.5rem 0; }

/* BUG 3 — El contenedor del calendario no debe desbordar el card en width */
/* Card ocupa toda la altura disponible bajo el header de la página */
.vzt-calendar-card {
    display: flex;
    flex-direction: column;
    height: calc(100vh - 110px); /* solo header app + breadcrumb */
    overflow: hidden;
}
.vzt-calendar-card .card-body {
    flex: 1 1 auto;
    padding: 0.25rem;
    min-height: 0;
    overflow: hidden;
}
#kt_calendar_resources { width: 100%; max-width: 100%; height: 100%; min-height: 0; overflow: hidden; }
#kt_calendar_resources .fc { width: 100% !important; max-width: 100%; }
#kt_calendar_resources .fc-scrollgrid { width: 100% !important; }
/* En fullscreen, ocupa 100vh */
.vzt-calendar-card.vzt-calendar-fullscreen { height: 100vh; }
.vzt-calendar-card.vzt-calendar-fullscreen #kt_calendar_resources { height: calc(100vh - 60px); }

/* ITEM 2 — Truncado con ellipsis en nombres de profesionales */
.vzt-resource-label { width: 100%; overflow: hidden; padding: 4px 6px; }
.vzt-resource-title { width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13px; }
.fc .fc-datagrid-cell, .fc .fc-resource { overflow: hidden; }
.fc .fc-datagrid-cell-frame, .fc .fc-resource-cell { overflow: hidden; max-width: 100%; }

/* ITEM 3 — Swal visible sobre el overlay fullscreen */
body.vzt-calendar-fs-active .swal2-container,
body.vzt-calendar-fs-active .modal,
body.vzt-calendar-fs-active .modal-backdrop {
    z-index: 2200 !important;
}

/* === Horarios partidos — contraste de tabla === */

/* Refuerza los bordes de cada slot para que las divisiones de la
   parrilla horaria se vean nitidamente sobre el fondo claro de las
   horas disponibles. */
.fc .fc-timegrid-slot {
    border-color: #e4e6ef !important;
}
.fc .fc-timegrid-slot-minor {
    border-top-style: dotted !important;
}
.fc .fc-timegrid-slot-label {
    border-color: #e4e6ef !important;
}

/* Neutraliza el verde por defecto que FullCalendar aplica a
   .fc-bg-event (#8fdf82 con opacidad 0.3). Los off-span propios
   (vzt-off-span) mantienen su patron rayado gris; los demas bg-event
   quedan transparentes para que el contraste de la tabla mande. */
.fc .fc-bg-event:not(.vzt-off-span) {
    background-color: transparent !important;
    opacity: 0 !important;
}

/* Borde derecho entre columnas de recurso para distinguir profesionales. */
.fc .fc-timegrid-col {
    border-right: 1px solid #e4e6ef;
}
