/*
Theme Name: A Través del Mundo
Theme URI: https://atravesdelmundo.com/
Author: A Través del Mundo
Description: Tema a la medida para guías de viaje desde México. Moderno: fondo claro, tinta casi negra y acento coral.
Version: 1.0.0
Requires at least: 6.6
Tested up to: 7.1
Requires PHP: 8.0
License: GNU General Public License v2 or later
Text Domain: atravesdelmundo
*/

/* ---------- Base ---------- */
:root {
	--atdm-arena: #FAF9F7;
	--atdm-superficie: #FFFFFF;
	--atdm-tinta: #16161D;
	--atdm-gris: #62626E;
	--atdm-terracota: #D23F36;
	--atdm-azul: #1B1A33;
	--atdm-linea: #ECE8E4;
	--atdm-durazno: #FFB49E;
	--atdm-tinte: #FFF0EC;
	--atdm-ancho: 1240px;
}
body { -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }
img { height: auto; }
:where(.wp-site-blocks) > * { margin-block-start: 0; }
:where(.wp-site-blocks) > main { margin-block-start: 0; }
a { text-underline-offset: 3px; }
:focus-visible { outline: 3px solid var(--atdm-terracota); outline-offset: 3px; }
.atdm-wrap { max-width: var(--atdm-ancho); margin-inline: auto; }
.atdm-label { font-size: 13px !important; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--atdm-terracota); margin: 0; }
.atdm-muted { color: var(--atdm-gris); }
.wp-block-button.is-style-outline > .wp-block-button__link { border: 1.5px solid currentColor; background: transparent; color: var(--atdm-tinta); padding: 14px 26px; }
.wp-block-button.is-style-outline > .wp-block-button__link:hover { background: var(--atdm-tinta); color: var(--atdm-superficie); }

/* ---------- Barra superior ---------- */
.atdm-bar { background: var(--atdm-azul); color: var(--atdm-arena); text-align: center; font-size: 14px; padding: 10px 24px; margin: 0; }
.atdm-bar a { color: var(--atdm-arena); font-weight: 600; }
.atdm-bar strong { display: inline-block; background: var(--atdm-arena); color: var(--atdm-azul); border-radius: 999px; padding: 2px 10px; font-size: 12px; letter-spacing: .04em; margin-right: 8px; }

/* ---------- Encabezado ---------- */
.atdm-header { border-bottom: 1px solid var(--atdm-linea); background: var(--atdm-arena); }
.atdm-header__inner { max-width: var(--atdm-ancho); margin-inline: auto; padding: 14px 24px; box-sizing: content-box; gap: 24px; }
@media (max-width: 781px) { .atdm-header__inner { padding: 10px 16px; } }
.atdm-logo { margin: 0 !important; }
.atdm-logo img { height: 60px; width: auto; border-radius: 0 !important; display: block; }
.atdm-nav { font-size: 16px; font-weight: 500; gap: 26px; }
.atdm-nav a { color: var(--atdm-tinta) !important; text-decoration: none; }
.atdm-nav a:hover { color: var(--atdm-terracota) !important; }
.atdm-nav .wp-block-navigation__responsive-container.is-menu-open { background: var(--atdm-arena); padding: 32px 24px; }
.atdm-header .wp-block-button__link { padding: 12px 22px; font-size: 15px; }
@media (max-width: 781px) {
	.atdm-logo img { height: 46px; }
	.atdm-header .wp-block-buttons { display: none; }
}

/* ---------- Hero ---------- */
.atdm-hero { min-height: 700px; padding: 0 !important; align-items: flex-end !important; }
.atdm-hero::before { content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none;
	background: linear-gradient(90deg, rgba(14,20,32,.78) 0%, rgba(14,20,32,.42) 45%, rgba(14,20,32,0) 75%), linear-gradient(0deg, rgba(14,20,32,.6) 0%, rgba(14,20,32,0) 40%); }
