/**
 * Service Page Styles
 * Стили для страницы сервиса с сайдбаром
 */

/* === LAYOUT С САЙДБАРОМ === */
.service-layout {
    display: grid;
    grid-template-columns: 1fr 350px;
    gap: 40px;
    margin-top: 30px;
}

.service-main {
    min-width: 0;
}

/* === САЙДБАР === */
.service-sidebar {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.sidebar-widget {
    background: #fff;
    border-radius: 20px;
    padding: 25px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.05);
}

.sidebar-widget h3 {
    font-size: 18px;
    font-weight: 700;
    color: #2D3748;
    margin-bottom: 15px;
    padding-bottom: 12px;
    border-bottom: 2px solid #4ECDC4;
}

.sidebar-content {
    font-size: 14px;
    line-height: 1.7;
    color: #4A5568;
}

.sidebar-content p {
    margin-bottom: 12px;
}

.sidebar-content p:last-child {
    margin-bottom: 0;
}

.sidebar-content a {
    color: #4ECDC4;
    text-decoration: underline;
}

.sidebar-content a:hover {
    color: #38B2AC;
}

.sidebar-content ul,
.sidebar-content ol {
    margin: 12px 0;
    padding-left: 20px;
}

.sidebar-content li {
    margin-bottom: 8px;
}

/* Виджет "Как использовать" */
.howto-list {
    list-style: none;
    padding: 0;
    margin: 0;
    counter-reset: howto-counter;
}

.howto-list li {
    position: relative;
    padding-left: 35px;
    margin-bottom: 15px;
    font-size: 14px;
    color: #4A5568;
    line-height: 1.5;
    counter-increment: howto-counter;
}

.howto-list li:last-child {
    margin-bottom: 0;
}

.howto-list li::before {
    content: counter(howto-counter);
    position: absolute;
    left: 0;
    top: 0;
    width: 24px;
    height: 24px;
    background: linear-gradient(135deg, #4ECDC4 0%, #44A8B3 100%);
    border-radius: 50%;
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Ссылка на сайт */
.sidebar-site-link {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 15px 20px;
    background: linear-gradient(135deg, #4ECDC4 0%, #44A8B3 100%);
    color: #fff !important;
    border-radius: 12px;
    font-weight: 600;
    font-size: 14px;
    text-decoration: none !important;
    transition: all 0.3s;
}

.sidebar-site-link:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(78, 205, 196, 0.4);
    color: #fff !important;
}

/* === SEO-ТЕКСТ ВНИЗУ === */
.service-bottom-text {
    margin-top: 50px;
    background: #fff;
    border-radius: 20px;
    padding: 35px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.05);
}

.seo-content {
    font-size: 15px;
    line-height: 1.8;
    color: #4A5568;
}

.seo-content h2 {
    font-size: 24px;
    font-weight: 700;
    color: #2D3748;
    margin: 25px 0 15px 0;
}

.seo-content h2:first-child {
    margin-top: 0;
}

.seo-content h3 {
    font-size: 20px;
    font-weight: 700;
    color: #2D3748;
    margin: 20px 0 12px 0;
}

.seo-content h4 {
    font-size: 18px;
    font-weight: 600;
    color: #2D3748;
    margin: 18px 0 10px 0;
}

.seo-content p {
    margin-bottom: 15px;
}

.seo-content a {
    color: #4ECDC4;
    text-decoration: underline;
}

.seo-content a:hover {
    color: #38B2AC;
}

.seo-content ul,
.seo-content ol {
    margin: 15px 0;
    padding-left: 25px;
}

.seo-content li {
    margin-bottom: 10px;
}

.seo-content blockquote {
    margin: 20px 0;
    padding: 20px 25px;
    background: #F0FFFE;
    border-left: 4px solid #4ECDC4;
    border-radius: 0 12px 12px 0;
    font-style: italic;
    color: #2D3748;
}

.seo-content img {
    max-width: 100%;
    height: auto;
    border-radius: 12px;
    margin: 15px 0;
}

.seo-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 20px 0;
}

.seo-content th,
.seo-content td {
    padding: 12px 15px;
    border: 1px solid #E2E8F0;
    text-align: left;
}

.seo-content th {
    background: #F7FAFC;
    font-weight: 600;
    color: #2D3748;
}

/* === МОБИЛЬНЫЙ САЙДБАР === */
.service-sidebar-mobile {
    display: none;
    margin-top: 30px;
}

/* === АДАПТИВНОСТЬ === */
@media (max-width: 1024px) {
    .service-layout {
        grid-template-columns: 1fr 280px;
        gap: 30px;
    }
}

@media (max-width: 868px) {
    .service-layout {
        grid-template-columns: 1fr;
    }
    
    /* Скрываем десктопный сайдбар */
    .service-sidebar {
        display: none;
    }
    
    /* Показываем мобильный сайдбар внизу */
    .service-sidebar-mobile {
        display: block;
    }
    
    .service-bottom-text {
        margin-top: 30px;
        padding: 25px;
    }
    
    .seo-content {
        font-size: 14px;
    }
    
    .seo-content h2 {
        font-size: 20px;
    }
    
    .seo-content h3 {
        font-size: 18px;
    }
}

@media (max-width: 480px) {
    .service-bottom-text {
        padding: 20px;
        border-radius: 16px;
    }
    
    .sidebar-widget {
        padding: 20px;
        border-radius: 16px;
    }
}
