/* mainFormStyle.css - СОВРЕМЕННЫЙ PREMIUM ДИЗАЙН */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: linear-gradient(135deg, #0f0c29, #302b63, #24243e);
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    color: #1a1a2e;
    overflow-x: hidden;
    position: relative;
}

/* Анимированный фон */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background:
            radial-gradient(circle at 20% 80%, rgba(120, 119, 198, 0.3) 0%, transparent 50%),
            radial-gradient(circle at 80% 20%, rgba(255, 119, 198, 0.2) 0%, transparent 50%),
            repeating-linear-gradient(45deg, rgba(255,255,255,0.02) 0px, rgba(255,255,255,0.02) 2px, transparent 2px, transparent 8px);
    pointer-events: none;
    z-index: 0;
}

/* Основной контейнер */
.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 60px;
    width: 100%;
    position: relative;
    z-index: 1;
}

/* ================================
ПРЕМИУМ ШАПКА
================================ */
.header {
    background: rgba(10, 10, 20, 0.8);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    padding: 20px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    width: 100%;
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 40px;
    width: 100%;
}

/* ЛОГОТИП */
.logo {
    color: white;
    font-size: 28px;
    font-weight: 800;
    letter-spacing: -0.5px;
    text-decoration: none;
    padding: 12px 24px;
    border-radius: 16px;
    background: linear-gradient(135deg, rgba(255,255,255,0.1), rgba(255,255,255,0.05));
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    overflow: hidden;
    flex-shrink: 0;
}

.logo::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.6s ease;
}

.logo:hover {
    background: linear-gradient(135deg, rgba(255,255,255,0.15), rgba(255,255,255,0.08));
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.logo:hover::before {
    left: 100%;
}

/* ПОИСКОВАЯ ФОРМА */
.search-form {
    flex: 1;
    max-width: 600px;
    width: 100%;
}

.search-container {
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(20px);
    border-radius: 60px;
    height: 56px;
    display: flex;
    align-items: center;
    padding: 0 20px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    transition: all 0.4s ease;
    width: 100%;
}

.search-container:focus-within {
    border-color: rgba(255, 255, 255, 0.4);
    background: rgba(255, 255, 255, 0.12);
    box-shadow: 0 0 30px rgba(102, 126, 234, 0.3);
}

.search-input {
    flex: 1;
    border: none;
    outline: none;
    background: transparent;
    font-size: 16px;
    font-weight: 500;
    color: white;
    padding: 0 20px;
    height: 100%;
    width: 100%;
}

.search-input::placeholder {
    color: rgba(255, 255, 255, 0.6);
}

.search-button {
    background: linear-gradient(135deg, #667eea, #764ba2);
    border: none;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.search-button:hover {
    transform: scale(1.05);
    box-shadow: 0 5px 20px rgba(102, 126, 234, 0.4);
}

#findImg {
    width: 20px;
    height: 20px;
    filter: brightness(0) invert(1);
}

/* НАВИГАЦИЯ */
.nav {
    display: flex;
    gap: 16px;
    align-items: center;
    flex-shrink: 0;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 10px;
    color: rgba(255, 255, 255, 0.9);
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    padding: 12px 20px;
    border-radius: 40px;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.nav-link:hover {
    background: rgba(255, 255, 255, 0.12);
    transform: translateY(-2px);
    color: white;
}

.nav-icon {
    width: 20px;
    height: 20px;
    filter: brightness(0) invert(1);
    transition: transform 0.3s ease;
}

.nav-link:hover .nav-icon {
    transform: scale(1.1);
}

/* ================================
ГЕРОЙ СЕКЦИЯ
================================ */
.hero-section {
    padding: 80px 0 60px;
    text-align: center;
}

.hero-title {
    font-size: 64px;
    font-weight: 800;
    background: linear-gradient(135deg, #fff, #a8b2ff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 20px;
    letter-spacing: -1px;
}

.hero-subtitle {
    font-size: 20px;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 40px;
}

.hero-stats {
    display: flex;
    justify-content: center;
    gap: 60px;
    margin-top: 40px;
}

.stat {
    text-align: center;
}

.stat-number {
    font-size: 36px;
    font-weight: 800;
    color: white;
    display: block;
}

.stat-label {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.6);
    margin-top: 8px;
}

/* ================================
ОСНОВНОЙ КОНТЕНТ
================================ */
.main-content {
    padding: 40px 0 80px;
    min-height: calc(100vh - 120px);
    width: 100%;
}

/* КАТАЛОГ */
.catalog {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    border-radius: 40px;
    padding: 50px 60px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    border: 1px solid rgba(255, 255, 255, 0.2);
    width: 100%;
}

.catalog-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 60px;
    padding-bottom: 30px;
    border-bottom: 2px solid rgba(0, 0, 0, 0.05);
    width: 100%;
    flex-wrap: wrap;
    gap: 30px;
}

.catalog-title {
    font-size: 42px;
    font-weight: 800;
    color: #1a1a2e;
    letter-spacing: -0.5px;
    position: relative;
    padding-left: 24px;
    flex: 1;
    min-width: 250px;
}

.catalog-title::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 6px;
    height: 60%;
    background: linear-gradient(135deg, #667eea, #764ba2);
    border-radius: 4px;
}

.catalog-filters {
    display: flex;
    gap: 20px;
    flex: 2;
    min-width: 300px;
    flex-wrap: wrap;
}

.filter-select {
    min-width: 250px;
    padding: 14px 20px;
    background: white;
    border: 2px solid #e2e8f0;
    border-radius: 16px;
    font-size: 14px;
    font-weight: 500;
    color: #1a1a2e;
    cursor: pointer;
    transition: all 0.3s ease;
    width: 100%;
}

.filter-select:hover {
    border-color: #667eea;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(102, 126, 234, 0.15);
}

.filter-select:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.1);
}

