﻿/*
Theme Name: DigestivaMente
Theme URI: https://digestivamente.com.ar/
Author: DigestivaMente
Description: Tema propio del Blog y Comunidad de DigestivaMente.
Version: 0.4.0
Text Domain: digestivamente
Requires at least: 7.1
Requires PHP: 8.4
*/

/* Scoped to the single template; other templates keep their existing styles. */
.dm-article {
	color: var(--wp--custom--article--ink);
}

.dm-article .dm-article-header .wp-block-post-title {
	margin-block: 0;
	text-wrap: pretty;
}

.dm-article .dm-article-meta {
	color: var(--wp--custom--article--muted);
}

/* Independent of contentSize, wideSize and post content alignments. */
.dm-article .dm-article-featured {
	max-width: min(100%, 720px);
	margin-block-start: clamp(2rem, 4vw, 3rem);
}

.dm-article .dm-article-featured img {
	display: block;
	width: 100%;
	height: auto;
	max-width: 100%;
	margin-inline: auto;
}

.dm-article .dm-article-content {
	box-sizing: border-box;
	margin-block-start: clamp(1.5rem, 3vw, 2.25rem);
	/* The full-width content wrapper keeps gutters and native wide alignments. */
	padding-inline: var(--wp--custom--article--gutter);
}

.dm-article .dm-article-content > * {
	margin-block-start: 1.25em;
}

.dm-article .dm-article-content :where(h2, h3, h4, h5, h6) {
	margin-block-start: 2em;
	margin-block-end: 0.65em;
	font-weight: 700;
	line-height: 1.3;
	text-wrap: pretty;
}

.dm-article .dm-article-content :where(h2) {
	font-size: 1.875rem;
	/* Preserve the previous 54px / 17.55px margins as the type grows. */
	margin-block-start: 3.375rem;
	margin-block-end: 1.096875rem;
}

.dm-article .dm-article-content :where(h2, h3) {
	font-family: var(--wp--preset--font-family--editorial);
	font-weight: 400;
}

.dm-article .dm-article-content :where(h3) {
	font-size: 1.5rem;
	/* Preserve the previous 45px / 14.625px margins as the type grows. */
	margin-block-start: 2.8125rem;
	margin-block-end: 0.9140625rem;
}

.dm-article .dm-article-content :where(h4, h5, h6) {
	font-size: 1.1em;
}

.dm-article .dm-article-content :where(h2, h3, h4, h5, h6) + * {
	margin-block-start: 0;
}

.dm-article .dm-article-content :where(a) {
	color: var(--wp--custom--article--link);
	overflow-wrap: anywhere;
	text-decoration: underline;
	text-decoration-thickness: 0.06em;
	text-underline-offset: 0.16em;
}

.dm-article :where(a:hover) {
	text-decoration-thickness: 0.1em;
}

.dm-article :where(a:focus-visible) {
	outline: 2px solid currentColor;
	outline-offset: 3px;
}

/* References can contain long URLs stored as plain paragraph or list text. */
.dm-article .dm-article-content :where(p, li) {
	overflow-wrap: break-word;
}

.dm-article .dm-article-content :where(ul, ol) {
	padding-inline-start: 1.4em;
}

.dm-article .dm-article-content :where(li + li) {
	margin-block-start: 0.4em;
}

.dm-article .dm-article-content :where(li > ul, li > ol) {
	margin-block-start: 0.4em;
}

.dm-article .dm-article-content :where(figcaption) {
	margin-block-start: 0.75rem;
	margin-block-end: 0;
	color: var(--wp--custom--article--muted);
	font-family: var(--wp--preset--font-family--system);
	font-size: 0.875rem;
	line-height: 1.5;
	overflow-wrap: anywhere;
}

