/* Paleta Energo: los dos azules del logo, grises y negro. */
:root {
  --brand: #2f61fa;      /* azul brillante del símbolo */
  --brand-600: #06168c;  /* azul marino del logotipo */
  --brand-50: #eef2ff;   /* tinte claro del azul para fondos */
  --accent: #2f61fa;
  --ink: #0a0b0f;        /* negro */
  --text: #33363f;       /* gris oscuro */
  --muted: #6b6f7a;      /* gris medio */
  --line: #e3e5ea;       /* gris claro */
  --bg: #ffffff;
  --bg-alt: #f4f5f7;
  --warn-bg: #f1f4ff;
  --warn-line: #c7d3fd;
  --ok-bg: #eef2ff;
  --err: #b42318;
  --radius: 14px;
  --shadow: 0 1px 2px rgb(10 11 15 / 6%), 0 8px 24px rgb(10 11 15 / 6%);
  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; font: 16px/1.6 var(--font); color: var(--text); background: var(--bg); }
img, svg { display: block; max-width: 100%; }
a { color: var(--brand-600); text-decoration-thickness: 1px; text-underline-offset: 3px; }
h1, h2, h3 { color: var(--ink); line-height: 1.2; margin: 0 0 .6em; letter-spacing: -.01em; }
h1 { font-size: clamp(2rem, 4.5vw, 3.1rem); letter-spacing: -.02em; }
h2 { font-size: clamp(1.5rem, 3vw, 2.1rem); }
h3 { font-size: 1.15rem; }
p { margin: 0 0 1em; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; border-radius: 4px; }

.wrap { width: 100%; max-width: 1140px; margin: 0 auto; padding: 0 20px; }
.narrow { max-width: 760px; }
.center { text-align: center; max-width: 680px; margin: 0 auto 2.5rem; }
.muted { color: var(--muted); font-size: .92rem; }
.eyebrow { color: var(--brand-600); font-weight: 700; font-size: .8rem; letter-spacing: .08em; text-transform: uppercase; margin-bottom: .6rem; }
.lead { font-size: 1.15rem; color: var(--text); max-width: 640px; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--ink); color: #fff; padding: 8px 14px; z-index: 100; border-radius: 6px; }
.skip:focus { left: 8px; }

