/**
 * Premium styles for /contactanos/ (custom .dmary-contact markup)
 */

.page-id-630 .entry-header .page-title {
	position: absolute;
	width: 1px;
	height: 1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
}

.dmary-contact {
	--dn-ink: #1f1c1a;
	--dn-muted: #6a645c;
	--dn-line: rgba(31, 28, 26, 0.1);
	--dn-sand: #f6f3ee;
	--dn-cream: #faf8f5;
	--dn-sage: #5c6b5a;
	--dn-teal: #1a9ea3;
	--dn-navy: #163a5f;
	--dn-ease: cubic-bezier(0.22, 1, 0.36, 1);
	color: var(--dn-ink);
	font-size: 1.05rem;
	line-height: 1.7;
}

.dmary-contact *,
.dmary-contact *::before,
.dmary-contact *::after {
	box-sizing: border-box;
}

.dmary-contact .dmary-container {
	width: min(100% - 2.5rem, 1080px);
	margin-inline: auto;
}

.dmary-contact section {
	padding-block: clamp(3.25rem, 6.5vw, 5.5rem);
}

.dmary-contact h1,
.dmary-contact h2,
.dmary-contact h3 {
	font-family: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, serif;
	font-weight: 600;
	letter-spacing: -0.02em;
	line-height: 1.15;
	color: var(--dn-ink);
	margin: 0 0 1rem;
}

.dmary-contact h1 {
	font-size: clamp(2rem, 4.2vw, 3rem);
}

.dmary-contact h2 {
	font-size: clamp(1.55rem, 2.8vw, 2.2rem);
	max-width: 18ch;
}

.dmary-contact h3 {
	font-size: 1.25rem;
	margin-bottom: 0.6rem;
}

.dmary-contact p {
	margin: 0 0 1rem;
	color: var(--dn-muted);
	max-width: 58ch;
}

.dmary-contact .dmary-section-intro {
	margin-bottom: 2rem;
	font-size: 1.06rem;
}

/* ------------------------------------------------------------------
   Hero
------------------------------------------------------------------ */
.dmary-contact-hero {
	position: relative;
	isolation: isolate;
	padding-block: clamp(4rem, 9vw, 6.5rem) !important;
	background:
		linear-gradient(110deg, rgba(22, 30, 28, 0.8) 0%, rgba(22, 58, 95, 0.55) 55%, rgba(26, 158, 163, 0.35) 100%),
		url("../images/nosotros/nosotros-hogar.jpg") center / cover no-repeat;
	color: #fff;
	overflow: hidden;
}

.dmary-contact-hero h1,
.dmary-contact-hero p {
	color: #fff;
	position: relative;
	z-index: 1;
}

.dmary-contact-hero p {
	color: rgba(255, 255, 255, 0.9);
	font-size: clamp(1.05rem, 1.4vw, 1.15rem);
	max-width: 36rem;
}

.dmary-contact-hero::after {
	content: "";
	position: absolute;
	inset: auto 0 0;
	height: 3.5rem;
	background: linear-gradient(to top, var(--dn-cream), transparent);
	pointer-events: none;
}

/* ------------------------------------------------------------------
   Contact option cards
------------------------------------------------------------------ */
.dmary-contact-options {
	background: var(--dn-cream);
}

.dmary-contact-grid {
	display: grid;
	grid-template-columns: 1fr;
	gap: 1.15rem;
}

@media (min-width: 800px) {
	.dmary-contact-grid {
		grid-template-columns: repeat(3, 1fr);
		gap: 1.25rem;
		align-items: stretch;
	}
}

.dmary-contact-card {
	display: flex;
	flex-direction: column;
	padding: 1.6rem 1.35rem 1.5rem;
	background: #fff;
	border-top: 2px solid var(--dn-teal);
	box-shadow: 0 10px 28px rgba(31, 28, 26, 0.05);
	transition: transform 0.35s var(--dn-ease), box-shadow 0.35s var(--dn-ease);
}

.dmary-contact-card:hover {
	transform: translateY(-4px);
	box-shadow: 0 18px 40px rgba(31, 28, 26, 0.09);
}

.dmary-contact-icon {
	position: relative;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 3rem;
	height: 3rem;
	margin-bottom: 1.1rem;
	border-radius: 999px;
	background: var(--dn-sand);
	color: var(--dn-navy);
	border: 1px solid rgba(22, 58, 95, 0.08);
}

/* Hide emoji placeholders from the HTML */
.dmary-contact-icon span {
	position: absolute;
	width: 1px;
	height: 1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
}

.dmary-contact-icon::before {
	content: "";
	display: block;
	width: 1.35rem;
	height: 1.35rem;
	background-color: currentColor;
	-webkit-mask-repeat: no-repeat;
	mask-repeat: no-repeat;
	-webkit-mask-position: center;
	mask-position: center;
	-webkit-mask-size: contain;
	mask-size: contain;
}