/* FITT keeps its five-column structure, with scrolling inside the wide block. */
.dm-article .dm-article-content > .wp-block-table.dm-fitt-table {
	box-sizing: border-box;
	width: 100%;
	max-width: var(--wp--style--global--wide-size, 960px);
	margin-block: 2rem;
	overflow-x: auto;
	color: var(--wp--custom--article--ink);
	font-family: var(--wp--preset--font-family--system);
	font-size: 1rem;
	line-height: 1.5;
}

.dm-article .dm-article-content .dm-fitt-table > table {
	width: 100%;
	min-width: 56.25rem;
	border-collapse: collapse;
	text-align: left;
}

.dm-article .dm-article-content .dm-fitt-table :where(th, td) {
	padding: 0.875rem 1rem;
	border: 0;
	border-block-end: 1px solid #dce0da;
	vertical-align: top;
	font-weight: 400;
	overflow-wrap: normal;
	word-break: normal;
}

.dm-article .dm-article-content .dm-fitt-table thead {
	border: 0;
}

.dm-article .dm-article-content .dm-fitt-table thead th {
	background: var(--wp--custom--article--link);
	color: #fff;
	font-weight: 600;
}

.dm-article .dm-article-content .dm-fitt-table tr > :first-child {
	width: 20%;
}

.dm-article .dm-article-content .dm-fitt-table tr > :nth-child(2),
.dm-article .dm-article-content .dm-fitt-table tr > :last-child {
	width: 22%;
}

.dm-article .dm-article-content .dm-fitt-table:focus-visible {
	outline: 2px solid var(--wp--custom--article--link);
	outline-offset: 4px;
}

/* Sharing sits below the editorial metadata; the archive link stays at the end. */
.dm-article .dm-article-actions {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0 1.375rem;
	margin-block-start: 1.25rem;
	font-family: var(--wp--preset--font-family--system);
	font-size: 0.875rem;
	line-height: 1.4;
}

.dm-article-actions .dm-article-action {
	display: inline-flex;
	align-items: center;
	gap: 0.375rem;
	min-height: 44px;
	max-width: 100%;
	box-sizing: border-box;
	padding: 0.75rem 0;
	border: 0;
	border-radius: 0;
	background: none;
	box-shadow: none;
	color: var(--wp--custom--article--muted);
	font: inherit;
	text-align: left;
	white-space: nowrap;
	appearance: none;
	cursor: pointer;
}

.dm-article-action svg {
	flex-shrink: 0;
}

.dm-article-actions .dm-article-action:hover {
	color: var(--wp--custom--article--ink);
	text-decoration: underline;
	text-underline-offset: 0.16em;
}

.dm-article-actions button:focus-visible {
	outline: 2px solid var(--wp--custom--article--link);
	outline-offset: 3px;
}

.dm-article .dm-article-actions[hidden],
.dm-article-actions [hidden] {
	display: none !important;
}

.dm-article-copy-label {
	display: grid;
}

.dm-article-copy-label > span {
	grid-area: 1 / 1;
}

.dm-article-copy-reserve {
	visibility: hidden;
}

.dm-article-copy-check,
.dm-article-copy[data-copy-state="success"] .dm-article-copy-icon {
	display: none;
}

.dm-article-copy[data-copy-state="success"] .dm-article-copy-check {
	display: inline;
}

.dm-article-actions-status {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip-path: inset(50%);
	white-space: nowrap;
	border: 0;
}

.dm-article .dm-article-return {
	margin-block-start: 3rem;
	padding-block-start: 1.5rem;
	border-block-start: 1px solid #dce0da;
	font-size: 1rem;
}

.dm-article-return .dm-article-back {
	display: inline-flex;
	align-items: center;
	min-height: 44px;
	color: var(--wp--custom--article--link);
	text-decoration: underline;
	text-underline-offset: 0.16em;
	overflow-wrap: anywhere;
}

/* Native comments stay within the article's existing reading width. */
.dm-article .dm-comments {
	margin-block-start: 3rem;
	padding-block-start: 2rem;
	border-block-start: 1px solid #dce0da;
	font-size: 1rem;
	line-height: 1.6;
}

