/* Sistemas Contra Incendios Madrid — estilos del tema (diseño del mockup aprobado) */

@font-face { font-family: Roboto; font-weight: 400; font-style: normal; font-display: swap; src: url(../fonts/roboto-latin-400-normal.woff2) format("woff2"); }
@font-face { font-family: Roboto; font-weight: 500; font-style: normal; font-display: swap; src: url(../fonts/roboto-latin-500-normal.woff2) format("woff2"); }
@font-face { font-family: Roboto; font-weight: 700; font-style: normal; font-display: swap; src: url(../fonts/roboto-latin-700-normal.woff2) format("woff2"); }
@font-face { font-family: Roboto; font-weight: 900; font-style: normal; font-display: swap; src: url(../fonts/roboto-latin-900-normal.woff2) format("woff2"); }
@font-face { font-family: "Roboto Condensed"; font-weight: 400; font-style: normal; font-display: swap; src: url(../fonts/roboto-condensed-latin-400-normal.woff2) format("woff2"); }
@font-face { font-family: "Roboto Condensed"; font-weight: 700; font-style: normal; font-display: swap; src: url(../fonts/roboto-condensed-latin-700-normal.woff2) format("woff2"); }

/* Paleta corporativa (kit global de Elementor de la web actual y logotipo) */
:root {
	--primary: #AB1B1B;
	--primary-dark: #781313;
	--primary-tint: #F7E8E8;
	--primary-tint-2: #FBF4F4;
	--accent: #E31E25;
	--accent-hover: #C11A1F;
	--black: #000;
	--text: #111;
	--grey: #4F4F4F;
	--line: #E5E5E5;
	--soft: #F5F5F5;
	--white: #fff;
	--font: Roboto, Arial, system-ui, sans-serif;
	--alt: "Roboto Condensed", "Arial Narrow", Arial, sans-serif;
	--r: 3px;
	--wrap: 1200px;
	--shadow: 0 1px 2px rgba(0, 0, 0, .06), 0 10px 28px rgba(0, 0, 0, .08);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--white); color: var(--text); font: 400 1rem/1.6 var(--font); }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--primary); text-underline-offset: .18em; }
