/* Reset & base */
body {
    font-family: 'Segoe UI', Arial, sans-serif;
    margin: 0;
    background: #f6f8fa;
    color: #222;
}
.container {
    width: 100%;
    max-width: 1300px;
    margin: 0 auto;
    display: flex;
    gap: 24px;
    padding: 24px 12px;
    box-sizing: border-box;
}
.sidebar {
    width: 320px;
    min-width: 220px;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.07);
    padding: 24px 18px;
    height: fit-content;
    margin-bottom: 24px;
    position: sticky;
    top: 24px;
}
.sidebar form label {
    display: block;
    margin-bottom: 10px;
    font-size: 1.04em;
    cursor: pointer;
}
#accordion-toggle {
    font-size: 1.13em;
    color: #1976d2;
    margin-bottom: 10px;
}
#accordion-content {
    margin-left: 0;
}
.products {
    flex: 1;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 28px;
    align-items: stretch;
    /* Přidáno pro konzistentní šířku karet */
    min-width: 0;
}
@media (min-width: 700px) {
    .products {
        grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
        /* Zaručí minimálně 2 sloupce na desktopu */
        grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    }
}
@media (max-width: 700px) {
    .products {
        grid-template-columns: 1fr;
        gap: 14px;
        padding: 0 2vw;
    }
}
.card {
    border: none;
    box-shadow: 0 2px 12px rgba(0,0,0,0.10);
    padding: 22px 18px 18px 18px;
    background: #fff;
    border-radius: 14px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
    transition: box-shadow 0.2s, transform 0.2s;
    min-height: 340px;
    position: relative;
}
.card:hover {
    box-shadow: 0 8px 32px rgba(0,0,0,0.18);
    transform: translateY(-6px) scale(1.03);
}
.card img {
    max-width: 100%;
    max-height: 180px;
    object-fit: contain;
    border-radius: 8px;
    background: #f3f3f3;
    margin-bottom: 10px;
}
.card > a {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    text-align: center;
}
.card > div,
.card > span,
.card > form {
    width: 100%;
    text-align: center;
}
.add-to-cart-form {
    margin-top: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
    justify-content: center;
}
.add-to-cart-form input[type="number"] {
    padding: 4px 8px;
    border: 1px solid #bbb;
    border-radius: 5px;
    font-size: 1em;
    width: 54px;
    background: #f7f7f7;
}
.add-to-cart-btn {
    background: #1976d2;
    color: #fff;
    border: none;
    border-radius: 5px;
    padding: 6px 16px;
    font-size: 1em;
    cursor: pointer;
    transition: background 0.15s;
    font-weight: 500;
}
.add-to-cart-btn:disabled {
    background: #ccc;
    cursor: not-allowed;
}
.add-to-cart-btn:hover:not(:disabled) {
    background: #1256a3;
}
.card > div[style*="font-weight:bold"] {
    font-size: 1.13em;
    margin-bottom: 2px;
}
.card > div[style*="margin-bottom:4px"] {
    margin-bottom: 6px !important;
}
.card > div[style*="font-size:0.97em"] {
    color: #666;
    margin-bottom: 2px;
}
.card > span[style*="font-size:1.1em"] {
    color: #1976d2;
}
@media (max-width: 1100px) {
    .container {
        flex-direction: column;
        gap: 0;
        padding: 12px 2vw;
    }
    .sidebar {
        width: 100%;
        max-width: 100%;
        margin-bottom: 18px;
        position: static;
        border-radius: 10px;
    }
    .products {
        grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
        gap: 18px;
    }
}
@media (max-width: 700px) {
    .container {
        padding: 0;
    }
    .sidebar {
        padding: 14px 8px;
        font-size: 0.98em;
    }
    .products {
        grid-template-columns: 1fr;
        gap: 14px;
        padding: 0 2vw;
    }
    .card {
        padding: 14px 8px 12px 8px;
        min-height: 0;
    }
    #open-advanced-filter {
        padding: 6px 0;
        font-size: 1em;
        border-radius: 5px;
    }
    .modal {
        align-items: flex-end !important;
        justify-content: center !important;
    }
    .modal-content {
        margin: 0 auto 0 auto !important;
        border-radius: 12px 12px 0 0 !important;
        min-height: 220px;
        max-height: 95vh;
        overflow-y: auto;
    }
}
@media (max-width: 480px) {
    .sidebar {
        padding: 8px 2px;
        font-size: 0.96em;
    }
    .products {
        padding: 0 1vw;
    }
    .card {
        padding: 8px 2px 8px 2px;
    }
    #open-advanced-filter {
        padding: 5px 0;
        font-size: 0.98em;
        border-radius: 5px;
    }
    .modal-content {
        padding: 8px 1vw 6px 1vw;
        max-width: 100vw;
    }
}

/* ===== Notifikace ===== */
#notification-container {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 9999;
}
.notification {
    background-color: #4caf50;
    color: white;
    padding: 12px 18px;
    margin-bottom: 10px;
    border-radius: 6px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.2);
    font-size: 15px;
    opacity: 0;
    transform: translateY(-10px);
    transition: opacity 0.3s ease, transform 0.3s ease;
}
.notification.show {
    opacity: 1;
    transform: translateY(0);
}

/* === QUANTITY BUTTONS (stejné jako v cart) === */
.cart-qty-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
}
.qty-minus, .qty-plus {
    background: #eee;
    border: none;
    border-radius: 50%;
    width: 28px;
    height: 28px;
    font-size: 1.2em;
    cursor: pointer;
    color: #1976d2;
    transition: background 0.15s;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin: 0 4px;
}
.qty-minus:hover, .qty-plus:hover {
    background: #d0d0d0;
}
.add-to-cart-form input[type="number"] {
    width: 44px;
    min-width: 38px;
    max-width: 50px;
    font-size: 1em;
    padding: 4px 4px;
    margin: 0 4px;
    text-align: center;
    display: inline-block;
}

/* === RESPONSIVE for quantity row/buttons === */
@media (max-width: 700px) {
    .cart-qty-row {
        gap: 10px;
    }
    .add-to-cart-form input[type="number"] {
        width: 54px;
        max-width: 70px;
        font-size: 1.15em;
        padding: 8px 10px;
        margin: 0 8px;
        border-radius: 8px;
        border: 1px solid #bbb;
        background: #fff;
    }
    .qty-minus, .qty-plus {
        width: 38px;
        height: 38px;
        font-size: 1.4em;
        box-shadow: 0 1px 4px rgba(0,0,0,0.07);
        margin: 0;
        background: #eee;
        color: #1976d2;
        border: none;
        border-radius: 50%;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        transition: background 0.15s;
    }
    .qty-minus:hover, .qty-plus:hover {
        background: #d0d0d0;
    }
}

@media (max-width: 480px) {
    .cart-qty-row {
        gap: 6px;
    }
    .add-to-cart-form input[type="number"] {
        width: 38px;
        font-size: 1em;
        padding: 4px 6px;
    }
    .qty-minus, .qty-plus {
        width: 28px;
        height: 28px;
        font-size: 1.1em;
    }
}