/* WhatsApp / mensaje */
.dmary-contact-card:nth-child(1) .dmary-contact-icon {
	color: var(--dn-teal);
}

.dmary-contact-card:nth-child(1) .dmary-contact-icon::before {
	-webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.75' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M21 11.5a8.4 8.4 0 0 1-.9 3.8 8.5 8.5 0 0 1-7.6 4.7 8.4 8.4 0 0 1-3.8-.9L3 21l1.9-5.7a8.4 8.4 0 0 1-.9-3.8 8.5 8.5 0 0 1 4.7-7.6 8.4 8.4 0 0 1 3.8-.9h.5a8.5 8.5 0 0 1 8 8v.5z'/%3E%3C/svg%3E");
	mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.75' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M21 11.5a8.4 8.4 0 0 1-.9 3.8 8.5 8.5 0 0 1-7.6 4.7 8.4 8.4 0 0 1-3.8-.9L3 21l1.9-5.7a8.4 8.4 0 0 1-.9-3.8 8.5 8.5 0 0 1 4.7-7.6 8.4 8.4 0 0 1 3.8-.9h.5a8.5 8.5 0 0 1 8 8v.5z'/%3E%3C/svg%3E");
}

/* Correo */
.dmary-contact-card:nth-child(2) .dmary-contact-icon::before {
	-webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.75' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='5' width='18' height='14' rx='2'/%3E%3Cpath d='m3 7 9 7 9-7'/%3E%3C/svg%3E");
	mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.75' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='5' width='18' height='14' rx='2'/%3E%3Cpath d='m3 7 9 7 9-7'/%3E%3C/svg%3E");
}

/* Horario */
.dmary-contact-card:nth-child(3) .dmary-contact-icon::before {
	-webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.75' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='9'/%3E%3Cpath d='M12 7v5l3.5 2'/%3E%3C/svg%3E");
	mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.75' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='9'/%3E%3Cpath d='M12 7v5l3.5 2'/%3E%3C/svg%3E");
}

.dmary-contact-card p {
	flex: 1;
	margin-bottom: 1.35rem;
	font-size: 0.98rem;
}

.dmary-contact-card strong {
	display: block;
	margin-top: auto;
	color: var(--dn-ink);
	font-weight: 650;
	letter-spacing: 0.01em;
	line-height: 1.45;
}

.dmary-contact-button,
.dmary-button,
.dmary-button-secondary {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	align-self: flex-start;
	min-height: 2.75rem;
	padding: 0.7rem 1.25rem;
	border-radius: 3px;
	font-weight: 600;
	letter-spacing: 0.03em;
	text-decoration: none !important;
	transition: transform 0.25s var(--dn-ease), background 0.25s var(--dn-ease),
		color 0.25s var(--dn-ease), box-shadow 0.25s var(--dn-ease), border-color 0.25s var(--dn-ease);
}

.dmary-contact-button,
.dmary-button {
	background: var(--dn-navy);
	color: #fff !important;
}

.dmary-contact-button:hover,
.dmary-button:hover {
	background: var(--dn-teal);
	transform: translateY(-2px);
	box-shadow: 0 12px 26px rgba(22, 58, 95, 0.16);
	color: #fff !important;
}

.dmary-button-secondary {
	background: transparent;
	color: var(--dn-navy) !important;
	border: 1px solid rgba(22, 58, 95, 0.28);
}

.dmary-button-secondary:hover {
	background: var(--dn-navy);
	color: #fff !important;
	border-color: var(--dn-navy);
	transform: translateY(-2px);
}

/* ------------------------------------------------------------------
   Form section
------------------------------------------------------------------ */
.dmary-contact-form-section {
	background: #fff;
}

.dmary-contact-form-wrapper {
	display: grid;
	gap: 2.25rem;
}

@media (min-width: 900px) {
	.dmary-contact-form-wrapper {
		grid-template-columns: 0.9fr 1.1fr;
		gap: 3rem;
		align-items: start;
	}
}

.dmary-contact-form-text h2 {
	max-width: 14ch;
}

.dmary-contact-form {
	padding: 1.5rem 1.35rem 1.6rem;
	background: var(--dn-cream);
	border: 1px solid var(--dn-line);
}

@media (min-width: 700px) {
	.dmary-contact-form {
		padding: 1.85rem 1.75rem 2rem;
	}
}

.dmary-contact-form form {
	display: flex;
	flex-direction: column;
	gap: 1rem;
	margin: 0;
}

.dmary-form-row {
	display: grid;
	gap: 1rem;
}

@media (min-width: 640px) {
	.dmary-form-row {
		grid-template-columns: 1fr 1fr;
	}
}

