/* ==========================================================================
   WorldlyBrief — main stylesheet
   1. Tokens  2. Base  3. Layout  4. Header  5. Search/menus  6. Cards
   7. Home sections  8. Article  9. Prose  10. Archive/Search  11. Pages
   12. Footer  13. Utilities  14. Responsive
   ========================================================================== */

/* 1. Tokens ---------------------------------------------------------------- */
:root {
	--bg: #ffffff;
	--surface: #f6f7fb;
	--surface-2: #eef1f7;
	--card: #ffffff;
	--ink: #0b1324;
	--ink-2: #334055;
	--muted: #667085;
	--line: #e6e9f0;
	--line-2: #d9dee8;
	--accent: #2448d8;
	--accent-ink: #ffffff;
	--accent-soft: #eaf0ff;
	--accent-2: #f5a524;
	--navy: #0a1430;
	--logo-mark-bg: #0b1324;
	--logo-mark-fg: #ffffff;
	--shadow-sm: 0 1px 2px rgba(16, 24, 40, .05);
	--shadow: 0 1px 2px rgba(16, 24, 40, .04), 0 6px 20px -6px rgba(16, 24, 40, .10);
	--shadow-lg: 0 2px 4px rgba(16, 24, 40, .04), 0 18px 40px -12px rgba(16, 24, 40, .20);
	--radius-sm: 10px;
	--radius: 16px;
	--radius-lg: 22px;
	--font-sans: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
	--font-serif: "Newsreader", "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, "Times New Roman", serif;
	--container: 1240px;
	--gutter: 16px;
	--header-h: 68px;
	--ease: cubic-bezier(.2, .7, .2, 1);
	color-scheme: light;
}

[data-theme="dark"] {
	--bg: #0a0f1d;
	--surface: #0f1628;
	--surface-2: #141d33;
	--card: #111a2e;
	--ink: #eef2f9;
	--ink-2: #c5cddb;
	--muted: #8e98ab;
	--line: #1e2940;
	--line-2: #28354f;
	--accent: #7b95ff;
	--accent-ink: #0a0f1d;
	--accent-soft: #18234a;
	--logo-mark-bg: #eef2f9;
	--logo-mark-fg: #0a0f1d;
	--shadow-sm: 0 1px 2px rgba(0, 0, 0, .3);
	--shadow: 0 1px 2px rgba(0, 0, 0, .25), 0 8px 24px -8px rgba(0, 0, 0, .5);
	--shadow-lg: 0 2px 4px rgba(0, 0, 0, .3), 0 20px 44px -12px rgba(0, 0, 0, .6);
	color-scheme: dark;
}

/* 2. Base ------------------------------------------------------------------ */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-padding-top: calc(var(--header-h) + 20px); }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
body {
	margin: 0;
	background: var(--bg);
	color: var(--ink);
	font-family: var(--font-sans);
	font-size: 16px;
	line-height: 1.6;
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
	text-rendering: optimizeLegibility;
	overflow-x: hidden;
}
img, svg, video { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
a:hover { color: var(--accent); }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
h1, h2, h3, h4, h5, h6 { margin: 0; color: var(--ink); font-weight: 700; line-height: 1.2; letter-spacing: -.015em; }
p { margin: 0; }
ul, ol { margin: 0; padding: 0; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 6px; }
::selection { background: var(--accent); color: #fff; }
.icon { flex-shrink: 0; }
.icon--flip { transform: rotate(180deg); }
.screen-reader-text {
	border: 0; clip: rect(1px, 1px, 1px, 1px); clip-path: inset(50%); height: 1px; margin: -1px;
	overflow: hidden; padding: 0; position: absolute !important; width: 1px; word-wrap: normal !important;
}
.screen-reader-text:focus { clip: auto; clip-path: none; height: auto; width: auto; z-index: 100000; }
.skip-link {
	position: absolute; left: 12px; top: -60px; z-index: 1000; background: var(--ink); color: var(--bg);
	padding: 10px 16px; border-radius: 8px; font-weight: 600; transition: top .2s;
}
.skip-link:focus { top: 12px; color: var(--bg); }
.hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; opacity: 0; }

/* 3. Layout ---------------------------------------------------------------- */
.container { width: 100%; max-width: calc(var(--container) + var(--gutter) * 2); margin-inline: auto; padding-inline: var(--gutter); }
.container--narrow { max-width: calc(800px + var(--gutter) * 2); }
.container--mid { max-width: calc(1080px + var(--gutter) * 2); }
.site-main { min-height: 60vh; }
.section { padding-block: 44px; }
.section + .section { padding-top: 12px; }
.section--surface { background: var(--surface); padding-block: 56px; margin-block: 32px; }
.section--surface + .section { padding-top: 44px; }
.grid { display: grid; gap: 28px; }
.grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

.btn {
	display: inline-flex; align-items: center; justify-content: center; gap: 8px;
	height: 44px; padding: 0 20px; border-radius: 999px; border: 1px solid transparent;
	font-weight: 600; font-size: 15px; line-height: 1; white-space: nowrap;
	transition: background-color .2s, color .2s, border-color .2s, transform .2s var(--ease), box-shadow .2s;
}
.btn--primary { background: var(--accent); color: var(--accent-ink); }
.btn--primary:hover { color: var(--accent-ink); filter: brightness(1.07); box-shadow: 0 8px 20px -8px color-mix(in srgb, var(--accent) 70%, transparent); }
.btn--ghost { border-color: var(--line-2); background: var(--card); color: var(--ink); }
.btn--ghost:hover { border-color: var(--ink); color: var(--ink); }
.btn--lg { height: 52px; padding: 0 26px; font-size: 16px; }
.btn[disabled] { opacity: .6; pointer-events: none; }
.icon-btn {
	display: inline-grid; place-items: center; width: 42px; height: 42px; border-radius: 12px;
	border: 1px solid transparent; background: transparent; color: var(--ink); transition: background-color .2s, border-color .2s, color .2s;
}
.icon-btn:hover { background: var(--surface-2); color: var(--ink); }

/* Section head */
.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 24px; padding-bottom: 14px; border-bottom: 1px solid var(--line); position: relative; }
.section-head::after { content: ""; position: absolute; left: 0; bottom: -1px; width: 56px; height: 2px; background: var(--cat, var(--accent)); border-radius: 2px; }
.section-head__titles { display: flex; align-items: center; gap: 12px; min-width: 0; }
.section-head__icon { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 11px; background: color-mix(in srgb, var(--cat, var(--accent)) 12%, transparent); color: var(--cat, var(--accent)); }
.section-head__kicker { font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); margin-bottom: 2px; }
.section-head__title { font-family: var(--font-serif); font-size: clamp(1.5rem, 1.2rem + 1vw, 1.95rem); font-weight: 600; letter-spacing: -.01em; }
.section-head__link { display: inline-flex; align-items: center; gap: 6px; font-size: 14px; font-weight: 600; color: var(--ink-2); white-space: nowrap; }
.section-head__link .icon { transition: transform .2s var(--ease); }
.section-head__link:hover { color: var(--cat, var(--accent)); }
.section-head__link:hover .icon { transform: translateX(3px); }

/* 4. Header ---------------------------------------------------------------- */
.topbar { border-bottom: 1px solid var(--line); font-size: 13px; color: var(--muted); }
.topbar__inner { display: flex; align-items: center; justify-content: space-between; height: 38px; gap: 16px; }
.topbar__left { display: flex; align-items: center; gap: 14px; }
.topbar__left .dot { width: 4px; height: 4px; border-radius: 50%; background: var(--line-2); }
.topbar .social { gap: 2px; }
.topbar .social a { width: 30px; height: 30px; }

.site-header {
	position: sticky; top: 0; z-index: 50;
	background: color-mix(in srgb, var(--bg) 86%, transparent);
	-webkit-backdrop-filter: saturate(180%) blur(14px); backdrop-filter: saturate(180%) blur(14px);
	border-bottom: 1px solid var(--line);
	transition: box-shadow .25s;
}
.site-header.is-scrolled { box-shadow: 0 6px 24px -14px rgba(16, 24, 40, .25); }
.admin-bar .site-header { top: 32px; }
@media (max-width: 782px) { .admin-bar .site-header { top: 46px; } }
@media (max-width: 600px) { .admin-bar .site-header { top: 0; } }
.site-header__inner { display: flex; align-items: center; height: var(--header-h); gap: 20px; }

