/* ==========================================================================
   LearnMarketing — editorial theme styles
   Tokens first, then base, then components. Light + dark via [data-theme].
   ========================================================================== */

/* ---------- Fonts ---------- */
@font-face {
	font-family: "Fraunces";
	src: url("../fonts/fraunces-var-latin.woff2") format("woff2");
	font-weight: 400 700;
	font-display: swap;
}
@font-face {
	font-family: "InterVar";
	src: url("../fonts/inter-var-latin.woff2") format("woff2");
	font-weight: 100 900;
	font-display: swap;
}

/* ---------- Tokens ---------- */
:root {
	--lm-font-display: "Fraunces", Georgia, "Times New Roman", serif;
	--lm-font-body: "InterVar", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

	--lm-bg: #ffffff;
	--lm-surface: #f6f7f9;
	--lm-surface-2: #eef1f5;
	--lm-ink: #10182b;
	--lm-ink-soft: #46536b;
	--lm-ink-faint: #6b7891;
	--lm-line: #e4e8ee;
	--lm-brand: #1d4ed8;
	--lm-brand-ink: #1a3fae;
	--lm-brand-soft: #e8eeff;
	--lm-accent: #d97706;
	--lm-accent-ink: #b45309;
	--lm-accent-soft: #fdf0dd;
	--lm-card-shadow: 0 1px 2px rgba(16, 24, 43, 0.05), 0 8px 24px -12px rgba(16, 24, 43, 0.12);
	--lm-card-shadow-hover: 0 2px 4px rgba(16, 24, 43, 0.06), 0 16px 36px -12px rgba(16, 24, 43, 0.2);

	--lm-radius: 14px;
	--lm-radius-sm: 8px;
	--lm-container: 1140px;
	--lm-narrow: 720px;
}

[data-theme="dark"] {
	--lm-bg: #0c1118;
	--lm-surface: #121926;
	--lm-surface-2: #1a2333;
	--lm-ink: #e9edf4;
	--lm-ink-soft: #a6b1c4;
	--lm-ink-faint: #7c8aa3;
	--lm-line: #232e42;
	--lm-brand: #7396ff;
	--lm-brand-ink: #9ab3ff;
	--lm-brand-soft: #1a2643;
	--lm-accent: #f0a63c;
	--lm-accent-ink: #f4b95f;
	--lm-accent-soft: #33261263;
	--lm-card-shadow: 0 1px 2px rgba(0, 0, 0, 0.35), 0 10px 26px -12px rgba(0, 0, 0, 0.5);
	--lm-card-shadow-hover: 0 2px 4px rgba(0, 0, 0, 0.4), 0 18px 40px -12px rgba(0, 0, 0, 0.6);
}

/* ---------- Base ---------- */
*,
*::before,
*::after {
	box-sizing: border-box;
}

html {
	-webkit-text-size-adjust: 100%;
	scroll-behavior: smooth;
}

body {
	margin: 0;
	font-family: var(--lm-font-body);
	font-size: 1.0625rem;
	line-height: 1.7;
	color: var(--lm-ink);
	background: var(--lm-bg);
	transition: background-color 0.25s ease, color 0.25s ease;
}

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

a {
	color: var(--lm-brand-ink);
	text-decoration: none;
}

a:hover {
	text-decoration: underline;
	text-underline-offset: 3px;
}

h1, h2, h3, h4 {
	font-family: var(--lm-font-display);
	font-weight: 600;
	line-height: 1.18;
	letter-spacing: -0.01em;
	color: var(--lm-ink);
	margin: 0 0 0.5em;
	text-wrap: balance;
}

.screen-reader-text {
	position: absolute !important;
	width: 1px;
	height: 1px;
	clip-path: inset(50%);
	overflow: hidden;
	white-space: nowrap;
}

.screen-reader-text:focus {
	position: fixed !important;
	top: 8px;
	left: 8px;
	z-index: 999;
	width: auto;
	height: auto;
	clip-path: none;
	background: var(--lm-bg);
	padding: 10px 16px;
	border-radius: var(--lm-radius-sm);
	box-shadow: var(--lm-card-shadow);
}

