/* ========================================
   TABLEAU REDESIGN 2026 V2 - OSPITAMENTE
   Full month view, mobile-optimized
======================================== */

:root {
    --t-bg: #f8f9fc;
    --t-surface: #ffffff;
    --t-border: #e8ecf1;
    --t-border-light: #f0f2f5;
    --t-text: #1a1f36;
    --t-text-secondary: #6b7280;
    --t-text-muted: #9ca3af;
    --t-accent: #0050b3;
    --t-accent-light: #e6f0ff;
    --t-header-bg: #f1f5f9;
    --t-header-text: #475569;
    --t-room-bg: #f8fafc;
    --t-today: #fff7e6;
    --t-today-border: #fbbf24;
    --t-today-header: #f59e0b;
    --t-weekend: #fafafd;
    --t-confirmed: #10b981;
    --t-confirmed-dark: #059669;
    --t-pending: #f59e0b;
    --t-pending-dark: #d97706;
    --t-checked-in: #3b82f6;
    --t-checked-in-dark: #2563eb;
    --t-checked-out: #94a3b8;
    --t-checked-out-dark: #64748b;
    --t-cancelled: #ef4444;
    --t-cancelled-dark: #dc2626;
    --t-no-show: #8b5cf6;
    --t-no-show-dark: #7c3aed;
    --t-radius: 10px;
    --t-radius-sm: 6px;
    --t-shadow: 0 1px 3px rgba(0,0,0,0.06);
    --t-shadow-md: 0 4px 12px rgba(0,0,0,0.08);
    --t-font: 'Segoe UI', -apple-system, BlinkMacSystemFont, sans-serif;
    /* Dynamic column sizing */
    --t-room-col: 160px;
    --t-day-col: 36px;
    --t-row-h: 50px;
}

/* ============================================
   BASE
============================================ */
.tableau-module {
    background: var(--t-bg);
    font-family: var(--t-font);
    border-radius: var(--t-radius);
    overflow: auto;
    display: flex;
    flex-direction: column;
   min-height: calc(100vh - 60px);
    height: auto;
}

/* ============================================
   TOP BAR - CONTROLLI
============================================ */
.module-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    background: var(--t-surface);
    border-bottom: 1px solid var(--t-border);
    gap: 12px;
    flex-wrap: wrap;
    flex-shrink: 0;
}

.module-header h2 {
    font-size: 18px;
    font-weight: 700;
    color: var(--t-text);
    margin: 0;
    white-space: nowrap;
}

/* Force white background for header controls (overrides admin dark bg) */
.tableau-module > .module-header {
    display: flex !important;
    background: #ffffff !important;
    color: #1a1f36 !important;
    padding: 12px 16px !important;
    border-bottom: 2px solid #e8ecf1 !important;
}

.tableau-module > .module-header h2 {
    color: #1a1f36 !important;
    font-size: 16px !important;
}

.tableau-module .tableau-controls {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
}

.tableau-module .tableau-controls input,
.tableau-module .tableau-controls select {
    padding: 7px 10px;
    border: 1px solid #d1d5db !important;
    border-radius: 8px;
    font-size: 13px;
    font-family: var(--t-font);
    color: #1a1f36 !important;
    background: #ffffff !important;
    transition: all 0.2s;
    outline: none;
}

.tableau-module .tableau-controls input:focus,
.tableau-module .tableau-controls select:focus {
    border-color: var(--t-accent) !important;
    box-shadow: 0 0 0 3px rgba(0,80,179,0.12);
}

.tableau-module .tableau-controls .btn {
    padding: 7px 12px;
    border: 1px solid #d1d5db !important;
    border-radius: 8px;
    background: #ffffff !important;
    color: #4b5563 !important;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    font-family: var(--t-font);
    white-space: nowrap;
}

.tableau-module .tableau-controls .btn:hover {
    background: #f3f4f6 !important;
}