/* Header */
.header { position: sticky; top: 0; z-index: 50; background: rgb(255 255 255 / 92%); backdrop-filter: saturate(1.4) blur(10px); border-bottom: 1px solid var(--line); }
.header-in { display: flex; align-items: center; justify-content: space-between; height: 68px; }
.brand { display: inline-flex; align-items: center; text-decoration: none; }
.brand .logo { display: block; height: 38px; width: auto; color: var(--brand-600); }
.brand-light .logo { color: #fff; }
.nav { display: flex; align-items: center; gap: 26px; }
.nav a { color: var(--text); text-decoration: none; font-weight: 500; font-size: .96rem; }
.nav a:hover, .nav a[aria-current="page"] { color: var(--brand); }
.nav a[aria-current="page"] { box-shadow: inset 0 -2px 0 var(--brand); }
.menu-btn { display: none; background: none; border: 0; padding: 10px; cursor: pointer; }
.menu-btn span { display: block; width: 22px; height: 2px; background: var(--ink); margin: 5px 0; transition: transform .2s, opacity .2s; }

/* Botones */
.btn { line-height: inherit; display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 12px 22px; border-radius: 10px; font-weight: 600; font-size: 1rem; text-decoration: none; border: 2px solid transparent; cursor: pointer; transition: background .15s, color .15s, border-color .15s; font-family: inherit; }
.btn-sm { padding: 7px 14px; font-size: .9rem; }
.btn-primary { background: var(--brand); color: #fff; }
.btn-primary:hover { background: var(--brand-600); }
.btn-outline { border-color: var(--brand); color: var(--brand); background: transparent; }
.nav .btn-outline { color: var(--brand); }
.btn-outline:hover { background: var(--brand-50); }
.btn-light { background: #fff; color: var(--brand); }
.btn-ghost-light { border-color: rgb(255 255 255 / 50%); color: #fff; }
.btn-ghost-light:hover { border-color: #fff; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 1.5rem; }

/* Hero */
.hero {
  position: relative; color: #e6ecff; padding: 56px 0; display: flex; align-items: center;
  background-color: #0a1a4f;
  background-image: linear-gradient(90deg, rgb(6 14 50 / 88%) 0%, rgb(6 14 50 / 62%) 45%, rgb(6 14 50 / 5%) 80%), url("/img/convoy-1800.jpg");
  background-image: linear-gradient(90deg, rgb(6 14 50 / 88%) 0%, rgb(6 14 50 / 62%) 45%, rgb(6 14 50 / 5%) 80%), image-set(url("/img/convoy-1800.webp") type("image/webp"), url("/img/convoy-1800.jpg") type("image/jpeg"));
  background-size: cover; background-position: 70% center;
}
.hero-in { max-width: 1140px; }
.hero-in > * { max-width: 620px; }
.hero h1 { color: #fff; }
.hero .lead { color: #dbe3ff; }
.hero .eyebrow { color: #9db6ff; }

/* Secciones */
.section { padding: 72px 0; }
.section.alt { background: var(--bg-alt); }
.page-head { padding: 64px 0 40px; background: linear-gradient(180deg, var(--brand-50), #fff); border-bottom: 1px solid var(--line); }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; }
.row-head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 1.5rem; }

.card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; }
.feature { padding: 4px 0; }
.feature .icon { width: 44px; height: 44px; padding: 10px; color: var(--brand); background: var(--brand-50); border-radius: 12px; margin-bottom: 14px; }
.feature p { margin: 0; }
.icon { width: 22px; height: 22px; flex: none; }

.checks { list-style: none; padding: 0; margin: 0 0 1.5rem; }
.checks li { display: flex; gap: 10px; align-items: flex-start; padding: 6px 0; }
.checks .icon { color: var(--brand-600); margin-top: 2px; }
.checks.big li { font-size: 1.05rem; color: var(--ink); padding: 10px 0; border-bottom: 1px solid var(--line); }
.checks.big li:last-child { border-bottom: 0; }

/* Planes */
.plans { display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px; max-width: 900px; margin: 0 auto; }
.plan { display: flex; flex-direction: column; }
.plan .btn { margin-top: auto; }
.plan-icon .icon { width: 48px; height: 48px; padding: 11px; border-radius: 12px; background: var(--brand-50); color: var(--brand); margin-bottom: 16px; }
.plan-sub { color: var(--muted); margin-top: -.4em; }
.plan-featured { border: 2px solid var(--brand); box-shadow: var(--shadow); }
.plan-featured .plan-icon .icon { background: var(--brand); color: #fff; }
.fine { font-size: .8rem; color: var(--muted); margin: 10px 0 0; text-align: center; }

/* Pasos */
.steps { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; counter-reset: s; }
.steps li { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; }
.steps span { display: inline-grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; background: var(--accent); color: #fff; font-weight: 800; margin-bottom: 14px; }
.steps p { margin: 0; }

/* Artículos */
.post { display: flex; flex-direction: column; }
.post h3 a { color: var(--ink); text-decoration: none; }
.post h3 a:hover { color: var(--brand); }
.post time, .prose time { color: var(--muted); font-size: .88rem; margin-top: auto; }
.meta { font-size: .8rem; color: var(--brand-600); font-weight: 600; text-transform: uppercase; letter-spacing: .05em; }
.meta a { color: inherit; }
.prose h1 { margin-bottom: .3em; }
.prose h2 { font-size: 1.4rem; margin-top: 1.8em; }
.prose time { display: block; margin-bottom: 2rem; }
.prose ul { padding-left: 1.2em; }
.prose li { margin-bottom: .4em; }

/* Stats / valores */
.stat { text-align: center; }
.stat strong { display: block; font-size: 2.6rem; color: var(--brand); letter-spacing: -.03em; }
.values { list-style: none; padding: 0; margin: 0; }
.values li { padding: 10px 0; border-bottom: 1px solid var(--line); color: var(--ink); }
.values li:last-child { border: 0; }

/* Portales */
.portal { text-decoration: none; color: var(--text); transition: border-color .15s, box-shadow .15s; }
.portal:hover { border-color: var(--brand); box-shadow: var(--shadow); }
.portal > .icon { width: 48px; height: 48px; color: var(--brand); margin-bottom: 14px; }
.portal-off:hover { border-color: var(--line); box-shadow: none; }
.btn:disabled { cursor: not-allowed; opacity: .45; }
.notices { display: grid; gap: 12px; margin-top: 32px; }
.alert { padding: 14px 18px; border-radius: 10px; background: var(--bg-alt); border: 1px solid var(--line); }
.alert-warn { background: var(--warn-bg); border-color: var(--warn-line); }
.alert-ok { background: var(--ok-bg); border-color: var(--warn-line); margin-bottom: 16px; }
.alert + .form { margin-top: 16px; }

/* Formulario */
.contact-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 32px; align-items: start; }
.contact-info { display: grid; gap: 16px; }
.contact-info h3 { display: flex; align-items: center; gap: 8px; }
.contact-info .icon { color: var(--brand); }
.contact-info p { margin: 0 0 .4em; overflow-wrap: anywhere; }
.form { display: grid; gap: 16px; }
.form .grid-2 { gap: 16px; }
.field { display: grid; gap: 6px; }
.field span { font-weight: 600; font-size: .92rem; color: var(--ink); }
input, select, textarea { font: inherit; color: var(--ink); width: 100%; padding: 11px 14px; border: 1.5px solid var(--line); border-radius: 10px; background: #fff; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--brand-600); box-shadow: 0 0 0 3px var(--brand-50); }
textarea { resize: vertical; }
.has-error input, .has-error textarea, .has-error select { border-color: var(--err); }
.err { color: var(--err); font-size: .85rem; }
.check { display: flex; gap: 10px; align-items: flex-start; font-size: .95rem; }
.check input { width: 18px; height: 18px; margin-top: 3px; accent-color: var(--brand); }
.form .btn { justify-self: start; }
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

/* CTA */
.cta-band { background: var(--brand-600); color: #d5dcff; padding: 56px 0; }
.cta-band h2 { color: #fff; }
.cta-in { display: flex; justify-content: space-between; align-items: center; gap: 24px; flex-wrap: wrap; }
.cta-in p { margin: 0; }
.cta-in .actions { margin: 0; }

/* Footer */
.footer { background: var(--ink); color: #b4b8c2; padding: 56px 0 24px; font-size: .94rem; }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1.2fr; gap: 32px; }
.footer h3 { color: #fff; font-size: .95rem; margin-bottom: 12px; }
.footer a { color: #dfe2e8; text-decoration: none; display: block; padding: 3px 0; }
.footer a:hover { color: #fff; text-decoration: underline; }
.footer .brand { margin-bottom: 14px; display: inline-flex; }
.footer .muted { color: #8b909b; }
.footer-bottom { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px; border-top: 1px solid #23262e; margin-top: 40px; padding-top: 20px; font-size: .85rem; }

/* Responsivo */
@media (max-width: 960px) {
  .split, .contact-grid { grid-template-columns: 1fr; gap: 32px; }
  .grid-3, .steps { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 820px) {
  .menu-btn { display: block; }
  .nav { position: absolute; top: 68px; left: 0; right: 0; flex-direction: column; align-items: stretch; gap: 0; background: #fff; border-bottom: 1px solid var(--line); padding: 8px 20px 20px; display: none; }
  .nav.open { display: flex; }
  .nav a { padding: 12px 0; border-bottom: 1px solid var(--line); }
  .nav a[aria-current="page"] { box-shadow: none; }
  .nav .btn { margin-top: 12px; border-bottom: 2px solid var(--brand); }
  .menu-btn[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .menu-btn[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
  .menu-btn[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
}
@media (max-width: 640px) {
  .wrap { padding: 0 16px; }
  .section { padding: 52px 0; }
  .hero { padding: 40px 0; background-position: 72% center; background-image: linear-gradient(180deg, rgb(6 14 50 / 82%), rgb(6 14 50 / 70%)), image-set(url("/img/convoy-900.webp") type("image/webp"), url("/img/convoy-1800.jpg") type("image/jpeg")); }
  .grid-2, .grid-3, .steps, .plans, .footer-grid { grid-template-columns: 1fr; }
  .row-head { flex-direction: column; gap: 4px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}

/* Captcha */
.captcha label { font-weight: 600; font-size: .92rem; color: var(--ink); }
.captcha-row { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.captcha-img svg { width: 210px; max-width: 100%; height: auto; border: 1.5px solid var(--line); border-radius: 10px; }
.captcha-refresh { font-size: .92rem; font-weight: 600; }
.captcha input { max-width: 210px; text-transform: uppercase; letter-spacing: .15em; }