.lm-container {
	max-width: var(--lm-container);
	margin: 0 auto;
	padding: 0 clamp(16px, 4vw, 28px);
}

.lm-container--narrow {
	max-width: var(--lm-narrow);
}

.lm-container--wideimg {
	max-width: 900px;
}

/* ---------- Reading progress ---------- */
.lm-progress {
	position: fixed;
	inset: 0 0 auto 0;
	height: 3px;
	z-index: 60;
	background: transparent;
}

.lm-progress-bar {
	display: block;
	height: 100%;
	width: 0;
	background: linear-gradient(90deg, var(--lm-brand), var(--lm-accent));
	transition: width 0.08s linear;
}

/* ---------- Header ---------- */
.lm-header {
	position: sticky;
	top: 0;
	z-index: 50;
	background: color-mix(in srgb, var(--lm-bg) 86%, transparent);
	backdrop-filter: blur(14px);
	-webkit-backdrop-filter: blur(14px);
	border-bottom: 1px solid var(--lm-line);
}

.lm-header-inner {
	display: flex;
	align-items: center;
	gap: 20px;
	min-height: 64px;
}

.lm-wordmark {
	font-family: var(--lm-font-body);
	font-size: 1.35rem;
	letter-spacing: -0.02em;
	white-space: nowrap;
	text-decoration: none !important;
}

.lm-wordmark-strong {
	font-weight: 800;
	color: var(--lm-brand);
}

.lm-wordmark-light {
	font-weight: 450;
	color: var(--lm-ink);
}

.custom-logo {
	max-height: 44px;
	width: auto;
	display: block;
}

.lm-nav {
	flex: 1;
	display: flex;
	align-items: center;
	justify-content: flex-end;
}

.lm-nav-list {
	display: flex;
	align-items: center;
	gap: 4px;
	list-style: none;
	margin: 0;
	padding: 0;
}

.lm-nav-list a {
	display: inline-block;
	padding: 8px 13px;
	border-radius: 999px;
	font-size: 0.95rem;
	font-weight: 550;
	color: var(--lm-ink-soft);
	text-decoration: none !important;
	transition: background-color 0.15s ease, color 0.15s ease;
}

.lm-nav-list a:hover,
.lm-nav-list .current-menu-item > a,
.lm-nav-list .current_page_item > a {
	color: var(--lm-brand-ink);
	background: var(--lm-brand-soft);
}

.lm-nav-list .sub-menu {
	display: none;
}

.lm-nav-extras {
	display: none;
}

.lm-header-actions {
	display: flex;
	align-items: center;
	gap: 6px;
}

.lm-icon-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 38px;
	height: 38px;
	border: none;
	border-radius: 999px;
	background: transparent;
	color: var(--lm-ink-soft);
	cursor: pointer;
	transition: background-color 0.15s ease, color 0.15s ease;
}

.lm-icon-btn:hover {
	background: var(--lm-surface-2);
	color: var(--lm-ink);
}

.lm-burger {
	display: none;
}

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

.lm-search-drawer {
	border-top: 1px solid var(--lm-line);
	padding: 14px 0;
	background: var(--lm-bg);
}

.lm-search-form {
	display: flex;
	gap: 10px;
}

.lm-search-form input[type="search"] {
	flex: 1;
	min-width: 0;
	padding: 11px 16px;
	font: inherit;
	font-size: 1rem;
	color: var(--lm-ink);
	background: var(--lm-surface);
	border: 1px solid var(--lm-line);
	border-radius: var(--lm-radius-sm);
}

.lm-search-form input[type="search"]:focus {
	outline: 2px solid var(--lm-brand);
	outline-offset: 1px;
	border-color: transparent;
}

/* ---------- Buttons ---------- */
.lm-btn {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 11px 20px;
	border: none;
	border-radius: 999px;
	font: inherit;
	font-size: 0.95rem;
	font-weight: 600;
	color: var(--lm-brand-ink);
	background: var(--lm-brand-soft);
	cursor: pointer;
	text-decoration: none !important;
	transition: transform 0.12s ease, box-shadow 0.12s ease, background-color 0.15s ease;
}

