/* PIEDĀVĀJUMI LAPAS SPECIFISKIE STILI */

/* Products Section */
.products-section {
    background: #ffffff;
    padding: 125px 0;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 40px;
    gap: 30px;
}

.products-controls {
    display: flex;
    gap: 20px;
    align-items: center;
}

.search-box {
    position: relative;
    min-width: 300px;
}

.search-box input {
    width: 100%;
    padding: 12px 45px 12px 16px;
    border: 2px solid var(--light);
    border-radius: 12px;
    background: var(--white);
    font-family: 'Josefin Sans', sans-serif;
    font-size: 14px;
    transition: var(--transition);
}

.search-box input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(251, 70, 130, 0.1);
    outline: none;
}

.search-icon {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text);
    opacity: 0.6;
}

.view-controls {
    display: flex;
    background: var(--white);
    border-radius: 12px;
    padding: 4px;
    border: 2px solid var(--light);
}

.view-btn {
    padding: 8px 12px;
    border: none;
    background: none;
    border-radius: 8px;
    cursor: pointer;
    color: var(--text);
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
}

.view-btn.active {
    background: var(--primary);
    color: var(--white);
}

.view-btn:hover:not(.active) {
    background: var(--light);
}

/* Products Layout */
.products-layout {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 30px;
    align-items: start;
}

/* Filter Sidebar */
.filter-sidebar {
    background: var(--white);
    border-radius: 20px;
    padding: 24px;
    box-shadow: var(--shadow);
    position: sticky;
    top: 120px;
    max-height: calc(100vh - 140px);
    overflow-y: auto;
}

.filter-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 2px solid var(--light);
}

.filter-title {
    display: flex;
    align-items: center;
    gap: 8px;
}

.filter-title h3 {
    margin: 0;
    font-size: 1.3rem;
    color: var(--secondary);
}

.active-filters-count {
    background: var(--primary);
    color: var(--white);
    border-radius: 12px;
    padding: 2px 8px;
    font-size: 0.8rem;
    font-weight: 600;
}

.filter-actions {
    display: flex;
    gap: 8px;
    align-items: center;
}

.btn-clear {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    background: var(--light);
    border: none;
    border-radius: 8px;
    font-size: 0.85rem;
    color: var(--text);
    cursor: pointer;
    transition: var(--transition);
}

.btn-clear:hover {
    background: var(--accent);
    color: var(--primary);
}

.btn-close-filters {
    display: none;
    padding: 6px;
    border: none;
    background: none;
    border-radius: 6px;
    cursor: pointer;
    color: var(--text);
    transition: var(--transition);
}

.btn-close-filters:hover {
    background: var(--light);
    color: var(--primary);
}

/* Filter Groups */
.filter-group {
    margin-bottom: 20px;
}

.filter-group-header {
    margin-bottom: 12px;
}

.filter-group-header h4 {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--secondary);
    margin: 0;
}

/* Common filter option style */
.filter-option {
    display: flex;
    align-items: center;
    padding: 8px 12px;
    margin-bottom: 6px;
    border: 2px solid var(--light);
    border-radius: 8px;
    cursor: pointer;
    transition: var(--transition);
    background: var(--white);
    font-size: 0.9rem;
}

.filter-option:hover {
    border-color: var(--accent);
    transform: translateX(2px);
}

.filter-option input:checked + * {
    border-color: var(--primary);
    background: var(--primary);
    color: var(--white);
}

/* Event filters - compact grid */
.events-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6px;
}

.event-option {
    position: relative;
}

.event-label {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 8px 4px;
    border: 2px solid var(--light);
    border-radius: 8px;
    cursor: pointer;
    transition: var(--transition);
    text-align: center;
    background: var(--white);
    height: 100%;
    min-height: 60px;
    justify-content: center;
}

.event-label:hover {
    border-color: var(--accent);
}