.dm-comments :where(h2, h3) {
	font-family: var(--wp--preset--font-family--editorial);
	font-weight: 400;
	line-height: 1.3;
}

.dm-comments h2 {
	font-size: 1.875rem;
}

.dm-comments h3 {
	font-size: 1.5rem;
}

.dm-comments .wp-block-comment-template {
	margin-block: 1.5rem;
	padding: 0;
	list-style: none;
}

.dm-comments .wp-block-comment-template > li,
.dm-comments .wp-block-comment-template ol > li {
	margin-block: 0;
	padding-block: 1.25rem;
	border-block-start: 1px solid #dce0da;
}

.dm-comments .wp-block-comment-template ol {
	margin-inline-start: clamp(0.75rem, 3vw, 1.5rem);
	padding: 0;
	list-style: none;
}

.dm-comments .dm-comment-meta {
	gap: 0.25rem 1rem;
	color: var(--wp--custom--article--muted);
	font-size: 0.875rem;
}

.dm-comments .wp-block-comment-author-name {
	font-weight: 600;
}

.dm-comments :where(.wp-block-comment-content, .dm-comment-guidance, .dm-comment-data) {
	overflow-wrap: anywhere;
}

.dm-comments :where(.dm-comment-guidance, .dm-comment-data, .comment-notes, .logged-in-as) {
	font-size: 0.875rem;
}

.dm-comments :where(.dm-comment-data, .comment-notes, .logged-in-as) {
	color: var(--wp--custom--article--muted);
}

.dm-comments :where(.comment-respond, form) {
	max-width: 100%;
	min-width: 0;
}

.dm-comments form > p {
	margin-block: 0 1rem;
}

.dm-comments label {
	display: block;
	margin-block-end: 0.375rem;
}

.dm-comments :where(input[type="text"], input[type="email"], textarea) {
	box-sizing: border-box;
	width: 100%;
	max-width: 100%;
	min-height: 44px;
	padding: 0.625rem;
	border: 1px solid var(--wp--custom--article--muted);
	border-radius: 2px;
	background: #fff;
	color: var(--wp--custom--article--ink);
	font: inherit;
}

.dm-comments textarea {
	min-height: 9rem;
	resize: vertical;
}

.dm-comments a {
	color: var(--wp--custom--article--link);
	text-decoration: underline;
	text-underline-offset: 0.16em;
	overflow-wrap: anywhere;
}

.dm-comments :where(.comment-reply-link, #cancel-comment-reply-link, .wp-block-comments-pagination a) {
	display: inline-flex;
	align-items: center;
	min-height: 44px;
	max-width: 100%;
	font-family: var(--wp--preset--font-family--system);
	font-size: 0.875rem;
}

.dm-comments .form-submit .submit {
	box-sizing: border-box;
	min-height: 44px;
	max-width: 100%;
	padding: 0.625rem 1rem;
	border: 1px solid var(--wp--custom--article--link);
	border-radius: 2px;
	background: transparent;
	color: var(--wp--custom--article--link);
	font: inherit;
	cursor: pointer;
}

.dm-comments .form-submit .submit:hover {
	border-color: var(--wp--custom--article--ink);
	color: var(--wp--custom--article--ink);
}

.dm-comments :where(a, input, textarea, button):focus-visible {
	outline: 2px solid var(--wp--custom--article--link);
	outline-offset: 3px;
}

/* Home editorial canvas and components; isolated from single article styles. */
.dm-home {
	box-sizing: content-box;
	width: calc(100% - 2 * var(--wp--custom--article--gutter));
	max-width: var(--wp--style--global--wide-size, 960px);
	margin-inline: auto;
	padding-block: clamp(1.5rem, 3vw, 2.5rem) clamp(3rem, 6vw, 4rem);
	color: var(--wp--custom--article--ink);
	font-family: var(--wp--preset--font-family--system);
	font-size: var(--wp--preset--font-size--article-body);
	line-height: 1.6;
}

