/*
Theme Name: weebr-ru
Theme URI: https://weebr.ru/
Author: Илья Казаков
Author URI: https://weebr.ru/
Description: Тема для сайта о создании сайтов: тёмная «стена» с чертёжной сеткой и светлые листы кальки с уроками — от идеи и дизайна до вёрстки и запуска.
Version: 1.1
Requires at least: 6.0
Requires PHP: 8.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: weebr-ru
*/

:root {
    --ink: #14121C;
    --wall: #2A2740;
    --paper: #EDEDF7;
    --mint: #DCE9E2;
    --blue: #5BC8E8;
    --muted: #6C6A80;
    --lime: #C6F73A;
    --rasp: #FF4D6D;
    --font-head: 'Oswald', 'Arial Narrow', sans-serif;
    --font-body: 'Inter', 'Segoe UI', Arial, sans-serif;
    --font-mono: 'JetBrains Mono', 'Courier New', monospace;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    overflow-x: hidden;
    background-color: var(--ink);
    background-image:
        linear-gradient(var(--wall) 1px, transparent 1px),
        linear-gradient(90deg, var(--wall) 1px, transparent 1px);
    background-size: 44px 44px;
    color: var(--paper);
    font-family: var(--font-body);
    font-size: 1rem;
    line-height: 1.6;
}

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

a {
    color: var(--blue);
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 3px;
}

a:hover {
    color: var(--lime);
}

h1, h2, h3, h4 {
    font-family: var(--font-head);
    text-transform: uppercase;
    line-height: 1.15;
    overflow-wrap: break-word;
    hyphens: auto;
}

p, li, td, th {
    overflow-wrap: break-word;
    hyphens: auto;
}

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

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

.skip-link {
    position: absolute;
    left: -9999px;
    top: 0;
    background: var(--lime);
    color: var(--ink);
    padding: 0.6rem 1rem;
    font-weight: 600;
    z-index: 100;
}

.skip-link:focus {
    left: 0;
}

/* ---------- Шапка ---------- */

.site-header {
    background: var(--ink);
    border-bottom: 2px solid var(--wall);
    padding: 1rem 0;
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
}

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

.brand-link {
    display: block;
    flex: 0 0 auto;
}

.brand-logo {
    display: block;
    width: 52px;
    height: 52px;
}

.brand-logo-svg {
    display: block;
}

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

.brand-name {
    font-family: var(--font-head);
    font-size: 1.8rem;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--paper);
    text-decoration: none;
    line-height: 1.1;
}

.brand-name:hover {
    color: var(--lime);
}

.brand-desc {
    margin: 0.15rem 0 0;
    font-size: 0.8rem;
    color: var(--muted);
    line-height: 1.4;
}

.nav-list {
    display: flex;
    gap: 1.6rem;
    list-style: none;
    margin: 0;
    padding: 0;
}

.nav-list a {
    color: var(--paper);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    padding-bottom: 0.2rem;
    border-bottom: 3px solid transparent;
}

.nav-list a:hover,
.nav-list .current-menu-item > a,
.nav-list .current_page_item > a {
    color: var(--paper);
    border-bottom-color: var(--lime);
}

.menu-toggle {
    display: none;
    background: none;
    border: 2px solid var(--paper);
    color: var(--paper);
    font-family: var(--font-body);
    font-size: 0.95rem;
    padding: 0.5rem 0.9rem;
    cursor: pointer;
    align-items: center;
    gap: 0.5rem;
}

.menu-toggle-bars {
    display: inline-block;
    width: 16px;
    height: 2px;
    background: var(--lime);
    box-shadow: 0 -5px 0 var(--lime), 0 5px 0 var(--lime);
}

/* ---------- Листы ---------- */

.front-main {
    padding: 3rem 0 4rem;
}

.sheet {
    position: relative;
    border: 1px solid var(--ink);
    box-shadow: 12px 14px 0 rgba(0, 0, 0, 0.35);
    padding: 2.5rem 2.2rem;
    color: var(--ink);
    margin-bottom: 3.5rem;
}

.sheet-paper {
    background-color: var(--paper);
    background-image:
        linear-gradient(rgba(91, 200, 232, 0.16) 1px, transparent 1px),
        linear-gradient(90deg, rgba(91, 200, 232, 0.16) 1px, transparent 1px);
    background-size: 28px 28px;
}

