/* Стили для верхней шапки */
.top-header {
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.top-header .social-icons a {
    transition: transform 0.2s ease;
}

.top-header .social-icons a:hover {
    transform: translateY(-2px);
    color: #602c07 !important;
}

/* Стили для логотипа */
.navbar-brand {
    display: flex;
    align-items: center;
    padding: 0;
}

.logo-img {
    height: 100%;
    width: auto;
    max-width: 100%;
    object-fit: contain;
    transition: opacity 0.3s ease;
}

.logo-img:hover {
    opacity: 0.9;
}

/* Стили для основного меню */
.navbar {
    padding-top: 0.5rem;
    padding-bottom: 0.5rem;
    background-color: #602c07 !important;
}

.nav-link {
    padding: 0.5rem 1rem;
    transition: all 0.2s ease;
}

.nav-link:hover {
    transform: translateY(-2px);
}

/* Улучшенные стили для бейджа корзины */
.badge.bg-danger {
    position: absolute;
    top: -8px;
    right: -8px;
    font-size: 1rem;
    padding: 0;
    font-weight: bold;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.3);
    background: #dc3545 !important;
    color: white;
    animation: pulse 2s infinite ease-in-out;
    z-index: 10;
    user-select: none;
}

/* Постоянная пульсация с большим масштабом */
@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

/* Усиленная анимация при изменении количества */
@keyframes pulse-big {
    0% { transform: scale(1); box-shadow: 0 0 0 0 rgba(220, 53, 69, 0.7); }
    50% { transform: scale(1.3); box-shadow: 0 0 0 15px rgba(220, 53, 69, 0); }
    100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(220, 53, 69, 0); }
}

.badge.bg-danger.pulse-effect {
    animation: pulse-big 0.8s ease-out;
}

/* Эффект волн */
.badge.bg-danger.pulse-effect::after {
    content: '';
    position: absolute;
    top: -5px;
    left: -5px;
    right: -5px;
    bottom: -5px;
    border-radius: 50%;
    background: rgba(220, 53, 69, 0.3);
    animation: wave 1s ease-out;
    z-index: -1;
}

@keyframes wave {
    0% { transform: scale(0.8); opacity: 1; }
    100% { transform: scale(2); opacity: 0; }
}

/* Эффект при наведении */
.nav-link:hover .badge.bg-danger {
    transform: translateY(-2px) scale(1.15);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.4);
}

/* Стили для телефона */
.contact-phone a {
    text-decoration: none !important;
    font-weight: bold !important;
    color: inherit !important;
    transition: color 0.2s ease;
}

.contact-phone a:hover {
    color: #602c07 !important;
}

/* Адаптивные стили */
@media (max-width: 767.98px) {
    .top-header {
        padding: 0.5rem 0;
    }
    
    .navbar-brand {
        margin: 0 auto;
    }
    
    .nav-link {
        padding: 0.5rem;
        font-size: 0.9rem;
    }
    
    .col-md-4.col-8 {
        flex: 0 0 100%;
        max-width: 100%;
    }
    
    .badge.bg-danger {
        width: 24px;
        height: 24px;
        font-size: 0.85rem;
        top: -6px;
        right: -6px;
    }
}
