/* Стили для блога и экспертных статей ТехноРемБыт */
:root {
    --brand-green: #00a700;
    --brand-green-hover: #008f00;
    --brand-green-light: #eaf8ea;
    --brand-dark: #0f172a;
    --text-primary: #1e293b;
    --text-secondary: #475569;
    --text-muted: #64748b;
    --border-color: #e2e8f0;
    --bg-light: #f8fafc;
    --bg-card: #ffffff;
    --font-main: 'Gilroy', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

html, body {
    overflow-x: hidden;
    max-width: 100%;
    width: 100%;
}

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

body {
    font-family: var(--font-main);
    color: var(--text-primary);
    background-color: #f1f5f9;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

a {
    color: var(--brand-green);
    text-decoration: none;
    transition: color 0.2s;
}

a:hover {
    color: var(--brand-green-hover);
}

/* Header */
.blog-header {
    background: #ffffff;
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0,0,0,0.03);
}

.blog-header__container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 14px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
}

.blog-header__logo img {
    height: 38px;
    width: auto;
    display: block;
}

.blog-header__nav {
    display: flex;
    align-items: center;
    gap: 24px;
}

.blog-header__nav a {
    color: var(--text-secondary);
    font-weight: 600;
    font-size: 15px;
}

.blog-header__nav a:hover,
.blog-header__nav a.active {
    color: var(--brand-green);
}

.blog-header__contacts {
    display: flex;
    align-items: center;
    gap: 16px;
}

.blog-header__phone {
    font-size: 17px;
    font-weight: 700;
    color: var(--brand-dark);
}

.blog-header__btn {
    background: var(--brand-green);
    color: #ffffff !important;
    padding: 8px 18px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 14px;
    display: inline-block;
    transition: background 0.2s, transform 0.1s;
}

.blog-header__btn:hover {
    background: var(--brand-green-hover);
    transform: translateY(-1px);
}

/* Breadcrumbs */
.blog-breadcrumbs {
    max-width: 1200px;
    margin: 20px auto 0;
    padding: 0 20px;
    font-size: 13px;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.blog-breadcrumbs a {
    color: var(--text-muted);
}

.blog-breadcrumbs a:hover {
    color: var(--brand-green);
}

.blog-breadcrumbs__sep {
    color: #cbd5e1;
}

/* Main Container */
.blog-container {
    max-width: 1200px;
    margin: 24px auto 60px;
    padding: 0 20px;
}

.blog-article-container {
    max-width: 860px;
    margin: 24px auto 60px;
    padding: 0 20px;
}

/* Blog Index */
.blog-hero {
    background: #ffffff;
    border-radius: 16px;
    padding: 40px 32px;
    margin-bottom: 32px;
    border: 1px solid var(--border-color);
    box-shadow: 0 4px 20px rgba(0,0,0,0.02);
    text-align: center;
}

.blog-hero h1 {
    font-size: 32px;
    font-weight: 800;
    color: var(--brand-dark);
    margin-bottom: 12px;
}

.blog-hero p {
    font-size: 16px;
    color: var(--text-secondary);
    max-width: 720px;
    margin: 0 auto;
}

.blog-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 30px;
    justify-content: center;
}

.blog-filter-btn {
    background: #ffffff;
    border: 1px solid var(--border-color);
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
}

.blog-filter-btn:hover,
.blog-filter-btn.active {
    background: var(--brand-green);
    border-color: var(--brand-green);
    color: #ffffff;
}

/* Blog Cards Grid */
.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 24px;
    margin-bottom: 48px;
}

.blog-card {
    background: #ffffff;
    border-radius: 16px;
    border: 1px solid var(--border-color);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: 0 4px 15px rgba(0,0,0,0.03);
    transition: transform 0.25s, box-shadow 0.25s, border-color 0.25s;
}

.blog-card:hover {
    transform: translateY(-4px);
    border-color: #86efac;
    box-shadow: 0 12px 28px rgba(0, 167, 0, 0.08);
}

