/*
Theme Name: Reboot Child
Theme URI: https://wpshop.ru/themes/reboot
Author: WPShop.biz
Author URI: http://wpshop.biz/
Template: reboot
Version: 1.0.0
*/

/* ==========================================================================
   MYCALCULATORLAND.COM - MASTER UNIFIED DESIGN SYSTEM
   Архитектура стилей сайта:
   0. ШРИФТЫ (WOFF2 приоритет и font-display: swap)
   1. СТАТЬИ И КОНТЕНТ (FAQ-аккордеоны, выноски, формулы, таблицы, ссылки, шаги)
   2. КАЛЬКУЛЯТОРЫ (деликатные переменные и карточки БЕЗ принудительной сетки)
   3. ГЛАВНАЯ СТРАНИЦА (изолирована под селектором body.home)
   4. СПЕЦСТРАНИЦЫ И СЕРВИСНЫЕ БЛОКИ (поиск, форма обратной связи, плагины)
   ========================================================================== */

/* ==========================================================================
   0. ОПТИМИЗАЦИЯ ШРИФТОВ: ПРИОРИТЕТ WOFF2 + FONT-DISPLAY: SWAP
   ========================================================================== */
@font-face {
    font-family: 'wpshop-core';
    src: url('../reboot/assets/fonts/wpshop-core.woff2') format('woff2'),
         url('../reboot/assets/fonts/wpshop-core.woff') format('woff'),
         url('../reboot/assets/fonts/wpshop-core.ttf') format('truetype');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

/* ==========================================================================
   1. СТАТЬИ И ТЕКСТОВЫЙ КОНТЕНТ
   ========================================================================== */

/* Сброс лишней внешней обертки */
.entry-content .calc-content-wrapper {
    background: transparent !important;
    border: none !important;
    padding: 0 !important;
    box-shadow: none !important;
}

/* Очистка пустых параграфов wpautop */
.entry-content p:empty {
    display: none !important;
    margin: 0 !important;
}

/* Лид-абзац статьи */
.cl-lead,
.entry-content p.lead {
    font-size: 16.5px !important;
    line-height: 1.65 !important;
    color: #475569 !important;
    margin-bottom: 24px !important;
}

/* Заголовки статьи */
.entry-content h2 {
    font-size: 22px !important;
    font-weight: 800 !important;
    color: #0f172a !important;
    margin: 36px 0 16px 0 !important;
    letter-spacing: -0.4px !important;
    line-height: 1.3 !important;
}

.entry-content h3 {
    font-size: 17.5px !important;
    font-weight: 700 !important;
    color: #1e293b !important;
    margin: 24px 0 12px 0 !important;
    line-height: 1.35 !important;
}

/* Ссылки внутри контента статьи (без подчеркивания) */
.entry-content a:not(.cl-cta-btn):not([class*="btn"]):not(.hub-card),
.cl-home-seo a,
.ccr-card a,
.ccr-wrap a {
    color: #c2410c !important;
    text-decoration: none !important;
    font-weight: 500 !important;
    transition: color 0.2s ease !important;
}

.entry-content a:not(.cl-cta-btn):not([class*="btn"]):not(.hub-card):hover,
.cl-home-seo a:hover,
.ccr-card a:hover,
.ccr-wrap a:hover {
    color: #9a3412 !important;
    text-decoration: none !important;
}

/* Математические формулы и inline code бейджи (вместо грязно-персикового фона темы) */
.entry-content code,
.cl-callout code,
.calc-formula code {
    background: #f1f5f9 !important;
    color: #0f172a !important;
    border: 1px solid #cbd5e1 !important;
    border-radius: 6px !important;
    padding: 3px 8px !important;
    font-size: 13.5px !important;
    font-weight: 600 !important;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace !important;
}

/* --- ВЫНОСКИ (CALLOUT BOXES) --- */
.cl-callout,
.entry-content .calc-formula {
    background: #ffffff !important;
    border: 1px solid #e2e8f0 !important;
    border-left: 4px solid #ff5a1e !important;
    border-radius: 14px !important;
    padding: 20px 22px !important;
    margin: 24px 0 !important;
    box-shadow: 0 2px 6px rgba(15, 23, 42, 0.03) !important;
    display: flex;
    gap: 16px;
    align-items: flex-start;
}

.cl-callout-icon {
    font-size: 24px;
    line-height: 1;
    flex-shrink: 0;
    margin-top: 2px;
}

.cl-callout-body {
    flex: 1;
    color: #334155;
    font-size: 15px;
    line-height: 1.6;
}

.cl-callout-title,
.calc-formula-title {
    font-weight: 700 !important;
    font-size: 16px !important;
    color: #0f172a !important;
    margin: 0 0 6px 0 !important;
    display: block;
}

.cl-callout-body p:last-child {
    margin-bottom: 0 !important;
}

/* Модификаторы выносок */
.cl-callout-tip { background: #f0fdf4 !important; border-color: #bbf7d0 !important; border-left-color: #16a34a !important; }
.cl-callout-tip .cl-callout-title { color: #166534 !important; }

.cl-callout-warning { background: #fffbeb !important; border-color: #fde68a !important; border-left-color: #d97706 !important; }
.cl-callout-warning .cl-callout-title { color: #92400e !important; }

.cl-callout-example { background: #f0f9ff !important; border-color: #bae6fd !important; border-left-color: #0284c7 !important; }
.cl-callout-example .cl-callout-title { color: #0369a1 !important; }

.cl-example {
    background: #f8fafc !important;
    border: 1px dashed #cbd5e1 !important;
    border-radius: 8px !important;
    padding: 10px 14px !important;
    margin-top: 12px !important;
    font-size: 13.5px !important;
    color: #0f172a !important;
}

/* --- ВЫНОСКА ДЛЯ БОЛЬШИХ ФОРМУЛ (.cl-formula-box) --- */
.cl-formula-box {
    margin: 24px 0;
    padding: 22px 24px;
    background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
    color: #f8fafc;
    border-radius: 14px;
    box-shadow: 0 10px 25px -5px rgba(15, 23, 42, 0.15);
    position: relative;
    overflow: hidden;
}

.cl-formula-box::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 3px;
    background: linear-gradient(90deg, #ff5a1e, #fb923c);
}

.cl-formula-label {
    display: inline-block;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #fb923c;
    margin-bottom: 8px;
}

.cl-formula-display {
    font-size: 20px;
    font-weight: 700;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    color: #ffffff;
    margin: 4px 0 12px 0;
    word-break: break-word;
}

.cl-formula-vars {
    font-size: 13.5px;
    color: #94a3b8;
    line-height: 1.6;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 10px;
}

/* --- ПОШАГОВЫЕ ИНСТРУКЦИИ (.cl-steps) --- */
ol.cl-steps,
ol.instruction-list {
    list-style: none !important;
    counter-reset: cl-step !important;
    padding-left: 0 !important;
    margin: 24px 0 !important;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

ol.cl-steps li,
ol.instruction-list li {
    counter-increment: cl-step !important;
    position: relative !important;
    padding-left: 42px !important;
    margin-bottom: 0 !important;
    font-size: 15px !important;
    color: #334155 !important;
    line-height: 1.6 !important;
}

ol.cl-steps li::before,
ol.instruction-list li::before {
    content: counter(cl-step) !important;
    position: absolute !important;
    left: 0 !important;
    top: 2px !important;
    width: 28px !important;
    height: 26px !important;
    background: #fff4f0 !important;
    color: #ff5a1e !important;
    font-weight: 800 !important;
    font-size: 13px !important;
    border-radius: 8px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    border: 1px solid rgba(255, 90, 30, 0.2) !important;
}

/* --- АДАПТИВНЫЕ ТАБЛИЦЫ (.cl-table) --- */
.cl-table-wrap,
.entry-content table {
    margin: 24px 0 !important;
    overflow-x: auto !important;
    border-collapse: separate !important;
    border-spacing: 0 !important;
    width: 100% !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 12px !important;
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.03) !important;
    background: #ffffff !important;
    -webkit-overflow-scrolling: touch !important;
}

.cl-table th,
.entry-content table thead th {
    background: #f8fafc !important;
    color: #1e293b !important;
    font-weight: 700 !important;
    padding: 13px 18px !important;
    border-bottom: 2px solid #e2e8f0 !important;
    font-size: 14px !important;
    text-align: left !important;
    white-space: nowrap !important;
}

.cl-table td,
.entry-content table tbody td {
    padding: 12px 18px !important;
    border-bottom: 1px solid #f1f5f9 !important;
    color: #334155 !important;
    font-size: 14px !important;
    line-height: 1.5 !important;
}

.entry-content table tbody tr:nth-child(even) td {
    background: #fafafc !important;
}

.entry-content table tbody tr:last-child td {
    border-bottom: none !important;
}

/* --- FAQ АККОРДЕОНЫ (СОВЕРШЕННЫЙ UI, РОВНЫЕ СТРЕЛКИ, БЕЗ ЛИШНИХ ТРЕУГОЛЬНИКОВ) --- */
.cl-faq,
.calc-faq {
    margin: 28px 0 !important;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.cl-faq details,
.calc-faq details,
.entry-content details {
    background: #ffffff !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 12px !important;
    margin-bottom: 10px !important;
    padding: 0 !important;
    overflow: hidden !important;
    transition: border-color 0.2s ease, box-shadow 0.2s ease !important;
}

.cl-faq details:hover,
.calc-faq details:hover,
.entry-content details:hover {
    border-color: #cbd5e1 !important;
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.04) !important;
}

.cl-faq details[open],
.calc-faq details[open],
.entry-content details[open] {
    border-color: #ff5a1e !important;
    box-shadow: 0 4px 14px rgba(255, 90, 30, 0.08) !important;
}

.cl-faq summary,
.calc-faq summary,
.entry-content details summary {
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    gap: 16px !important;
    padding: 16px 20px !important;
    font-weight: 700 !important;
    font-size: 15.5px !important;
    color: #0f172a !important;
    cursor: pointer !important;
    list-style: none !important;
    user-select: none !important;
    margin: 0 !important;
    background: transparent !important;
    transition: color 0.2s ease, background-color 0.2s ease !important;
}

/* Скрываем нативный браузерный маркер-треугольник ► */
.cl-faq summary::-webkit-details-marker,
.calc-faq summary::-webkit-details-marker,
.entry-content details summary::-webkit-details-marker,
.cl-faq summary::marker,
.calc-faq summary::marker,
.entry-content details summary::marker {
    display: none !important;
}

/* Глушим автоматические теги <br> от wpautop внутри summary */
.cl-faq summary br,
.calc-faq summary br,
.entry-content details summary br {
    display: none !important;
}

/* Настройка и анимация вращения стрелки справа */
.cl-faq-chevron,
.calc-faq-chevron {
    width: 20px !important;
    height: 20px !important;
    flex-shrink: 0 !important;
    margin-left: auto !important;
    color: #94a3b8 !important;
    stroke: #94a3b8 !important;
    transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1), color 0.2s ease, stroke 0.2s ease !important;
}

.cl-faq details:hover .cl-faq-chevron,
.calc-faq details:hover .calc-faq-chevron {
    color: #ff5a1e !important;
    stroke: #ff5a1e !important;
}

.cl-faq details[open] .cl-faq-chevron,
.calc-faq details[open] .calc-faq-chevron,
.entry-content details[open] .cl-faq-chevron {
    transform: rotate(180deg) !important;
    color: #ff5a1e !important;
    stroke: #ff5a1e !important;
}

/* Ответ внутри FAQ */
.cl-faq-answer,
.calc-faq-answer,
.entry-content details > div:not(.cl-faq-question),
.entry-content details > :not(summary) {
    padding: 0 20px 18px 20px !important;
}

.cl-faq details p,
.calc-faq details p,
.entry-content details p {
    margin: 0 !important;
    font-size: 14.5px !important;
    color: #475569 !important;
    line-height: 1.6 !important;
}

/* --- БЛОК ПЕРЕЛИНКОВКИ "СМОТРИТЕ ТАКЖЕ" (cl-related / calc-related) --- */
nav.cl-related,
.entry-content nav.cl-related,
.entry-content .cl-related,
.entry-content .calc-related,
.calc-related {
    background: #f8fafc !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 18px !important;
    padding: 20px 22px !important;
    margin: 36px 0 24px 0 !important;
    box-shadow: 0 1px 4px rgba(15, 23, 42, 0.02) !important;
    position: relative !important;
    box-sizing: border-box !important;
}

/* Заголовок блока с фирменным оранжевым акцентным маркером */
nav.cl-related > p:first-child,
nav.cl-related > h3:first-child,
nav.cl-related > h4:first-child,
.calc-related > p:first-child,
.calc-related > h3:first-child,
.calc-related > h4:first-child,
.calc-related-title {
    margin: 0 0 16px 0 !important;
    font-size: 13px !important;
    font-weight: 800 !important;
    color: #475569 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.08em !important;
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
    line-height: 1.2 !important;
    text-align: left !important;
}

nav.cl-related > p:first-child::before,
nav.cl-related > h3:first-child::before,
nav.cl-related > h4:first-child::before,
.calc-related > p:first-child::before,
.calc-related-title::before {
    content: "" !important;
    display: inline-block !important;
    width: 4px !important;
    height: 14px !important;
    background: #ff5a1e !important;
    border-radius: 2px !important;
    flex-shrink: 0 !important;
}

/* Список карточек — авто-сетка, равномерно заполняющая ширину */
nav.cl-related ul,
.entry-content nav.cl-related ul,
.entry-content .cl-related ul,
.entry-content .calc-related ul,
.calc-related ul {
    list-style: none !important;
    padding: 0 !important;
    margin: 0 !important;
    display: grid !important;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)) !important;
    gap: 12px !important;
    align-items: stretch !important;
}

/* Элементы списка LI — полностью глушим любые маркеры темы Reboot */
nav.cl-related li,
.entry-content nav.cl-related ul li,
.entry-content .cl-related ul li,
.entry-content .calc-related ul li,
.calc-related li {
    list-style: none !important;
    margin: 0 !important;
    padding: 0 !important;
    display: flex !important;
    position: static !important;
}

/* УБИВАЕМ псевдоэлементы-буллеты темы Reboot */
nav.cl-related li::before,
nav.cl-related li::after,
.entry-content nav.cl-related ul li::before,
.entry-content nav.cl-related ul li::after,
.entry-content nav.cl-related ul:not([class]) > li::before,
.entry-content .cl-related ul:not([class]) > li::before,
.entry-content .calc-related ul:not([class]) > li::before,
.calc-related li::before,
.calc-related li::after {
    display: none !important;
    content: none !important;
    width: 0 !important;
    height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    background: transparent !important;
}

/* Карточки-ссылки: аккуратные мини-карточки со стрелкой и динамическим подъемом */
body .entry-content nav.cl-related a,
body .entry-content .cl-related a,
body .entry-content .calc-related a,
nav.cl-related a,
.entry-content nav.cl-related a,
.entry-content .cl-related a,
.entry-content .calc-related a,
.calc-related a {
    display: flex !important;
    align-items: center !important;
    gap: 12px !important;
    width: 100% !important;
    background: #ffffff !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 14px !important;
    padding: 12px 16px !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    color: #1e293b !important;
    text-decoration: none !important;
    text-transform: none !important;
    line-height: 1.35 !important;
    box-sizing: border-box !important;
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04) !important;
    transition: all 0.22s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

/* Иконка-стрелка слева для каждой ссылки */
body .entry-content nav.cl-related a::before,
body .entry-content .cl-related a::before,
body .entry-content .calc-related a::before,
nav.cl-related a::before,
.calc-related a::before {
    content: "" !important;
    display: inline-block !important;
    width: 26px !important;
    height: 26px !important;
    border-radius: 8px !important;
    background: #fff4f0 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ff5a1e' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12h14'/%3E%3Cpath d='m13 6 6 6-6 6'/%3E%3C/svg%3E") center / 13px 13px no-repeat !important;
    flex-shrink: 0 !important;
    transition: all 0.22s ease !important;
}

/* Ховер карточек */
body .entry-content nav.cl-related a:hover,
body .entry-content .cl-related a:hover,
body .entry-content .calc-related a:hover,
nav.cl-related a:hover,
.entry-content nav.cl-related a:hover,
.entry-content .cl-related a:hover,
.entry-content .calc-related a:hover,
.calc-related a:hover {
    background: #ffffff !important;
    border-color: #ff5a1e !important;
    color: #ff5a1e !important;
    text-decoration: none !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 6px 16px -2px rgba(255, 90, 30, 0.16) !important;
}

body .entry-content nav.cl-related a:hover::before,
body .entry-content .cl-related a:hover::before,
body .entry-content .calc-related a:hover::before,
nav.cl-related a:hover::before,
.calc-related a:hover::before {
    background-color: #ff5a1e !important;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12h14'/%3E%3Cpath d='m13 6 6 6-6 6'/%3E%3C/svg%3E") !important;
}

@media (max-width: 540px) {
    nav.cl-related ul,
    .entry-content nav.cl-related ul,
    .entry-content .cl-related ul,
    .entry-content .calc-related ul,
    .calc-related ul {
        grid-template-columns: 1fr !important;
    }
    nav.cl-related,
    .entry-content nav.cl-related {
        padding: 16px 14px !important;
    }
}

/* --- БЕЙДЖИ И МЕТКИ (.cl-badge) --- */
.cl-badge {
    display: inline-flex;
    align-items: center;
    padding: 3px 10px;
    font-size: 12px;
    font-weight: 600;
    border-radius: 9999px;
    background: #f1f5f9;
    color: #475569;
    margin-right: 6px;
}
.cl-badge-orange { background: #fff7ed; color: #c2410c; border: 1px solid #fed7aa; }
.cl-badge-blue { background: #eff6ff; color: #1d4ed8; border: 1px solid #bfdbfe; }


/* ==========================================================================
   2. КАЛЬКУЛЯТОРЫ: ДЕЛИКАТНАЯ ДИЗАЙН-СИСТЕМА (БЕЗ ПРИНУДИТЕЛЬНОЙ СЕТКИ)
   ========================================================================== */

/* Переменные для калькуляторов */
[id$="-calc-container"] {
    --c-primary: #FF5A1E;
    --c-primary-hover: #E0480E;
    --c-primary-rgb: 255, 90, 30;
    --c-bg: #FFFFFF;
    --c-bg-soft: #F8FAFC;
    --c-bg-header: #FAFAFC;
    --c-text: #0F172A;
    --c-text-muted: #475569;
    --c-border: #E2E8F0;
    --c-radius: 16px;
    --c-radius-sm: 10px;
    --c-shadow: 0 10px 30px -10px rgba(15, 23, 42, 0.07), 0 0 1px 1px rgba(15, 23, 42, 0.04);
    --c-shadow-focus: 0 0 0 3px rgba(var(--c-primary-rgb), 0.15);
    max-width: 100% !important;
}

/* Карточка калькулятора с акцентной верхней полосой */
[id$="-calc-container"] :is([class$="-calc-card"], [class$="-card"]) {
    background: var(--c-bg);
    border: 1px solid var(--c-border);
    border-radius: var(--c-radius);
    box-shadow: var(--c-shadow);
    overflow: hidden;
    position: relative;
    isolation: isolate;
    width: 100% !important;
    box-sizing: border-box !important;
}

[id$="-calc-container"] :is([class$="-calc-card"], [class$="-card"])::before {
    content: "";
    position: absolute;
    inset: 0 0 auto 0;
    height: 4px;
    background: linear-gradient(90deg, var(--c-primary), #FF8A00);
    z-index: 1;
}

/* Скрываем только дублирующий внутренний заголовок калькулятора, если страница уже имеет H1 */
[id$="-calc-container"] [class$="-header-section"] {
    display: none !important;
}

/* Лейблы полей ввода */
[id$="-calc-container"] :is(label, [class$="-label"]) {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--c-text-muted);
    margin-bottom: 6px;
    display: block;
}

/* Поля ввода (аккуратный фокус) */
[id$="-calc-container"] :is(input:not([type="checkbox"]):not([type="radio"]), select) {
    background: var(--c-bg-soft);
    border: 1px solid var(--c-border);
    border-radius: var(--c-radius-sm);
    padding: 10px 14px;
    font-size: 15px;
    font-weight: 600;
    color: var(--c-text);
    transition: background-color .2s, border-color .2s, box-shadow .2s;
    box-sizing: border-box;
}

[id$="-calc-container"] :is(input, select):focus {
    outline: none;
    background: var(--c-bg);
    border-color: var(--c-primary);
    box-shadow: var(--c-shadow-focus);
}

/* Кнопка копирования результата */
[id$="-calc-container"] [class$="-copy-btn"] {
    background: var(--c-bg);
    border: 1px solid var(--c-border);
    cursor: pointer;
    width: 36px;
    height: 36px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--c-text-muted);
    box-shadow: 0 2px 5px rgba(0,0,0,0.04);
    flex-shrink: 0;
    transition: background-color .2s, border-color .2s, color .2s, transform .2s;
}

[id$="-calc-container"] [class$="-copy-btn"]:hover {
    background: var(--c-primary);
    color: #ffffff;
    border-color: var(--c-primary);
    transform: scale(1.05);
}


/* ==========================================================================
   3. ГЛАВНАЯ СТРАНИЦА (СТРОГО ИЗОЛИРОВАНА ПОД body.home)
   ========================================================================== */

body.home .hero-section {
    width: 100%;
    max-width: 1200px;
    margin: 2px auto 24px;
    padding: 0 20px;
    box-sizing: border-box;
}

body.home .hero-grid {
    display: grid;
    grid-template-columns: 0.9fr 1.4fr;
    gap: 50px;
    align-items: center;
}

body.home .hero-col-left { display: flex; justify-content: center; }
body.home .hero-col-right { display: flex; flex-direction: column; gap: 8px; align-items: center; text-align: center; }

body.home .hero-h1 {
    font-size: 34px;
    font-weight: 800;
    color: #1e293b;
    margin: 0;
    line-height: 1.25;
    letter-spacing: -0.6px;
}

body.home .hero-highlight {
    background: linear-gradient(135deg, #d14600 0%, #ff7a00 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
}

body.home .hero-sub {
    font-size: 16px;
    color: #475569;
    line-height: 1.6;
    margin: 0;
    max-width: 560px;
}

body.home .hero-quick {
    display: flex;
    flex-direction: column;
    gap: 2px;
    align-items: center;
    margin-top: 2px;
}

body.home .hql-label { font-size: 13px; color: #444b55; font-weight: 600; }
body.home .hero-quick .ccm-s-w { margin: 0 !important; }

body.home hr.cl-home-divider {
    margin: 28px auto;
    border: none;
    border-top: 1px solid #eaeaea;
    max-width: 1200px;
}

body.home .cl-home-seo {
    max-width: 1100px;
    margin: 30px auto;
    padding: 0 20px;
    text-align: center;
    box-sizing: border-box;
}

body.home .cl-home-h2 { font-size: 28px; font-weight: 800; color: #1e293b; margin: 0 0 16px; letter-spacing: -0.5px; }
body.home .cl-home-desc { font-size: 16px; color: #475569; line-height: 1.6; max-width: 720px; margin: 0 auto 28px; }

body.home .cl-home-features {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    text-align: left;
    margin-top: 28px;
}

body.home .cl-feature {
    background: #fff;
    border: 1px solid #eef2f7;
    border-radius: 16px;
    padding: 26px 24px;
    box-shadow: 0 1px 3px rgba(0,0,0,.03);
    transition: transform .2s ease, box-shadow .2s ease;
}

body.home .cl-feature:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 24px rgba(15,23,42,.06);
}

body.home .cl-feature-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
    flex-shrink: 0;
}

body.home .cl-feature-icon svg { width: 24px; height: 24px; }
body.home .cl-feature h3 { font-size: 18px; font-weight: 700; color: #1e293b; margin: 0 0 12px; line-height: 1.3; }
body.home .cl-feature p { font-size: 14px; color: #475569; line-height: 1.6; margin: 0; }

body.home .cl-home-cta {
    max-width: 800px;
    margin: 30px auto;
    padding: 40px 28px;
    background: #fff7ed;
    border: 1px solid #ffedd5;
    border-radius: 20px;
    text-align: center;
    box-sizing: border-box;
}

body.home .cl-home-cta .cl-home-h2 { margin-bottom: 16px; }
body.home .cl-home-cta .cl-home-desc { margin-bottom: 28px; }

.cl-cta-btn {
    display: inline-block;
    background: #c2410c;
    color: #fff !important;
    padding: 14px 36px;
    border-radius: 12px;
    font-weight: 700;
    font-size: 15px;
    text-decoration: none !important;
    transition: all .2s;
    box-shadow: 0 4px 12px rgba(194,65,12,.25);
}

.cl-cta-btn:hover {
    background: #9a3412;
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(194,65,12,.3);
}

body.home .ccr-split { margin: 10px 0 30px !important; }
body.home .ccr-wrap { gap: 44px !important; margin: 10px 0 30px !important; }
body.home .ccr-title { margin: 20px 0 18px !important; }

/* Адаптив главной */
@media (max-width: 1024px) {
    body.home .hero-grid { grid-template-columns: 1fr; gap: 0; }
    body.home .hero-col-left { display: none !important; }
    body.home .hero-section { margin: 1px auto 20px !important; }
    body.home .hero-h1 { font-size: 28px; }
    body.home .ccr-split { margin: 8px 0 24px !important; }
    body.home .ccr-wrap { gap: 32px !important; }
}

@media (max-width: 960px) {
    body.home .cl-home-features { grid-template-columns: 1fr; }
}

@media (max-width: 480px) {
    body.home .hero-h1 { font-size: 24px; }
    body.home .hero-sub { font-size: 15px; }
    body.home .cl-home-h2 { font-size: 22px; }
    body.home .cl-home-cta { margin: 30px 16px; padding: 32px 20px; }
    body.home .cl-feature { padding: 22px 18px; }
}


/* ==========================================================================
   4. СПЕЦСТРАНИЦЫ И СЕРВИСНЫЕ БЛОКИ
   ========================================================================== */

/* --- ПОИСК В ШАПКЕ --- */
.ccm-search-ico, .ccm-search-ico circle, .ccm-search-ico path {
    fill: none !important;
    stroke: currentColor !important;
    stroke-width: 2 !important;
    stroke-linecap: round !important;
    stroke-linejoin: round !important;
}

/* --- ФОРМА ОБРАТНОЙ СВЯЗИ (.custom-contact-form) --- */
.custom-contact-form {
    max-width: 580px;
    margin: 20px auto;
    padding: 30px;
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.05);
}

.custom-contact-form label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    font-size: 14px;
    color: #333;
}

.custom-contact-form input[type="text"],
.custom-contact-form input[type="email"],
.custom-contact-form textarea {
    width: 100%;
    padding: 14px 16px;
    margin-bottom: 20px;
    border: 2px solid #f0f0f0;
    border-radius: 8px;
    background-color: #fcfcfc;
    font-size: 16px;
    box-sizing: border-box;
    transition: all 0.3s ease;
    outline: none;
}

.custom-contact-form input:focus,
.custom-contact-form textarea:focus {
    border-color: #d14600;
    background-color: #fff;
    box-shadow: 0 0 0 4px rgba(209, 70, 0, 0.1);
}

.cf-button {
    width: 100%;
    padding: 16px;
    background-color: #d14600;
    color: #fff;
    font-size: 16px;
    font-weight: bold;
    text-transform: uppercase;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.3s ease;
}

.cf-button:hover { background-color: #b03a00; }
.cf-success-msg { color: #2e7d32; background-color: #e8f5e9; padding: 15px; border-radius: 8px; margin-bottom: 25px; text-align: center; font-weight: bold; border: 1px solid #c8e6c9; }
.error-box { color: #c62828; background-color: #ffebee; padding: 15px; border-radius: 8px; margin-bottom: 25px; text-align: center; }

@media (max-width: 600px) {
    .custom-contact-form { margin: 2px; padding: 20px; }
}

/* --- КАТАЛОГ ПЛАГИНОВ --- */
.wp-plugin-catalog {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
    margin: 30px 0;
}

.plugin-card {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    overflow: hidden;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    display: flex;
    flex-direction: column;
}

.plugin-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
    border-color: #d14600;
}

.plugin-thumb {
    height: 300px;
    background: #f9f9f9;
    display: flex;
    align-items: center;
    justify-content: center;
    border-bottom: 1px solid #eee;
    padding: 20px;
}

.plugin-thumb img { max-height: 100%; width: auto; object-fit: contain; border-radius: 8px; }
.plugin-body { padding: 20px; display: flex; flex-direction: column; flex-grow: 1; }
.plugin-title { margin: 0 0 10px 0 !important; font-size: 18px; font-weight: 700; line-height: 1.3; }
.plugin-desc { font-size: 14px; color: #555; margin-bottom: 20px !important; flex-grow: 1; line-height: 1.5; }
.plugin-btn { display: block; text-align: center; background: #d14600; color: #fff !important; text-decoration: none; padding: 10px 15px; border-radius: 6px; font-weight: 600; transition: background 0.2s; }
.plugin-btn:hover { background: #b03a00; color: #fff !important; }

/* --- ФИКСЫ ПРОИЗВОДИТЕЛЬНОСТИ И ЛОГОТИПА --- */
a, .widget_nav_menu a, .site-footer a, .widget a {
    transition-property: color, background-color, border-color, transform, opacity, box-shadow !important;
}

.site-branding__body img {
    width: 44px !important;
    height: 44px !important;
    min-width: 44px !important;
    display: block;
}

/* ==========================================================================
   5. ГЛОБАЛЬНАЯ ОПТИМИЗАЦИЯ ОТСТУПОВ И МОБИЛЬНОГО UX ДЛЯ ВСЕХ КАЛЬКУЛЯТОРОВ
   ========================================================================== */

@media (max-width: 768px) {
    /* Компактная шапка: убираем лишние 18px дыры снизу */
    .site-header {
        margin-bottom: 12px !important;
    }

    /* Компактная полоса поиска на внутренних страницах */
    .cl-top-section {
        margin-bottom: 8px !important;
    }
    .ccm-search {
        height: 42px !important;
        max-width: 100% !important;
    }
    .ccm-search input {
        height: 42px !important;
        font-size: 13.5px !important;
    }
    .ccm-search button {
        height: 36px !important;
        padding: 0 14px !important;
    }

    /* Компактные заголовки H1 на всех калькуляторах (не распирают первый экран) */
    h1.entry-title, .entry-header h1, .page-header h1, h1.cl-dynamic-h1 {
        font-size: 22px !important;
        margin-top: 4px !important;
        margin-bottom: 12px !important;
        line-height: 1.25 !important;
    }

    /* Прижимаем контейнеры всех 1500+ калькуляторов к первому экрану */
    [id$="-calc-container"], 
    .calc-content-wrapper, 
    .entry-content .calc-content-wrapper {
        margin-top: 6px !important;
        margin-bottom: 16px !important;
        padding-left: 8px !important;
        padding-right: 8px !important;
    }

    /* Карточки калькуляторов на смартфонах */
    [id$="-calc-container"] :is([class$="-calc-card"], [class$="-card"]) {
        border-radius: 14px !important;
    }

    /* Лейблы и поля ввода всех калькуляторов */
    [id$="-calc-container"] :is(label, [class$="-label"]) {
        font-size: 11px !important;
        margin-bottom: 4px !important;
    }
    [id$="-calc-container"] :is(input:not([type="checkbox"]):not([type="radio"]), select) {
        padding: 8px 12px !important;
        font-size: 14px !important;
        border-radius: 8px !important;
    }

    /* Глобальная защита выносок в статьях от переполнения экрана */
    .cl-callout {
        flex-direction: column !important;
        padding: 14px 16px !important;
        margin: 18px 0 !important;
        gap: 10px !important;
    }
    .cl-callout > * {
        max-width: 100% !important;
        min-width: 0 !important;
        box-sizing: border-box !important;
    }
    .cl-example {
        max-width: 100% !important;
        box-sizing: border-box !important;
    }

    /* Защита любых широких таблиц в статьях от поломки верстки */
    .entry-content table {
        display: block !important;
        width: 100% !important;
        overflow-x: auto !important;
        -webkit-overflow-scrolling: touch !important;
    }
}

/* ==========================================================================
   6. ПЕРЕНОС ПЕРЕКЛЮЧАТЕЛЯ ЯЗЫКОВ В ШАПКУ И СТИЛИЗАЦИЯ ШЕРИНГА
   ========================================================================== */

/* Компактный и эстетичный контейнер кнопок "Поделиться" (VK, TG, WA, Копировать) */
.share-buttons {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;
    flex-wrap: wrap !important;
    padding: 16px 0 8px !important;
}

.share-btn {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 38px !important;
    height: 38px !important;
    background: #f8fafc !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 50% !important;
    color: #64748b !important;
    cursor: pointer !important;
    transition: all .2s ease !important;
}

.share-btn:hover {
    color: #fff !important;
    border-color: transparent !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 4px 12px rgba(0,0,0,.12) !important;
}

.share-vk:hover   { background: #0077FF !important; }
.share-tg:hover   { background: #2AABEE !important; }
.share-wa:hover   { background: #25D366 !important; }
.share-copy:hover { background: #475569 !important; }

.share-copy.copied {
    background: #16a34a !important;
    color: #fff !important;
    border-color: transparent !important;
}

/* --- Б. Перенос переключателя языков в шапку сайта --- */
/* Дефолтная позиция (до перемещения в DOM) */
.pll-float-switcher {
    position: absolute !important;
    top: 26px !important;
    right: 12px !important;
    bottom: auto !important;
    left: auto !important;
    z-index: 9999 !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: flex-end !important;
    gap: 4px !important;
}

/* Когда переключатель перемещен внутрь .site-header-inner */
.site-header-inner .pll-float-switcher {
    position: relative !important;
    top: auto !important;
    bottom: auto !important;
    left: auto !important;
    right: auto !important;
    margin-left: 14px !important;
    flex-shrink: 0 !important;
}

/* Кнопка текущего языка (аккуратный pill) */
.pll-float-main {
    width: auto !important;
    min-width: 38px !important;
    height: 32px !important;
    padding: 0 10px !important;
    border-radius: 8px !important;
    background: #f8fafc !important;
    color: #1e293b !important;
    border: 1px solid #cbd5e1 !important;
    font-size: 12px !important;
    font-weight: 700 !important;
    letter-spacing: 0.5px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 4px !important;
    box-shadow: 0 1px 2px rgba(0,0,0,0.05) !important;
    cursor: pointer !important;
    transition: all 0.2s ease !important;
}

.pll-float-main::after {
    content: '' !important;
    display: inline-block !important;
    width: 0 !important;
    height: 0 !important;
    border-left: 3.5px solid transparent !important;
    border-right: 3.5px solid transparent !important;
    border-top: 4.5px solid #64748b !important;
    transition: transform 0.2s ease !important;
}

.pll-float-switcher:hover .pll-float-main {
    background: #ffffff !important;
    color: #d14600 !important;
    border-color: #d14600 !important;
    transform: none !important;
    box-shadow: 0 2px 8px rgba(209, 70, 0, 0.15) !important;
}

.pll-float-switcher:hover .pll-float-main::after {
    border-top-color: #d14600 !important;
    transform: rotate(180deg) !important;
}

/* Выпадающий список языков */
.pll-float-list {
    position: absolute !important;
    top: calc(100% + 4px) !important;
    right: 0 !important;
    background: #ffffff !important;
    border-radius: 8px !important;
    padding: 4px !important;
    box-shadow: 0 6px 20px rgba(0,0,0,0.12) !important;
    border: 1px solid #e2e8f0 !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 4px !important;
    min-width: 52px !important;
    z-index: 9999 !important;
    opacity: 0 !important;
    visibility: hidden !important;
    transform: translateY(-4px) !important;
    transition: all 0.2s ease !important;
}

.pll-float-switcher:hover .pll-float-list {
    opacity: 1 !important;
    visibility: visible !important;
    transform: translateY(0) !important;
}

/* Пункты выбора языка */
.pll-float-item {
    width: 100% !important;
    height: 28px !important;
    border-radius: 6px !important;
    background: #f8fafc !important;
    color: #334155 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-size: 11px !important;
    font-weight: 700 !important;
    text-decoration: none !important;
    border: 1px solid #f1f5f9 !important;
    box-shadow: none !important;
    transition: all 0.15s ease !important;
}

.pll-float-item:hover {
    background: #d14600 !important;
    color: #ffffff !important;
    border-color: #d14600 !important;
}

/* Адаптив под десктоп */
@media (min-width: 769px) {
    .pll-float-switcher {
        top: 15px !important;
        right: calc(max(16px, (100vw - 1190px) / 2 + 10px)) !important;
    }
}

/* Адаптив под смартфоны */
@media (max-width: 768px) {
    .site-header-inner {
        display: flex !important;
        align-items: center !important;
        justify-content: space-between !important;
        padding: 0 15px !important;
    }
    .site-branding {
        flex: 1 !important;
        margin: 0 10px !important;
    }
    .site-header-inner .pll-float-switcher {
        margin-left: 0 !important;
    }
    .pll-float-main {
        height: 30px !important;
        padding: 0 8px !important;
        font-size: 11px !important;
    }
}