.logo { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); flex-shrink: 0; }
.logo:hover { color: var(--ink); }
.logo__mark svg { width: 34px; height: 34px; }
.logo__text { font-family: var(--font-serif); font-size: 26px; line-height: 1; letter-spacing: -.02em; display: inline-flex; align-items: baseline; }
.logo__worldly { font-weight: 700; }
.logo__brief { font-weight: 500; font-style: italic; color: var(--accent); margin-left: 1px; }
.custom-logo-link img { max-height: 44px; width: auto; }

.primary-nav { margin-inline: auto; }
.primary-nav ul { list-style: none; display: flex; align-items: center; gap: 2px; }
.primary-nav a {
	position: relative; display: inline-flex; align-items: center; height: 40px; padding: 0 12px;
	font-size: 14.5px; font-weight: 500; color: var(--ink-2); border-radius: 10px; transition: color .2s, background-color .2s;
}
.primary-nav a:hover { color: var(--ink); background: var(--surface-2); }
.primary-nav .current-menu-item > a, .primary-nav .current-category-ancestor > a, .primary-nav .current-post-ancestor > a, .primary-nav .current-menu-parent > a {
	color: var(--ink); font-weight: 600;
}
.primary-nav .current-menu-item > a::after, .primary-nav .current-category-ancestor > a::after, .primary-nav .current-post-ancestor > a::after {
	content: ""; position: absolute; left: 12px; right: 12px; bottom: 4px; height: 2px; border-radius: 2px; background: var(--accent);
}
.primary-nav .sub-menu { display: none; }
.header-actions { display: flex; align-items: center; gap: 4px; margin-left: auto; }
.primary-nav + .header-actions { margin-left: 0; }

.theme-toggle .icon-sun { display: none; }
[data-theme="dark"] .theme-toggle .icon-sun { display: block; }
[data-theme="dark"] .theme-toggle .icon-moon { display: none; }

.hamburger { display: none; position: relative; }
.hamburger__lines { position: relative; width: 20px; height: 14px; }
.hamburger__lines span { position: absolute; left: 0; width: 100%; height: 2px; border-radius: 2px; background: currentColor; transition: transform .35s var(--ease), opacity .2s, top .35s var(--ease), width .35s var(--ease); }
.hamburger__lines span:nth-child(1) { top: 0; }
.hamburger__lines span:nth-child(2) { top: 6px; width: 70%; }
.hamburger__lines span:nth-child(3) { top: 12px; }
.menu-open .hamburger__lines span:nth-child(1) { top: 6px; transform: rotate(45deg); }
.menu-open .hamburger__lines span:nth-child(2) { opacity: 0; width: 0; }
.menu-open .hamburger__lines span:nth-child(3) { top: 6px; transform: rotate(-45deg); }

/* Reading progress */
.progress { position: absolute; left: 0; bottom: -1px; height: 2px; width: 100%; transform-origin: 0 50%; transform: scaleX(0); background: var(--accent); }

/* 5. Mobile menu + search overlay ------------------------------------------ */
.drawer {
	position: fixed; inset: 0; z-index: 60; visibility: hidden; pointer-events: none;
}
.drawer__backdrop { position: absolute; inset: 0; background: rgba(6, 10, 22, .5); opacity: 0; transition: opacity .3s; }
.drawer__panel {
	position: absolute; top: 0; right: 0; height: 100%; width: min(380px, 88vw); background: var(--bg);
	box-shadow: var(--shadow-lg); transform: translateX(100%); transition: transform .4s var(--ease);
	display: flex; flex-direction: column; overflow-y: auto; overscroll-behavior: contain;
}
.menu-open .drawer { visibility: visible; pointer-events: auto; }
.menu-open .drawer__backdrop { opacity: 1; }
.menu-open .drawer__panel { transform: none; }
.drawer__head { display: flex; align-items: center; justify-content: space-between; padding: 14px 16px; border-bottom: 1px solid var(--line); }
.drawer__search { padding: 16px; }
.drawer nav ul { list-style: none; padding: 8px 8px 16px; }
.drawer nav li { opacity: 0; transform: translateX(16px); transition: opacity .35s, transform .35s var(--ease); }
.menu-open .drawer nav li { opacity: 1; transform: none; }
.menu-open .drawer nav li:nth-child(2) { transition-delay: .03s; } .menu-open .drawer nav li:nth-child(3) { transition-delay: .06s; }
.menu-open .drawer nav li:nth-child(4) { transition-delay: .09s; } .menu-open .drawer nav li:nth-child(5) { transition-delay: .12s; }
.menu-open .drawer nav li:nth-child(6) { transition-delay: .15s; } .menu-open .drawer nav li:nth-child(7) { transition-delay: .18s; }
.menu-open .drawer nav li:nth-child(8) { transition-delay: .21s; } .menu-open .drawer nav li:nth-child(9) { transition-delay: .24s; }
.drawer nav a { display: flex; align-items: center; justify-content: space-between; padding: 13px 12px; font-size: 17px; font-weight: 600; border-radius: 12px; }
.drawer nav a:hover, .drawer nav .current-menu-item > a { background: var(--surface); }
.drawer nav a::after { content: ""; width: 7px; height: 7px; border-right: 2px solid var(--muted); border-top: 2px solid var(--muted); transform: rotate(45deg); }
.drawer__foot { margin-top: auto; padding: 16px; border-top: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.drawer__foot small { color: var(--muted); }
body.menu-open, body.search-open { overflow: hidden; }

.search-overlay {
	position: fixed; inset: 0; z-index: 70; display: grid; align-items: start; justify-items: center; padding: 10vh 16px 16px;
	background: color-mix(in srgb, var(--bg) 70%, rgba(6, 10, 22, .55)); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
	opacity: 0; visibility: hidden; transition: opacity .25s, visibility .25s;
}
.search-open .search-overlay { opacity: 1; visibility: visible; }
.search-overlay__box {
	width: min(720px, 100%); background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-lg);
	box-shadow: var(--shadow-lg); padding: 20px; transform: translateY(-12px) scale(.98); transition: transform .3s var(--ease);
}
.search-open .search-overlay__box { transform: none; }
.search-overlay__top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.search-overlay__top p { font-size: 13px; font-weight: 600; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
.search-overlay__topics { margin-top: 18px; }
.search-overlay__topics p { font-size: 13px; color: var(--muted); margin-bottom: 10px; }

.search-form { position: relative; display: flex; align-items: center; gap: 8px; width: 100%; }
.search-form__field { position: relative; flex: 1; min-width: 0; }
.search-form__field .icon { position: absolute; left: 16px; top: 50%; transform: translateY(-50%); color: var(--muted); pointer-events: none; }
.search-form input[type="search"] {
	width: 100%; height: 54px; padding: 0 16px 0 46px; border-radius: 14px; border: 1px solid var(--line-2);
	background: var(--surface); font-size: 17px; outline: none; transition: border-color .2s, box-shadow .2s, background-color .2s;
}
.search-form input[type="search"]:focus { border-color: var(--accent); background: var(--card); box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 16%, transparent); }
.search-form select {
	height: 54px; border-radius: 14px; border: 1px solid var(--line-2); background: var(--surface); padding: 0 34px 0 14px; max-width: 170px;
	appearance: none; -webkit-appearance: none;
	background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%);
	background-position: calc(100% - 18px) 50%, calc(100% - 13px) 50%; background-size: 5px 5px; background-repeat: no-repeat;
}
.search-form .btn { height: 54px; border-radius: 14px; }
.search-form--compact input[type="search"], .search-form--compact .btn { height: 46px; font-size: 15px; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
	display: inline-flex; align-items: center; gap: 7px; height: 36px; padding: 0 14px; border-radius: 999px;
	border: 1px solid var(--line-2); background: var(--card); font-size: 14px; font-weight: 500; color: var(--ink-2);
	transition: border-color .2s, color .2s, background-color .2s;
}
.chip .icon { color: var(--cat, var(--accent)); }
.chip:hover, .chip.is-active { border-color: var(--cat, var(--accent)); color: var(--ink); background: color-mix(in srgb, var(--cat, var(--accent)) 8%, var(--card)); }