.event-option input:checked + .event-label {
    border-color: var(--primary);
    background: var(--primary);
    color: var(--white);
}

.event-icon {
    font-size: 1.2rem;
    margin-bottom: 4px;
}

.event-text {
    font-size: 0.75rem;
    font-weight: 500;
    line-height: 1.2;
}

/* Size filters - compact */
.sizes-container {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.size-option {
    margin-bottom: 0;
}

.size-label {
    display: flex;
    align-items: center;
    padding: 10px 12px;
    border: 2px solid var(--light);
    border-radius: 8px;
    cursor: pointer;
    transition: var(--transition);
    background: var(--white);
    font-size: 0.9rem;
    font-weight: 500;
}

.size-label:hover {
    border-color: var(--accent);
    transform: translateX(4px);
}

.size-option input:checked + .size-label {
    border-color: var(--primary);
    background: var(--primary);
    color: var(--white);
}

/* Design filters - compact */
.design-option {
    margin-bottom: 6px;
}

.design-label {
    display: flex;
    align-items: center;
    padding: 8px 10px;
    border: 2px solid var(--light);
    border-radius: 8px;
    cursor: pointer;
    transition: var(--transition);
    background: var(--white);
}

.design-label:hover {
    border-color: var(--accent);
}

.design-option input:checked + .design-label {
    border-color: var(--primary);
    background: var(--light);
}

.design-color {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    margin-right: 8px;
    border: 2px solid var(--white);
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    flex-shrink: 0;
}

.design-text {
    font-size: 0.85rem;
    font-weight: 500;
}

/* Product Type filters - compact */
.product-type-option {
    margin-bottom: 6px;
}

.type-label {
    display: flex;
    align-items: center;
    padding: 8px 10px;
    border: 2px solid var(--light);
    border-radius: 8px;
    cursor: pointer;
    transition: var(--transition);
    background: var(--white);
}

.type-label:hover {
    border-color: var(--accent);
}

.product-type-option input:checked + .type-label {
    border-color: var(--primary);
    background: var(--primary);
    color: var(--white);
}

.type-icon {
    font-size: 1rem;
    margin-right: 8px;
    flex-shrink: 0;
}

.type-text {
    font-size: 0.85rem;
    font-weight: 500;
}

/* Hide default checkboxes */
.filter-group input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    cursor: pointer;
    height: 0;
    width: 0;
}

/* Quick Categories */
.quick-categories {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.category-chip {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 16px;
    background: var(--light);
    border: 2px solid transparent;
    border-radius: 12px;
    cursor: pointer;
    transition: var(--transition);
    font-family: 'Josefin Sans', sans-serif;
    font-size: 0.9rem;
    color: var(--text);
}

.category-chip:hover {
    background: var(--accent);
    transform: translateY(-1px);
}

.category-chip.active {
    background: var(--primary);
    color: var(--white);
    border-color: var(--primary);
}

.category-count {
    background: rgba(255, 255, 255, 0.2);
    padding: 2px 8px;
    border-radius: 8px;
    font-size: 0.8rem;
}

/* Price Range */
.price-slider-container {
    padding: 8px 0;
}

.multi-range {
    width: 100%;
    height: 6px;
    background: linear-gradient(to right, var(--light) 0%, var(--primary) 100%);
    border-radius: 3px;
    outline: none;
    -webkit-appearance: none;
}

.multi-range::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 20px;
    height: 20px;
    background: var(--primary);
    border-radius: 50%;
    cursor: pointer;
    border: 3px solid var(--white);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
    transition: var(--transition);
}

.multi-range::-webkit-slider-thumb:hover {
    transform: scale(1.1);
}

.price-labels {
    display: flex;
    justify-content: space-between;
    margin-top: 8px;
    font-size: 0.8rem;
    color: var(--text);
    opacity: 0.7;
}