.tableau-module .tableau-controls .btn-primary {
    background: var(--t-accent) !important;
    color: white !important;
    border-color: var(--t-accent) !important;
}

.tableau-module .tableau-controls .btn-primary:hover {
    background: #003d8a !important;
}

/* Checkbox filter */
.tableau-module .checkbox-filter {
    display: flex;
    align-items: center;
    gap: 4px;
    cursor: pointer;
    font-size: 12px;
    color: #4b5563 !important;
    padding: 6px 10px;
    border-radius: 8px;
    transition: background 0.2s;
    white-space: nowrap;
    background: transparent;
}

.tableau-module .checkbox-filter:hover {
    background: #f3f4f6;
}

/* ============================================
   MONTH NAVIGATION BAR
============================================ */
.tableau-month-nav {
    display: flex !important;
    align-items: center;
    justify-content: center;
    gap: 16px;
    padding: 10px 16px;
    background: #ffffff !important;
    border-bottom: 1px solid var(--t-border);
    flex-shrink: 0;
}

.month-nav-btn {
    display: flex !important;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border: 1px solid #d1d5db;
    border-radius: 50%;
    background: #ffffff !important;
    color: #1a1f36 !important;
    font-size: 20px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
    flex-shrink: 0;
    line-height: 1;
}

.month-nav-btn:hover {
    background: var(--t-accent) !important;
    color: white !important;
    border-color: var(--t-accent);
}

.month-nav-btn:active {
    transform: scale(0.95);
}

.month-nav-title {
    font-size: 18px;
    font-weight: 700;
    color: #1a1f36 !important;
    min-width: 180px;
    text-align: center;
    text-transform: capitalize;
}

