/**
 * Стили для главной страницы (только специфичные стили, основные стили карточек в shop.css)
 */

/* Бейдж "Популярный" */
.product-badge-popular {
    position: absolute;
    top: 1rem;
    right: 1rem;
    z-index: 10;
}

.product-badge-popular span {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: #0a0e14;
    padding: 0.4rem 0.8rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
}

/* Бейдж "Новинка" */
.product-badge-new {
    position: absolute;
    top: 1rem;
    left: 1rem;
    z-index: 10;
}

.product-badge-new span {
    background: #ef4444;
    color: white;
    padding: 0.4rem 0.8rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
}

/* Иконка протокола */
.product-protocol-icon {
    position: absolute;
    bottom: -15px;
    right: 1rem;
    width: 50px;
    height: 50px;
    background: var(--primary);
    color: #0a0e14;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.1rem;
    box-shadow: 0 0 15px rgba(0, 255, 136, 0.45);
}

/* Заголовок карточки продукта */
.product-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
}

.product-card-protocol {
    font-size: 0.75rem;
    padding: 0.25rem 0.75rem;
    background: rgba(var(--primary-rgb, 0, 255, 136), 0.12);
    color: var(--primary);
    border-radius: 20px;
    font-weight: 600;
}

.product-card-price {
    font-size: 0.75rem;
    color: var(--primary);
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

/* Старая цена (зачеркнутая) */
.product-old-price {
    font-size: 0.875rem;
    color: var(--text-secondary);
    text-decoration: line-through;
    margin-bottom: 0.25rem;
}

/* Пустое состояние */
.empty-products {
    grid-column: 1 / -1;
    text-align: center;
    padding: 4rem 2rem;
    background: var(--bg-card);
    border-radius: 16px;
    border: 1px solid var(--border-color);
}

.empty-products-icon {
    font-size: 4rem;
    color: var(--text-muted);
    margin-bottom: 1.5rem;
}

/* Секция популярных товаров */
.popular-products {
    padding: 4rem 0;
}

/* ===== HERO СЕКЦИЯ ===== */
.hero {
    padding: 6rem 0;
    background: radial-gradient(circle at 50% 40%, rgba(0, 255, 136, 0.08) 0%, transparent 70%);
    border-bottom: 1px solid rgba(0, 255, 136, 0.08);
    overflow: hidden;
    position: relative;
}

.hero::before {
    content: '';
    position: absolute;
    top: -200px;
    right: -400px;
    width: 900px;
    height: 600px;
    background: radial-gradient(circle, rgba(0, 255, 136, 0.1) 0%, transparent 70%);
    animation: float 6s ease-in-out infinite;
}

.hero-content {
    position: relative;
    z-index: 1;
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 800;
    margin-bottom: 1.5rem;
    line-height: 1.1;
    background: linear-gradient(to right, #ffffff, var(--primary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-bottom: 3rem;
    line-height: 1.6;
}

.hero-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* ===== FEATURES СЕКЦИЯ ===== */
.features {
    padding: 5rem 0;
    background: var(--bg-darker);
}

.section-header {
    text-align: center;
    margin-bottom: 3rem;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--text-primary);
    margin-bottom: 1rem;
}

.section-subtitle {
    font-size: 1.125rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.feature-card {
    padding: 2.5rem;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    text-align: center;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--primary), var(--primary-light));
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.3s ease;
}

.feature-card:hover {
    border-color: var(--primary);
    background: rgba(99, 102, 241, 0.02);
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(99, 102, 241, 0.15);
}

.feature-card:hover::before {
    transform: scaleX(1);
}

.feature-icon {
    width: 60px;
    height: 60px;
    margin: 0 auto 1.5rem;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.2) 0%, rgba(139, 92, 246, 0.2) 100%);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    font-size: 1.5rem;
    transition: all 0.3s ease;
}

.feature-card:hover .feature-icon {
    background: linear-gradient(135deg, var(--primary) 0%, rgba(99, 102, 241, 0.8) 100%);
    color: white;
    transform: scale(1.1) rotate(-5deg);
}

.feature-card h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.75rem;
}

.feature-card p {
    font-size: 0.95rem;
    color: var(--text-secondary);
    line-height: 1.6;
}

/* ===== STATS СЕКЦИЯ ===== */
.stats {
    padding: 5rem 0;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.05) 0%, rgba(139, 92, 246, 0.05) 100%);
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.stats .stat-item {
    padding: 3rem 2rem;
    text-align: center;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.stats .stat-item::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 200px;
    height: 200px;
    background: radial-gradient(circle, rgba(99, 102, 241, 0.1) 0%, transparent 70%);
    animation: pulse 3s ease-in-out infinite;
}

.stats .stat-item:hover {
    transform: translateY(-8px);
    border-color: var(--primary);
    box-shadow: 0 15px 40px rgba(99, 102, 241, 0.2);
}

.stats .stat-item h3 {
    font-size: 3rem;
    font-weight: 900;
    background: linear-gradient(135deg, var(--primary) 0%, rgba(99, 102, 241, 0.8) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 0.75rem;
    position: relative;
    z-index: 1;
}

.stats .stat-item p {
    font-size: 1rem;
    color: var(--text-secondary);
    font-weight: 500;
    position: relative;
    z-index: 1;
}

/* ===== CTA СЕКЦИЯ ===== */
.cta {
    padding: 5rem 0;
    background: var(--bg-dark);
}

.cta-content {
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
    padding: 4rem 2rem;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.1) 0%, rgba(139, 92, 246, 0.1) 100%);
    border: 1px solid var(--border-color);
    border-radius: 20px;
}

.cta-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
    margin-top: 2.5rem;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
    .hero-title {
        font-size: 2.5rem;
    }

    .hero-subtitle {
        font-size: 1rem;
    }

    .section-title {
        font-size: 2rem;
    }

    .stat-item h3 {
        font-size: 2.5rem;
    }

    .features-grid,
    .stats-grid {
        grid-template-columns: 1fr;
    }

    .hero-actions,
    .cta-actions {
        flex-direction: column;
        align-items: stretch;
    }
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(20px);
    }
}

@keyframes pulse {

    0%,
    100% {
        transform: scale(1);
        opacity: 0.5;
    }

    50% {
        transform: scale(1.1);
        opacity: 0.8;
    }
}

/* Уведомления магазина */
.shop-notification {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 1rem 1.5rem;
    color: white;
    border-radius: var(--border-radius-md);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    z-index: 9999;
    animation: slideInRight 0.3s ease;
    max-width: 350px;
}

.shop-notification.notification-success {
    background: #10b981;
}

.shop-notification.notification-error {
    background: #ef4444;
}

.shop-notification .notification-content {
    display: flex;
    align-items: center;
}

.shop-notification .notification-content [data-icon] {
    width: 20px;
    height: 20px;
    margin-right: 0.5rem;
    vertical-align: middle;
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }

    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideOutRight {
    from {
        transform: translateX(0);
        opacity: 1;
    }

    to {
        transform: translateX(100%);
        opacity: 0;
    }
}