/* ==========================================================================
   CHESSOV - Стили главной страницы
   ========================================================================== */

/* Hero-секция */
.hero {
    position: relative;
    padding: 80px 0 100px;
    overflow: hidden;
    background: linear-gradient(180deg, #ffffff 0%, #fef6f3 100%);
}

.hero::before {
    content: '';
    position: absolute;
    top: 10%;
    right: -10%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, var(--color-primary-soft), transparent 70%);
    border-radius: 50%;
    z-index: 0;
}

.hero::after {
    content: '';
    position: absolute;
    bottom: -20%;
    left: -10%;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, var(--color-secondary-soft), transparent 70%);
    border-radius: 50%;
    z-index: 0;
}

.hero-inner {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 1.1fr 1fr;
    gap: 64px;
    align-items: center;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 18px;
    background: white;
    border-radius: var(--radius-full);
    font-size: 14px;
    font-weight: 500;
    color: var(--color-text-soft);
    margin-bottom: 24px;
    box-shadow: var(--shadow-sm);
    animation: fadeIn 0.6s ease forwards;
}

.hero-badge-dot {
    width: 8px;
    height: 8px;
    background: var(--color-primary);
    border-radius: 50%;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(1.3); }
}

.hero h1 {
    margin-bottom: 20px;
    opacity: 0;
    animation: fadeIn 0.8s ease 0.1s forwards;
}

.hero h1 .accent {
    color: var(--color-primary);
    font-style: italic;
    font-weight: 500;
    position: relative;
    display: inline-block;
}

.hero h1 .accent::after {
    content: '';
    position: absolute;
    bottom: 4px;
    left: 0;
    width: 100%;
    height: 10px;
    background: var(--color-primary-soft);
    z-index: -1;
    border-radius: 6px;
}

.hero-subtitle {
    font-size: 18px;
    color: var(--color-text-soft);
    margin-bottom: 36px;
    max-width: 520px;
    line-height: 1.6;
    opacity: 0;
    animation: fadeIn 0.8s ease 0.2s forwards;
}

.hero-cta {
    display: flex;
    gap: 16px;
    margin-bottom: 48px;
    flex-wrap: wrap;
    opacity: 0;
    animation: fadeIn 0.8s ease 0.3s forwards;
}

.hero-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
    padding-top: 32px;
    border-top: 1px solid var(--color-border);
    opacity: 0;
    animation: fadeIn 0.8s ease 0.4s forwards;
}

.hero-stat-num {
    font-family: var(--font-display);
    font-size: 32px;
    font-weight: 700;
    color: var(--color-primary);
    line-height: 1;
    margin-bottom: 4px;
}

.hero-stat-label {
    font-size: 13px;
    color: var(--color-text-soft);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* Правая часть hero — коллаж фото */
.hero-visual {
    position: relative;
    height: 560px;
    opacity: 0;
    animation: fadeIn 1s ease 0.5s forwards;
}

.hero-card {
    position: absolute;
    background: white;
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-lg);
    transition: transform var(--transition-base);
}

.hero-card:hover {
    transform: translateY(-8px) rotate(0) !important;
}

.hero-card-1 {
    top: 0;
    left: 0;
    width: 240px;
    height: 320px;
    transform: rotate(-4deg);
    z-index: 2;
}

.hero-card-2 {
    top: 40px;
    right: 0;
    width: 260px;
    height: 340px;
    transform: rotate(3deg);
    z-index: 3;
}

.hero-card-3 {
    bottom: 0;
    left: 30%;
    width: 220px;
    height: 260px;
    transform: rotate(-2deg);
    z-index: 1;
}

.hero-card img {
    width: 100%;
    height: 70%;
    object-fit: cover;
}

.hero-card-info {
    padding: 14px 16px;
}

.hero-card-name {
    font-size: 14px;
    font-weight: 600;
    color: var(--color-text);
    margin-bottom: 4px;
}

.hero-card-role {
    font-size: 12px;
    color: var(--color-text-muted);
}

.hero-card-rating {
    display: flex;
    align-items: center;
    gap: 4px;
    margin-top: 6px;
    font-size: 12px;
    color: var(--color-text);
    font-weight: 600;
}

/* ==========================================================================
   Секции
   ========================================================================== */

section {
    padding: 80px 0;
}

.section-header {
    text-align: center;
    max-width: 680px;
    margin: 0 auto 56px;
}

.section-header h2 {
    margin-bottom: 16px;
}

.section-header p {
    font-size: 17px;
    color: var(--color-text-soft);
}

/* Категории */
.categories-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 20px;
}

.category-card {
    background: white;
    border: 1.5px solid var(--color-border);
    border-radius: var(--radius-lg);
    padding: 28px 20px;
    text-align: center;
    transition: all var(--transition-base);
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.category-card::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 100%;
    height: 100%;
    background: var(--cat-color, var(--color-primary-soft));
    border-radius: 50%;
    opacity: 0;
    transition: all var(--transition-base);
    z-index: 0;
}

.category-card:hover {
    transform: translateY(-6px);
    border-color: var(--cat-color, var(--color-primary));
    box-shadow: var(--shadow-hover);
}