.dm-home .dm-home-masthead {
	margin-block: 0 1.5rem;
	padding-block-end: 1.5rem;
}

.dm-home .dm-home-welcome-copy {
	min-width: 0;
	max-width: 46rem;
	margin: 0;
}

.dm-home .dm-home-title {
	margin: 0;
	font-family: var(--wp--preset--font-family--editorial);
	font-size: clamp(1.875rem, 1.5rem + 1vw, 2.25rem);
	font-weight: 400;
	line-height: 1.2;
	text-wrap: pretty;
}

.dm-home .dm-home-intro {
	margin-block: 0.75rem 0;
	font-size: inherit;
	line-height: 1.6;
}

.dm-home .dm-home-project-link {
	margin-block: 0.875rem 0;
	font-size: 1rem;
}

.dm-home .dm-home-project-link a {
	display: inline-flex;
	align-items: center;
	gap: 0.375em;
	/* Extend the touch area into existing whitespace without shifting the copy. */
	padding-block: 0.625rem;
	margin-block: -0.625rem;
	color: #365b49;
	font-weight: 500;
	text-decoration: none;
}

.dm-home .dm-home-project-link a:is(:hover, :focus) {
	text-decoration: underline;
	text-decoration-thickness: 1px;
}

.dm-home .dm-home-project-arrow {
	font-size: 0.875em;
}

.dm-editorial-motif {
	display: block;
	width: 108px;
	height: 28px;
	flex: 0 0 108px;
	margin: 0;
}

.dm-home .wp-block-post-title {
	font-family: var(--wp--preset--font-family--editorial);
	font-weight: 400;
	text-align: left;
	text-wrap: pretty;
	word-break: normal;
	overflow-wrap: break-word;
}

.dm-home .dm-home-lead-query,
.dm-home .dm-home-secondary-query,
.dm-home .wp-block-post-template {
	margin: 0;
	padding: 0;
}

.dm-home .dm-home-featured {
	box-sizing: border-box;
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 1.5rem;
	margin: 0;
	padding: clamp(1rem, 3vw, 2.25rem);
	/* Fallback is editorial green mixed with 92% white, rounded to sRGB. */
	background: #eff2f0;
	background: color-mix(in srgb, var(--wp--custom--article--link) 8%, white);
}

.dm-home .dm-home-featured-text {
	flex: 1 1 0%;
	min-width: 0;
	width: 100%;
}

.dm-home .dm-home-featured-text > * {
	margin-block: 0;
}

.dm-home .dm-home-featured-text > * + * {
	margin-block-start: 0.875rem;
}

.dm-home .dm-home-kicker {
	color: var(--wp--custom--article--link);
	font-size: var(--wp--preset--font-size--article-meta);
	font-weight: 600;
	line-height: 1.5;
}

.dm-home .dm-home-featured-title {
	font-size: var(--wp--preset--font-size--article-title);
	line-height: 1.15;
}

.dm-home .dm-home-featured-image {
	flex: 0 1 auto;
	width: 100%;
	max-width: 24rem;
	margin: 0;
}

.dm-home .dm-home-featured-image img {
	display: block;
	width: 100%;
	max-width: 100%;
	height: auto;
}

.dm-home .dm-home-meta {
	gap: 0.25rem 0.5rem;
	color: var(--wp--custom--article--muted);
	font-size: var(--wp--preset--font-size--article-meta);
	line-height: 1.5;
}

.dm-home .dm-home-meta > * {
	min-width: 0;
	margin: 0;
}

.dm-home .dm-home-meta .wp-block-post-author-name::before {
	content: "\00b7";
	margin-inline-end: 0.5rem;
}

.dm-home .dm-home-recent {
	margin-block-start: clamp(2rem, 5vw, 3rem);
}