.sheet-mint {
    background-color: var(--mint);
    background-image:
        linear-gradient(rgba(91, 200, 232, 0.22) 1px, transparent 1px),
        linear-gradient(90deg, rgba(91, 200, 232, 0.22) 1px, transparent 1px);
    background-size: 28px 28px;
}

.sheet-flat {
    transform: none;
}

.tilt-left {
    transform: rotate(-0.6deg);
}

.tilt-right {
    transform: rotate(0.5deg);
}

.pin {
    position: absolute;
    top: -9px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: radial-gradient(circle at 35% 30%, #f2f2f8 0%, #9a97ab 45%, #4d4a5e 100%);
    box-shadow: 0 2px 3px rgba(0, 0, 0, 0.5);
}

.pin-tl {
    left: 22px;
}

.pin-tr {
    right: 22px;
}

.sheet-title {
    display: inline-flex;
    align-items: center;
    gap: 0.7rem;
    border: 2px solid var(--ink);
    background: var(--paper);
    padding: 0.35rem 1rem 0.35rem 0.4rem;
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0 0 1.8rem;
    transform: rotate(-0.8deg);
}

.sheet-mint .sheet-title {
    background: var(--mint);
}

.sheet-num {
    font-family: var(--font-mono);
    font-size: 1.05rem;
    font-weight: 500;
    border: 2px solid var(--ink);
    padding: 0.1rem 0.45rem;
    background: var(--paper);
}

.sheet-mint .sheet-num {
    background: var(--mint);
}

/* Декоративные размерные стрелки */
.dim-arrow {
    position: absolute;
    pointer-events: none;
}

.dim-arrow-v {
    right: -34px;
    top: 60px;
    width: 22px;
    height: 150px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='22' height='150'%3E%3Cline x1='11' y1='8' x2='11' y2='142' stroke='%23FF4D6D' stroke-width='2'/%3E%3Cpath d='M4 14 L11 4 L18 14' fill='none' stroke='%23FF4D6D' stroke-width='2'/%3E%3Cpath d='M4 136 L11 146 L18 136' fill='none' stroke='%23FF4D6D' stroke-width='2'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
}

.dim-arrow-h {
    left: 40px;
    bottom: -30px;
    width: 150px;
    height: 22px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='150' height='22'%3E%3Cline x1='8' y1='11' x2='142' y2='11' stroke='%23FF4D6D' stroke-width='2'/%3E%3Cpath d='M14 4 L4 11 L14 18' fill='none' stroke='%23FF4D6D' stroke-width='2'/%3E%3Cpath d='M136 4 L146 11 L136 18' fill='none' stroke='%23FF4D6D' stroke-width='2'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
}

/* ---------- Кнопки ---------- */

.btn {
    display: inline-block;
    background: var(--lime);
    color: var(--ink);
    border: 2px solid var(--ink);
    box-shadow: 5px 5px 0 var(--ink);
    padding: 0.65rem 1.6rem;
    font-family: var(--font-body);
    font-weight: 600;
    font-size: 0.95rem;
    text-decoration: none;
    text-align: center;
    cursor: pointer;
}

.btn:hover {
    background: var(--ink);
    color: var(--lime);
    box-shadow: 2px 2px 0 var(--lime);
    transform: translate(3px, 3px);
}

/* ---------- Блок 01: маршрут ---------- */

.route {
    padding: 0 0.5rem;
}

.route-line {
    display: block;
    width: 100%;
    height: 90px;
}

.route-path {
    stroke: var(--lime);
    stroke-width: 6;
    stroke-linejoin: round;
    stroke-linecap: round;
}

.route-path-dash {
    stroke: var(--ink);
    stroke-width: 1.6;
    stroke-dasharray: 8 7;
}

.route-dot {
    fill: var(--lime);
    stroke: var(--ink);
    stroke-width: 2.5;
}

.route-stops {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    list-style: none;
    margin: 0.6rem 0 0;
    padding: 0;
    counter-reset: stop;
}

.route-stop {
    text-align: center;
    padding: 0 0.4rem;
    min-width: 0;
}

.route-name {
    display: block;
    font-family: var(--font-head);
    font-weight: 700;
    font-size: 1.25rem;
    text-transform: uppercase;
    color: var(--ink);
}

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

/* ---------- Блок 02: анатомия ---------- */

.anatomy {
    display: grid;
    grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
    gap: 2.2rem;
    align-items: start;
}

.anatomy-tabs {
    display: flex;
    gap: 1.1rem;
    min-width: 0;
}

.tab-list {
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
    flex: 0 0 auto;
}

.tab-btn {
    font-family: var(--font-head);
    font-weight: 600;
    font-size: 0.95rem;
    text-transform: uppercase;
    background: var(--paper);
    color: var(--ink);
    border: 2px solid var(--ink);
    padding: 0.5rem 1rem;
    cursor: pointer;
    text-align: left;
    writing-mode: vertical-rl;
    transform: rotate(180deg);
}

.tab-btn:hover {
    background: var(--lime);
}

.tab-btn.is-active {
    background: var(--lime);
    box-shadow: 4px 4px 0 var(--ink);
}

.tab-panels {
    min-width: 0;
    border-left: 2px solid var(--ink);
    padding-left: 1.3rem;
}

.tab-panel[hidden] {
    display: none !important;
}

.tab-heading {
    font-size: 1.3rem;
    margin: 0 0 0.6rem;
}

.tab-panel p {
    margin: 0 0 0.8rem;
}

.anatomy-figure {
    margin: 0;
    min-width: 0;
}

.anatomy-figure img {
    display: block;
    width: 100%;
    aspect-ratio: 1372 / 1058;
    object-fit: contain;
}

/* ---------- Последние записи ---------- */

.latest {
    margin-bottom: 3.5rem;
}

.latest-title {
    color: var(--paper);
    font-size: 2.1rem;
    font-weight: 700;
    margin: 0 0 1.6rem;
}

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

.card {
    display: flex;
    flex-direction: column;
    background: var(--paper);
    border: 2px solid var(--ink);
    box-shadow: 8px 9px 0 rgba(0, 0, 0, 0.35);
    color: var(--ink);
    min-width: 0;
}

.card-strip {
    background: var(--lime);
    border-bottom: 2px solid var(--ink);
    min-height: 2.1rem;
    padding: 0.15rem 0.9rem;
    font-family: var(--font-head);
    font-weight: 700;
    font-size: 1.1rem;
}

.card-thumb {
    border-bottom: 2px solid var(--ink);
    background: var(--paper);
}

.card-thumb img {
    display: block;
    width: 100%;
    aspect-ratio: 5 / 3;
    object-fit: cover;
}

.card-thumb-empty {
    padding: 0.8rem 1rem;
    background-image:
        linear-gradient(rgba(91, 200, 232, 0.18) 1px, transparent 1px),
        linear-gradient(90deg, rgba(91, 200, 232, 0.18) 1px, transparent 1px);
    background-size: 22px 22px;
}

.card-thumb-empty svg {
    display: block;
    width: 100%;
    aspect-ratio: 5 / 3;
}

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

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

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

.card-title a:hover {
    color: var(--ink);
    text-decoration: underline;
    text-decoration-color: var(--rasp);
}

.card-excerpt {
    font-size: 0.92rem;
}

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

.card-meta {
    margin: auto 0 0.9rem;
    padding-top: 0.4rem;
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--muted);
}

