/*
Theme Name: DM Publisher Theme
Theme URI: https://example.com/dm-publisher-theme
Author: DM Publisher
Author URI: https://example.com
Description: A lightweight premium publisher blog theme for fast US-market AdSense websites.
Version: 1.0.7
Requires at least: 6.0
Tested up to: 6.5
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: dm-publisher-theme
Tags: blog, news, custom-logo, featured-images, threaded-comments, translation-ready
*/

:root {
	--dm-bg: #ffffff;
	--dm-surface: #f7faff;
	--dm-surface-strong: #edf4ff;
	--dm-text: #08111f;
	--dm-muted: #617089;
	--dm-border: #dfe7f2;
	--dm-accent: #155dff;
	--dm-accent-dark: #0644d8;
	--dm-dark: #030812;
	--dm-radius: 12px;
	--dm-radius-sm: 8px;
	--dm-shadow: 0 16px 40px rgba(8, 17, 31, 0.08);
	--dm-max: 1240px;
}

* {
	box-sizing: border-box;
}

html {
	scroll-behavior: smooth;
}

body {
	margin: 0;
	background: var(--dm-bg);
	color: var(--dm-text);
	font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
	font-size: 16px;
	line-height: 1.6;
	text-rendering: optimizeLegibility;
}

a {
	color: inherit;
	text-decoration: none;
}

a:hover,
a:focus {
	color: var(--dm-accent);
}

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

button,
input,
textarea {
	font: inherit;
}

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

.dm-container {
	width: min(var(--dm-max), calc(100% - 40px));
	margin-inline: auto;
}

.dm-trending {
	background: linear-gradient(90deg, #050b14, #09111c);
	color: #fff;
	font-size: 13px;
}

.dm-trending__inner {
	min-height: 48px;
	display: flex;
	align-items: center;
	justify-content: flex-start;
	gap: 18px;
	overflow: hidden;
}

.dm-trending__label {
	display: inline-flex;
	align-items: center;
	gap: 7px;
	padding: 5px 11px;
	border-radius: 999px;
	background: #ef2e2e;
	font-weight: 800;
	letter-spacing: 0.02em;
	text-transform: uppercase;
}

.dm-trending__links {
	display: flex;
	align-items: center;
	gap: 22px;
	flex: 1;
	min-width: 0;
	white-space: nowrap;
	overflow-x: auto;
	scrollbar-width: none;
}

.dm-trending__links a {
	color: #fff;
	opacity: 0.9;
	flex: 0 0 auto;
}

.dm-trending__links::-webkit-scrollbar {
	display: none;
}

.dm-site-header {
	background: rgba(255, 255, 255, 0.96);
	border-bottom: 1px solid var(--dm-border);
	position: sticky;
	top: 0;
	z-index: 20;
	backdrop-filter: blur(12px);
}

.dm-header__inner {
	min-height: 96px;
	display: flex;
	align-items: center;
	gap: 28px;
}

.dm-logo {
	display: inline-flex;
	align-items: center;
	font-size: 28px;
	font-weight: 900;
	letter-spacing: -0.04em;
	white-space: nowrap;
}

.dm-logo span,
.site-title span {
	color: var(--dm-accent);
}

.custom-logo {
	max-height: 54px;
	width: auto;
}

.dm-nav {
	flex: 1;
}

.dm-menu {
	display: flex;
	align-items: center;
	gap: 24px;
	list-style: none;
	margin: 0;
	padding: 0;
	font-size: 14px;
	font-weight: 800;
	text-transform: uppercase;
}

.dm-menu ul {
	display: none;
}

.dm-header__actions {
	display: flex;
	align-items: center;
	gap: 14px;
}

.dm-search {
	width: min(230px, 22vw);
	position: relative;
}

.dm-search input[type="search"] {
	width: 100%;
	height: 42px;
	border: 1px solid var(--dm-border);
	border-radius: var(--dm-radius-sm);
	padding: 0 42px 0 14px;
	color: var(--dm-text);
	background: #fff;
}

.dm-search button {
	position: absolute;
	right: 6px;
	top: 6px;
	width: 30px;
	height: 30px;
	border: 0;
	border-radius: 7px;
	background: transparent;
	color: var(--dm-text);
	cursor: pointer;
}

.dm-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 42px;
	padding: 0 20px;
	border-radius: var(--dm-radius-sm);
	border: 1px solid var(--dm-dark);
	background: var(--dm-dark);
	color: #fff;
	font-size: 14px;
	font-weight: 800;
	cursor: pointer;
}