.dm-home .dm-home-recent-titlebar {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1rem;
	margin-block: 0;
	padding-block-end: 0.875rem;
	border-block-end: 1px solid var(--wp--custom--article--link);
}

.dm-home .dm-home-recent-heading {
	min-width: 0;
	margin: 0;
	color: var(--wp--custom--article--link);
	font-family: var(--wp--preset--font-family--system);
	font-size: var(--wp--preset--font-size--article-body);
	font-weight: 600;
	line-height: 1.4;
	overflow-wrap: break-word;
}

.dm-home .dm-home-row {
	margin: 0;
	padding-block: 1.5rem;
	border-block-end: 1px solid #d3dbd7;
	border-block-end-color: color-mix(in srgb, var(--wp--custom--article--link) 22%, white);
}

.dm-home .dm-home-secondary-title {
	margin-block: 0 0.65rem;
	font-size: 1.5rem;
	line-height: 1.3;
}

.dm-home .dm-home-secondary-query .wp-block-post + .wp-block-post {
	margin-block-start: 0;
}

.dm-home a {
	color: inherit;
	text-decoration: underline;
	text-decoration-color: var(--wp--custom--article--link);
	text-decoration-thickness: 1px;
	text-underline-offset: 0.2em;
	text-decoration-skip-ink: auto;
}

.dm-home a:hover {
	color: var(--wp--custom--article--link);
	text-decoration-thickness: 2px;
}

.dm-home .wp-block-post-title a {
	max-width: 100%;
}

.dm-home :is(.dm-home-featured-title, .dm-home-secondary-title) a {
	text-decoration: none;
}

.dm-home :is(.dm-home-featured-title, .dm-home-secondary-title) a:hover {
	text-decoration: underline;
	text-decoration-thickness: 1px;
}

.dm-home a:focus-visible {
	outline: 2px solid var(--wp--custom--article--link);
	outline-offset: 4px;
}

@media (max-width: 22.5rem) {
	.dm-home .dm-home-featured-title {
		font-size: calc(var(--wp--preset--font-size--article-title) * 0.9375);
	}
}

@media (min-width: 56rem) {
	.dm-home .dm-home-featured {
		flex-direction: row;
		align-items: center;
		gap: 2rem;
	}

	.dm-home .dm-home-featured-image {
		flex: 0 1 36%;
	}
}

/* Native posts index; isolated from Home and single article styles. */
.dm-posts-index {
	box-sizing: content-box;
	width: calc(100% - 2 * var(--wp--custom--article--gutter));
	max-width: var(--wp--style--global--wide-size, 960px);
	margin-inline: auto;
	padding-block: clamp(1.5rem, 3vw, 2.5rem) clamp(3rem, 6vw, 4rem);
	color: var(--wp--custom--article--ink);
	font-family: var(--wp--preset--font-family--system);
	font-size: var(--wp--preset--font-size--article-body);
	line-height: 1.6;
}

.dm-posts-index .dm-posts-index-header {
	margin-block: 0 1rem;
}

.dm-posts-index .dm-posts-index-header > h1 {
	margin: 0;
	font-family: var(--wp--preset--font-family--editorial);
	font-size: var(--wp--preset--font-size--article-title);
	font-weight: 400;
	line-height: 1.2;
}

.dm-posts-index .dm-posts-index-header > p {
	max-width: 46rem;
	margin-block: 0.75rem 0;
}

/* Native search form, shared by the posts index and search results. */
.dm-posts-index .dm-article-search {
	max-width: 27.5rem;
	margin-block: 0.875rem 0.5rem;
}

.dm-posts-index .dm-article-search .wp-block-search__label {
	display: block;
	margin-block-end: 0.25rem;
	color: var(--wp--custom--article--muted);
	font-size: var(--wp--preset--font-size--article-meta);
	font-weight: 400;
}

