/*
Theme Name: dds_onchainbandits.com
Author: Артём «Bandy» Леснов
Description: Информационно-аналитический портал и база знаний о блокчейн-играх: практические гайды для новичков, обзоры GameFi-проектов и безопасный старт в NFT-гейминге.
Version: 1.1
Text Domain: ocb
*/

/* ============================================================
   Базовые переменные и палитра (GameFi / NFT — тёмная база,
   фиолетово-золотые акценты «бандитов»)
   ============================================================ */
:root {
    --bg: #0e0b1a;
    --bg-soft: #161127;
    --panel: #1d1733;
    --panel-2: #241c40;
    --ink: #ece9f7;
    --ink-dim: #b7afd4;
    --ink-mute: #8d84ac;
    --line: #2f2750;
    --violet: #8b5cf6;
    --violet-deep: #6d28d9;
    --cyan: #22d3ee;
    --gold: #f5b942;
    --gold-deep: #d99520;
    --danger: #fb7185;
    --radius: 14px;
    --radius-sm: 9px;
    --shell: min(92%, 1180px);
    --shadow: 0 18px 44px rgba(0, 0, 0, 0.45);
    --shadow-sm: 0 8px 22px rgba(0, 0, 0, 0.3);
    --sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
    --display: "Space Grotesk", "Inter", -apple-system, Segoe UI, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    margin: 0;
    padding: 0;
    background: var(--bg);
    color: var(--ink);
    font-family: var(--sans);
    font-size: 17px;
    line-height: 1.7;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

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

a { color: var(--cyan); text-decoration: none; }
a:hover { text-decoration: underline; }

h1, h2, h3, h4, h5 {
    font-family: var(--display);
    line-height: 1.2;
    color: #fff;
    margin: 0 0 0.5em;
    letter-spacing: -0.01em;
}
h1 { font-size: 2.2rem; }
h2 { font-size: 1.7rem; }
h3 { font-size: 1.3rem; }

p { margin: 0 0 1.1em; }

ul, ol { margin: 0 0 1.1em; padding-left: 1.3em; }
li { margin: 0.3em 0; }

blockquote {
    margin: 1.4em 0;
    padding: 0.8em 1.2em;
    border-left: 4px solid var(--gold);
    background: var(--panel);
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
    color: var(--ink-dim);
}

code, pre {
    font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
    background: #0b0817;
    border-radius: 6px;
}
code { padding: 0.15em 0.4em; font-size: 0.9em; color: var(--gold); }
pre {
    padding: 1em;
    overflow-x: auto;
    border: 1px solid var(--line);
    margin: 1.2em 0;
    min-width: 0;
}
pre code { background: none; padding: 0; color: var(--ink); }

table {
    width: 100%;
    border-collapse: collapse;
    margin: 1.4em 0;
    border: 1px solid var(--line);
    font-size: 0.96rem;
}
th, td {
    border: 1px solid var(--line);
    padding: 0.6em 0.85em;
    text-align: left;
}
th { background: var(--panel-2); color: #fff; font-family: var(--display); }
td { color: var(--ink-dim); }

hr { border: none; border-top: 1px solid var(--line); margin: 2em 0; }

/* ============================================================
   Контейнер ширины — единый источник
   ============================================================ */
.shell {
    width: var(--shell);
    margin-inline: auto;
}

/* ============================================================
   Шапка
   ============================================================ */
.site-header {
    background: linear-gradient(180deg, #140f26 0%, var(--bg) 100%);
    border-bottom: 1px solid var(--line);
}
.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 20px 0;
    flex-wrap: wrap;
}
.brand {
    display: flex;
    align-items: center;
    gap: 14px;
    min-width: 0;
}
.brand-logo { display: block; height: 52px; width: auto; }
.brand svg.brand-logo { height: 52px; width: 52px; }
.brand-text { min-width: 0; }
.brand-name {
    font-family: var(--display);
    font-weight: 700;
    font-size: 1.25rem;
    color: #fff;
    line-height: 1.15;
    display: block;
    max-width: 42ch;
}
.brand-name a { color: #fff; }
.brand-name a:hover { text-decoration: none; color: var(--gold); }
.brand-desc {
    color: var(--ink-mute);
    font-size: 0.8rem;
    margin-top: 4px;
    max-width: 46ch;
    line-height: 1.4;
}

/* Навигация */
.main-nav { margin-left: auto; }
.menu-toggle {
    display: none;
    background: var(--panel-2);
    color: var(--ink);
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    padding: 10px 14px;
    font-size: 0.95rem;
    cursor: pointer;
    font-family: var(--display);
}
.nav-list {
    list-style: none;
    display: flex;
    gap: 6px;
    margin: 0;
    padding: 0;
    flex-wrap: wrap;
}
.nav-list a {
    display: block;
    padding: 9px 15px;
    color: var(--ink-dim);
    border-radius: var(--radius-sm);
    font-family: var(--display);
    font-weight: 500;
    font-size: 0.97rem;
    transition: background 0.15s, color 0.15s;
}
.nav-list a:hover {
    background: var(--panel-2);
    color: #fff;
    text-decoration: none;
}
.nav-list .current-menu-item > a {
    background: var(--violet-deep);
    color: #fff;
}

/* ============================================================
   Основной макет
   ============================================================ */
.site-main { padding: 38px 0 56px; }

.layout-with-sidebar {
    display: grid;
    grid-template-columns: minmax(0, 67fr) minmax(0, 27fr);
    gap: 40px;
    align-items: start;
}
.layout-single .content-area {
    width: 85%;
    margin-left: auto;
    margin-right: auto;
}
.layout-single { display: block; }

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

/* ============================================================
   Хлебные крошки
   ============================================================ */
.breadcrumbs {
    font-size: 0.85rem;
    color: var(--ink-mute);
    margin-bottom: 22px;
    line-height: 1.5;
}
.breadcrumbs a { color: var(--ink-dim); }
.breadcrumbs a:hover { color: var(--gold); }
.breadcrumbs .sep { margin: 0 7px; color: var(--violet); }
.breadcrumbs span { color: var(--ink); }

/* ============================================================
   Карточки записей
   ============================================================ */
.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 26px;
}
.card {
    display: flex;
    flex-direction: column;
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    overflow: hidden;
    transition: transform 0.18s, border-color 0.18s;
}
.card:hover {
    transform: translateY(-4px);
    border-color: var(--violet);
}
.card-thumb {
    display: block;
    aspect-ratio: 16 / 9;
    overflow: hidden;
}
.card-thumb img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.card-thumb-ph {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    background: linear-gradient(135deg, var(--violet-deep), var(--panel-2));
}
.card-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    padding: 18px 20px 20px;
}
.card-meta {
    font-size: 0.78rem;
    color: var(--ink-mute);
    margin-bottom: 8px;
    font-family: var(--display);
    letter-spacing: 0.02em;
}
.card-title {
    font-size: 1.18rem;
    margin: 0 0 10px;
}
.card-title a { color: #fff; }
.card-title a:hover { color: var(--gold); text-decoration: none; }
.card-excerpt {
    color: var(--ink-dim);
    font-size: 0.95rem;
    flex: 1;
}
.card-excerpt p { margin: 0 0 0.5em; background: none; }
.card-more {
    margin-top: 14px;
    align-self: flex-start;
    display: inline-block;
    padding: 8px 16px;
    background: transparent;
    border: 1px solid var(--violet);
    color: var(--ink);
    border-radius: var(--radius-sm);
    font-family: var(--display);
    font-size: 0.88rem;
    font-weight: 500;
    transition: background 0.15s, color 0.15s;
}
.card-more:hover {
    background: var(--violet);
    color: #fff;
    text-decoration: none;
}

/* ============================================================
   Одиночная запись / страница
   ============================================================ */
.entry {
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 32px 36px 38px;
}
.entry-header { margin-bottom: 22px; }
.entry-title { font-size: 2rem; margin-bottom: 10px; }
.entry-meta {
    color: var(--ink-mute);
    font-size: 0.85rem;
    font-family: var(--display);
}
.entry-thumb {
    margin: 0 0 26px;
    border-radius: var(--radius);
    overflow: hidden;
    border: 1px solid var(--line);
}
.entry-thumb img { display: block; width: 100%; height: auto; }
.entry-content { color: var(--ink-dim); }
.entry-content h2,
.entry-content h3 { margin-top: 1.4em; }
.entry-content img { border-radius: var(--radius-sm); }
.entry-content a { color: var(--cyan); }

.entry-footer {
    margin-top: 26px;
    padding-top: 18px;
    border-top: 1px solid var(--line);
    font-size: 0.88rem;
    color: var(--ink-mute);
}
.entry-footer a {
    color: var(--ink-dim);
    background: var(--panel-2);
    padding: 4px 10px;
    border-radius: 6px;
    display: inline-block;
    margin: 3px 4px 3px 0;
    font-size: 0.82rem;
}
.entry-footer a:hover { color: var(--gold); text-decoration: none; }

/* ============================================================
   Сайдбар + виджеты
   ============================================================ */
.sidebar { min-width: 0; }
.widget {
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 20px 22px;
    margin-bottom: 24px;
    color: var(--ink-dim);
}
.widget-title {
    font-family: var(--display);
    font-size: 1.05rem;
    color: #fff;
    margin: 0 0 14px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--line);
}
.widget a { color: var(--cyan); }
.widget a:hover { color: var(--gold); }
.widget ul { list-style: none; margin: 0; padding: 0; }
.widget li {
    margin: 0;
    padding: 9px 0;
    border-bottom: 1px solid var(--line);
}
.widget li:last-child { border-bottom: none; }
.widget .post-date {
    display: block;
    font-size: 0.76rem;
    color: var(--ink-mute);
    margin-top: 3px;
    font-family: var(--display);
}

/* ============================================================
   Главная
   ============================================================ */
.front-section { margin-bottom: 56px; }

.hero {
    background:
        radial-gradient(900px 400px at 80% -10%, rgba(139, 92, 246, 0.35), transparent 60%),
        radial-gradient(700px 360px at 0% 120%, rgba(245, 185, 66, 0.16), transparent 55%),
        var(--bg-soft);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 54px 46px;
}
.hero h1 { font-size: 2.6rem; max-width: 18ch; }
.hero p { color: var(--ink-dim); font-size: 1.1rem; max-width: 60ch; }
.hero-tag {
    display: inline-block;
    font-family: var(--display);
    font-size: 0.8rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--gold);
    background: rgba(245, 185, 66, 0.1);
    border: 1px solid rgba(245, 185, 66, 0.3);
    padding: 6px 14px;
    border-radius: 999px;
    margin-bottom: 18px;
}
.hero-cta {
    display: inline-block;
    margin-top: 12px;
    padding: 13px 26px;
    background: linear-gradient(135deg, var(--violet), var(--violet-deep));
    color: #fff;
    border-radius: var(--radius-sm);
    font-family: var(--display);
    font-weight: 600;
    box-shadow: var(--shadow-sm);
}
.hero-cta:hover { text-decoration: none; filter: brightness(1.08); }

