/*
Theme Name: Mulcha Blog
Theme URI: https://blog.mulcha.info/
Description: Дочерняя тема для блога Mulcha с дизайном основного сайта mulcha.info
Author: Mulcha
Author URI: https://mulcha.info/
Template: twentytwentyfive
Version: 1.0.1
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: mulcha-blog
*/

/* ==================================================
   АГРЕССИВНЫЙ СБРОС СТИЛЕЙ WORDPRESS
   ================================================== */

/* Сброс всех стилей body от родительской темы */
body,
body.wp-singular,
body.blog,
body.archive,
body.home,
body.single-post,
body.page,
body.search,
body.category,
body.tag,
body.author,
body.date,
body.paged,
body.attachment,
body.error404 {
    font-family: 'Lato', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen-Sans, Ubuntu, Cantarell, 'Helvetica Neue', sans-serif !important;
    font-size: 14px !important;
    line-height: 1.6 !important;
    color: #555 !important;
    background: #fff !important;
    margin: 0 !important;
    padding: 0 !important;
    letter-spacing: normal !important;
    font-weight: 400 !important;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Убираем все padding от WordPress */
.wp-site-blocks,
.is-layout-constrained > .alignfull,
.is-layout-constrained > .alignwide,
.has-global-padding,
.entry-content,
.wp-block-post-content {
    padding-top: 0 !important;
    padding-bottom: 0 !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
    margin-top: 0 !important;
    margin-bottom: 0 !important;
}

/* Сброс стилей заголовков от родительской темы */
h1, h2, h3, h4, h5, h6,
.wp-block-heading h1,
.wp-block-heading h2,
.wp-block-heading h3,
.wp-block-heading h4,
.wp-block-heading h5,
.wp-block-heading h6 {
    font-family: 'Lato', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen-Sans, Ubuntu, Cantarell, 'Helvetica Neue', sans-serif !important;
    font-weight: 700 !important;
    letter-spacing: normal !important;
    line-height: 1.3 !important;
    color: #555 !important;
    text-transform: none !important;
}

/* Сброс стилей ссылок */
a {
    color: #9abc31;
    text-decoration: none;
}

a:hover {
    color: #7a9a20;
    text-decoration: underline;
}

/* Сброс стилей параграфов */
p {
    margin-bottom: 15px;
    line-height: 1.6;
}

/* ==================================================
   КОНТЕНТ СТАТЕЙ
   ================================================== */

.blog-content-wrapper {
    max-width: 1200px;
    margin: 0 auto;
    padding: 60px 20px;
}

.blog-content-wrapper .post-media {
    margin-bottom: 30px;
}

.blog-content-wrapper .entry-title {
    font-size: 36px;
    color: #555;
    font-weight: 700;
    margin-bottom: 20px;
    line-height: 1.3;
}

.blog-content-wrapper .entry-meta {
    font-size: 13px;
    color: #999;
    margin-bottom: 30px;
    padding-bottom: 15px;
    border-bottom: 1px solid #e6e6e6;
}

.blog-content-wrapper .entry-meta a {
    color: #9abc31;
    text-decoration: none;
}

.blog-content-wrapper .entry-meta a:hover {
    text-decoration: underline;
}

.blog-content-wrapper .entry-content {
    font-size: 16px;
    line-height: 1.8;
}

.blog-content-wrapper .entry-content h1,
.blog-content-wrapper .entry-content h2,
.blog-content-wrapper .entry-content h3,
.blog-content-wrapper .entry-content h4,
.blog-content-wrapper .entry-content h5,
.blog-content-wrapper .entry-content h6 {
    color: #555;
    font-weight: 700;
    margin-top: 30px;
    margin-bottom: 15px;
}

.blog-content-wrapper .entry-content h1 { font-size: 32px; }
.blog-content-wrapper .entry-content h2 { font-size: 28px; }
.blog-content-wrapper .entry-content h3 { font-size: 24px; }
.blog-content-wrapper .entry-content h4 { font-size: 20px; }
.blog-content-wrapper .entry-content h5 { font-size: 16px; text-transform: uppercase; }
.blog-content-wrapper .entry-content h6 { font-size: 14px; }

.blog-content-wrapper .entry-content p {
    margin-bottom: 20px;
}

.blog-content-wrapper .entry-content a {
    color: #9abc31;
    text-decoration: none;
}

.blog-content-wrapper .entry-content a:hover {
    text-decoration: underline;
}

.blog-content-wrapper .entry-content img {
    max-width: 100%;
    height: auto;
    border-radius: 5px;
    margin: 20px 0;
}

.blog-content-wrapper .entry-content ul,
.blog-content-wrapper .entry-content ol {
    margin: 0 0 20px 20px;
}

.blog-content-wrapper .entry-content ul {
    list-style-type: disc;
}

.blog-content-wrapper .entry-content ol {
    list-style-type: decimal;
}

.blog-content-wrapper .entry-content li {
    margin-bottom: 8px;
}

.blog-content-wrapper .entry-content blockquote {
    border-left: 4px solid #9abc31;
    padding-left: 20px;
    margin: 30px 0;
    font-style: italic;
    color: #666;
}

.blog-content-wrapper .entry-content table {
    width: 100%;
    margin: 20px 0;
    border-collapse: collapse;
}

.blog-content-wrapper .entry-content table th,
.blog-content-wrapper .entry-content table td {
    border: 1px solid #e6e6e6;
    padding: 10px;
    text-align: left;
}

.blog-content-wrapper .entry-content table th {
    background: #f5f5f5;
    font-weight: 700;
}

/* ==================================================
   СПИСОК СТАТЕЙ (БЛОГ)
   ================================================== */

.blog-list-wrapper {
    max-width: 1200px;
    margin: 0 auto;
    padding: 60px 20px;
}

.blog-list-wrapper .page-title {
    font-size: 30px;
    color: #555;
    margin-bottom: 40px;
    font-weight: 700;
}

.articles-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
}