.dm-posts-index .dm-article-search .wp-block-search__inside-wrapper {
	flex-wrap: wrap;
	gap: 0.375rem;
}

.dm-posts-index .dm-article-search :is(input, button) {
	box-sizing: border-box;
	min-height: 44px;
	border-radius: 3px;
	padding: 0.5rem 0.625rem;
	font: inherit;
	font-size: 1rem;
}

.dm-posts-index .dm-article-search .wp-block-search__input {
	flex: 1 1 12rem;
	min-width: 0;
	border: 1px solid #d3dbd7;
	color: var(--wp--custom--article--ink);
	background: #fff;
}

.dm-posts-index .dm-article-search .wp-block-search__button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex: 0 0 auto;
	gap: 0.375rem;
	margin: 0;
	border: 0;
	padding-inline: 0.375rem;
	color: var(--wp--custom--article--link);
	background: transparent;
	font-size: var(--wp--preset--font-size--article-meta);
	cursor: pointer;
}

.dm-posts-index .dm-article-search .wp-block-search__button::before {
	content: "";
	flex: 0 0 1rem;
	width: 1rem;
	height: 1rem;
	background: currentColor;
	mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Ccircle cx='10.5' cy='10.5' r='6.5' fill='none' stroke='black' stroke-width='1.5'/%3E%3Cpath d='m15.5 15.5 4.5 4.5' stroke='black' stroke-width='1.5'/%3E%3C/svg%3E") center / contain no-repeat;
}

.dm-posts-index .dm-article-search .wp-block-search__button:hover {
	text-decoration: underline;
	text-underline-offset: 0.2em;
}

.dm-posts-index .dm-article-search :is(input, button):focus-visible {
	outline: 2px solid var(--wp--custom--article--link);
	outline-offset: 3px;
}

.dm-search-results .wp-block-query-title {
	overflow-wrap: anywhere;
}

/* Reuse the configured posts-index link without changing its Home presentation. */
.dm-search-results .dm-home-articles-link {
	margin-block: 0.25rem 0.5rem;
	font-size: var(--wp--preset--font-size--article-meta);
}

.dm-search-results .dm-home-articles-link a {
	display: inline-flex;
	align-items: center;
	gap: 0.375em;
	min-height: 44px;
	text-decoration: none;
}

.dm-search-results .dm-home-articles-link a::before {
	content: "\2190";
}

.dm-search-results .dm-home-articles-link [aria-hidden="true"] {
	display: none;
}

.dm-posts-index .dm-posts-index-query,
.dm-posts-index .wp-block-post-template {
	margin: 0;
	padding: 0;
}

.dm-posts-index .dm-posts-index-entry {
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	align-items: start;
	gap: 0.75rem;
	margin: 0;
	padding-block: 2rem;
	border-block-end: 1px solid #d3dbd7;
}

.dm-posts-index .wp-block-post + .wp-block-post {
	margin-block-start: 0;
}

.dm-posts-index .dm-posts-index-entry > *,
.dm-posts-index .wp-block-post-excerpt__excerpt {
	margin: 0;
}

.dm-posts-index .wp-block-post-title {
	font-family: var(--wp--preset--font-family--editorial);
	font-size: clamp(1.5rem, 1.25rem + 0.6vw, 1.875rem);
	font-weight: 400;
	line-height: 1.3;
	text-wrap: pretty;
	overflow-wrap: break-word;
}

.dm-posts-index .wp-block-post-date {
	color: var(--wp--custom--article--muted);
	font-size: var(--wp--preset--font-size--article-meta);
}

.dm-posts-index .dm-posts-index-image {
	width: 100%;
	max-width: 20rem;
	margin: 0;
}

.dm-posts-index .dm-posts-index-image img {
	display: block;
	width: 100%;
	height: auto;
}

.dm-posts-index a {
	color: var(--wp--custom--article--link);
	text-underline-offset: 0.2em;
}