.card-btn {
    align-self: flex-start;
}

/* ---------- Блок 03: паспорт ---------- */

.passport {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 2.2rem;
    align-items: start;
}

.passport-table {
    width: 100%;
    border-collapse: collapse;
    background: var(--paper);
}

.passport-table th,
.passport-table td {
    border: 2px solid var(--ink);
    padding: 0.55rem 0.9rem;
    text-align: left;
    font-size: 0.95rem;
}

.passport-table th {
    font-family: var(--font-head);
    text-transform: uppercase;
    font-weight: 600;
    background: var(--lime);
}

.palette {
    display: grid;
    grid-template-columns: repeat(2, 84px);
    gap: 0.7rem;
}

.swatch {
    display: block;
    width: 84px;
    height: 84px;
    border: 2px solid var(--ink);
    box-shadow: 4px 4px 0 rgba(20, 18, 28, 0.55);
}

.swatch-ink {
    background: var(--ink);
}

.swatch-paper {
    background: var(--paper);
}

.swatch-lime {
    background: var(--lime);
}

.swatch-rasp {
    background: var(--rasp);
}

.palette-caption {
    margin: 0.7rem 0 1.1rem;
    font-size: 0.9rem;
    color: var(--muted);
}

.code-line {
    margin: 0;
    font-family: var(--font-mono);
    font-size: 0.85rem;
    background: var(--ink);
    color: var(--lime);
    border: 2px solid var(--ink);
    padding: 0.9rem 1.1rem;
    overflow-x: auto;
}

/* ---------- Блок 04: ошибки ---------- */

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

