/* 2+2 · maquetación de las páginas del sitio.
   Va después de 2mas2-variables.css, 2mas2-componentes.css y 2mas2-web.css.
   Las medidas salen de diseno/referencia/ (celular a 390 px, escritorio a 1440 px).
   Cortes: tipografía y espacios de celular hasta 767 px; menú de celular hasta 1099 px. */

h1, h2, h3, p { margin: 0; }
a, button { touch-action: manipulation; }
img { max-width: 100%; }

/* ---------- Contenedor y secciones ---------- */
.contenedor { max-width: 1200px; margin: 0 auto; padding-left: 32px; padding-right: 32px; box-sizing: border-box; }
.seccion { padding: 96px 0; background: var(--papel); }
.seccion--superficie { background: var(--superficie); border-top: 1px solid var(--linea); }
.seccion--tinta { background: var(--tinta); color: var(--papel); }

.columna { display: flex; flex-direction: column; gap: 48px; }
.fila { display: flex; flex-wrap: wrap; gap: 48px; }
.fila--centro { align-items: center; }
.fila--abajo { align-items: flex-end; }
.encabezado-seccion { display: flex; flex-direction: column; gap: 20px; }

/* ---------- Tipografía ---------- */
.titulo-portada, .titulo-interno, .titulo-seccion, .titulo-contacto, .titulo-qd, .panel__cifra, .dato__cifra, .menu__nav a {
  font-family: var(--font-display); font-stretch: 125%;
}
.titulo-portada { font-size: clamp(44px, 6.5vw, 96px); line-height: 1; font-weight: 900; letter-spacing: -0.015em; text-wrap: balance; }
.titulo-interno { font-size: 72px; line-height: 76px; font-weight: 900; letter-spacing: -0.015em; text-wrap: balance; }
.titulo-seccion { font-size: 56px; line-height: 60px; font-weight: 800; letter-spacing: -0.01em; text-wrap: balance; }
.titulo-contacto { font-size: 72px; line-height: 76px; font-weight: 800; letter-spacing: -0.01em; text-wrap: balance; color: var(--papel); }
.titulo-qd { font-size: clamp(52px, 9.4vw, 136px); line-height: 1; font-weight: 900; letter-spacing: -0.02em; color: var(--lima); }
.titulo-tarjeta { font-size: 24px; line-height: 30px; font-weight: 700; text-wrap: balance; }

.bajada { font-size: 20px; line-height: 30px; text-wrap: pretty; }
.texto { font-size: 18px; line-height: 28px; }
.texto-tarjeta { font-size: 16px; line-height: 25px; }
.chico { font-size: 14px; line-height: 20px; color: var(--texto-secundario); }
.secundario { color: var(--texto-secundario); }
.secundario-oscuro { color: var(--texto-secundario-oscuro); }

.ancho-520 { max-width: 520px; }
.ancho-560 { max-width: 560px; }
.ancho-620 { max-width: 620px; }
.ancho-640 { max-width: 640px; }
.ancho-760 { max-width: 760px; }
.ancho-900 { max-width: 900px; }

/* ---------- Botones en grupo ---------- */
.botones { display: flex; flex-wrap: wrap; gap: 14px; }
.botones--juntos { gap: 12px; }

/* ---------- Encabezados ---------- */
.encabezado { background: var(--papel); border-bottom: 1px solid var(--linea); }
.encabezado__fila { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 40px; padding-top: 12px; padding-bottom: 12px; }
.encabezado--grande { border-bottom: 0; }
.encabezado--grande .encabezado__fila { gap: 24px 40px; padding-top: 28px; padding-bottom: 0; }
.logo-chico { display: block; width: 84px; height: 38px; }
.logo-grande { display: block; width: 220px; height: 118px; }
.encabezado a[aria-label], .pie a[aria-label] { display: block; }

.nav-principal { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 28px; }
.nav-principal a:not(.dd-boton) { font-size: 16px; font-weight: 500; text-decoration: none; }