/* Popular Tags */
.popular-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.tag {
    padding: 6px 12px;
    background: var(--light);
    border-radius: 20px;
    font-size: 0.8rem;
    color: var(--text);
    cursor: pointer;
    transition: var(--transition);
}

.tag:hover {
    background: var(--accent);
    color: var(--primary);
    transform: translateY(-1px);
}

/* Products Main Area */
.products-main {
    min-height: 500px;
}

.products-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    padding: 16px 0;
    border-bottom: 2px solid var(--light);
}

.mobile-filter-toggle {
    display: none;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    background: var(--primary);
    color: var(--white);
    border: none;
    border-radius: 12px;
    cursor: pointer;
    font-family: 'Josefin Sans', sans-serif;
    font-weight: 600;
    transition: var(--transition);
}

.mobile-filter-toggle:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
}

.filter-badge {
    background: var(--white);
    color: var(--primary);
    border-radius: 8px;
    padding: 2px 6px;
    font-size: 0.8rem;
    font-weight: 600;
}

.results-info {
    display: flex;
    align-items: center;
    gap: 16px;
    font-size: 0.9rem;
    color: var(--text);
}

.sort-dropdown select {
    padding: 8px 12px;
    border: 2px solid var(--light);
    border-radius: 8px;
    background: var(--white);
    font-family: 'Josefin Sans', sans-serif;
    font-size: 0.9rem;
    cursor: pointer;
    transition: var(--transition);
}

.sort-dropdown select:focus {
    border-color: var(--primary);
    outline: none;
}

/* Products Grid */
.products-container {
    position: relative;
}

.products-grid {
    display: grid;
    gap: 24px;
    transition: var(--transition);
}

.view-grid {
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
}

.view-list {
    grid-template-columns: 1fr;
}

.view-list .product-card {
    flex-direction: row;
    align-items: center;
    padding: 20px;
}

.view-list .product-card img {
    width: 120px;
    height: 120px;
    margin-right: 20px;
    margin-bottom: 0;
}

.view-list .product-content {
    flex: 1;
}

.view-list .product-actions {
    margin-top: 0;
}

/* Enhanced Product Card */
.product-card {
    background: var(--white);
    border-radius: 16px;
    padding: 0;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
    position: relative;
    display: flex;
    flex-direction: column;
}

.product-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

.product-image {
    position: relative;
    height: 200px;
    overflow: hidden;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.product-card:hover .product-image img {
    transform: scale(1.05);
}

.product-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    background: var(--primary);
    color: var(--white);
    padding: 4px 8px;
    border-radius: 6px;
    font-size: 0.7rem;
    font-weight: 600;
    z-index: 2;
}

/* FIXED: Product actions with corrected syntax */
.product-actions {
    position: absolute;
    top: 12px;
    right: 12px;
    display: flex;
    gap: 8px;
    opacity: 0;
    transform: translateY(-10px);
    transition: var(--transition);
}

.action-btn {
    width: 36px;
    height: 36px;
    background: rgba(255, 255, 255, 0.95);
    border: none;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center; /* FIXED: removed space */
    cursor: pointer;
    transition: var(--transition);
    backdrop-filter: blur(10px);
}

.action-btn:hover {
    background: var(--primary);
    color: var(--white);
    transform: scale(1.1);
}

.product-card:hover .product-actions {
    opacity: 1;
    transform: translateY(0);
}

.product-content {
    padding: 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.product-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--secondary);
    margin-bottom: 8px;
    line-height: 1.3;
}

.product-description {
    font-size: 0.9rem;
    color: var(--text);
    margin-bottom: 12px;
    line-height: 1.4;
    flex: 1;
}

.product-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: auto;
}

.product-price {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--primary);
}

.product-category {
    font-size: 0.8rem;
    color: var(--text);
    opacity: 0.7;
}