.dm-btn:hover,
.dm-btn:focus {
	background: var(--dm-accent);
	border-color: var(--dm-accent);
	color: #fff;
}

.dm-section {
	padding: 36px 0;
	clear: both;
}

.dm-section__head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	margin-bottom: 18px;
}

.dm-section__title {
	margin: 0;
	font-size: 18px;
	line-height: 1.2;
	text-transform: uppercase;
	letter-spacing: -0.02em;
}

.dm-section__link {
	font-size: 14px;
	font-weight: 700;
	color: var(--dm-text);
}

.dm-hero {
	padding-top: 34px;
}

.dm-hero-grid {
	display: grid;
	grid-template-columns: minmax(0, 1.08fr) minmax(0, 1.08fr);
	gap: 14px;
}

.dm-hero-grid__small {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 14px;
}

.dm-post-card {
	position: relative;
	overflow: hidden;
	border: 1px solid var(--dm-border);
	border-radius: var(--dm-radius);
	background: #fff;
}

.dm-post-card--image {
	min-height: 200px;
	background: var(--dm-dark);
	color: #fff;
}

.dm-post-card--large {
	min-height: 420px;
}

.dm-post-card--small {
	min-height: 203px;
}

.dm-post-card__thumb {
	position: absolute;
	inset: 0;
	display: block;
}

.dm-post-card__thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.dm-post-card--image::after {
	content: "";
	position: absolute;
	inset: 0;
	background: linear-gradient(180deg, rgba(3, 8, 18, 0.05), rgba(3, 8, 18, 0.82));
}

.dm-post-card__content {
	position: relative;
	z-index: 2;
	height: 100%;
	display: flex;
	flex-direction: column;
	justify-content: flex-end;
	padding: 22px;
}

.dm-post-card--large .dm-post-card__content {
	padding: 28px;
}

.dm-badge {
	display: inline-flex;
	align-items: center;
	align-self: flex-start;
	margin-bottom: 10px;
	padding: 5px 8px;
	border-radius: 6px;
	background: #e8f0ff;
	color: var(--dm-accent);
	font-size: 11px;
	line-height: 1;
	font-weight: 900;
	text-transform: uppercase;
}

.dm-badge--light {
	background: #fff;
	color: var(--dm-accent);
}

.dm-post-card__title {
	margin: 0;
	font-size: 20px;
	line-height: 1.18;
	letter-spacing: -0.03em;
}

.dm-post-card--large .dm-post-card__title {
	font-size: clamp(30px, 4vw, 44px);
	max-width: 720px;
}

.dm-post-card__excerpt {
	display: none;
}

.dm-meta {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 8px;
	margin-top: 14px;
	color: inherit;
	opacity: 0.82;
	font-size: 13px;
}

.dm-categories {
	display: grid;
	grid-template-columns: repeat(6, minmax(0, 1fr));
	gap: 12px;
}

.dm-category-card {
	display: flex;
	gap: 14px;
	min-height: 104px;
	padding: 20px;
	border: 1px solid var(--dm-border);
	border-radius: var(--dm-radius);
	background: #fff;
}

.dm-category-card__icon {
	width: 38px;
	height: 38px;
	display: grid;
	place-items: center;
	border-radius: 10px;
	background: var(--dm-surface-strong);
	color: var(--dm-accent);
	font-weight: 900;
}

