/* PerMaT-RP web · componentes de páginas interiores, formularios, acceso, legal y errores. */

.logo img { height: 38px; width: auto; display: block; }
.footer .logo img { height: 38px; }
.noscript-msg { background: #fff4e5; color: #6b3e00; padding: 12px var(--gutter); text-align: center; font-size: .9375rem; }

/* ---------- Cabecera de página interior ---------- */
.page-hero {
  position: relative; overflow: clip; padding: clamp(118px, 13vw, 164px) 0 clamp(40px, 6vw, 72px);
  background:
    radial-gradient(800px 420px at 92% -10%, #d9e7ff 0%, transparent 62%),
    radial-gradient(640px 400px at -6% 30%, #d5f4f0 0%, transparent 58%),
    linear-gradient(#fff, #f7faff);
}
.page-hero::before { content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .45;
  background-image: linear-gradient(var(--line) 1px, transparent 1px), linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 56px 56px; -webkit-mask-image: radial-gradient(60% 70% at 75% 20%, #000, transparent 75%); mask-image: radial-gradient(60% 70% at 75% 20%, #000, transparent 75%); }
.page-hero .wrap { position: relative; }
.page-hero h1 { font-size: clamp(2rem, 4.6vw, 3.4rem); font-weight: 800; letter-spacing: -.03em; line-height: 1.08; margin-top: 18px; max-width: 22ch; text-wrap: balance; }
.page-hero .lead { font-size: clamp(1.05rem, 1.6vw, 1.25rem); max-width: 68ch; }
.page-hero .hero-cta { margin-top: 28px; }
.crumbs { margin-bottom: 18px; }
.crumbs ol { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; padding: 0; margin: 0; list-style: none; font-size: .875rem; color: var(--muted); }
.crumbs li + li::before { content: "/"; margin-right: 6px; color: #9aa9c2; }
.crumbs a { color: var(--muted); text-decoration: none; } .crumbs a:hover { color: var(--blue-700); text-decoration: underline; }
.crumbs [aria-current] { color: var(--ink); font-weight: 600; }
.section-soft { background: var(--bg-soft); }
.section-tight { padding-block: clamp(48px, 7vw, 88px); }
.head-center { text-align: center; } .head-center .lead { margin-inline: auto; } .head-center .eyebrow { justify-content: center; }

/* ---------- Tarjetas ---------- */
.cards { display: grid; gap: 18px; margin-top: 44px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); }
.cards-4 { grid-template-columns: repeat(4, 1fr); } .cards-3 { grid-template-columns: repeat(3, 1fr); } .cards-2 { grid-template-columns: repeat(2, 1fr); }
.card { padding: 28px; border-radius: var(--radius); background: #fff; border: 1px solid var(--line); transition: transform .35s var(--ease), box-shadow .35s var(--ease), border-color .3s; }
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-1); border-color: #bccde8; }
.card .ic { width: 46px; height: 46px; border-radius: 13px; display: grid; place-items: center; background: var(--sky); color: var(--blue); margin-bottom: 18px; }
.card .ic svg { width: 24px; height: 24px; }
.card h3 { font-size: 1.1875rem; font-weight: 700; letter-spacing: -.01em; }
.card p { margin-top: 8px; font-size: .9875rem; line-height: 1.58; color: var(--muted); }
.card .num { font: 800 .8125rem/1 var(--font-display); letter-spacing: .12em; color: var(--blue); margin-bottom: 14px; display: block; }
.card.dark { background: var(--navy); border-color: transparent; }
.card.dark h3 { color: #fff; } .card.dark p { color: #aebcda; } .card.dark .ic { background: rgba(53, 211, 199, .16); color: var(--teal-300); }

/* ---------- Filas texto + imagen ---------- */
.split { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(28px, 5vw, 80px); align-items: center; }
.split + .split { margin-top: clamp(64px, 9vw, 120px); }
.split.rev { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); } .split.rev .split-text { order: 2; }
.split-text .num-chip { display: inline-grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; background: var(--blue); color: #fff; font: 800 1.05rem/1 var(--font-display); margin-bottom: 16px; }
.split-text h2, .split-text h3 { font-size: clamp(1.6rem, 3vw, 2.3rem); font-weight: 800; letter-spacing: -.025em; text-wrap: balance; }
.split-text .sub { margin-top: 10px; font: 700 1.0625rem/1.35 var(--font-display); color: var(--blue-700); }
.split-text p { margin-top: 16px; color: var(--ink-2); }
.ticks { margin-top: 20px; display: grid; gap: 10px; }
.ticks li { position: relative; padding-left: 32px; font-size: .9875rem; line-height: 1.5; }
.ticks li::before { content: ""; position: absolute; left: 0; top: 2px; width: 22px; height: 22px; border-radius: 50%; background: var(--sky) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231553d6' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 12.5l4 4 8-9'/%3E%3C/svg%3E") center/13px no-repeat; }
.shot { margin: 0; position: relative; }
.shot .win { box-shadow: var(--shadow-2); }
.shot .shot-img { display: block; position: relative; background: #fff; cursor: zoom-in; border: 0; padding: 0; width: 100%; font: inherit; text-align: left; }
.shot .shot-img img { width: 100%; height: auto; }
.shot .shot-img::after { content: ""; position: absolute; right: 12px; bottom: 12px; width: 38px; height: 38px; border-radius: 50%; background: rgba(10, 26, 51, .78) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='10.5' cy='10.5' r='6'/%3E%3Cpath d='M15 15l5 5M10.5 8v5M8 10.5h5'/%3E%3C/svg%3E") center/20px no-repeat; opacity: 0; transition: opacity .25s; }
.shot .shot-img:hover::after, .shot .shot-img:focus-visible::after { opacity: 1; }
.shot figcaption { margin-top: 12px; font-size: .875rem; color: var(--muted); }
.shot figcaption b { color: var(--ink); font-family: var(--font-display); }

/* ---------- Cuadrícula de funcionalidades ---------- */
.fgrid { display: grid; gap: 14px; margin-top: 40px; grid-template-columns: repeat(4, 1fr); }
.fgrid a { display: block; padding: 22px 20px; border-radius: var(--radius); background: #fff; border: 1px solid var(--line); color: inherit; text-decoration: none; transition: transform .3s var(--ease), border-color .3s, box-shadow .3s; }
.fgrid a:hover, .fgrid a:focus-visible { transform: translateY(-4px); border-color: #b8c9e4; box-shadow: var(--shadow-1); }
.fgrid .ic { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: var(--sky); color: var(--blue); margin-bottom: 14px; }
.fgrid .ic svg { width: 22px; height: 22px; }
.fgrid h3 { font-size: 1.0625rem; font-weight: 700; letter-spacing: -.01em; }

/* ---------- Franja de llamada a la acción ---------- */
.cta-band { background: linear-gradient(115deg, #0b2f86 0%, #0f43b0 55%, #0e8f93 130%); color: #d5e3ff; border-radius: 28px; padding: clamp(32px, 6vw, 64px); display: flex; flex-wrap: wrap; gap: 24px 40px; align-items: center; justify-content: space-between; position: relative; overflow: hidden; }
.cta-band::after { content: ""; position: absolute; right: -80px; top: -80px; width: 320px; height: 320px; border-radius: 50%; background: radial-gradient(circle, rgba(53, 211, 199, .4), transparent 65%); pointer-events: none; }
.cta-band > * { position: relative; z-index: 1; }
.cta-band h2 { color: #fff; font-size: clamp(1.6rem, 3.2vw, 2.4rem); font-weight: 800; letter-spacing: -.025em; max-width: 24ch; text-wrap: balance; }
.cta-band p { margin-top: 12px; color: #c4d6fb; max-width: 52ch; }
.cta-band .btns { display: flex; flex-wrap: wrap; gap: 12px; }

/* ---------- Listas con iconos ---------- */
.trust { display: grid; gap: 14px; margin-top: 28px; grid-template-columns: repeat(2, 1fr); }
.trust li { display: flex; gap: 14px; padding: 18px 20px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; font-size: .9875rem; line-height: 1.5; }
.trust li svg { flex: none; width: 24px; height: 24px; color: var(--teal); margin-top: 1px; }

/* ---------- Pasos verticales (cómo funciona, demo) ---------- */
.vsteps { counter-reset: v; display: grid; gap: 0; margin-top: 44px; max-width: 920px; }
.vstep { position: relative; display: grid; grid-template-columns: 56px minmax(0, 1fr); gap: 22px; padding-bottom: 44px; }
.vstep::before { content: ""; position: absolute; left: 27px; top: 56px; bottom: 6px; width: 2px; background: linear-gradient(var(--blue), rgba(21, 83, 214, .12)); }
.vstep:last-child { padding-bottom: 0; } .vstep:last-child::before { display: none; }
.vstep .n { width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center; background: var(--blue); color: #fff; font: 800 1.25rem/1 var(--font-display); box-shadow: 0 10px 20px -8px rgba(21, 83, 214, .6); }
.vstep h3 { font-size: 1.375rem; font-weight: 800; letter-spacing: -.02em; }
.vstep p { margin-top: 8px; color: var(--ink-2); max-width: 62ch; }
.vstep .shot { margin-top: 20px; max-width: 760px; }

/* ---------- Formularios ---------- */
.form-card { background: #fff; border: 1px solid var(--line); border-radius: 24px; padding: clamp(22px, 4vw, 40px); box-shadow: var(--shadow-1); }
.form-card h2 { font-size: 1.5rem; font-weight: 800; letter-spacing: -.02em; }
.form-grid { display: grid; gap: 18px 20px; grid-template-columns: 1fr 1fr; margin-top: 22px; }
.field { display: flex; flex-direction: column; gap: 7px; min-width: 0; }
.field.full { grid-column: 1 / -1; }
.field label, .field .lab { font: 700 .9375rem/1.3 var(--font-display); color: var(--ink); }
.field label .req { color: var(--red); margin-left: 2px; }
.field label .opt { font-weight: 500; color: var(--muted); margin-left: 6px; font-size: .8125rem; }
.input, .textarea, .select {
  width: 100%; min-height: 50px; padding: 12px 14px; border: 1.5px solid #c3d0e4; border-radius: 12px; background: #fff; color: var(--ink);
  font: 400 1rem/1.4 var(--font-body); transition: border-color .2s, box-shadow .2s;
}
.textarea { min-height: 150px; resize: vertical; line-height: 1.55; }
.select { appearance: none; -webkit-appearance: none; padding-right: 40px; background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2322344f' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") right 12px center/18px no-repeat; }
.input:hover, .textarea:hover, .select:hover { border-color: #93a8c9; }
.input:focus, .textarea:focus, .select:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 4px rgba(21, 83, 214, .16); }
.field.is-invalid .input, .field.is-invalid .textarea, .field.is-invalid .select, .input[aria-invalid="true"] { border-color: #c62828; background-color: #fff8f8; }
.field-error { display: flex; gap: 6px; align-items: flex-start; color: #b3261e; font-size: .875rem; line-height: 1.4; font-weight: 600; }
.field-error::before { content: "!"; flex: none; display: inline-grid; place-items: center; width: 18px; height: 18px; border-radius: 50%; background: #b3261e; color: #fff; font-size: .75rem; font-weight: 800; margin-top: 1px; }
.field-hint { font-size: .8125rem; color: var(--muted); }
.check { display: flex; gap: 12px; align-items: flex-start; }
.check input { flex: none; width: 22px; height: 22px; margin-top: 2px; accent-color: var(--blue); cursor: pointer; }
.check label { font: 400 .9875rem/1.5 var(--font-body); color: var(--ink-2); cursor: pointer; }
.check.is-invalid label { color: #b3261e; }
.hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }
.privacy-layer { margin-top: 6px; padding: 14px 16px; border-radius: 12px; background: var(--bg-soft); border: 1px solid var(--line); font-size: .8125rem; line-height: 1.55; color: var(--muted); }
.privacy-layer b { color: var(--ink); }
.form-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 22px; margin-top: 8px; }
.btn[disabled], .btn[aria-disabled="true"] { opacity: .65; cursor: progress; transform: none; box-shadow: none; }
.btn-link { background: none; border: 0; padding: 6px 0; font: 600 .9375rem/1.3 var(--font-display); color: var(--blue-700); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.btn-link:hover { color: var(--blue); }

.alert { display: flex; gap: 14px; padding: 18px 20px; border-radius: 16px; border: 1px solid; margin-bottom: 22px; }
.alert svg { flex: none; width: 24px; height: 24px; margin-top: 1px; }
.alert strong { display: block; font: 700 1.0625rem/1.3 var(--font-display); }
.alert p, .alert ul { margin-top: 4px; font-size: .9875rem; line-height: 1.5; }
.alert ul { padding-left: 18px; list-style: disc; }
.alert--ok { background: #eafaf3; border-color: #a6e3c8; color: #0b4d38; } .alert--ok svg { color: #12a06b; }
.alert--err { background: #fff3f2; border-color: #f2b8b5; color: #7a1710; } .alert--err svg { color: #c62828; }
.alert--info { background: var(--sky); border-color: #c4d6fa; color: #12306e; } .alert--info svg { color: var(--blue); }

/* ---------- Contacto ---------- */
.contact-grid { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 4fr); gap: clamp(24px, 4vw, 56px); align-items: start; }
.contact-side { display: grid; gap: 16px; position: sticky; top: 100px; }
.cinfo { display: flex; gap: 16px; padding: 22px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
.cinfo .ic { flex: none; width: 46px; height: 46px; border-radius: 13px; display: grid; place-items: center; background: var(--sky); color: var(--blue); }
.cinfo .ic svg { width: 24px; height: 24px; }
.cinfo h3 { font: 700 .8125rem/1.2 var(--font-display); letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.cinfo p, .cinfo address { margin-top: 6px; font-style: normal; font-size: 1.0625rem; line-height: 1.5; color: var(--ink); font-weight: 600; }
.cinfo a { color: var(--blue-700); text-decoration: none; } .cinfo a:hover { text-decoration: underline; }
.cinfo small { display: block; margin-top: 6px; font-size: .8125rem; font-weight: 400; color: var(--muted); }
.note-reply { font-size: .875rem; color: var(--muted); padding: 0 6px; }

/* ---------- Acceso (Espacio cliente) ---------- */
.auth { min-height: 100vh; display: grid; align-items: center; padding: clamp(110px, 12vw, 150px) 0 70px; background:
    radial-gradient(800px 460px at 85% -10%, #d9e7ff 0%, transparent 60%), radial-gradient(640px 420px at -5% 90%, #d5f4f0 0%, transparent 58%), #f7faff; }
.auth-card { width: min(100% - 2 * var(--gutter), 480px); margin-inline: auto; background: #fff; border: 1px solid var(--line); border-radius: 24px; padding: clamp(24px, 5vw, 40px); box-shadow: var(--shadow-2); }
.auth-card h1 { font-size: 1.75rem; font-weight: 800; letter-spacing: -.025em; margin-top: 14px; }
.auth-card .lead { font-size: 1rem; margin-top: 10px; }
.auth-card form { margin-top: 24px; display: grid; gap: 18px; }
.auth-card .btn { width: 100%; }
.auth-links { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px 16px; margin-top: 6px; }
.auth-foot { margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--line); font-size: .9375rem; color: var(--muted); }
.pw { position: relative; }
.pw .input { padding-right: 52px; }
.pw button { position: absolute; right: 4px; top: 4px; width: 42px; height: 42px; border: 0; background: transparent; border-radius: 10px; cursor: pointer; color: var(--muted); display: grid; place-items: center; }
.pw button:hover { background: var(--sky); color: var(--blue-700); }
.pw button svg { width: 22px; height: 22px; }
.meter { display: grid; grid-template-columns: repeat(4, 1fr); gap: 5px; margin-top: 4px; }
.meter i { height: 6px; border-radius: 4px; background: #dfe7f3; transition: background-color .25s; }
.meter[data-s="1"] i:nth-child(-n+1) { background: #e0453a; } .meter[data-s="2"] i:nth-child(-n+2) { background: #f0a020; }
.meter[data-s="3"] i:nth-child(-n+3) { background: #7bbf3a; } .meter[data-s="4"] i { background: #12a06b; }
.meter-lab { font-size: .8125rem; color: var(--muted); }

/* ---------- Mensajes del servidor (sustituye a los antiguos pop-ups) ---------- */
.msg-overlay { position: fixed; inset: 0; z-index: 90; display: grid; place-items: center; padding: 20px; background: rgba(10, 26, 51, .55); backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px); }
.msg-box { width: min(100%, 460px); background: #fff; border-radius: 20px; padding: 28px; box-shadow: var(--shadow-2); }
.msg-box h2 { font-size: 1.25rem; font-weight: 800; }
.msg-box .msg-text { margin-top: 12px; color: var(--ink-2); font-size: 1rem; line-height: 1.55; }
.msg-box .msg-text ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; }
.msg-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 22px; }
.msg-actions form { margin: 0; }

/* ---------- Texto legal ---------- */
.legal-layout { display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: clamp(28px, 5vw, 72px); align-items: start; }
.toc { position: sticky; top: 100px; padding: 20px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
.toc h2 { font: 700 .8125rem/1 var(--font-display); letter-spacing: .12em; text-transform: uppercase; color: var(--muted); margin-bottom: 12px; }
.toc a { display: block; padding: 8px 10px; border-radius: 8px; color: var(--ink-2); text-decoration: none; font: 600 .9375rem/1.3 var(--font-display); }
.toc a:hover, .toc a:focus-visible { background: var(--sky); color: var(--blue-700); }
.prose { max-width: 78ch; }
.prose section { scroll-margin-top: 96px; }
.prose section + section { margin-top: 56px; }
.prose h2 { font-size: clamp(1.5rem, 2.6vw, 2rem); font-weight: 800; letter-spacing: -.02em; margin-bottom: 16px; padding-bottom: 12px; border-bottom: 2px solid var(--line); }
.prose h3 { font-size: 1.1875rem; font-weight: 700; margin: 30px 0 8px; letter-spacing: -.01em; }
.prose p { margin-top: 12px; line-height: 1.7; }
.prose ul { list-style: disc; padding-left: 22px; margin-top: 12px; display: grid; gap: 8px; line-height: 1.6; }
.prose a { color: var(--blue-700); }
.prose .ver { color: var(--muted); font-size: .9375rem; }

/* ---------- Mapa web ---------- */
.sitemap { display: grid; grid-template-columns: repeat(2, 1fr); gap: 22px; margin-top: 36px; }
.sitemap section { padding: 26px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
.sitemap h2 { font-size: 1.125rem; font-weight: 800; margin-bottom: 14px; }
.sitemap ul { display: grid; gap: 4px; }
.sitemap a { display: block; padding: 8px 10px; margin-inline: -10px; border-radius: 8px; color: var(--blue-700); text-decoration: none; font-weight: 600; }
.sitemap a:hover { background: var(--sky); }

/* ---------- Error ---------- */
.errpage { min-height: 80vh; display: grid; place-items: center; text-align: center; padding: 140px 0 80px; }
.errpage .code { font: 800 clamp(5rem, 18vw, 10rem)/1 var(--font-display); letter-spacing: -.05em; background: linear-gradient(100deg, var(--blue), var(--teal)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.errpage h1 { font-size: clamp(1.7rem, 4vw, 2.6rem); font-weight: 800; margin-top: 8px; }
.errpage p { max-width: 52ch; margin: 14px auto 0; color: var(--muted); }
.errpage .btn { margin-top: 28px; }

/* ---------- Visor de imágenes ---------- */
.lb { position: fixed; inset: 0; z-index: 95; display: none; align-items: center; justify-content: center; padding: clamp(12px, 3vw, 40px); background: rgba(6, 14, 30, .88); }
.lb.is-open { display: flex; animation: lbin .25s var(--ease); }
@keyframes lbin { from { opacity: 0; } to { opacity: 1; } }
.lb figure { margin: 0; max-width: min(100%, 1400px); max-height: 100%; display: flex; flex-direction: column; gap: 10px; }
.lb img { max-width: 100%; max-height: calc(100vh - 110px); width: auto; height: auto; object-fit: contain; background: #fff; border-radius: 10px; box-shadow: 0 30px 80px rgba(0, 0, 0, .5); }
.lb figcaption { color: #cfd9ec; font-size: .9375rem; text-align: center; }
.lb button { position: absolute; top: 14px; right: 14px; width: 48px; height: 48px; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .14); color: #fff; font-size: 1.6rem; line-height: 1; cursor: pointer; }
.lb button:hover { background: rgba(255, 255, 255, .26); }

/* ---------- Responsive de componentes interiores ---------- */
@media (max-width: 1080px) { .cards-4 { grid-template-columns: repeat(2, 1fr); } .fgrid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 960px) {
  .split, .split.rev { grid-template-columns: 1fr; } .split.rev .split-text { order: 0; }
  .contact-grid { grid-template-columns: 1fr; } .contact-side { position: static; }
  .legal-layout { grid-template-columns: 1fr; } .toc { position: static; display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
  .toc h2 { width: 100%; margin: 0 0 4px; } .toc a { padding: 8px 12px; background: var(--bg-soft); }
  .cards-3 { grid-template-columns: repeat(2, 1fr); }
  .trust { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .cards-4, .cards-3, .cards-2, .fgrid, .sitemap { grid-template-columns: 1fr; }
  .form-grid { grid-template-columns: 1fr; }
  .page-hero { padding-top: 104px; }
  .vstep { grid-template-columns: 44px minmax(0, 1fr); gap: 14px; } .vstep .n { width: 44px; height: 44px; font-size: 1.05rem; } .vstep::before { left: 21px; top: 44px; }
  .form-actions .btn, .cta-band .btn { width: 100%; }
  .msg-actions .btn { width: 100%; } .msg-actions form { width: 100%; }
  .cinfo { padding: 18px; }
}

/* Navegación: opción activa y sin saltos de línea */
.nav a:not(.btn)[aria-current="page"] { background: var(--sky); color: var(--blue-700); }
.client-link, .nav a { white-space: nowrap; }

/* Cabecera: evitar que el logotipo se encoja y compactar la navegación en pantallas medias */
.header .wrap { width: min(100% - 2 * var(--gutter), 1320px); }
.logo { flex: none; }
.nav { margin-left: auto; }
.nav a:not(.btn) { padding: 10px 11px; font-size: .9rem; }
.nav .nav-client { display: none; }
.client-link { flex: none; }
@media (max-width: 1439px) { .client-link span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); } }
@media (max-width: 960px) {
  .nav .nav-client { display: block; }
  .client-link { display: none; }
}

/* Navegación compacta: 6 opciones + acción principal; menú desplegable hasta 1180 px */
.nav { gap: 0; }
.nav a:not(.btn) { padding: 10px 10px; font-size: .875rem; }
.header .wrap { gap: 18px; }
.nav .nav-extra, .nav .nav-client { display: none; }
@media (max-width: 1279px) {
  .burger { display: block; }
  .nav { position: fixed; inset: 66px 0 auto 0; flex-direction: column; align-items: stretch; gap: 2px; background: #fff; padding: 14px var(--gutter) 24px;
    border-bottom: 1px solid var(--line); box-shadow: 0 30px 40px -20px rgba(10, 26, 51, .35); transform: translateY(-12px); opacity: 0; visibility: hidden;
    transition: transform .3s var(--ease), opacity .25s, visibility .25s; max-height: calc(100dvh - 66px); overflow: auto; margin-left: 0; }
  .nav.is-open { transform: none; opacity: 1; visibility: visible; }
  .nav a:not(.btn) { padding: 15px 12px; font-size: 1.0625rem; }
  .nav a.is-sim::after { top: 20px; right: auto; left: 150px; }
  .nav .nav-extra, .nav .nav-client { display: block; }
  .nav .btn { margin-top: 10px; }
  .client-link { display: none; }
  .header-tools { margin-left: auto; }
}
@media (max-width: 380px) {
  .logo img { height: 30px; }
  .header .wrap { gap: 4px; }
  .lang summary { padding: 0 6px; }
}

.for-grid--2 { grid-template-columns: repeat(2, 1fr); margin-top: 0; }
@media (max-width: 480px) { .for-grid--2 { grid-template-columns: 1fr; } }

/* Listas ordenadas con numeración propia */
.steps, .demo-grid { list-style: none; padding: 0; }
.steps { margin: 0; }
.auth-card > .logo { display: flex; margin: 0 0 4px; }
.auth-card > .eyebrow { display: flex; }
.auth { min-height: min(100vh, 900px); }

/* ---------- Revision responsive (moviles y pantallas pequenas) ---------- */
/* Rotulo superior: el interlineado a 1 hacia que, al partirse en dos lineas, se tocaran */
.eyebrow { line-height: 1.4; }
.roles li { line-height: 1.3; }

/* Objetivos tactiles: enlaces del pie, enlaces de texto y botones sin caja con una altura comoda para el dedo */
.footer li a, .legal a { display: inline-block; padding-block: 6px; }
.footer li + li { margin-top: 0; }
.cinfo a { display: inline-block; padding-block: 6px; }
.btn-link { min-height: 40px; display: inline-flex; align-items: center; }
.check input { width: 24px; height: 24px; }

@media (max-width: 1279px) {
  /* Menu desplegable: el punto del simulador va junto al texto (antes estaba a 150 px fijos y pisaba la palabra en otros idiomas) */
  .nav a.is-sim { display: flex; align-items: center; gap: 8px; padding-inline: 12px; }
  .nav a.is-sim::after { position: static; flex: none; margin: 0; }
  .nav { overscroll-behavior: contain; }
}

@media (max-width: 600px) {
  /* Tarjetas compactas: icono a la izquierda y texto a la derecha (la portada pasa de unos 15.000 px a bastante menos) */
  .pain, .b-card:not(.hero-b) { display: grid; grid-template-columns: 44px minmax(0, 1fr); column-gap: 14px; align-items: start; padding: 18px; }
  .pain .ic, .b-card:not(.hero-b) .ic { grid-row: 1 / span 2; width: 44px; height: 44px; margin: 0; }
  .pain h3, .b-card:not(.hero-b) h3 { align-self: center; min-height: 44px; display: flex; align-items: center; font-size: 1.0625rem; line-height: 1.25; }
  .pain p, .b-card:not(.hero-b) p { margin-top: 6px; font-size: .9375rem; }
  .pain-grid { gap: 12px; margin-top: 32px; }
  .bento { gap: 12px; }
  .b-card.hero-b { padding: 22px; }
  .for-card { display: flex; align-items: center; gap: 14px; padding: 14px 18px; }
  .for-card .ic { margin: 0; flex: none; width: 34px; height: 34px; }
  .for-grid { gap: 10px; }
  .sim-stage .tag { font-size: .6875rem; }
  .section { padding-block: 56px; }
}

/* ---------- Pantallas pequenas: imagen siempre junto a su texto ---------- */
.tab .m-shot { display: none; }
.step-stage { list-style: none; }
@media (max-width: 960px) {
  /* Bloques «texto + imagen» (Funcionalidades, Que es...): primero el texto y debajo su imagen, en todos los bloques
     (antes, en los bloques invertidos la imagen salia por delante del texto) */
  .split > .split-text, .split.rev > .split-text { order: 0; }
  .split > :not(.split-text), .split.rev > :not(.split-text) { order: 1; }
  .split { gap: 24px; }
  .split + .split { margin-top: 56px; }

  /* Que ofrece: no hay columna de imagen aparte; cada area muestra su captura justo debajo de su texto */
  .offer-grid .stage { display: none; }
  .tab p { transition: none; }
  .tab[aria-selected="true"] p { max-height: none; }
  .tab[aria-selected="true"] .m-shot { display: block; margin: 14px 0 0 -52px; }
  .m-win { display: block; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; background: #fff; box-shadow: var(--shadow-1); }
  .m-win img { display: block; width: 100%; height: auto; }
  .m-cap { display: block; margin-top: 8px; font-size: .8125rem; line-height: 1.4; color: var(--muted); }
  .m-cap b { color: var(--ink); font-family: var(--font-display); }

  /* Como funciona: la ilustracion se coloca debajo del paso activo (js/web/permat.js) */
  .step-stage { margin: 6px 0 14px; }
}
@media (max-width: 600px) { .tab[aria-selected="true"] .m-shot { margin-left: -48px; } }
@media (max-width: 600px) {
  /* La etiqueta «Ilustracion conceptual» ocupa la primera fila y el titulo de cada paso va debajo (antes se solapaban) */
  .sim-stage { min-height: 452px; }
  .sim-layer { inset: 84px 16px 16px; }
  .sim-title { top: -32px; line-height: 1.2; }
}