/* Moderna groza pievienošanas poga */
.add-to-cart-btn {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: var(--white);
    border: none;
    padding: 12px 20px;
    border-radius: 12px;
    cursor: pointer;
    font-family: 'Josefin Sans', sans-serif;
    font-weight: 600;
    font-size: 0.95rem;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-top: 15px;
    width: 100%;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(251, 70, 130, 0.3);
}

.add-to-cart-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.8s ease;
}

.add-to-cart-btn:hover::before {
    left: 100%;
}

.add-to-cart-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(251, 70, 130, 0.4);
    background: linear-gradient(135deg, var(--primary-dark) 0%, #c53065 100%);
}

.add-to-cart-btn:active {
    transform: translateY(-1px);
    box-shadow: 0 4px 15px rgba(251, 70, 130, 0.3);
}

.add-to-cart-btn .btn-text {
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s ease;
}

.add-to-cart-btn .btn-icon {
    font-size: 1.1rem;
    transition: all 0.3s ease;
}

.add-to-cart-btn .btn-check {
    display: none;
    font-size: 1.1rem;
}

/* Pievienots stāvoklis */
.add-to-cart-btn.added {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.3);
}

.add-to-cart-btn.added:hover {
    background: linear-gradient(135deg, #059669 0%, #047857 100%);
    box-shadow: 0 8px 25px rgba(16, 185, 129, 0.4);
}

.add-to-cart-btn.added .btn-text {
    transform: translateX(-5px);
}

.add-to-cart-btn.added .btn-icon {
    display: none;
}

.add-to-cart-btn.added .btn-check {
    display: block;
}

/* Loading stāvoklis */
.add-to-cart-btn.loading {
    pointer-events: none;
    background: linear-gradient(135deg, #9ca3af 0%, #6b7280 100%);
}

.add-to-cart-btn.loading .btn-text {
    opacity: 0.7;
}

/* Pulsējoša animācija kad produkts tiek pievienots */
@keyframes pulseSuccess {
    0% {
        box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(16, 185, 129, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(16, 185, 129, 0);
    }
}

.add-to-cart-btn.pulse {
    animation: pulseSuccess 0.6s ease-out;
}

/* Loading State */
.loading-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 20px;
    color: var(--text);
}

.loading-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid var(--light);
    border-top: 3px solid var(--primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 16px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: var(--text);
}

.empty-state svg {
    color: var(--light);
    margin-bottom: 16px;
}

.empty-state h3 {
    margin-bottom: 8px;
    color: var(--secondary);
}

.empty-state p {
    margin-bottom: 20px;
    opacity: 0.7;
}

/* Enhanced Pagination */
.pagination-container {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 40px;
    gap: 8px;
}

.pagination-btn {
    padding: 10px 16px;
    border: 2px solid var(--light);
    background: var(--white);
    border-radius: 8px;
    cursor: pointer;
    transition: var(--transition);
    font-family: 'Josefin Sans', sans-serif;
    font-weight: 600;
}

.pagination-btn:hover:not(.disabled) {
    border-color: var(--primary);
    color: var(--primary);
}

.pagination-btn.active {
    background: var(--primary);
    border-color: var(--primary);
    color: var(--white);
}

.pagination-btn.disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.pagination-dots {
    padding: 10px;
    color: var(--text);
    opacity: 0.5;
}

/* Groza stili */
.cart-sidebar {
    position: fixed;
    top: 0;
    right: -400px;
    width: 380px;
    height: 100vh;
    background: var(--white);
    box-shadow: -5px 0 25px rgba(0, 0, 0, 0.1);
    z-index: 1001;
    transition: var(--transition);
    display: flex;
    flex-direction: column;
}

.cart-sidebar.active {
    right: 0;
}

.cart-header {
    padding: 20px;
    border-bottom: 2px solid var(--light);
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: var(--primary);
    color: var(--white);
}

.cart-header h3 {
    margin: 0;
    color: var(--white);
}

.cart-close {
    background: none;
    border: none;
    font-size: 24px;
    color: var(--white);
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cart-content {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
}

.empty-cart {
    text-align: center;
    padding: 40px 20px;
    color: var(--text);
    opacity: 0.7;
}

.empty-cart p {
    margin-bottom: 8px;
    font-weight: 600;
}

.cart-items {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.cart-item {
    display: flex;
    gap: 12px;
    padding: 15px;
    background: var(--gray);
    border-radius: 12px;
    border: 2px solid var(--light);
}

.cart-item-image {
    width: 60px;
    height: 60px;
    border-radius: 8px;
    object-fit: cover;
    flex-shrink: 0;
}

.cart-item-details {
    flex: 1;
}

.cart-item-title {
    font-weight: 600;
    color: var(--secondary);
    margin-bottom: 5px;
    font-size: 0.9rem;
}

.cart-item-price {
    color: var(--primary);
    font-weight: 700;
    font-size: 0.9rem;
}

.cart-item-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 8px;
}

.quantity-controls {
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--white);
    border-radius: 20px;
    padding: 4px;
}

.quantity-btn {
    width: 24px;
    height: 24px;
    border: none;
    background: var(--primary);
    color: var(--white);
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    transition: var(--transition);
}

.quantity-btn:hover {
    background: var(--primary-dark);
}

.quantity-display {
    min-width: 30px;
    text-align: center;
    font-weight: 600;
    font-size: 0.9rem;
}

.remove-item {
    background: none;
    border: none;
    color: var(--danger);
    cursor: pointer;
    padding: 4px;
    border-radius: 4px;
    transition: var(--transition);
}

.remove-item:hover {
    background: var(--danger);
    color: var(--white);
}

/* Cart Footer */
.cart-footer {
    padding: 1.5rem;
    border-top: 2px solid #f0f0f0;
    background-color: #fff;
    border-radius: 16px 16px 0 0;
    box-shadow: 0 -2px 10px rgba(0,0,0,0.05);
}

/* Cart Total Box */
.cart-total {
    text-align: center;
    margin-bottom: 1.2rem;
    padding: 1.2rem;
    background-color: #f9f9f9;
    border-radius: 12px;
    font-size: 1.15rem;
    font-weight: 600;
    box-shadow: 0 4px 15px rgba(0,0,0,0.08);
    transition: transform 0.2s ease;
}
.cart-total:hover {
    transform: translateY(-2px);
}

/* Floating Cart Button */
.cart-floating-btn {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 65px;
    height: 65px;
    background: linear-gradient(145deg, #fb4682, #fb4682);
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 10px 25px rgba(0,0,0,0.25);
    z-index: 1000;
    transition: all 0.3s cubic-bezier(.25,.8,.25,1);
}
.cart-floating-btn:hover {
    transform: scale(1.15) rotate(-5deg);
    box-shadow: 0 15px 35px rgba(0,0,0,0.3);
}

/* Cart Item Count Badge */
.cart-count {
    position: absolute;
    top: -8px;
    right: -8px;
    background-color: #ff3b3b;
    color: #fff;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    font-size: 0.8rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
    transition: transform 0.2s ease;
}
.cart-count.bump {
    transform: scale(1.4);
}

/* Cart Overlay */
.cart-overlay {
    position: fixed;
    inset: 0;
    background-color: rgba(0,0,0,0.55);
    z-index: 900;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.35s ease, visibility 0.35s ease;
}
.cart-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* Filter Overlay for Mobile */
.filter-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.5);
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
}

.filter-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* Smooth transitions for all interactive elements */
button, input, select, .product-card, .category-chip, .tag {
    transition: var(--transition);
}

/* Focus styles for accessibility */
button:focus-visible, 
input:focus-visible, 
select:focus-visible,
.view-btn:focus-visible,
.category-chip:focus-visible {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}

/* Responsive Styles */
@media (max-width: 1200px) {
    .products-layout {
        grid-template-columns: 280px 1fr;
        gap: 20px;
    }
}

@media (max-width: 992px) {
    .section-header {
        flex-direction: column;
        align-items: stretch;
        gap: 20px;
    }
    
    .products-controls {
        justify-content: space-between;
    }
    
    .search-box {
        min-width: 250px;
    }
}

@media (max-width: 768px) {
    .products-layout {
        grid-template-columns: 1fr;
    }
    
    .filter-sidebar {
        position: fixed;
        top: 0;
        left: -100%;
        width: 85%;
        height: 100vh;
        z-index: 1000;
        border-radius: 0;
        transition: left 0.3s ease;
        max-height: 100vh;
    }
    
    .filter-sidebar.active {
        left: 0;
    }
    
    .btn-close-filters {
        display: flex;
    }
    
    .mobile-filter-toggle {
        display: flex;
    }
    
    .products-controls {
        flex-direction: column;
        gap: 16px;
    }
    
    .search-box {
        min-width: 100%;
    }
    
    .view-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    }
    
    .products-toolbar {
        flex-direction: column;
        gap: 16px;
        align-items: stretch;
    }
    
    .results-info {
        justify-content: space-between;
    }
    
    .cart-sidebar {
        width: 100%;
        right: -100%;
    }
    .cart-floating-btn {
        bottom: 1.25rem;
        right: 1.25rem;
        width: 55px;
        height: 55px;
    }
    .cart-count {
        width: 20px;
        height: 20px;
        font-size: 0.7rem;
    }
}

