/* ==========================================================================
   DPEX Blog
   Body follows the Figma "Blog" wireframe; header, footer, ticker and bottom
   nav copy dpex.co. Colors and sizes come from the Figma variables.
   ========================================================================== */

/* Vazirmatn ships with the theme (SIL OFL). Yekan Bakh / Peyda are optional: see README. */
@font-face { font-family: "Vazirmatn"; src: url("../fonts/Vazirmatn.woff2") format("woff2"); font-weight: 100 900; font-display: swap; }
@font-face { font-family: "yekanBakh"; src: url("../fonts/YekanBakh.woff2") format("woff2"); font-weight: 100 900; font-display: swap; }
@font-face { font-family: "peyda"; src: url("../fonts/Peyda-SemiBold.woff2") format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "peyda"; src: url("../fonts/Peyda-Bold.woff2") format("woff2"); font-weight: 700; font-display: swap; }

:root {
	--brand: #1a9e6e;
	--brand-hover: #168a60;
	--brand-400: #28b07b;
	--brand-300: #45c48a;
	--brand-50: #f3fbf7;
	--ink: #101828;
	--text: #1d2939;
	--gray-700: #344054;
	--muted: #667085;
	--muted-2: #98a2b3;
	--line: #e4e7ec;
	--line-2: #d0d5dd;
	--surface: #f9fafb;
	--dark: #0c111d;
	--dark-panel: #172131;
	--up: #12b76a;
	--down: #f04438;

	--font: "Vazirmatn", Tahoma, sans-serif;
	--font-display: var(--font);
	--container: 1216px;
	--header-h: 65px;
	--ease: cubic-bezier(.22, 1, .36, 1);
	--dark-gradient: linear-gradient(180deg, #121212 0%, #000 100%);
}
.font-yekan {
	--font: "yekanBakh", "Vazirmatn", Tahoma, sans-serif;
	--font-display: "peyda", "yekanBakh", "Vazirmatn", Tahoma, sans-serif;
}

/* ---------- Motion ---------- */
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-smooth [data-lenis-prevent] { overscroll-behavior: contain; }
.lenis.lenis-stopped { overflow: hidden; }

@keyframes dpex-rise { from { opacity: 0; transform: translateY(14px); filter: blur(4px); } }
@keyframes dpex-drop { from { opacity: 0; transform: translateY(-10px); } }

/* Elements that animate in when they enter the screen (see theme.js). Hidden only while html.motion is set. */
.motion :is(.hero-home-head, .slider, .tile, .hero-inner, .toolbar, .chips-home, .cat-head, .post-grid > .card, .list-card, .newsletter,
	.article-top, .article-header, .article-cover, .aside-card, .signup-cta, .author-box, .post-nav, .comments, .empty-state,
	.prose > h2, .prose > h3, .prose > figure, .prose > .wp-block-image, .prose > blockquote, .prose > .wp-block-table, .prose > .is-style-dpex-takeaways):not(.is-in) {
	opacity: 0; transform: translateY(24px) scale(.985); filter: blur(6px);
}
.motion .article-cover:not(.is-in) { transform: scale(.97); }
.motion .is-revealing { transition: opacity .9s var(--ease), transform .9s var(--ease), filter .9s var(--ease) !important; transition-delay: var(--d, 0ms) !important; }
.article-cover img { transition: transform 1.6s var(--ease); }
.motion .article-cover:not(.is-in) img { transform: scale(1.08); }

/* Header items drop in on page load, like the dpex.co intro. */
.motion .header-logo, .motion .header-nav > *, .motion .header-actions { animation: dpex-drop .6s var(--ease) both; }
.motion .header-nav > :nth-child(2) { animation-delay: 40ms; }
.motion .header-nav > :nth-child(3) { animation-delay: 80ms; }
.motion .header-nav > :nth-child(4) { animation-delay: 120ms; }
.motion .header-nav > :nth-child(5) { animation-delay: 160ms; }
.motion .header-nav > :nth-child(6) { animation-delay: 200ms; }
.motion .header-nav > :nth-child(7) { animation-delay: 240ms; }
.motion .header-actions { animation-delay: 280ms; }

/* Softer hover motion on cards and buttons. */
.btn { transition: background-color .25s var(--ease), border-color .25s var(--ease), transform .25s var(--ease), box-shadow .25s var(--ease); }
.btn-primary:hover { box-shadow: 0 8px 20px -8px rgba(26, 158, 110, .55); }
.card { transition: transform .45s var(--ease); }
.card:hover { transform: translateY(-4px); }

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 24px); }
body {
	margin: 0;
	background: #fff;
	color: var(--text);
	font-family: var(--font);
	font-size: 16px;
	line-height: 1.75;
	-webkit-font-smoothing: antialiased;
	text-rendering: optimizeLegibility;
}
img, svg, video { max-width: 100%; height: auto; }
img { display: block; }
a { color: inherit; text-decoration: none; }
button, input, textarea, select { font: inherit; color: inherit; }
h1, h2, h3, h4, h5, h6 { margin: 0; font-family: var(--font-display); color: inherit; }
p, ul, ol, figure { margin: 0; }
:focus-visible { outline: 2px solid var(--brand-400); outline-offset: 2px; border-radius: 6px; }
::selection { background: var(--brand); color: #fff; }

.screen-reader-text {
	position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
	overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}
.skip-link:focus {
	clip: auto; width: auto; height: auto; margin: 0; z-index: 100; inset-inline-start: 16px; top: 16px;
	padding: 8px 16px; background: var(--brand); color: #fff; border-radius: 8px;
}

.container { width: 100%; max-width: calc(var(--container) + 32px); margin-inline: auto; padding-inline: 16px; }
.icon { flex-shrink: 0; }

/* Shared dark surface with the dpex.co diamond pattern. */
.dark-panel, .hero { position: relative; isolation: isolate; overflow: hidden; color: #fff; }
.dark-panel { border-radius: 24px; background: radial-gradient(70% 120% at 15% 50%, #1a9e6e33, transparent 70%), linear-gradient(135deg, #1b2b33, #0c111d); }
.dark-panel::before, .hero::before, .slide-media::before {
	content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
	background: url("../img/pattern.svg") 0 0 / 162px 81px repeat; opacity: .3;
}

/* ---------- Buttons, chips, badges ---------- */
.btn {
	display: inline-flex; align-items: center; justify-content: center; gap: 8px;
	height: 44px; padding: 0 20px; border: 0; border-radius: 8px;
	font-size: 14px; font-weight: 700; line-height: 20px; white-space: nowrap; cursor: pointer;
	transition: background-color .2s, transform .2s;
}
.btn-primary { background: var(--brand); color: #fff; }
.btn-primary:hover { background: var(--brand-hover); }
.btn-primary:active { transform: translateY(1px); }
.btn-pill { border-radius: 999px; }
.btn-block { width: 100%; }

.chip {
	display: inline-flex; align-items: center; height: 38px; padding: 0 16px;
	border: 1px solid var(--line); border-radius: 999px; background: #fff;
	font-size: 14px; font-weight: 500; color: var(--gray-700); white-space: nowrap;
	transition: border-color .2s, background-color .2s, color .2s;
}
.chip:hover { border-color: var(--line-2); background: var(--surface); color: var(--ink); }
.chip.is-active { border-color: var(--brand); background: var(--brand); color: #fff; font-weight: 700; }
.chip-sm { height: 32px; padding: 0 12px; font-size: 13px; }

.badge {
	position: absolute; top: 12px; inset-inline-start: 12px; z-index: 2;
	display: inline-flex; padding: 3px 12px; border-radius: 999px; background: var(--brand);
	font-size: 12px; font-weight: 500; line-height: 18px; color: #fff; transition: background-color .2s;
}
.badge:hover { background: var(--brand-hover); }
.badge-static { position: static; margin-bottom: 16px; }

.link-more { display: inline-flex; align-items: center; gap: 6px; font-size: 14px; font-weight: 600; color: var(--brand); transition: color .2s; }
.link-more:hover { color: var(--brand-hover); }
.link-more.on-dark { color: var(--brand-300); margin-top: 24px; }
.eyebrow { font-size: 16px; line-height: 28px; color: var(--muted); }

/* ==========================================================================
   Header — copy of dpex.co
   ========================================================================== */
.site-header {
	position: fixed; inset-inline: 0; top: 0; z-index: 40; color: #fff;
	background: rgba(18, 18, 18, .9); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
}
.admin-bar .site-header { top: 32px; }
.header-inner {
	position: relative; display: flex; align-items: center; gap: 16px;
	width: 100%; max-width: 1264px; height: var(--header-h); margin-inline: auto; padding-inline: 16px;
}
.header-logo { display: block; flex-shrink: 0; width: 41px; color: #fff; }
.header-logo .logo-mark { display: block; width: 41px; height: 41px; }
.header-nav { display: none; align-items: center; gap: 20px; }
.nav-link {
	display: flex; align-items: center; gap: 4px; padding: 0; border: 0; background: none; cursor: pointer;
	font-size: 14px; font-weight: 500; line-height: 20px; color: rgba(255, 255, 255, .9); white-space: nowrap; transition: color .15s;
}
.nav-link:hover { color: #fff; }
.nav-link.is-current { position: relative; color: #fff; }
.nav-link.is-current::after { content: ""; position: absolute; inset-inline: 0; bottom: -22px; height: 2px; border-radius: 2px; background: var(--brand-400); }
.nav-link .icon { width: 14px; height: 14px; }
.nav-link.is-soon { gap: 8px; color: rgba(255, 255, 255, .45); cursor: default; }
.soon { padding: 2px 8px; border-radius: 999px; background: rgba(255, 255, 255, .1); font-size: 11px; font-weight: 700; line-height: 16px; color: rgba(255, 255, 255, .7); }

.dd { position: relative; }
.dd-panel {
	position: absolute; top: 100%; left: 50%; z-index: 50; padding-top: 8px;
	visibility: hidden; opacity: 0; transform: translate(-50%, 8px); transition: all .2s ease-out;
}
.dd:hover .dd-panel, .dd:focus-within .dd-panel, .dd.is-open .dd-panel { visibility: visible; opacity: 1; transform: translate(-50%, 0); }
.dd-card {
	display: flex; flex-direction: column; gap: 4px; width: 380px; overflow: hidden; padding: 4px;
	border: 1px solid rgba(255, 255, 255, .15); border-radius: 16px; background: #111;
	box-shadow: 0 24px 60px rgba(0, 0, 0, .35);
}
.dd-item { display: flex; align-items: center; gap: 16px; padding: 8px; border-radius: 16px; text-align: start; transition: background-color .15s; }
.dd-item:hover { background: rgba(255, 255, 255, .05); }
.dd-icon {
	display: flex; flex-shrink: 0; align-items: center; justify-content: center; width: 56px; height: 56px;
	border-radius: 16px; background: rgba(255, 255, 255, .08); box-shadow: 0 0 0 1px rgba(255, 255, 255, .05); color: #fff;
}
.dd-text { display: flex; flex: 1; flex-direction: column; min-width: 0; }
.dd-text strong { font-size: 16px; font-weight: 700; line-height: 24px; color: #fff; }
.dd-text span { margin-top: 4px; font-size: 14px; line-height: 20px; color: var(--muted-2); }
.dd-arrow { flex-shrink: 0; color: var(--muted-2); transition: transform .2s, color .2s; }
.dd-item:hover .dd-arrow { transform: translateX(-4px); color: #fff; }

.dd-prices { width: 420px; padding: 12px; }
.dd-cats { width: 300px; gap: 2px; padding: 8px; }
.dd-cat {
	display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 12px;
	border-radius: 12px; transition: background-color .15s;
}
.dd-cat:hover { background: rgba(255, 255, 255, .06); }
.dd-cat strong { font-size: 14px; font-weight: 600; color: #fff; }
.dd-cat span { font-size: 12px; color: var(--muted-2); }
.dd-cats .coin-all { margin-top: 4px; border-top: 1px solid rgba(255, 255, 255, .08); border-radius: 0; padding-top: 12px; }
.coin-search { position: relative; display: block; }
.coin-search .icon { position: absolute; top: 50%; right: 16px; transform: translateY(-50%); color: var(--muted-2); pointer-events: none; }
.coin-search input {
	width: 100%; height: 44px; padding: 0 44px 0 32px; border: 1px solid rgba(255, 255, 255, .15); border-radius: 12px;
	background: #111; outline: none; font-size: 14px; color: #fff; transition: border-color .2s;
}
.coin-search input::placeholder { color: #868a92; }
.coin-search input:focus { border-color: var(--brand-400); }
.coin-tabs { display: flex; gap: 8px; margin-top: 12px; }
.coin-tab {
	padding: 4px 12px; border: 0; border-radius: 999px; cursor: pointer;
	background: rgba(255, 255, 255, .05); font-size: 12px; font-weight: 600; line-height: 16px; color: var(--muted-2);
	transition: background-color .2s, color .2s;
}
.coin-tab:hover { background: rgba(255, 255, 255, .1); color: #fff; }
.coin-tab.is-active { background: var(--brand-400); color: #fff; }
.coin-list { display: flex; flex-direction: column; gap: 2px; margin-top: 12px; padding: 0; list-style: none; max-height: 336px; overflow-y: auto; scrollbar-width: thin; scrollbar-color: rgba(255, 255, 255, .15) transparent; }
.coin-list a { display: flex; align-items: center; gap: 12px; padding: 8px; border-radius: 12px; transition: background-color .15s; }
.coin-list a:hover { background: rgba(255, 255, 255, .05); }
.coin-list img { width: 32px; height: 32px; border-radius: 999px; }
.coin-name { display: flex; flex-direction: column; line-height: 20px; }
.coin-name strong { font-size: 14px; font-weight: 600; color: #fff; }
.coin-name span, .coin-price span { font-size: 12px; color: var(--muted-2); }
.coin-price { display: flex; flex-direction: column; align-items: flex-end; margin-inline-start: auto; line-height: 20px; }
.coin-price strong { font-size: 14px; font-weight: 600; color: #fff; }
.coin-price .is-up, .is-up { color: var(--up); }
.coin-price .is-down, .is-down { color: #f97066; }
.coin-empty {
	display: flex; align-items: center; justify-content: center; min-height: 112px; margin-top: 12px; padding: 0 16px;
	border-radius: 16px; background: rgba(255, 255, 255, .05); font-size: 14px; color: var(--muted-2); text-align: center;
}
.coin-empty[hidden] { display: none; }
.coin-all {
	display: flex; align-items: center; justify-content: center; gap: 8px; margin-top: 12px; padding: 8px 0;
	border-radius: 999px; font-size: 14px; font-weight: 600; color: var(--brand-400); transition: opacity .2s;
}
.coin-all:hover { opacity: .8; }
.coin-all .icon { transform: rotate(270deg); }

.header-actions { display: flex; align-items: center; gap: 8px; margin-inline-start: auto; }
.btn-login {
	display: none; align-items: center; height: 44px; padding: 0 16px; border-radius: 999px;
	background: var(--brand); font-size: 14px; font-weight: 600; color: #fff; transition: background-color .2s;
}
.btn-login:hover { background: var(--brand-hover); }

.menu-toggle {
	position: relative; display: grid; place-content: center; gap: 5px; width: 44px; height: 44px; padding: 0; cursor: pointer;
	border: 1px solid rgba(255, 255, 255, .12); border-radius: 12px; background: rgba(255, 255, 255, .06);
}
.menu-toggle span { display: block; width: 18px; height: 2px; border-radius: 2px; background: #fff; transition: transform .35s var(--ease), opacity .2s; }
.menu-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.menu-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.mobile-menu {
	position: fixed; inset: var(--header-h) 0 0; z-index: 39; overflow-y: auto; overscroll-behavior: contain;
	background: rgb(14, 14, 14); visibility: hidden; opacity: 0; transform: translateY(-12px);
	transition: opacity .35s var(--ease), transform .35s var(--ease), visibility 0s .35s;
}
.menu-open .mobile-menu { visibility: visible; opacity: 1; transform: none; transition: opacity .35s var(--ease), transform .35s var(--ease); }
.menu-open { overflow: hidden; }
.menu-open .site-header { background: rgb(14, 14, 14); }
.admin-bar .mobile-menu { top: calc(var(--header-h) + 46px); }
.mobile-menu-inner { padding: 20px 16px 40px; }
.mobile-nav { display: flex; flex-direction: column; margin-top: 8px; }
.mobile-nav-label { margin: 20px 0 4px; font-size: 12px; color: rgba(255, 255, 255, .45); }
.mobile-nav a, .mobile-nav .is-soon {
	display: flex; align-items: center; gap: 12px; padding: 14px 4px; border-bottom: 1px solid rgba(255, 255, 255, .08);
	font-size: 16px; font-weight: 500; color: #fff;
}
.mobile-nav a .icon { color: var(--brand-400); }
.mobile-nav a.mobile-sub { padding: 10px 4px 10px 0; padding-inline-start: 32px; font-size: 14px; color: rgba(255, 255, 255, .75); }
.mobile-nav a.is-current { color: var(--brand-300); }
.mobile-nav .is-soon { color: rgba(255, 255, 255, .45); }
.mobile-login { height: 52px; margin-top: 28px; border-radius: 999px; }
.motion .menu-open .mobile-nav > *, .motion .menu-open .mobile-search, .motion .menu-open .mobile-login { animation: dpex-rise .5s var(--ease) both; }
.motion .menu-open .mobile-nav > :nth-child(n + 2) { animation-delay: 40ms; }
.motion .menu-open .mobile-nav > :nth-child(n + 4) { animation-delay: 80ms; }
.motion .menu-open .mobile-nav > :nth-child(n + 6) { animation-delay: 120ms; }
.motion .menu-open .mobile-nav > :nth-child(n + 8) { animation-delay: 160ms; }
.motion .menu-open .mobile-login { animation-delay: 200ms; }

@media (min-width: 640px) {
	.header-inner { padding-inline: 24px; }
}
@media (min-width: 1024px) {
	.site-header { background: rgba(18, 18, 18, .9); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); }
	.header-inner { gap: 32px; }
	.header-nav { display: flex; }
	.btn-login { display: inline-flex; }
	.menu-toggle, .mobile-menu { display: none; }
}

/* ---------- Reading progress ---------- */
.read-progress { position: fixed; inset-inline: 0; top: 0; z-index: 60; height: 3px; pointer-events: none; }
.admin-bar .read-progress { top: 32px; }
.read-progress span { display: block; width: 0; height: 100%; background: linear-gradient(90deg, var(--brand-300), var(--brand)); }

/* ==========================================================================
   Hero (Figma: Blog Hero)
   ========================================================================== */
.hero { padding-top: var(--header-h); background: var(--dark-gradient); }
.hero::before { -webkit-mask-image: linear-gradient(#000 40%, transparent); mask-image: linear-gradient(#000 40%, transparent); }
.hero-inner { display: flex; flex-direction: column; align-items: center; padding-block: 64px 80px; text-align: center; }
.hero-eyebrow { margin-bottom: 12px; font-size: 14px; font-weight: 500; line-height: 20px; color: var(--brand-400); }
.hero-title { max-width: 900px; font-size: 48px; font-weight: 600; line-height: 60px; color: #fff; }
.hero-sub { max-width: 640px; margin-top: 16px; font-size: 18px; line-height: 28px; color: rgba(255, 255, 255, .8); }
.hero-sub p { margin: 0; }
.hero-count { margin-top: 12px; font-size: 14px; color: rgba(255, 255, 255, .55); }
.hero-search { width: 100%; max-width: 560px; margin-top: 40px; }
.hero-sm .hero-inner { padding-block: 40px 56px; }
.hero-sm .hero-title { font-size: 40px; line-height: 52px; }

.hero-art { position: absolute; z-index: -1; pointer-events: none; display: none; }
.hero-art-a { right: 6%; bottom: -24px; width: 190px; transform: rotate(-10deg); opacity: .9; filter: drop-shadow(0 24px 40px rgba(0, 0, 0, .45)); }
.hero-art-b { left: 7%; top: 120px; width: 140px; transform: rotate(12deg); opacity: .55; filter: blur(1.5px); }
@media (min-width: 1100px) {
	.hero-art { display: block; }
}

.breadcrumbs ol { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 20px; padding: 0; list-style: none; font-size: 13px; color: rgba(255, 255, 255, .55); }
.breadcrumbs li + li::before { content: "/"; margin-inline-end: 6px; opacity: .6; }
.breadcrumbs a:hover { color: #fff; }

/* Search pill (dark glass, as in the wireframe hero). */
.search-form {
	display: flex; align-items: center; gap: 8px; height: 60px; padding: 8px; padding-inline-start: 20px;
	border: 1px solid rgba(255, 255, 255, .12); border-radius: 999px; background: rgba(255, 255, 255, .05);
	-webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); transition: border-color .2s, box-shadow .2s;
}
.search-form:focus-within { border-color: var(--brand-400); box-shadow: 0 0 0 4px rgba(40, 176, 123, .15); }
.search-form > .icon { color: rgba(255, 255, 255, .6); }
.search-field { flex: 1; min-width: 0; height: 100%; border: 0; background: transparent; outline: none; font-size: 16px; color: #fff; }
.search-field::placeholder { color: rgba(255, 255, 255, .55); }
.search-field::-webkit-search-cancel-button { display: none; }
.search-form .btn { height: 44px; padding: 0 24px; }

/* ==========================================================================
   Blog body (Figma: Blog Body)
   ========================================================================== */
.page-body { padding-top: 56px; padding-bottom: 32px; }

.filters { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 64px; }
.chips { display: flex; gap: 8px; min-width: 0; overflow-x: auto; scrollbar-width: none; }
.chips::-webkit-scrollbar { display: none; }
.sort { position: relative; flex-shrink: 0; margin-inline-start: auto; }
.sort summary {
	display: flex; align-items: center; gap: 6px; height: 38px; padding: 0 16px; list-style: none; cursor: pointer;
	border: 1px solid var(--line); border-radius: 999px; background: #fff; font-size: 14px; color: var(--ink); transition: border-color .2s;
}
.sort summary::-webkit-details-marker { display: none; }
.sort summary:hover, .sort[open] summary { border-color: var(--line-2); }
.sort-label { color: var(--muted); }
.sort summary strong { font-weight: 600; }
.sort summary .icon { color: var(--muted); transition: transform .2s; }
.sort[open] summary .icon { transform: rotate(180deg); }
.sort ul {
	position: absolute; top: calc(100% + 8px); inset-inline-end: 0; z-index: 20; min-width: 180px; padding: 6px; list-style: none;
	border: 1px solid var(--line); border-radius: 12px; background: #fff; box-shadow: 0 12px 32px -8px rgba(16, 24, 40, .18);
}
.sort li a { display: flex; align-items: center; justify-content: space-between; padding: 8px 12px; border-radius: 8px; font-size: 14px; color: var(--gray-700); }
.sort li a:hover { background: var(--surface); }
.sort li a[aria-current] { font-weight: 600; color: var(--brand); }

/* Small green pill used on editor's picks. */
.featured-badge {
	padding: 4px 12px; border: 1px solid rgba(40, 176, 123, .3); border-radius: 999px; background: rgba(40, 176, 123, .12);
	font-size: 12px; font-weight: 500; line-height: 18px; color: var(--brand-300);
}

/* Section heading */
.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 32px; }
.section-title { font-size: 36px; font-weight: 700; line-height: 44px; color: var(--ink); }

/* Article cards */
.post-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 48px 32px; }
.card { position: relative; display: flex; flex-direction: column; }
.card-media {
	position: relative; display: block; overflow: hidden; aspect-ratio: 384 / 216; border-radius: 16px;
	background: var(--surface); box-shadow: inset 0 0 0 1px rgba(16, 24, 40, .06); transition: box-shadow .25s;
}
.card:hover .card-media { box-shadow: 0 14px 28px -14px rgba(16, 24, 40, .35); }
.media-placeholder {
	position: relative; isolation: isolate; display: grid; place-items: center; width: 100%; height: 100%; color: rgba(255, 255, 255, .16);
	background: radial-gradient(60% 80% at 70% 20%, #1a9e6e40, transparent 70%), linear-gradient(135deg, #1b2b33, #0c111d);
}
.media-placeholder::before { content: ""; position: absolute; inset: 0; z-index: -1; background: url("../img/pattern.svg") 0 0 / 162px 81px repeat; opacity: .25; }
.media-placeholder .logo-mark { width: 22%; max-width: 72px; height: auto; }
.media-cover { width: 100%; height: 100%; object-fit: cover; transition: transform .9s var(--ease); }
.card:hover .media-cover { transform: scale(1.04); }
.card-body { display: flex; flex-direction: column; gap: 8px; padding-top: 20px; }
.post-meta { display: flex; align-items: center; gap: 8px; font-size: 12px; line-height: 18px; color: var(--muted); }
.post-meta .dot { width: 3px; height: 3px; border-radius: 50%; background: var(--muted-2); }
.card-title { font-size: 18px; font-weight: 700; line-height: 28px; color: var(--ink); }
.card-title a { transition: color .2s; }
.card-title a:hover { color: var(--brand); }
.card-excerpt {
	display: -webkit-box; overflow: hidden; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
	font-size: 14px; line-height: 22px; color: var(--muted);
}

/* Pagination */
.pagination { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-top: 64px; }
.pagination .page-numbers {
	display: inline-grid; place-items: center; min-width: 36px; height: 36px; padding: 0 6px; border-radius: 10px;
	font-size: 14px; font-weight: 600; color: var(--gray-700); transition: background-color .2s, color .2s;
}
.pagination a.page-numbers:hover { background: #f2f4f7; color: var(--ink); }
.pagination .current { background: var(--brand); color: #fff; }
.pagination .dots { color: var(--muted-2); }
.pagination .prev .icon { transform: scaleX(-1); }

/* ---------- Newsletter ---------- */
.section-sm { padding-top: 32px; padding-bottom: 96px; }
.newsletter { display: flex; align-items: center; justify-content: space-between; gap: 32px; padding: 32px 40px; border: 1px solid var(--line); border-radius: 20px; background: var(--surface); }
.newsletter h2 { font-size: 22px; font-weight: 700; line-height: 34px; color: var(--ink); }
.newsletter p { margin-top: 6px; font-size: 15px; line-height: 26px; color: var(--muted); }
.newsletter-form { display: flex; flex: 0 1 440px; gap: 8px; }
.newsletter-form input[type="email"] {
	flex: 1; min-width: 0; height: 48px; padding: 0 16px; border: 1px solid var(--line-2); border-radius: 10px;
	background: #fff; outline: none; font-size: 15px; color: var(--ink); transition: border-color .2s, box-shadow .2s;
}
.newsletter-form input::placeholder { color: var(--muted-2); }
.newsletter-form input:focus { border-color: var(--brand); box-shadow: 0 0 0 4px rgba(26, 158, 110, .12); }
.newsletter-form .btn { height: 48px; padding: 0 22px; border-radius: 10px; }

/* Empty state */
.empty-state { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 48px 0 64px; text-align: center; }
.empty-state img { width: 140px; margin-bottom: 8px; }
.empty-state h2 { font-size: 22px; color: var(--ink); }
.empty-state p { color: var(--muted); }
.empty-state .btn { margin-top: 16px; }

/* 404 */
.hero-404 .hero-inner { padding-block: 56px 96px; }
.hero-404 .hero-eyebrow { margin: 8px 0 4px; font-size: 20px; font-weight: 700; }
.not-found-art { width: 180px; filter: drop-shadow(0 30px 50px rgba(26, 158, 110, .35)); }

/* ==========================================================================
   Blog home — magazine layout (slider + bento hero, category sections)
   ========================================================================== */
.hero-home { background: #fff; color: var(--ink); }
.hero-home::before { display: none; }
.hero-home-inner { padding-block: 36px 16px; }
.hero-home-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 24px; }
.hero-home .hero-eyebrow { margin-bottom: 4px; }
.hero-home-title { font-size: 32px; font-weight: 700; line-height: 48px; color: var(--ink); }
.hero-home .hero-eyebrow { color: var(--brand); }

@keyframes dpex-pulse { 0% { box-shadow: 0 0 0 0 rgba(18, 183, 106, .55); } 100% { box-shadow: 0 0 0 8px rgba(18, 183, 106, 0); } }

.hero-grid { display: grid; grid-template-columns: minmax(0, 1.12fr) minmax(0, 1fr); gap: 20px; height: 460px; }
.hero-grid.no-tiles { grid-template-columns: 1fr; }
.stretched::after { content: ""; position: absolute; inset: 0; z-index: 1; }

/* Slider */
.slider { position: relative; isolation: isolate; overflow: hidden; border-radius: 24px; background: #0e1520; box-shadow: 0 24px 48px -28px rgba(16, 24, 40, .45); }
.slides { display: flex; height: 100%; transition: transform .7s cubic-bezier(.65, 0, .35, 1); }
.slide { position: relative; isolation: isolate; flex: 0 0 100%; height: 100%; overflow: hidden; }
.slide-media { position: absolute; inset: 0; z-index: -2; }
.slide-media::before { display: none; }
.slide-media .media-cover { width: 100%; height: 100%; object-fit: cover; transform: scale(1.06); transition: transform 6s ease-out; }
.slide.is-active .media-cover { transform: scale(1); }
.slide::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(to top, rgba(12, 17, 29, .96) 0%, rgba(12, 17, 29, .55) 45%, transparent 78%); }
.slide-body { position: absolute; inset-inline: 0; bottom: 0; display: flex; flex-direction: column; align-items: flex-start; gap: 10px; padding: 28px 32px 76px; }
.slide-badges { display: flex; gap: 8px; }
.slide-badges .badge-static { margin: 0; }
.slide-title { max-width: 560px; font-size: 26px; font-weight: 700; line-height: 40px; color: #fff; }
.slide-title a:hover { color: var(--brand-300); }
.slide-excerpt { display: -webkit-box; overflow: hidden; max-width: 520px; -webkit-line-clamp: 2; -webkit-box-orient: vertical; font-size: 15px; line-height: 26px; color: rgba(255, 255, 255, .75); }
.slide .post-meta, .tile .post-meta { color: rgba(255, 255, 255, .6); }
.slide .post-meta .dot { background: rgba(255, 255, 255, .4); }

.slider-controls { position: absolute; inset-inline: 32px; bottom: 24px; z-index: 3; display: flex; align-items: center; justify-content: space-between; }
.slider-dots { display: flex; gap: 6px; }
.slider-dot { position: relative; width: 24px; height: 4px; padding: 0; overflow: hidden; border: 0; border-radius: 4px; background: rgba(255, 255, 255, .25); cursor: pointer; transition: width .3s; }
.slider-dot.is-active { width: 44px; }
.slider-dot span { position: absolute; inset-block: 0; inset-inline-start: 0; width: 0; background: #fff; }
.slider-dot.is-active span { animation: dpex-progress 6s linear forwards; }
.slider.is-paused .slider-dot.is-active span { animation-play-state: paused; }
.slider.no-autoplay .slider-dot.is-active span { width: 100%; animation: none; }
@keyframes dpex-progress { to { width: 100%; } }
.slider-arrows { display: flex; gap: 8px; }
.slider-arrow {
	display: grid; place-items: center; width: 40px; height: 40px; padding: 0; border: 1px solid rgba(255, 255, 255, .18); border-radius: 50%;
	background: rgba(12, 17, 29, .45); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); color: #fff; cursor: pointer; transition: background-color .2s, border-color .2s;
}
.slider-arrow:hover { border-color: var(--brand); background: var(--brand); }
.slider-arrow.js-prev .icon { transform: scaleX(-1); }

/* Bento grid: wide, small / small, wide */
.bento { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); grid-template-rows: repeat(2, minmax(0, 1fr)); gap: 20px; }
.tile-0, .tile-3 { grid-column: span 2; }
.tile {
	position: relative; isolation: isolate; overflow: hidden; border-radius: 20px; background: var(--dark);
	box-shadow: 0 16px 32px -24px rgba(16, 24, 40, .45); transition: transform .45s var(--ease), box-shadow .45s var(--ease);
}
.tile:hover { transform: translateY(-3px); box-shadow: 0 22px 40px -22px rgba(16, 24, 40, .5); }
.tile-media { position: absolute; inset: 0; z-index: -2; }
.tile .media-cover { width: 100%; height: 100%; object-fit: cover; transition: transform .9s var(--ease); }
.tile:hover .media-cover { transform: scale(1.05); }
.tile::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(to top, rgba(12, 17, 29, .94) 0%, rgba(12, 17, 29, .35) 55%, transparent 85%); }
.tile-body { position: absolute; inset-inline: 0; bottom: 0; display: flex; flex-direction: column; align-items: flex-start; gap: 6px; padding: 16px 18px; }
.tile-cat { padding: 2px 10px; border-radius: 999px; background: var(--brand); font-size: 11px; font-weight: 600; line-height: 18px; color: #fff; }
.tile-title { display: -webkit-box; overflow: hidden; -webkit-line-clamp: 2; -webkit-box-orient: vertical; font-size: 15px; font-weight: 700; line-height: 24px; color: #fff; }
.tile-0 .tile-title, .tile-3 .tile-title { font-size: 17px; line-height: 28px; }
.tile-title a:hover { color: var(--brand-300); }
.tile-meta { font-size: 12px; color: rgba(255, 255, 255, .55); }

/* Search under the hero grid */
/* Search toolbar above the posts (light) */
.toolbar { display: flex; flex-direction: column; align-items: center; gap: 12px; margin-bottom: 20px; }
.toolbar-search { width: 100%; max-width: 640px; }
.toolbar .search-form { height: 56px; border-color: var(--line); background: #fff; box-shadow: 0 1px 2px rgba(16, 24, 40, .05); -webkit-backdrop-filter: none; backdrop-filter: none; }
.toolbar .search-form:focus-within { border-color: var(--brand); box-shadow: 0 0 0 4px rgba(26, 158, 110, .12); }
.toolbar .search-form > .icon { color: var(--muted-2); }
.toolbar .search-field { color: var(--ink); }
.toolbar .search-field::placeholder { color: var(--muted-2); }
.toolbar .search-form .btn { height: 42px; }
.hot-tags { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 14px; font-size: 13px; color: var(--muted); }
.hot-tags a { color: var(--gray-700); transition: color .2s; }
.hot-tags a:hover { color: var(--brand); }

/* Category sections (kifpool-style) */
.chips-home { padding-bottom: 4px; }
/* Centred when the chips fit, still scrollable from the first chip when they don't. */
.chips-home > :first-child { margin-inline-start: auto; }
.chips-home > :last-child { margin-inline-end: auto; }
.cat-section { margin-top: 56px; }
.cat-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 24px; }
.cat-head .sort { margin-inline-start: 0; }
.cat-title { position: relative; padding-inline-start: 16px; font-size: 22px; font-weight: 700; line-height: 32px; color: var(--ink); }
.cat-title::before { content: ""; position: absolute; top: 6px; bottom: 6px; inset-inline-start: 0; width: 4px; border-radius: 4px; background: var(--brand); }
.post-grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 32px 24px; }
.post-grid-4.has-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.post-grid-4.has-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.post-grid-4 .card-body { padding-top: 16px; }
.post-grid-4 .card-title { font-size: 16px; line-height: 26px; }

.list-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
.list-card { padding: 4px 20px 8px; border: 1px solid var(--line); border-radius: 16px; background: #fff; }
.list-card-head { display: flex; align-items: center; gap: 10px; padding: 14px 0; border-bottom: 1px solid var(--line); font-size: 16px; font-weight: 700; color: var(--ink); transition: color .2s; }
.list-card-head .icon { margin-inline-start: auto; color: var(--muted-2); transition: transform .2s; }
.list-card-head:hover { color: var(--brand); }
.list-card-head:hover .icon { transform: translateX(-4px); color: var(--brand); }
.list-card ol { margin: 0; padding: 0; list-style: none; }
.list-card li { display: flex; gap: 14px; padding: 14px 0; border-bottom: 1px dashed var(--line); }
.list-card li:last-child { border-bottom: 0; }
.list-num { min-width: 30px; padding-top: 2px; font-size: 22px; font-weight: 800; line-height: 1; color: var(--line-2); transition: color .2s; }
.list-card li:hover .list-num { color: var(--brand); }
.list-card li a { display: -webkit-box; overflow: hidden; -webkit-line-clamp: 2; -webkit-box-orient: vertical; font-size: 14px; font-weight: 600; line-height: 24px; color: var(--ink); transition: color .2s; }
.list-card li a:hover { color: var(--brand); }
.list-card .post-meta { margin-top: 4px; }

@media (max-width: 1100px) {
	.hero-grid { grid-template-columns: 1fr; height: auto; }
	.slider { height: 420px; }
	.bento { grid-template-rows: none; grid-auto-rows: 200px; }
	.post-grid-4, .post-grid-4.has-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
	.list-grid { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
	.hero-home-inner { padding-block: 24px 36px; }
	.hero-home-head { flex-direction: column; align-items: flex-start; margin-bottom: 18px; }
	.hero-home-title { font-size: 24px; line-height: 38px; }
	.slider { height: 380px; border-radius: 20px; }
	.slide-body { padding: 20px 20px 64px; }
	.slide-title { font-size: 20px; line-height: 32px; }
	.slide-excerpt { display: none; }
	.slider-controls { inset-inline: 20px; bottom: 20px; }
	.bento { grid-template-columns: repeat(2, minmax(0, 1fr)); grid-auto-rows: 170px; gap: 12px; }
	.tile-0, .tile-3 { grid-column: span 2; }
	.tile-title, .tile-0 .tile-title, .tile-3 .tile-title { font-size: 14px; line-height: 22px; }
	.cat-section { margin-top: 44px; }
	.cat-title { font-size: 19px; }
	/* Category rows scroll sideways on phones instead of stacking four tall cards. */
	.post-grid-4, .post-grid-4.has-3, .post-grid-4.has-2 {
		grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: 78%; gap: 16px;
		margin-inline: -16px; padding-inline: 16px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none;
	}
	.post-grid-4::-webkit-scrollbar { display: none; }
	.post-grid-4 > .card { scroll-snap-align: start; }
}

/* ==========================================================================
   Single post — light reading layout with a sidebar (kifpool / Binance Academy)
   ========================================================================== */
.single-article { padding-top: var(--header-h); }
/* Pages without a dark hero keep the header's dark background from the start, so the white logo stays visible. */
.article-layout { display: grid; grid-template-columns: minmax(0, 1fr) 320px; align-items: start; gap: 48px; padding-top: 28px; padding-bottom: 40px; }
.article-main { min-width: 0; max-width: 820px; }
.article-top { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 16px; margin-bottom: 24px; }
.back-link {
	display: inline-flex; align-items: center; gap: 6px; height: 36px; padding: 0 12px 0 16px; border: 1px solid var(--line); border-radius: 999px;
	background: #fff; font-size: 13px; font-weight: 600; color: var(--gray-700); transition: border-color .2s, color .2s;
}
.back-link .icon { transform: scaleX(-1); }
.back-link:hover { border-color: var(--brand); color: var(--brand); }
.article-top .breadcrumbs ol { margin: 0; color: var(--muted); }
.article-top .breadcrumbs a:hover { color: var(--brand); }
.article-cat { display: inline-flex; margin-bottom: 14px; padding: 3px 12px; border: 1px solid #1a9e6e33; border-radius: 999px; background: var(--brand-50); font-size: 13px; font-weight: 600; line-height: 22px; color: var(--brand); }
.article-title { font-size: 34px; font-weight: 700; line-height: 52px; color: var(--ink); }
.article-lead { margin-top: 14px; font-size: 18px; line-height: 32px; color: var(--gray-700); }
.article-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 20px; margin-top: 20px; padding-block: 12px; border-block: 1px solid var(--line); font-size: 13px; color: var(--muted); }
.article-meta > span { display: inline-flex; align-items: center; gap: 6px; }
.article-author { display: inline-flex; align-items: center; gap: 10px; font-weight: 600; color: var(--ink); }
.article-author:hover { color: var(--brand); }
.article-author .avatar { width: 32px; height: 32px; border-radius: 50%; }
.article-cover { margin-top: 24px; }
.article-cover img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; border-radius: 20px; }
.article-cover figcaption { margin-top: 10px; font-size: 13px; color: var(--muted); text-align: center; }
.single-article .entry-content { margin-top: 32px; }

/* Contents: sidebar card on desktop, sticky collapsible bar on smaller screens. */
.toc-bar {
	position: fixed; inset-inline: 16px; bottom: max(16px, env(safe-area-inset-bottom)); z-index: 45; display: none; max-width: 520px; margin-inline: auto;
	border-radius: 20px; color: #fff; background: linear-gradient(rgba(255, 255, 255, .07), rgba(255, 255, 255, .02)), rgba(22, 22, 22, .92);
	-webkit-backdrop-filter: blur(12px) saturate(1.5); backdrop-filter: blur(12px) saturate(1.5);
	box-shadow: inset 0 1px .5px rgba(255, 255, 255, .08), 0 12px 32px rgba(0, 0, 0, .45), 0 2px 8px rgba(0, 0, 0, .3);
	transform: translateY(calc(100% + 32px)); transition: transform .5s var(--ease);
}
.toc-bar.is-visible { transform: none; }
.toc-bar summary { display: flex; align-items: center; gap: 12px; padding: 10px 14px; list-style: none; cursor: pointer; }
.toc-bar summary::-webkit-details-marker { display: none; }
.toc-bar-icon { display: grid; flex-shrink: 0; place-items: center; width: 38px; height: 38px; border-radius: 12px; background: rgba(255, 255, 255, .08); color: var(--brand-300); }
.toc-bar-text { display: flex; flex-direction: column; min-width: 0; line-height: 20px; }
.toc-bar-text span { font-size: 11px; color: rgba(255, 255, 255, .55); }
.toc-bar-text strong { overflow: hidden; font-size: 13px; font-weight: 600; white-space: nowrap; text-overflow: ellipsis; }
.toc-bar summary > .icon { flex-shrink: 0; margin-inline-start: auto; color: rgba(255, 255, 255, .6); transform: rotate(180deg); transition: transform .3s var(--ease); }
.toc-bar[open] summary > .icon { transform: none; }
.toc-bar-panel {
	position: absolute; inset-inline: 0; bottom: calc(100% + 8px); max-height: 56vh; overflow-y: auto; padding: 16px 14px; border-radius: 20px;
	background: rgba(22, 22, 22, .97); box-shadow: 0 16px 40px rgba(0, 0, 0, .45);
}
.motion .toc-bar[open] .toc-bar-panel { animation: dpex-rise .35s var(--ease) both; }
.toc-bar .aside-title { display: none; }
.toc-bar .toc ol { max-height: none; }
.toc-bar .toc li::before { background: rgba(255, 255, 255, .12); }
.toc-bar .toc li a { color: rgba(255, 255, 255, .7); }
.toc-bar .toc li a::before { border-color: rgba(255, 255, 255, .3); background: #161616; }
.toc-bar .toc li a.is-active, .toc-bar .toc li a:hover { color: #fff; }
.toc-bar .toc li a.is-active::before { border-color: var(--brand-400); background: var(--brand-400); }

.article-aside {
	position: sticky; top: calc(var(--header-h) + 24px); display: flex; flex-direction: column; gap: 20px;
	/* The sidebar can be taller than the screen; let it scroll on its own so its end stays reachable. */
	max-height: calc(100vh - var(--header-h) - 72px); overflow-y: auto; scrollbar-width: none;
}
.article-aside::-webkit-scrollbar { display: none; }
.admin-bar .article-aside { top: calc(var(--header-h) + 56px); }
.aside-card { padding: 20px; border: 1px solid var(--line); border-radius: 16px; background: #fff; }
.aside-title { margin-bottom: 14px; font-size: 15px; font-weight: 700; color: var(--ink); }
.aside-card-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 6px; }
.aside-card-head .aside-title { margin: 0; }
.aside-card-head .link-more { font-size: 13px; }

/* The list scrolls, so the line and dots sit inside it (with room for the active halo) instead of hanging over its edge. */
.toc ol { max-height: 40vh; overflow-x: hidden; overflow-y: auto; margin: 0; padding-block: 4px; padding-inline: 6px 0; list-style: none; }
.toc li { position: relative; }
.toc li::before { content: ""; position: absolute; inset-block: 0; inset-inline-start: 4px; width: 2px; background: var(--line); }
.toc li:first-child::before { top: 15px; }
.toc li:last-child::before { bottom: auto; height: 15px; }
.toc li:only-child::before { display: none; }
.toc li a { position: relative; display: block; padding-block: 6px; padding-inline: 22px 4px; font-size: 14px; line-height: 22px; color: var(--muted); transition: color .2s; }
.toc li a::before {
	content: ""; position: absolute; top: 11px; inset-inline-start: 0; z-index: 1; width: 10px; height: 10px; border-radius: 50%;
	border: 2px solid var(--line-2); background: #fff; transition: all .2s;
}
.toc li.toc-level-3 a { padding-inline-start: 32px; font-size: 13px; }
.toc li.toc-level-3 a::before { top: 12px; inset-inline-start: 1px; width: 8px; height: 8px; }
.toc li a:hover { color: var(--ink); }
.toc li a.is-active { font-weight: 600; color: var(--ink); }
.toc li a.is-active::before { border-color: var(--brand); background: var(--brand); box-shadow: 0 0 0 4px rgba(26, 158, 110, .15); }

/* Live prices (light) */
.price-card ul { margin: 0; padding: 0; list-style: none; }
.price-card li { display: flex; align-items: center; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.price-card li:last-child { border-bottom: 0; }
.price-card img { width: 32px; height: 32px; border-radius: 50%; }
.price-card-name, .price-card-value { display: flex; flex-direction: column; line-height: 20px; }
.price-card-value { align-items: flex-end; margin-inline-start: auto; }
.price-card strong { font-size: 14px; font-weight: 600; color: var(--ink); }
.price-card-name span { font-size: 12px; color: var(--muted); }
.price-card-value span { font-size: 12px; }
.aside-card .is-up { color: #079455; }
.aside-card .is-down { color: #d92d20; }
.price-card-unit { margin: 8px 0 14px; font-size: 12px; color: var(--muted-2); }
.price-card .btn { height: 42px; }

.aside-related ul { display: grid; gap: 14px; margin: 0; padding: 0; list-style: none; }
.aside-related a { display: flex; align-items: center; gap: 12px; }
.aside-thumb { flex: 0 0 76px; height: 58px; overflow: hidden; border-radius: 10px; background: var(--surface); }
.aside-thumb img { width: 100%; height: 100%; object-fit: cover; }
.aside-thumb .media-placeholder .logo-mark { width: 40%; }
.aside-related-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.aside-related-text strong { display: -webkit-box; overflow: hidden; -webkit-line-clamp: 2; -webkit-box-orient: vertical; font-size: 13px; font-weight: 600; line-height: 22px; color: var(--ink); transition: color .2s; }
.aside-related-text span { font-size: 12px; color: var(--muted); }
.aside-related a:hover strong { color: var(--brand); }

.share { display: flex; flex-wrap: wrap; gap: 8px; }
.share-btn {
	display: grid; place-items: center; width: 38px; height: 38px; padding: 0; cursor: pointer;
	border: 1px solid var(--line); border-radius: 10px; background: #fff; color: var(--gray-700); transition: all .2s;
}
.share-btn:hover, .share-btn.is-copied { border-color: var(--brand); color: var(--brand); }

.article-footer { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; margin-top: 40px; padding-top: 24px; border-top: 1px solid var(--line); }
.post-tags { display: flex; flex-wrap: wrap; gap: 8px; }
.post-share { display: flex; align-items: center; gap: 12px; font-size: 14px; color: var(--muted); }

/* Sign-up box at the end of an article */
.signup-cta { display: flex; align-items: center; justify-content: space-between; gap: 32px; margin-top: 40px; padding: 28px 32px; border-radius: 16px; background: var(--dark); color: #fff; }
.signup-cta h2 { font-size: 20px; font-weight: 700; line-height: 32px; }
.signup-cta p { max-width: 440px; margin-top: 6px; font-size: 14px; line-height: 24px; color: rgba(255, 255, 255, .7); }
.cta-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 18px; }
.btn-outline-light { border: 1px solid rgba(255, 255, 255, .25); background: transparent; color: #fff; }
.btn-outline-light:hover { border-color: #fff; }
.signup-cta-quote { flex-shrink: 0; min-width: 190px; margin: 0; padding: 16px 18px; border: 1px solid rgba(255, 255, 255, .12); border-radius: 12px; }
.signup-cta-quote dt { font-size: 12px; color: rgba(255, 255, 255, .55); }
.signup-cta-quote dd { margin: 4px 0 0; font-size: 13px; color: rgba(255, 255, 255, .7); }
.signup-cta-quote dd strong { font-size: 22px; font-weight: 700; color: #fff; }

.author-box { display: flex; gap: 20px; margin-top: 32px; padding: 24px; border: 1px solid var(--line); border-radius: 16px; background: var(--surface); }
.author-box img { width: 64px; height: 64px; flex-shrink: 0; border-radius: 50%; }
.author-box .eyebrow { font-size: 13px; line-height: 20px; }
.author-box h2 { margin-bottom: 6px; font-size: 18px; color: var(--ink); }
.author-box p:last-child { font-size: 14px; line-height: 24px; color: var(--muted); }

.post-nav { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 32px; }
.post-nav-item { display: flex; flex-direction: column; gap: 6px; padding: 16px 20px; border: 1px solid var(--line); border-radius: 14px; transition: border-color .2s; }
.post-nav-item:hover { border-color: var(--brand); }
.post-nav-item.is-next { text-align: end; }
.post-nav-label { font-size: 12px; color: var(--muted); }
.post-nav-item strong { display: -webkit-box; overflow: hidden; -webkit-line-clamp: 2; -webkit-box-orient: vertical; font-size: 14px; font-weight: 600; line-height: 24px; color: var(--ink); }

.related { margin-top: 24px; padding-block: 64px; border-top: 1px solid var(--line); background: var(--surface); }

.page-links { display: flex; gap: 8px; margin-top: 32px; font-weight: 700; }

/* ---------- Prose ---------- */
.prose { font-size: 17px; line-height: 2.1; color: var(--text); overflow-wrap: break-word; }
.prose-page { max-width: 760px; margin-inline: auto; }
.prose > * + * { margin-top: 1.25em; }
.prose h2, .prose h3, .prose h4 { color: var(--ink); font-weight: 700; }
.prose h2 { margin-top: 2em; font-size: 26px; line-height: 1.6; }
.prose h3 { margin-top: 1.8em; font-size: 21px; line-height: 1.6; }
.prose h4 { margin-top: 1.6em; font-size: 18px; line-height: 1.6; }
.prose h2 + *, .prose h3 + *, .prose h4 + * { margin-top: .75em; }
.prose a { color: var(--brand); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 5px; }
.prose a:hover { text-decoration-thickness: 2px; }
.prose strong { font-weight: 700; color: var(--ink); }
.prose ul, .prose ol { padding-inline-start: 1.3em; }
.prose ol { list-style-type: persian; }
.prose li + li { margin-top: .5em; }
.prose li::marker { color: var(--brand); }
.prose blockquote, .prose .wp-block-quote {
	margin-inline: 0; padding: 20px 24px; border-inline-start: 4px solid var(--brand); border-radius: 16px;
	background: var(--brand-50); font-size: 18px; color: var(--ink);
}
.prose blockquote p { margin: 0; }
.prose blockquote cite { display: block; margin-top: 8px; font-size: 14px; font-style: normal; color: var(--muted); }
.prose .wp-block-pullquote { padding: 32px 0; border: 0; border-block: 2px solid var(--brand); text-align: center; }
.prose .wp-block-pullquote blockquote { border: 0; background: none; padding: 0; font-size: 24px; font-weight: 700; }
.prose img { height: auto; border-radius: 16px; }
.prose figure { margin-inline: 0; }
.prose figcaption, .prose .wp-element-caption { margin-top: 10px; font-size: 13px; color: var(--muted); text-align: center; }
.prose hr, .prose .wp-block-separator { height: 1px; margin-block: 2.5em; border: 0; background: var(--line); }
.prose code { padding: 2px 6px; border-radius: 6px; background: #f2f4f7; font-size: .88em; direction: ltr; unicode-bidi: embed; }
.prose pre { overflow-x: auto; padding: 20px; border-radius: 16px; background: var(--dark); color: #e4e7ec; direction: ltr; text-align: left; font-size: 14px; line-height: 1.7; }
.prose pre code { padding: 0; background: none; }
.prose .wp-block-table { overflow-x: auto; border: 1px solid var(--line); border-radius: 16px; }
.prose table { width: 100%; border-collapse: collapse; font-size: 15px; }
.prose th, .prose td { padding: 14px 16px; border: 0; border-bottom: 1px solid var(--line); text-align: start; }
.prose thead { border: 0; }
.prose thead th { background: var(--surface); font-size: 14px; font-weight: 500; color: var(--muted); }
.prose tbody tr:last-child td { border-bottom: 0; }
.prose .wp-block-buttons { display: flex; flex-wrap: wrap; gap: 12px; }
.prose .wp-block-button__link {
	display: inline-flex; padding: 12px 24px; border-radius: 8px; background: var(--brand);
	font-size: 15px; font-weight: 700; line-height: 1.5; color: #fff; text-decoration: none;
}
.prose .wp-block-button__link:hover { background: var(--brand-hover); }
.prose .wp-block-button.is-style-outline .wp-block-button__link { border: 1px solid var(--brand); background: transparent; color: var(--brand); }
.prose .alignwide { margin-inline: -48px; }
.prose .alignfull { max-width: 100vw; margin-inline: calc(50% - 50vw); }
.prose .alignleft { float: left; margin: .4em 0 1em 1.5em; }
.prose .alignright { float: right; margin: .4em 1.5em 1em 0; }
.prose .aligncenter { margin-inline: auto; }
.prose iframe, .prose .wp-block-embed { max-width: 100%; }

/* Block styles (Styles panel in the editor). */
.prose .is-style-dpex-takeaways {
	padding: 24px 28px; border: 1px solid #1a9e6e33; border-radius: 16px; background: var(--brand-50); list-style: none;
}
.prose .is-style-dpex-takeaways::before {
	content: "نکات کلیدی"; display: block; margin-bottom: 12px; font-size: 17px; font-weight: 700; color: var(--ink);
}
.prose ul.is-style-dpex-takeaways, .prose ol.is-style-dpex-takeaways { padding-inline-start: 28px; }
.prose .is-style-dpex-takeaways li { position: relative; padding-inline-start: 30px; }
.prose .is-style-dpex-takeaways li::marker { content: ""; }
.prose .is-style-dpex-takeaways li::before {
	content: "✓"; position: absolute; top: .6em; inset-inline-start: 0; width: 20px; height: 20px; border-radius: 50%;
	background: var(--brand); font-size: 11px; line-height: 20px; color: #fff; text-align: center;
}
.prose .is-style-dpex-tip, .prose .is-style-dpex-warning { padding: 16px 20px; border-inline-start: 4px solid; border-radius: 12px; }
.prose .is-style-dpex-tip { border-color: #2e90fa; background: #eff8ff; }
.prose .is-style-dpex-warning { border-color: #f79009; background: #fffaeb; }
.prose .is-style-dpex-tip::before, .prose .is-style-dpex-warning::before { font-weight: 700; }
.prose .is-style-dpex-tip::before { content: "نکته: "; color: #175cd3; }
.prose .is-style-dpex-warning::before { content: "هشدار: "; color: #b54708; }
.prose .wp-block-group.is-style-dpex-tip::before, .prose .wp-block-group.is-style-dpex-warning::before { display: block; }

/* ---------- Comments ---------- */
.comments { margin-top: 48px; }
.comments-title { margin-bottom: 16px; font-size: 22px; font-weight: 700; color: var(--ink); }
.comment-list { margin: 0 0 24px; padding: 0; list-style: none; }
.comment-list .children { padding-inline-start: 32px; list-style: none; }
.comment-body { padding: 16px 0; border-bottom: 1px solid var(--line); font-size: 15px; }
.comment-author { display: flex; align-items: center; gap: 10px; font-weight: 700; color: var(--ink); }
.comment-author .avatar { border-radius: 50%; }
.comment-author .says { display: none; }
.comment-metadata { margin-block: 4px 8px; font-size: 12px; color: var(--muted-2); }
.reply a { font-size: 13px; font-weight: 700; color: var(--brand); }
.comment-respond { padding: 24px; border: 1px solid var(--line); border-radius: 16px; }
.comment-reply-title { margin-bottom: 12px; font-size: 18px; font-weight: 700; color: var(--ink); }
.comment-form p { margin: 0 0 16px; font-size: 14px; color: var(--muted); }
.comment-form-comment, .comment-form-author, .comment-form-email, .comment-form-url { display: grid; gap: 6px; }
.comment-form label { font-weight: 500; color: var(--gray-700); }
.logged-in-as a { color: var(--brand); }
.comment-form input[type="text"], .comment-form input[type="email"], .comment-form input[type="url"], .comment-form textarea {
	width: 100%; padding: 12px 16px; border: 1px solid var(--line-2); border-radius: 12px; background: #fff; outline: none; transition: border-color .2s, box-shadow .2s;
}
.comment-form input:focus, .comment-form textarea:focus { border-color: var(--brand); box-shadow: 0 0 0 4px rgba(26, 158, 110, .12); }
.comment-form .comment-form-cookies-consent { display: flex; align-items: center; gap: 8px; }
.comment-form .form-submit { margin: 0; }

/* ==========================================================================
   Footer — copy of dpex.co
   ========================================================================== */
.site-footer { position: relative; isolation: isolate; background: linear-gradient(to bottom, #0c111d, #193038); color: #fff; }
.footer-pattern { position: absolute; inset: 0; z-index: -10; opacity: .3; pointer-events: none; background: url("../img/pattern.svg") 0 0 / 162px 81px repeat; }
.footer-coins { position: absolute; top: -96px; left: max(16px, calc((100% - 1216px) / 2 - 24px)); z-index: 10; display: none; width: 440px; aspect-ratio: 16 / 9; pointer-events: none; }
.footer-coins img { width: 100%; height: 100%; object-fit: contain; transform: scaleX(-1); }
.footer-inner { position: relative; width: 100%; max-width: 1264px; margin-inline: auto; padding: 40px 24px; }
.footer-brand { display: flex; flex-direction: column; align-items: center; gap: 16px; margin-bottom: 56px; text-align: center; }
.footer-brand svg { display: block; width: 155px; height: 48px; color: #fff; }
.footer-brand p { max-width: 600px; font-size: 14px; line-height: 28px; color: rgba(255, 255, 255, .7); }
.footer-columns { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 32px; }
.footer-columns h3 { margin-bottom: 16px; font-family: var(--font); font-size: 14px; font-weight: 600; line-height: 20px; }
.footer-columns ul { padding: 0; list-style: none; }
.footer-columns li + li { margin-top: 12px; }
.footer-columns a { font-size: 14px; line-height: 20px; color: rgba(255, 255, 255, .7); transition: color .15s; }
.footer-columns a:hover { color: #fff; }
.footer-contact { display: flex; flex-direction: column; align-items: center; gap: 24px; margin-top: 56px; font-size: 14px; color: rgba(255, 255, 255, .7); text-align: center; }
.footer-contact-start, .footer-contact-end { display: flex; flex-direction: column; align-items: center; gap: 16px; }
.footer-address { display: flex; align-items: center; justify-content: center; gap: 8px; }
.pin { display: inline-block; flex-shrink: 0; width: 18px; height: 18px; background: #fff; -webkit-mask: url("../img/location.svg") center / contain no-repeat; mask: url("../img/location.svg") center / contain no-repeat; }
.footer-digipay { width: fit-content; }
.footer-digipay img { width: 99px; height: auto; }
.footer-contact-end a:hover { color: #fff; }
.footer-copy { padding-bottom: 24px; font-size: 12px; line-height: 16px; color: rgba(255, 255, 255, .45); text-align: center; }

@media (min-width: 640px) {
	.footer-columns { grid-template-columns: repeat(4, minmax(0, 1fr)); }
	.footer-contact { flex-direction: row; align-items: flex-end; justify-content: space-between; text-align: start; }
	.footer-contact-start { align-items: flex-start; }
	.footer-contact-end { align-items: flex-end; }
	.footer-address { justify-content: flex-start; }
}
@media (min-width: 1024px) {
	.footer-coins { display: block; }
	.footer-inner { min-height: 507px; }
	.footer-brand { align-items: flex-start; text-align: start; }
}

/* ---------- Price ticker (desktop, fixed to the bottom like dpex.co) ---------- */
.ticker { position: fixed; inset-inline: 0; bottom: 0; z-index: 50; display: none; overflow: hidden; padding-block: 6px; border-top: 1px solid rgba(255, 255, 255, .08); background: rgba(12, 17, 29, .96); }
.ticker-track { display: flex; gap: 28px; width: max-content; padding-inline-end: 28px; animation: dpex-marquee 40s linear infinite; }
.ticker:hover .ticker-track { animation-play-state: paused; }
.ticker-item { display: flex; align-items: center; gap: 6px; font-size: 11px; line-height: 20px; color: rgba(255, 255, 255, .75); white-space: nowrap; }
.ticker-item img { width: 20px; height: 20px; border-radius: 50%; }
.ticker-item span:first-of-type { font-weight: 700; color: #fff; }
@keyframes dpex-marquee { from { transform: translateX(0); } to { transform: translateX(50%); } }
@media (min-width: 1024px) {
	.ticker { display: block; }
	.has-ticker { padding-bottom: 33px; }
}


/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 1100px) {
	.article-layout { grid-template-columns: minmax(0, 1fr); gap: 32px; }
	.article-main { max-width: none; }
	.article-aside { position: static; display: grid; grid-template-columns: 1fr 1fr; align-items: start; max-height: none; overflow: visible; }
	.aside-toc { display: none; }
	.toc-bar { display: block; }
	.prose .alignwide { margin-inline: 0; }
}

@media (max-width: 900px) {
	.post-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 40px 24px; }
	.filters { flex-direction: column-reverse; align-items: stretch; margin-bottom: 40px; }
	.sort { margin-inline-start: 0; align-self: flex-start; }
	.newsletter { flex-direction: column; align-items: stretch; gap: 20px; padding: 28px; }
	.newsletter-form { flex-basis: auto; }
	.toolbar { flex-direction: column; align-items: stretch; gap: 12px; }
	.toolbar-search { flex-basis: auto; }
	.section-title { font-size: 28px; line-height: 40px; }
}

@media (max-width: 782px) {
	.admin-bar .site-header, .admin-bar .read-progress { top: 46px; }
}
@media (max-width: 600px) {
	.admin-bar .site-header, .admin-bar .read-progress { top: 0; }
}

@media (max-width: 640px) {
	.hero-inner { padding-block: 40px 56px; }
	.hero-title { font-size: 32px; line-height: 46px; }
	.hero-sm .hero-title { font-size: 28px; line-height: 40px; }
	.hero-sub { font-size: 16px; line-height: 26px; }
	.hero-search { margin-top: 28px; }
	.search-form { height: 56px; padding-inline-start: 16px; }
	.search-form .btn { height: 40px; padding: 0 18px; }
	.page-body { padding-top: 32px; }
	.post-grid { grid-template-columns: 1fr; }
	.article-title { font-size: 26px; line-height: 40px; }
	.article-lead { font-size: 16px; line-height: 28px; }
	.article-cover img { border-radius: 14px; }
	.article-aside { grid-template-columns: 1fr; }
	.signup-cta { flex-direction: column; align-items: stretch; padding: 24px; }
	.post-nav { grid-template-columns: 1fr; }
	.prose { font-size: 16px; line-height: 2; }
	.prose h2 { font-size: 22px; }
	.prose h3 { font-size: 19px; }
	.newsletter { padding: 24px; }
	.newsletter-form .btn { padding: 0 18px; }
	.author-box { flex-direction: column; }
	.related { padding-block: 48px; }
	.section-sm { padding-bottom: 56px; }
}

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