@media (max-width: 768px) {
    .articles-grid {
        grid-template-columns: 1fr;
    }
}

.article-card {
    background: #fff;
    border-radius: 5px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    border: 1px solid #e6e6e6;
    border-bottom: 2px solid #e6e6e6;
    margin-bottom: 40px;
    transition: box-shadow 0.3s ease;
}

.article-card:hover {
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
}

.article-card .card-image {
    position: relative;
    overflow: hidden;
}

.article-card .card-image img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    display: block;
}

.article-card .card-date {
    position: absolute;
    top: 0;
    left: 10px;
    background: #9abc31;
    color: #fff;
    padding: 15px 10px 10px;
    text-align: center;
    border-bottom: 2px solid #fff;
}

.article-card .card-date .day {
    display: block;
    font-size: 18px;
    font-weight: 700;
}

.article-card .card-date .month {
    display: block;
    font-size: 11px;
    text-transform: uppercase;
}

.article-card .card-content {
    padding: 25px;
}

.article-card .card-title {
    font-size: 20px;
    margin-bottom: 15px;
}

.article-card .card-title a {
    color: #555;
    text-decoration: none;
}

.article-card .card-title a:hover {
    color: #9abc31;
}

.article-card .card-excerpt {
    color: #666;
    font-size: 14px;
    line-height: 1.7;
    margin-bottom: 20px;
}

.article-card .card-meta {
    font-size: 12px;
    color: #999;
    text-transform: uppercase;
}

.article-card .card-meta a {
    color: #9abc31;
}

.read-more-link {
    color: #9abc31;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 13px;
    letter-spacing: 1px;
}

.read-more-link:hover {
    color: #7a9a20;
}

/* ==================================================
   SIDEBAR
   ================================================== */

.blog-sidebar {
    padding-left: 30px;
}

.blog-sidebar .widget {
    margin-bottom: 40px;
    padding-bottom: 30px;
    border-bottom: 1px solid #e6e6e6;
}

.blog-sidebar .widget:last-child {
    border-bottom: none;
}

.blog-sidebar .widget-title {
    font-size: 16px;
    text-transform: uppercase;
    color: #555;
    margin-bottom: 20px;
    font-weight: 700;
    letter-spacing: 1px;
}

.blog-sidebar .widget ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.blog-sidebar .widget ul li {
    padding: 10px 0;
    border-bottom: 1px solid #f0f0f0;
}

.blog-sidebar .widget ul li:last-child {
    border-bottom: none;
}

.blog-sidebar .widget ul li a {
    color: #555;
    text-decoration: none;
}

.blog-sidebar .widget ul li a:hover {
    color: #9abc31;
}

/* Поиск */
.blog-sidebar .search-form {
    position: relative;
}

.blog-sidebar .search-field {
    width: 100%;
    padding: 10px 15px;
    border: 1px solid #e6e6e6;
    border-radius: 3px;
    font-size: 14px;
}

.blog-sidebar .search-submit {
    margin-top: 10px;
    background: #9abc31;
    border: none;
    color: #fff;
    padding: 10px 20px;
    border-radius: 3px;
    cursor: pointer;
}

/* ==================================================
   ПАГИНАЦИЯ
   ================================================== */

.blog-pagination {
    text-align: center;
    margin-top: 40px;
    padding-top: 40px;
    border-top: 1px solid #e6e6e6;
}

.blog-pagination .nav-links {
    display: inline-block;
}

.blog-pagination .page-numbers {
    display: inline-block;
    width: 40px;
    height: 40px;
    line-height: 38px;
    text-align: center;
    border: 1px solid #e6e6e6;
    margin: 0 5px;
    border-radius: 3px;
    color: #555;
    text-decoration: none;
    transition: all 0.3s ease;
}