@media (max-width: 576px) {
    .view-grid {
        grid-template-columns: 1fr;
    }
    
    .view-list .product-card {
        flex-direction: column;
        align-items: stretch;
    }
    
    .view-list .product-card img {
        width: 100%;
        height: 200px;
        margin-right: 0;
        margin-bottom: 16px;
    }
    
    .pagination-container {
        flex-wrap: wrap;
    }
    
    .products-controls {
        gap: 12px;
    }
    
    .search-box {
        min-width: 100%;
    }
    
    .view-controls {
        align-self: flex-start;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 15px;
    }
    
    .products-controls {
        flex-direction: column;
        align-items: stretch;
    }
    
    .search-box {
        min-width: 100%;
    }
    
    .view-controls {
        align-self: center;
    }
    
    .filter-sidebar {
        width: 90%;
    }
}

/* Print styles */
@media print {
    .filter-sidebar, .mobile-filter-toggle, .cart-floating-btn, .cart-sidebar {
        display: none !important;
    }
    
    .products-layout {
        grid-template-columns: 1fr;
    }
    
    .products-grid {
        grid-template-columns: repeat(2, 1fr) !important;
    }
    
    .product-card {
        break-inside: avoid;
        box-shadow: none !important;
        border: 1px solid #ddd;
    }
}