.section-head { margin-bottom: 26px; }
.section-head .eyebrow {
    font-family: var(--display);
    font-size: 0.8rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--cyan);
}
.section-head h2 { font-size: 2rem; margin-top: 6px; }
.section-head p { color: var(--ink-mute); max-width: 64ch; }

.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 24px;
}
.feature-card {
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 26px 24px;
    min-width: 0;
}
.feature-card .ico {
    width: 46px;
    height: 46px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--panel-2);
    margin-bottom: 14px;
}
.feature-card h3 { font-size: 1.15rem; }
.feature-card p { color: var(--ink-dim); font-size: 0.95rem; margin-bottom: 0; }

.steps {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 22px;
    counter-reset: step;
}
.step {
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 24px 22px;
    position: relative;
    min-width: 0;
}
.step::before {
    counter-increment: step;
    content: counter(step);
    font-family: var(--display);
    font-weight: 700;
    font-size: 1.4rem;
    color: var(--bg);
    background: var(--gold);
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 14px;
}
.step h3 { font-size: 1.1rem; }
.step p { color: var(--ink-dim); font-size: 0.93rem; margin-bottom: 0; }

.front-posts-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 24px;
    flex-wrap: wrap;
}
.front-posts-head a.more-link {
    font-family: var(--display);
    font-size: 0.9rem;
    color: var(--cyan);
}