.blog-pagination .page-numbers:hover,
.blog-pagination .page-numbers.current {
    background: #9abc31;
    border-color: #9abc31;
    color: #fff;
}

/* ==================================================
   КОММЕНТАРИИ
   ================================================== */

.post-comments {
    margin-top: 40px;
    padding-top: 30px;
    border-top: 1px solid #e6e6e6;
}

.post-comments h3 {
    font-size: 20px;
    margin-bottom: 20px;
}

.post-comments .comment-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.post-comments .comment {
    padding: 20px 0;
    border-bottom: 1px solid #f0f0f0;
}

.post-comments .comment-author {
    font-weight: 700;
}

.post-comments .comment-meta {
    font-size: 12px;
    color: #999;
    margin-bottom: 10px;
}

/* Форма комментариев */
.comment-respond {
    margin-top: 30px;
}

.comment-reply-title {
    font-size: 20px;
    margin-bottom: 20px;
}

.comment-form label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
}

.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea {
    width: 100%;
    padding: 10px 15px;
    border: 1px solid #e6e6e6;
    border-radius: 3px;
    margin-bottom: 15px;
    font-size: 14px;
}

.comment-form textarea {
    min-height: 120px;
}

.comment-form .submit,
.comment-form .wp-block-button__link {
    background: #9abc31 !important;
    border: none !important;
    color: #fff !important;
    padding: 12px 30px !important;
    border-radius: 3px !important;
    cursor: pointer;
    font-weight: 600;
    text-transform: uppercase;
}

.comment-form .submit:hover,
.comment-form .wp-block-button__link:hover {
    background: #7a9a20 !important;
}

/* ==================================================
   НАВИГАЦИЯ ПО СТАТЬЯМ
   ================================================== */

.post-navigation {
    margin-top: 40px;
    padding-top: 20px;
    border-top: 1px solid #eee;
}

.post-navigation .prev-post,
.post-navigation .next-post {
    margin-bottom: 10px;
}

.post-navigation small {
    color: #999;
    font-size: 12px;
    text-transform: uppercase;
}

.post-navigation h5 {
    font-size: 16px;
    margin: 5px 0 0 0;
}

.post-navigation h5 a {
    color: #555;
}

.post-navigation h5 a:hover {
    color: #9abc31;
}

/* ==================================================
   АДАПТИВНОСТЬ
   ================================================== */

@media (max-width: 992px) {
    .blog-sidebar {
        padding-left: 0;
        margin-top: 40px;
    }
}

@media (max-width: 768px) {
    .blog-content-wrapper .entry-title {
        font-size: 28px;
    }
    
    .blog-content-wrapper {
        padding: 40px 15px;
    }
    
    .blog-list-wrapper {
        padding: 40px 15px;
    }
}

/* ==================================================
   ИСПРАВЛЕНИЕ Z-INDEX ДЛЯ МОБИЛЬНОГО МЕНЮ
   ================================================== */

/* Увеличиваем z-index для шапки и навигации */
.header-wrapper {
    position: relative;
    z-index: 9999 !important;
}

.site-header {
    position: relative;
    z-index: 9999 !important;
}

.main-navigation {
    position: relative;
    z-index: 9998 !important;
}

/* Мобильное меню */
#menu-toggle {
    z-index: 10000 !important;
    position: relative;
}

.main-navigation nav {
    z-index: 9997 !important;
    position: relative;
}

/* Выпадающее меню на мобильных */
.dd-menu {
    z-index: 9996 !important;
}

.dd-menu li ul {
    z-index: 9995 !important;
}

/* Кнопка контактов в шапке */
#contact-info {
    z-index: 10001 !important;
    position: relative;
}

/* Кнопка заявки в шапке */
.quote-head-btn {
    z-index: 10000 !important;
    position: relative;
}

/* Социальные иконки в шапке */
.social-icons {
    z-index: 10000 !important;
    position: relative;
}

/* Исправление для body - убираем возможные конфликты */
.body {
    position: relative;
    z-index: 1;
}