.dm-category-card h3 {
	margin: 0 0 5px;
	font-size: 14px;
	line-height: 1.2;
}

.dm-category-card p {
	margin: 0;
	color: var(--dm-muted);
	font-size: 12px;
	line-height: 1.5;
}

.dm-split {
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	gap: 34px;
}

.dm-split > div {
	min-width: 0;
	overflow: hidden;
}

.dm-ranked-row {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
	gap: 18px;
}

.dm-mini-card {
	position: relative;
	min-width: 0;
	padding-bottom: 4px;
}

.dm-mini-card__thumb {
	display: block;
	aspect-ratio: 16 / 10;
	overflow: hidden;
	border: 1px solid var(--dm-border);
	border-radius: var(--dm-radius-sm);
	background: var(--dm-surface);
}

.dm-mini-card__thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.dm-rank {
	position: absolute;
	top: 0;
	left: 0;
	width: 26px;
	height: 26px;
	display: grid;
	place-items: center;
	border-radius: 7px 0 7px 0;
	background: var(--dm-dark);
	color: #fff;
	font-size: 12px;
	font-weight: 900;
}

.dm-mini-card h3,
.dm-editor-card h3,
.dm-latest-card h3,
.dm-guide-card h3 {
	margin: 10px 0 0;
	font-size: 14px;
	line-height: 1.3;
	letter-spacing: -0.02em;
	overflow-wrap: anywhere;
	word-break: normal;
}

.dm-mini-card h3 a,
.dm-editor-card h3 a,
.dm-latest-card h3 a,
.dm-article-card h2 a {
	display: -webkit-box;
	-webkit-box-orient: vertical;
	-webkit-line-clamp: 3;
	overflow: hidden;
}

.dm-mini-card .dm-meta,
.dm-editor-card .dm-meta,
.dm-latest-card .dm-meta {
	margin-top: 6px;
	color: var(--dm-muted);
}

.dm-editor-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
	gap: 18px;
}

.dm-editor-card {
	min-width: 0;
}

.dm-editor-card__thumb {
	display: block;
	aspect-ratio: 16 / 10;
	overflow: hidden;
	border-radius: var(--dm-radius-sm);
	background: var(--dm-surface);
}

.dm-editor-card__thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.dm-home-curated .dm-split {
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	gap: 40px;
}

.dm-home-curated .dm-ranked-row,
.dm-home-curated .dm-editor-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
	gap: 20px;
	align-items: start;
}

.dm-home-curated .dm-mini-card,
.dm-home-curated .dm-editor-card {
	min-width: 0;
	overflow: hidden;
}

.dm-home-curated .dm-mini-card__thumb,
.dm-home-curated .dm-editor-card__thumb {
	width: 100%;
	aspect-ratio: 16 / 9;
}

.dm-home-curated .dm-mini-card h3,
.dm-home-curated .dm-editor-card h3 {
	min-height: 0;
}

.dm-latest-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
	gap: 20px;
}

.dm-latest-card {
	display: grid;
	grid-template-columns: 100px minmax(0, 1fr);
	gap: 16px;
	align-items: center;
	min-height: 94px;
	padding: 12px;
	border: 1px solid var(--dm-border);
	border-radius: var(--dm-radius);
	background: #fff;
	min-width: 0;
}

.dm-latest-card--no-thumb {
	grid-template-columns: 1fr;
}

.dm-latest-card__thumb {
	display: block;
	width: 100px;
	aspect-ratio: 1.25;
	overflow: hidden;
	border-radius: var(--dm-radius-sm);
	background: var(--dm-surface);
}

.dm-latest-card__thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.dm-guides {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 18px;
}