/* ATTĒLU PALIELINĀŠANAS MODĀLAIS LOGS (LIGHTBOX) */
.image-lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.92);
    z-index: 2000;
    display: none;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.image-lightbox.active {
    display: flex;
    opacity: 1;
    visibility: visible;
    animation: lightboxFadeIn 0.3s ease;
}

@keyframes lightboxFadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.lightbox-content {
    position: relative;
    width: 90%;
    max-width: 1200px;
    height: 90vh;
    background: transparent;
    display: flex;
    flex-direction: column;
}

.lightbox-close {
    position: absolute;
    top: -40px;
    right: 0;
    background: var(--primary);
    color: white;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 1.2rem;
    cursor: pointer;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.lightbox-close:hover {
    background: var(--primary-dark);
    transform: rotate(90deg) scale(1.1);
}

.lightbox-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.15);
    color: white;
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    font-size: 1.2rem;
    cursor: pointer;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    backdrop-filter: blur(5px);
}

.lightbox-nav:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: translateY(-50%) scale(1.1);
}

.lightbox-prev {
    left: -60px;
}

.lightbox-next {
    right: -60px;
}

.lightbox-image-container {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    border-radius: 8px;
}

#lightboxImage {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    transition: transform 0.3s ease;
    cursor: zoom-in;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