.mistake {
    display: grid;
    grid-template-columns: auto auto;
    justify-content: center;
    gap: 2.4rem;
    align-items: center;
    padding: 0.55rem 0.2rem;
    border-bottom: 1px dashed rgba(20, 18, 28, 0.35);
}

.mistake:last-child {
    border-bottom: none;
}

.mistake-bad {
    font-family: var(--font-head);
    font-weight: 600;
    font-size: 1.1rem;
    text-transform: uppercase;
    color: var(--ink);
    text-decoration: line-through;
    text-decoration-color: var(--rasp);
    text-decoration-thickness: 3px;
    text-align: right;
}

.mark-x {
    color: var(--rasp);
    text-decoration: none;
    display: inline-block;
    font-weight: 700;
}

.mistake-good {
    font-family: var(--font-head);
    font-weight: 600;
    font-size: 1.1rem;
    text-transform: uppercase;
    color: var(--ink);
}

.mark-ok {
    color: var(--lime);
    background: var(--ink);
    padding: 0 0.35rem;
    margin-right: 0.3rem;
}

.mistake-note {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    margin: 1.6rem 0 0;
}

.mistake-note-text {
    color: var(--rasp);
    font-family: var(--font-mono);
    font-style: italic;
    font-size: 1.05rem;
    border-bottom: 2px solid var(--rasp);
}

/* ---------- Внутренние страницы ---------- */

.site-main {
    padding: 2.5rem 0 3.5rem;
}

.front-main.site-main {
    padding: 3rem 0 4rem;
}

.page-title {
    color: var(--paper);
    font-size: 2.2rem;
    font-weight: 700;
    margin: 0 0 1.6rem;
}

.layout-with-sidebar {
    display: flex;
    justify-content: space-between;
    gap: 2rem;
    align-items: flex-start;
}

.layout-with-sidebar .content-area {
    flex: 0 0 67%;
    min-width: 0;
}

.layout-with-sidebar .sidebar {
    flex: 0 0 27%;
    min-width: 0;
}

.layout-single {
    display: block;
}

.layout-single .content-area {
    width: 85%;
    margin-left: auto;
    margin-right: auto;
}

.entry {
    margin-bottom: 2rem;
}

.entry-title {
    font-size: 2rem;
    margin: 0 0 0.6rem;
}

.entry-meta {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    color: var(--muted);
    margin: 0 0 1.4rem;
}

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

.entry-thumb img {
    display: block;
    width: 100%;
    border: 2px solid var(--ink);
}

.entry-content p {
    margin: 0 0 1em;
}

.entry-content h2,
.entry-content h3,
.entry-content h4 {
    margin: 1.4em 0 0.6em;
}

.entry-content ul,
.entry-content ol {
    margin: 0 0 1em;
    padding-left: 1.4rem;
}

.entry-content blockquote {
    margin: 1.4em 0;
    padding: 1rem 1.4rem;
    border-left: 4px solid var(--rasp);
    background: rgba(91, 200, 232, 0.12);
    font-style: italic;
}

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

.entry-content table th,
.entry-content table td {
    border: 2px solid var(--ink);
    padding: 0.5rem 0.8rem;
    text-align: left;
}

.entry-content table th {
    background: var(--lime);
    font-family: var(--font-head);
    text-transform: uppercase;
}

.entry-content a {
    color: #1d7a96;
}

.entry-content code {
    font-family: var(--font-mono);
    font-size: 0.9em;
    background: rgba(20, 18, 28, 0.08);
    padding: 0.1em 0.35em;
}

.entry-content pre {
    background: var(--ink);
    color: var(--lime);
    padding: 1rem 1.2rem;
    overflow-x: auto;
    border: 2px solid var(--ink);
}

.entry-content pre code {
    background: none;
    padding: 0;
    color: inherit;
}

.page-links {
    margin-top: 1.2rem;
    font-family: var(--font-mono);
}

.empty-note {
    margin: 0;
}

/* ---------- Хлебные крошки ---------- */

.breadcrumbs {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    color: var(--muted);
    margin-bottom: 1.4rem;
}

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

.breadcrumbs .sep {
    color: var(--rasp);
    margin: 0 0.35rem;
}

/* ---------- Пагинация ---------- */

.pagination {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
    margin-top: 2.2rem;
}

.page-numbers {
    display: inline-block;
    min-width: 2.4rem;
    padding: 0.45rem 0.7rem;
    text-align: center;
    background: var(--paper);
    color: var(--ink);
    border: 2px solid var(--ink);
    box-shadow: 3px 3px 0 var(--ink);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
}