/* ============================================================
   Пагинация
   ============================================================ */
.pagination {
    margin-top: 38px;
    display: flex;
    justify-content: center;
}
.pagination .page-numbers {
    display: flex;
    gap: 8px;
    list-style: none;
    margin: 0;
    padding: 0;
    flex-wrap: wrap;
}
.pagination .page-numbers li { margin: 0; }
.pagination .page-numbers a,
.pagination .page-numbers span {
    display: block;
    min-width: 42px;
    text-align: center;
    padding: 10px 13px;
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    color: var(--ink-dim);
    font-family: var(--display);
    background: var(--panel);
}
.pagination .page-numbers a:hover {
    border-color: var(--violet);
    color: #fff;
    text-decoration: none;
}
.pagination .page-numbers .current {
    background: var(--violet-deep);
    border-color: var(--violet-deep);
    color: #fff;
}

/* ============================================================
   Форма поиска
   ============================================================ */
.search-form {
    display: flex;
    gap: 8px;
    min-width: 0;
}
.search-form .search-field {
    flex: 1;
    min-width: 0;
    padding: 11px 14px;
    background: var(--bg-soft);
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    color: var(--ink);
    font-family: var(--sans);
    font-size: 0.95rem;
}
.search-form .search-field::placeholder { color: var(--ink-mute); }
.search-form .search-submit {
    padding: 11px 20px;
    background: var(--violet-deep);
    color: #fff;
    border: none;
    border-radius: var(--radius-sm);
    font-family: var(--display);
    font-weight: 500;
    cursor: pointer;
}
.search-form .search-submit:hover { filter: brightness(1.1); }