.boton-icono { width: 48px; height: 48px; border: 0; background: transparent; padding: 0; display: flex; align-items: center; justify-content: center; cursor: pointer; color: var(--tinta); }
.boton-icono svg { display: block; }
.boton-menu { display: none; }

/* ---------- Menú del celular ---------- */
.menu { position: fixed; inset: 0; z-index: 50; overflow-y: auto; background: var(--papel); color: var(--tinta); display: flex; flex-direction: column; box-sizing: border-box; overscroll-behavior: contain; }
.menu__barra { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 8px 20px; border-bottom: 1px solid var(--linea); }
.menu__nav { padding: 8px 20px 0 20px; display: flex; flex-direction: column; }
.menu__nav a { display: flex; align-items: center; justify-content: space-between; padding: 18px 0; border-bottom: 1px solid var(--linea); font-size: 24px; line-height: 30px; font-weight: 800; text-decoration: none; }
.menu__nav svg { display: block; flex-shrink: 0; }
.menu__pie { margin-top: auto; padding: 24px 20px 36px 20px; display: flex; flex-direction: column; gap: 16px; }
.menu__pie .dd-boton { width: 100%; min-height: 52px; }
.menu__correo { align-self: center; }

.correo { font-size: 16px; line-height: 1.3; font-weight: 700; text-decoration: underline; text-underline-offset: 4px; text-decoration-thickness: 2px; overflow-wrap: anywhere; }

/* ---------- Portada ---------- */
.portada { padding: 72px 0 96px 0; }
.portada__fila { align-items: stretch; }
.portada__texto { flex: 999 1 700px; min-width: 0; display: flex; flex-direction: column; justify-content: center; gap: 28px; }
.panel { flex: 1 1 380px; min-width: 0; max-width: 420px; background: var(--tinta); display: flex; flex-direction: column; }
.panel__cabeza { padding: 36px 36px 0 36px; }
.panel__textura { margin-top: 16px; padding: 20px 36px 24px 36px; }
.panel__cifra { font-size: 76px; line-height: 0.95; font-weight: 900; letter-spacing: -0.02em; color: var(--lima); }
.panel__cuerpo { padding: 16px 36px 36px 36px; display: flex; flex-direction: column; gap: 12px; }
.panel__frase { font-size: 24px; line-height: 32px; font-weight: 700; color: var(--papel); text-wrap: balance; }

/* ---------- Qué hacemos ---------- */
.tarjetas { display: flex; flex-wrap: wrap; gap: 20px; }
.tarjeta { flex: 1 1 240px; min-width: 0; background: var(--superficie); border: 1px solid var(--linea); padding: 28px; box-sizing: border-box; display: flex; flex-direction: column; gap: 16px; }
.tarjeta__icono { display: block; width: 56px; height: 56px; }
.tarjeta__plazo { margin-top: auto; padding-top: 16px; border-top: 1px solid var(--linea); display: flex; flex-direction: column; gap: 6px; }
.tarjeta__plazo-texto { font-size: 17px; line-height: 24px; font-weight: 700; }

/* ---------- Quick Deploy ---------- */
.qd__cabeza { padding-top: 96px; }
.qd__textura { margin-top: 20px; padding: 36px 0; }
.qd__cuerpo { padding-top: 40px; padding-bottom: 96px; }
.qd__intro { font-size: 22px; line-height: 33px; color: var(--papel); max-width: 780px; text-wrap: pretty; }
.pasos { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 32px 28px; }
.paso { flex: 1 1 230px; min-width: 0; border-top: 1px solid var(--grafito); padding-top: 24px; display: flex; flex-direction: column; gap: 12px; }
.paso__numero { display: flex; align-items: center; gap: 12px; }
.paso__numero svg { display: block; flex-shrink: 0; }
.paso__numero p { font-size: 13px; line-height: 16px; font-weight: 600; color: var(--texto-secundario-oscuro); letter-spacing: 0.14em; text-transform: uppercase; }
.paso .titulo-tarjeta { color: var(--papel); text-wrap: wrap; }
.qd__cierre { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px 32px; border-top: 1px solid var(--grafito); padding-top: 32px; }
.frase-cierre { font-size: 24px; line-height: 32px; font-weight: 700; color: var(--papel); }