.page-numbers:hover {
    background: var(--lime);
    color: var(--ink);
}

.page-numbers.current {
    background: var(--lime);
    color: var(--ink);
    box-shadow: none;
    transform: translate(2px, 2px);
}

.page-numbers.dots {
    border: none;
    background: none;
    box-shadow: none;
    color: var(--paper);
}

.page-numbers.prev,
.page-numbers.next {
    font-weight: 600;
}

/* ---------- Сайдбар ---------- */

.sidebar {
    background-color: var(--mint);
    background-image:
        linear-gradient(rgba(91, 200, 232, 0.22) 1px, transparent 1px),
        linear-gradient(90deg, rgba(91, 200, 232, 0.22) 1px, transparent 1px);
    background-size: 28px 28px;
    border: 1px solid var(--ink);
    box-shadow: 8px 9px 0 rgba(0, 0, 0, 0.35);
    padding: 1.4rem 1.3rem;
    color: var(--ink);
}

.sidebar .widget {
    color: var(--ink);
    margin-bottom: 1.6rem;
}

.sidebar .widget:last-child {
    margin-bottom: 0;
}

.sidebar .widget-title {
    font-size: 1.05rem;
    margin: 0 0 0.8rem;
    border-bottom: 2px solid var(--ink);
    padding-bottom: 0.4rem;
}

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

.sidebar .widget li {
    margin-bottom: 0.55rem;
}

.sidebar .widget a {
    color: var(--ink);
    text-decoration: none;
    border-bottom: 1px solid var(--blue);
}

.sidebar .widget a:hover {
    color: var(--ink);
    border-bottom-color: var(--rasp);
}

/* ---------- Подвал ---------- */

.site-footer {
    background: var(--ink);
    border-top: 2px solid var(--wall);
    padding: 2.6rem 0 1.6rem;
    margin-top: 2rem;
}

.footer-inner {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 2rem;
}

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

.site-footer .widget-title {
    color: var(--paper);
    font-size: 1.05rem;
    margin: 0 0 0.9rem;
}

.site-footer .widget {
    color: #C9C7D8;
    font-size: 0.92rem;
}

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

.site-footer .widget li {
    margin-bottom: 0.5rem;
}

.site-footer .widget a {
    color: var(--blue);
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 3px;
}

.site-footer .widget a:hover {
    color: var(--lime);
}

.footer-copy {
    margin-top: 2.2rem;
    padding-top: 1.2rem;
    border-top: 1px solid var(--wall);
    text-align: center;
}

.footer-copy p {
    margin: 0;
    color: var(--muted);
    font-size: 0.85rem;
}

/* ---------- Поиск ---------- */

.search-form {
    margin: 1rem 0;
}

.search-label {
    display: block;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: inherit;
}

.search-row {
    display: flex;
    gap: 0.7rem;
}

.search-input {
    flex: 1;
    min-width: 0;
    border: 2px solid var(--ink);
    background: var(--paper);
    color: var(--ink);
    padding: 0.6rem 0.9rem;
    font-family: var(--font-body);
    font-size: 0.95rem;
}

.sidebar .search-input {
    background: #ffffff;
}

.search-btn {
    flex: 0 0 auto;
}

/* ---------- Комментарии ---------- */

.comments-area {
    background: var(--paper);
    border: 1px solid var(--ink);
    box-shadow: 8px 9px 0 rgba(0, 0, 0, 0.35);
    color: var(--ink);
    padding: 1.8rem 1.6rem;
    margin-top: 2rem;
}

.comments-title {
    margin: 0 0 1.2rem;
    font-size: 1.4rem;
}

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

.comment-list .children {
    list-style: none;
    padding-left: 1.6rem;
    margin-top: 1rem;
}

.comment-item {
    border: 2px solid var(--ink);
    background: #ffffff;
    padding: 1rem 1.2rem;
    margin-bottom: 1rem;
}

.comment-meta {
    display: flex;
    gap: 0.9rem;
    align-items: baseline;
    margin-bottom: 0.5rem;
    flex-wrap: wrap;
}

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

.comment-date {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--muted);
}

.comment-text p {
    margin: 0 0 0.6em;
}

.comment-awaiting {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--rasp);
}

.comment-actions a {
    font-size: 0.85rem;
}

.comments-navigation {
    margin: 1rem 0;
}

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

.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea {
    width: 100%;
    border: 2px solid var(--ink);
    background: #ffffff;
    color: var(--ink);
    padding: 0.55rem 0.8rem;
    font-family: var(--font-body);
    font-size: 0.95rem;
}

