﻿/* --- Tło siatki --- */
.gantt .grid-background {
    fill: none;
}

.gantt .grid-header {
    fill: #1a1f2b; /* ciemniejszy nagłówek */
    stroke: #3a3f50;
    stroke-width: 1.4;
}

.gantt .grid-row {
    fill: #1f2230; /* ciemne tło wierszy */
}

    .gantt .grid-row:nth-child(even) {
        fill: #292c3d; /* ciemniejszy dla parzystych wierszy */
    }

.gantt .row-line {
    stroke: #3a3f50;
}

.gantt .tick {
    stroke: #4a4f5c;
    stroke-width: 0.2;
}

    .gantt .tick.thick {
        stroke-width: 0.4;
    }

/* --- Dzisiaj (today) --- */
.gantt .today-highlight {
    fill: rgba(40, 167, 69, 0.3); /* lekko zielony */
    opacity: 1; /* alfa kontrolowana przez RGBA */
}

/* --- Strzałki zależności --- */
.gantt .arrow {
    fill: none;
    stroke: #888;
    stroke-width: 1.4;
}

/* --- Paski zamówień (kolory ustawiamy w JS) --- */
.gantt .bar {
    fill: #1b2aF9; /* ciemnoniebieskie tło wszystkich pasków */
    stroke: none;
    stroke-width: 0;
    transition: stroke-width .3s ease;
    user-select: none;
}

.gantt .bar-progress {
    fill: rgba(0, 0, 0, 0.2); /* nałożenie postępu */
}

.gantt .bar-invalid {
    fill: transparent;
    stroke: #888;
    stroke-width: 1;
    stroke-dasharray: 5;
}

    .gantt .bar-invalid ~ .bar-label {
        fill: #aaa;
    }

/* --- Napisy na paskach --- */
.gantt .bar-label {
    fill: #ffffff; /* białe, czytelne */
    dominant-baseline: central;
    text-anchor: middle;
    font-size: 12px;
    font-weight: lighter;
}

    .gantt .bar-label.big {
        fill: #ddd;
        text-anchor: start;
    }

/* --- Uchwyty edycji --- */
.gantt .handle {
    fill: #ddd;
    cursor: ew-resize;
    opacity: 0;
    visibility: hidden;
    transition: opacity .3s ease;
}

/* --- Wrapper pasków --- */
.gantt .bar-wrapper {
    cursor: pointer;
    outline: none;
}

    .gantt .bar-wrapper:hover .bar {
        opacity: 0.85; /* lekki efekt hover */
    }

    .gantt .bar-wrapper:hover .bar-progress {
        fill: rgba(0, 0, 0, 0.25);
    }

    .gantt .bar-wrapper:hover .handle {
        visibility: visible;
        opacity: 1;
    }

    .gantt .bar-wrapper.active .bar {
        opacity: 0.85;
    }

    .gantt .bar-wrapper.active .bar-progress {
        fill: rgba(0, 0, 0, 0.25);
    }

/* --- Napisy na osi --- */
.gantt .lower-text, .gantt .upper-text {
    font-size: 12px;
    text-anchor: middle;
}

.gantt .upper-text {
    fill: #ccc;
}

.gantt .lower-text {
    fill: #eee;
}

/* --- Ukrywanie elementów --- */
.gantt .hide {
    display: none;
}

/* --- Kontener Gantta --- */
.gantt-container {
    position: relative;
    overflow: auto;
    font-size: 12px;
}

    /* --- Popup info --- */
    .gantt-container .popup-wrapper {
        position: absolute;
        top: 0;
        left: 0;
        background: rgba(0, 0, 0, 0.85);
        padding: 0;
        color: #ddd;
        border-radius: 3px;
    }

        .gantt-container .popup-wrapper .title {
            border-bottom: 3px solid #1a73e8; /* niebieski pasek nagłówka */
            padding: 10px;
        }

        .gantt-container .popup-wrapper .subtitle {
            padding: 10px;
            color: #ccc;
        }

        .gantt-container .popup-wrapper .pointer {
            position: absolute;
            height: 5px;
            margin: 0 0 0 -5px;
            border: 5px solid transparent;
            border-top-color: rgba(0, 0, 0, 0.85);
        }