/* Убираем лишние отступы WordPress которые могут мешать кликам */
.wp-site-blocks,
.is-layout-constrained {
    position: relative;
    z-index: auto !important;
    overflow: visible !important;
}

    /* Гарантируем что шапка выше контента */
    #main-container {
        position: relative;
        z-index: 1 !important;
    }

    /* ==================================================
       МОБИЛЬНОЕ МЕНЮ
       ================================================== */

    /* Стили для кнопки меню на мобильных */
    #menu-toggle {
        display: none;
        cursor: pointer;
        padding: 10px 15px;
        background: #9abc31;
        color: #fff !important;
        border-radius: 3px;
        font-size: 12px;
        font-weight: 700;
        text-transform: uppercase;
        letter-spacing: 1px;
    }

    #menu-toggle.active {
        background: #7a9a20;
    }

    /* Показываем кнопку меню только на мобильных */
    @media (max-width: 991px) {
        #menu-toggle {
            display: inline-block;
        }
        
        .main-navigation nav {
            display: none;
        }
        
        .main-navigation nav.mobile-menu-open {
            display: block !important;
        }
        
        .dd-menu {
            display: none;
            position: absolute;
            top: 100%;
            left: 0;
            right: 0;
            background: #333;
            padding: 15px 0;
            margin: 0;
            list-style: none;
            box-shadow: 0 5px 15px rgba(0,0,0,0.2);
        }
        
        .dd-menu li {
            float: none !important;
            display: block;
        }
        
        .dd-menu li a {
            display: block;
            padding: 12px 20px;
            color: #fff !important;
            border-bottom: 1px solid rgba(255,255,255,0.1);
        }
        
        .dd-menu li a:hover {
            background: rgba(154, 188, 49, 0.2);
        }
        
        .dd-menu li ul {
            position: static !important;
            display: none;
            background: rgba(0,0,0,0.2);
            padding: 0;
            margin: 0;
        }
        
        .dd-menu li:hover > ul {
            display: block;
        }
        
        .dd-menu li ul li a {
            padding-left: 40px;
        }
        
        .dd-menu li ul li ul li a {
            padding-left: 60px;
        }
    }

    /* Стили для контактной информации на мобильных */
    @media (max-width: 991px) {
        .site-header-right {
            display: none;
            position: absolute;
            top: 100%;
            left: 0;
            right: 0;
            background: #fff;
            padding: 20px;
            box-shadow: 0 5px 15px rgba(0,0,0,0.1);
            z-index: 9999;
        }
        
        #contact-info {
            display: inline-block;
        }
        
        .header-info-cols {
            display: block;
        }
        
        .header-info-cols li {
            float: none !important;
            display: block;
            margin-bottom: 15px;
            text-align: left;
        }
        
        .header-info-cols li:last-child {
            margin-bottom: 0;
        }
    }

/* ==================================================
   ИСПРАВЛЕНИЕ ЦВЕТА ТЕКСТА В ПОДВАЛЕ
   ================================================== */

/* Основной подвал - серый текст */
.site-footer {
    color: #999 !important;
}

.site-footer p,
.site-footer span,
.site-footer li {
    color: #999 !important;
}

/* Заголовки виджетов в подвале - белые */
.site-footer h4,
.site-footer .widgettitle {
    color: #fff !important;
}

.site-footer h4 i,
.site-footer .widgettitle i {
    color: #9abc31 !important;
}

/* Ссылки в подвале */
.site-footer a {
    color: #999 !important;
}

.site-footer a:hover {
    color: #9abc31 !important;
}

/* Нижний подвал */
.site-footer-bottom {
    color: #999 !important;
}

.site-footer-bottom p {
    color: #999 !important;
}

/* Форма в подвале */
.site-footer input,
.site-footer select,
.site-footer textarea {
    color: #555 !important;
}

.site-footer input::placeholder {
    color: #999 !important;
}
/* ==================================================
   ИСПРАВЛЕНИЕ Z-INDEX ДЛЯ МОБИЛЬНОГО МЕНЮ
   ================================================== */

/* Увеличиваем z-index для шапки и навигации */
.header-wrapper {
    position: relative;
    z-index: 9999 !important;
}

.site-header {
    position: relative;
    z-index: 9999 !important;
}

.main-navigation {
    position: relative;
    z-index: 9998 !important;
}

/* Мобильное меню */
#menu-toggle {
    z-index: 10000 !important;
    position: relative;
}

.main-navigation nav {
    z-index: 9997 !important;
    position: relative;
}

/* Выпадающее меню на мобильных */
.dd-menu {
    z-index: 9996 !important;
}

.dd-menu li ul {
    z-index: 9995 !important;
}

/* Кнопка контактов в шапке */
#contact-info {
    z-index: 10001 !important;
    position: relative;
}

/* Кнопка заявки в шапке */
.quote-head-btn {
    z-index: 10000 !important;
    position: relative;
}

/* Социальные иконки в шапке */
.social-icons {
    z-index: 10000 !important;
    position: relative;
}

/* Исправление для body - убираем возможные конфликты */
.body {
    position: relative;
    z-index: 1;
}

/* Убираем лишние отступы WordPress которые могут мешать кликам */
.wp-site-blocks,
.is-layout-constrained {
    position: relative;
    z-index: auto !important;
    overflow: visible !important;
}

/* Гарантируем что шапка выше контента */
#main-container {
    position: relative;
    z-index: 1 !important;
}
