/* ==========================================================================
   LENZA ENGINEERING · styles.css
   Paleta derivada del logotipo: azul marino #15263A + escala de azul acero
   ========================================================================== */

/* ---------- Fuentes (alojadas localmente, licencia OFL) ---------- */
@font-face { font-family: "Montserrat"; src: url("../fonts/montserrat-var.woff") format("woff"); font-weight: 100 900; font-display: swap; }
@font-face { font-family: "Inter"; src: url("../fonts/inter-regular.woff") format("woff"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Inter"; src: url("../fonts/inter-medium.woff") format("woff"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Inter"; src: url("../fonts/inter-semibold.woff") format("woff"); font-weight: 600; font-display: swap; }

/* ---------- Tokens ---------- */
:root {
  --navy-950: #0A1422;
  --navy-900: #0F1D2E;
  --navy: #15263A;
  --navy-700: #213650;
  --steel-700: #3E5268;
  --steel-600: #4A5F75;
  --steel-500: #67809A;
  --steel-400: #8199AF;
  --steel-300: #A9BCCD;
  --steel-200: #CBD7E2;
  --steel-100: #E7EDF3;
  --paper: #F4F6F9;
  --white: #FFFFFF;
  --ink: #18202D;
  --text: #3A4452;
  --muted: #5F6B7A;
  --line: #E0E6ED;
  --ok: #1F7A55;
  --err: #B42318;

  --f-head: "Montserrat", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --f-body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;

  --radius: 14px;
  --radius-sm: 9px;
  --shadow-sm: 0 1px 2px rgba(15, 29, 46, .06), 0 2px 8px rgba(15, 29, 46, .05);
  --shadow: 0 10px 30px -10px rgba(15, 29, 46, .22), 0 2px 6px rgba(15, 29, 46, .06);
  --shadow-lg: 0 30px 60px -20px rgba(10, 20, 34, .45);
  --header-h: 88px;
  --container: 1240px;
  --ease: cubic-bezier(.2, .7, .2, 1);

  /* logo inline: colores por defecto (fondo claro) */
  --lz-navy: #15263A; --lz-legl: #8199AF; --lz-legr: #67809A; --lz-apex: #4A5F75;
  --lz-word: #1B2230; --lz-sub: #4A505B; --lz-rule: #A9AFB9;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 12px); }
body { margin: 0; font-family: var(--f-body); font-size: 1.0625rem; line-height: 1.65; color: var(--text); background: var(--white); -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--navy-700); text-underline-offset: 3px; }
a:hover { color: var(--steel-600); }
h1, h2, h3, h4 { font-family: var(--f-head); color: var(--ink); line-height: 1.18; margin: 0 0 .6em; letter-spacing: -.01em; overflow-wrap: break-word; }
:lang(de) h3 { hyphens: auto; -webkit-hyphens: auto; }
p { margin: 0 0 1em; }
ul, ol { margin: 0; padding: 0; }
address { font-style: normal; }
:focus-visible { outline: 3px solid var(--steel-400); outline-offset: 3px; border-radius: 4px; }
::selection { background: var(--steel-200); color: var(--navy-900); }

.container { width: 100%; max-width: var(--container); margin-inline: auto; padding-inline: clamp(20px, 4vw, 40px); }
.sr-only { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.skip-link { position: absolute; left: 16px; top: -60px; z-index: 200; background: var(--navy); color: #fff; padding: 10px 16px; border-radius: 8px; text-decoration: none; transition: top .2s; }
.skip-link:focus { top: 12px; color: #fff; }

.ico { width: 1.35em; height: 1.35em; flex: none; }
.ico-sm { width: 1.05em; height: 1.05em; }
.ico-xs { width: .95em; height: .95em; }

/* ---------- Tipografía de sección ---------- */
.section { padding-block: clamp(72px, 10vw, 128px); }
.section-head { max-width: 760px; margin-bottom: clamp(36px, 5vw, 60px); }
.section-head-center { text-align: center; margin-inline: auto; }
.eyebrow { font-family: var(--f-head); font-size: .78rem; font-weight: 600; letter-spacing: .2em; line-height: 1.6; text-transform: uppercase; color: var(--steel-500); margin-bottom: 1.1rem; display: inline-flex; align-items: flex-start; gap: .75em; }
.eyebrow::before, .eyebrow::after { margin-top: .78em; flex: none; }
.eyebrow::before { content: ""; width: 28px; height: 2px; background: currentColor; display: inline-block; }
.section-head-center .eyebrow::after { content: ""; width: 28px; height: 2px; background: currentColor; display: inline-block; }
.eyebrow-light { color: var(--steel-300); }
.section-title { font-size: clamp(1.8rem, 1.2rem + 2.3vw, 2.85rem); font-weight: 650; }
.section-lead, .lead { font-size: clamp(1.06rem, 1rem + .3vw, 1.2rem); color: var(--muted); }
.lead { color: var(--text); }

/* ---------- Botones ---------- */
.btn { --bg: var(--navy); --fg: #fff; --bd: var(--navy); display: inline-flex; align-items: center; justify-content: center; gap: .55em; padding: .9em 1.45em; border-radius: 999px; border: 1.5px solid var(--bd); background: var(--bg); color: var(--fg); font-family: var(--f-head); font-weight: 600; font-size: .95rem; letter-spacing: .01em; text-decoration: none; cursor: pointer; transition: transform .2s var(--ease), background .2s, color .2s, box-shadow .2s, border-color .2s; white-space: nowrap; }
.btn:hover { transform: translateY(-1px); color: var(--fg); box-shadow: var(--shadow); }
.btn:active { transform: translateY(0); }
.btn .ico { transition: transform .2s var(--ease); }
.btn:hover .ico { transform: translateX(3px); }
.btn-primary:hover { --bg: var(--navy-700); --bd: var(--navy-700); }
.btn-light { --bg: #fff; --fg: var(--navy); --bd: #fff; }
.btn-light:hover { --bg: var(--steel-100); --bd: var(--steel-100); }
.btn-ghost { --bg: transparent; --fg: #fff; --bd: rgba(255, 255, 255, .45); }
.btn-ghost:hover { --bg: rgba(255, 255, 255, .1); --bd: #fff; }
.btn-sm { padding: .62em 1.15em; font-size: .86rem; }
.btn-lg { padding: 1.02em 1.8em; font-size: 1rem; }
.btn-block { width: 100%; }
.btn[disabled] { opacity: .65; cursor: progress; transform: none; box-shadow: none; }

/* ---------- Header ---------- */
.site-header { position: fixed; inset: 0 0 auto; z-index: 100; height: var(--header-h); transition: background .3s, box-shadow .3s, backdrop-filter .3s;
  --lz-navy: #fff; --lz-legl: #A9BCCD; --lz-legr: #8AA1B8; --lz-apex: #6E849B; --lz-word: #fff; --lz-sub: #C9D3DE; --lz-rule: rgba(255,255,255,.35); }
.site-header.is-solid, .site-header.is-scrolled, body.nav-open .site-header { background: rgba(255, 255, 255, .94); backdrop-filter: saturate(160%) blur(14px); -webkit-backdrop-filter: saturate(160%) blur(14px); box-shadow: 0 1px 0 var(--line), 0 6px 24px -12px rgba(15, 29, 46, .18);
  --lz-navy: #15263A; --lz-legl: #8199AF; --lz-legr: #67809A; --lz-apex: #4A5F75; --lz-word: #1B2230; --lz-sub: #4A505B; --lz-rule: #A9AFB9; }
.header-inner { height: 100%; display: flex; align-items: center; gap: 28px; }
.brand { display: block; flex: none; line-height: 0; }
.logo-svg { height: 56px; width: auto; }
.logo-svg * { transition: fill .3s; }
.main-nav { margin-left: auto; }
.main-nav ul { display: flex; gap: clamp(14px, 1.8vw, 30px); list-style: none; }
.main-nav a { position: relative; font-family: var(--f-head); font-size: .9rem; font-weight: 550; color: #fff; text-decoration: none; padding: 6px 0; transition: color .2s; }
.main-nav a::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: currentColor; transform: scaleX(0); transform-origin: left; transition: transform .25s var(--ease); }
.main-nav a:hover::after, .main-nav a.is-active::after { transform: scaleX(1); }
.is-solid .main-nav a, .is-scrolled .main-nav a { color: var(--ink); }
.is-solid .main-nav a:hover, .is-scrolled .main-nav a:hover, .main-nav a.is-active { color: var(--steel-600); }
.site-header:not(.is-solid):not(.is-scrolled) .main-nav a.is-active { color: #fff; }
.header-actions { display: flex; align-items: center; gap: 12px; }
.site-header:not(.is-solid):not(.is-scrolled) .header-cta { --bg: #fff; --fg: var(--navy); --bd: #fff; }

.lang { position: relative; }
.lang-btn { display: inline-flex; align-items: center; gap: 6px; height: 40px; padding: 0 12px; border-radius: 999px; border: 1.5px solid rgba(255, 255, 255, .4); background: transparent; color: #fff; font-family: var(--f-head); font-weight: 600; font-size: .85rem; cursor: pointer; transition: border-color .2s, color .2s, background .2s; }
.lang-btn:hover { background: rgba(255, 255, 255, .1); }
.is-solid .lang-btn, .is-scrolled .lang-btn { color: var(--ink); border-color: var(--line); }
.is-solid .lang-btn:hover, .is-scrolled .lang-btn:hover { background: var(--paper); }
.lang-btn .ico-sm { transition: transform .2s; }
.lang.is-open .lang-btn .ico-sm { transform: rotate(180deg); }
.lang-menu { position: absolute; right: 0; top: calc(100% + 10px); min-width: 190px; list-style: none; background: #fff; border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow); padding: 6px; opacity: 0; visibility: hidden; transform: translateY(-6px); transition: opacity .18s, transform .18s, visibility .18s; }
.lang.is-open .lang-menu { opacity: 1; visibility: visible; transform: none; }
.lang-menu a { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border-radius: 8px; color: var(--ink); text-decoration: none; font-size: .93rem; }
.lang-menu a:hover { background: var(--paper); }
.lang-menu a[aria-current] { background: var(--steel-100); font-weight: 600; }
.lang-code { font-family: var(--f-head); font-size: .72rem; font-weight: 700; letter-spacing: .08em; color: var(--steel-500); width: 22px; }

.nav-toggle { display: none; width: 44px; height: 44px; border-radius: 12px; border: 1.5px solid rgba(255, 255, 255, .4); background: transparent; color: #fff; cursor: pointer; align-items: center; justify-content: center; }
.is-solid .nav-toggle, .is-scrolled .nav-toggle, body.nav-open .nav-toggle { color: var(--ink); border-color: var(--line); }
.nav-toggle .ico-close { display: none; }
body.nav-open .nav-toggle .ico-open { display: none; }
body.nav-open .nav-toggle .ico-close { display: block; }

.mobile-nav { position: fixed; inset: var(--header-h) 0 0; z-index: 99; background: #fff; padding: 24px clamp(20px, 4vw, 40px) 40px; overflow-y: auto; border-top: 1px solid var(--line); animation: slideDown .25s var(--ease); }
.mobile-nav ul { list-style: none; margin-bottom: 24px; }
.mobile-nav li a { display: block; padding: 14px 0; font-family: var(--f-head); font-size: 1.25rem; font-weight: 600; color: var(--ink); text-decoration: none; border-bottom: 1px solid var(--line); }
.mobile-langs { display: flex; gap: 8px; margin-bottom: 24px; flex-wrap: wrap; }
.mobile-langs a { flex: 1; text-align: center; padding: 10px 12px; border: 1.5px solid var(--line); border-radius: 10px; color: var(--ink); text-decoration: none; font-weight: 500; font-size: .95rem; }
.mobile-langs a[aria-current] { border-color: var(--navy); background: var(--navy); color: #fff; }
@keyframes slideDown { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: none; } }

/* ---------- Hero ---------- */
.hero { position: relative; min-height: min(100svh, 980px); display: flex; flex-direction: column; justify-content: flex-end; padding-top: calc(var(--header-h) + 60px); padding-bottom: 40px; color: #fff; overflow: hidden; background: var(--navy-900); isolation: isolate; }
.hero-media { position: absolute; inset: 0; z-index: -2; }
.hero-media img { width: 100%; height: 100%; object-fit: cover; object-position: center 40%; filter: saturate(.55) contrast(1.05); transform: scale(1.04); animation: heroZoom 18s ease-out forwards; }
.hero::before { content: ""; position: absolute; inset: 0; z-index: -1; background:
  linear-gradient(100deg, rgba(10, 20, 34, .96) 0%, rgba(13, 26, 42, .88) 38%, rgba(21, 38, 58, .55) 70%, rgba(21, 38, 58, .35) 100%),
  linear-gradient(0deg, rgba(10, 20, 34, .9) 0%, rgba(10, 20, 34, 0) 45%); }
.hero-grid { position: absolute; inset: 0; z-index: -1; background-image: linear-gradient(rgba(255,255,255,.045) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.045) 1px, transparent 1px); background-size: 56px 56px; mask-image: linear-gradient(100deg, #000 0%, transparent 65%); -webkit-mask-image: linear-gradient(100deg, #000 0%, transparent 65%); }
@keyframes heroZoom { to { transform: scale(1); } }
.hero-inner { max-width: var(--container); margin-bottom: clamp(48px, 7vw, 88px); }
.hero-title { color: #fff; font-size: clamp(2.15rem, 1.1rem + 4.3vw, 4.35rem); font-weight: 650; line-height: 1.06; letter-spacing: -.02em; max-width: 15.5em; margin-bottom: .45em; text-wrap: balance; }
.hero-lead { font-size: clamp(1.06rem, 1rem + .45vw, 1.3rem); color: rgba(255, 255, 255, .82); max-width: 40em; margin-bottom: 2.1rem; }
.hero-ctas { display: flex; flex-wrap: wrap; gap: 14px; }
.hero-facts { list-style: none; display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid rgba(255, 255, 255, .18); }
.hero-facts li { padding: 22px 22px 6px 0; display: flex; flex-direction: column; gap: 4px; }
.hero-facts li + li { padding-left: 22px; border-left: 1px solid rgba(255, 255, 255, .12); }
.hero-facts strong { font-family: var(--f-head); font-weight: 600; font-size: 1.02rem; color: #fff; letter-spacing: .01em; }
.hero-facts span { font-size: .9rem; color: rgba(255, 255, 255, .62); }

/* ---------- Trust ---------- */
.trust { background: var(--paper); border-bottom: 1px solid var(--line); padding-block: 38px 30px; }
.trust-inner { text-align: center; }
.trust-label { font-family: var(--f-head); font-size: .8rem; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); font-weight: 600; margin-bottom: 18px; }
.trust-names { list-style: none; display: flex; flex-wrap: wrap; justify-content: center; gap: 12px clamp(28px, 6vw, 80px); margin-bottom: 16px; }
.trust-names li { font-family: var(--f-head); font-size: clamp(1.2rem, 1rem + .9vw, 1.65rem); font-weight: 700; color: var(--steel-600); letter-spacing: -.01em; opacity: .85; }
.trust-note { font-size: .76rem; color: var(--muted); max-width: 760px; margin: 0 auto; opacity: .85; }

/* ---------- About ---------- */
.about-grid { display: grid; grid-template-columns: 1fr 1.05fr; gap: clamp(36px, 6vw, 88px); align-items: center; }
.about-media { position: relative; }
.about-media img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; border-radius: var(--radius); box-shadow: var(--shadow-lg); background: var(--steel-100); }
.about-media::before { content: ""; position: absolute; inset: -18px auto auto -18px; width: 46%; height: 46%; border-top: 2px solid var(--steel-300); border-left: 2px solid var(--steel-300); border-radius: 18px 0 0 0; z-index: -1; }
.about-badge { position: absolute; right: -20px; bottom: 32px; display: flex; gap: 14px; align-items: center; background: var(--navy); color: #fff; padding: 18px 22px; border-radius: var(--radius); box-shadow: var(--shadow-lg); max-width: 300px; }
.about-badge-mark { width: 44px; height: 44px; border-radius: 12px; background: rgba(255,255,255,.08); display: grid; place-items: center; color: var(--steel-300); flex: none; }
.about-badge strong { display: block; font-family: var(--f-head); font-size: 1rem; }
.about-badge span { font-size: .85rem; color: rgba(255,255,255,.7); line-height: 1.4; display: block; }
.about-text p { max-width: 62ch; }
.pillars { list-style: none; display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; margin-top: clamp(56px, 7vw, 88px); }
.pillar { padding: 26px 24px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; transition: border-color .25s, box-shadow .25s, transform .25s var(--ease); }
.pillar:hover { border-color: var(--steel-300); box-shadow: var(--shadow); transform: translateY(-3px); }
.pillar-num { font-family: var(--f-head); font-size: .8rem; font-weight: 700; color: var(--steel-400); letter-spacing: .1em; display: block; margin-bottom: 14px; }
.pillar h3 { font-size: 1.08rem; margin-bottom: .4em; }
.pillar p { font-size: .95rem; color: var(--muted); margin: 0; }
.mv { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-top: 20px; }
.mv-card { padding: 30px 32px; border-radius: var(--radius); background: var(--paper); border-left: 4px solid var(--steel-400); }
.mv-card h3 { font-size: .8rem; letter-spacing: .2em; text-transform: uppercase; color: var(--steel-500); margin-bottom: .8em; }
.mv-card p { margin: 0; font-size: 1.06rem; color: var(--ink); font-family: var(--f-head); font-weight: 500; line-height: 1.5; }
.mv-card-dark { background: var(--navy); border-left-color: var(--steel-300); }
.mv-card-dark h3 { color: var(--steel-300); }
.mv-card-dark p { color: #fff; }

/* ---------- Servicios ---------- */
.services { background: linear-gradient(180deg, var(--paper), #fff 70%); }
.service-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; align-items: start; }
.service { position: relative; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 30px 28px 22px; box-shadow: var(--shadow-sm); transition: border-color .25s, box-shadow .25s, transform .25s var(--ease); overflow: hidden; }
.service::before { content: ""; position: absolute; left: 0; top: 0; height: 3px; width: 100%; background: linear-gradient(90deg, var(--navy), var(--steel-400)); transform: scaleX(0); transform-origin: left; transition: transform .35s var(--ease); }
.service:hover { border-color: var(--steel-200); box-shadow: var(--shadow); transform: translateY(-3px); }
.service:hover::before, .service:has(details[open])::before { transform: scaleX(1); }
.service-thumb { margin: 0 0 18px; aspect-ratio: 5 / 2; overflow: hidden; border-radius: 10px; background: var(--steel-100); }
.service-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ease); }
.service:hover .service-thumb img { transform: scale(1.05); }
.service::before { z-index: 1; }
.btn-download { margin-top: 6px; }
.cta-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.footer-pf { color: rgba(255, 255, 255, .72); }
.footer-pf a { font-weight: 600; margin-left: 4px; }
.service h3 { font-size: 1.15rem; margin-bottom: .45em; }
.service > p { color: var(--muted); font-size: .97rem; margin-bottom: 14px; }
.service details { border-top: 1px solid var(--line); padding-top: 12px; }
.service summary { list-style: none; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; font-family: var(--f-head); font-weight: 600; font-size: .88rem; color: var(--navy-700); padding: 4px 0; user-select: none; }
.service summary::-webkit-details-marker { display: none; }
.service summary .ico { transition: transform .25s; }
.service details[open] summary .ico { transform: rotate(180deg); }
.service summary:hover { color: var(--steel-500); }
.checklist { list-style: none; margin: 12px 0 14px; display: grid; gap: 8px; }
.checklist li { display: flex; gap: 10px; font-size: .93rem; line-height: 1.45; color: var(--text); }
.checklist .ico { color: var(--steel-500); margin-top: .22em; }
.deliv { font-size: .86rem; color: var(--muted); background: var(--paper); border-radius: 8px; padding: 10px 12px; margin: 0 0 6px; }
.deliv strong { color: var(--ink); font-weight: 600; }

/* ---------- Civil ---------- */
.civil { background: var(--navy-900); color: rgba(255, 255, 255, .78); position: relative; overflow: hidden; }
.civil::before { content: ""; position: absolute; inset: 0; background-image: linear-gradient(rgba(255,255,255,.035) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.035) 1px, transparent 1px); background-size: 48px 48px; mask-image: radial-gradient(ellipse at 80% 20%, #000, transparent 70%); -webkit-mask-image: radial-gradient(ellipse at 80% 20%, #000, transparent 70%); pointer-events: none; }
.civil-grid { position: relative; display: grid; grid-template-columns: .85fr 1.15fr; gap: clamp(36px, 6vw, 80px); align-items: center; }
.civil-media { position: relative; }
.civil-media img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; border-radius: var(--radius); background: var(--navy-700); box-shadow: var(--shadow-lg); }
.civil-codes { position: absolute; left: 16px; right: 16px; bottom: 16px; margin: 0; padding: 12px 16px; border-radius: 10px; background: rgba(10, 20, 34, .82); backdrop-filter: blur(6px); color: var(--steel-200); font-family: var(--f-head); font-size: .78rem; font-weight: 600; letter-spacing: .06em; text-align: center; }
.civil .section-title { color: #fff; }
.civil .section-lead { color: rgba(255, 255, 255, .72); }
.civil-points { list-style: none; display: grid; grid-template-columns: 1fr 1fr; gap: 18px; margin-top: 34px; }
.civil-points li { padding: 22px 22px 20px; border: 1px solid rgba(255, 255, 255, .12); border-radius: var(--radius); background: rgba(255, 255, 255, .03); transition: background .25s, border-color .25s; }
.civil-points li:hover { background: rgba(255, 255, 255, .06); border-color: rgba(255, 255, 255, .22); }
.civil-points h3 { color: #fff; font-size: 1.04rem; margin-bottom: .4em; }
.civil-points h3::before { content: ""; display: block; width: 28px; height: 3px; border-radius: 2px; background: var(--steel-400); margin-bottom: 14px; }
.civil-points p { margin: 0; font-size: .93rem; }

/* ---------- Mercados ---------- */
.market-grid { list-style: none; display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.market { position: relative; min-height: 360px; border-radius: var(--radius); overflow: hidden; display: flex; align-items: flex-end; isolation: isolate; background: var(--navy-700); box-shadow: var(--shadow-sm); }
.market img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; transition: transform .8s var(--ease); }
.market::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(10, 20, 34, .05) 20%, rgba(10, 20, 34, .55) 55%, rgba(10, 20, 34, .94) 100%); transition: background .4s; }
.market:hover img { transform: scale(1.06); }
.market:hover::after { background: linear-gradient(180deg, rgba(21, 38, 58, .25) 0%, rgba(21, 38, 58, .75) 45%, rgba(10, 20, 34, .96) 100%); }
.market-body { padding: 26px 26px 24px; color: rgba(255, 255, 255, .82); }
.market-body h3 { color: #fff; font-size: 1.22rem; margin-bottom: .45em; }
.market-body p { margin: 0; font-size: .95rem; line-height: 1.55; }

/* ---------- Ciclo de vida ---------- */
.lifecycle { background: var(--paper); }
.timeline { list-style: none; display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; counter-reset: s; position: relative; }
.step { position: relative; padding: 0 26px 40px 0; }
.step::before { content: ""; position: absolute; top: 23px; left: 48px; right: 0; height: 2px; background: repeating-linear-gradient(90deg, var(--steel-300) 0 8px, transparent 8px 14px); }
.step:nth-child(4n)::before { right: 26px; background: linear-gradient(90deg, var(--steel-300), transparent); }
.step-num { position: relative; z-index: 1; width: 48px; height: 48px; border-radius: 50%; background: #fff; border: 2px solid var(--navy); display: grid; place-items: center; font-family: var(--f-head); font-weight: 700; font-size: .9rem; color: var(--navy); margin-bottom: 20px; transition: background .25s, color .25s; }
.step:hover .step-num { background: var(--navy); color: #fff; }
.step:first-child .step-num, .step:nth-child(7) .step-num { background: var(--navy); color: #fff; }
.step h3 { font-size: 1.06rem; margin-bottom: .4em; }
.step p { font-size: .93rem; color: var(--muted); margin: 0; }

/* ---------- Normas ---------- */
.standards-grid { display: grid; grid-template-columns: .9fr 1.1fr; gap: clamp(36px, 6vw, 80px); align-items: start; }
.standards-intro { position: sticky; top: calc(var(--header-h) + 30px); }
.standards-media { margin-top: 30px; }
.standards-media img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; border-radius: var(--radius); box-shadow: var(--shadow); background: var(--steel-100); }
.regions { display: grid; gap: 16px; }
.region { padding: 24px 26px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; transition: border-color .25s, box-shadow .25s; }
.region:hover { border-color: var(--steel-300); box-shadow: var(--shadow-sm); }
.region h3 { font-size: 1rem; margin-bottom: 14px; display: flex; align-items: center; gap: 10px; }
.region h3::before { content: ""; width: 10px; height: 10px; border-radius: 3px; background: var(--navy); transform: rotate(45deg); }
.chips { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; }
.chips li { font-family: var(--f-head); font-size: .82rem; font-weight: 600; color: var(--navy); background: var(--steel-100); border-radius: 999px; padding: 6px 13px; }
.region-tools { background: var(--navy); border-color: var(--navy); }
.region-tools h3 { color: #fff; }
.region-tools h3::before { background: var(--steel-300); }
.chips-soft li { background: rgba(255, 255, 255, .08); color: var(--steel-100); border: 1px solid rgba(255, 255, 255, .12); }

/* ---------- Por qué ---------- */
.why-grid { list-style: none; display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.why-item { background: #fff; padding: 36px 32px; transition: background .25s; }
.why-item:hover { background: var(--paper); }
.why-icon { width: 50px; height: 50px; border-radius: 50%; display: grid; place-items: center; border: 1.5px solid var(--steel-300); color: var(--navy); margin-bottom: 20px; }
.why-icon .ico { width: 24px; height: 24px; }
.why-item h3 { font-size: 1.1rem; margin-bottom: .45em; }
.why-item p { margin: 0; color: var(--muted); font-size: .96rem; }

/* ---------- CTA ---------- */
.cta-band { position: relative; isolation: isolate; overflow: hidden; background: var(--navy); color: #fff; padding-block: clamp(64px, 9vw, 110px); }
.cta-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; filter: grayscale(.4); }
.cta-band::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, rgba(15, 29, 46, .95) 0%, rgba(21, 38, 58, .82) 55%, rgba(21, 38, 58, .55) 100%); }
.cta-inner { display: flex; align-items: center; justify-content: space-between; gap: 32px; flex-wrap: wrap; }
.cta-inner h2 { color: #fff; font-size: clamp(1.8rem, 1.2rem + 2.2vw, 2.7rem); margin-bottom: .3em; }
.cta-inner p { margin: 0; color: rgba(255, 255, 255, .8); font-size: 1.12rem; max-width: 36em; }

/* ---------- Contacto ---------- */
.contact-grid { display: grid; grid-template-columns: .78fr 1.22fr; gap: clamp(24px, 4vw, 44px); align-items: start; }
.contact-card { background: var(--navy); color: rgba(255, 255, 255, .8); border-radius: var(--radius); padding: clamp(28px, 3.5vw, 40px); position: sticky; top: calc(var(--header-h) + 24px); overflow: hidden; }
.contact-card::after { content: ""; position: absolute; right: -60px; bottom: -60px; width: 220px; height: 220px; background: url("../img/mark.svg") no-repeat center / contain; opacity: .06; filter: brightness(10); pointer-events: none; }
.contact-card h3 { color: #fff; font-size: 1.25rem; margin-bottom: 26px; }
.contact-list { list-style: none; display: grid; gap: 22px; position: relative; z-index: 1; }
.contact-list li { display: flex; gap: 16px; }
.contact-ico { width: 44px; height: 44px; flex: none; border-radius: 12px; background: rgba(255, 255, 255, .08); color: var(--steel-300); display: grid; place-items: center; }
.contact-label { display: block; font-family: var(--f-head); font-size: .72rem; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; color: var(--steel-300); margin-bottom: 3px; }
.contact-list a { color: #fff; text-decoration: none; font-weight: 500; word-break: break-word; }
.contact-list a:hover { text-decoration: underline; color: #fff; }
.contact-list address { color: #fff; line-height: 1.5; margin-bottom: 6px; }
.link-arrow { display: inline-flex; align-items: center; gap: 6px; font-size: .9rem; color: var(--steel-200) !important; }

.quote-form { position: relative; display: grid; grid-template-columns: 1fr 1fr; gap: 18px 20px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(24px, 3.5vw, 40px); box-shadow: var(--shadow); }
.field { display: flex; flex-direction: column; gap: 7px; min-width: 0; border: 0; padding: 0; margin: 0; }
.field-full { grid-column: 1 / -1; }
.label { font-family: var(--f-head); font-size: .84rem; font-weight: 600; color: var(--ink); padding: 0; }
.req { color: var(--err); }
.opt { font-family: var(--f-body); font-weight: 400; color: var(--muted); font-size: .8rem; }
.quote-form input[type=text], .quote-form input[type=email], .quote-form input[type=tel], .quote-form select, .quote-form textarea {
  width: 100%; font: inherit; font-size: 1rem; color: var(--ink); background: var(--paper); border: 1.5px solid transparent; border-radius: var(--radius-sm); padding: 12px 14px; transition: border-color .2s, background .2s, box-shadow .2s; appearance: none; -webkit-appearance: none; }
.quote-form textarea { resize: vertical; min-height: 140px; line-height: 1.5; }
.quote-form input:hover, .quote-form select:hover, .quote-form textarea:hover { border-color: var(--steel-200); }
.quote-form input:focus, .quote-form select:focus, .quote-form textarea:focus { outline: none; background: #fff; border-color: var(--steel-500); box-shadow: 0 0 0 4px rgba(103, 128, 154, .18); }
.quote-form ::placeholder { color: #8A94A3; }
.select { position: relative; }
.select select { padding-right: 40px; cursor: pointer; }
.select .ico { position: absolute; right: 14px; top: 50%; transform: translateY(-50%); pointer-events: none; color: var(--steel-500); }
.field.has-error input, .field.has-error textarea, .field.has-error select { border-color: var(--err); background: #FFF8F7; }
.field-error { font-size: .82rem; color: var(--err); margin: 0; }

.segmented { display: flex; flex-wrap: wrap; gap: 8px; }
.segmented label { position: relative; cursor: pointer; }
.segmented input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.segmented span { display: inline-block; padding: 9px 16px; border-radius: 999px; border: 1.5px solid var(--line); font-size: .92rem; font-weight: 500; color: var(--text); transition: all .2s; }
.segmented label:hover span { border-color: var(--steel-300); }
.segmented input:checked + span { background: var(--navy); border-color: var(--navy); color: #fff; }
.segmented input:focus-visible + span { outline: 3px solid var(--steel-400); outline-offset: 2px; }

.dropzone { display: flex; align-items: center; gap: 14px; padding: 18px 20px; border: 1.5px dashed var(--steel-300); border-radius: var(--radius-sm); background: var(--paper); cursor: pointer; transition: border-color .2s, background .2s; color: var(--steel-600); }
.dropzone:hover, .dropzone.is-drag { border-color: var(--navy); background: var(--steel-100); }
.dropzone .ico { width: 26px; height: 26px; }
.dropzone strong { display: block; font-family: var(--f-head); font-size: .92rem; color: var(--navy); }
.dropzone small { display: block; font-size: .8rem; color: var(--muted); line-height: 1.4; }
#f-files:focus-visible + .file-list, .field:focus-within .dropzone { border-color: var(--steel-500); }
.file-list { list-style: none; display: grid; gap: 6px; }
.file-list:empty { display: none; }
.file-list li { display: flex; align-items: center; justify-content: space-between; gap: 10px; font-size: .88rem; padding: 8px 12px; background: var(--steel-100); border-radius: 8px; }
.file-list li span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.file-list small { color: var(--muted); margin-left: 6px; }
.file-list button { border: 0; background: none; color: var(--steel-600); cursor: pointer; font-size: .82rem; font-weight: 600; padding: 4px 6px; border-radius: 6px; }
.file-list button:hover { background: #fff; color: var(--err); }

.check { display: flex; gap: 12px; align-items: flex-start; font-size: .93rem; line-height: 1.5; cursor: pointer; }
.check input { appearance: none; -webkit-appearance: none; flex: none; width: 22px; height: 22px; margin: 1px 0 0; border: 1.5px solid var(--steel-400); border-radius: 6px; background: #fff; cursor: pointer; display: grid; place-items: center; transition: background .2s, border-color .2s; }
.check input::after { content: ""; width: 11px; height: 6px; border-left: 2px solid #fff; border-bottom: 2px solid #fff; transform: rotate(-45deg) translate(1px, -1px); opacity: 0; }
.check input:checked { background: var(--navy); border-color: var(--navy); }
.check input:checked::after { opacity: 1; }
.field.has-error .check input { border-color: var(--err); }
.notice { font-size: .78rem; color: var(--muted); line-height: 1.5; margin: 6px 0 0 34px; }

.form-footer { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding-top: 6px; }
.req-note { margin: 0; font-size: .82rem; color: var(--muted); }
.form-status { padding: 14px 16px; border-radius: 10px; font-size: .93rem; background: #FEF3F2; color: var(--err); border: 1px solid #FECDCA; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-success { position: absolute; inset: 0; z-index: 2; background: #fff; border-radius: var(--radius); display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 40px; animation: fadeIn .4s var(--ease); }
.form-success[hidden] { display: none; }
.form-success h3 { font-size: 1.5rem; margin: 18px 0 .4em; }
.form-success p { color: var(--muted); max-width: 30em; }
.success-ico { width: 64px; height: 64px; border-radius: 50%; display: grid; place-items: center; background: #E8F5EF; color: var(--ok); }
.success-ico .ico { width: 32px; height: 32px; }
@keyframes fadeIn { from { opacity: 0; transform: scale(.98); } to { opacity: 1; transform: none; } }

/* ---------- Footer ---------- */
.site-footer { background: var(--navy-950); color: rgba(255, 255, 255, .66); font-size: .93rem; padding-top: clamp(56px, 7vw, 84px); }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1.25fr 1.15fr; gap: 40px; padding-bottom: 48px; }
.footer-logo img { width: 260px; height: auto; margin-bottom: 18px; }
.footer-brand p { max-width: 34ch; }
.footer-title { color: #fff; font-size: .78rem; letter-spacing: .18em; text-transform: uppercase; font-weight: 600; margin-bottom: 18px; }
.footer-title-legal { margin-top: 28px; }
.footer-links { list-style: none; display: grid; gap: 10px; }
.footer-links a, .footer-contact a { color: rgba(255, 255, 255, .72); text-decoration: none; transition: color .2s; }
.footer-links a:hover, .footer-contact a:hover { color: #fff; }
.footer-contact { list-style: none; display: grid; gap: 14px; }
.footer-contact li { display: flex; gap: 10px; align-items: flex-start; }
.footer-contact .ico { color: var(--steel-400); margin-top: 2px; width: 1.15em; height: 1.15em; }
.social { display: inline-grid; place-items: center; width: 40px; height: 40px; border-radius: 10px; background: rgba(255,255,255,.08); color: #fff; }
.footer-bottom { border-top: 1px solid rgba(255, 255, 255, .1); padding-block: 22px 28px; display: flex; justify-content: space-between; gap: 12px 24px; flex-wrap: wrap; font-size: .82rem; }
.footer-bottom p { margin: 0; }
.footer-note { color: rgba(255, 255, 255, .45); }

.to-top { position: fixed; right: 20px; bottom: 20px; z-index: 90; width: 46px; height: 46px; border-radius: 50%; background: var(--navy); color: #fff; display: grid; place-items: center; box-shadow: var(--shadow); opacity: 0; visibility: hidden; transform: translateY(10px); transition: all .25s var(--ease); }
.to-top.is-visible { opacity: 1; visibility: visible; transform: none; }
.to-top:hover { background: var(--steel-600); color: #fff; }

/* ---------- Páginas internas ---------- */
.page-hero { background: var(--navy-900); color: #fff; padding: calc(var(--header-h) + 64px) 0 56px; position: relative; overflow: hidden; }
.page-hero::before { content: ""; position: absolute; inset: 0; background-image: linear-gradient(rgba(255,255,255,.04) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.04) 1px, transparent 1px); background-size: 48px 48px; mask-image: linear-gradient(90deg, #000, transparent 75%); -webkit-mask-image: linear-gradient(90deg, #000, transparent 75%); }
.page-hero .container { position: relative; }
.page-hero h1 { color: #fff; font-size: clamp(1.9rem, 1.3rem + 2.5vw, 3rem); max-width: 22em; }
.page-meta { color: var(--steel-300); margin: 0; font-size: .92rem; }
.legal { padding-top: clamp(48px, 6vw, 72px); }
.legal-container { max-width: 860px; }
.legal-note { background: var(--paper); border-left: 4px solid var(--steel-400); padding: 14px 18px; border-radius: 8px; font-size: .92rem; }
.prose h2 { font-size: 1.3rem; margin: 2em 0 .7em; padding-top: .4em; }
.prose ul { padding-left: 1.3em; margin-bottom: 1.2em; display: grid; gap: .4em; }
.prose li::marker { color: var(--steel-500); }
.prose p, .prose li { color: var(--text); }
.simple-page { min-height: 80vh; display: grid; place-items: center; padding: calc(var(--header-h) + 60px) 0 80px; background: var(--paper); }
.simple-inner { text-align: center; max-width: 640px; }
.simple-inner h1 { font-size: clamp(1.8rem, 1.3rem + 2vw, 2.6rem); margin-top: 22px; }
.simple-inner p { color: var(--muted); font-size: 1.1rem; margin-bottom: 1.8em; }
.success-ico-lg { margin-inline: auto; width: 80px; height: 80px; }
.simple-code { font-family: var(--f-head); font-size: clamp(4rem, 10vw, 7rem); font-weight: 700; color: var(--steel-300); line-height: 1; margin: 0; }
.simple-alt { margin-top: 1.5em; display: flex; gap: 20px; justify-content: center; font-size: .92rem; }

/* ---------- Animaciones de aparición ---------- */
.js .reveal { opacity: 0; transform: translateY(18px); transition: opacity .7s var(--ease), transform .7s var(--ease); transition-delay: var(--d, 0ms); }
.js .reveal.is-in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  .js .reveal { opacity: 1; transform: none; }
}

/* ---------- Responsive ---------- */
@media (max-width: 1180px) {
  .main-nav ul { gap: 18px; }
  .main-nav a { font-size: .85rem; }
}
@media (max-width: 1080px) {
  .main-nav, .header-cta { display: none; }
  .nav-toggle { display: inline-flex; }
  .header-actions { margin-left: auto; }
  .hero-facts { grid-template-columns: repeat(2, 1fr); }
  .hero-facts li:nth-child(3) { padding-left: 0; border-left: 0; }
  .hero-facts li:nth-child(n+3) { border-top: 1px solid rgba(255,255,255,.12); }
  .about-grid, .civil-grid, .standards-grid, .contact-grid { grid-template-columns: 1fr; }
  .about-media img { aspect-ratio: 16 / 11; }
  .about-badge { right: 16px; bottom: 16px; }
  .civil-media img { aspect-ratio: 16 / 9; }
  .standards-intro { position: static; }
  .contact-card { position: relative; top: auto; }
  .pillars { grid-template-columns: repeat(2, 1fr); }
  .service-grid, .market-grid, .why-grid { grid-template-columns: repeat(2, 1fr); }
  .timeline { grid-template-columns: repeat(2, 1fr); }
  .step:nth-child(2n)::before { right: 26px; background: linear-gradient(90deg, var(--steel-300), transparent); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 680px) {
  :root { --header-h: 74px; }
  body { font-size: 1rem; }
  .logo-svg { height: 42px; }
  .lang-btn span { display: none; }
  .lang-btn { padding: 0 10px; }
  .hero { min-height: auto; padding-top: calc(var(--header-h) + 72px); }
  .hero-ctas .btn { width: 100%; }
  .hero-facts { grid-template-columns: 1fr 1fr; }
  .hero-facts li { padding: 16px 12px 4px 0 !important; border-left: 0 !important; }
  .hero-facts li:nth-child(even) { padding-left: 12px !important; border-left: 1px solid rgba(255,255,255,.12) !important; }
  .hero-facts strong { font-size: .92rem; }
  .hero-facts span { font-size: .8rem; }
  .pillars, .mv, .service-grid, .market-grid, .why-grid, .civil-points { grid-template-columns: 1fr; }
  .market { min-height: 300px; }
  .timeline { grid-template-columns: 1fr; padding-left: 0; }
  .step { padding: 0 0 30px 70px; }
  .step::before, .step:nth-child(2n)::before, .step:nth-child(4n)::before { top: 48px; bottom: 0; left: 23px; right: auto; width: 2px; height: auto; background: repeating-linear-gradient(180deg, var(--steel-300) 0 8px, transparent 8px 14px); }
  .step:last-child::before { display: none; }
  .step-num { position: absolute; left: 0; top: 0; }
  .quote-form { grid-template-columns: 1fr; }
  .form-footer .btn { width: 100%; }
  .notice { margin-left: 0; }
  .about-badge { position: relative; right: auto; bottom: auto; margin: -36px 16px 0; max-width: none; }
  .cta-inner .btn, .cta-actions { width: 100%; }
  .footer-grid { grid-template-columns: 1fr; gap: 32px; }
  .why-item { padding: 28px 24px; }
}

/* ---------- Aviso de cookies ---------- */
.cookie { position: fixed; left: 16px; right: 16px; bottom: 16px; z-index: 150; display: flex; justify-content: center; pointer-events: none; }
.cookie[hidden] { display: none; }
.cookie-inner { pointer-events: auto; width: 100%; max-width: 980px; background: #fff; border: 1px solid var(--line); border-radius: 16px; box-shadow: 0 24px 60px -18px rgba(10, 20, 34, .45); padding: 22px 24px; display: grid; grid-template-columns: 1fr auto; gap: 16px 28px; align-items: center; animation: slideUp .35s var(--ease); }
@keyframes slideUp { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }
.cookie h2 { font-size: 1.02rem; margin-bottom: .3em; }
.cookie p { font-size: .88rem; margin: 0; color: var(--muted); line-height: 1.55; }
.cookie-actions { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.btn-outline { --bg: #fff; --fg: var(--navy); --bd: var(--steel-200); }
.btn-outline:hover { --bg: var(--paper); --bd: var(--steel-400); }
.cookie-prefs { grid-column: 1 / -1; display: grid; gap: 10px; }
.cookie-prefs[hidden] { display: none; }
.cookie-opt { display: flex; justify-content: space-between; gap: 18px; align-items: center; padding: 12px 14px; background: var(--paper); border-radius: 10px; cursor: pointer; }
.cookie-opt strong { display: block; font-family: var(--f-head); font-size: .9rem; color: var(--ink); }
.cookie-opt small { display: block; font-size: .8rem; color: var(--muted); line-height: 1.45; }
.switch { position: relative; flex: none; width: 44px; height: 26px; }
.switch input { position: absolute; inset: 0; opacity: 0; margin: 0; cursor: pointer; z-index: 1; }
.switch i { position: absolute; inset: 0; border-radius: 999px; background: var(--steel-200); transition: background .2s; }
.switch i::after { content: ""; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.25); transition: transform .2s var(--ease); }
.switch input:checked + i { background: var(--navy); }
.switch input:checked + i::after { transform: translateX(18px); }
.switch input:disabled + i { opacity: .55; }
.switch input:focus-visible + i { outline: 3px solid var(--steel-400); outline-offset: 2px; }
.linklike { background: none; border: 0; padding: 0; font: inherit; color: rgba(255, 255, 255, .72); cursor: pointer; text-align: left; }
.linklike:hover { color: #fff; text-decoration: underline; }
@media (max-width: 760px) {
  .cookie { left: 8px; right: 8px; bottom: 8px; }
  .cookie-inner { grid-template-columns: 1fr; padding: 18px; max-height: 80vh; overflow-y: auto; }
  .cookie-actions { justify-content: stretch; }
  .cookie-actions .btn { flex: 1 1 calc(50% - 8px); }
  .cookie-actions [data-cookie-accept] { flex-basis: 100%; order: -1; }
}
.btn[hidden] { display: none !important; }
