/*
Theme Name: ZenLike
Theme URI: https://vitalkaburns.su
Author: ZenLike Studio
Description: Светлая авторская тема с карточками публикаций и правой боковой панелью.
Version: 2.0.0
License: GNU General Public License v2 or later
Text Domain: zenlike
*/

:root {
    --ink: #17191d;
    --muted: #70757d;
    --line: #e8e9ec;
    --surface: #ffffff;
    --canvas: #f6f7f9;
    --accent: #365fe8;
    --accent-dark: #2347bd;
    --warm: #f2c66d;
    --radius: 18px;
    --shadow: 0 12px 35px rgba(21, 29, 50, .07);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    margin: 0;
    background: var(--canvas);
    color: var(--ink);
    font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
a:focus-visible, button:focus-visible, input:focus-visible { outline: 3px solid rgba(54,95,232,.35); outline-offset: 3px; }
img { display: block; max-width: 100%; height: auto; }
button, input { font: inherit; }

.screen-reader-text { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }

.site-header { position: sticky; top: 0; z-index: 20; background: rgba(255,255,255,.92); border-bottom: 1px solid var(--line); backdrop-filter: blur(14px); }
.header-inner { width: min(calc(100% - 48px), 1240px); min-height: 82px; margin: 0 auto; display: flex; align-items: center; gap: 28px; }
.site-brand { display: inline-flex; align-items: center; gap: 11px; min-width: max-content; }
.site-brand-mark { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 12px; color: #fff; background: var(--ink); font-weight: 800; font-size: 21px; }
.site-brand-text { display: grid; gap: 0; line-height: 1.15; }
.site-brand-text strong { font-size: 18px; letter-spacing: -.02em; }
.site-brand-text small { color: var(--muted); font-size: 11px; margin-top: 4px; max-width: 260px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.main-navigation { margin-left: auto; min-width: 0; }
.main-navigation ul { display: flex; align-items: center; flex-wrap: wrap; gap: 22px; list-style: none; margin: 0; padding: 0; }
.main-navigation a { color: var(--muted); font-size: 14px; font-weight: 650; transition: color .2s ease; }
.main-navigation a:hover, .main-navigation .current-menu-item > a { color: var(--ink); }
.header-cta { display: inline-flex; align-items: center; gap: 8px; padding: 10px 15px; border: 1px solid var(--ink); border-radius: 999px; font-size: 13px; font-weight: 750; white-space: nowrap; transition: .2s ease; }
.header-cta:hover { color: #fff; background: var(--ink); }

.hero-section { padding: 62px 0 46px; background: linear-gradient(135deg, #eef2ff 0%, #f8f8fa 57%, #fff 100%); border-bottom: 1px solid var(--line); }
.hero-inner { width: 100%; max-width: none; min-height: 0; margin: 0; padding: 0 clamp(32px, 6.35vw, 110px); display: block; }
.hero-copy, .hero-copy h1, .hero-lead, .hero-actions { width: 100%; max-width: none; }
.hero-actions { justify-content: flex-start; }
.eyebrow, .sidebar-kicker { display: block; color: var(--accent); font-size: 11px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; }
.hero-copy h1 { max-width: none; margin: 12px 0 16px; font-size: clamp(42px, 6vw, 76px); line-height: .98; letter-spacing: -.065em; }
.hero-lead { max-width: none; margin: 0; color: #4f5662; font-size: clamp(18px, 2vw, 22px); line-height: 1.45; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.button { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 44px; padding: 11px 17px; border-radius: 999px; border: 1px solid transparent; font-size: 14px; font-weight: 750; transition: transform .2s ease, background .2s ease, color .2s ease; }
.button:hover { transform: translateY(-2px); }
.button--primary { color: #fff; background: var(--accent); box-shadow: 0 8px 20px rgba(54,95,232,.22); }
.button--primary:hover { background: var(--accent-dark); }
.button--ghost { border-color: #cfd3dd; background: rgba(255,255,255,.6); }
.button--ghost:hover { background: #fff; }
.button--dark { width: 100%; color: #fff; background: var(--ink); }
.button--dark:hover { background: #30343b; }
.hero-panel { position: relative; min-height: 300px; overflow: hidden; border-radius: 32px; background: #151922; box-shadow: 0 25px 55px rgba(21,25,34,.18); }
.hero-panel:before { content: ""; position: absolute; inset: 0; background: radial-gradient(circle at 70% 28%, rgba(242,198,109,.75), transparent 28%), radial-gradient(circle at 25% 70%, rgba(54,95,232,.8), transparent 40%); }
.hero-panel-orbit { position: absolute; border: 1px solid rgba(255,255,255,.35); border-radius: 50%; transform: rotate(-26deg); }
.hero-panel-orbit--one { width: 270px; height: 160px; right: -30px; top: 55px; }
.hero-panel-orbit--two { width: 330px; height: 210px; right: -70px; top: 28px; border-color: rgba(255,255,255,.2); }
.hero-panel-mark { position: absolute; left: 34px; bottom: 26px; color: #fff; font-size: 110px; font-weight: 900; line-height: 1; opacity: .95; }
.hero-panel-note { position: absolute; right: 27px; bottom: 26px; display: grid; gap: 2px; color: #fff; text-align: right; }
.hero-panel-note span { color: #f2c66d; font-size: 12px; text-transform: uppercase; letter-spacing: .15em; }
.hero-panel-note strong { font-size: 21px; }

.site-container { width: min(calc(100% - 48px), 1240px); margin: 46px auto 0; display: grid; grid-template-columns: minmax(0, 1fr) 300px; align-items: start; gap: 34px; }
.content-column { min-width: 0; grid-column: 1; }
.site-sidebar { min-width: 0; grid-column: 2; grid-row: 1; display: flex; flex-direction: column; gap: 18px; }
.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 20px; margin-bottom: 22px; }
.section-heading h2, .archive-heading h1, .page-header h1 { margin: 4px 0 0; font-size: clamp(28px, 4vw, 42px); line-height: 1.08; letter-spacing: -.045em; }
.text-link { color: var(--accent); font-size: 14px; font-weight: 750; white-space: nowrap; }
.text-link:hover { color: var(--accent-dark); }

.posts-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; }
.post-card { min-width: 0; overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); box-shadow: 0 5px 18px rgba(21,29,50,.025); transition: transform .2s ease, box-shadow .2s ease; }
.post-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.post-card-link { display: flex; flex-direction: column; height: 100%; }
.post-card-image { height: 210px; margin: 0; overflow: hidden; background: #e8ecf5; }
.post-card-image img { width: 100%; height: 100%; object-fit: cover; transition: transform .35s ease; }
.post-card:hover .post-card-image img { transform: scale(1.035); }
.post-card-image--empty { display: grid; place-items: center; color: rgba(255,255,255,.9); background: linear-gradient(135deg, #365fe8, #9b5de5); font-size: 55px; }
.post-card-body { display: flex; flex: 1; flex-direction: column; padding: 19px 20px 18px; }
.post-meta { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; color: #969ba5; font-size: 12px; }
.post-category { color: var(--accent); font-size: 11px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.post-card-title { margin: 10px 0 8px; font-size: 21px; line-height: 1.2; letter-spacing: -.025em; }
.post-card-excerpt { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 3; overflow: hidden; margin: 0 0 18px; color: var(--muted); font-size: 14px; line-height: 1.5; }
.post-card-author, .single-author { display: flex; align-items: center; gap: 9px; margin-top: auto; color: #8a9099; font-size: 13px; }
.author-badge { display: inline-grid; flex: 0 0 auto; place-items: center; width: 30px; height: 30px; border-radius: 50%; color: #fff; background: var(--ink); font-size: 13px; font-weight: 800; }
.single-author .author-badge { width: 34px; height: 34px; }

.sidebar-card { padding: 22px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); box-shadow: 0 5px 18px rgba(21,29,50,.025); }
.sidebar-card h2 { margin: 7px 0 9px; font-size: 20px; line-height: 1.2; letter-spacing: -.025em; }
.sidebar-card p { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.55; }
.sidebar-link { display: inline-flex; gap: 8px; margin-top: 17px; color: var(--accent); font-size: 13px; font-weight: 800; }
.sidebar-link:hover { color: var(--accent-dark); }
.widget-title { margin: 0 0 15px !important; padding: 0 !important; border: 0 !important; font-size: 18px !important; }
.category-list { margin: 0; padding: 0; list-style: none; }
.category-list li + li { border-top: 1px solid var(--line); }
.category-list a { display: flex; justify-content: space-between; gap: 10px; padding: 10px 0; color: #4e5560; font-size: 14px; }
.category-list a:hover { color: var(--accent); }
.category-list small { color: #a4a9b1; }
.muted { color: var(--muted); }
.search-form { display: flex; gap: 8px; }
.search-field { min-width: 0; width: 100%; padding: 11px 12px; border: 1px solid #dfe2e8; border-radius: 10px; color: var(--ink); background: #fafbfc; }
.search-submit { flex: 0 0 42px; border: 0; border-radius: 10px; color: #fff; background: var(--accent); cursor: pointer; font-size: 21px; line-height: 1; }
.search-submit:hover { background: var(--accent-dark); }

.archive-layout, .page-layout, .single-layout { margin-top: 50px; }
.archive-heading { margin-bottom: 28px; }
.archive-heading p, .archive-description { margin: 10px 0 0; color: var(--muted); }
.archive-heading h1 { margin-top: 7px; }
.empty-state { grid-column: 1 / -1; padding: 45px 30px; border: 1px dashed #cfd4df; border-radius: var(--radius); text-align: center; background: #fff; }
.empty-state h1, .empty-state h2, .empty-state h3 { margin: 0 0 8px; line-height: 1.15; }
.empty-state p { margin: 0 0 20px; color: var(--muted); }
.navigation.pagination { grid-column: 1 / -1; margin: 30px 0 0; }
.navigation.pagination .nav-links { display: flex; justify-content: center; flex-wrap: wrap; gap: 7px; }
.navigation.pagination a, .navigation.pagination span { display: inline-flex; align-items: center; justify-content: center; min-width: 40px; min-height: 38px; padding: 6px 12px; border-radius: 9px; background: #fff; color: var(--ink); border: 1px solid var(--line); font-size: 13px; font-weight: 700; }
.navigation.pagination a:hover, .navigation.pagination .current { color: #fff; background: var(--accent); border-color: var(--accent); }

.page-card, .single-post.content-column { min-width: 0; padding: clamp(24px, 5vw, 58px); border: 1px solid var(--line); border-radius: var(--radius); background: #fff; box-shadow: 0 5px 18px rgba(21,29,50,.025); }
.page-header, .single-header { max-width: 780px; margin: 0 auto; }
.page-header h1 { margin-bottom: 28px; }
.single-header .post-meta { justify-content: center; }
.single-header { text-align: center; }
.single-header h1 { margin: 14px auto 20px; font-size: clamp(34px, 5vw, 58px); line-height: 1.05; letter-spacing: -.055em; }
.single-header .single-author { justify-content: center; margin-top: 0; }
.single-featured-image { margin: 38px auto 42px; max-width: 1000px; overflow: hidden; border-radius: 15px; }
.single-featured-image img { width: 100%; max-height: 650px; object-fit: cover; }
.single-content { max-width: 760px; margin: 0 auto; color: #343943; font-size: 18px; line-height: 1.78; }
.single-content > *:first-child { margin-top: 0; }
.single-content h2 { margin-top: 42px; color: var(--ink); font-size: 31px; line-height: 1.15; }
.single-content h3 { margin-top: 30px; color: var(--ink); font-size: 24px; line-height: 1.2; }
.single-content p { margin: 0 0 22px; }
.single-content ul, .single-content ol { margin-bottom: 24px; }
.single-content blockquote { margin: 28px 0; padding: 20px 24px; border-left: 4px solid var(--accent); border-radius: 0 12px 12px 0; background: #f3f5ff; color: #4f5662; }
.single-content img { margin: 28px auto; border-radius: 12px; }
.post-tags { max-width: 760px; margin: 30px auto 0; display: flex; flex-wrap: wrap; gap: 8px; }
.post-tags a { padding: 6px 10px; border-radius: 999px; color: var(--accent); background: #eef2ff; font-size: 12px; font-weight: 700; }
.article-back { max-width: 760px; margin: 34px auto 0; padding-top: 22px; border-top: 1px solid var(--line); }
.comments-area { max-width: 760px; margin: 40px auto 0; padding-top: 28px; border-top: 1px solid var(--line); }

.site-footer { margin-top: 70px; padding: 42px 0 30px; color: var(--muted); background: #fff; border-top: 1px solid var(--line); }
.footer-inner { width: min(calc(100% - 48px), 1240px); margin: 0 auto; display: grid; grid-template-columns: 1.2fr 1fr auto; gap: 35px; align-items: start; }
.site-brand--footer .site-brand-mark { width: 32px; height: 32px; font-size: 17px; }
.site-brand--footer .site-brand-text strong { font-size: 16px; }
.footer-brand p { max-width: 290px; margin: 15px 0 0; font-size: 13px; }
.footer-links { display: flex; flex-wrap: wrap; gap: 10px 18px; align-content: start; font-size: 13px; }
.footer-links a:hover, .footer-account a:hover { color: var(--accent); }
.footer-meta { display: grid; gap: 8px; justify-items: end; font-size: 12px; white-space: nowrap; }
.footer-account { display: inline-flex; gap: 8px; }

@media (max-width: 980px) {
    .header-inner { min-height: 74px; gap: 18px; }
    .main-navigation ul { gap: 14px; }
    .header-cta { display: none; }
    .hero-inner { grid-template-columns: 1fr; gap: 30px; }
    .hero-panel { min-height: 240px; }
    .site-container { grid-template-columns: minmax(0, 1fr); }
    .content-column, .site-sidebar { grid-column: 1; grid-row: auto; }
    .site-sidebar { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; }
    .sidebar-contact { grid-column: 1 / -1; }
    .footer-inner { grid-template-columns: 1fr 1fr; }
    .footer-meta { justify-items: start; }
}
@media (max-width: 680px) {
    .header-inner, .hero-inner, .site-container, .footer-inner { width: min(calc(100% - 32px), 1240px); }
    .header-inner { flex-wrap: wrap; padding: 13px 0; }
    .main-navigation { order: 3; width: 100%; overflow-x: auto; }
    .main-navigation ul { flex-wrap: nowrap; width: max-content; }
    .hero-section { padding: 42px 0 32px; }
    .hero-copy h1 { font-size: clamp(40px, 14vw, 62px); }
    .hero-panel { min-height: 190px; border-radius: 22px; }
    .hero-panel-mark { left: 23px; bottom: 17px; font-size: 76px; }
    .hero-panel-note { right: 19px; bottom: 18px; }
    .section-heading { align-items: start; flex-direction: column; gap: 10px; }
    .posts-grid { grid-template-columns: 1fr; }
    .posts-grid .post-card:only-child a { display: flex; flex-direction: column; }
    .post-card-image { height: 200px; }
    .site-sidebar { display: flex; }
    .sidebar-contact { order: initial; }
    .page-card, .single-post.content-column { padding: 25px 19px; }
    .single-content { font-size: 17px; }
    .footer-inner { grid-template-columns: 1fr; gap: 23px; }
    .footer-meta { justify-items: start; }
}
/* Hero: full-width content without the empty right visual area */
.hero-section { background: #f1f3ff; }
.hero-inner { display: block !important; width: 100% !important; max-width: none !important; padding-left: clamp(32px, 6.35vw, 110px); padding-right: clamp(32px, 6.35vw, 110px); }
.hero-copy { display: block !important; width: 100% !important; max-width: none !important; }
.hero-copy h1, .hero-lead, .hero-actions { width: 100% !important; max-width: none !important; }

/* Definitive full-width hero */
.hero-section { width: 100%; padding: clamp(52px, 5vw, 88px) 0 clamp(48px, 5vw, 78px); background: #f1f3ff; }
.hero-inner { width: 100% !important; max-width: none !important; min-height: 0 !important; margin: 0 !important; padding: 0 clamp(32px, 6vw, 114px) !important; display: block !important; }
.hero-copy { display: block !important; width: 100% !important; max-width: none !important; }
.hero-copy h1 { display: block; width: 100% !important; max-width: none !important; margin: 18px 0 22px; font-size: clamp(58px, 9.3vw, 172px); line-height: .9; letter-spacing: -.075em; white-space: nowrap; }
.hero-lead { display: block; width: 100% !important; max-width: none !important; margin: 0; font-size: clamp(21px, 2.55vw, 42px); line-height: 1.2; }
.hero-actions { display: flex !important; align-items: center; justify-content: flex-start !important; width: 100% !important; max-width: none !important; gap: 16px; margin-top: clamp(26px, 3vw, 42px); }
.hero-actions .button { min-height: 52px; padding: 14px 24px; }
@media (max-width: 680px) { .hero-inner { padding-left: 16px !important; padding-right: 16px !important; } .hero-copy h1 { font-size: clamp(42px, 14vw, 72px); white-space: normal; } .hero-lead { font-size: clamp(19px, 5vw, 27px); } .hero-actions .button { min-height: 46px; padding: 11px 16px; } }

/* Make the hero typography visibly use the whole desktop row */
.hero-copy h1 { font-size: clamp(58px, 10vw, 190px); letter-spacing: -.08em; }
.hero-lead { font-size: clamp(21px, 3.2vw, 58px); line-height: 1.15; }
.hero-actions { gap: clamp(12px, 1.5vw, 28px); }
.hero-actions .button { min-height: clamp(46px, 4vw, 64px); padding: 14px clamp(18px, 2vw, 34px); font-size: clamp(14px, 1.2vw, 22px); }
@media (max-width: 680px) { .hero-copy h1 { font-size: clamp(42px, 14vw, 72px); letter-spacing: -.075em; } .hero-lead { font-size: clamp(19px, 5vw, 27px); } }

/* Align hero with site containers */
.hero-inner { width: min(calc(100% - 48px), 1240px) !important; max-width: 1240px !important; margin: 0 auto !important; padding-left: 0 !important; padding-right: 0 !important; }

/* Center the hero text and action buttons */
.hero-copy { text-align: center !important; }
.hero-copy .eyebrow, .hero-copy h1, .hero-copy .hero-lead { text-align: center !important; }
.hero-actions { justify-content: center !important; }


/* Final compact hero and tighter section spacing */
.hero-section {
    padding: 32px 0 24px !important;
    margin: 0 !important;
}
.hero-inner {
    min-height: 0 !important;
}
.hero-copy h1 {
    font-size: clamp(48px, 6vw, 92px) !important;
    line-height: .98 !important;
    margin: 10px auto 14px !important;
}
.hero-lead {
    font-size: clamp(18px, 1.8vw, 30px) !important;
    line-height: 1.25 !important;
    margin: 0 auto 16px !important;
}
.hero-actions {
    gap: 12px !important;
    margin-top: 14px !important;
}
.hero-actions .button {
    min-height: 46px !important;
    padding: 11px 18px !important;
    font-size: 14px !important;
}
.site-container {
    margin-top: 24px !important;
}
.section-heading {
    margin-bottom: 14px !important;
}
.posts-grid {
    gap: 16px !important;
}
.site-footer {
    margin-top: 32px !important;
}
@media (max-width: 680px) {
    .hero-section { padding: 28px 0 20px !important; }
    .hero-copy h1 {
        font-size: clamp(40px, 12vw, 64px) !important;
        margin: 8px auto 12px !important;
    }
    .hero-lead { font-size: clamp(17px, 5vw, 24px) !important; }
    .hero-actions { margin-top: 12px !important; }
    .site-container { margin-top: 18px !important; }
}


/* Authentication links moved from footer to the right side */
.header-account {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    margin-left: 2px;
    color: var(--muted);
    font-size: 13px;
    font-weight: 750;
    white-space: nowrap;
}
.header-account a { transition: color .2s ease; }
.header-account a:hover { color: var(--ink); }
.header-account span { color: #c4c8d0; }
@media (max-width: 980px) {
    .header-account { margin-left: auto; }
}
@media (max-width: 680px) {
    .header-account { order: 2; margin-left: auto; font-size: 12px; }
}

/* Header readability: scoped typography and responsive layout */
.site-header .header-inner { gap: 22px; }
.site-header .site-brand-text strong { font-size: 24px; line-height: 1.2; }
.site-header .site-brand-text small {
    font-size: 14px; line-height: 1.4; color: #505660;
    max-width: 340px; white-space: normal; overflow: visible;
}
.site-header .main-navigation a { font-size: 18px; font-weight: 700; color: #414751; }
.site-header .main-navigation a:hover,
.site-header .main-navigation .current-menu-item > a { color: var(--ink); }
.site-header .header-cta { font-size: 16px; }
.site-header .header-account { font-size: 16px; line-height: 1.5; color: #414751; }
.site-header .header-account a { display: inline-flex; align-items: center; min-height: 44px; }
@media (max-width: 1100px) {
    .site-header .header-inner { flex-wrap: wrap; gap: 10px 18px; padding: 12px 0; }
    .site-header .main-navigation { order: 3; width: 100%; margin-left: 0; }
    .site-header .header-account { margin-left: auto; }
    .site-header .header-cta { display: none; }
}
@media (max-width: 680px) {
    .site-header .site-brand { min-width: 0; width: 100%; }
    .site-header .site-brand-text { min-width: 0; }
    .site-header .site-brand-text strong { font-size: 22px; }
    .site-header .site-brand-text small { max-width: 100%; font-size: 14px; }
    .site-header .site-brand-mark { flex-shrink: 0; }
    .site-header .main-navigation ul { flex-wrap: wrap; width: auto; gap: 8px 18px; }
    .site-header .main-navigation a { font-size: 17px; }
    .site-header .header-account { font-size: 16px; }
}


/* =====================================================================
   Visual refinement — September 2026
   CSS-only presentation layer. Content and copy are intentionally untouched.
   ===================================================================== */
:root {
    --ink: #171a22;
    --muted: #687181;
    --line: #e5e8ef;
    --surface: #ffffff;
    --canvas: #f7f8fb;
    --accent: #3158d8;
    --accent-dark: #2444b0;
    --warm: #e9b85f;
    --warm-soft: #fff5df;
    --radius: 20px;
    --shadow: 0 16px 42px rgba(29, 39, 75, .08);
}

html { background: var(--canvas); }
body {
    background:
        radial-gradient(circle at 88% 0%, rgba(225, 232, 255, .45), transparent 29rem),
        var(--canvas);
    color: var(--ink);
}

/* Header: lighter glass effect and calmer proportions */
.site-header {
    background: rgba(255, 255, 255, .86);
    border-bottom-color: rgba(220, 224, 234, .88);
    box-shadow: 0 4px 24px rgba(28, 38, 70, .035);
}
.header-inner {
    min-height: 76px;
    gap: 24px;
}
.site-brand { gap: 12px; }
.site-brand-mark {
    width: 40px;
    height: 40px;
    border-radius: 13px;
    background: linear-gradient(145deg, #1b1f29, #363d4c);
    box-shadow: 0 7px 16px rgba(23, 26, 34, .16);
}
.site-brand-text strong { letter-spacing: -.035em; }
.main-navigation ul { gap: 20px; }
.main-navigation a { position: relative; transition: color .2s ease; }
.main-navigation a::after {
    content: "";
    position: absolute;
    right: 0;
    bottom: -8px;
    left: 0;
    height: 2px;
    border-radius: 2px;
    background: var(--accent);
    transform: scaleX(0);
    transform-origin: center;
    transition: transform .2s ease;
}
.main-navigation a:hover::after,
.main-navigation .current-menu-item > a::after { transform: scaleX(1); }
.header-cta {
    border-color: #cbd1df;
    background: rgba(255, 255, 255, .64);
    box-shadow: 0 4px 12px rgba(29, 39, 75, .04);
}
.header-cta:hover { border-color: var(--ink); }

/* Hero: a more editorial, memorable opening without adding content */
.hero-section {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    padding: clamp(58px, 7vw, 92px) 0 clamp(50px, 6vw, 76px);
    background:
        radial-gradient(circle at 94% 20%, rgba(233, 184, 95, .28), transparent 16rem),
        radial-gradient(circle at 75% 90%, rgba(92, 119, 226, .16), transparent 24rem),
        linear-gradient(135deg, #eef2ff 0%, #f8f9fd 55%, #fff 100%);
    border-bottom-color: #e2e6f0;
}
.hero-section::before {
    content: "";
    position: absolute;
    z-index: -1;
    top: -11rem;
    right: -8rem;
    width: 30rem;
    height: 30rem;
    border: 1px solid rgba(49, 88, 216, .12);
    border-radius: 45% 55% 52% 48%;
    transform: rotate(24deg);
    box-shadow: 0 0 0 34px rgba(49, 88, 216, .025), 0 0 0 68px rgba(49, 88, 216, .018);
    pointer-events: none;
}
.hero-inner {
    position: relative;
    z-index: 1;
    padding-right: clamp(24px, 6.35vw, 110px);
    padding-left: clamp(24px, 6.35vw, 110px);
}
.hero-copy { max-width: 920px !important; }
.hero-copy h1 {
    max-width: 900px !important;
    margin-top: 16px;
    margin-bottom: 20px;
    color: #12151c;
    font-size: clamp(44px, 6vw, 78px);
    letter-spacing: -.075em;
    text-wrap: balance;
}
.hero-lead {
    max-width: 760px !important;
    color: #515b6b;
    font-size: clamp(18px, 2vw, 22px);
    text-wrap: pretty;
}
.eyebrow { letter-spacing: .18em; }
.hero-actions { margin-top: 32px; }
.button {
    min-height: 46px;
    padding-right: 19px;
    padding-left: 19px;
    transition: transform .2s ease, box-shadow .2s ease, background .2s ease, color .2s ease, border-color .2s ease;
}
.button--primary {
    background: linear-gradient(135deg, #3d64e2, #2d50c9);
    box-shadow: 0 10px 22px rgba(49, 88, 216, .22);
}
.button--primary:hover {
    background: linear-gradient(135deg, #3158d8, #2444b0);
    box-shadow: 0 13px 25px rgba(49, 88, 216, .28);
}
.button--ghost {
    border-color: #cbd2e0;
    background: rgba(255, 255, 255, .72);
}
.button--ghost:hover { border-color: #aeb8cb; box-shadow: 0 8px 18px rgba(29, 39, 75, .07); }

/* Content rhythm and editorial headings */
.site-container { margin-top: 58px; }
.section-heading { align-items: end; margin-bottom: 25px; }
.section-heading h2 { letter-spacing: -.04em; }
.text-link { transition: color .2s ease, transform .2s ease; }
.text-link:hover { transform: translateX(3px); }

/* Cards: clearer hierarchy and a subtle tactile interaction */
.post-card {
    border-color: #e3e7ef;
    border-radius: 20px;
    background: rgba(255, 255, 255, .96);
    box-shadow: 0 7px 22px rgba(29, 39, 75, .045);
    transition: transform .24s ease, box-shadow .24s ease, border-color .24s ease;
}
.post-card:hover {
    border-color: #ccd5ee;
    box-shadow: 0 18px 38px rgba(29, 39, 75, .11);
    transform: translateY(-5px);
}
.post-card-image { background: linear-gradient(135deg, #e9edff, #fff5df); }
.post-card-image img { transition: transform .45s cubic-bezier(.2,.7,.2,1); }
.post-card:hover .post-card-image img { transform: scale(1.045); }
.post-card-body { padding: 22px 22px 20px; }
.post-card-title { letter-spacing: -.04em; }
.post-card-excerpt { color: #667080; }
.author-badge {
    background: linear-gradient(145deg, #1b1f29, #465064);
    box-shadow: 0 4px 10px rgba(23, 26, 34, .14);
}

/* Sidebar and utility controls */
.sidebar-card, .page-card, .single-post.content-column {
    border-color: #e3e7ef;
    box-shadow: 0 8px 24px rgba(29, 39, 75, .045);
}
.sidebar-card { padding: 24px; }
.search-field { border-color: #d9deea; background: #fbfcff; }
.search-field:focus { border-color: #91a4e5; box-shadow: 0 0 0 4px rgba(49, 88, 216, .11); outline: 0; }
.search-submit { background: linear-gradient(135deg, #3d64e2, #2d50c9); }

/* Footer: stronger finish, still restrained */
.site-footer {
    margin-top: 82px;
    padding-top: 48px;
    background: #fff;
    border-top-color: #e3e7ef;
}
.footer-inner { gap: 42px; }
.site-brand--footer .site-brand-mark { background: linear-gradient(145deg, #1b1f29, #363d4c); }
.footer-links a, .footer-account a { transition: color .2s ease; }

/* Keyboard and pointer states */
:where(a, button, input):focus-visible {
    outline: 3px solid rgba(49, 88, 216, .3);
    outline-offset: 4px;
}

@media (max-width: 980px) {
    .header-inner { min-height: 72px; }
    .hero-copy { max-width: 820px !important; }
    .hero-copy h1 { max-width: 820px !important; }
    .site-container { margin-top: 48px; }
}

@media (max-width: 680px) {
    .site-header { position: relative; }
    .header-inner {
        display: grid;
        grid-template-columns: minmax(0, 1fr) auto;
        align-items: center;
        gap: 10px 12px;
        min-height: 0;
        padding-top: 12px;
        padding-bottom: 12px;
    }
    .site-brand { grid-column: 1; min-width: 0; }
    .site-brand-text strong { display: block; max-width: 100%; overflow: hidden; font-size: 16px; text-overflow: ellipsis; white-space: nowrap; }
    .site-brand-text small { display: none; }
    .site-brand-mark { width: 36px; height: 36px; border-radius: 11px; font-size: 19px; }
    .header-cta {
        display: inline-flex;
        grid-column: 2;
        padding: 8px 11px;
        font-size: 12px;
    }
    .main-navigation {
        grid-column: 1 / -1;
        order: initial;
        width: 100%;
        padding-top: 9px;
        border-top: 1px solid rgba(229, 232, 239, .9);
        overflow-x: auto;
        scrollbar-width: none;
    }
    .main-navigation::-webkit-scrollbar { display: none; }
    .main-navigation ul { gap: 18px; }
    .main-navigation a { font-size: 13px; white-space: nowrap; }
    .main-navigation a::after { bottom: -6px; }
    .hero-section { padding-top: 50px; padding-bottom: 42px; }
    .hero-section::before { top: -9rem; right: -12rem; width: 23rem; height: 23rem; }
    .hero-inner { padding-right: 24px; padding-left: 24px; }
    .hero-copy, .hero-copy h1, .hero-lead, .hero-actions { max-width: none !important; }
    .hero-copy h1 { margin-top: 13px; margin-bottom: 17px; font-size: clamp(42px, 14vw, 62px); line-height: 1; }
    .hero-lead { font-size: 18px; }
    .hero-actions { gap: 10px; margin-top: 26px; }
    .hero-actions .button { flex: 0 1 auto; }
    .site-container { width: min(calc(100% - 32px), 1240px); margin-top: 38px; }
    .section-heading { align-items: start; gap: 12px; }
    .section-heading h2 { font-size: 26px; }
    .post-card { border-radius: 18px; }
    .post-card:hover { transform: translateY(-2px); }
    .post-card-body { padding: 20px 18px 18px; }
    .site-footer { margin-top: 58px; padding-top: 36px; }
    .footer-inner { gap: 26px; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; }
}


/* =====================================================================
   Visual refinement v2 — September 2026
   Presentation and interaction layer only. Site copy and content untouched.
   ===================================================================== */

/* More legible secondary text and a clearer editorial rhythm */
:root {
    --muted: #5f6979;
    --line: #e1e5ee;
    --accent: #3158d8;
    --accent-dark: #2444b0;
    --warm: #e9b85f;
    --warm-soft: #fff5df;
}

.post-meta { color: #737d8d; }
.post-card-excerpt,
.sidebar-card p,
.footer-brand p,
.archive-heading p,
.archive-description { color: #5f6979; }

/* The brand accent is a small signature rather than decoration for its own sake */
.hero-section::after {
    content: "";
    position: absolute;
    z-index: -1;
    right: clamp(28px, 10vw, 170px);
    bottom: 38px;
    width: 66px;
    height: 10px;
    border-top: 2px solid rgba(233, 184, 95, .75);
    border-bottom: 2px solid rgba(49, 88, 216, .2);
    border-radius: 50%;
    transform: rotate(-8deg);
    pointer-events: none;
}

/* The only visible publication gets an intentional featured layout */
.posts-grid .post-card:only-child {
    grid-column: 1 / -1;
}
.posts-grid .post-card:only-child .post-card-link {
    display: grid;
    grid-template-columns: minmax(280px, .88fr) minmax(0, 1.12fr);
    min-height: 320px;
}
.posts-grid .post-card:only-child .post-card-image {
    height: 100%;
    min-height: 320px;
    aspect-ratio: auto;
}
.posts-grid .post-card:only-child .post-card-body {
    justify-content: center;
    padding: clamp(26px, 4vw, 46px);
}
.posts-grid .post-card:only-child .post-card-title {
    font-size: clamp(24px, 2.4vw, 34px);
    line-height: 1.12;
}

/* Stable editorial image proportions for future cards */
.post-card:not(:only-child) .post-card-image {
    aspect-ratio: 16 / 9;
}
.post-card:not(:only-child) .post-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Stronger active state in the main navigation */
.main-navigation .current-menu-item > a {
    color: var(--ink);
}
.main-navigation .current-menu-item > a::before {
    content: "";
    position: absolute;
    z-index: -1;
    top: 50%;
    right: -10px;
    bottom: -6px;
    left: -10px;
    border-radius: 8px;
    background: rgba(49, 88, 216, .08);
    transform: translateY(-50%);
}

/* Keep account controls out of the public-facing composition */
.header-account { display: none !important; }

/* Search as a distinct utility card */
.search-form {
    align-items: center;
    padding: 7px;
    border: 1px solid #e0e5ef;
    border-radius: 15px;
    background: #f8faff;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.85), 0 5px 16px rgba(29, 39, 75, .035);
}
.search-form .search-field {
    border-color: transparent;
    background: transparent;
}
.search-form .search-field:focus { border-color: transparent; box-shadow: none; }
.search-submit { box-shadow: 0 5px 13px rgba(49, 88, 216, .2); }

/* More finished inner pages */
.archive-heading,
.page-header,
.single-header { position: relative; }
.archive-heading::after,
.page-header::after {
    content: "";
    display: block;
    width: 46px;
    height: 3px;
    margin-top: 18px;
    border-radius: 3px;
    background: linear-gradient(90deg, var(--accent), var(--warm));
}
.page-header::after { margin-right: auto; margin-left: auto; }
.page-card, .single-post.content-column, .sidebar-card {
    border-color: #dfe4ed;
    box-shadow: 0 10px 28px rgba(29, 39, 75, .055);
}
.single-content a { color: var(--accent-dark); text-decoration: underline; text-decoration-color: rgba(49, 88, 216, .35); text-underline-offset: 3px; }
.single-content a:hover { text-decoration-color: currentColor; }
.footer-links a,
.footer-account a {
    text-decoration: underline;
    text-decoration-color: transparent;
    text-underline-offset: 4px;
    transition: color .2s ease, text-decoration-color .2s ease, transform .2s ease;
}
.footer-links a:hover,
.footer-account a:hover { text-decoration-color: currentColor; }

/* Compact mobile menu button: navigation remains available without JavaScript */
.menu-toggle {
    display: none;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    padding: 0;
    border: 1px solid #d7ddea;
    border-radius: 12px;
    color: var(--ink);
    background: rgba(255,255,255,.72);
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(29, 39, 75, .045);
}
.menu-toggle-lines,
.menu-toggle-lines::before,
.menu-toggle-lines::after {
    display: block;
    width: 16px;
    height: 2px;
    border-radius: 2px;
    background: currentColor;
    transition: transform .2s ease, opacity .2s ease;
}
.menu-toggle-lines { position: relative; }
.menu-toggle-lines::before,
.menu-toggle-lines::after { content: ""; position: absolute; left: 0; }
.menu-toggle-lines::before { top: -5px; }
.menu-toggle-lines::after { top: 5px; }
.menu-open .menu-toggle-lines { background: transparent; }
.menu-open .menu-toggle-lines::before { transform: translateY(5px) rotate(45deg); }
.menu-open .menu-toggle-lines::after { transform: translateY(-5px) rotate(-45deg); }

/* Subtle entrance animation, disabled automatically for reduced-motion users */
@media (prefers-reduced-motion: no-preference) {
    .has-reveal .reveal-item {
        opacity: 0;
        transform: translateY(12px);
        transition: opacity .55s ease var(--reveal-delay, 0ms), transform .55s ease var(--reveal-delay, 0ms);
    }
    .has-reveal .reveal-item.is-visible {
        opacity: 1;
        transform: none;
    }
}

@media (max-width: 680px) {
    .header-inner {
        grid-template-columns: minmax(0, 1fr) auto auto;
        column-gap: 8px;
    }
    .site-brand { grid-column: 1; }
    .menu-toggle {
        display: inline-flex;
        grid-column: 2;
    }
    .header-cta {
        grid-column: 3;
        padding-right: 10px;
        padding-left: 10px;
    }
    body.menu-ready .main-navigation {
        display: none;
    }
    body.menu-ready.menu-open .main-navigation {
        display: block;
    }
    body.menu-ready.menu-open .main-navigation ul {
        display: grid;
        gap: 4px;
        width: 100%;
    }
    body.menu-ready.menu-open .main-navigation a {
        display: block;
        padding: 9px 10px;
        border-radius: 9px;
    }
    body.menu-ready.menu-open .main-navigation a::after,
    body.menu-ready.menu-open .main-navigation .current-menu-item > a::before { display: none; }
    body.menu-ready.menu-open .main-navigation .current-menu-item > a { background: rgba(49, 88, 216, .08); }
    .posts-grid .post-card:only-child .post-card-link {
        display: flex;
        flex-direction: column;
        min-height: 0;
    }
    .posts-grid .post-card:only-child .post-card-image {
        min-height: 0;
        aspect-ratio: 16 / 9;
        height: auto;
    }
    .posts-grid .post-card:only-child .post-card-body { padding: 20px 18px 18px; }
    .posts-grid .post-card:only-child .post-card-title { font-size: 25px; }
    .hero-section::after { right: 28px; bottom: 25px; transform: rotate(-8deg) scale(.8); }
}

/* Opt-in dark palette for a future theme switch: add data-theme="dark" to <html>. */
[data-theme="dark"] {
    --ink: #f3f5fb;
    --muted: #aeb8ca;
    --line: #2b3447;
    --surface: #151b27;
    --canvas: #0f141d;
    --accent: #8da7ff;
    --accent-dark: #b8c7ff;
    --warm: #f2c66d;
}
[data-theme="dark"] body {
    background: radial-gradient(circle at 88% 0%, rgba(45, 66, 132, .35), transparent 30rem), var(--canvas);
}
[data-theme="dark"] .site-header,
[data-theme="dark"] .site-footer,
[data-theme="dark"] .post-card,
[data-theme="dark"] .sidebar-card,
[data-theme="dark"] .page-card,
[data-theme="dark"] .single-post.content-column,
[data-theme="dark"] .empty-state { color: var(--ink); background: var(--surface); border-color: var(--line); }
[data-theme="dark"] .hero-section { background: linear-gradient(135deg, #18223c, #121927 58%, #151b27); border-color: var(--line); }
[data-theme="dark"] .hero-copy h1,
[data-theme="dark"] .section-heading h2,
[data-theme="dark"] .post-card-title,
[data-theme="dark"] .sidebar-card h2,
[data-theme="dark"] .single-content h2,
[data-theme="dark"] .single-content h3 { color: var(--ink); }
[data-theme="dark"] .hero-lead,
[data-theme="dark"] .post-card-excerpt,
[data-theme="dark"] .sidebar-card p,
[data-theme="dark"] .footer-brand p,
[data-theme="dark"] .archive-heading p,
[data-theme="dark"] .archive-description { color: var(--muted); }
[data-theme="dark"] .button--ghost,
[data-theme="dark"] .search-form { border-color: #3a455c; background: #1b2434; }
[data-theme="dark"] .search-form .search-field { color: var(--ink); }
[data-theme="dark"] .main-navigation a,
[data-theme="dark"] .footer-links a,
[data-theme="dark"] .footer-account a { color: var(--muted); }
[data-theme="dark"] .menu-toggle { color: var(--ink); border-color: #3a455c; background: #1b2434; }