.blog-card__body {
    padding: 24px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.blog-card__badge {
    align-self: flex-start;
    background: var(--brand-green-light);
    color: #166534;
    font-size: 12px;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 6px;
    margin-bottom: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.blog-card__title {
    font-size: 19px;
    font-weight: 700;
    color: var(--brand-dark);
    margin-bottom: 10px;
    line-height: 1.35;
}

.blog-card__title a {
    color: inherit;
}

.blog-card__title a:hover {
    color: var(--brand-green);
}

.blog-card__excerpt {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.55;
    margin-bottom: 18px;
    flex-grow: 1;
}

.blog-card__footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid #f1f5f9;
    padding-top: 14px;
    font-size: 13px;
    color: var(--text-muted);
}

.blog-card__link {
    font-weight: 700;
    color: var(--brand-green);
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

/* Article Page */
.article-box {
    background: #ffffff;
    border-radius: 16px;
    padding: 40px;
    border: 1px solid var(--border-color);
    box-shadow: 0 4px 20px rgba(0,0,0,0.03);
    margin-bottom: 36px;
}

.article-header {
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 24px;
    margin-bottom: 28px;
}

.article-tag {
    display: inline-block;
    background: var(--brand-green-light);
    color: #166534;
    font-size: 12px;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 6px;
    margin-bottom: 14px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.article-title {
    font-size: 32px;
    font-weight: 800;
    color: var(--brand-dark);
    line-height: 1.3;
    margin-bottom: 16px;
}

.article-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 16px;
    font-size: 14px;
    color: var(--text-muted);
}

.article-meta__author {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
    color: var(--text-primary);
}

.article-lead {
    font-size: 17px;
    line-height: 1.65;
    color: #334155;
    background: #f8fafc;
    border-left: 4px solid var(--brand-green);
    padding: 16px 20px;
    border-radius: 0 8px 8px 0;
    margin-bottom: 28px;
}

.article-content {
    font-size: 16px;
    line-height: 1.7;
    color: #334155;
}

.article-content h2 {
    font-size: 24px;
    font-weight: 700;
    color: var(--brand-dark);
    margin: 36px 0 16px;
    padding-bottom: 8px;
    border-bottom: 2px solid #f1f5f9;
}

.article-content h3 {
    font-size: 19px;
    font-weight: 700;
    color: var(--brand-dark);
    margin: 24px 0 12px;
}

.article-content p {
    margin-bottom: 16px;
}

.article-content ul,
.article-content ol {
    margin: 0 0 20px 24px;
}

.article-content li {
    margin-bottom: 8px;
}

/* Callout Box */
.article-callout {
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    border-left: 5px solid var(--brand-green);
    border-radius: 8px;
    padding: 18px 22px;
    margin: 24px 0;
}

.article-callout--warn {
    background: #fffbeb;
    border: 1px solid #fde68a;
    border-left: 5px solid #d97706;
}

.article-callout__title {
    font-weight: 700;
    font-size: 16px;
    color: var(--brand-dark);
    margin-bottom: 6px;
}

/* Diagnostic Table */
.article-table-wrap {
    overflow-x: auto;
    margin: 24px 0;
    border-radius: 10px;
    border: 1px solid var(--border-color);
}

.article-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
    text-align: left;
    background: #ffffff;
}

.article-table th {
    background: #f8fafc;
    color: var(--brand-dark);
    font-weight: 700;
    padding: 12px 16px;
    border-bottom: 2px solid var(--border-color);
}

.article-table td {
    padding: 12px 16px;
    border-bottom: 1px solid var(--border-color);
    vertical-align: top;
}

.article-table tr:last-child td {
    border-bottom: none;
}

.article-table tr:hover td {
    background: #f8fafc;
}

/* Master CTA block */
.article-cta {
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
    border-radius: 16px;
    padding: 36px 32px;
    color: #ffffff;
    margin: 36px 0;
    position: relative;
    overflow: hidden;
}

.article-cta::after {
    content: '';
    position: absolute;
    right: -40px;
    bottom: -40px;
    width: 200px;
    height: 200px;
    background: radial-gradient(circle, rgba(0, 167, 0, 0.25) 0%, transparent 70%);
    pointer-events: none;
}

.article-cta h3 {
    font-size: 24px;
    font-weight: 800;
    margin-bottom: 10px;
    color: #ffffff;
}

.article-cta p {
    font-size: 15px;
    color: #cbd5e1;
    margin-bottom: 20px;
    max-width: 600px;
}

.article-cta__actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 16px;
}

.article-cta__btn {
    background: var(--brand-green);
    color: #ffffff !important;
    padding: 12px 26px;
    border-radius: 10px;
    font-weight: 700;
    font-size: 15px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: background 0.2s, transform 0.1s;
    border: none;
    cursor: pointer;
}

.article-cta__btn:hover {
    background: var(--brand-green-hover);
    transform: translateY(-2px);
}

.article-cta__phone {
    color: #ffffff;
    font-size: 18px;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.article-cta__phone:hover {
    color: #86efac;
}

/* Footer */
.blog-footer {
    background: #0f172a;
    color: #94a3b8;
    padding: 40px 20px 24px;
    border-top: 1px solid #1e293b;
    font-size: 14px;
}

.blog-footer__container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 24px;
    padding-bottom: 24px;
    border-bottom: 1px solid #1e293b;
}

.blog-footer__company {
    max-width: 380px;
}

.blog-footer__company h4 {
    color: #ffffff;
    font-size: 18px;
    margin-bottom: 10px;
}

.blog-footer__links h4 {
    color: #ffffff;
    font-size: 15px;
    margin-bottom: 12px;
}

.blog-footer__links ul {
    list-style: none;
}

.blog-footer__links li {
    margin-bottom: 8px;
}

.blog-footer__links a {
    color: #94a3b8;
}

.blog-footer__links a:hover {
    color: #ffffff;
}

.blog-footer__bottom {
    max-width: 1200px;
    margin: 20px auto 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
    color: #64748b;
    flex-wrap: wrap;
    gap: 12px;
}

/* Responsive */
@media (max-width: 768px) {
    .blog-header__nav {
        display: none;
    }
    .blog-header__phone {
        font-size: 15px;
    }
    .blog-hero {
        padding: 24px 16px;
    }
    .blog-hero h1 {
        font-size: 24px;
    }
    .blog-grid {
        grid-template-columns: 1fr;
    }
    .article-box {
        padding: 20px;
    }
    .article-title {
        font-size: 24px;
    }
    .article-cta {
        padding: 24px 18px;
    }
    .article-cta__actions {
        flex-direction: column;
        align-items: flex-start;
    }
    .article-cta__btn {
        width: 100%;
        justify-content: center;
    }
    .blog-footer__container {
        flex-direction: column;
    }
}