/* ============================================================
   Комментарии
   ============================================================ */
.comments-area {
    margin-top: 34px;
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 28px 32px;
}
.comments-title { font-size: 1.4rem; }
.comment-list { list-style: none; margin: 0; padding: 0; }
.comment-list li { margin: 0 0 18px; }
.comment-body {
    background: var(--bg-soft);
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    padding: 16px 18px;
}
.comment-list .children { list-style: none; margin: 14px 0 0 26px; padding: 0; }
.comment-author { font-family: var(--display); color: #fff; font-weight: 600; }
.comment-meta { font-size: 0.78rem; color: var(--ink-mute); margin-bottom: 8px; }
.comment-content { color: var(--ink-dim); font-size: 0.95rem; }

.comment-respond {
    margin-top: 26px;
    padding-top: 22px;
    border-top: 1px solid var(--line);
}
.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea {
    width: 100%;
    padding: 11px 14px;
    background: var(--bg-soft);
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    color: var(--ink);
    font-family: var(--sans);
    font-size: 0.95rem;
    margin-top: 5px;
}
.comment-form p { margin-bottom: 14px; }
.comment-form label { font-size: 0.9rem; color: var(--ink-dim); font-family: var(--display); }
.comment-form .submit {
    background: var(--violet-deep);
    color: #fff;
    border: none;
    padding: 12px 26px;
    border-radius: var(--radius-sm);
    font-family: var(--display);
    font-weight: 600;
    cursor: pointer;
}
.comment-form .submit:hover { filter: brightness(1.1); }

/* ============================================================
   404
   ============================================================ */
.error-404 {
    text-align: center;
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 60px 40px;
}
.error-404 .code {
    font-family: var(--display);
    font-size: 5rem;
    font-weight: 700;
    color: var(--violet);
    line-height: 1;
}
.error-404 .search-form { max-width: 460px; margin: 26px auto 18px; }
.btn-home {
    display: inline-block;
    margin-top: 8px;
    padding: 12px 26px;
    background: var(--gold);
    color: var(--bg);
    border-radius: var(--radius-sm);
    font-family: var(--display);
    font-weight: 600;
}
.btn-home:hover { text-decoration: none; filter: brightness(1.07); }

.page-title-block { margin-bottom: 26px; }
.page-title-block h1 { font-size: 2rem; }

/* ============================================================
   Подвал
   ============================================================ */
.site-footer {
    background: #0a0714;
    border-top: 1px solid var(--line);
    padding: 48px 0 0;
}
.footer-cols {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 36px;
}
/* Тёмный фон футера → светлый текст виджетов */
.site-footer .widget {
    background: transparent;
    border: none;
    padding: 0;
    margin: 0;
    color: var(--ink-dim);
}
.site-footer .widget-title {
    color: #fff;
    border-bottom-color: var(--line);
}
.site-footer .widget a { color: var(--ink-dim); }
.site-footer .widget a:hover { color: var(--gold); }
.site-footer .widget li { border-bottom-color: rgba(255, 255, 255, 0.06); }
.site-footer .widget .post-date { color: var(--ink-mute); }

.footer-contacts a { color: var(--cyan); }
.footer-social { margin-top: 12px; display: flex; gap: 12px; }
.footer-social a { color: var(--ink-dim); }
.footer-social a:hover { color: var(--gold); }

.site-bottom {
    border-top: 1px solid var(--line);
    margin-top: 40px;
    padding: 22px 0;
    text-align: center;
    color: var(--ink-mute);
    font-size: 0.85rem;
}

/* ============================================================
   Cookie-баннер — правило [hidden] до основного блока (A11)
   ============================================================ */
.cookie-banner[hidden] { display: none !important; }
.cookie-banner {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 999;
    background: var(--panel-2);
    border-top: 1px solid var(--violet);
    box-shadow: 0 -10px 30px rgba(0, 0, 0, 0.4);
    padding: 16px 0;
}
.cookie-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    flex-wrap: wrap;
}
.cookie-inner p { margin: 0; color: var(--ink-dim); font-size: 0.9rem; flex: 1; min-width: 240px; }
.cookie-accept {
    padding: 11px 24px;
    background: var(--gold);
    color: var(--bg);
    border: none;
    border-radius: var(--radius-sm);
    font-family: var(--display);
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
}
.cookie-accept:hover { filter: brightness(1.07); }

/* ============================================================
   Адаптив
   ============================================================ */
@media (max-width: 960px) {
    .layout-with-sidebar { grid-template-columns: 1fr; gap: 30px; }
    .footer-cols { grid-template-columns: 1fr 1fr; }
    .hero { padding: 40px 28px; }
    .hero h1 { font-size: 2.1rem; }
    .entry { padding: 26px 24px; }
}

@media (max-width: 600px) {
    body { font-size: 16px; }
    h1 { font-size: 1.8rem; }
    .menu-toggle { display: block; }
    .main-nav { width: 100%; margin-left: 0; }
    .nav-list {
        display: none;
        flex-direction: column;
        gap: 4px;
        margin-top: 12px;
        width: 100%;
    }
    .nav-list.is-open { display: flex; }
    .nav-list a { padding: 12px 14px; background: var(--panel); }
    .header-inner { gap: 14px; }
    .layout-single .content-area { width: 100%; }
    .footer-cols { grid-template-columns: 1fr; gap: 28px; }
    .hero h1 { font-size: 1.7rem; }
    .entry { padding: 22px 18px; }
    .entry-title { font-size: 1.5rem; }
    .search-form { flex-direction: column; }
    .search-form .search-submit { width: 100%; }
}
