/* ===== GLOBAL ===== */
body {
    margin: 0;
    background: #070716;
    font-family: "Arial", sans-serif;
    color: white;
    overflow-x: hidden;
}

/* ===== CANVAS TŁO ===== */
#snow {
    position: fixed;
    inset: 0;
    z-index: -1;
    pointer-events: none;
}

/* ===== TABELA ===== */
.table-container {
    max-width: 700px;
    margin: 80px auto;
    padding: 20px 30px;
    backdrop-filter: blur(25px);
    background: rgba(255, 255, 255, 0.12);
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 0 30px rgba(255, 255, 255, 0.1);
}

.table-container h1 {
    text-align: center;
    margin-bottom: 20px;
}

.scroll {
    overflow-x: auto;
    max-width: 100%;
}

/* ===== CUSTOM SCROLLBAR ===== */
.custom-scroll::-webkit-scrollbar {
    height: 10px;
    width: 10px;
}

.custom-scroll::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
}

.custom-scroll::-webkit-scrollbar-thumb {
    background: rgba(160, 210, 255, 0.7);
    border-radius: 10px;
    border: 2px solid rgba(255, 255, 255, 0.2);
}

.custom-scroll::-webkit-scrollbar-thumb:hover {
    background: rgba(190, 235, 255, 1);
}

/* ===== TABELA DANE ===== */
table {
    width: 100%;
    border-collapse: collapse;
}


.table-container {
    padding: 20px;
}

td, th {
    padding: 8px 10px;
    word-break: break-word;
}

td:last-child {
    margin-top: 20px;
    display: flex;
    justify-content: flex-end; /* Wymagania po prawej */
    align-items: center;       /* pionowe wyśrodkowanie */
    gap: 12px;                 /* odstęp między przyciskami */
}

tbody tr:hover {
    background: rgba(255, 255, 255, 0.12);
    transition: 0.2s;
}

td .pretty-btn {
    padding: 6px 17px;
    border-radius: 8px;
    background: linear-gradient(135deg, #4a90e2, #70b8ff);
    color: white;
    font-size: 13px;
    font-weight: bold;
    margin-right: 0;
    box-shadow: 0 0 6px rgba(70,160,240,0.5);
    transition: 0.2s;
}

a {
    color: #9cf;
}

.product-thumb {
    width: 60px;
    height: 60px;
    object-fit: cover;
    border-radius: 10px;
    border: 1px solid rgba(255,255,255,0.25);
    box-shadow: 0 0 10px rgba(255,255,255,0.25);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    cursor: pointer;
}

.product-thumb:hover {
    transform: scale(1.15);
    box-shadow: 0 0 15px rgba(255,255,255,0.45);
}

.pretty-btn {
    padding: 8px 14px;
    border-radius: 12px;
    background: linear-gradient(135deg, #6ab0ff, #a8d8ff);
    border: none;
    cursor: pointer;
    color: black;
    font-weight: bold;
    font-size: 14px;
    transition: 0.2s;
    box-shadow: 0 0 10px rgba(160,210,255,0.5);
}

.pretty-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 0 15px rgba(200,230,255,0.8);
}

.pretty-btn:active {
    transform: scale(0.96);
}

/* ===== MODALE – NOWA, ŁADNA WERSJA ===== */

.modal {
    position: fixed;
    inset: 0;
    backdrop-filter: blur(12px);
    background: rgba(0, 0, 0, 0.55);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 200;
    padding: 20px;
}

.hidden {
    display: none;
}

.modal-box {
    width: min(420px, 90vw);
    max-height: 80vh;
    overflow-y: auto;

    background: rgba(255,255,255,0.18);
    border-radius: 20px;
    padding: 25px 30px;
    color: white;

    border: 1px solid rgba(255,255,255,0.25);
    backdrop-filter: blur(25px);

    box-shadow: 0 0 25px rgba(255,255,255,0.15);

    display: flex;
    flex-direction: column;
    gap: 18px;
}

/* Ładny nagłówek */
.modal-box h2 {
    font-size: 22px;
    margin: 0;
    text-align: center;
}

/* Lista wymagań – większa, czytelna */
.modal-box ul {
    padding-left: 20px;
    display: flex;
    flex-direction: column;
    gap: 10px;

    font-size: 16px;
    line-height: 1.45;
}

/* Przyciski modalowe */
.modal-close {
    background: linear-gradient(135deg, #6ab0ff, #a8d8ff);
    border: none;
    padding: 10px 22px;
    border-radius: 14px;
    color: black;
    font-weight: bold;
    box-shadow: 0 0 12px rgba(160,210,255,0.6);
    cursor: pointer;
    transition: 0.2s;
    margin-top: 10px;
    align-self: center;
}

.modal-close:hover {
    transform: scale(1.05);
    box-shadow: 0 0 18px rgba(200,230,255,0.8);
}


.modal-buttons .pretty-btn {
    margin: 0; /* usuwa margines globalny w modalach */
}

.modal-buttons {
    display: flex;
    justify-content: space-between;
    gap: 10px; /* odległość między przyciskami */
}

/* Nowe style przycisków */
.cancel-btn {
    background: linear-gradient(135deg, #ff6b6b, #ff8787);
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 12px;
    font-weight: bold;
    box-shadow: 0 0 10px rgba(255,100,100,0.5);
    transition: 0.2s;
}

.cancel-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 0 15px rgba(255,120,120,0.8);
}

.confirm-btn {
    background: linear-gradient(135deg, #4acfa0, #70e5c3);
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 12px;
    font-weight: bold;
    box-shadow: 0 0 10px rgba(70,220,180,0.5);
    transition: 0.2s;
}

.confirm-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 0 15px rgba(100,240,200,0.8);
}


/* RESPONSYWNOŚĆ – FULL MOBILE SUPPORT */
@media (max-width: 650px) {

    .table-container {
        margin: 20px 10px;
        padding: 15px;
    }

    h1 {
        font-size: 22px;
    }

    table thead {
        display: none; /* ukrywamy nagłówek, bo na mobilkach i tak się nie mieści */
    }

    table, tbody, tr, td {
        display: block;
        width: 100%;
    }

    tr {
        background: rgba(255,255,255,0.08);
        margin-bottom: 15px;
        padding: 12px;
        border-radius: 12px;
        box-shadow: 0 0 10px rgba(255,255,255,0.08);
    }

    td {
        padding: 8px 5px;
        text-align: left;
        display: flex;
        align-items: center;
        gap: 10px;
    }

    /* MINI NAGŁÓWKI PO LEWEJ STRONIE */
    td::before {
        content: attr(data-label);
        font-weight: bold;
        width: 110px;
        flex-shrink: 0;
        opacity: 0.75;
    }

    /* obrazek */
    .product-thumb {
        width: 70px;
        height: 70px;
    }

    /* kolumna z przyciskami */
    td:last-child {
        justify-content: flex-start !important;
        flex-wrap: wrap;
        gap: 10px;
        margin-top: 10px;
    }

    .pretty-btn {
        flex: 1 1 auto;
        text-align: center;
        padding: 10px 14px;
        font-size: 14px;
    }

    /* modal na telefon */
    .modal-box {
        width: 95vw;
        padding: 20px;
    }

    .modal-box img {
        width: 100%;
        height: auto;
        border-radius: 14px;
    }

    .modal-buttons {
        flex-direction: column;
    }

}