.atdm-hero .wp-block-cover__inner-container { position: relative; z-index: 2 !important; width: 100% !important; max-width: calc(var(--atdm-ancho) + 48px) !important; margin-inline: auto !important; padding: 120px 24px 72px; box-sizing: border-box; }
.atdm-hero .atdm-label { color: var(--atdm-durazno); }
.atdm-hero h1 { color: var(--atdm-superficie); font-size: clamp(44px, 6.4vw, 88px); line-height: 1.02; max-width: 780px; margin: 20px 0 0; letter-spacing: -.02em; }
.atdm-hero h1 em { color: var(--atdm-durazno); font-style: italic; padding-bottom: .06em; }
.atdm-hero p.atdm-hero__sub { color: #F1EFEC; font-size: 20px; line-height: 1.5; max-width: 560px; margin: 22px 0 0; }
.atdm-hero .wp-block-buttons { margin-top: 32px; gap: 12px; }
.atdm-hero .is-style-outline > .wp-block-button__link { color: var(--atdm-superficie); border-color: rgba(251,248,243,.8); }
.atdm-hero .is-style-outline > .wp-block-button__link:hover { background: var(--atdm-superficie); color: var(--atdm-tinta); }
@media (max-width: 781px) { .atdm-hero { min-height: 600px; } .atdm-hero .wp-block-cover__inner-container { padding: 96px 20px 40px; } .atdm-hero p.atdm-hero__sub { font-size: 17px; } }

/* ---------- Confianza ---------- */
.atdm-trust { background: var(--atdm-superficie); border-bottom: 1px solid var(--atdm-linea); padding: 28px 24px; margin: 0; }
.atdm-trust .wp-block-columns { max-width: var(--atdm-ancho); margin: 0 auto; gap: 28px; }
.atdm-trust h3 { font-family: var(--wp--preset--font-family--hanken); font-size: 17px; font-weight: 700; letter-spacing: 0; margin: 0 0 4px; }
.atdm-trust p { font-size: 15px; color: var(--atdm-gris); margin: 0; line-height: 1.5; }

/* ---------- Secciones ---------- */
.atdm-section { max-width: var(--atdm-ancho); margin: 0 auto !important; padding: 96px 24px 0; box-sizing: content-box; }
.atdm-section__head { margin-bottom: 36px; }
.atdm-section__head h2 { margin: 0; }
.atdm-section__head p { color: var(--atdm-gris); max-width: 560px; margin: 14px 0 0; font-size: 18px; }

/* Destinos */
.atdm-dest { gap: 28px !important; }
.atdm-dest .wp-block-cover { border-radius: 28px; overflow: hidden; min-height: 560px !important; align-items: flex-end; padding: 36px; }
.atdm-dest .wp-block-cover::after { content: ""; position: absolute; inset: 0; background: linear-gradient(0deg, rgba(14,20,32,.86) 0%, rgba(14,20,32,.08) 58%); z-index: 1; pointer-events: none; }
.atdm-dest .wp-block-cover img { transition: transform .6s ease; }
.atdm-dest .wp-block-cover:hover img { transform: scale(1.04); }
.atdm-dest .wp-block-cover__inner-container { position: relative; z-index: 2 !important; color: var(--atdm-superficie); }
.atdm-dest h3 { color: var(--atdm-superficie); font-size: 52px; line-height: 1; margin: 0 0 12px; }
.atdm-dest p { color: #F1EFEC; font-size: 17px; line-height: 1.5; max-width: 440px; margin: 0; }
.atdm-dest p.atdm-places { font-size: 14px; color: var(--atdm-durazno); letter-spacing: .02em; margin-top: 14px; }
.atdm-dest .wp-block-buttons { margin-top: 22px; }
.atdm-dest .wp-block-button__link { background: var(--atdm-superficie); color: var(--atdm-tinta); }
.atdm-dest .wp-block-button__link:hover { background: var(--atdm-terracota); color: #fff; }
@media (max-width: 781px) { .atdm-dest .wp-block-cover { min-height: 420px !important; padding: 24px; } .atdm-dest h3 { font-size: 38px; } }

/* Rutas */
.atdm-routes { padding-top: 40px; }
.atdm-routes .wp-block-columns { gap: 20px; }
.atdm-routes figure { margin: 0 0 14px; border-radius: 20px; overflow: hidden; aspect-ratio: 4 / 3; }
.atdm-routes figure img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s ease; }
.atdm-routes figure:hover img { transform: scale(1.05); }
.atdm-routes h3 { font-size: 24px; margin: 0; }
.atdm-routes p { font-size: 15px; color: var(--atdm-gris); margin: 6px 0 0; line-height: 1.5; }
.atdm-routes h3 a { color: var(--atdm-tinta); text-decoration: none; }

/* Guías (query) */
.atdm-guides-band { background: var(--atdm-superficie); border-block: 1px solid var(--atdm-linea); margin-top: 96px !important; padding: 0 0 96px; }
.atdm-guides .wp-block-post-template { gap: 40px 28px; }
.atdm-guides .wp-block-post-featured-image { margin-bottom: 16px; overflow: hidden; border-radius: 20px; }
.atdm-guides .wp-block-post-featured-image img { aspect-ratio: 4 / 3; object-fit: cover; transition: transform .6s ease; }
.atdm-guides .wp-block-post-featured-image:hover img { transform: scale(1.04); }
.atdm-guides .wp-block-post-terms { font-size: 13px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; margin: 0 0 8px; }
.atdm-guides .wp-block-post-terms a { text-decoration: none; }
.atdm-guides .wp-block-post-title { font-size: 25px; line-height: 1.2; margin: 0 0 8px; }
.atdm-guides .wp-block-post-title a { color: var(--atdm-tinta); text-decoration: none; }
.atdm-guides .wp-block-post-title a:hover { color: var(--atdm-terracota); }
.atdm-guides .wp-block-post-date { font-size: 14px; color: var(--atdm-gris); }
.atdm-empty { background: var(--atdm-arena); border: 1px dashed #DDD8D3; border-radius: 20px; padding: 32px; color: var(--atdm-gris); }

/* Herramientas */
.atdm-tools .wp-block-columns { gap: 40px; }
.atdm-tools__grid { display: grid !important; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px !important; }
.atdm-tool { background: var(--atdm-superficie); border: 1px solid var(--atdm-linea); border-radius: 22px; padding: 26px !important; margin: 0 !important; transition: border-color .2s ease, transform .2s ease; }
.atdm-tool:hover { border-color: var(--atdm-terracota); transform: translateY(-2px); }
.atdm-tool h3 { font-size: 24px; margin: 0 0 8px; }
.atdm-tool p { font-size: 15px; color: var(--atdm-gris); margin: 0 0 12px; line-height: 1.55; }
.atdm-tool p.atdm-tool__link { margin: 0; font-weight: 600; }
.atdm-tool p.atdm-tool__link a { text-decoration: none; }
.atdm-disclosure { background: var(--atdm-tinte); border-radius: 14px; padding: 16px 18px; font-size: 14px !important; line-height: 1.55; color: #4A4A55; }
@media (max-width: 781px) { .atdm-tools__grid { grid-template-columns: 1fr; } }

/* Presupuesto */
.atdm-budget { background: var(--atdm-tinta); color: var(--atdm-arena); margin-top: 96px !important; padding: 96px 24px; }
.atdm-budget > .wp-block-columns { max-width: var(--atdm-ancho); margin: 0 auto; gap: 56px; align-items: center; }
.atdm-budget h2 { color: var(--atdm-superficie); }
.atdm-budget p { color: #C8C6CC; font-size: 18px; }
.atdm-budget__card { background: var(--atdm-superficie); color: var(--atdm-tinta); border-radius: 26px; padding: 32px !important; box-shadow: 0 30px 60px rgba(8,12,20,.35); }
.atdm-budget__card h3 { font-size: 26px; margin: 0; }
.atdm-budget__card p { color: var(--atdm-gris); font-size: 14px; margin: 4px 0 0; }
.atdm-budget__card table { width: 100%; border-collapse: collapse; font-size: 16px; color: var(--atdm-tinta); }
.atdm-budget__card td { padding: 13px 0; border-bottom: 1px solid var(--atdm-tinte); border-top: 0; border-left: 0; border-right: 0; }
.atdm-budget__card td:last-child { text-align: right; font-weight: 600; }
.atdm-budget__card tr:last-child td { border-bottom: 0; font-size: 19px; font-weight: 700; padding-top: 18px; }
.atdm-budget__card tr:last-child td:last-child { color: var(--atdm-terracota); font-family: var(--wp--preset--font-family--hanken); font-weight: 700; }
.atdm-budget__card .wp-block-table { margin: 14px 0 0; }
.atdm-budget__card .wp-block-table td { border-color: var(--atdm-tinte); }

/* Sobre mí */
.atdm-about .wp-block-columns { gap: 56px; align-items: center; }
.atdm-about figure { margin: 0; border-radius: 28px; overflow: hidden; }
.atdm-about figure img { width: 100%; aspect-ratio: 5 / 4; object-fit: cover; }
.atdm-about p { font-size: 18px; color: #4A4A55; }

/* Boletín */
.atdm-news { margin-top: 96px !important; min-height: 460px !important; }
.atdm-news::before { content: ""; position: absolute; inset: 0; background: rgba(14,20,32,.6); z-index: 1; }
.atdm-news .wp-block-cover__inner-container { position: relative; z-index: 2 !important; max-width: 720px !important; margin-inline: auto; text-align: center; color: var(--atdm-superficie); }
.atdm-news h2 { color: var(--atdm-superficie); }
.atdm-news p { color: #F1EFEC; font-size: 18px; }
.atdm-news .wp-block-buttons { justify-content: center; }

/* ---------- Pie ---------- */
.atdm-footer { background: var(--atdm-arena); border-top: 1px solid var(--atdm-linea); padding: 72px 24px 32px; }
.atdm-footer > .wp-block-columns { max-width: var(--atdm-ancho); margin: 0 auto; gap: 48px; }
.atdm-footer .atdm-logo img { height: 70px; }
.atdm-footer h3 { font-family: var(--wp--preset--font-family--hanken); font-size: 16px; font-weight: 700; letter-spacing: 0; margin: 0 0 10px; }
.atdm-footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; font-size: 15px; }
.atdm-footer ul a { color: var(--atdm-tinta); text-decoration: none; }
.atdm-footer ul a:hover { color: var(--atdm-terracota); }
.atdm-footer p { color: var(--atdm-gris); font-size: 15px; }
.atdm-footer__legal { max-width: var(--atdm-ancho); margin: 40px auto 0 !important; padding-top: 20px; border-top: 1px solid var(--atdm-linea); font-size: 13px !important; color: var(--atdm-gris); }

/* ---------- Artículos y páginas ---------- */
.atdm-article-head { max-width: 900px; margin: 0 auto; padding: 56px 24px 24px; }
.atdm-article-head .wp-block-post-terms { font-size: 13px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; }
.atdm-article-head .wp-block-post-terms a { text-decoration: none; }
.atdm-article-head .wp-block-post-title { margin: 14px 0 0; }
.atdm-article-head .wp-block-post-excerpt { font-size: 20px; color: #4A4A55; margin-top: 18px; }
.atdm-article-head .wp-block-post-excerpt__excerpt { margin: 0; }
.atdm-meta { gap: 18px; font-size: 14px; color: var(--atdm-gris); margin-top: 18px; }
.atdm-meta .wp-block-post-author-name { font-weight: 700; color: var(--atdm-tinta); }
.atdm-feature { max-width: var(--atdm-ancho); margin: 16px auto 0 !important; padding-inline: 24px; }
.atdm-feature img { border-radius: 28px; max-height: 620px; object-fit: cover; width: 100%; }
.atdm-content { padding-top: 40px; padding-bottom: 72px; font-size: 18px; line-height: 1.72; color: #2A2A33; }
.atdm-content h2 { margin-top: 48px; font-size: 34px; }
.atdm-content h3 { margin-top: 32px; }
.atdm-content table { font-size: 16px; }
.atdm-content .wp-block-table { border-radius: 18px; overflow-x: auto; border: 1px solid var(--atdm-linea); background: var(--atdm-superficie); }
.atdm-content .wp-block-table thead { background: var(--atdm-tinte); border: 0; }
.atdm-content .wp-block-table td, .atdm-content .wp-block-table th { border: 0; border-top: 1px solid var(--atdm-linea); padding: 12px 16px; }
.atdm-content details { border-bottom: 1px solid var(--atdm-linea); padding: 16px 0; }
.atdm-content summary { cursor: pointer; font-weight: 700; }
.atdm-page-head { max-width: 760px; margin: 0 auto; padding: 64px 24px 0; }
.atdm-related { background: var(--atdm-superficie); border-top: 1px solid var(--atdm-linea); padding: 72px 24px 88px; }
.atdm-related > * { max-width: var(--atdm-ancho); margin-inline: auto !important; }
.atdm-archive-head { padding-top: 64px; }
.atdm-archive-head .wp-block-query-title { margin: 0; }
.atdm-archive-head .wp-block-term-description { color: var(--atdm-gris); max-width: 620px; }

@media (prefers-reduced-motion: reduce) {
	* { transition: none !important; }
}

/* ---------- Bloques especiales de artículos ---------- */
.atdm-content p.atdm-respuesta { background: var(--atdm-superficie); border: 1px solid var(--atdm-linea); border-radius: 20px; padding: 24px 26px; font-size: 19px; line-height: 1.6; color: var(--atdm-tinta); }
.atdm-content p.atdm-respuesta::before { content: "Respuesta rápida"; display: block; font-size: 13px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--atdm-terracota); margin-bottom: 8px; }
.atdm-content p.atdm-tu { background: #FFF0EC; border: 2px dashed var(--atdm-terracota); border-radius: 14px; padding: 16px 18px; font-size: 16px; color: #8E2A23; }
.atdm-content p.atdm-cta { background: #F1F0F8; border: 2px dashed var(--atdm-azul); border-radius: 14px; padding: 16px 18px; font-size: 16px; color: var(--atdm-azul); font-weight: 600; }
.atdm-content .wp-block-details { border-bottom: 1px solid var(--atdm-linea); padding: 16px 0; margin: 0; }
.atdm-content .wp-block-details summary { cursor: pointer; font-weight: 700; color: var(--atdm-tinta); }
.atdm-content .wp-block-details p { margin-top: 10px; }
.atdm-content .wp-block-table table { min-width: 520px; }
.atdm-region { padding-top: 64px; }
.atdm-region > h2 { margin-bottom: 24px; }
/* Menú compacto hasta pantallas anchas para que la navegación nunca ocupe dos líneas */
@media (max-width: 1100px) {
	.atdm-nav .wp-block-navigation__responsive-container-open:not(.always-shown) { display: flex; }
	.atdm-nav .wp-block-navigation__responsive-container:not(.hidden-by-default):not(.is-menu-open) { display: none; }
	.atdm-header .wp-block-buttons { display: none; }
}
.atdm-budget__card .wp-block-table + p { font-size: 13px !important; color: var(--atdm-gris) !important; margin-top: 12px; line-height: 1.5; }
