/*
Theme Name: dds_pizzeriamozzarellaaz.com
Author: Матвей Волков
Description: Тема для информационного сайта с практическими советами и разборами.
Version: 1.1
Text Domain: mzsov
*/

:root {
    --bg: #F4F6F9;
    --bg-alt: #E8ECF2;
    --dark: #1A1F2B;
    --ink: #1E232E;
    --copper: #C97B4A;
    --steel: #4A6B8F;
    --muted: #7A8494;
    --line: #D0D7E0;
    --paper: repeating-linear-gradient(7deg, rgba(226,230,237,0) 0 39.5px, #E2E6ED 39.5px 40px);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    margin: 0;
    padding: 0;
    background-color: var(--bg);
    background-image: var(--paper);
    color: var(--ink);
    font-family: "Roboto Flex", "Segoe UI", "Helvetica Neue", Arial, sans-serif;
    font-size: 17px;
    line-height: 1.7;
    letter-spacing: 0.01em;
    overflow-x: hidden;
}

/* Асимметричная медная полоса вдоль левого края окна */
body::before {
    content: "";
    position: fixed;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: var(--copper);
    z-index: 900;
}

h1, h2, h3, h4, h5, h6 {
    font-family: Inter, "Segoe UI", "Helvetica Neue", Arial, sans-serif;
    color: var(--ink);
    font-weight: 700;
    letter-spacing: -0.015em;
    line-height: 1.18;
    margin: 0 0 0.7em;
}

h1 { font-size: 3.2rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.45rem; }
h4 { font-size: 1.18rem; }

p { margin: 0 0 1.1em; }

a {
    color: var(--copper);
    text-decoration: none;
    position: relative;
}

.entry-content a::after,
.widget a::after,
.breadcrumbs a::after,
.site-nav a::after,
.card-title a::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: -2px;
    height: 1px;
    background: var(--copper);
    transform: scaleX(0);
    transition: transform .22s ease;
}

.entry-content a:hover::after,
.widget a:hover::after,
.breadcrumbs a:hover::after,
.site-nav a:hover::after,
.card-title a:hover::after {
    transform: scaleX(1);
}

img { max-width: 100%; height: auto; }

.shell {
    width: min(92%, 1180px);
    margin-inline: auto;
}

/* Квадратная медная пометка перед заголовками в тексте */
.entry-content h2,
.entry-content h3 {
    position: relative;
    padding-left: 16px;
}

.entry-content h2::before,
.entry-content h3::before {
    content: "";
    position: absolute;
    left: 0;
    bottom: 0.32em;
    width: 6px;
    height: 6px;
    background: var(--copper);
}

/* Заголовки секций: смещение вправо + тонкая вертикальная черта слева */
.sec-title {
    position: relative;
    margin: 0 0 2.2rem 34px;
    font-size: 2rem;
}

.sec-title::before {
    content: "";
    position: absolute;
    left: -34px;
    top: 0.12em;
    width: 2px;
    height: 1.5em;
    background: var(--copper);
}

/* Кнопки */
.btn {
    display: inline-block;
    padding: 0.72em 1.6em;
    border: 1.5px solid var(--copper);
    border-radius: 4px;
    color: var(--copper);
    background: transparent;
    font-size: 0.94rem;
    font-weight: 600;
    letter-spacing: 0.03em;
    transition: background-color .25s ease, color .25s ease, transform .15s ease;
}

.btn:hover {
    background: var(--copper);
    color: #fff;
    transform: translateY(1px);
}

.btn-light {
    border-color: var(--copper);
    color: #F4F6F9;
}

.btn-light:hover {
    background: var(--copper);
    color: #fff;
}

/* Шапка */
.site-head {
    background: var(--dark);
    color: #EDF0F5;
    padding: 1.6rem 0;
}

.head-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.6rem;
    flex-wrap: wrap;
}

.brand {
    display: flex;
    align-items: center;
    gap: 0.9rem;
    min-width: 0;
    text-decoration: none;
}

.brand-logo,
.brand-mark {
    display: block;
    width: 46px;
    height: 46px;
    flex: 0 0 46px;
}

.brand-text { min-width: 0; }

.brand-name {
    display: block;
    font-family: Inter, "Segoe UI", Arial, sans-serif;
    font-size: 1.02rem;
    font-weight: 700;
    color: #F4F6F9;
    line-height: 1.3;
}