#lightboxImage.zoomed {
    cursor: grab;
}

#lightboxImage.zoomed:active {
    cursor: grabbing;
}

.image-zoom-controls {
    position: absolute;
    bottom: 20px;
    right: 20px;
    display: flex;
    gap: 10px;
    background: rgba(0, 0, 0, 0.7);
    padding: 10px;
    border-radius: 25px;
    backdrop-filter: blur(5px);
}

.zoom-btn {
    width: 36px;
    height: 36px;
    background: rgba(255, 255, 255, 0.95);
    border: none;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center; /* FIXED: removed space */
    cursor: pointer;
    transition: var(--transition);
    backdrop-filter: blur(10px);
}

.zoom-btn:hover {
    background: var(--primary);
    color: var(--white);
    transform: scale(1.1);
}

.lightbox-info {
    position: absolute;
    bottom: -60px;
    left: 0;
    right: 0;
    color: white;
    text-align: center;
    padding: 15px;
}

.image-counter {
    font-size: 0.9rem;
    opacity: 0.8;
    margin-bottom: 5px;
    font-family: 'Josefin Sans', sans-serif;
}

.image-title {
    font-size: 1.1rem;
    font-weight: 500;
    color: white;
    font-family: 'Playfair Display', serif;
}

/* Zoom level indicator */
.zoom-level {
    position: absolute;
    top: 20px;
    right: 20px;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 5px 10px;
    border-radius: 15px;
    font-size: 0.8rem;
    display: none;
}

.zoom-level.show {
    display: block;
}

/* Mobile optimizations */
@media (max-width: 768px) {
    .lightbox-content {
        width: 95%;
        height: 85vh;
    }
    
    .lightbox-nav {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }
    
    .lightbox-prev {
        left: 10px;
    }
    
    .lightbox-next {
        right: 10px;
    }
    
    .lightbox-close {
        top: -50px;
        right: 10px;
    }
    
    .image-zoom-controls {
        bottom: 10px;
        right: 10px;
        padding: 8px;
    }
    
    .zoom-btn {
        width: 35px;
        height: 35px;
        font-size: 0.9rem;
    }
    
    .lightbox-info {
        bottom: -70px;
    }
}

@media (max-width: 480px) {
    .lightbox-nav {
        width: 35px;
        height: 35px;
        font-size: 0.9rem;
    }
    
    .lightbox-prev {
        left: 5px;
    }
    
    .lightbox-next {
        right: 5px;
    }
    
    .image-zoom-controls {
        flex-direction: column;
        gap: 8px;
        padding: 6px;
    }
}

/* Touch device optimizations */
@media (hover: none) and (pointer: coarse) {
    .lightbox-nav {
        background: rgba(255, 255, 255, 0.25);
        width: 44px;
        height: 44px;
    }
    
    .zoom-btn {
        width: 38px;
        height: 38px;
    }
}

/* Smooth loading animations */
.products-grid {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.4s ease, transform 0.4s ease;
}

.products-grid.loading {
    opacity: 0.5;
    transform: translateY(10px);
}

.products-grid.hidden {
    opacity: 0;
    transform: translateY(20px);
}

/* Smooth filter transitions */
.filter-group {
    transition: opacity 0.3s ease;
}

.filter-group.loading {
    opacity: 0.6;
    pointer-events: none;
}

/* Fade in animation for product cards */
.product-card {
    animation: fadeInUp 0.5s ease forwards;
    opacity: 0;
    transform: translateY(20px);
}

