

.favorites-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 40px;
    padding: 20px 0;
    position: relative;
}

.favorites-title {
    display: flex;
    align-items: center;
    gap: 15px;
    font-size: 42px;
    font-weight: 700;
    color: var(--text-light);
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
    margin: 0;
}

.favorites-icon {
    color: var(--accent-cyan);
    filter: drop-shadow(0 0 10px rgba(0, 212, 255, 0.5));
    animation: heartbeat 2s infinite;
}

@keyframes heartbeat {
    0% { transform: scale(1); }
    14% { transform: scale(1.1); }
    28% { transform: scale(1); }
    42% { transform: scale(1.1); }
    70% { transform: scale(1); }
}

.favorites-count {
    display: flex;
    align-items: center;
}

.count-badge {
    background: linear-gradient(45deg, var(--primary-blue), var(--accent-cyan));
    color: white;
    padding: 8px 16px;
    border-radius: 25px;
    font-weight: 700;
    font-size: 18px;
    box-shadow: 0 4px 15px rgba(35, 65, 148, 0.4);
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(10px);
}

.clear-favorites-btn {
    background: linear-gradient(45deg, #ff4757, #ff6b7a) !important;
    border: none;
    padding: 12px 24px;
    border-radius: 25px;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(255, 71, 87, 0.4);
    color: white !important;
}

.clear-favorites-btn:hover {
    background: linear-gradient(45deg, #ff3742, #ff5722) !important;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 71, 87, 0.6);
}

.favorites-content {
    position: relative;
    z-index: 1;
}


.container_products {
    display: flex;
    justify-content: center;
}

.cards_wrapper {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    align-items: stretch;
}

.card {
    justify-content: space-between;
    display: flex;
    flex-direction: column;
    height: 100%; 
    background: var(--card-bg);
    backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    border-radius: 15px;
    padding: 15px;
    text-align: center;
    transition: all 0.3s ease;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
    position: relative;
}

.card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    border-color: var(--accent-cyan);
    background: rgba(255, 255, 255, 0.98);
}

.card__top {
    position: relative;
}

.card__image img {
    width: 100%;
    border-radius: 10px;
    display: flex;
    align-items: center;
    transition: all 0.3s ease;
}

.card:hover .card__image img {
    transform: scale(1.05);
}

.favorite-remove {
    position: absolute;
    top: 5px;
    right: 5px;
    z-index: 2;
}

.remove-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    background: rgba(255, 71, 87, 0.9);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    color: white;
    font-size: 14px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(255, 71, 87, 0.3);
}

.remove-btn:hover {
    background: rgba(255, 71, 87, 1);
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(255, 71, 87, 0.5);
    color: white;
}

.card__prices {
    min-height: 40px;
    margin: 10px 0;
}

.card__price--discount {
    color: rgba(0, 0, 0, 0.819);
    font-size: 18px;
    font-weight: bold;
}

.card__price--common {
    text-decoration: line-through;
    color: gray;
}

.card__title {
    white-space: nowrap;
    text-overflow: ellipsis;
    height: 40px;
    font-weight: 600;
    display: block;
    margin: 10px 0;
    color: #333;
    text-decoration: none;
    display: -webkit-box;
    min-height: 48px;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    transition: color 0.3s ease;
}

.card__title:hover {
    color: var(--primary-blue);
}

.card p{
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    color: #555;
}

.card__func{
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.card__bottom {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    margin-top: auto; 
}

.description {
    flex-grow: 1; 
    min-height: 60px; 
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 3; 
    -webkit-box-orient: vertical;
}

.card__func a{
    color: #999999;
    transition: all 0.3s ease;
    font-size: 18px;
}

.card__func a:hover{
    color: var(--accent-cyan);
    transform: scale(1.2);
}

.button-cart{
    border: none;
    background: linear-gradient(45deg, var(--primary-blue), var(--accent-cyan)) !important;
    color: white !important;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(35, 65, 148, 0.3);
}

.button-cart:hover{
    background: linear-gradient(45deg, var(--secondary-blue), #00b8e6) !important;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(35, 65, 148, 0.5);
}

.button-cart:active{
    transform: translateY(0);
    box-shadow: 0 2px 10px rgba(35, 65, 148, 0.4);
}


.empty-favorites {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 60vh;
    padding: 40px 20px;
}

.empty-favorites-content {
    text-align: center;
    max-width: 500px;
    background: var(--glass-bg);
    backdrop-filter: blur(15px);
    border: 1px solid var(--glass-border);
    border-radius: 25px;
    padding: 60px 40px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.3);
}

.empty-icon {
    font-size: 80px;
    color: var(--accent-cyan);
    margin-bottom: 30px;
    filter: drop-shadow(0 0 15px rgba(0, 212, 255, 0.3));
    animation: float 3s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
}

.empty-title {
    font-size: 28px;
    font-weight: 700;
    color: var(--text-light);
    margin-bottom: 15px;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
}

.empty-description {
    font-size: 16px;
    color: var(--text-muted);
    margin-bottom: 30px;
    line-height: 1.6;
}

.browse-products-btn {
    background: linear-gradient(45deg, var(--primary-blue), var(--accent-cyan)) !important;
    border: none;
    padding: 15px 30px;
    border-radius: 25px;
    font-weight: 600;
    font-size: 16px;
    color: white !important;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(35, 65, 148, 0.4);
}

.browse-products-btn:hover {
    background: linear-gradient(45deg, var(--secondary-blue), #00b8e6) !important;
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(35, 65, 148, 0.6);
    color: white !important;
}


@media (max-width: 1200px) {
    .cards_wrapper {
        grid-template-columns: repeat(3, 1fr);
        gap: 20px;
    }
}

@media (max-width: 1024px) {
    .cards_wrapper {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .favorites-header {
        flex-direction: column;
        gap: 20px;
        text-align: center;
        margin-bottom: 30px;
    }

    .favorites-title {
        font-size: 32px;
        justify-content: center;
    }

    .cards_wrapper {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }
    
    .card {
        width: 100%;
        max-width: 100%;
        margin: 10px 0;
    }

    .card__image img {
        max-height: 150px;
        object-fit: contain;
    }

    .empty-favorites-content {
        padding: 40px 20px;
        margin: 0 10px;
    }

    .empty-icon {
        font-size: 60px;
    }

    .empty-title {
        font-size: 24px;
    }

    .browse-products-btn {
        padding: 12px 24px;
        font-size: 14px;
    }
}

@media (max-width: 480px) {
    .cards_wrapper {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .card {
        max-width: 100%;
    }

    .favorites-title {
        font-size: 28px;
        gap: 10px;
    }

    .count-badge {
        font-size: 16px;
        padding: 6px 14px;
    }
}