.dm-guide-card {
	min-height: 148px;
	padding: 20px;
	border: 1px solid var(--dm-border);
	border-radius: var(--dm-radius);
	background: linear-gradient(135deg, #edf5ff, #ffffff);
}

.dm-guide-card:nth-child(2) {
	background: linear-gradient(135deg, #f2edff, #ffffff);
}

.dm-guide-card:nth-child(3) {
	background: linear-gradient(135deg, #eafaf2, #ffffff);
}

.dm-guide-card:nth-child(4) {
	background: linear-gradient(135deg, #fff0e9, #ffffff);
}

.dm-guide-card p {
	margin: 8px 0;
	color: #25334a;
	font-size: 14px;
}

.dm-guide-card a {
	font-weight: 900;
	font-size: 14px;
}

.dm-newsletter {
	padding: 36px 0 50px;
}

.dm-newsletter__inner {
	display: grid;
	grid-template-columns: minmax(0, 1fr) auto;
	align-items: center;
	gap: 34px;
	padding: 32px 40px;
	border-radius: var(--dm-radius);
	background: linear-gradient(90deg, #eaf3ff, #f4f8ff);
}

.dm-newsletter h2 {
	margin: 0 0 6px;
	font-size: 24px;
	line-height: 1.2;
	letter-spacing: -0.03em;
}

.dm-newsletter p {
	margin: 0 0 10px;
	color: #25334a;
}

.dm-cta-button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 46px;
	padding: 0 22px;
	border-radius: var(--dm-radius-sm);
	background: var(--dm-accent);
	color: #fff;
	font-weight: 800;
	white-space: nowrap;
}

.dm-cta-button:hover,
.dm-cta-button:focus {
	background: var(--dm-accent-dark);
	color: #fff;
}

.dm-site-footer {
	background: var(--dm-dark);
	color: #fff;
	padding: 46px 0 28px;
}

.dm-footer-grid {
	display: grid;
	grid-template-columns: 1.4fr repeat(4, 1fr);
	gap: 38px;
}

.dm-site-footer h2,
.dm-site-footer h3 {
	margin: 0 0 14px;
	line-height: 1.2;
}

.dm-site-footer p,
.dm-site-footer li,
.dm-site-footer a {
	color: #cdd7e5;
	font-size: 14px;
}

.dm-footer-menu,
.dm-tag-list {
	list-style: none;
	margin: 0;
	padding: 0;
}

.dm-tag-list {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}

.dm-tag-list a {
	display: inline-flex;
	padding: 7px 10px;
	border-radius: 8px;
	background: rgba(255, 255, 255, 0.08);
}

.dm-copyright {
	margin-top: 28px;
	padding-top: 20px;
	border-top: 1px solid rgba(255, 255, 255, 0.1);
	color: #aab6c5;
	font-size: 13px;
}

.dm-content-wrap {
	display: grid;
	grid-template-columns: minmax(0, 1fr) 320px;
	gap: 36px;
	padding: 36px 0 56px;
}

.dm-archive-header {
	margin-bottom: 24px;
}

.dm-archive-header .dm-search {
	width: min(100%, 560px);
	margin-top: 18px;
}

.dm-archive-title,
.dm-single-title {
	margin: 0 0 18px;
	font-size: clamp(34px, 5vw, 56px);
	line-height: 1.05;
	letter-spacing: -0.05em;
}

.dm-post-list {
	display: grid;
	gap: 18px;
}

.dm-archive-grid {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 18px;
}

.dm-archive-grid--related {
	grid-template-columns: repeat(3, minmax(0, 1fr));
}

.dm-article-card {
	display: flex;
	flex-direction: column;
	gap: 14px;
	padding: 16px;
	border: 1px solid var(--dm-border);
	border-radius: var(--dm-radius);
	background: #fff;
	min-width: 0;
}

.dm-article-card__thumb {
	display: block;
	aspect-ratio: 1.45;
	overflow: hidden;
	border-radius: var(--dm-radius-sm);
	background: var(--dm-surface);
}

.dm-article-card__thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.dm-article-card h2 {
	margin: 8px 0;
	font-size: 24px;
	line-height: 1.18;
	letter-spacing: -0.03em;
}

.dm-article-card p {
	margin: 0;
	color: var(--dm-muted);
}

.dm-single-header {
	padding: 42px 0 26px;
}

.dm-single-featured {
	border-radius: var(--dm-radius);
	overflow: hidden;
	border: 1px solid var(--dm-border);
	margin-bottom: 30px;
}

.dm-single-featured img {
	width: 100%;
	height: auto;
}

.dm-entry-content {
	font-size: 18px;
}

.dm-entry-content a {
	color: var(--dm-accent);
	text-decoration: underline;
}

.dm-entry-content h2,
.dm-entry-content h3 {
	line-height: 1.2;
	letter-spacing: -0.03em;
}

.dm-single-article {
	min-width: 0;
}

.dm-post-insights {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-top: 12px;
}

.dm-post-insights span {
	display: inline-flex;
	align-items: center;
	min-height: 30px;
	padding: 4px 10px;
	border: 1px solid var(--dm-border);
	border-radius: 999px;
	background: var(--dm-surface);
	color: #35435a;
	font-size: 12px;
}

.dm-toc,
.dm-newsletter-box {
	margin-bottom: 28px;
	padding: 22px;
	border: 1px solid var(--dm-border);
	border-radius: var(--dm-radius);
	background: var(--dm-surface);
}

.dm-toc h2,
.dm-newsletter-box h2 {
	margin: 0 0 8px;
	font-size: 18px;
	line-height: 1.25;
	letter-spacing: -0.02em;
}

.dm-toc p,
.dm-newsletter-box p {
	margin: 0;
	color: var(--dm-muted);
}

.dm-newsletter-box {
	margin-top: 28px;
	background: linear-gradient(90deg, #eaf3ff, #f7fbff);
}

.dm-newsletter-box .dm-cta-button {
	margin-top: 16px;
}

.dm-related-posts {
	margin-top: 30px;
}

.dm-ad-slot {
	display: none;
	place-items: center;
	min-height: 96px;
	margin: 26px 0;
	border: 1px dashed #b8c7dc;
	border-radius: var(--dm-radius);
	background: #f8fbff;
	color: #6b7b92;
	font-size: 12px;
	font-weight: 800;
	letter-spacing: 0.08em;
	text-transform: uppercase;
}

.dm-ad-slot span {
	opacity: 0.9;
}

.dm-archive-ad-break {
	grid-column: 1 / -1;
}

.dm-sidebar {
	display: grid;
	gap: 18px;
	align-content: start;
}

.dm-widget {
	padding: 20px;
	border: 1px solid var(--dm-border);
	border-radius: var(--dm-radius);
	background: #fff;
}

.dm-widget h2,
.dm-widget h3 {
	margin: 0 0 12px;
	font-size: 16px;
	text-transform: uppercase;
}

.dm-widget ul {
	margin: 0;
	padding-left: 18px;
}

.dm-pagination {
	margin-top: 28px;
}

.dm-pagination .nav-links {
	display: flex;
	gap: 8px;
	flex-wrap: wrap;
}

.dm-pagination a,
.dm-pagination span {
	display: inline-grid;
	place-items: center;
	min-width: 40px;
	height: 40px;
	border: 1px solid var(--dm-border);
	border-radius: 8px;
	padding: 0 12px;
}

.dm-pagination .current {
	background: var(--dm-accent);
	border-color: var(--dm-accent);
	color: #fff;
}

.dm-empty,
.dm-404 {
	padding: 70px 0;
	text-align: center;
}

.dm-mobile-toggle {
	display: none;
	width: 42px;
	height: 42px;
	border: 1px solid var(--dm-border);
	border-radius: 8px;
	background: #fff;
	cursor: pointer;
	align-items: center;
	justify-content: center;
	padding: 0;
	transition: border-color 0.16s ease, background-color 0.16s ease;
}

.dm-mobile-toggle:hover,
.dm-mobile-toggle:focus {
	border-color: var(--dm-accent);
	background: var(--dm-surface);
	outline: none;
}

.dm-mobile-toggle__icon,
.dm-mobile-toggle__icon::before,
.dm-mobile-toggle__icon::after {
	display: block;
	width: 18px;
	height: 2px;
	border-radius: 999px;
	background: var(--dm-text);
	content: "";
	transition: transform 0.16s ease, opacity 0.16s ease;
}

.dm-mobile-toggle__icon {
	position: relative;
}

.dm-mobile-toggle__icon::before,
.dm-mobile-toggle__icon::after {
	position: absolute;
	left: 0;
}

.dm-mobile-toggle__icon::before {
	top: -6px;
}

.dm-mobile-toggle__icon::after {
	top: 6px;
}

.dm-mobile-toggle[aria-expanded="true"] .dm-mobile-toggle__icon {
	background: transparent;
}

.dm-mobile-toggle[aria-expanded="true"] .dm-mobile-toggle__icon::before {
	transform: translateY(6px) rotate(45deg);
}

.dm-mobile-toggle[aria-expanded="true"] .dm-mobile-toggle__icon::after {
	transform: translateY(-6px) rotate(-45deg);
}

@media (max-width: 1080px) {
	.dm-hero-grid,
	.dm-split,
	.dm-content-wrap,
	.dm-newsletter__inner {
		grid-template-columns: 1fr;
	}

	.dm-categories,
	.dm-guides {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.dm-ranked-row,
	.dm-editor-grid,
	.dm-latest-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.dm-archive-grid,
	.dm-archive-grid--related {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

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

	.dm-content-wrap > .dm-sidebar {
		display: none;
	}
}

@media (max-width: 840px) {
	.dm-trending__inner {
		min-height: 44px;
	}

	.dm-trending__links {
		gap: 16px;
	}

	.dm-trending__links a {
		max-width: 240px;
		overflow: hidden;
		text-overflow: ellipsis;
	}

	.dm-header__inner {
		min-height: 76px;
		flex-wrap: wrap;
		gap: 14px;
	}

	.dm-mobile-toggle {
		display: inline-grid;
		place-items: center;
		margin-left: auto;
	}

	.dm-nav {
		display: none;
		order: 4;
		flex-basis: 100%;
	}

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

	.dm-menu {
		align-items: stretch;
		flex-direction: column;
		gap: 0;
		padding-bottom: 12px;
	}

	.dm-menu a {
		display: block;
		padding: 10px 0;
	}

	.dm-header__actions {
		order: 3;
		width: 100%;
	}

	.dm-search {
		flex: 1;
		width: auto;
	}

	.dm-trending__links {
		overflow-x: auto;
	}

	.dm-trending__readers {
		display: none;
	}
}

@media (max-width: 680px) {
	.dm-container {
		width: min(100% - 28px, var(--dm-max));
	}

	.dm-section {
		padding: 26px 0;
	}

	.dm-section__head {
		align-items: flex-start;
		flex-direction: column;
		gap: 8px;
	}

	.dm-hero-grid__small,
	.dm-categories,
	.dm-ranked-row,
	.dm-editor-grid,
	.dm-latest-grid,
	.dm-guides,
	.dm-footer-grid {
		grid-template-columns: 1fr;
	}

	.dm-post-card--large,
	.dm-post-card--small {
		min-height: 280px;
	}

	.dm-mini-card,
	.dm-editor-card,
	.dm-latest-card,
	.dm-article-card {
		width: 100%;
	}

	.dm-mini-card__thumb,
	.dm-editor-card__thumb,
	.dm-article-card__thumb {
		aspect-ratio: 16 / 9;
	}

	.dm-latest-card,
	.dm-article-card {
		grid-template-columns: 1fr;
	}

	.dm-archive-grid,
	.dm-archive-grid--related {
		grid-template-columns: 1fr;
	}

	.dm-latest-card__thumb {
		width: 100%;
	}

	.dm-newsletter__inner {
		padding: 26px 22px;
	}

	.dm-cta-button {
		width: 100%;
	}
}

/* Homepage curated sections: final responsive guard against card collisions. */
.dm-home-curated .dm-split {
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	gap: 40px;
}

.dm-home-curated .dm-ranked-row,
.dm-home-curated .dm-editor-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
	gap: 20px;
	align-items: start;
}

.dm-home-curated .dm-mini-card,
.dm-home-curated .dm-editor-card {
	min-width: 0;
	overflow: hidden;
}

.dm-home-curated .dm-mini-card__thumb,
.dm-home-curated .dm-editor-card__thumb {
	width: 100%;
	aspect-ratio: 16 / 9;
}

.dm-home-curated .dm-mini-card h3 a,
.dm-home-curated .dm-editor-card h3 a {
	display: -webkit-box;
	-webkit-box-orient: vertical;
	-webkit-line-clamp: 3;
	overflow: hidden;
}

@media (max-width: 900px) {
	.dm-home-curated .dm-ranked-row,
	.dm-home-curated .dm-editor-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

@media (max-width: 560px) {
	.dm-home-curated .dm-ranked-row,
	.dm-home-curated .dm-editor-grid {
		grid-template-columns: 1fr;
	}
}

.dm-contact-hero {
	padding: 72px 0;
	background:
		linear-gradient(90deg, rgba(3, 8, 18, 0.88), rgba(5, 39, 88, 0.78)),
		linear-gradient(135deg, #07152a, #0d5cff);
	color: #fff;
	text-align: center;
}

.dm-contact-hero h1 {
	margin: 0;
	font-size: clamp(42px, 7vw, 68px);
	line-height: 1;
	letter-spacing: -0.05em;
}

.dm-contact-hero p {
	margin: 14px 0 0;
	color: rgba(255, 255, 255, 0.82);
}

.dm-contact-page {
	padding: 46px 0 64px;
}

.dm-contact-layout {
	display: grid;
	grid-template-columns: minmax(0, 1fr) 420px;
	gap: 36px;
	align-items: start;
}

.dm-contact-intro h2,
.dm-contact-section h2,
.dm-contact-form-card h2,
.dm-contact-cta h2 {
	margin: 0 0 16px;
	font-size: clamp(26px, 4vw, 38px);
	line-height: 1.12;
	letter-spacing: -0.04em;
}

.dm-contact-intro p,
.dm-contact-section p,
.dm-contact-cta p {
	color: #263852;
}

.dm-contact-cards {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	margin-top: 28px;
	border: 1px solid var(--dm-border);
	border-radius: var(--dm-radius);
	overflow: hidden;
	background: #fff;
}

.dm-contact-card {
	min-height: 180px;
	padding: 24px;
	border-right: 1px solid var(--dm-border);
	border-bottom: 1px solid var(--dm-border);
}

.dm-contact-card:nth-child(3n) {
	border-right: 0;
}

.dm-contact-card:nth-last-child(-n+3) {
	border-bottom: 0;
}

.dm-contact-card__icon {
	display: grid;
	place-items: center;
	width: 42px;
	height: 42px;
	margin-bottom: 16px;
	border-radius: 10px;
	background: var(--dm-surface-strong);
	color: var(--dm-accent);
	font-weight: 900;
}

.dm-contact-card h3 {
	margin: 0 0 8px;
	font-size: 17px;
	line-height: 1.25;
}

.dm-contact-card p {
	margin: 0;
	color: var(--dm-muted);
	font-size: 14px;
}

.dm-contact-form-card,
.dm-contact-section,
.dm-contact-cta {
	border: 1px solid var(--dm-border);
	border-radius: var(--dm-radius);
	background: #fff;
	box-shadow: 0 16px 36px rgba(8, 17, 31, 0.05);
}

.dm-contact-form-card {
	position: sticky;
	top: 126px;
	padding: 26px;
}

.dm-contact-form {
	display: grid;
	gap: 14px;
}

.dm-contact-form label {
	display: grid;
	gap: 7px;
	color: #21324a;
	font-size: 14px;
	font-weight: 800;
}

.dm-contact-form input,
.dm-contact-form select,
.dm-contact-form textarea {
	width: 100%;
	border: 1px solid var(--dm-border);
	border-radius: 8px;
	background: #fff;
	color: var(--dm-text);
	padding: 12px 13px;
}

.dm-contact-form textarea {
	min-height: 132px;
	resize: vertical;
}

.dm-contact-form button {
	min-height: 46px;
	border: 0;
	border-radius: 8px;
	background: var(--dm-accent);
	color: #fff;
	font-weight: 900;
	cursor: pointer;
}

.dm-contact-form button:hover,
.dm-contact-form button:focus {
	background: var(--dm-accent-dark);
}

.dm-form-note {
	margin: 12px 0 0;
	color: var(--dm-muted);
	font-size: 13px;
	text-align: center;
}

.dm-form-message {
	margin-bottom: 16px;
	padding: 12px 14px;
	border-radius: 8px;
	background: #eafaf2;
	color: #14532d;
	font-weight: 800;
}

.dm-form-message--error {
	background: #fff1f2;
	color: #9f1239;
}

.dm-contact-sections {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 24px;
	margin-top: 34px;
}

.dm-contact-section {
	padding: 28px;
}

.dm-contact-section h2 {
	font-size: 24px;
}

.dm-check-list,
.dm-audience-list {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 10px 18px;
	margin: 18px 0;
	padding: 0;
	list-style: none;
}

.dm-check-list li,
.dm-audience-list li {
	position: relative;
	padding-left: 22px;
	color: #263852;
	font-size: 14px;
}

.dm-check-list li::before,
.dm-audience-list li::before {
	content: "";
	position: absolute;
	left: 0;
	top: 0.72em;
	width: 8px;
	height: 8px;
	border-radius: 50%;
	background: var(--dm-accent);
}

.dm-requirements {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 10px 18px;
	margin-top: 20px;
	padding: 18px;
	border-radius: var(--dm-radius-sm);
	background: var(--dm-surface);
}

.dm-requirements ul {
	margin: 0;
	padding-left: 18px;
}

.dm-contact-cta {
	display: block;
	margin-top: 34px;
	padding: 34px;
	background: linear-gradient(90deg, #eef6ff, #ffffff);
	text-align: center;
}

.dm-contact-cta p {
	max-width: 760px;
	margin-left: auto;
	margin-right: auto;
}

.dm-contact-cta .dm-cta-button {
	margin-top: 8px;
}

@media (max-width: 1080px) {
	.dm-contact-layout {
		grid-template-columns: 1fr;
	}

	.dm-contact-form-card {
		position: static;
	}
}

@media (max-width: 760px) {
	.dm-contact-cards,
	.dm-contact-sections,
	.dm-check-list,
	.dm-audience-list,
	.dm-requirements,
	.dm-contact-cta {
		grid-template-columns: 1fr;
	}

	.dm-contact-card,
	.dm-contact-card:nth-child(3n),
	.dm-contact-card:nth-last-child(-n+3) {
		border-right: 0;
		border-bottom: 1px solid var(--dm-border);
	}

	.dm-contact-card:last-child {
		border-bottom: 0;
	}
}

@media (max-width: 680px) {
	.dm-contact-hero {
		padding: 54px 0;
	}

	.dm-contact-page {
		padding: 30px 0 46px;
	}

	.dm-contact-form-card,
	.dm-contact-section,
	.dm-contact-cta {
		padding: 22px;
	}
}