.comment-form .submit {
    background: var(--lime);
    color: var(--ink);
    border: 2px solid var(--ink);
    box-shadow: 4px 4px 0 var(--ink);
    padding: 0.6rem 1.5rem;
    font-weight: 600;
    cursor: pointer;
}

.comment-form .submit:hover {
    background: var(--ink);
    color: var(--lime);
    box-shadow: 1px 1px 0 var(--lime);
    transform: translate(2px, 2px);
}

.comment-notes,
.must-log-in {
    font-size: 0.85rem;
    color: var(--muted);
}

/* ---------- 404 ---------- */

.error-404 .search-form {
    max-width: 460px;
}

/* ---------- Навигация между записями ---------- */

.post-navigation {
    margin-bottom: 2rem;
}

.post-navigation .nav-links {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
}

.post-navigation a {
    display: block;
    background: var(--paper);
    color: var(--ink);
    border: 2px solid var(--ink);
    box-shadow: 5px 5px 0 var(--ink);
    padding: 0.7rem 1.1rem;
    text-decoration: none;
    max-width: 48%;
}

.post-navigation a:hover {
    box-shadow: 2px 2px 0 var(--lime);
    transform: translate(2px, 2px);
}

.nav-sub {
    display: block;
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--muted);
    margin-bottom: 0.25rem;
}

.nav-title {
    font-weight: 600;
}

/* ---------- Cookie-баннер ---------- */

.cookie-banner[hidden] {
    display: none !important;
}

.cookie-banner {
    position: fixed;
    left: 1rem;
    right: 1rem;
    bottom: 1rem;
    z-index: 90;
    width: min(92%, 720px);
    margin-inline: auto;
    background: var(--paper);
    color: var(--ink);
    border: 2px solid var(--ink);
    box-shadow: 8px 8px 0 rgba(0, 0, 0, 0.45);
    padding: 1rem 1.2rem;
    display: flex;
    align-items: center;
    gap: 1.2rem;
}

.cookie-text {
    margin: 0;
    font-size: 0.88rem;
    flex: 1;
    min-width: 0;
}

.cookie-accept {
    flex: 0 0 auto;
}

/* ---------- Адаптив ---------- */

@media (max-width: 960px) {
    .cards {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .anatomy {
        grid-template-columns: minmax(0, 1fr);
    }

    .passport {
        grid-template-columns: minmax(0, 1fr);
    }

    .route-stops {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        row-gap: 1.2rem;
    }

    .route-line {
        display: none;
    }

    .footer-inner {
        grid-template-columns: minmax(0, 1fr);
    }

    .layout-with-sidebar {
        flex-direction: column;
    }

    .layout-with-sidebar .content-area,
    .layout-with-sidebar .sidebar {
        flex: none;
        width: 100%;
    }

    .layout-single .content-area {
        width: 100%;
    }

    .dim-arrow {
        display: none;
    }
}

@media (max-width: 600px) {
    .cards {
        grid-template-columns: minmax(0, 1fr);
    }

    .header-inner {
        flex-wrap: wrap;
    }

    .menu-toggle {
        display: inline-flex;
    }

    .site-nav {
        display: none;
        flex: 0 0 100%;
        order: 3;
    }

    .site-nav.is-open {
        display: block;
    }

    .nav-list {
        flex-direction: column;
        gap: 0.2rem;
        padding-top: 0.9rem;
    }

    .nav-list a {
        display: block;
        padding: 0.5rem 0;
    }

    .sheet {
        padding: 1.8rem 1.3rem;
        margin-bottom: 2.4rem;
    }

    .sheet-title {
        font-size: 1.15rem;
    }

    .route-stops {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .anatomy-tabs {
        flex-direction: column;
    }

    .tab-list {
        flex-direction: row;
        flex-wrap: wrap;
    }

    .tab-btn {
        writing-mode: horizontal-tb;
        transform: none;
    }

    .tab-panels {
        border-left: none;
        padding-left: 0;
    }

    .mistake {
        grid-template-columns: minmax(0, 1fr);
        justify-content: stretch;
        gap: 0.3rem;
    }

    .mistake-bad {
        text-align: left;
    }

    .cookie-banner {
        flex-direction: column;
        align-items: stretch;
        text-align: left;
    }

    .tilt-left,
    .tilt-right {
        transform: none;
    }

    .brand-desc {
        display: none;
    }
}