/* ---------- Productos (antes del primero) ---------- */
.productos__texto { flex: 999 1 520px; min-width: 0; display: flex; flex-direction: column; gap: 20px; }
.caja { flex: 1 1 460px; min-width: 0; background: var(--superficie); border: 1px solid var(--linea); padding: 28px 32px 14px 32px; box-sizing: border-box; position: relative; }
.caja__cabeza { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; padding-bottom: 18px; }
.caja__cabeza p { font-size: 16px; line-height: 24px; color: var(--texto-secundario); max-width: 240px; }
.nota-productos { display: block; width: 120px; height: 120px; flex-shrink: 0; }
.familia { display: flex; align-items: flex-start; gap: 16px; padding: 18px 0; border-top: 1px solid var(--linea); }
.familia__icono { display: block; width: 48px; height: 48px; flex-shrink: 0; }
.familia__texto { display: flex; flex-direction: column; gap: 4px; }
.familia__nombre { font-size: 18px; line-height: 24px; font-weight: 700; }
.familia__descripcion { font-size: 15px; line-height: 22px; color: var(--texto-secundario); }

/* ---------- Quiénes somos ---------- */
.datos { display: flex; flex-wrap: wrap; gap: 24px 32px; }
.dato { flex: 1 1 150px; min-width: 0; display: flex; flex-direction: column; gap: 8px; border-top: 1px solid var(--linea); padding-top: 16px; }
.dato__cifra { font-size: 32px; line-height: 1.12; font-weight: 800; letter-spacing: -0.01em; font-variant-numeric: tabular-nums; text-wrap: balance; }
.dato__texto { font-size: 15px; line-height: 22px; color: var(--texto-secundario); }

/* ---------- Consultoría ---------- */
.consultoria__texto { flex: 999 1 480px; min-width: 0; display: flex; flex-direction: column; gap: 20px; }
.caja-lista { flex: 1 1 400px; min-width: 0; background: var(--superficie); border: 1px solid var(--linea); padding: 36px; box-sizing: border-box; }
.caja-lista .dd-vinetas { font-size: 18px; line-height: 28px; gap: 16px; }

/* ---------- Contacto ---------- */
.contacto__texto { flex: 999 1 600px; min-width: 0; display: flex; flex-direction: column; gap: 24px; }
.correo-grande { font-size: 28px; line-height: 1.3; font-weight: 700; color: var(--papel); text-decoration: underline; text-decoration-color: var(--lima); text-decoration-thickness: 3px; text-underline-offset: 6px; overflow-wrap: anywhere; }
.contacto__nota { flex: 1 1 336px; min-width: 0; display: flex; justify-content: flex-end; }
.recuadro-nota { width: 336px; height: 336px; max-width: 100%; display: flex; align-items: center; justify-content: center; }
.nota-contacto { display: block; width: 236px; height: 236px; }

/* ---------- 404 ---------- */
.error { padding: 120px 0 96px 0; }
.error__texto { flex: 999 1 520px; min-width: 0; display: flex; flex-direction: column; gap: 22px; }
.error__nota { flex: 1 1 280px; min-width: 0; display: flex; justify-content: center; }
.nota-uy { display: block; width: 280px; height: 280px; }

/* ---------- Pie ---------- */
.pie { background: var(--papel); border-top: 1px solid var(--linea); padding: 56px 0 32px 0; }
.pie__columna { display: flex; flex-direction: column; gap: 40px; }
.pie__arriba { display: flex; flex-wrap: wrap; align-items: flex-start; justify-content: space-between; gap: 32px 48px; }
.logo-pie { display: block; width: 97px; height: 44px; }
.pie__nav { flex: 1 1 320px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); grid-template-rows: repeat(3, auto); grid-auto-flow: column; gap: 12px 32px; max-width: 420px; }
.pie__nav a { font-size: 15px; line-height: 22px; font-weight: 500; text-decoration: none; }
.pie__contacto { display: flex; flex-direction: column; gap: 10px; }
.pie__abajo { border-top: 1px solid var(--linea); padding-top: 20px; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px; }