@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Stagger animation for product cards */
.products-grid.view-grid .product-card:nth-child(1) { animation-delay: 0.1s; }
.products-grid.view-grid .product-card:nth-child(2) { animation-delay: 0.15s; }
.products-grid.view-grid .product-card:nth-child(3) { animation-delay: 0.2s; }
.products-grid.view-grid .product-card:nth-child(4) { animation-delay: 0.25s; }
.products-grid.view-grid .product-card:nth-child(5) { animation-delay: 0.3s; }
.products-grid.view-grid .product-card:nth-child(6) { animation-delay: 0.35s; }
.products-grid.view-grid .product-card:nth-child(7) { animation-delay: 0.4s; }
.products-grid.view-grid .product-card:nth-child(8) { animation-delay: 0.45s; }

/* ============================================= */
/* AUTORIZĀCIJAS POGAS UN PAZIŅOJUMI */
/* ============================================= */

/* Groza pogas konteiners */
.cart-checkout-container {
    margin-top: 15px;
}

/* Smuka "Doties uz pasūtījumu" poga (kad autorizējies) */
.cart-checkout-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    padding: 15px 20px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: var(--white);
    border: none;
    border-radius: 12px;
    font-family: 'Josefin Sans', sans-serif;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 15px rgba(251, 70, 130, 0.3);
    position: relative;
    overflow: hidden;
}

.cart-checkout-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.7s ease;
}

.cart-checkout-btn:hover::before {
    left: 100%;
}

.cart-checkout-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(251, 70, 130, 0.4);
    background: linear-gradient(135deg, var(--primary-dark) 0%, #c53065 100%);
}

.cart-checkout-btn:active {
    transform: translateY(-1px);
    box-shadow: 0 4px 15px rgba(251, 70, 130, 0.3);
}

.cart-checkout-btn i {
    font-size: 1.2rem;
}

.cart-checkout-btn span {
    font-size: 1.05rem;
}

/* Poga "Autorizēties" (kad nav autorizējies) */
.cart-auth-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    padding: 15px 20px;
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
    color: var(--white);
    border: none;
    border-radius: 12px;
    font-family: 'Josefin Sans', sans-serif;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 15px rgba(52, 152, 219, 0.3);
    position: relative;
    overflow: hidden;
}

.cart-auth-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.7s ease;
}

.cart-auth-btn:hover::before {
    left: 100%;
}

.cart-auth-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(52, 152, 219, 0.4);
    background: linear-gradient(135deg, #2980b9 0%, #1c6ea4 100%);
}

.cart-auth-btn:active {
    transform: translateY(-1px);
    box-shadow: 0 4px 15px rgba(52, 152, 219, 0.3);
}

/* Paziņojums "Lūdzu, autorizējieties" */
.cart-auth-message {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border: 2px solid #dee2e6;
    border-left: 4px solid #3498db;
    border-radius: 12px;
    padding: 20px;
    margin-top: 15px;
    text-align: center;
    animation: fadeInUp 0.5s ease;
}

.cart-auth-message i {
    font-size: 2rem;
    color: #3498db;
    margin-bottom: 10px;
    display: block;
}

.cart-auth-message h4 {
    color: #2c3e50;
    margin-bottom: 8px;
    font-size: 1.1rem;
}

.cart-auth-message p {
    color: #6c757d;
    font-size: 0.9rem;
    margin-bottom: 15px;
    line-height: 1.5;
}

/* Loading indikators */
.cart-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    padding: 15px 20px;
    background: linear-gradient(135deg, #95a5a6 0%, #7f8c8d 100%);
    color: var(--white);
    border: none;
    border-radius: 12px;
    font-family: 'Josefin Sans', sans-serif;
    font-weight: 600;
    font-size: 1rem;
    cursor: not-allowed;
    opacity: 0.8;
}

.cart-loading-spinner {
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-top: 3px solid var(--white);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Responsive */
@media (max-width: 768px) {
    .cart-checkout-btn,
    .cart-auth-btn,
    .cart-loading {
        padding: 14px 18px;
        font-size: 0.95rem;
    }
    
    .cart-auth-message {
        padding: 15px;
    }
}