/* 6. Cards ----------------------------------------------------------------- */
.badge {
	display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase;
	color: var(--cat, var(--accent)); line-height: 1.2;
}
.badge::before { content: ""; width: 6px; height: 6px; border-radius: 2px; background: currentColor; }
[data-theme="dark"] .badge { color: color-mix(in srgb, var(--cat, var(--accent)) 60%, #fff); }
a.badge:hover { color: var(--ink); }

.meta { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 0; font-size: 13px; color: var(--muted); }
.meta > * + *::before { content: "·"; margin: 0 8px; color: var(--line-2); }
.meta__author { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; color: var(--ink-2); }
.meta__author::before { display: none; }
.meta__author + *::before { content: "·"; margin: 0 8px; }
.avatar { border-radius: 50%; object-fit: cover; background: var(--surface-2); }
.avatar--xs { width: 24px; height: 24px; }

.card { position: relative; display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.card__media { position: relative; display: block; overflow: hidden; border-radius: var(--radius); aspect-ratio: 16 / 10; background: var(--surface-2); isolation: isolate; }
.card__media img, .card__img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ease); }
.card:hover .card__media img { transform: scale(1.04); }
.card__placeholder {
	position: absolute; inset: 0; display: grid; place-items: center; color: color-mix(in srgb, var(--cat) 80%, #fff);
	background:
		radial-gradient(120% 90% at 100% 0%, color-mix(in srgb, var(--cat) 35%, transparent) 0%, transparent 60%),
		radial-gradient(100% 80% at 0% 100%, color-mix(in srgb, var(--cat) 22%, transparent) 0%, transparent 60%),
		linear-gradient(135deg, color-mix(in srgb, var(--cat) 14%, var(--surface)) 0%, var(--surface-2) 100%);
}
.card__placeholder .icon { width: 44px; height: 44px; opacity: .85; }
.card__body { display: flex; flex-direction: column; gap: 9px; min-width: 0; }
.card__title { font-family: var(--font-serif); font-weight: 600; font-size: 1.28rem; line-height: 1.25; letter-spacing: -.01em; }
.card__title a { background-image: linear-gradient(currentColor, currentColor); background-size: 0 1px; background-repeat: no-repeat; background-position: 0 100%; transition: background-size .35s var(--ease), color .2s; }
.card:hover .card__title a { background-size: 100% 1px; color: var(--ink); }
.card__excerpt { color: var(--ink-2); font-size: 15px; line-height: 1.55; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }

/* Hero card */
.card--hero .card__media { aspect-ratio: 16 / 9; border-radius: var(--radius-lg); }
.card--hero .card__title { font-size: clamp(1.7rem, 1.2rem + 1.6vw, 2.45rem); line-height: 1.12; letter-spacing: -.02em; }
.card--hero .card__excerpt { font-size: 17px; -webkit-line-clamp: 2; }
.card--hero .card__body { gap: 12px; }

/* Side card: thumb left */
.card--side, .card--compact { flex-direction: row; align-items: flex-start; gap: 16px; }
.card--side .card__media, .card--compact .card__media { width: 124px; flex-shrink: 0; aspect-ratio: 1 / 1; border-radius: 12px; }
.card--side .card__title, .card--compact .card__title { font-size: 1.06rem; line-height: 1.3; }
.card--side .card__body, .card--compact .card__body { gap: 7px; }
.card--compact .card__media { width: 96px; aspect-ratio: 4 / 3; }

/* Horizontal */
.card--horizontal { flex-direction: row; align-items: center; gap: 28px; }
.card--horizontal .card__media { width: 54%; flex-shrink: 0; aspect-ratio: 16 / 10; border-radius: var(--radius-lg); }
.card--horizontal .card__title { font-size: clamp(1.45rem, 1.1rem + 1vw, 2rem); line-height: 1.15; }
.card--horizontal .card__excerpt { font-size: 16px; }

/* Overlay */
.card--overlay { display: block; border-radius: var(--radius-lg); overflow: hidden; min-height: 320px; color: #fff; background: #0b1324; }
.card--overlay .card__media { position: absolute; inset: 0; aspect-ratio: auto; border-radius: 0; }
.card--overlay .card__media::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(5, 9, 20, 0) 25%, rgba(5, 9, 20, .55) 55%, rgba(5, 9, 20, .92) 100%); }
.card--overlay .card__body { position: absolute; left: 0; right: 0; bottom: 0; padding: 26px; z-index: 1; }
.card--overlay .card__title { color: #fff; font-size: 1.5rem; }
.card--overlay .card__title a:hover, .card--overlay:hover .card__title a { color: #fff; }
.card--overlay .card__excerpt { color: rgba(255, 255, 255, .82); -webkit-line-clamp: 2; }
.card--overlay .badge { color: #fff; background: color-mix(in srgb, var(--cat) 85%, #000); padding: 6px 10px; border-radius: 999px; align-self: flex-start; }
.card--overlay .badge::before { display: none; }
.card--overlay .meta, .card--overlay .meta__author { color: rgba(255, 255, 255, .8); }
.card--overlay .meta > * + *::before { color: rgba(255, 255, 255, .45); }

/* Numbered */
.card--numbered { flex-direction: row; gap: 16px; align-items: flex-start; }
.card__num { font-family: var(--font-serif); font-size: 2.2rem; font-weight: 600; line-height: .9; color: color-mix(in srgb, var(--cat, var(--accent)) 70%, var(--line-2)); min-width: 44px; font-variant-numeric: tabular-nums; }
.card--numbered .card__title { font-size: 1.08rem; }

/* Minimal */
.card--minimal { padding: 18px 0; border-top: 1px solid var(--line); }
.card--minimal .card__title { font-size: 1.15rem; }

/* Card on surface */
.section--surface .card--standard { background: var(--card); border-radius: var(--radius-lg); padding: 12px 12px 20px; box-shadow: var(--shadow-sm); border: 1px solid var(--line); transition: box-shadow .3s, transform .3s var(--ease); }
.section--surface .card--standard:hover { box-shadow: var(--shadow); transform: translateY(-3px); }
.section--surface .card--standard .card__body { padding-inline: 8px; }
.section--surface .card--standard .card__media { border-radius: 12px; }

/* 7. Home sections --------------------------------------------------------- */
.home-hero { padding-block: 32px 40px; }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.65fr) minmax(0, 1fr); gap: 40px; }
.hero-side { display: flex; flex-direction: column; }
.hero-side__label { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); padding-bottom: 14px; border-bottom: 1px solid var(--line); }
.hero-side__label .icon { color: var(--accent); }
.hero-side .card { padding-block: 18px; border-bottom: 1px solid var(--line); }
.hero-side .card:last-child { border-bottom: 0; padding-bottom: 0; }

/* Trending rail */
.rail-wrap { position: relative; }
.rail {
	display: grid; grid-auto-flow: column; grid-auto-columns: minmax(270px, 1fr); gap: 20px; overflow-x: auto;
	scroll-snap-type: x mandatory; scrollbar-width: none; padding: 4px 2px 8px; margin: -4px -2px -8px;
}
.rail::-webkit-scrollbar { display: none; }
.rail > * { scroll-snap-align: start; }
.rail .card--trend {
	flex-direction: column; gap: 14px; padding: 14px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--card);
	transition: border-color .25s, box-shadow .25s, transform .25s var(--ease);
}
.rail .card--trend:hover { border-color: var(--line-2); box-shadow: var(--shadow); transform: translateY(-2px); }
.card--trend .trend__top { display: flex; align-items: center; gap: 14px; }
.card--trend .card__media { width: 76px; aspect-ratio: 1; border-radius: 12px; flex-shrink: 0; }
.card--trend .card__num { font-size: 2rem; min-width: 0; }
.card--trend .card__title { font-size: 1.05rem; line-height: 1.32; }
.rail-nav { display: flex; gap: 6px; }
.rail-nav .icon-btn { border: 1px solid var(--line-2); border-radius: 50%; width: 38px; height: 38px; }
.rail-nav .icon-btn[disabled] { opacity: .35; pointer-events: none; }

/* Latest */
.latest-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 40px 28px; }
.load-more { display: flex; justify-content: center; margin-top: 40px; }
.load-more .btn { min-width: 220px; }