.brand-desc {
    display: block;
    font-size: 0.78rem;
    color: #98A3B4;
    line-height: 1.45;
    margin-top: 0.25rem;
    max-width: 460px;
}

.nav-toggle {
    display: none;
    border: 1.5px solid var(--copper);
    border-radius: 4px;
    background: transparent;
    color: #F4F6F9;
    padding: 0.5em 0.9em;
    font: inherit;
    font-size: 0.9rem;
    cursor: pointer;
}

.site-nav ul {
    list-style: none;
    display: flex;
    gap: 1.7rem;
    margin: 0;
    padding: 0;
    flex-wrap: wrap;
}

.site-nav a {
    color: #DCE2EA;
    font-size: 0.95rem;
    letter-spacing: 0.02em;
}

.site-nav a:hover { color: var(--copper); }

.site-nav .current-menu-item > a { color: var(--copper); }

/* Хлебные крошки */
.breadcrumbs {
    font-size: 0.85rem;
    color: var(--muted);
    padding: 1.5rem 0 0;
}

.breadcrumbs a { color: var(--steel); }

.breadcrumbs .sep { margin: 0 0.45rem; color: var(--line); }

/* Раскладки */
.site-main { padding: 2.2rem 0 5rem; }

.layout-single {
    display: block;
    width: 85%;
    margin-left: auto;
    margin-right: auto;
}

.layout-with-sidebar {
    display: grid;
    grid-template-columns: minmax(0, 67fr) minmax(0, 27fr);
    gap: 6%;
    align-items: start;
}

.content-area { min-width: 0; }

.sidebar {
    min-width: 0;
    background: var(--bg);
    border-left: 1px solid var(--line);
    padding-left: 1.6rem;
}

/* Виджеты */
.widget {
    margin-bottom: 2.4rem;
}

.widget-title {
    font-size: 1.05rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--ink);
    margin-bottom: 1rem;
    position: relative;
    padding-left: 14px;
}

.widget-title::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0.42em;
    width: 6px;
    height: 6px;
    background: var(--copper);
}

.sidebar .widget { color: var(--ink); }
.sidebar .widget a { color: var(--steel); }
.sidebar .widget a:hover { color: var(--copper); }
.sidebar .widget .post-date { color: var(--muted); }

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

.widget li {
    padding: 0.55rem 0;
    border-bottom: 1px solid var(--line);
    font-size: 0.94rem;
}

.widget li:last-child { border-bottom: 0; }

/* Карточки записей */
.card-list {
    display: flex;
    flex-direction: column;
    gap: 1.6rem;
}

.card {
    display: flex;
    flex-direction: column;
    border: 1px solid var(--line);
    border-radius: 0;
    background: #fff;
    overflow: hidden;
    transition: border-color .25s ease, transform .25s ease;
}

.card:hover {
    border-color: var(--copper);
    transform: translateY(-2px);
}

.card-row {
    flex-direction: row;
    align-items: stretch;
}

.card-thumb-wrap {
    flex: 0 0 30%;
    position: relative;
    overflow: hidden;
    min-height: 190px;
    background: var(--bg-alt);
}

.card-thumb-wrap a {
    display: block;
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
}

.card-thumb-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.card-body {
    flex: 1;
    min-width: 0;
    padding: 1.5rem 1.7rem;
    display: flex;
    flex-direction: column;
}

.card-title {
    font-size: 1.3rem;
    margin: 0 0 0.5rem;
}

.card-title a { color: var(--ink); }

.card-title a:hover { color: var(--copper); }

.card-meta {
    font-size: 0.8rem;
    color: var(--muted);
    letter-spacing: 0.04em;
    margin-bottom: 0.8rem;
}

.card-excerpt {
    color: #3C4552;
    font-size: 0.97rem;
    margin-bottom: 1.1rem;
}

.card-excerpt p {
    margin: 0 0 0.5em;
    background: none;
}

.card-more { margin-top: auto; }

/* Пагинация */
.pagination {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 3rem;
}

.pagination .page-numbers {
    display: inline-block;
    min-width: 42px;
    text-align: center;
    padding: 0.5em 0.85em;
    border: 1px solid var(--line);
    border-radius: 4px;
    color: var(--steel);
    font-size: 0.92rem;
    transition: border-color .2s ease, color .2s ease, background-color .2s ease;
}