.lm-btn:hover {
	transform: translateY(-1px);
}

.lm-btn--accent {
	color: #fff;
	background: linear-gradient(120deg, var(--lm-brand), #3b6ce8);
	box-shadow: 0 6px 16px -6px rgba(29, 78, 216, 0.55);
}

[data-theme="dark"] .lm-btn--accent {
	color: #0c1118;
	background: linear-gradient(120deg, var(--lm-brand), #9ab3ff);
}

/* ---------- Chips & meta ---------- */
.lm-chip {
	display: inline-block;
	padding: 4px 12px;
	border-radius: 999px;
	font-size: 0.78rem;
	font-weight: 650;
	letter-spacing: 0.04em;
	text-transform: uppercase;
	color: var(--lm-accent-ink);
	background: var(--lm-accent-soft);
	text-decoration: none !important;
}

.lm-chip:hover {
	filter: brightness(0.96);
}

.lm-meta {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	font-size: 0.85rem;
	color: var(--lm-ink-faint);
}

.lm-meta-dot {
	opacity: 0.7;
}

.lm-eyebrow {
	margin: 0 0 6px;
	font-size: 0.82rem;
	font-weight: 700;
	letter-spacing: 0.09em;
	text-transform: uppercase;
	color: var(--lm-accent-ink);
}

/* ---------- Sections ---------- */
.lm-section {
	padding: clamp(28px, 4.5vw, 52px) 0;
}

.lm-section--hero {
	padding-top: clamp(24px, 4vw, 44px);
}

.lm-section-head {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	margin-bottom: 22px;
}

.lm-section-title {
	font-size: clamp(1.4rem, 2.6vw, 1.8rem);
	margin: 0;
}

.lm-section-title::after {
	content: "";
	display: block;
	width: 44px;
	height: 3px;
	margin-top: 8px;
	border-radius: 2px;
	background: linear-gradient(90deg, var(--lm-brand), var(--lm-accent));
}

/* ---------- Hero card ---------- */
.lm-hero {
	display: grid;
	grid-template-columns: 1.15fr 1fr;
	gap: clamp(20px, 3.5vw, 44px);
	align-items: center;
	background: var(--lm-surface);
	border: 1px solid var(--lm-line);
	border-radius: calc(var(--lm-radius) + 6px);
	padding: clamp(18px, 3vw, 34px);
}

.lm-hero-media {
	display: block;
	border-radius: var(--lm-radius);
	overflow: hidden;
	aspect-ratio: 16 / 10;
	background: var(--lm-surface-2);
}

.lm-hero-media img,
.lm-hero-media .lm-thumb-fallback {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
	transition: transform 0.35s ease;
}

.lm-hero:hover .lm-hero-media img {
	transform: scale(1.03);
}

.lm-hero-title {
	font-size: clamp(1.6rem, 3.4vw, 2.4rem);
	margin: 12px 0 10px;
}

.lm-hero-title a {
	color: inherit;
	text-decoration: none !important;
}

.lm-hero-title a:hover {
	color: var(--lm-brand-ink);
}

.lm-hero-excerpt {
	margin: 0 0 18px;
	color: var(--lm-ink-soft);
	font-size: 1.02rem;
}

.lm-hero-meta {
	display: flex;
	align-items: center;
	gap: 18px;
	flex-wrap: wrap;
}

/* ---------- Cards & grid ---------- */
.lm-grid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: clamp(18px, 2.5vw, 28px);
}

.lm-card {
	display: flex;
	flex-direction: column;
	background: var(--lm-bg);
	border: 1px solid var(--lm-line);
	border-radius: var(--lm-radius);
	overflow: hidden;
	box-shadow: var(--lm-card-shadow);
	transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.lm-card:hover {
	transform: translateY(-4px);
	box-shadow: var(--lm-card-shadow-hover);
}

.lm-card-media {
	display: block;
	aspect-ratio: 16 / 10;
	overflow: hidden;
	background: var(--lm-surface-2);
}

.lm-card-media img,
.lm-card-media .lm-thumb-fallback {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
	transition: transform 0.35s ease;
}

.lm-card:hover .lm-card-media img {
	transform: scale(1.045);
}

/* Odd-ratio images: contained over a blurred copy of themselves */
.lm-thumb-contain {
	display: block;
	position: relative;
	width: 100%;
	height: 100%;
	overflow: hidden;
}

.lm-thumb-contain::before {
	content: "";
	position: absolute;
	inset: 0;
	background-image: var(--lm-thumb-src);
	background-size: cover;
	background-position: center;
	filter: blur(26px) saturate(1.15);
	transform: scale(1.2);
	opacity: 0.5;
}

.lm-thumb-img--contain {
	position: relative;
	width: 100%;
	height: 100%;
	object-fit: contain !important;
}

.lm-card:hover .lm-thumb-img--contain,
.lm-hero:hover .lm-thumb-img--contain {
	transform: none;
}

.lm-thumb-fallback {
	display: grid;
	place-items: center;
	background:
		radial-gradient(120% 120% at 15% 15%, hsl(var(--lm-fb-hue, 214) 82% 60% / 0.92), transparent 60%),
		radial-gradient(120% 120% at 85% 80%, hsl(calc(var(--lm-fb-hue, 214) + 40) 75% 45% / 0.9), transparent 65%),
		hsl(var(--lm-fb-hue, 214) 60% 30%);
}

.lm-thumb-fallback span {
	font-family: var(--lm-font-display);
	font-size: 3.4rem;
	font-weight: 600;
	color: rgba(255, 255, 255, 0.9);
}

.lm-card-body {
	display: flex;
	flex-direction: column;
	gap: 10px;
	padding: 18px 20px 20px;
	flex: 1;
}

.lm-card-title {
	font-size: 1.18rem;
	margin: 0;
}

.lm-card-title a {
	color: inherit;
	text-decoration: none !important;
}

.lm-card-title a:hover {
	color: var(--lm-brand-ink);
}

.lm-card-excerpt {
	margin: 0;
	font-size: 0.93rem;
	line-height: 1.6;
	color: var(--lm-ink-soft);
	display: -webkit-box;
	-webkit-line-clamp: 3;
	-webkit-box-orient: vertical;
	overflow: hidden;
	flex: 1;
}

/* ---------- Popular list ---------- */
.lm-section--popular {
	padding-top: 0;
}

.lm-popular-list {
	counter-reset: pop;
	list-style: none;
	margin: 0;
	padding: 0;
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: 18px;
}

.lm-popular-list li {
	counter-increment: pop;
	position: relative;
}

.lm-popular-list a {
	display: flex;
	flex-direction: column;
	gap: 6px;
	height: 100%;
	padding: 16px 18px 16px 58px;
	background: var(--lm-surface);
	border: 1px solid var(--lm-line);
	border-radius: var(--lm-radius);
	text-decoration: none !important;
	transition: transform 0.15s ease, border-color 0.15s ease;
}

.lm-popular-list a:hover {
	transform: translateY(-3px);
	border-color: var(--lm-brand);
}

.lm-popular-list a::before {
	content: counter(pop, decimal-leading-zero);
	position: absolute;
	left: 16px;
	top: 12px;
	font-family: var(--lm-font-display);
	font-size: 1.6rem;
	font-weight: 600;
	color: var(--lm-brand);
	opacity: 0.85;
}

.lm-popular-title {
	font-weight: 600;
	font-size: 0.97rem;
	line-height: 1.4;
	color: var(--lm-ink);
	display: -webkit-box;
	-webkit-line-clamp: 3;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

/* ---------- Topics ---------- */
.lm-topics {
	display: flex;
	flex-wrap: wrap;
	gap: 12px;
}

.lm-topic {
	display: inline-flex;
	flex-direction: column;
	gap: 2px;
	padding: 12px 20px;
	border: 1px solid var(--lm-line);
	border-radius: var(--lm-radius);
	background: var(--lm-surface);
	text-decoration: none !important;
	transition: transform 0.15s ease, border-color 0.15s ease, background-color 0.15s ease;
}

.lm-topic:hover {
	transform: translateY(-2px);
	border-color: var(--lm-brand);
	background: var(--lm-brand-soft);
}

.lm-topic-name {
	font-weight: 650;
	color: var(--lm-ink);
}

.lm-topic-count {
	font-size: 0.8rem;
	color: var(--lm-ink-faint);
}

/* ---------- Newsletter ---------- */
.lm-newsletter {
	border-radius: calc(var(--lm-radius) + 6px);
	padding: clamp(24px, 4vw, 44px);
	background:
		radial-gradient(90% 140% at 8% 0%, rgba(29, 78, 216, 0.14), transparent 55%),
		radial-gradient(80% 120% at 95% 100%, rgba(217, 119, 6, 0.13), transparent 55%),
		var(--lm-surface);
	border: 1px solid var(--lm-line);
	display: grid;
	gap: 18px;
}

.lm-newsletter--band {
	grid-template-columns: 1.2fr 1fr;
	align-items: center;
}

.lm-newsletter--inline {
	margin-top: 34px;
}

.lm-newsletter-title {
	font-size: clamp(1.3rem, 2.4vw, 1.7rem);
	margin: 0 0 6px;
}

.lm-newsletter-sub {
	margin: 0;
	color: var(--lm-ink-soft);
	font-size: 0.97rem;
}

.lm-newsletter-form {
	display: flex;
	gap: 10px;
	flex-wrap: wrap;
}

.lm-newsletter-form input[type="email"] {
	flex: 1;
	min-width: 220px;
	padding: 12px 16px;
	font: inherit;
	font-size: 1rem;
	color: var(--lm-ink);
	background: var(--lm-bg);
	border: 1px solid var(--lm-line);
	border-radius: 999px;
}

.lm-newsletter-form input[type="email"]:focus {
	outline: 2px solid var(--lm-brand);
	outline-offset: 1px;
	border-color: transparent;
}

.lm-hp {
	position: absolute !important;
	left: -9999px;
}

.lm-newsletter-done {
	font-weight: 650;
	color: var(--lm-brand-ink);
	margin: 0;
}

.lm-newsletter-error {
	grid-column: 1 / -1;
	color: #c2410c;
	font-size: 0.9rem;
	margin: 0;
}

/* ---------- Article ---------- */
.lm-article-header {
	padding: clamp(30px, 5vw, 56px) 0 0;
}

.lm-article-chips {
	margin-bottom: 14px;
}

.lm-article-title {
	font-size: clamp(1.9rem, 4.5vw, 3rem);
	margin-bottom: 14px;
}

.lm-article-standfirst {
	font-size: clamp(1.05rem, 2vw, 1.25rem);
	line-height: 1.55;
	color: var(--lm-ink-soft);
	margin: 0 0 16px;
}

.lm-article-meta {
	padding-bottom: 8px;
}

.lm-article-figure {
	margin: clamp(20px, 3vw, 36px) 0 0;
}

.lm-article-image {
	width: 100%;
	border-radius: var(--lm-radius);
}

/* TOC */
.lm-toc {
	margin: clamp(24px, 3vw, 36px) 0 6px;
	padding: 18px 22px;
	background: var(--lm-surface);
	border: 1px solid var(--lm-line);
	border-left: 3px solid var(--lm-brand);
	border-radius: var(--lm-radius-sm);
}

.lm-toc-label {
	margin: 0 0 8px;
	font-size: 0.8rem;
	font-weight: 700;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: var(--lm-ink-faint);
}

.lm-toc-list {
	margin: 0;
	padding-left: 18px;
	display: grid;
	gap: 4px;
	font-size: 0.95rem;
}

.lm-toc-list a {
	color: var(--lm-ink-soft);
}

.lm-toc-list a:hover {
	color: var(--lm-brand-ink);
}

/* Prose */
.lm-prose {
	padding: clamp(18px, 3vw, 28px) 0 8px;
	font-size: 1.11rem;
	line-height: 1.78;
}

.lm-prose > p:first-child::first-letter {
	font-family: var(--lm-font-display);
	font-size: 3.1em;
	font-weight: 600;
	float: left;
	line-height: 0.82;
	padding: 6px 10px 0 0;
	color: var(--lm-brand);
}

.lm-prose h2 {
	font-size: 1.65rem;
	margin: 1.7em 0 0.6em;
}

.lm-prose h3 {
	font-size: 1.3rem;
	margin: 1.5em 0 0.5em;
}

.lm-prose a {
	text-decoration: underline;
	text-decoration-color: color-mix(in srgb, var(--lm-brand) 40%, transparent);
	text-underline-offset: 3px;
}

.lm-prose blockquote {
	margin: 1.6em 0;
	padding: 4px 0 4px 22px;
	border-left: 3px solid var(--lm-accent);
	font-family: var(--lm-font-display);
	font-size: 1.18em;
	line-height: 1.5;
	color: var(--lm-ink-soft);
}

.lm-prose img {
	border-radius: var(--lm-radius-sm);
}

.lm-prose pre {
	background: var(--lm-surface-2);
	padding: 16px 20px;
	border-radius: var(--lm-radius-sm);
	overflow-x: auto;
	font-size: 0.88em;
}

.lm-prose table {
	width: 100%;
	border-collapse: collapse;
	font-size: 0.94em;
}

.lm-prose th,
.lm-prose td {
	border: 1px solid var(--lm-line);
	padding: 9px 12px;
	text-align: left;
}

.lm-prose th {
	background: var(--lm-surface);
}

.lm-article-footer {
	padding: 10px 0 clamp(24px, 4vw, 40px);
}

.lm-tags {
	display: inline-flex;
	flex-wrap: wrap;
	gap: 8px;
}

.lm-tags a {
	font-size: 0.83rem;
	padding: 4px 12px;
	border-radius: 999px;
	background: var(--lm-surface-2);
	color: var(--lm-ink-soft);
	text-decoration: none !important;
}

.lm-tags a:hover {
	background: var(--lm-brand-soft);
	color: var(--lm-brand-ink);
}

.lm-section--related {
	background: var(--lm-surface);
	border-top: 1px solid var(--lm-line);
}

/* Up Next floating card */
.lm-upnext {
	position: fixed;
	right: 22px;
	bottom: 22px;
	z-index: 55;
	width: min(340px, calc(100vw - 44px));
	padding: 16px 40px 16px 18px;
	background: var(--lm-bg);
	border: 1px solid var(--lm-line);
	border-radius: var(--lm-radius);
	box-shadow: var(--lm-card-shadow-hover);
	transform: translateY(16px);
	opacity: 0;
	transition: transform 0.3s ease, opacity 0.3s ease;
}

.lm-upnext.is-visible {
	transform: translateY(0);
	opacity: 1;
}

.lm-upnext-label {
	margin: 0 0 4px;
	font-size: 0.75rem;
	font-weight: 700;
	letter-spacing: 0.09em;
	text-transform: uppercase;
	color: var(--lm-accent-ink);
}

.lm-upnext-link {
	display: block;
	text-decoration: none !important;
}

.lm-upnext-title {
	display: block;
	font-weight: 650;
	line-height: 1.4;
	color: var(--lm-ink);
	margin-bottom: 4px;
}

.lm-upnext-link:hover .lm-upnext-title {
	color: var(--lm-brand-ink);
}

.lm-upnext-close {
	position: absolute;
	top: 8px;
	right: 8px;
	width: 28px;
	height: 28px;
	border: none;
	border-radius: 999px;
	background: transparent;
	color: var(--lm-ink-faint);
	font-size: 1.1rem;
	cursor: pointer;
}

.lm-upnext-close:hover {
	background: var(--lm-surface-2);
	color: var(--lm-ink);
}

/* ---------- Archive ---------- */
.lm-section--archive-head {
	padding-bottom: 0;
}

.lm-archive-title {
	font-size: clamp(1.7rem, 4vw, 2.5rem);
	margin-bottom: 8px;
}

.lm-archive-desc {
	color: var(--lm-ink-soft);
	max-width: 640px;
}

/* ---------- Pagination ---------- */
.pagination,
.lm-main .navigation {
	margin-top: 34px;
}

.nav-links {
	display: flex;
	gap: 8px;
	flex-wrap: wrap;
	align-items: center;
}

.nav-links .page-numbers {
	display: inline-flex;
	align-items: center;
	min-height: 40px;
	padding: 6px 16px;
	border: 1px solid var(--lm-line);
	border-radius: 999px;
	font-size: 0.92rem;
	font-weight: 600;
	color: var(--lm-ink-soft);
	text-decoration: none !important;
}

.nav-links a.page-numbers:hover {
	border-color: var(--lm-brand);
	color: var(--lm-brand-ink);
}

.nav-links .page-numbers.current {
	background: var(--lm-brand);
	border-color: var(--lm-brand);
	color: #fff;
}

/* ---------- Comments ---------- */
.lm-comments {
	padding: 10px 0 50px;
}

.lm-comment-list {
	list-style: none;
	margin: 0 0 24px;
	padding: 0;
}

.lm-comment-list .comment-body {
	padding: 16px 0;
	border-bottom: 1px solid var(--lm-line);
}

.lm-comment-list .avatar {
	border-radius: 999px;
	margin-right: 10px;
	vertical-align: middle;
}

.lm-comment-list .children {
	list-style: none;
	padding-left: 28px;
}

.comment-form textarea,
.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"] {
	width: 100%;
	padding: 11px 14px;
	font: inherit;
	color: var(--lm-ink);
	background: var(--lm-surface);
	border: 1px solid var(--lm-line);
	border-radius: var(--lm-radius-sm);
}

.comment-form .submit {
	padding: 11px 22px;
	border: none;
	border-radius: 999px;
	font: inherit;
	font-weight: 650;
	color: #fff;
	background: var(--lm-brand);
	cursor: pointer;
}

/* ---------- Footer ---------- */
.lm-footer {
	margin-top: 30px;
	border-top: 1px solid var(--lm-line);
	background: var(--lm-surface);
	padding: 40px 0 26px;
}

.lm-footer-top {
	display: flex;
	justify-content: space-between;
	gap: 30px;
	flex-wrap: wrap;
	margin-bottom: 26px;
}

.lm-footer-tag {
	color: var(--lm-ink-faint);
	font-size: 0.92rem;
	margin: 8px 0 0;
}

.lm-footer-links {
	display: flex;
	gap: 6px 18px;
	flex-wrap: wrap;
	list-style: none;
	margin: 0;
	padding: 0;
}

.lm-footer-links a {
	color: var(--lm-ink-soft);
	font-size: 0.93rem;
}

.lm-footer-bottom {
	border-top: 1px solid var(--lm-line);
	padding-top: 18px;
	font-size: 0.85rem;
	color: var(--lm-ink-faint);
}

.lm-footer-bottom p {
	margin: 0;
}

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
	.lm-grid {
		grid-template-columns: repeat(2, 1fr);
	}

	.lm-popular-list {
		grid-template-columns: repeat(2, 1fr);
	}

	.lm-hero {
		grid-template-columns: 1fr;
	}
}

@media (max-width: 760px) {
	.lm-burger {
		display: inline-flex;
	}

	.lm-nav {
		display: none;
		position: absolute;
		top: 100%;
		left: 0;
		right: 0;
		background: var(--lm-bg);
		border-bottom: 1px solid var(--lm-line);
		box-shadow: var(--lm-card-shadow-hover);
		padding: 12px clamp(16px, 4vw, 28px) 18px;
	}

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

	.lm-nav-list {
		flex-direction: column;
		align-items: stretch;
	}

	.lm-nav-list a {
		display: block;
		padding: 11px 14px;
		font-size: 1.02rem;
	}

	.lm-nav-extras {
		display: block;
		margin-top: 10px;
	}

	.lm-newsletter--band {
		grid-template-columns: 1fr;
	}
}

@media (max-width: 560px) {
	.lm-grid,
	.lm-popular-list {
		grid-template-columns: 1fr;
	}

	.lm-upnext {
		right: 12px;
		bottom: 12px;
	}
}

@media (prefers-reduced-motion: reduce) {
	html {
		scroll-behavior: auto;
	}

	*,
	*::before,
	*::after {
		transition: none !important;
		animation: none !important;
	}
}