a:hover { color: var(--accent); }
h1, h2, h3, h4 { font-family: var(--font); font-weight: 700; line-height: 1.15; color: var(--black); margin: 0 0 .6em; }
h1 { font-size: clamp(2.1rem, 1.3rem + 3.4vw, 4rem); font-weight: 900; letter-spacing: -.01em; }
h2 { font-size: clamp(1.6rem, 1.2rem + 1.5vw, 2.4rem); }
h3 { font-size: 1.2rem; }
p { margin: 0 0 1em; }
:focus-visible { outline: 3px solid #ffb300; outline-offset: 2px; }
.ico { width: 1.1em; height: 1.1em; flex: none; vertical-align: -.18em; }

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 16px; }
@media (min-width: 768px) { .wrap { padding: 0 28px; } }
.wrap--narrow { max-width: 860px; }
.screen-reader-text { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: -9999px; top: 8px; background: var(--black); color: #fff; padding: 8px 14px; z-index: 100; }
.skip-link:focus { left: 8px; }

.kicker { font: 700 .88rem/1.3 var(--alt); letter-spacing: .14em; text-transform: uppercase; color: var(--accent); margin: 0 0 .4rem; }
.sub { color: var(--grey); max-width: 50em; font-size: 1.06rem; }
.hd { font-family: var(--font); font-weight: 700; color: var(--black); font-size: 1.12rem; line-height: 1.25; margin: 0 0 .6em; }
.hd--lg { font-size: clamp(1.5rem, 1.2rem + 1.2vw, 2.1rem); }
.more { font: 700 .88rem/1.2 var(--alt); color: var(--accent); text-transform: uppercase; letter-spacing: .03em; }
.tag { display: inline-block; align-self: flex-start; font: 700 .8rem/1.2 var(--alt); text-transform: uppercase; color: #fff; background: var(--primary); padding: 3px 8px; }

/* Botones */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .5em; min-height: 46px; padding: .75em 1.4em; border-radius: var(--r); border: 2px solid transparent; font: 700 1rem/1.2 var(--alt); letter-spacing: .04em; text-transform: uppercase; text-decoration: none; cursor: pointer; transition: background .15s, color .15s, border-color .15s; text-align: center; }
.btn--lg { min-height: 54px; padding: .9em 1.6em; font-size: 1.05rem; }
.btn--accent { background: var(--accent); color: #fff; }
.btn--accent:hover { background: var(--accent-hover); color: #fff; }
.btn--primary { background: var(--primary); color: #fff; }
.btn--primary:hover { background: var(--primary-dark); color: #fff; }
.btn--dark { background: var(--black); color: #fff; }
.btn--dark:hover { background: #222; color: #fff; }
.btn--outline { border-color: var(--primary); color: var(--primary); background: transparent; font-size: .92rem; }
.btn--outline:hover { background: var(--primary); color: #fff; }
.btn--ghost-light { border-color: #fff; color: #fff; background: transparent; }
.btn--ghost-light:hover { background: rgba(255, 255, 255, .12); color: #fff; }

/* Barra superior */
.topbar { background: var(--primary); color: #fff; font: 400 .9rem/1.3 var(--alt); }
.topbar__inner { display: flex; align-items: center; gap: 22px; min-height: 38px; }
.topbar__item { color: #fff; text-decoration: none; display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; }
.topbar__item:hover { color: #fff; text-decoration: underline; }
.topbar__claim { margin: 0 0 0 auto; text-align: right; }
@media (max-width: 1100px) { .topbar__claim { display: none; } }
@media (max-width: 640px) { .topbar__mail { display: none; } .topbar__inner { justify-content: center; gap: 16px; } }

/* Cabecera */
.header { background: var(--black); position: sticky; top: 0; z-index: 50; }
.header__inner { display: flex; align-items: center; gap: 16px; min-height: 92px; }
.brand { display: flex; align-items: center; gap: 12px; margin-right: auto; text-decoration: none; flex: none; }
.brand img { width: auto; height: 72px; }
.brand__name { font: 700 1.3rem/1.05 var(--alt); color: #fff; letter-spacing: .02em; white-space: nowrap; }
@media (min-width: 1181px) and (max-width: 1300px) { .brand__name { display: none; } }
.brand__name small { display: block; font-size: .8rem; font-weight: 400; color: #ddd; letter-spacing: .12em; text-transform: uppercase; margin-top: 3px; }
.brand:hover .brand__name { color: #fff; }
@media (max-width: 1560px) { .brand__name small { display: none; } }
.nav__list { list-style: none; margin: 0; padding: 0; display: flex; align-items: center; }
.nav__list > li > a, .nav__sub-toggle { display: inline-flex; align-items: center; gap: 2px; padding: 10px 6px; white-space: nowrap; font: 700 .95rem/1.2 var(--alt); letter-spacing: .03em; text-transform: uppercase; color: #fff; text-decoration: none; background: none; border: 0; border-bottom: 2px solid transparent; cursor: pointer; }
.nav__list > li > a:hover, .nav__sub-toggle:hover { color: var(--accent); }
.nav__list > li.is-active > a, .nav__list > li.is-active > .nav__sub-toggle { color: var(--accent); border-bottom-color: var(--accent); }
.nav__sub-toggle .ico { width: 14px; height: 14px; }
.nav__has-sub { position: relative; }
.nav__sub { list-style: none; margin: 0; padding: 8px; position: absolute; top: 100%; left: 0; min-width: 290px; background: #fff; border-top: 3px solid var(--accent); box-shadow: var(--shadow); display: none; z-index: 60; }
.nav__sub a { display: block; padding: 8px 12px; color: var(--text); text-decoration: none; font-size: .95rem; }
.nav__sub a:hover, .nav__sub a[aria-current] { background: var(--primary-tint-2); color: var(--primary); }
.nav__has-sub.is-open .nav__sub { display: block; }
@media (hover: hover) and (min-width: 1181px) { .nav__has-sub:hover .nav__sub, .nav__has-sub:focus-within .nav__sub { display: block; } }
.nav__cta-mobile, .header__burger { display: none; }
.header__tel { white-space: nowrap; padding: .7em 1.1em; }
.header__burger { background: none; border: 0; padding: 10px; margin-right: -10px; color: #fff; cursor: pointer; }
.header__burger .ico { width: 30px; height: 30px; }
.header__burger .ico--close { display: none; }
.header__burger[aria-expanded="true"] .ico--open { display: none; }
.header__burger[aria-expanded="true"] .ico--close { display: block; }
@media (max-width: 1180px) {
	.header__inner { min-height: 74px; gap: 10px; }
	.brand img { height: 56px; }
	.header__burger { display: block; }
	.nav { display: none; position: absolute; left: 0; right: 0; top: 100%; background: var(--black); border-top: 1px solid #222; padding: 8px 16px 20px; max-height: calc(100vh - 112px); overflow-y: auto; }
	.nav.is-open { display: block; }
	.nav__list { flex-direction: column; align-items: stretch; }
	.nav__list > li > a, .nav__sub-toggle { width: 100%; justify-content: space-between; padding: 14px 4px; font-size: 1.05rem; border-bottom: 1px solid #222; }
	.nav__list > li.is-active > a, .nav__list > li.is-active > .nav__sub-toggle { border-bottom-color: #222; }
	.nav__sub { position: static; box-shadow: none; border: 0; padding: 4px 0 8px 12px; background: transparent; min-width: 0; }
	.nav__sub a { color: #ddd; }
	.nav__sub a:hover, .nav__sub a[aria-current] { background: transparent; color: #fff; }
	.nav__cta-mobile { display: flex; margin-top: 16px; }
}
@media (max-width: 640px) { .brand__name { font-size: 1.05rem; } .header__tel-txt { display: none; } }
@media (max-width: 520px) { .brand__name { display: none; } .header__tel { font-size: .95rem; padding: .6em .8em; } }

/* Secciones */
.section { padding: clamp(52px, 7vw, 80px) 0; }
.section--soft { background: var(--soft); }
.section--tint { background: var(--primary-tint-2); }
.section__head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px 40px; flex-wrap: wrap; margin-bottom: 34px; }
.section__head > div { flex: 1 1 560px; max-width: 820px; }
.section__head h2 { margin-bottom: .3em; }
.section__head .sub { margin: 0; }

/* Portada: hero */
.hero { position: relative; color: #fff; background: linear-gradient(90deg, rgba(0, 0, 0, .92) 0%, rgba(120, 19, 19, .88) 52%, rgba(171, 27, 27, .35) 100%), var(--hero) center / cover no-repeat, var(--black); }
.hero__inner { padding-top: clamp(56px, 8vw, 92px); padding-bottom: clamp(52px, 7vw, 84px); }
.eyebrow { display: inline-block; font: 400 .92rem/1.3 var(--alt); letter-spacing: .14em; text-transform: uppercase; color: #fff; background: rgba(227, 30, 37, .9); padding: 5px 12px; margin: 0; }
.hero h1 { color: #fff; margin: 22px 0; max-width: 13em; }
.hero__lead { font-size: clamp(1.02rem, .95rem + .35vw, 1.2rem); color: #f2f2f2; max-width: 38em; }
.hero__ctas { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 30px; }
.trustbar { background: var(--black); color: #fff; }
.trustbar__inner { list-style: none; margin: 0 auto; padding-top: 22px; padding-bottom: 22px; display: grid; gap: 16px 20px; grid-template-columns: 1fr; }
@media (min-width: 600px) { .trustbar__inner { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1000px) { .trustbar__inner { grid-template-columns: repeat(4, 1fr); } }
.trustbar li { display: flex; gap: 12px; align-items: flex-start; }
.trustbar .ico { width: 22px; height: 22px; color: var(--accent); margin-top: 2px; }
.trustbar strong { display: block; font: 700 1.06rem/1.25 var(--alt); }
.trustbar span span, .trustbar li > span { font-size: .9rem; color: #cfcfcf; }
.trustbar li > span strong { color: #fff; }

/* Tarjetas de servicio */
.grid5 { display: grid; gap: 18px; grid-template-columns: 1fr; }
@media (min-width: 560px) { .grid5 { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 900px) { .grid5 { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1150px) { .grid5 { grid-template-columns: repeat(5, 1fr); } }
.card { display: flex; flex-direction: column; border: 1px solid var(--line); border-top: 4px solid var(--primary); padding: 24px 20px; background: #fff; min-height: 238px; text-decoration: none; color: var(--text); transition: box-shadow .2s, transform .2s; }
.card:hover { box-shadow: var(--shadow); transform: translateY(-2px); color: var(--text); }
.card__ic { width: 58px; height: 58px; border-radius: 50%; background: var(--primary-tint); display: grid; place-items: center; margin-bottom: 16px; color: var(--primary); }
.card__ic .ico { width: 32px; height: 32px; }
.card h3, .card__t { display: block; font-size: 1.18rem; margin-bottom: 8px; color: var(--primary); font-weight: 700; }
.card__d { font-size: .93rem; color: var(--grey); flex: 1; }
.card .more { margin-top: 12px; }
.pills { margin: 26px 0 0; display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.pills strong { margin-right: 4px; }
.pills a { background: var(--primary-tint-2); border: 1px solid var(--primary-tint); color: var(--primary); padding: 7px 14px; border-radius: 20px; font-weight: 500; text-decoration: none; font-size: .95rem; }
.pills a:hover { background: var(--primary); color: #fff; }

/* RIPCI */
.ripci { display: grid; gap: 24px; margin-top: 28px; }
@media (min-width: 860px) { .ripci { grid-template-columns: 1fr 1fr; } }
.ripci__block { background: #fff; padding: clamp(24px, 3vw, 34px); border-left: 6px solid var(--primary); }
.ripci__block h3 { font-size: 1.45rem; }
.ripci__block p { color: var(--grey); margin-bottom: 20px; }

/* Sectores */
.sectors { display: grid; gap: 16px; grid-template-columns: 1fr; margin-top: 28px; }
@media (min-width: 560px) { .sectors { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 900px) { .sectors { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1150px) { .sectors { grid-template-columns: repeat(5, 1fr); } }
.sector { display: block; background: var(--black); color: #fff; padding: 26px 22px; min-height: 190px; border-bottom: 4px solid var(--accent); text-decoration: none; transition: background .2s; }
.sector:hover { background: #1a1a1a; color: #fff; }
.sector h3 { color: #fff; font-size: 1.18rem; margin-bottom: 10px; }
.sector span { font-size: .93rem; color: #d7d7d7; }

/* La empresa */
.about__inner { display: grid; gap: 40px; align-items: center; }
@media (min-width: 960px) { .about__inner { grid-template-columns: 1.1fr .9fr; gap: 56px; } }
.about p:not(.kicker) { font-size: 1.04rem; color: #222; }
.about__checks { list-style: none; margin: 18px 0 26px; padding: 0; display: grid; gap: 10px 18px; grid-template-columns: 1fr; }
@media (min-width: 560px) { .about__checks { grid-template-columns: 1fr 1fr; } }
.about__checks li { display: flex; gap: 8px; align-items: center; font-weight: 500; font-size: .96rem; }
.about__checks .ico { width: 20px; height: 20px; color: var(--accent); }
.about__photo { position: relative; margin: 0 0 0 26px; }
.about__photo img { width: 100%; height: clamp(300px, 36vw, 430px); object-fit: cover; }
.about__badge { position: absolute; left: -26px; bottom: 26px; background: var(--primary); color: #fff; padding: 16px 22px; font: 400 1rem/1.2 var(--alt); }
.about__badge b { display: block; font-size: 1.9rem; }

/* Zona de servicio */
.zones { background: var(--black); color: #fff; }
.zones h2 { color: #fff; }
.zones .sub { color: #d0d0d0; }
.zones__inner { display: grid; gap: 36px; align-items: center; }
@media (min-width: 960px) { .zones__inner { grid-template-columns: .9fr 1.1fr; gap: 50px; } }
.zones__list { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; grid-template-columns: repeat(2, 1fr); }
@media (min-width: 640px) { .zones__list { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1100px) { .zones__list { grid-template-columns: repeat(4, 1fr); } }
.zones__list a { display: block; border: 1px solid #444; padding: 13px 14px; font: 400 1.05rem/1.2 var(--alt); color: #fff; text-decoration: none; }
.zones__list a::before { content: "● "; color: var(--accent); }
.zones__list a:hover { border-color: var(--accent); }

/* Proceso */
.steps { list-style: none; margin: 30px 0 0; padding: 0; display: grid; gap: 22px; grid-template-columns: 1fr; }
@media (min-width: 640px) { .steps { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1000px) { .steps { grid-template-columns: repeat(4, 1fr); } }
.steps__n { width: 46px; height: 46px; border-radius: 50%; background: var(--accent); color: #fff; display: grid; place-items: center; font-weight: 700; font-size: 1.25rem; margin-bottom: 14px; }
.steps h3 { font-size: 1.18rem; margin-bottom: 6px; }
.steps p { color: var(--grey); font-size: .96rem; margin: 0; }

/* Preguntas frecuentes */
.split { display: grid; gap: 30px 50px; }
@media (min-width: 960px) { .split--faq { grid-template-columns: .7fr 1.3fr; } }
.faqs, .prose .faq-list { display: grid; gap: 12px; }
details.faq { background: #fff; border-left: 4px solid var(--primary); }
details.faq summary { cursor: pointer; list-style: none; padding: 18px 52px 18px 22px; font-weight: 600; font-size: 1.05rem; position: relative; line-height: 1.4; }
details.faq summary::-webkit-details-marker { display: none; }
details.faq summary::after { content: "+"; position: absolute; right: 22px; top: 50%; transform: translateY(-50%); color: var(--accent); font-size: 1.6rem; line-height: 1; }
details.faq[open] summary::after { content: "–"; }
details.faq > p, details.faq > div { padding: 0 22px 18px; margin: 0; color: var(--grey); }
.prose details.faq { background: var(--soft); }

/* Artículos (portada, blog) */
.posts { list-style: none; margin: 0; padding: 0; display: grid; gap: 22px; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
.posts--3 { grid-template-columns: 1fr; }
@media (min-width: 760px) { .posts--3 { grid-template-columns: repeat(3, 1fr); } }
.post-card a { display: flex; flex-direction: column; height: 100%; background: #fff; border: 1px solid var(--line); text-decoration: none; color: var(--text); transition: box-shadow .2s; }
.post-card a:hover { box-shadow: var(--shadow); color: var(--text); }
.post-card img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; background: var(--soft); }
.post-card__body { padding: 18px 20px 22px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.post-card strong { font-size: 1.1rem; line-height: 1.3; color: var(--black); }
.post-card__body > span:not(.tag):not(.more) { font-size: .92rem; color: var(--grey); }
.post-card .more { margin-top: auto; }
.posts--3 .post-card img, .posts--guides .post-card img { object-fit: contain; background: #fff; padding: 10px; border-bottom: 1px solid var(--line); }
.list-title { font-size: 1.5rem; margin: 0 0 20px; }
.posts + .list-title, .posts--guides + .list-title { margin-top: 52px; }
.pagination { margin-top: 36px; }
.pagination .nav-links { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; }
.pagination .page-numbers { display: inline-grid; place-items: center; min-width: 44px; min-height: 44px; padding: 0 12px; border: 1px solid var(--line); background: #fff; text-decoration: none; color: var(--text); }
.pagination .page-numbers.current { background: var(--primary); color: #fff; border-color: var(--primary); }

/* Llamada final */
.cta { background: linear-gradient(90deg, var(--primary-dark), var(--primary)); color: #fff; padding: clamp(44px, 5vw, 60px) 0; }
.cta__inner { display: grid; gap: 24px; align-items: center; }
@media (min-width: 960px) { .cta__inner { grid-template-columns: 1.5fr auto auto; gap: 40px; } }
.cta .hd { color: #fff; margin-bottom: .3em; }
.cta p { color: #fbe9e9; margin: 0; }
.cta__phones { font: 700 1.8rem/1.2 var(--alt); white-space: nowrap; }
.cta__phones a { color: #fff; text-decoration: none; }
.cta__phones small { display: block; font-size: .95rem; font-weight: 400; }
@media (min-width: 960px) { .cta__phones { text-align: right; } }

/* Páginas interiores */
.page-hero { background: linear-gradient(90deg, #000 0%, var(--primary-dark) 70%, var(--primary) 100%); color: #fff; border-bottom: 4px solid var(--accent); }
.page-hero__inner { display: grid; gap: 28px; padding-top: 26px; padding-bottom: 44px; align-items: center; }
@media (min-width: 900px) { .page-hero--img .page-hero__inner { grid-template-columns: 1.4fr 1fr; } }
.page-hero h1 { color: #fff; font-size: clamp(1.9rem, 1.3rem + 2.4vw, 3rem); margin: 14px 0 .4em; }
.page-hero__lead { font-size: 1.1rem; color: #f0f0f0; max-width: 42em; margin: 0; }
.page-hero__ctas { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }
.page-hero__media { margin: 0; }
.page-hero__media img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; background: #fff; border: 4px solid rgba(255, 255, 255, .12); }
.byline { color: #e2e2e2; font-size: .93rem; margin: 0; }
.crumbs ol { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 4px; font: 400 .9rem/1.3 var(--alt); color: #d4d4d4; }
.crumbs li + li::before { content: "›"; margin-right: 4px; color: var(--accent); }
.crumbs a { color: #fff; }
.page-grid { display: grid; gap: 40px; }
@media (min-width: 1000px) { .page-grid { grid-template-columns: minmax(0, 1fr) 330px; align-items: start; } }

/* Texto largo */
.prose { font-size: 1.04rem; max-width: 800px; }
.prose h2 { font-size: clamp(1.4rem, 1.15rem + .9vw, 1.85rem); margin-top: 1.7em; padding-top: .2em; }
.prose h3 { margin-top: 1.4em; font-size: 1.22rem; color: var(--primary); }
.prose > :first-child { margin-top: 0; }
.prose ul, .prose ol { padding-left: 1.3em; margin: 0 0 1.2em; }
.prose li { margin-bottom: .45em; }
.prose li::marker { color: var(--accent); }
.prose figure { margin: 1.6em 0; }
.prose figure img { width: 100%; max-height: 520px; object-fit: cover; }
.prose figure.contain img { object-fit: contain; background: var(--soft); max-height: 460px; }
.prose figcaption { font-size: .88rem; color: var(--grey); margin-top: 8px; }
.prose table { width: 100%; border-collapse: collapse; margin: 1.4em 0; font-size: .95rem; background: #fff; }
.prose th, .prose td { border: 1px solid var(--line); padding: 10px 12px; text-align: left; vertical-align: top; overflow-wrap: break-word; }
.prose th { background: var(--primary); color: #fff; font-weight: 700; }
.prose tbody tr:nth-child(even) td { background: var(--primary-tint-2); }
.prose .table-wrap { overflow-x: auto; margin: 1.4em 0; }
.prose .table-wrap table { margin: 0; }
.prose iframe { display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; border: 0; margin: 1.4em 0; }
.prose blockquote { margin: 1.6em 0; padding: 16px 20px; background: var(--primary-tint-2); border-left: 4px solid var(--primary); }
.prose blockquote p:last-child { margin: 0; }
.checks { list-style: none !important; padding: 0 !important; }
.checks li { position: relative; padding-left: 28px; }
.checks li::before { content: ""; position: absolute; left: 4px; top: .45em; width: 12px; height: 7px; border-left: 2.4px solid var(--accent); border-bottom: 2.4px solid var(--accent); transform: rotate(-45deg); }
.answer { background: var(--primary-tint-2); border-left: 4px solid var(--primary); padding: 18px 20px; margin: 0 0 1.6em; font-size: 1.08rem; }
.answer p:last-child { margin: 0; }
.gallery-grid { display: grid; gap: 12px; grid-template-columns: repeat(2, 1fr); margin: 1.6em 0; }
@media (min-width: 700px) { .gallery-grid { grid-template-columns: repeat(3, 1fr); } }
.gallery-grid figure { margin: 0; }
.gallery-grid img { aspect-ratio: 1; object-fit: contain; width: 100%; background: #fff; border: 1px solid var(--line); max-height: none; }
.cert-grid { display: grid; gap: 18px; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); margin: 1.6em 0; }
.cert-grid figure { margin: 0; border: 1px solid var(--line); background: #fff; padding: 10px; }
.cert-grid img { width: 100%; aspect-ratio: 3 / 4; object-fit: contain; max-height: none; }
.cert-grid figcaption { font-size: .88rem; color: var(--text); margin-top: 8px; line-height: 1.35; }
.post-thumb { margin: 0 0 1.6em; }
.post-thumb img { width: 100%; max-height: 460px; object-fit: cover; }
.sitemap ul { columns: 2 260px; }
.contact__text { margin-top: 48px; }

/* Lateral */
.aside { display: grid; gap: 18px; }
@media (min-width: 1000px) { .aside { position: sticky; top: 112px; } }
.aside__box { background: #fff; border: 1px solid var(--line); padding: 22px; }
.aside__box--brand { background: var(--black); border-color: var(--black); color: #fff; border-top: 4px solid var(--accent); }
.aside__box--brand .hd { color: #fff; }
.aside__box--brand p { color: #d0d0d0; font-size: .95rem; }
.aside__box--brand .btn { width: 100%; }
.aside__tel, .aside__wa { display: flex; align-items: center; justify-content: center; gap: 8px; margin-top: 12px; color: #fff; font: 700 1.3rem/1.2 var(--alt); text-decoration: none; }
.aside__wa { font-size: 1.05rem; font-weight: 400; margin-top: 6px; }
.aside__tel:hover, .aside__wa:hover { color: #fff; text-decoration: underline; }
.aside__note { margin: 12px 0 0; font-size: .82rem !important; text-align: center; }
.aside__box--creds p { display: flex; gap: 10px; align-items: flex-start; font-size: .9rem; margin: 0; }
.aside__box--creds p + p { margin-top: 12px; }
.aside__box--creds .ico { width: 24px; height: 24px; color: var(--primary); }
.aside__links { list-style: none; margin: 0; padding: 0; }
.aside__links li { border-top: 1px solid var(--line); }
.aside__links a { display: block; padding: 9px 0; text-decoration: none; color: var(--text); font-size: .95rem; }
.aside__links a:hover { color: var(--primary); }

/* Presupuesto */
.quote__inner { display: grid; gap: 36px; }
@media (min-width: 1000px) { .quote__inner { grid-template-columns: 1fr 1.4fr; align-items: start; } }
.quote__contact { line-height: 2.1; }
.quote__contact .ico { margin-right: 8px; color: var(--accent); }

/* Formulario */
.form { background: #fff; border: 1px solid var(--line); border-top: 4px solid var(--primary); padding: clamp(20px, 4vw, 32px); box-shadow: var(--shadow); scroll-margin-top: 120px; max-width: 100%; }
.form__title { font-size: 1.5rem; }
.form__intro { color: var(--grey); font-size: .95rem; }
.form__row { display: grid; gap: 0 16px; }
@media (min-width: 640px) { .form__row { grid-template-columns: 1fr 1fr; } }
.form__field { margin: 0 0 14px; }
.form__field label { display: block; font-weight: 600; font-size: .9rem; margin-bottom: 5px; }
.form input[type=text], .form input[type=tel], .form input[type=email], .form select, .form textarea { width: 100%; min-height: 46px; padding: 10px 12px; border: 1.5px solid var(--line); border-radius: var(--r); font: inherit; background: var(--soft); color: var(--text); }
.form input:focus, .form select:focus, .form textarea:focus { outline: none; border-color: var(--primary); background: #fff; }
.form input[type=file] { font-size: .9rem; width: 100%; }
.form__hint { display: block; font-size: .82rem; color: var(--grey); margin-top: 4px; }
.form__check { display: flex; gap: 10px; align-items: flex-start; font-size: .92rem; }
.form__check input { margin-top: 4px; width: 18px; height: 18px; accent-color: var(--primary); flex: none; }
.form__legal { font-size: .8rem; color: var(--grey); }
.form__alert { background: #fdecec; border: 1px solid #f2b8ba; color: #8a0b10; padding: 12px 14px; font-size: .93rem; }
.form__hp { position: absolute; left: -9999px; }
.form__done { background: #eaf6ec; border: 1px solid #b7dfbf; color: #14532d; padding: 14px 16px; margin: 0; }
.form.is-sending button[type=submit] { opacity: .6; pointer-events: none; }
.grecaptcha-badge { visibility: hidden; }

/* Contacto */
.contact { display: grid; gap: 36px; }
@media (min-width: 1000px) { .contact { grid-template-columns: 1fr 1.4fr; align-items: start; } }
.facts { background: #fff; border: 1px solid var(--line); border-top: 4px solid var(--primary); padding: 24px; box-shadow: var(--shadow); }
.facts dl { margin: 0; }
.facts dl > div { display: grid; grid-template-columns: 112px minmax(0, 1fr); gap: 12px; padding: 10px 0; border-top: 1px solid var(--line); font-size: .95rem; }
.facts dt { color: var(--grey); }
.facts dd { margin: 0; font-weight: 600; overflow-wrap: anywhere; }
.map iframe { display: block; width: 100%; height: 400px; border: 0; }

/* Pie */
.footer { background: var(--black); color: #cfcfcf; padding-top: 60px; font-size: .95rem; }
.footer a { color: #e6e6e6; text-decoration: none; }
.footer a:hover { color: #fff; text-decoration: underline; }
.footer__grid { display: grid; gap: 36px; grid-template-columns: 1fr; padding-bottom: 44px; }
@media (min-width: 700px) { .footer__grid { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1100px) { .footer__grid { grid-template-columns: 1.3fr 1fr 1fr 1.2fr; } }
.footer__brand img { height: 80px; width: auto; margin-bottom: 14px; }
.footer__creds { list-style: none; margin: 16px 0 0; padding: 0; }
.footer__creds li { display: flex; gap: 8px; align-items: center; color: #e6e6e6; font-weight: 500; font-size: .9rem; margin-bottom: 8px; }
.footer__creds .ico { color: var(--accent); width: 20px; height: 20px; }
.footer .hd { font: 700 .95rem/1.3 var(--alt); letter-spacing: .1em; text-transform: uppercase; color: #fff; margin-bottom: 14px; }
.footer ul { list-style: none; margin: 0; padding: 0; }
.footer__col li { margin-bottom: 8px; }
.footer__contact li { display: flex; gap: 10px; align-items: flex-start; margin-bottom: 12px; }
.footer__contact .ico { margin-top: 3px; color: var(--accent); }
.footer__contact a { overflow-wrap: anywhere; }
.footer__zones-hd { margin-top: 24px; }
.footer__zones { display: flex; flex-wrap: wrap; gap: 4px 14px; }
.footer__bottom { border-top: 1px solid #333; padding: 18px 0; font-size: .86rem; }
.footer__bottom-inner { display: flex; flex-wrap: wrap; gap: 8px 24px; justify-content: space-between; }
.footer__bottom p { margin: 0; }
.footer__bottom ul { display: flex; flex-wrap: wrap; gap: 6px 18px; }

/* Barra fija en el móvil */
.mbar { display: none; }
@media (max-width: 760px) {
	.mbar { display: grid; grid-template-columns: 1fr 1fr 1.4fr; position: fixed; left: 0; right: 0; bottom: 0; z-index: 60; background: var(--black); box-shadow: 0 -4px 16px rgba(0, 0, 0, .2); }
	.mbar a { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; min-height: 58px; font: 700 .82rem/1.1 var(--alt); text-transform: uppercase; color: #fff; text-decoration: none; }
	.mbar .ico { width: 20px; height: 20px; color: var(--accent); }
	.mbar__cta { background: var(--accent); }
	.mbar__cta .ico { color: #fff; }
	body { padding-bottom: 58px; }
}

/* Mapa bajo demanda */
.map-consent { position: relative; display: grid; place-items: center; width: 100%; min-height: 400px; background: var(--soft); overflow: hidden; text-align: center; }
.map-consent__box { padding: 24px; max-width: 400px; }
.map-consent__ico { width: 40px; height: 40px; color: var(--primary); margin-bottom: 8px; }
.map-consent__title { font-weight: 700; color: var(--black); margin: 0 0 14px; }
.map-consent__note { font-size: .82rem; color: var(--grey); margin: 14px 0 0; line-height: 1.45; }
.map-consent.is-loaded { display: block; background: none; }
.map-consent iframe { width: 100%; height: 100%; min-height: inherit; border: 0; display: block; }

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

/* Móvil: que ninguna columna de rejilla se salga de la pantalla */
.contact > *, .quote__inner > *, .page-grid > *, .split > *, .about__inner > *, .zones__inner > *, .prose, .prose .table-wrap { min-width: 0; }
@media (max-width: 420px) { .facts dl > div { grid-template-columns: 92px minmax(0, 1fr); gap: 10px; } .about__photo { margin-left: 0; } .about__badge { left: 0; } }
/* Tablas en el móvil: cada fila pasa a ser una ficha con la etiqueta de su columna (data-label, añadido en inc/compat.php). */
@media (max-width: 640px) {
	.prose .table-wrap { overflow: visible; }
	.prose table.sci-stack, .prose table.sci-stack tbody, .prose table.sci-stack tr, .prose table.sci-stack td { display: block; width: 100%; }
	.prose table.sci-stack { border: 0; background: none; font-size: .96rem; }
	.prose table.sci-stack thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
	.prose table.sci-stack tr { background: #fff; border: 1px solid var(--line); margin-bottom: 12px; overflow: hidden; }
	.prose table.sci-stack td { border: 0; border-top: 1px solid var(--line); padding: 9px 14px; overflow-wrap: anywhere; background: #fff !important; }
	.prose table.sci-stack td:first-child { border-top: 0; background: var(--primary-tint) !important; font-weight: 700; }
	.prose table.sci-stack td[data-label]:not(:first-child)::before { content: attr(data-label); display: block; font: 700 .78rem/1.3 var(--alt); letter-spacing: .04em; text-transform: uppercase; color: var(--grey); margin-bottom: 2px; }
}