.pagination a.page-numbers:hover {
    border-color: var(--copper);
    color: var(--copper);
}

.pagination .page-numbers.current {
    background: var(--copper);
    border-color: var(--copper);
    color: #fff;
}

.pagination .page-numbers.dots {
    border-color: transparent;
    color: var(--muted);
}

/* Запись и страница */
.entry-head { margin-bottom: 1.8rem; }

.entry-title { font-size: 2.6rem; margin-bottom: 0.5rem; }

.entry-meta {
    font-size: 0.84rem;
    color: var(--muted);
    letter-spacing: 0.04em;
}

.entry-thumb {
    margin: 0 0 2rem;
}

.entry-thumb img {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 8;
    object-fit: cover;
}

.entry-content { font-size: 1.03rem; }

.entry-content ul,
.entry-content ol { padding-left: 1.3rem; }

.entry-content li { margin-bottom: 0.5rem; }

.entry-content blockquote {
    margin: 1.8rem 0;
    padding: 1.4rem 1.6rem;
    background: var(--bg-alt);
    border-left: 3px solid var(--copper);
    color: #2A3140;
}

.entry-content img { display: block; }

.entry-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 1.6rem 0;
}

.entry-content table,
.entry-content th,
.entry-content td {
    border: 1px solid var(--line);
}

.entry-content th,
.entry-content td {
    padding: 0.65rem 0.85rem;
    text-align: left;
}

.entry-content th { background: var(--bg-alt); }

.tags-row {
    margin-top: 2.2rem;
    font-size: 0.88rem;
    color: var(--muted);
}

/* Главная — секции */
.front-section { padding: 5.5rem 0; position: relative; }

.front-section.alt {
    background-color: var(--bg-alt);
    background-image: var(--paper);
}

.front-section.blot::after {
    content: "";
    position: absolute;
    right: 3%;
    bottom: 6%;
    width: 260px;
    height: 200px;
    pointer-events: none;
    background-repeat: no-repeat;
    background-size: contain;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 260 200'%3E%3Cpath fill='%23C97B4A' fill-opacity='0.06' d='M62 96c-14-24 4-52 32-58 25-6 38 10 60 6 24-5 46-16 63 2 18 19 6 47-8 64-15 18-38 22-52 38-15 17-16 44-38 48-23 4-40-16-49-36-9-19-8-42-8-64z'/%3E%3Cpath fill='%23C97B4A' fill-opacity='0.06' d='M196 152c9-4 20 3 20 13s-11 17-19 13c-9-4-10-22-1-26z'/%3E%3C/svg%3E");
}

/* Блок 1 — Hero */
.fs-hero {
    background: var(--dark);
    padding: 6rem 0;
    overflow: hidden;
    position: relative;
}

.hero-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(0, 0.65fr);
    gap: 2rem;
    align-items: center;
}

.hero-copy { min-width: 0; }

.hero-copy h1 {
    color: #F7F9FC;
    font-size: 3.2rem;
    margin-bottom: 1rem;
}

.hero-copy p {
    color: #9AA5B6;
    font-size: 1.08rem;
    max-width: 620px;
}

.hero-mark {
    min-width: 0;
    display: flex;
    justify-content: center;
    align-items: center;
}

.hero-word {
    writing-mode: vertical-rl;
    transform: rotate(180deg);
    font-family: Inter, "Segoe UI", Arial, sans-serif;
    font-size: 4.6rem;
    font-weight: 800;
    letter-spacing: 0.18em;
    color: var(--copper);
    line-height: 1;
    opacity: 0.92;
}

/* Блок 2 — Таймлайн */
.tl { position: relative; padding-left: 0; }

.tl-item {
    position: relative;
    display: grid;
    grid-template-columns: 92px minmax(0, 1fr);
    gap: 1.6rem;
    padding: 0 0 3.4rem 0;
}

.tl-item:last-child { padding-bottom: 0; }

.tl-item::before {
    content: "";
    position: absolute;
    left: 45px;
    top: 3.2rem;
    bottom: 0;
    width: 1.5px;
    background: var(--line);
}