.dm-posts-index .wp-block-post-title a {
	color: inherit;
	text-decoration: none;
}

.dm-posts-index a:hover {
	text-decoration: underline;
}

.dm-posts-index a:focus-visible {
	outline: 2px solid var(--wp--custom--article--link);
	outline-offset: 4px;
}

.dm-posts-index .wp-block-read-more,
.dm-posts-index .dm-posts-index-pagination :is(a, .page-numbers) {
	box-sizing: border-box;
	display: inline-flex;
	align-items: center;
	min-height: 44px;
}

.dm-posts-index .wp-block-read-more {
	justify-self: start;
}

.dm-posts-index .dm-posts-index-pagination {
	gap: 0.5rem 1rem;
	margin-block-start: 2rem;
	font-size: 1rem;
}

.dm-posts-index .wp-block-query-pagination-numbers {
	display: flex;
	flex-wrap: wrap;
	gap: 0.25rem;
	margin: 0;
}

.dm-posts-index .dm-posts-index-pagination .page-numbers {
	justify-content: center;
	min-width: 44px;
}

.dm-posts-index .dm-posts-index-pagination [aria-current="page"] {
	font-weight: 600;
	text-decoration: underline;
	text-underline-offset: 0.3em;
}

.dm-home .dm-home-articles-link {
	margin-block: 1.25rem 0;
	font-size: 1rem;
}

.dm-home .dm-home-articles-link a {
	display: inline-flex;
	align-items: center;
	gap: 0.375em;
	padding-block: 0.625rem;
	margin-block: -0.625rem;
	color: var(--wp--custom--article--link);
	font-weight: 500;
	text-decoration: none;
}

.dm-home .dm-home-articles-link a:visited {
	color: var(--wp--custom--article--link);
}

.dm-home .dm-home-articles-link a:is(:hover, :focus-visible) {
	text-decoration: underline;
	text-decoration-thickness: 1px;
}

@media (min-width: 56rem) {
	.dm-posts-index .dm-posts-index-entry:has(> .dm-posts-index-image) {
		grid-template-columns: minmax(0, 1fr) 14rem;
		column-gap: 2rem;
	}

	.dm-posts-index .dm-posts-index-entry > :not(.dm-posts-index-image) {
		grid-column: 1;
	}

	.dm-posts-index .dm-posts-index-image {
		grid-column: 2;
		grid-row: 1 / span 4;
	}
}

/* Shared identity; the editorial main content keeps its existing rules. */
.dm-site-header,
.dm-site-footer {
	--dm-cream: #fdfae7;
	box-sizing: border-box;
	margin-block: 0;
	color: var(--wp--custom--article--ink);
	font-family: var(--wp--preset--font-family--system);
	font-size: 1rem;
	line-height: 1.4;
}

.dm-site-header {
	border-block-end: 1px solid #dce5df;
	background: #fff;
}

.dm-header-inner,
.dm-footer-inner {
	box-sizing: border-box;
	width: calc(100% - 2rem);
	max-width: var(--wp--style--global--wide-size, 960px);
	margin-inline: auto;
}

.dm-header-inner {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 0.25rem 1.5rem;
	padding-block: 0.625rem;
}

.dm-header-inner > *,
.dm-footer-inner > * {
	margin-block: 0;
}

.dm-site-brand {
	display: inline-flex;
	flex: 0 0 auto;
	align-items: center;
	gap: 0.75rem;
	min-height: 44px;
	color: var(--wp--custom--article--link);
	text-decoration: none;
}

.dm-site-brand picture {
	display: flex;
	align-items: center;
	justify-content: center;
	min-width: 38px;
}

.dm-site-brand img {
	display: block;
	width: 180px;
	height: auto;
	aspect-ratio: 592 / 137;
	object-fit: contain;
}

.dm-site-brand-name {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	overflow: hidden;
	clip-path: inset(50%);
	white-space: nowrap;
}