.month-nav-today {
    padding: 5px 14px;
    border: 1px solid var(--t-accent);
    border-radius: 16px;
    background: transparent;
    color: var(--t-accent) !important;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.month-nav-today:hover {
    background: var(--t-accent) !important;
    color: white !important;
}

/* ============================================
   ROOM COUNTER (Stats bar)
============================================ */
.room-counter {
    display: flex;
    gap: 10px;
    padding: 8px 16px;
    background: #ffffff !important;
    border-bottom: 1px solid var(--t-border);
    overflow-x: auto;
    flex-shrink: 0;
}

.room-count-info {
    font-size: 12px;
    color: #4b5563 !important;
    white-space: nowrap;
}

/* ============================================
   LEGENDA COMPATTA
============================================ */
.tableau-legend {
    display: flex;
    gap: 6px;
    padding: 8px 16px;
    background: #ffffff !important;
    border-bottom: 1px solid var(--t-border);
    overflow-x: auto;
    flex-wrap: nowrap;
    flex-shrink: 0;
}

.legend-section {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: nowrap;
}

.legend-section h4 {
    font-size: 10px;
    color: var(--t-text-muted);
    margin: 0;
    font-weight: 600;
    white-space: nowrap;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 3px;
    font-size: 10px;
    color: var(--t-text-secondary);
    white-space: nowrap;
}

.status-box {
    width: 14px;
    height: 8px;
    border-radius: 3px;
    display: inline-block;
}

.status-box.confirmed { background: var(--t-confirmed); }
.status-box.pending { background: var(--t-pending); }
.status-box.checked-in { background: var(--t-checked-in); }
.status-box.checked_out { background: var(--t-checked-out); }
.status-box.cancelled { background: var(--t-cancelled); }
.status-box.no_show { background: var(--t-no-show); }
.status-box.available { background: #d1fae5; }
.status-box.occupied { background: #fecaca; }
.status-box.maintenance { background: #fef3c7; }
.status-box.blocked { background: #e5e7eb; }

/* ============================================
   GRIGLIA TABLEAU - FULL MONTH FIT
============================================ */
.tableau-container {
    flex: 1;
    overflow: auto;
    background: var(--t-surface);
    -webkit-overflow-scrolling: touch;
    position: relative;
    /* Force visible scrollbar */
    overflow-x: scroll !important;
    overflow-y: auto;
    scrollbar-width: auto;
    scrollbar-color: #8899aa #e8ecf1;
}

.tableau-container::-webkit-scrollbar {
    height: 12px;
    width: 10px;
    display: block !important;
}

.tableau-container::-webkit-scrollbar-track {
    background: #e8ecf1;
    border-radius: 6px;
}

.tableau-container::-webkit-scrollbar-thumb {
    background: #8899aa;
    border-radius: 6px;
    border: 2px solid #e8ecf1;
}

.tableau-container::-webkit-scrollbar-thumb:hover {
    background: #667788;
}

.tableau-table.enhanced {
    border-collapse: separate;
    border-spacing: 0;
    font-size: 12px;
    font-family: var(--t-font);
    background: var(--t-surface);
    /* Make table fill container width */
    width: max-content;
    min-width: 100%;
}

/* ============================================
   HEADER GIORNI
============================================ */
.tableau-table.enhanced thead th {
    background: var(--t-header-bg);
    color: var(--t-header-text);
    padding: 6px 1px;
    text-align: center;
    font-weight: 600;
    font-size: 10px;
    border-bottom: 2px solid var(--t-border);
    border-right: 1px solid var(--t-border-light);
    position: sticky;
    top: 0;
    z-index: 20;
    min-width: var(--t-day-col);
    width: var(--t-day-col);
    white-space: nowrap;
    line-height: 1.2;
}

.tableau-table.enhanced thead th:first-child {
    min-width: var(--t-room-col);
    width: var(--t-room-col);
    max-width: var(--t-room-col);
    text-align: left;
    padding-left: 12px;
    font-size: 12px;
    position: sticky;
    left: 0;
    z-index: 40;
}

.day-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0;
}

.day-number {
    font-size: 14px;
    font-weight: 700;
    color: var(--t-text);
    line-height: 1.2;
}

.day-name {
    font-size: 8px;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    color: var(--t-text-muted);
    font-weight: 600;
}

/* ============================================
   COLONNA CAMERE (STICKY)
============================================ */
.tableau-table.enhanced thead th.room-column {
    background: var(--t-header-bg) !important;
    color: var(--t-header-text) !important;
    min-width: var(--t-room-col);
    width: var(--t-room-col);
    max-width: var(--t-room-col);
    position: sticky;
    left: 0;
    z-index: 30;
    border-right: 2px solid var(--t-border) !important;
}

.tableau-table.enhanced td.room-cell {
    background: var(--t-room-bg) !important;
    border-right: 2px solid var(--t-border) !important;
    border-bottom: 1px solid var(--t-border-light) !important;
    padding: 6px 10px !important;
    min-width: var(--t-room-col);
    width: var(--t-room-col);
    max-width: var(--t-room-col);
    height: var(--t-row-h);
    vertical-align: middle;
    position: sticky;
    left: 0;
    z-index: 10;
}

.room-info {
    text-align: left;
    display: flex;
    flex-direction: column;
    gap: 1px;
}

.room-number {
    font-weight: 700;
    font-size: 14px;
    color: var(--t-text);
    margin: 0;
    line-height: 1.2;
}

.room-type {
    font-size: 11px;
    color: var(--t-text-muted);
    margin: 0;
    line-height: 1.3;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 130px;
}

.room-floor {
   font-size: 11px;
    font-weight: 700;
    color: var(--t-text);
    margin: 0;
}
.room-notes {
    font-size: 12px;
    color: var(--t-text);
    font-style: italic;
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 140px;
}

.room-status {
    display: inline-flex;
    align-items: center;
    font-size: 8px;
    padding: 1px 6px;
    border-radius: 8px;
    margin-top: 1px;
    font-weight: 600;
    letter-spacing: 0.2px;
    width: fit-content;
}

.room-status.status-available { background: #d1fae5; color: #065f46; }
.room-status.status-occupied { background: #fecaca; color: #991b1b; }
.room-status.status-maintenance { background: #fef3c7; color: #92400e; }
.room-status.status-blocked { background: #e5e7eb; color: #4b5563; }

/* ============================================
   CELLE GIORNI
============================================ */
.tableau-table.enhanced td {
    border-right: 1px solid var(--t-border-light);
    border-bottom: 1px solid var(--t-border-light);
    padding: 0;
    text-align: center;
    height: var(--t-row-h);
    min-width: var(--t-day-col);
    width: var(--t-day-col);
    vertical-align: middle;
    position: relative;
    background: var(--t-surface);
    transition: background 0.15s;
}

/* ============================================
   CELLE VUOTE
============================================ */
.empty-cell { background: var(--t-surface); cursor: pointer; }
.empty-cell:hover { background: var(--t-accent-light); }
.empty-slot {
    color: #e5e7eb;
    font-size: 12px;
    font-weight: 300;
    line-height: var(--t-row-h);
    user-select: none;
}
.empty-cell:hover .empty-slot { color: var(--t-accent); }

/* ============================================
   BLOCCHI PRENOTAZIONI
============================================ */
.booking-cell {
    padding: 3px 4px !important;
    cursor: pointer;
    position: relative;
    overflow: visible !important;
    text-align: left;
    height: var(--t-row-h);
    vertical-align: middle;
    border-right: none !important;
    border-left: none !important;
    border-top: 1px solid rgba(255,255,255,0.3) !important;
    border-bottom: 1px solid rgba(0,0,0,0.08) !important;
}

.booking-cell.booking-start {
    border-radius: 6px 0 0 6px;
    padding-left: 8px !important;
}

.booking-cell.booking-end {
    border-radius: 0 6px 6px 0;
}

.booking-cell.booking-start.booking-end {
    border-radius: 6px;
}

/* COLORI PRENOTAZIONI */
.booking-cell.confirmed { background: var(--t-confirmed) !important; color: #fff !important; }
.booking-cell.confirmed.booking-start { box-shadow: inset 3px 0 0 var(--t-confirmed-dark); }

.booking-cell.pending { background: var(--t-pending) !important; color: #000 !important; }
.booking-cell.pending.booking-start { box-shadow: inset 3px 0 0 var(--t-pending-dark); }

.booking-cell.checked_in { background: var(--t-checked-in) !important; color: #fff !important; }
.booking-cell.checked_in.booking-start { box-shadow: inset 3px 0 0 var(--t-checked-in-dark); }

.booking-cell.checked_out { background: var(--t-checked-out) !important; color: #fff !important; opacity: 0.7; }
.booking-cell.checked_out.booking-start { box-shadow: inset 3px 0 0 var(--t-checked-out-dark); }

.booking-cell.cancelled { background: var(--t-cancelled) !important; color: #fff !important; opacity: 0.55; }
.booking-cell.cancelled.booking-start { box-shadow: inset 3px 0 0 var(--t-cancelled-dark); }

.booking-cell.no_show { background: var(--t-no-show) !important; color: #fff !important; opacity: 0.55; }
.booking-cell.no_show.booking-start { box-shadow: inset 3px 0 0 var(--t-no-show-dark); }

/* ============================================
   CONTENUTO BOOKING
============================================ */
.booking-info {
    display: flex;
    flex-direction: column;
    gap: 1px;
    height: 100%;
    justify-content: center;
    padding: 1px 2px;
    white-space: nowrap;
    overflow: visible !important;
    position: relative;
    z-index: 5;
}

.booking-cell.booking-start .booking-info {
    position: relative;
    z-index: 15;
    width: max-content;
    min-width: 100%;
    pointer-events: none;
}

.booking-cell.booking-start .booking-info * { pointer-events: auto; }

.guest-name {
    font-weight: 700;
    font-size: 10px;
    line-height: 1.2;
    margin: 0;
    white-space: nowrap;
    overflow: visible;
    position: relative;
    z-index: 15;
    text-shadow: 0 1px 2px rgba(0,0,0,0.2);
}

.booking-details {
    display: flex;
    gap: 4px;
    font-size: 8px;
    line-height: 1.2;
    align-items: center;
    white-space: nowrap;
    opacity: 0.9;
}

.booking-code {
    font-family: 'SF Mono', 'Consolas', monospace;
    font-weight: 600;
    font-size: 8px;
}

.nights {
    background: rgba(255,255,255,0.25);
    padding: 1px 4px;
    border-radius: 3px;
    font-weight: 700;
    font-size: 7px;
}

/* MIDDLE/END: hide text */
.booking-cell.booking-middle .booking-info,
.booking-cell.booking-end .booking-info { display: none; }
.booking-cell.booking-start.booking-end .booking-info { display: flex !important; }

/* 1-day booking compact */
.booking-cell.booking-start.booking-end { overflow: hidden !important; }
.booking-cell.booking-start.booking-end .booking-info { width: 100% !important; min-width: 0 !important; overflow: hidden; }
.booking-cell.booking-start.booking-end .guest-name { overflow: hidden; text-overflow: ellipsis; display: block; max-width: 100%; font-size: 8px; }
.booking-cell.booking-start.booking-end .booking-details { display: none; }

.stay-marker, .checkout-marker { display: none; }

/* Channel icons */
.ch-dot {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    font-size: 9px;
    font-weight: 800;
    color: white;
    flex-shrink: 0;
    vertical-align: middle;
    margin-right: 2px;
    box-shadow: 0 1px 2px rgba(0,0,0,0.2);
    font-family: Arial, sans-serif;
}

.channel-logo {
    width: 14px;
    height: 14px;
    border-radius: 3px;
    vertical-align: middle;
    margin-right: 2px;
    object-fit: contain;
    flex-shrink: 0;
}

/* ============================================
   HOVER
============================================ */
.booking-cell:hover {
    filter: brightness(1.1);
    z-index: 50;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

/* ============================================
   OGGI - Highlight column
============================================ */
.today {
    background: var(--t-today) !important;
}

.tableau-table.enhanced thead th.today {
    background: var(--t-today-header) !important;
    color: white !important;
}

.tableau-table.enhanced thead th.today .day-number { color: white; }

/* ============================================
   OVERBOOKING
============================================ */
.booking-cell.overbooking {
    background: repeating-linear-gradient(45deg, var(--t-cancelled), var(--t-cancelled) 6px, var(--t-cancelled-dark) 6px, var(--t-cancelled-dark) 12px) !important;
    animation: pulse-ob 2s infinite;
}

@keyframes pulse-ob { 0%, 100% { opacity: 1; } 50% { opacity: 0.8; } }

.overbooking-alert {
    background: #fef2f2;
    border-left: 4px solid var(--t-cancelled);
    padding: 10px 16px;
    margin: 8px 16px;
    color: #991b1b;
    font-weight: 600;
    border-radius: var(--t-radius-sm);
    font-size: 13px;
    flex-shrink: 0;
}

/* ============================================
   DRAG & DROP
============================================ */
.booking-cell[draggable="true"] { cursor: grab; }
.booking-cell[draggable="true"]:active { cursor: grabbing; }
.drag-over {
    background: var(--t-accent-light) !important;
    border: 2px dashed var(--t-accent) !important;
    border-radius: 6px;
}

/* ============================================
   SUMMARY (bottom)
============================================ */
.tableau-summary {
    padding: 10px 16px;
    background: #ffffff !important;
    border-top: 2px solid var(--t-border);
    flex-shrink: 0;
}

.summary-cards {
    display: flex;
    gap: 12px;
    justify-content: center;
}

.summary-card {
    background: var(--t-bg);
    padding: 10px 20px;
    border-radius: var(--t-radius-sm);
    text-align: center;
    flex: 0 1 200px;
}

.summary-card h4 {
    font-size: 10px;
    color: var(--t-text-muted);
    margin: 0 0 4px;
    text-transform: uppercase;
    font-weight: 600;
}

.summary-value {
    font-size: 18px;
    font-weight: 700;
    color: var(--t-text);
}

/* ============================================
   MOBILE RESPONSIVE
============================================ */
@media (max-width: 768px) {
    :root {
        --t-room-col: 100px;
        --t-day-col: 30px;
        --t-row-h: 44px;
    }

    .tableau-module {
        height: calc(100vh - 56px);
        border-radius: 0;
    }

    .module-header {
        padding: 8px 12px;
        gap: 8px;
    }

    .module-header h2 {
        font-size: 14px;
    }

    .tableau-controls {
        gap: 4px;
        width: 100%;
    }

    .tableau-controls input,
    .tableau-controls select {
        padding: 6px 8px;
        font-size: 12px;
        flex: 1;
        min-width: 0;
    }

    .tableau-controls .btn {
        padding: 6px 8px;
        font-size: 11px;
    }

    /* Hide text on buttons, keep icons */
    .tableau-controls .btn .btn-text { display: none; }
    .checkbox-filter .checkbox-label { font-size: 10px; }

    /* Month nav */
    .tableau-month-nav {
        padding: 8px 12px;
        gap: 10px;
    }

    .month-nav-btn { width: 32px; height: 32px; font-size: 16px; }
    .month-nav-title { font-size: 15px; min-width: 140px; }
    .month-nav-today { padding: 4px 10px; font-size: 11px; }

    /* Legend compact */
    .tableau-legend {
        padding: 6px 12px;
        gap: 4px;
    }

    .legend-section h4 { font-size: 9px; }
    .legend-item { font-size: 9px; }
    .status-box { width: 12px; height: 6px; }

    /* Room counter */
    .room-counter { padding: 4px 12px; }
    .room-count-info { font-size: 10px; }

    /* Room cells */
    .room-cell { padding: 4px 6px !important; }
    .room-number { font-size: 12px; }
    .room-type { font-size: 8px; max-width: 85px; }
    .room-floor { display: none; }
    .room-status { font-size: 7px; padding: 1px 4px; }

    /* Day cells */
    .day-number { font-size: 12px; }
    .day-name { font-size: 7px; }

    /* Booking content */
    .guest-name { font-size: 9px; }
    .booking-details { font-size: 7px; gap: 3px; }
    .booking-code { font-size: 7px; }
    .nights { font-size: 6px; padding: 1px 3px; }
    .ch-dot { width: 14px; height: 14px; font-size: 8px; }
    .empty-slot { font-size: 10px; }

    /* Summary */
    .summary-cards { gap: 8px; }
    .summary-card { padding: 8px 12px; flex: 1; }
    .summary-card h4 { font-size: 9px; }
    .summary-value { font-size: 15px; }
}

@media (max-width: 480px) {
    :root {
        --t-room-col: 80px;
        --t-day-col: 26px;
        --t-row-h: 40px;
    }

    .module-header {
        flex-direction: column;
        align-items: stretch;
    }

    .tableau-controls {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 4px;
    }

    .tableau-controls .btn {
        justify-content: center;
        text-align: center;
    }

    .checkbox-filter { grid-column: 1 / -1; }

    /* Even smaller cells */
    .room-number { font-size: 11px; }
    .room-type { font-size: 7px; max-width: 65px; }
    .room-status { font-size: 6px; }

    .day-number { font-size: 10px; }
    .day-name { font-size: 6px; }

    .guest-name { font-size: 8px; }
    .booking-details { display: none; }
    .ch-dot { width: 12px; height: 12px; font-size: 7px; }

    .tableau-legend { display: none; } /* Hide legend on very small screens */

    .summary-cards { flex-direction: column; }
    .summary-card { flex: auto; }
}

/* ============================================
   FORCE OVERRIDES (against admin.css dark themes)
============================================ */
#tableau-module > .module-header,
.tableau-module > .module-header,
.tableau-module .module-header {
    background: #ffffff !important;
    color: #1a1f36 !important;
}

#tableau-module > .module-header h2,
.tableau-module > .module-header h2 {
    color: #1a1f36 !important;
}

#tableau-module .tableau-controls input[type="date"],
#tableau-module .tableau-controls select,
#tableau-module .room-type-filter {
    background: #ffffff !important;
    color: #1a1f36 !important;
    border: 1px solid #d1d5db !important;
}

#tableau-module .tableau-controls .btn,
#tableau-module .tableau-controls button {
    background: #ffffff !important;
    color: #4b5563 !important;
    border: 1px solid #d1d5db !important;
}

#tableau-module .tableau-controls .btn:hover,
#tableau-module .tableau-controls button:hover {
    background: #f3f4f6 !important;
}

#tableau-module .checkbox-filter {
    color: #4b5563 !important;
}

#tableau-module .checkbox-filter .checkbox-label {
    color: #4b5563 !important;
}

/* ============================================
   PRINT
============================================ */
@media print {
    .tableau-module { border-radius: 0; height: auto; }
    .tableau-container { overflow: visible; flex: auto; }
    .tableau-month-nav, .checkbox-filter { display: none; }
    .booking-cell:hover { filter: none; box-shadow: none; }
    .tableau-table.enhanced { width: 100%; }
    .tableau-table.enhanced thead th { min-width: 20px; width: auto; }
    .tableau-table.enhanced td { min-width: 20px; width: auto; }
}
/* ============================================
   GRID VISIBILITY ENHANCEMENT 2026-06 v2
   Bordi griglia visibili SOLO nelle celle vuote.
   Le prenotazioni coprono i bordi.
   Domeniche evidenziate.
============================================ */

/* Bordi grid - solo su celle vuote (non booking-cell) */
.tableau-table.enhanced thead th {
    border-right: 1px solid #cbd5e1 !important;
    border-bottom: 2px solid #94a3b8 !important;
    background: #f1f5f9 !important;
}

.tableau-table.enhanced td:not(.has-booking):not(.booking-cell):not(:has(.booking-cell)) {
    border-right: 1px solid #cbd5e1 !important;
    border-bottom: 1px solid #cbd5e1 !important;
}

/* Booking cells - sopra la griglia, niente bordi grigi */
.tableau-table.enhanced td.booking-cell,
.tableau-table.enhanced td.has-booking,
.tableau-table.enhanced td:has(.booking-cell) {
    border: none !important;
    position: relative;
    z-index: 2;
}

/* Colonna camere - bordo destro evidente */
.tableau-table.enhanced thead th.room-column,
.tableau-table.enhanced td.room-cell {
    border-right: 2px solid #94a3b8 !important;
    border-bottom: 1px solid #cbd5e1 !important;
}

/* Today column - bordo arancione */
.tableau-table.enhanced thead th.today {
    border-left: 2px solid var(--t-today-border) !important;
    border-right: 2px solid var(--t-today-border) !important;
}

/* Domenica - colonna evidenziata con tinta rosata */
.tableau-table.enhanced thead th.sunday,
.tableau-table.enhanced thead th[data-day="sunday"],
.tableau-table.enhanced thead th[data-weekday="0"],
.tableau-table.enhanced thead th.weekend.dom,
.tableau-table.enhanced thead th.dom {
    background: #fee2e2 !important;
    color: #b91c1c !important;
    font-weight: 600;
}

.tableau-table.enhanced td.sunday,
.tableau-table.enhanced td[data-day="sunday"],
.tableau-table.enhanced td[data-weekday="0"],
.tableau-table.enhanced td.weekend.dom,
.tableau-table.enhanced td.dom {
    background: #fef2f2 !important;
}