.tl-item:last-child::before { display: none; }

.tl-num {
    font-family: Inter, "Segoe UI", Arial, sans-serif;
    font-size: 2.6rem;
    font-weight: 700;
    color: var(--copper);
    line-height: 1;
    text-align: right;
    padding-right: 0.4rem;
}

.tl-body { min-width: 0; }

.tl-body h3 { margin-bottom: 0.4rem; font-size: 1.25rem; }

.tl-body p { margin: 0; color: #3C4552; }

/* Блок 3 — Статистика */
.stats-row {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 2rem;
}

.stat { min-width: 0; }

.stat-num {
    font-family: Inter, "Segoe UI", Arial, sans-serif;
    font-size: 3rem;
    font-weight: 700;
    color: var(--steel);
    line-height: 1.05;
}

.stat-bar {
    width: 46px;
    height: 2px;
    background: var(--copper);
    margin: 0.7rem 0 0.8rem;
}

.stat-label {
    color: var(--muted);
    font-size: 0.92rem;
}

/* Блок 4 — Карта тем */
.topic-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.5rem;
}

.topic-tile {
    display: block;
    min-width: 0;
    background: var(--bg);
    border: 1px solid var(--line);
    padding: 2rem 2rem;
    transition: border-color .25s ease, transform .25s ease;
}

.topic-tile:hover {
    border-color: var(--copper);
    transform: translateY(-2px);
}

.topic-name {
    font-family: Inter, "Segoe UI", Arial, sans-serif;
    font-size: 1.35rem;
    font-weight: 700;
    color: var(--ink);
    display: block;
    margin-bottom: 0.35rem;
}

.topic-note {
    font-size: 0.88rem;
    color: var(--muted);
    display: block;
}

/* Блок последних записей на главной */
.fs-latest .card-list { gap: 1.6rem; }

.front-cta-row { margin-top: 2.4rem; }

/* Форма поиска */
.search-form {
    display: flex;
    gap: 0.6rem;
    max-width: 460px;
}

.search-form input[type="search"] {
    flex: 1;
    min-width: 0;
    padding: 0.65em 0.9em;
    border: 1px solid var(--line);
    border-radius: 4px;
    background: #fff;
    font: inherit;
    font-size: 0.95rem;
    color: var(--ink);
}

.search-form input[type="search"]:focus {
    outline: none;
    border-color: var(--copper);
}

.search-form button {
    padding: 0.65em 1.3em;
    border: 1.5px solid var(--copper);
    border-radius: 4px;
    background: transparent;
    color: var(--copper);
    font: inherit;
    font-size: 0.92rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color .25s ease, color .25s ease, transform .15s ease;
}

.search-form button:hover {
    background: var(--copper);
    color: #fff;
    transform: translateY(1px);
}

/* Комментарии */
.comments-area {
    margin-top: 3.4rem;
    padding-top: 2.4rem;
    border-top: 1px solid var(--line);
}

.comment-list {
    list-style: none;
    margin: 0 0 2.4rem;
    padding: 0;
}

.comment-list ol {
    list-style: none;
    padding-left: 1.6rem;
}

.comment-body {
    border: 1px solid var(--line);
    padding: 1.2rem 1.4rem;
    margin-bottom: 1.2rem;
    background: #fff;
}

.comment-meta {
    font-size: 0.82rem;
    color: var(--muted);
    margin-bottom: 0.5rem;
}

.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea {
    width: 100%;
    padding: 0.6em 0.85em;
    border: 1px solid var(--line);
    border-radius: 4px;
    background: #fff;
    font: inherit;
    font-size: 0.95rem;
    color: var(--ink);
}

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

.comment-form p { margin-bottom: 1rem; }

.comment-form .submit {
    padding: 0.7em 1.6em;
    border: 1.5px solid var(--copper);
    border-radius: 4px;
    background: transparent;
    color: var(--copper);
    font: inherit;
    font-weight: 600;
    cursor: pointer;
    transition: background-color .25s ease, color .25s ease, transform .15s ease;
}

.comment-form .submit:hover {
    background: var(--copper);
    color: #fff;
    transform: translateY(1px);
}

/* 404 */
.err-code {
    font-family: Inter, "Segoe UI", Arial, sans-serif;
    font-size: 5rem;
    font-weight: 700;
    color: var(--steel);
    line-height: 1;
    margin-bottom: 0.6rem;
}