.dmary-form-field {
	display: flex;
	flex-direction: column;
	gap: 0.4rem;
}

.dmary-form-field label {
	font-size: 0.92rem;
	font-weight: 600;
	color: var(--dn-ink);
	letter-spacing: 0.01em;
}

.dmary-form-field label span {
	font-weight: 450;
	color: var(--dn-muted);
}

.dmary-form-field input,
.dmary-form-field select,
.dmary-form-field textarea {
	width: 100%;
	min-height: 2.85rem;
	padding: 0.7rem 0.85rem;
	border: 1px solid rgba(31, 28, 26, 0.14);
	border-radius: 3px;
	background: #fff;
	color: var(--dn-ink);
	font: inherit;
	transition: border-color 0.2s var(--dn-ease), box-shadow 0.2s var(--dn-ease);
}

.dmary-form-field textarea {
	min-height: 9rem;
	resize: vertical;
}

.dmary-form-field input:focus,
.dmary-form-field select:focus,
.dmary-form-field textarea:focus {
	outline: none;
	border-color: var(--dn-teal);
	box-shadow: 0 0 0 3px rgba(26, 158, 163, 0.16);
}

.dmary-form-field input::placeholder,
.dmary-form-field textarea::placeholder {
	color: #9a948c;
}

.dmary-form-submit {
	margin-top: 0.35rem;
}

.dmary-contact-form button[type="submit"],
.dmary-contact-form .dmary-button,
.dmary-contact-form .wpcf7-submit,
.dmary-contact-form .wpforms-submit {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	align-self: flex-start;
	min-height: 3rem;
	padding: 0.8rem 1.5rem;
	border: 0;
	border-radius: 3px;
	background: var(--dn-navy);
	color: #fff !important;
	font: inherit;
	font-weight: 600;
	letter-spacing: 0.04em;
	cursor: pointer;
	text-decoration: none !important;
	transition: transform 0.25s var(--dn-ease), background 0.25s var(--dn-ease), box-shadow 0.25s var(--dn-ease);
}

.dmary-contact-form button[type="submit"]:hover,
.dmary-contact-form .dmary-button:hover,
.dmary-contact-form .wpcf7-submit:hover,
.dmary-contact-form .wpforms-submit:hover {
	background: var(--dn-teal);
	transform: translateY(-2px);
	box-shadow: 0 12px 26px rgba(22, 58, 95, 0.16);
	color: #fff !important;
}

/* WPForms / CF7 inside wrapper */
.dmary-contact-form .wpforms-field,
.dmary-contact-form .wpcf7-form-control-wrap {
	margin-bottom: 0.85rem;
}

.dmary-contact-form .wpforms-field input,
.dmary-contact-form .wpforms-field select,
.dmary-contact-form .wpforms-field textarea,
.dmary-contact-form .wpcf7-form-control {
	width: 100%;
	border: 1px solid rgba(31, 28, 26, 0.14);
	border-radius: 3px;
	background: #fff;
	min-height: 2.85rem;
	padding: 0.7rem 0.85rem;
}

/* ------------------------------------------------------------------
   FAQ teaser
------------------------------------------------------------------ */
.dmary-contact-faq {
	background: var(--dn-sand);
	text-align: center;
}

.dmary-contact-faq h2,
.dmary-contact-faq p {
	margin-inline: auto;
}

.dmary-contact-faq p {
	margin-bottom: 1.5rem;
}

/* ------------------------------------------------------------------
   Final message
------------------------------------------------------------------ */
.dmary-contact-final {
	position: relative;
	isolation: isolate;
	text-align: center;
	padding-block: clamp(3.75rem, 8vw, 5.75rem) !important;
	background:
		linear-gradient(rgba(22, 58, 95, 0.78), rgba(26, 158, 163, 0.55)),
		url("../images/nosotros/nosotros-blancos.jpg") center / cover no-repeat;
	color: #fff;
}

.dmary-contact-final h2,
.dmary-contact-final p,
.dmary-contact-final strong {
	color: #fff;
	margin-inline: auto;
}

.dmary-contact-final h2 {
	max-width: 16ch;
	font-size: clamp(1.7rem, 3.4vw, 2.4rem);
}

.dmary-contact-final p {
	max-width: 34rem;
	color: rgba(255, 255, 255, 0.9);
}

/* Motion */
@media (prefers-reduced-motion: no-preference) {
	.dmary-contact-card {
		animation: dmaryContactUp 0.65s var(--dn-ease) both;
	}

	.dmary-contact-card:nth-child(2) {
		animation-delay: 0.07s;
	}

	.dmary-contact-card:nth-child(3) {
		animation-delay: 0.14s;
	}
}

@keyframes dmaryContactUp {
	from {
		opacity: 0;
		transform: translateY(12px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}