/* ---------- Hasta 1191 px: el panel de la portada baja y ocupa todo el ancho ---------- */
@media (max-width: 1191px) {
  .panel { max-width: none; }
}

/* ---------- Hasta 1099 px: menú de celular ---------- */
@media (max-width: 1099px) {
  .encabezado .nav-principal { display: none; }
  .boton-menu { display: flex; }
  .encabezado__fila { flex-wrap: nowrap; gap: 16px; padding-top: 8px; padding-bottom: 8px; }
  .encabezado--grande .encabezado__fila { align-items: flex-start; gap: 16px; padding-top: 20px; padding-bottom: 0; }
  /* Área táctil de 44 px en los enlaces del pie, sin cambiar cómo se ven */
  .pie__nav a, .pie__contacto .correo { display: block; padding: 11px 0; margin: -11px 0; }
}

/* ---------- Hasta 767 px: celular ---------- */
@media (max-width: 767px) {
  .contenedor { padding-left: 20px; padding-right: 20px; }
  .seccion { padding: 64px 0; }
  .columna, .fila { gap: 40px; }

  .titulo-portada { font-size: 46px; line-height: 48px; }
  .titulo-interno { font-size: 40px; line-height: 44px; }
  .titulo-seccion { font-size: 34px; line-height: 38px; }
  .titulo-contacto { font-size: 36px; line-height: 40px; }
  .titulo-qd { font-size: 52px; line-height: 54px; }
  .titulo-tarjeta { font-size: 22px; line-height: 28px; }
  .bajada { font-size: 18px; line-height: 28px; }
  .texto { font-size: 17px; line-height: 27px; }

  /* Botones a lo ancho */
  .botones { flex-direction: column; gap: 12px; }
  .botones > .dd-boton, .boton-ancho { width: 100%; }
  .botones > .dd-boton, .boton-ancho--alto { min-height: 52px; }
  .botones--juntos > .dd-boton { min-height: 48px; }

  .portada { padding: 40px 0 64px 0; }
  .portada__texto { gap: 24px; }
  .panel__cabeza { padding: 28px 28px 0 28px; }
  .panel__textura { padding: 20px 28px 24px 28px; }
  .panel__cifra { font-size: 72px; }
  .panel__cuerpo { padding: 16px 28px 28px 28px; }
  .panel__frase { font-size: 20px; line-height: 28px; }

  .tarjeta { padding: 24px; }

  .qd__cabeza { padding-top: 64px; }
  .qd__textura { padding: 24px 0; }
  .qd__cuerpo { padding-top: 32px; padding-bottom: 64px; }
  .qd__intro { font-size: 19px; line-height: 29px; }
  .frase-cierre { font-size: 22px; line-height: 28px; }

  .caja { padding: 24px 20px 8px 20px; }
  .nota-productos { width: 96px; height: 96px; }
  .familia__icono { width: 40px; height: 40px; }
  .familia__nombre { font-size: 17px; }

  .dato { flex-basis: 100%; }
  .dato__cifra { font-size: 28px; }

  .caja-lista { padding: 24px; }
  .caja-lista .dd-vinetas { font-size: 17px; line-height: 26px; }

  .correo-grande { font-size: 20px; }
  .contacto__nota { flex-basis: 240px; }
  .recuadro-nota { width: 240px; height: 240px; }
  .nota-contacto { width: 168px; height: 168px; }

  .error { padding: 56px 0 64px 0; }
  .nota-uy { width: 180px; height: 180px; }

  .pie { padding-top: 48px; }
}

/* ---------- Celulares de menos de 390 px: los títulos anchos se achican para que ninguna palabra se salga ---------- */
@media (max-width: 389px) {
  .titulo-portada { font-size: min(46px, calc((100vw - 40px) * 0.131)); line-height: 1.05; }
  .titulo-seccion { font-size: min(34px, calc((100vw - 40px) * 0.1)); line-height: 1.12; }
  .panel__cifra { font-size: min(72px, calc((100vw - 96px) * 0.245)); }
}