/* Подвал */
.site-foot {
    background: var(--dark);
    color: #C6CEDA;
    padding: 3.6rem 0 2rem;
}

.foot-cols {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 2.6rem;
}

.foot-col { min-width: 0; }

.foot-col .widget { margin-bottom: 1.6rem; color: #C6CEDA; }

.foot-col .widget-title { color: #F4F6F9; }

.foot-col .widget-title::before { background: var(--copper); }

.foot-col .widget a { color: #D6DDE7; }

.foot-col .widget a:hover { color: var(--copper); }

.foot-col .widget li { border-bottom: 1px solid #2A303E; }

.foot-col .widget .post-date { color: #8E99AA; }

.foot-bottom {
    margin-top: 2.6rem;
    padding-top: 1.4rem;
    border-top: 1px solid #2A303E;
    font-size: 0.85rem;
    color: #8E99AA;
}

/* Cookie-баннер */
.cookie-banner[hidden] { display: none !important; }

.cookie-banner {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 950;
    background: var(--dark);
    color: #D6DDE7;
    padding: 1rem 0;
    border-top: 2px solid var(--copper);
}

.cookie-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.4rem;
    flex-wrap: wrap;
}

.cookie-inner p {
    margin: 0;
    font-size: 0.88rem;
    max-width: 780px;
}

.cookie-inner a { color: var(--copper); }

/* Адаптив */
@media (max-width: 960px) {
    h1 { font-size: 2.4rem; }
    .hero-copy h1 { font-size: 2.4rem; }
    .hero-word { font-size: 3.2rem; }
    .layout-with-sidebar {
        grid-template-columns: minmax(0, 1fr);
        gap: 3rem;
    }
    .sidebar {
        border-left: 0;
        border-top: 1px solid var(--line);
        padding-left: 0;
        padding-top: 2rem;
    }
    .layout-single { width: 100%; }
    .stats-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .foot-cols { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 600px) {
    body { font-size: 16px; }
    h1 { font-size: 2rem; }
    h2 { font-size: 1.6rem; }
    .hero-copy h1 { font-size: 2rem; }
    .sec-title { font-size: 1.6rem; margin-left: 22px; }
    .sec-title::before { left: -22px; }
    .front-section { padding: 3.4rem 0; }
    .fs-hero { padding: 3.4rem 0; }
    .front-section.blot::after { display: none; }
    .hero-grid { grid-template-columns: minmax(0, 1fr); }
    .hero-mark { justify-content: flex-start; }
    .hero-word {
        writing-mode: horizontal-tb;
        transform: none;
        font-size: 2.6rem;
        letter-spacing: 0.22em;
    }
    .nav-toggle { display: inline-block; }
    .site-nav { width: 100%; }
    .site-nav[hidden] { display: none !important; }
    .site-nav ul {
        flex-direction: column;
        gap: 0.2rem;
        margin-top: 1rem;
    }
    .site-nav li {
        border-bottom: 1px solid #2A303E;
        padding: 0.55rem 0;
    }
    .card-row { flex-direction: column; }
    .card-thumb-wrap {
        flex: none;
        width: 100%;
        position: static;
        min-height: 0;
    }
    .card-thumb-wrap a { position: static; }
    .card-thumb-wrap img {
        width: 100%;
        height: auto;
        aspect-ratio: 16 / 9;
    }
    .card-body { padding: 1.2rem 1.2rem; }
    .entry-title { font-size: 1.9rem; }
    .stats-row { grid-template-columns: minmax(0, 1fr); gap: 1.6rem; }
    .topic-grid { grid-template-columns: minmax(0, 1fr); }
    .topic-tile { padding: 1.5rem 1.4rem; }
    .foot-cols { grid-template-columns: minmax(0, 1fr); gap: 2rem; }
    .tl-item {
        grid-template-columns: 56px minmax(0, 1fr);
        gap: 1rem;
        padding-bottom: 2.4rem;
    }
    .tl-item::before { left: 27px; top: 2.6rem; }
    .tl-num { font-size: 1.9rem; }
    .entry-content blockquote { padding: 1.1rem 1.2rem; }
    .cookie-inner { gap: 0.9rem; }
}