/* СЕТКА ТОВАРОВ */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
    margin-bottom: 60px;
    width: 100%;
}

/* КАРТОЧКА ТОВАРА PREMIUM */
.product-card {
    background: white;
    border-radius: 24px;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    position: relative;
    animation: fadeInUp 0.6s ease-out forwards;
    opacity: 0;
    width: 100%;
    display: flex;
    flex-direction: column;
}

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

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

.product-image {
    height: 280px;
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    width: 100%;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

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

.category-badge {
    position: absolute;
    top: 16px;
    left: 16px;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(10px);
    color: white;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
}

.product-card:hover .category-badge {
    background: linear-gradient(135deg, #667eea, #764ba2);
}

.product-info {
    padding: 24px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    width: 100%;
}

.product-name {
    font-size: 20px;
    font-weight: 700;
    color: #1a1a2e;
    margin-bottom: 12px;
    line-height: 1.3;
    transition: color 0.3s ease;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 52px;
}

.product-card:hover .product-name {
    color: #667eea;
}

.product-description {
    color: #666;
    font-size: 14px;
    line-height: 1.5;
    margin-bottom: 20px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    flex-grow: 1;
}

.product-meta {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin-bottom: 20px;
    padding-top: 16px;
    border-top: 1px solid #eee;
    width: 100%;
    flex-wrap: wrap;
    gap: 12px;
}

.product-price {
    font-size: 28px;
    font-weight: 800;
    background: linear-gradient(135deg, #667eea, #764ba2);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.product-stock {
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}

.product-stock.in-stock {
    background: #e6f7e6;
    color: #28a745;
}

.product-stock.out-of-stock {
    background: #fee;
    color: #dc3545;
}

.product-actions {
    display: flex;
    gap: 12px;
    margin-top: auto;
    width: 100%;
}

.btn-add-to-cart {
    flex: 1;
    padding: 14px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    border: none;
    border-radius: 14px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.btn-add-to-cart::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.6s ease;
}

.btn-add-to-cart:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(102, 126, 234, 0.3);
}

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

.btn-view-details {
    flex: 1;
    padding: 14px;
    background: #f8f9fa;
    color: #667eea;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-view-details:hover {
    background: #667eea;
    color: white;
    border-color: #667eea;
    transform: translateY(-2px);
}

/* ПАГИНАЦИЯ */
.pagination-container {
    margin-top: 60px;
    padding-top: 30px;
    border-top: 2px solid rgba(0, 0, 0, 0.05);
    width: 100%;
}

.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    width: 100%;
    flex-wrap: wrap;
}

.pagination-btn {
    padding: 12px 28px;
    background: white;
    color: #1a1a2e;
    border: 2px solid #e2e8f0;
    border-radius: 40px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.pagination-btn:hover:not(:disabled) {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    border-color: transparent;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(102, 126, 234, 0.3);
}

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

.pagination-numbers {
    display: flex;
    gap: 8px;
    background: white;
    padding: 8px 16px;
    border-radius: 40px;
    border: 2px solid #e2e8f0;
}

.pagination-number {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    color: #1a1a2e;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
    font-size: 14px;
}

.pagination-number:hover {
    background: #f0f0f0;
}

.pagination-number.active {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
}

.page-info {
    text-align: center;
    margin-top: 30px;
    color: rgba(255, 255, 255, 0.7);
    font-size: 14px;
}

/* АДАПТИВНОСТЬ */
@media (max-width: 1200px) {
    .container {
        padding: 0 40px;
    }

    .catalog {
        padding: 40px;
    }

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

@media (max-width: 992px) {
    .container {
        padding: 0 30px;
    }

    .header-content {
        flex-direction: column;
        gap: 20px;
    }

    .search-form {
        max-width: 100%;
    }

    .nav {
        width: 100%;
        justify-content: center;
        flex-wrap: wrap;
    }

    .hero-title {
        font-size: 48px;
    }

    .catalog-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .catalog-filters {
        width: 100%;
    }

    .filter-select {
        min-width: 100%;
    }

    .products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }
}

@media (max-width: 768px) {
    .container {
        padding: 0 20px;
    }

    .hero-title {
        font-size: 36px;
    }

    .hero-subtitle {
        font-size: 16px;
    }

    .hero-stats {
        gap: 30px;
        flex-wrap: wrap;
    }

    .stat-number {
        font-size: 28px;
    }

    .catalog {
        padding: 30px;
        border-radius: 30px;
    }

    .catalog-title {
        font-size: 32px;
    }

    .products-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .product-image {
        height: 240px;
    }

    .product-actions {
        flex-direction: column;
    }

    .pagination {
        flex-direction: column;
    }

    .pagination-numbers {
        order: 1;
    }

    .pagination-btn {
        order: 2;
        width: 100%;
        max-width: 200px;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 16px;
    }

    .hero-title {
        font-size: 28px;
    }

    .catalog {
        padding: 20px;
        border-radius: 24px;
    }

    .catalog-title {
        font-size: 26px;
        padding-left: 16px;
    }

    .product-info {
        padding: 20px;
    }

    .product-name {
        font-size: 18px;
    }

    .product-price {
        font-size: 24px;
    }

    .pagination-number {
        width: 36px;
        height: 36px;
        font-size: 13px;
    }
}

/* АНИМАЦИИ */
@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

.loading {
    animation: pulse 1.5s ease-in-out infinite;
}

/* СКРОЛЛБАР */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.1);
    border-radius: 10px;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #667eea, #764ba2);
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, #5a67d8, #6b46c1);
}