.category-card:hover::before {
    opacity: 0.15;
    transform: scale(1.5);
}

.category-card > * {
    position: relative;
    z-index: 1;
}

.category-icon {
    font-size: 40px;
    margin-bottom: 16px;
    display: inline-block;
    transition: transform var(--transition-base);
}

.category-card:hover .category-icon {
    transform: scale(1.15) rotate(-5deg);
}

.category-name {
    font-size: 15px;
    font-weight: 600;
    color: var(--color-text);
}

/* Топ специалистов */
.top-specialists {
    background: linear-gradient(180deg, #fff 0%, var(--color-bg-soft) 100%);
}

.specialists-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}

.specialist-card {
    background: white;
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: all var(--transition-base);
    border: 1px solid var(--color-border);
    display: flex;
    flex-direction: column;
}

.specialist-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-hover);
    border-color: var(--color-primary);
}

.specialist-img {
    position: relative;
    width: 100%;
    height: 240px;
    overflow: hidden;
    background: var(--color-bg-soft);
}

.specialist-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-slow);
}

.specialist-card:hover .specialist-img img {
    transform: scale(1.06);
}

.specialist-badges {
    position: absolute;
    top: 12px;
    left: 12px;
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}

.specialist-info {
    padding: 20px;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.specialist-name {
    font-family: var(--font-display);
    font-size: 19px;
    font-weight: 600;
    color: var(--color-text);
    margin-bottom: 6px;
}

.specialist-profession {
    font-size: 14px;
    color: var(--color-text-soft);
    margin-bottom: 14px;
}

.specialist-meta {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 16px;
    font-size: 14px;
}

.specialist-rating {
    display: flex;
    align-items: center;
    gap: 4px;
    color: var(--color-text);
    font-weight: 600;
}

.specialist-rating::before {
    content: '★';
    color: var(--color-accent-gold);
}

.specialist-reviews {
    color: var(--color-text-muted);
    font-size: 13px;
}

.specialist-price {
    margin-top: auto;
    padding-top: 16px;
    border-top: 1px solid var(--color-border-soft);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.specialist-price-label {
    font-size: 12px;
    color: var(--color-text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.specialist-price-value {
    font-family: var(--font-display);
    font-size: 20px;
    font-weight: 600;
    color: var(--color-primary);
}

/* Как это работает */
.how-it-works {
    position: relative;
}

.how-steps {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    position: relative;
}

.how-step {
    background: white;
    border-radius: var(--radius-lg);
    padding: 36px 28px;
    text-align: center;
    border: 1px solid var(--color-border);
    position: relative;
    transition: all var(--transition-base);
}

.how-step:hover {
    border-color: var(--color-primary);
    box-shadow: var(--shadow-md);
}

.how-step-num {
    width: 56px;
    height: 56px;
    background: linear-gradient(135deg, var(--color-primary), var(--color-accent-coral));
    color: white;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-display);
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 24px;
    box-shadow: 0 8px 20px rgba(255, 107, 157, 0.3);
}

.how-step h3 {
    margin-bottom: 12px;
    font-size: 22px;
}

.how-step p {
    color: var(--color-text-soft);
    font-size: 15px;
    line-height: 1.6;
}

/* Бизнес-блок CTA */
.business-cta {
    padding: 100px 0;
}

.business-cta-inner {
    background: linear-gradient(135deg, var(--color-primary-soft), var(--color-tertiary-soft));
    border-radius: var(--radius-xl);
    padding: 64px 48px;
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 48px;
    align-items: center;
    position: relative;
    overflow: hidden;
}

.business-cta-inner::before {
    content: '';
    position: absolute;
    top: -50px;
    right: -50px;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, white, transparent 70%);
    border-radius: 50%;
    opacity: 0.6;
}

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

.business-cta-content h2 {
    margin-bottom: 20px;
}

.business-cta-content p {
    font-size: 17px;
    color: var(--color-text-soft);
    margin-bottom: 32px;
    line-height: 1.6;
}

.business-cta-features {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 12px;
    position: relative;
    z-index: 1;
}

.business-cta-features li {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 16px;
    color: var(--color-text);
}

.business-cta-features li::before {
    content: '✓';
    width: 28px;
    height: 28px;
    background: var(--color-primary);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    flex-shrink: 0;
}

/* Адаптив для главной */
@media (max-width: 1024px) {
    .hero-inner {
        grid-template-columns: 1fr;
    }

    .hero-visual {
        height: 400px;
    }

    .categories-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .specialists-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .how-steps {
        grid-template-columns: 1fr;
    }

    .business-cta-inner {
        grid-template-columns: 1fr;
        padding: 48px 32px;
    }
}

@media (max-width: 640px) {
    .hero {
        padding: 48px 0 64px;
    }

    .hero-stats {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }

    .hero-visual {
        height: 340px;
    }

    .hero-card-1 { width: 160px; height: 220px; }
    .hero-card-2 { width: 180px; height: 240px; }
    .hero-card-3 { width: 160px; height: 180px; left: 20%; }

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

    .specialists-grid {
        grid-template-columns: 1fr;
    }

    section {
        padding: 56px 0;
    }

    .section-header {
        margin-bottom: 40px;
    }
}