.dm-site-nav {
	color: var(--wp--custom--article--link);
	font-size: 1rem;
}

.dm-site-nav .wp-block-navigation__container {
	flex-wrap: wrap;
	gap: 0;
}

.dm-site-nav :is(.wp-block-navigation__responsive-container-open, .wp-block-navigation__responsive-container-close) {
	box-sizing: border-box;
	min-width: 44px;
	min-height: 44px;
	padding: 10px;
}

/* Match Navigation's native mobile breakpoint; desktop keeps its existing rules. */
@media (max-width: 599px) {
	.dm-header-inner {
		flex-wrap: nowrap;
	}

	.dm-site-nav {
		flex: 0 0 auto;
	}
}

/* Keep the open mobile panel inset and leave room for its native close button. */
@media (max-width: 599px) {
	.dm-site-nav .wp-block-navigation__responsive-container.is-menu-open {
		box-sizing: border-box;
		padding: 24px;
	}

	.dm-site-nav .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__responsive-container-content {
		padding-top: 64px;
	}

	.dm-site-nav .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__container {
		align-items: flex-start;
		gap: 8px;
	}

	.dm-site-nav .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation-item__content {
		min-width: 44px;
	}

	.dm-site-nav .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__responsive-container-close {
		color: var(--wp--custom--article--link);
	}
}

.dm-site-nav .wp-block-navigation-item__content,
.dm-site-footer a {
	box-sizing: border-box;
	display: inline-flex;
	align-items: center;
	min-height: 44px;
	padding: 0.5rem;
	color: var(--wp--custom--article--link);
	line-height: 1.4;
	text-decoration: none;
	text-underline-offset: 0.3em;
}

.dm-site-nav a:hover,
.dm-site-footer a:hover,
.dm-site-footer .dm-footer-external .wp-social-link a:hover {
	text-decoration: underline;
	text-decoration-thickness: 1px;
}

.dm-site-nav a[aria-current="page"] {
	font-weight: 600;
	text-decoration: underline;
	text-decoration-thickness: 2px;
}

.dm-site-header a:focus-visible,
.dm-site-nav :is(.wp-block-navigation__responsive-container-open, .wp-block-navigation__responsive-container-close):focus-visible,
.dm-site-footer a:focus-visible {
	outline: 2px solid var(--wp--custom--article--link);
	outline-offset: 3px;
	border-radius: 2px;
}

.dm-site-footer {
	border-block-start: 1px solid #dce5df;
	background: var(--dm-cream);
}

.dm-footer-inner {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-start;
	justify-content: space-between;
	gap: 1.5rem 3rem;
	padding-block: 2rem;
}

.dm-footer-identity > * {
	margin-block: 0;
}

.dm-footer-label {
	color: var(--wp--custom--article--link);
	font-family: var(--wp--preset--font-family--editorial);
	font-size: 1.375rem;
	font-weight: 400;
}

.dm-site-footer a {
	padding-inline: 0;
}

.dm-site-footer .dm-footer-external {
	gap: 0;
	padding: 0;
	font-size: 1rem;
}

.dm-footer-external .wp-social-link {
	color: var(--wp--custom--article--link);
	transition: none;
}

.dm-footer-external .wp-social-link:hover {
	transform: none;
}

.dm-footer-external .wp-social-link svg {
	flex-shrink: 0;
	width: 1.25rem;
	height: 1.25rem;
}

.dm-site-footer .dm-footer-external .wp-social-link .wp-block-social-link-label {
	margin-inline: 0.5rem 0;
	font-size: inherit;
}

@media (min-width: 56rem) {
	.dm-header-inner {
		gap: 1rem 1.5rem;
		padding-block: 1rem;
	}

	.dm-site-brand img {
		width: 300px;
		height: auto;
		aspect-ratio: 592 / 137;
	}

	.dm-footer-inner {
		padding-block: 2.5rem;
	}
}