/* Topics */
.topics { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 14px; }
.topic {
	position: relative; display: flex; flex-direction: column; gap: 14px; padding: 18px; border-radius: var(--radius); border: 1px solid var(--line);
	background: var(--card); overflow: hidden; transition: border-color .25s, transform .25s var(--ease), box-shadow .25s;
}
.topic::before { content: ""; position: absolute; inset: auto -30% -60% auto; width: 140px; height: 140px; border-radius: 50%; background: color-mix(in srgb, var(--cat) 10%, transparent); transition: transform .5s var(--ease); }
.topic:hover { border-color: color-mix(in srgb, var(--cat) 45%, var(--line)); transform: translateY(-3px); box-shadow: var(--shadow); color: var(--ink); }
.topic:hover::before { transform: scale(1.3); }
.topic__icon { position: relative; display: grid; place-items: center; width: 42px; height: 42px; border-radius: 12px; background: color-mix(in srgb, var(--cat) 12%, transparent); color: var(--cat); }
[data-theme="dark"] .topic__icon, [data-theme="dark"] .section-head__icon { color: color-mix(in srgb, var(--cat, var(--accent)) 60%, #fff); }
.topic__name { position: relative; font-weight: 700; font-size: 15px; }
.topic__count { position: relative; font-size: 12.5px; color: var(--muted); margin-top: -10px; }

/* Layout A — feature + 2x2 */
.layout-a { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 36px; }
.layout-a__list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px 24px; align-content: start; }
.layout-a__list .card__title { font-size: 1.08rem; }
.layout-a__list .card__excerpt { display: none; }
.layout-a .card--standard:first-child .card__title { font-size: clamp(1.4rem, 1.1rem + 1vw, 1.85rem); }

/* Layout B — dark band with overlay cards */
.band { background: var(--navy); color: #fff; padding-block: 56px; margin-block: 32px; position: relative; overflow: hidden; }
.band::before { content: ""; position: absolute; inset: -40% -10% auto auto; width: 620px; height: 620px; border-radius: 50%; background: radial-gradient(closest-side, color-mix(in srgb, var(--cat, #7c3aed) 45%, transparent), transparent); opacity: .55; pointer-events: none; }
.band .section-head { border-color: rgba(255, 255, 255, .12); }
.band .section-head__title, .band .section-head__link { color: #fff; }
.band .section-head__kicker { color: rgba(255, 255, 255, .6); }
.band .section-head__icon { background: rgba(255, 255, 255, .08); color: #c4b5fd; }
.layout-b { position: relative; display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) minmax(0, 1fr); gap: 20px; }
.layout-b .card--overlay { min-height: 420px; }
.layout-b .card--overlay:first-child .card__title { font-size: 1.85rem; }
.layout-b__stack { display: grid; }
.layout-b__stack .card--overlay { min-height: 420px; }
.layout-b__stack .card--overlay .card__title { font-size: 1.15rem; }
.layout-b__stack .card--overlay .card__excerpt { display: none; }
.band + .section { padding-top: 44px; }

/* Layout C — horizontal feature + list */
.layout-c { display: grid; grid-template-columns: minmax(0, 1.9fr) minmax(0, 1fr); gap: 40px; }
.layout-c__list { display: flex; flex-direction: column; gap: 20px; }
.layout-c__list .card { padding-bottom: 20px; border-bottom: 1px solid var(--line); }
.layout-c__list .card:last-child { border-bottom: 0; padding-bottom: 0; }
.layout-c .card--horizontal { flex-direction: column; align-items: stretch; gap: 18px; }
.layout-c .card--horizontal .card__media { width: 100%; }

/* Layout D — 4 col */
.layout-d { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 28px 24px; }
.layout-d .card__title { font-size: 1.12rem; }
.layout-d .card__excerpt { -webkit-line-clamp: 2; font-size: 14.5px; }

/* Layout E — mosaic */
.layout-e { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); grid-template-rows: repeat(2, minmax(250px, auto)); gap: 20px; }
.layout-e .card--overlay:first-child { grid-row: span 2; min-height: 520px; }
.layout-e .card--overlay:first-child .card__title { font-size: 1.9rem; }
.layout-e .card--overlay:not(:first-child) { min-height: 250px; }
.layout-e .card--overlay:not(:first-child) .card__excerpt { display: none; }

/* Layout F — 3 standard with borders */
.layout-f { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px; }

/* Layout G — how-to numbered with thumbs */
.layout-g { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 40px; counter-reset: step; }
.layout-g .card { padding-block: 20px; border-bottom: 1px solid var(--line); counter-increment: step; }
.layout-g .card--compact .card__media::before {
	content: counter(step, decimal-leading-zero); position: absolute; left: 8px; top: 8px; z-index: 2; font-size: 11px; font-weight: 700;
	color: #fff; background: rgba(5, 9, 20, .7); border-radius: 6px; padding: 3px 6px; font-variant-numeric: tabular-nums;
}
.layout-g .card--compact .card__media { width: 132px; }
.layout-g .card__title { font-size: 1.12rem; }

/* Editor's picks */
.picks { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: 28px; }
.picks__list { display: grid; gap: 18px; align-content: start; }
.picks__list .card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; box-shadow: var(--shadow-sm); }
.picks .card--overlay { min-height: 460px; }
.picks .card--overlay .card__title { font-size: clamp(1.5rem, 1.1rem + 1.2vw, 2.1rem); }
.pick-star { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--accent-2); }

/* Newsletter */
.newsletter {
	position: relative; overflow: hidden; border-radius: 28px; padding: clamp(32px, 5vw, 64px); color: #fff;
	background:
		radial-gradient(60% 120% at 100% 0%, rgba(123, 149, 255, .45), transparent 60%),
		radial-gradient(50% 90% at 0% 100%, rgba(245, 165, 36, .22), transparent 60%),
		linear-gradient(135deg, #0a1430 0%, #13235a 100%);
	display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 40px; align-items: center;
}
.newsletter::after {
	content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .18;
	background-image: radial-gradient(rgba(255, 255, 255, .6) 1px, transparent 1px); background-size: 22px 22px;
	-webkit-mask-image: linear-gradient(90deg, transparent, #000 70%); mask-image: linear-gradient(90deg, transparent, #000 70%);
}
.newsletter > * { position: relative; z-index: 1; }
.newsletter__eyebrow { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; color: rgba(255, 255, 255, .75); margin-bottom: 14px; }
.newsletter__title { color: #fff; font-family: var(--font-serif); font-size: clamp(1.9rem, 1.3rem + 2vw, 2.8rem); font-weight: 600; line-height: 1.1; letter-spacing: -.02em; }
.newsletter__text { color: rgba(255, 255, 255, .8); font-size: 17px; margin-top: 14px; max-width: 520px; }
.nl-form__row { position: relative; display: flex; gap: 8px; background: #fff; border-radius: 16px; padding: 6px; box-shadow: 0 20px 40px -20px rgba(0, 0, 0, .5); }
.nl-form__icon { position: absolute; left: 20px; top: 50%; transform: translateY(-50%); color: #667085; }
.nl-form input[type="email"] { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; color: #0b1324; height: 48px; padding: 0 12px 0 44px; font-size: 16px; }
.nl-form .btn { height: 48px; border-radius: 12px; background: #2448d8; color: #fff; }
.nl-form__note { margin-top: 12px; font-size: 13px; color: rgba(255, 255, 255, .7); }
.nl-form__note a { text-decoration: underline; text-underline-offset: 2px; }
.nl-form__note.is-success { color: #86efac; font-weight: 600; }
.nl-form__note.is-error { color: #fecaca; font-weight: 600; }

/* Ad slots */
.ad-slot { margin: 36px auto; text-align: center; min-height: 0; }
.ad-slot__label { display: block; font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin-bottom: 8px; }
.ad-slot--mid { margin: 40px 0; padding: 16px 0; border-block: 1px solid var(--line); }

/* 8. Article --------------------------------------------------------------- */
.breadcrumbs ol { list-style: none; display: flex; flex-wrap: wrap; align-items: center; gap: 4px; font-size: 13.5px; color: var(--muted); }
.breadcrumbs li { display: inline-flex; align-items: center; gap: 4px; }
.breadcrumbs a { color: var(--ink-2); }
.breadcrumbs a:hover { color: var(--accent); }
.breadcrumbs [aria-current] span { display: inline-block; max-width: 40ch; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; vertical-align: bottom; }
.breadcrumbs .icon { color: var(--line-2); }

.article-header { padding-top: 32px; }
.article-header .breadcrumbs { margin-bottom: 22px; }
.article-header .badge { font-size: 13px; }
.article-title { font-family: var(--font-serif); font-weight: 600; font-size: clamp(2rem, 1.3rem + 2.8vw, 3.3rem); line-height: 1.08; letter-spacing: -.025em; margin: 14px 0 16px; text-wrap: balance; }
.article-dek { font-size: clamp(1.1rem, 1rem + .4vw, 1.3rem); line-height: 1.55; color: var(--ink-2); max-width: 720px; text-wrap: pretty; }
.byline { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 18px; margin-top: 26px; padding-block: 18px; border-block: 1px solid var(--line); }
.byline__author { display: flex; align-items: center; gap: 12px; }
.byline__author .avatar { width: 48px; height: 48px; }
.byline__name { font-weight: 700; font-size: 15px; color: var(--ink); }
.byline__name a:hover { color: var(--accent); }
.byline__role { font-size: 13px; color: var(--muted); }
.byline__dates { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 13px; color: var(--muted); margin-top: 2px; }
.byline__dates span { display: inline-flex; align-items: center; gap: 5px; }
.share { display: flex; align-items: center; gap: 6px; }
.share__btn {
	display: inline-grid; place-items: center; width: 38px; height: 38px; border-radius: 50%; border: 1px solid var(--line-2);
	background: var(--card); color: var(--ink-2); transition: all .2s;
}
.share__btn:hover { color: #fff; border-color: transparent; background: var(--ink); transform: translateY(-2px); }
.share__btn--facebook:hover { background: #1877f2; } .share__btn--linkedin:hover { background: #0a66c2; } .share__btn--whatsapp:hover { background: #25d366; }
.share__btn.is-copied { background: #16a34a; color: #fff; border-color: transparent; }

.article-figure { margin: 32px auto 0; }
.article-figure img { width: 100%; border-radius: var(--radius-lg); aspect-ratio: 16 / 9; object-fit: cover; background: var(--surface-2); }
.article-figure .card__placeholder { position: relative; aspect-ratio: 16 / 9; border-radius: var(--radius-lg); }
.article-figure figcaption { font-size: 13px; color: var(--muted); margin-top: 10px; text-align: center; }

.article-layout { display: grid; grid-template-columns: minmax(0, 1fr); justify-content: center; gap: 56px; padding-top: 40px; }
.has-article-sidebar .article-layout { grid-template-columns: minmax(0, 720px) 300px; }
.article-sidebar { position: relative; }
.article-sidebar__inner { position: sticky; top: calc(var(--header-h) + 24px); display: flex; flex-direction: column; gap: 28px; }
.widget__title { font-size: 13px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); margin-bottom: 14px; font-weight: 700; }
.widget ul { list-style: none; }
.widget li + li { margin-top: 8px; }

.article-body { max-width: 720px; width: 100%; margin-inline: auto; }
.article-footer { max-width: 720px; margin: 40px auto 0; }
.tags { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 28px; }
.tags a { font-size: 13px; padding: 6px 12px; border-radius: 999px; background: var(--surface); color: var(--ink-2); }
.tags a:hover { background: var(--accent-soft); color: var(--accent); }
.share-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; padding: 18px 0; border-block: 1px solid var(--line); }
.share-row p { font-weight: 600; }

.author-box {
	display: grid; grid-template-columns: 88px minmax(0, 1fr); gap: 22px; margin-top: 36px; padding: 28px; border-radius: var(--radius-lg);
	background: var(--surface); border: 1px solid var(--line);
}
.author-box .avatar { width: 88px; height: 88px; }
.author-box__kicker { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
.author-box__name { font-family: var(--font-serif); font-size: 1.45rem; font-weight: 600; margin: 2px 0 2px; }
.author-box__role { font-size: 14px; color: var(--accent); font-weight: 600; margin-bottom: 10px; }
.author-box__bio { color: var(--ink-2); font-size: 15.5px; }
.author-box__links { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-top: 16px; }
.author-box__links .link { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; font-size: 14px; color: var(--accent); }
.author-box__links .icon-btn { width: 36px; height: 36px; border: 1px solid var(--line-2); border-radius: 50%; }

.trust-note { display: flex; gap: 12px; align-items: flex-start; margin-top: 20px; padding: 16px 18px; border-radius: var(--radius); border: 1px dashed var(--line-2); font-size: 14px; color: var(--ink-2); }
.trust-note .icon { color: #16a34a; margin-top: 2px; }
.trust-note a { color: var(--accent); font-weight: 600; }

.related { padding-block: 56px; margin-top: 56px; background: var(--surface); }
.related .grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.related .card__title { font-size: 1.1rem; }
.related .card__excerpt { display: none; }

/* Comments */
.comments { max-width: 720px; margin: 48px auto 0; }
.comments__title { font-family: var(--font-serif); font-size: 1.6rem; font-weight: 600; margin-bottom: 20px; }
.comment-list { list-style: none; }
.comment-list .children { list-style: none; padding-left: 28px; border-left: 2px solid var(--line); margin-top: 16px; }
.comment-body { padding: 18px 0; border-bottom: 1px solid var(--line); }
.comment-meta { display: flex; align-items: center; gap: 10px; font-size: 14px; }
.comment-meta .avatar { width: 40px; height: 40px; }
.comment-metadata { font-size: 12.5px; color: var(--muted); }
.comment-content { margin-top: 10px; color: var(--ink-2); }
.comment-content p + p { margin-top: 10px; }
.reply a { font-size: 13px; font-weight: 600; color: var(--accent); }
.comment-respond { margin-top: 32px; }
.comment-reply-title { font-family: var(--font-serif); font-size: 1.4rem; font-weight: 600; margin-bottom: 12px; }
.comment-form p { margin-bottom: 14px; }
.comment-form label, .field label { display: block; font-size: 14px; font-weight: 600; margin-bottom: 6px; }
.comment-form input[type="text"], .comment-form input[type="email"], .comment-form input[type="url"], .comment-form textarea,
.field input, .field textarea, .field select {
	width: 100%; border: 1px solid var(--line-2); background: var(--card); border-radius: 12px; padding: 12px 14px; font-size: 16px; outline: none;
	transition: border-color .2s, box-shadow .2s;
}
.comment-form input:focus, .comment-form textarea:focus, .field input:focus, .field textarea:focus, .field select:focus { border-color: var(--accent); box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 14%, transparent); }
.comment-form .submit { height: 48px; padding: 0 24px; border-radius: 999px; border: 0; background: var(--accent); color: var(--accent-ink); font-weight: 600; }
.comment-form-cookies-consent { display: flex; gap: 8px; align-items: flex-start; font-size: 14px; }
.comment-form-cookies-consent label { font-weight: 400; margin: 0; }

/* 9. Prose ----------------------------------------------------------------- */
.prose { font-size: 1.125rem; line-height: 1.78; color: var(--ink-2); overflow-wrap: break-word; }
.prose > * + * { margin-top: 1.35em; }
.prose p { margin: 0; }
.prose > p:first-child::first-letter { }
.prose h2 { font-family: var(--font-serif); font-size: clamp(1.55rem, 1.3rem + .9vw, 2rem); font-weight: 600; line-height: 1.22; letter-spacing: -.015em; margin-top: 2em; color: var(--ink); }
.prose h3 { font-size: 1.3rem; font-weight: 700; line-height: 1.3; margin-top: 1.7em; color: var(--ink); letter-spacing: -.01em; }
.prose h4 { font-size: 1.1rem; font-weight: 700; margin-top: 1.5em; color: var(--ink); }
.prose h2 + *, .prose h3 + *, .prose h4 + * { margin-top: .7em; }
.prose a:not(.btn):not(.wp-block-button__link) { color: var(--accent); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; text-decoration-color: color-mix(in srgb, var(--accent) 40%, transparent); transition: text-decoration-color .2s; }
.prose a:not(.btn):hover { text-decoration-color: var(--accent); }
.prose strong { color: var(--ink); font-weight: 650; }
.prose ul, .prose ol { padding-left: 1.4em; }
.prose li + li { margin-top: .5em; }
.prose li::marker { color: var(--accent); font-weight: 700; }
.prose ul { list-style: none; padding-left: 1.5em; }
.prose ul > li { position: relative; }
.prose ul > li::before { content: ""; position: absolute; left: -1.1em; top: .72em; width: 7px; height: 7px; border-radius: 2px; background: var(--accent); transform: rotate(45deg); }
.prose ol { counter-reset: none; }
.prose blockquote, .prose .wp-block-quote {
	margin-inline: 0; padding: 6px 0 6px 26px; border-left: 3px solid var(--accent); font-family: var(--font-serif); font-size: 1.4rem;
	line-height: 1.45; color: var(--ink); font-style: italic;
}
.prose blockquote cite, .prose .wp-block-quote cite { display: block; margin-top: 10px; font-family: var(--font-sans); font-size: 14px; font-style: normal; color: var(--muted); }
.prose .wp-block-pullquote { border-block: 2px solid var(--ink); padding: 28px 0; text-align: center; }
.prose .wp-block-pullquote blockquote { border: 0; padding: 0; font-size: 1.6rem; }
.prose figure { margin-inline: 0; }
.prose img { border-radius: var(--radius); }
.prose figcaption, .prose .wp-element-caption { font-size: 14px; color: var(--muted); margin-top: 10px; text-align: center; }
.prose hr { border: 0; height: 1px; background: var(--line); margin-block: 2.5em; }
.prose code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: .88em; background: var(--surface-2); padding: .15em .4em; border-radius: 6px; color: var(--ink); }
.prose pre { background: #0b1324; color: #e5e9f2; padding: 20px; border-radius: var(--radius); overflow-x: auto; font-size: .9rem; line-height: 1.6; }
.prose pre code { background: none; padding: 0; color: inherit; }
.prose table { width: 100%; border-collapse: separate; border-spacing: 0; font-size: .95rem; line-height: 1.5; border: 1px solid var(--line); border-radius: 14px; overflow: hidden; }
.prose .wp-block-table, .prose .table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.prose .wp-block-table table { margin: 0; }
.prose th { background: var(--surface); color: var(--ink); font-weight: 700; text-align: left; font-size: .85rem; text-transform: uppercase; letter-spacing: .04em; }
.prose th, .prose td { padding: 12px 16px; border-bottom: 1px solid var(--line); vertical-align: top; }
.prose tr:last-child td { border-bottom: 0; }
.prose tbody tr:nth-child(even) td { background: color-mix(in srgb, var(--surface) 55%, transparent); }
.prose .wp-block-image.alignwide, .prose .alignwide { margin-inline: -60px; max-width: none; }
.prose .alignleft { float: left; margin: .4em 1.5em 1em 0; max-width: 50%; }
.prose .alignright { float: right; margin: .4em 0 1em 1.5em; max-width: 50%; }
.prose .aligncenter { margin-inline: auto; }
.prose .wp-block-embed iframe, .prose iframe { max-width: 100%; border-radius: var(--radius); }
.prose .wp-block-button__link { background: var(--accent); color: var(--accent-ink); border-radius: 999px; padding: 12px 22px; font-weight: 600; font-size: 1rem; }
.prose > p:first-of-type { font-size: 1.2rem; color: var(--ink); }

/* Info boxes */
.wb-box, .is-style-wb-info, .is-style-wb-tip, .is-style-wb-warning, .is-style-wb-key {
	--box: var(--accent); display: flex; gap: 14px; padding: 18px 20px; border-radius: 14px; font-size: 1.02rem; line-height: 1.65;
	background: color-mix(in srgb, var(--box) 8%, var(--bg)); border: 1px solid color-mix(in srgb, var(--box) 24%, transparent);
	color: var(--ink-2);
}
.is-style-wb-info, .is-style-wb-tip, .is-style-wb-warning, .is-style-wb-key { display: block; }
.wb-box--tip, .is-style-wb-tip { --box: #16a34a; }
.wb-box--warning, .is-style-wb-warning { --box: #d97706; }
.wb-box--key, .is-style-wb-key { --box: #7c3aed; }
.wb-box--check { --box: #16a34a; }
.wb-box__icon { color: var(--box); margin-top: 3px; }
.wb-box__body { min-width: 0; }
.wb-box__body > * + * { margin-top: .6em; }
.wb-box__title { font-weight: 700; color: var(--ink); }
.wb-box ul { padding-left: 1.2em; }
.contact-form .wb-box { margin-bottom: 20px; }

/* TOC */
.toc { border: 1px solid var(--line); border-radius: 16px; background: var(--surface); font-size: 1rem; }
.toc summary { list-style: none; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 20px; cursor: pointer; font-weight: 700; color: var(--ink); }
.toc summary::-webkit-details-marker { display: none; }
.toc__title { display: inline-flex; align-items: center; gap: 10px; }
.toc__title .icon { color: var(--accent); }
.toc__toggle { width: 9px; height: 9px; border-right: 2px solid var(--muted); border-bottom: 2px solid var(--muted); transform: rotate(45deg); transition: transform .25s; margin-right: 4px; }
.toc details[open] .toc__toggle { transform: rotate(-135deg); }
.toc__list { padding: 0 20px 18px 42px !important; margin: 0 !important; counter-reset: toc; list-style: none !important; }
.toc__list > li { counter-increment: toc; position: relative; }
.toc__list > li::before { content: counter(toc) "." !important; position: absolute; left: -24px; top: 0 !important; width: auto !important; height: auto !important; background: none !important; transform: none !important; color: var(--muted); font-size: .85rem; font-weight: 600; font-variant-numeric: tabular-nums; }
.toc__list ol { list-style: none; padding-left: 16px !important; margin-top: 6px; }
.toc__list ol li::before { display: none; }
.toc li + li { margin-top: 6px !important; }
.toc a { color: var(--ink-2) !important; text-decoration: none !important; font-size: .98rem; line-height: 1.45; }
.toc a:hover, .toc a.is-active { color: var(--accent) !important; }
.toc li::marker { content: none; }

/* FAQ */
.faq { display: grid; gap: 10px; }
.faq__item { border: 1px solid var(--line); border-radius: 14px; background: var(--card); transition: border-color .2s, box-shadow .2s; }
.faq__item[open] { border-color: var(--line-2); box-shadow: var(--shadow-sm); }
.faq__q { list-style: none; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 16px 20px; cursor: pointer; font-weight: 650; color: var(--ink); font-size: 1.05rem; line-height: 1.45; }
.faq__q::-webkit-details-marker { display: none; }
.faq__icon { position: relative; width: 22px; height: 22px; flex-shrink: 0; border-radius: 50%; background: var(--surface-2); }
.faq__icon::before, .faq__icon::after { content: ""; position: absolute; left: 50%; top: 50%; width: 10px; height: 2px; background: var(--ink-2); border-radius: 2px; transform: translate(-50%, -50%); transition: transform .25s; }
.faq__icon::after { transform: translate(-50%, -50%) rotate(90deg); }
.faq__item[open] .faq__icon::after { transform: translate(-50%, -50%) rotate(0); }
.faq__a { padding: 0 20px 18px; font-size: 1.02rem; }
.faq__a > * + * { margin-top: .7em; }

/* 10. Archive / search ----------------------------------------------------- */
.archive-hero { padding-block: 40px 36px; border-bottom: 1px solid var(--line); background: linear-gradient(180deg, color-mix(in srgb, var(--cat, var(--accent)) 6%, var(--bg)) 0%, var(--bg) 100%); }
.archive-hero .breadcrumbs { margin-bottom: 20px; }
.archive-hero__row { display: flex; align-items: flex-start; gap: 18px; }
.archive-hero__icon { display: grid; place-items: center; width: 60px; height: 60px; border-radius: 18px; background: color-mix(in srgb, var(--cat, var(--accent)) 14%, transparent); color: var(--cat, var(--accent)); flex-shrink: 0; }
[data-theme="dark"] .archive-hero__icon { color: color-mix(in srgb, var(--cat, var(--accent)) 60%, #fff); }
.archive-hero__kicker { font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.archive-title { font-family: var(--font-serif); font-size: clamp(2rem, 1.4rem + 2.2vw, 3rem); font-weight: 600; letter-spacing: -.02em; line-height: 1.1; margin-top: 4px; }
.archive-desc { margin-top: 12px; max-width: 720px; font-size: 1.08rem; color: var(--ink-2); }
.archive-desc p + p { margin-top: 8px; }
.archive-hero .chips { margin-top: 22px; }
.archive-feature { padding-block: 40px 8px; }
.archive-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 40px 28px; }
.pagination { margin-top: 48px; display: flex; justify-content: center; }
.pagination ul { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; }
.pagination a, .pagination span {
	display: inline-grid; place-items: center; min-width: 44px; height: 44px; padding: 0 12px; border-radius: 12px; border: 1px solid var(--line-2);
	font-weight: 600; font-size: 15px; color: var(--ink-2); background: var(--card); transition: all .2s;
}
.pagination a:hover { border-color: var(--ink); color: var(--ink); }
.pagination .current { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.pagination .dots { border: 0; background: none; }

.search-hero { padding-block: 44px 32px; background: var(--surface); border-bottom: 1px solid var(--line); }
.search-hero .archive-title { margin-bottom: 20px; }
.search-hero .archive-title em { font-style: italic; color: var(--accent); }
.search-hero .chips { margin-top: 16px; }
.results-count { font-size: 14px; color: var(--muted); margin-top: 14px; }
.empty-state { text-align: center; padding: 64px 0 24px; max-width: 580px; margin-inline: auto; }
.empty-state__icon { display: inline-grid; place-items: center; width: 72px; height: 72px; border-radius: 22px; background: var(--accent-soft); color: var(--accent); margin-bottom: 20px; }
.empty-state h2 { font-family: var(--font-serif); font-size: 1.8rem; font-weight: 600; }
.empty-state p { color: var(--ink-2); margin-top: 10px; }
.empty-state ul { list-style: none; text-align: left; display: inline-block; margin-top: 16px; color: var(--ink-2); }
.empty-state ul li::before { content: "→ "; color: var(--accent); }

/* Author archive */
.author-hero { padding-block: 44px; border-bottom: 1px solid var(--line); background: var(--surface); }
.author-hero__row { display: grid; grid-template-columns: 120px minmax(0, 1fr); gap: 28px; align-items: center; }
.author-hero .avatar { width: 120px; height: 120px; box-shadow: 0 0 0 6px var(--bg); }
.author-hero__role { color: var(--accent); font-weight: 600; margin-top: 6px; }
.author-hero__bio { margin-top: 12px; color: var(--ink-2); max-width: 720px; font-size: 1.05rem; }
.author-hero__meta { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 16px; align-items: center; }
.expertise { display: flex; flex-wrap: wrap; gap: 6px; }
.expertise span { font-size: 12.5px; padding: 5px 10px; border-radius: 999px; background: var(--card); border: 1px solid var(--line); color: var(--ink-2); }

/* 11. Pages ---------------------------------------------------------------- */
.page-hero { padding-block: 48px 36px; text-align: center; border-bottom: 1px solid var(--line); background: linear-gradient(180deg, var(--surface) 0%, var(--bg) 100%); }
.page-hero .breadcrumbs ol { justify-content: center; }
.page-hero .breadcrumbs { margin-bottom: 18px; }
.page-title { font-family: var(--font-serif); font-size: clamp(2.1rem, 1.4rem + 2.6vw, 3.2rem); font-weight: 600; letter-spacing: -.025em; line-height: 1.1; text-wrap: balance; }
.page-lead { margin: 14px auto 0; max-width: 640px; color: var(--ink-2); font-size: 1.12rem; }
.page-updated { margin-top: 14px; font-size: 13.5px; color: var(--muted); display: inline-flex; align-items: center; gap: 6px; }
.page-content { padding-block: 48px 72px; }
.page-content .prose > p:first-of-type { font-size: 1.125rem; color: var(--ink-2); }
.legal .prose h2 { font-size: 1.5rem; }

.values { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.values .value { padding: 22px; border-radius: 16px; border: 1px solid var(--line); background: var(--card); }
.values .value h3 { margin-top: 0 !important; font-size: 1.1rem; display: flex; align-items: center; gap: 10px; }
.values .value p { font-size: 1rem; margin-top: 8px !important; }
.values .value .dot { width: 10px; height: 10px; border-radius: 3px; background: var(--accent); transform: rotate(45deg); flex-shrink: 0; }

.contact-grid { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 48px; align-items: start; }
.contact-form { display: grid; gap: 4px; padding: 32px; border-radius: var(--radius-lg); border: 1px solid var(--line); background: var(--card); box-shadow: var(--shadow); }
.field-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.field { margin-bottom: 14px; }
.field select { appearance: auto; }
.field--consent label { display: flex; gap: 10px; align-items: flex-start; font-weight: 400; color: var(--ink-2); font-size: 14px; }
.field--consent input { width: auto; margin-top: 4px; }
.field--consent a { color: var(--accent); text-decoration: underline; }
.contact-aside { display: grid; gap: 16px; }
.info-card { padding: 22px; border-radius: 16px; background: var(--surface); border: 1px solid var(--line); display: flex; gap: 14px; }
.info-card .icon { color: var(--accent); margin-top: 2px; }
.info-card h3 { font-size: 1rem; }
.info-card p { font-size: 14.5px; color: var(--ink-2); margin-top: 4px; }
.info-card a { color: var(--accent); font-weight: 600; word-break: break-word; }

.authors-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
.author-card { display: flex; flex-direction: column; align-items: center; text-align: center; padding: 32px 24px; border-radius: var(--radius-lg); border: 1px solid var(--line); background: var(--card); transition: box-shadow .25s, transform .25s var(--ease); }
.author-card:hover { box-shadow: var(--shadow); transform: translateY(-3px); }
.author-card .avatar { width: 96px; height: 96px; margin-bottom: 16px; }
.author-card h2 { font-family: var(--font-serif); font-size: 1.35rem; font-weight: 600; }
.author-card__role { color: var(--accent); font-size: 14px; font-weight: 600; margin-top: 4px; }
.author-card__bio { color: var(--ink-2); font-size: 14.5px; margin-top: 12px; display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }
.author-card .expertise { justify-content: center; margin-top: 14px; }
.author-card__foot { margin-top: 18px; display: flex; gap: 10px; align-items: center; font-size: 13.5px; color: var(--muted); }
.author-card__foot a { color: var(--accent); font-weight: 600; }

.sitemap-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px; }
.sitemap-block h2 { font-family: var(--font-serif); font-size: 1.35rem; font-weight: 600; display: flex; align-items: center; gap: 10px; padding-bottom: 12px; border-bottom: 1px solid var(--line); margin-bottom: 12px; }
.sitemap-block h2 .icon { color: var(--cat, var(--accent)); }
.sitemap-block ul { list-style: none; }
.sitemap-block li { padding: 6px 0; font-size: 15px; }
.sitemap-block li a { color: var(--ink-2); }
.sitemap-block li a:hover { color: var(--accent); }
.sitemap-block .more { font-weight: 600; color: var(--accent); font-size: 14px; }
.sitemap-note { margin-top: 40px; font-size: 14px; color: var(--muted); }
.sitemap-note a { color: var(--accent); }

.error-404 { padding-block: 72px 40px; text-align: center; }
.error-404__code { font-family: var(--font-serif); font-size: clamp(6rem, 4rem + 10vw, 11rem); font-weight: 600; line-height: .9; letter-spacing: -.05em; background: linear-gradient(135deg, var(--ink) 20%, var(--accent)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.error-404 .page-title { margin-top: 12px; }
.error-404 .page-lead { margin-bottom: 28px; }
.error-404 .search-form { max-width: 620px; margin-inline: auto; }
.error-404 .chips { justify-content: center; margin-top: 22px; }

/* 12. Footer --------------------------------------------------------------- */
.site-footer { margin-top: 72px; background: #070d1f; color: #aab3c5; font-size: 15px; --logo-mark-bg: #eef2f9; --logo-mark-fg: #070d1f; }
.site-footer .logo { color: #fff; }
.site-footer .logo__brief { color: #8ea4ff; }
.footer-top { display: grid; grid-template-columns: minmax(0, 1.6fr) repeat(3, minmax(0, 1fr)); gap: 48px; padding-block: 64px 48px; }
.footer-about p { margin-top: 18px; max-width: 360px; line-height: 1.65; }
.footer-col h2 { color: #fff; font-size: 13px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; margin-bottom: 18px; }
.footer-col ul { list-style: none; }
.footer-col li + li { margin-top: 11px; }
.footer-col a { color: #aab3c5; transition: color .2s; }
.footer-col a:hover { color: #fff; }
.social { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; }
.social a { display: inline-grid; place-items: center; width: 40px; height: 40px; border-radius: 12px; color: inherit; transition: all .2s; }
.site-footer .social { margin-top: 24px; }
.site-footer .social a { background: rgba(255, 255, 255, .06); color: #dfe4ee; }
.site-footer .social a:hover { background: #fff; color: #070d1f; transform: translateY(-2px); }
.footer-bottom { border-top: 1px solid rgba(255, 255, 255, .08); }
.footer-bottom__inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; padding-block: 22px; font-size: 14px; }
.footer-bottom a { color: #aab3c5; }
.footer-bottom a:hover { color: #fff; }
.footer-bottom nav ul { list-style: none; display: flex; flex-wrap: wrap; gap: 18px; }

.to-top {
	position: fixed; right: 18px; bottom: 18px; z-index: 40; width: 46px; height: 46px; border-radius: 50%; border: 1px solid var(--line-2);
	background: var(--card); color: var(--ink); box-shadow: var(--shadow); display: grid; place-items: center;
	opacity: 0; visibility: hidden; transform: translateY(10px); transition: all .3s var(--ease);
}
.to-top.is-visible { opacity: 1; visibility: visible; transform: none; }
.to-top:hover { background: var(--ink); color: var(--bg); }

/* 13. Utilities ------------------------------------------------------------ */
.toast { position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 20px); background: var(--ink); color: var(--bg); padding: 10px 18px; border-radius: 999px; font-size: 14px; font-weight: 600; opacity: 0; transition: all .3s var(--ease); z-index: 90; pointer-events: none; }
.toast.is-visible { opacity: 1; transform: translate(-50%, 0); }
.divider { height: 1px; background: var(--line); border: 0; margin: 0; }
.wp-caption { max-width: 100%; }
.sticky, .gallery-caption, .bypostauthor { }
.alignnone { margin: 0; }

/* 14. Responsive ----------------------------------------------------------- */
@media (min-width: 768px) { :root { --gutter: 24px; } }
@media (min-width: 1280px) { :root { --gutter: 32px; } }

@media (max-width: 1180px) {
	.primary-nav a { padding: 0 9px; font-size: 14px; }
	.topics { grid-template-columns: repeat(4, minmax(0, 1fr)); }
	.related .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.has-article-sidebar .article-layout { grid-template-columns: minmax(0, 1fr); }
	.article-sidebar { display: none; }
	.layout-d { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 1023px) {
	.primary-nav { display: none; }
	.hamburger { display: inline-grid; }
	.header-actions { margin-left: auto !important; }
	.hero-grid, .layout-a, .layout-c, .picks, .newsletter, .contact-grid { grid-template-columns: minmax(0, 1fr); }
	.hero-grid { gap: 28px; }
	.hero-side { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 24px; }
	.hero-side__label { grid-column: 1 / -1; }
	.hero-side .card:last-child { border-bottom: 1px solid var(--line); padding-bottom: 18px; }
	.latest-grid, .archive-grid, .layout-f, .authors-grid, .sitemap-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.layout-b { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
	.layout-b > .card--overlay:first-child { grid-column: 1 / -1; min-height: 380px; }
	.layout-b__stack { grid-column: span 1; }
	.layout-b__stack .card--overlay { min-height: 280px; }
	.footer-top { grid-template-columns: repeat(3, minmax(0, 1fr)); }
	.footer-about { grid-column: 1 / -1; }
	.card--horizontal { flex-direction: column; align-items: stretch; gap: 18px; }
	.card--horizontal .card__media { width: 100%; }
	.prose .alignwide { margin-inline: 0; }
}

@media (max-width: 767px) {
	.topbar { display: none; }
	:root { --header-h: 60px; }
	.logo__text { font-size: 23px; }
	.logo__mark svg { width: 30px; height: 30px; }
	.section { padding-block: 32px; }
	.section--surface, .band { padding-block: 40px; margin-block: 20px; }
	.home-hero { padding-block: 20px 28px; }
	.hero-side { grid-template-columns: minmax(0, 1fr); }
	.card--hero .card__excerpt { font-size: 16px; }
	.grid--2, .grid--3, .grid--4, .latest-grid, .archive-grid, .layout-f, .layout-d, .layout-g, .authors-grid, .sitemap-grid, .values, .field-row { grid-template-columns: minmax(0, 1fr); }
	.latest-grid, .archive-grid { gap: 32px; }
	.layout-a__list { grid-template-columns: minmax(0, 1fr); gap: 0; }
	.layout-a__list .card { flex-direction: row; gap: 14px; padding-block: 16px; border-bottom: 1px solid var(--line); }
	.layout-a__list .card .card__media { width: 110px; flex-shrink: 0; aspect-ratio: 1; border-radius: 12px; }
	.layout-a__list .card:last-child { border-bottom: 0; }
	.layout-d .card { flex-direction: row; gap: 14px; }
	.layout-d .card .card__media { width: 110px; flex-shrink: 0; aspect-ratio: 1; border-radius: 12px; }
	.layout-d .card .card__excerpt { display: none; }
	.layout-b, .layout-e { grid-template-columns: minmax(0, 1fr); grid-template-rows: none; }
	.layout-b__stack { grid-column: auto; }
	.layout-b .card--overlay, .layout-e .card--overlay:first-child { min-height: 340px; }
	.layout-e .card--overlay:first-child { grid-row: auto; }
	.card--overlay .card__body { padding: 20px; }
	.card--overlay .card__title, .layout-b .card--overlay:first-child .card__title, .layout-e .card--overlay:first-child .card__title { font-size: 1.35rem; }
	.layout-g .card--compact .card__media { width: 104px; }
	.topics { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
	.topic { padding: 14px; flex-direction: row; align-items: center; gap: 12px; }
	.topic__count { display: none; }
	.picks .card--overlay { min-height: 380px; }
	.related .grid { grid-template-columns: minmax(0, 1fr); gap: 20px; }
	.related .card { flex-direction: row; gap: 14px; }
	.related .card .card__media { width: 110px; flex-shrink: 0; aspect-ratio: 1; border-radius: 12px; }
	.rail { grid-auto-columns: 82%; }
	.section-head__title { font-size: 1.45rem; }
	.section-head__link span { display: none; }
	.card__title { font-size: 1.18rem; }
	.card--side .card__media { width: 96px; }
	.byline { flex-direction: column; align-items: flex-start; }
	.article-header { padding-top: 20px; }
	.article-figure { margin-top: 24px; margin-inline: calc(var(--gutter) * -1); }
	.article-figure img, .article-figure .card__placeholder { border-radius: 0; }
	.prose { font-size: 1.07rem; line-height: 1.75; }
	.prose > p:first-of-type { font-size: 1.12rem; }
	.prose blockquote { font-size: 1.22rem; padding-left: 18px; }
	.prose .alignleft, .prose .alignright { float: none; margin: 0 0 1em; max-width: 100%; }
	.author-box { grid-template-columns: minmax(0, 1fr); padding: 22px; }
	.author-box .avatar { width: 72px; height: 72px; }
	.author-hero__row { grid-template-columns: minmax(0, 1fr); text-align: left; gap: 18px; }
	.author-hero .avatar { width: 92px; height: 92px; }
	.newsletter { border-radius: 20px; padding: 28px 20px; gap: 22px; }
	.nl-form__row { flex-direction: column; background: transparent; box-shadow: none; padding: 0; gap: 10px; }
	.nl-form input[type="email"] { background: #fff; border-radius: 12px; height: 52px; }
	.nl-form__icon { top: 26px; }
	.nl-form .btn { height: 52px; width: 100%; }
	.search-form { flex-wrap: wrap; }
	.search-form__field { flex-basis: 100%; }
	.search-form select { flex: 1; max-width: none; height: 48px; }
	.search-form .btn { height: 48px; }
	.search-overlay { padding-top: 12px; }
	.search-overlay__box { padding: 16px; border-radius: 18px; }
	.contact-form { padding: 20px; }
	.footer-top { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 36px 24px; padding-block: 48px 36px; }
	.footer-bottom__inner { flex-direction: column; align-items: flex-start; }
	.pagination a, .pagination span { min-width: 40px; height: 40px; }
	.archive-hero__icon { width: 48px; height: 48px; border-radius: 14px; }
	.page-hero { padding-block: 36px 28px; }
	.error-404 { padding-top: 48px; }
}

@media (max-width: 380px) {
	.card--side .card__media, .card--compact .card__media { width: 84px; }
	.layout-a__list .card .card__media, .layout-d .card .card__media, .related .card .card__media { width: 92px; }
	.share__btn { width: 36px; height: 36px; }
}

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

@media print {
	.site-header, .topbar, .site-footer, .share, .share-row, .related, .comments, .ad-slot, .to-top, .toc, .newsletter { display: none !important; }
	body { color: #000; background: #fff; }
	.prose { font-size: 12pt; }
}
