/* ==========================================================================
   HGE Soluciones Informáticas — hoja de estilos principal
   Sin frameworks ni build: CSS plano listo para producción.
   ========================================================================== */

:root {
  /* Marca (derivada del logo: cian de los anillos + plata) */
  --navy: #0a1f33;
  --navy-2: #12314d;
  --navy-3: #1d4468;
  --cyan: #19aee6;
  --cyan-300: #7fd4f4;
  --cyan-700: #0a6fa3;   /* 5.5:1 con blanco */
  --link: #075e8c;
  --wa: #0b7a5e;         /* verde WhatsApp oscurecido: 5.3:1 con blanco */
  --wa-hover: #096650;

  /* Neutros */
  --ink: #0f2233;
  --text: #3a4a5a;
  --muted: #566676;
  --line: #dce6ee;
  --bg: #f4f8fb;
  --white: #fff;

  --radius: 16px;
  --radius-sm: 10px;
  --shadow: 0 1px 2px rgba(10, 31, 51, .06), 0 8px 24px rgba(10, 31, 51, .07);
  --shadow-lg: 0 2px 4px rgba(10, 31, 51, .06), 0 18px 40px rgba(10, 31, 51, .12);
  --container: 1180px;
  --header-h: 72px;

  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-head: "Manrope", "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

/* ------------------------------------------------------------------ base */
*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-padding-top: calc(var(--header-h) + 16px);
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.65;
  color: var(--text);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
}

img, svg { max-width: 100%; height: auto; display: block; }

h1, h2, h3 {
  font-family: var(--font-head);
  color: var(--ink);
  line-height: 1.15;
  letter-spacing: -.02em;
  margin: 0;
  text-wrap: balance;
}

p { margin: 0; }
ul, ol, dl, dd { margin: 0; padding: 0; }
ul, ol { list-style: none; }

a { color: var(--link); text-underline-offset: 3px; }
a:hover { color: var(--navy); }

:focus-visible {
  outline: 3px solid var(--cyan);
  outline-offset: 3px;
  border-radius: 6px;
}
.on-dark :focus-visible, .on-dark:focus-visible { outline-color: #fff; }

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}

.nowrap { white-space: nowrap; }

.skip-link {
  position: absolute; left: 16px; top: -100px; z-index: 200;
  background: var(--navy); color: #fff; padding: 12px 18px;
  border-radius: var(--radius-sm); font-weight: 600; text-decoration: none;
}
.skip-link:focus { top: 12px; color: #fff; }

.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: 20px;
}
@media (min-width: 768px) { .container { padding-inline: 32px; } }

.icon { width: 1.25em; height: 1.25em; flex: none; }

/* --------------------------------------------------------------- botones */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 48px; padding: 12px 22px;
  font: 600 1rem/1.2 var(--font-body);
  text-decoration: none; text-align: center;
  border: 2px solid transparent; border-radius: 999px;
  cursor: pointer;
  transition: background-color .2s, border-color .2s, color .2s, transform .2s, box-shadow .2s;
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: none; }

.btn--wa { background: var(--wa); color: #fff; box-shadow: 0 6px 18px rgba(11, 122, 94, .28); }
.btn--wa:hover { background: var(--wa-hover); color: #fff; }

.btn--primary { background: var(--cyan-700); color: #fff; }
.btn--primary:hover { background: var(--link); color: #fff; }

.btn--dark { background: var(--navy); color: #fff; }
.btn--dark:hover { background: var(--navy-2); color: #fff; }

.btn--ghost { border-color: rgba(255, 255, 255, .45); color: #fff; background: transparent; }
.btn--ghost:hover { background: rgba(255, 255, 255, .1); border-color: #fff; color: #fff; }

.btn--outline { border-color: var(--navy); color: var(--navy); background: transparent; }
.btn--outline:hover { background: var(--navy); color: #fff; }

.btn--sm { min-height: 44px; padding: 9px 18px; font-size: .9375rem; }

/* ---------------------------------------------------------------- header */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(255, 255, 255, .94);
  -webkit-backdrop-filter: saturate(160%) blur(10px);
  backdrop-filter: saturate(160%) blur(10px);
  border-bottom: 1px solid transparent;
  transition: border-color .2s, box-shadow .2s;
}
.site-header.is-scrolled { border-color: var(--line); box-shadow: 0 4px 20px rgba(10, 31, 51, .06); }

.site-header__inner {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  min-height: var(--header-h);
}

.brand { display: inline-flex; align-items: center; text-decoration: none; }
.brand img { height: 52px; width: auto; }

.nav-toggle {
  display: inline-flex; align-items: center; justify-content: center;
  width: 48px; height: 48px; padding: 0;
  background: transparent; border: 1px solid var(--line); border-radius: 12px;
  color: var(--navy); cursor: pointer;
}
.nav-toggle .icon { width: 24px; height: 24px; }
.nav-toggle .icon-close { display: none; }
.nav-toggle[aria-expanded="true"] .icon-open { display: none; }
.nav-toggle[aria-expanded="true"] .icon-close { display: block; }

.site-nav {
  display: none;
  position: absolute; left: 0; right: 0; top: 100%;
  background: #fff; border-bottom: 1px solid var(--line);
  box-shadow: 0 18px 30px rgba(10, 31, 51, .1);
  padding: 8px 20px 20px;
}
.site-nav.is-open { display: block; }
.site-nav ul { display: flex; flex-direction: column; }
.site-nav li a:not(.btn) {
  display: block; padding: 14px 4px;
  color: var(--ink); font-weight: 500; text-decoration: none;
  border-bottom: 1px solid var(--line);
}
.site-nav li a:not(.btn):hover { color: var(--cyan-700); }
.site-nav .nav-cta { margin-top: 16px; }
.site-nav .nav-cta .btn { width: 100%; }

@media (min-width: 1000px) {
  .nav-toggle { display: none; }
  .site-nav {
    display: block; position: static; padding: 0;
    background: none; border: 0; box-shadow: none;
  }
  .site-nav ul { flex-direction: row; align-items: center; gap: 4px; }
  .site-nav li a:not(.btn) {
    padding: 10px 12px; border: 0; border-radius: 8px; font-size: .9375rem;
  }
  .site-nav li a:not(.btn):hover { background: var(--bg); }
  .site-nav .nav-cta { margin: 0 0 0 10px; }
  .site-nav .nav-cta .btn { width: auto; }
}

/* ------------------------------------------------------------------ hero */
.hero {
  position: relative; overflow: hidden;
  color: #d5e2ec;
  background:
    radial-gradient(900px 500px at 85% 10%, rgba(25, 174, 230, .18), transparent 60%),
    linear-gradient(180deg, var(--navy) 0%, #0d2740 100%);
}
.hero::before {
  content: ""; position: absolute; inset: 0;
  background: url("../img/patron-red.svg") center / 900px auto;
  opacity: .22; pointer-events: none;
}
.hero__inner {
  position: relative;
  display: grid; gap: 40px; align-items: center;
  padding-block: 56px 64px;
}
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: .8125rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase;
  color: var(--cyan-700);
}
.eyebrow::before { content: ""; width: 24px; height: 2px; background: currentColor; }
.hero .eyebrow { color: var(--cyan-300); }

.hero h1 {
  color: #fff;
  font-size: clamp(2.125rem, 5.2vw, 3.5rem);
  font-weight: 800;
  margin-top: 16px;
}
.hero h1 em { font-style: normal; color: #5ccbf5; }
.hero__lead { margin-top: 20px; font-size: 1.125rem; max-width: 56ch; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.hero__support { margin-top: 22px; font-size: .9375rem; color: #b7c8d6; }
.hero__support a { color: #fff; font-weight: 600; }
.hero__support a:hover { color: var(--cyan-300); }
.hero__art { max-width: 460px; margin-inline: auto; width: 100%; }

@media (max-width: 479px) {
  .hero__actions .btn { width: 100%; }
}
@media (min-width: 900px) {
  .hero__inner { grid-template-columns: 1.1fr .9fr; padding-block: 88px 96px; gap: 48px; }
  .hero__art { max-width: 560px; }
}

/* -------------------------------------------------------------- secciones */
.section { padding-block: 72px; }
.section--alt { background: var(--bg); }
.section--dark { background: var(--navy); color: #c5d4e0; }
.section--dark h2, .section--dark h3 { color: #fff; }
.section--dark .eyebrow { color: var(--cyan-300); }
@media (min-width: 900px) { .section { padding-block: 104px; } }

.section__head { max-width: 720px; margin-bottom: 48px; }
.section__head h2 { font-size: clamp(1.75rem, 3.6vw, 2.5rem); font-weight: 800; margin-top: 12px; }
.section__head p { margin-top: 16px; font-size: 1.0625rem; }

/* ---------------------------------------------------------------- pilares */
.pillars { border-bottom: 1px solid var(--line); }
.pillars__grid { display: grid; gap: 0; }
.pillar { display: flex; gap: 16px; padding: 28px 0; border-top: 1px solid var(--line); }
.pillar:first-child { border-top: 0; }
.pillar__icon {
  flex: none; width: 48px; height: 48px; border-radius: 12px;
  display: grid; place-items: center;
  background: #e3f4fc; color: var(--cyan-700);
}
.pillar__icon .icon { width: 24px; height: 24px; }
.pillar h3 { font-size: 1.0625rem; font-weight: 700; letter-spacing: -.01em; }
.pillar p { margin-top: 4px; font-size: .9375rem; color: var(--muted); }
@media (min-width: 900px) {
  .pillars__grid { grid-template-columns: repeat(3, 1fr); }
  .pillar { padding: 36px 32px; border-top: 0; border-left: 1px solid var(--line); }
  .pillar:first-child { border-left: 0; padding-left: 0; }
}

/* -------------------------------------------------------------- servicios */
.services { display: grid; gap: 24px; }
@media (min-width: 700px) { .services { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1080px) { .services { grid-template-columns: repeat(3, 1fr); gap: 28px; } }

.service {
  display: flex; flex-direction: column;
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; box-shadow: var(--shadow);
  transition: transform .25s, box-shadow .25s, border-color .25s;
}
.service:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: #c3d6e4; }
.service__media { border-bottom: 1px solid var(--line); background: #eaf6fc; }
.service__media img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.service__body { display: flex; flex-direction: column; flex: 1; padding: 24px; }
.service__num { font: 700 .8125rem/1 var(--font-head); letter-spacing: .08em; color: var(--cyan-700); }
.service h3 { font-size: 1.25rem; font-weight: 800; margin-top: 10px; }
.service__lead { margin-top: 10px; font-size: .9688rem; }

.checks { margin-top: 16px; display: grid; gap: 8px; }
.checks li { display: flex; gap: 10px; font-size: .9375rem; color: var(--ink); }
.checks .icon { width: 20px; height: 20px; margin-top: 3px; color: var(--cyan-700); }
.section--dark .checks li { color: #e6eef5; }
.section--dark .checks .icon { color: var(--cyan-300); }

.service__case {
  margin-top: auto; padding-top: 18px;
}
.service__case p {
  padding: 14px 16px; border-radius: var(--radius-sm);
  background: var(--bg); border-left: 3px solid var(--cyan);
  font-size: .875rem; line-height: 1.55; color: var(--text);
}
.service__case strong { display: block; color: var(--ink); font-size: .75rem; letter-spacing: .08em; text-transform: uppercase; margin-bottom: 2px; }

.services-cta {
  margin-top: 40px; padding: 24px;
  display: flex; flex-direction: column; gap: 16px; align-items: flex-start;
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
}
.services-cta p { color: var(--ink); font-weight: 600; font-size: 1.0625rem; }
.services-cta span { display: block; font-weight: 400; font-size: .9375rem; color: var(--muted); margin-top: 2px; }
@media (min-width: 800px) {
  .services-cta { flex-direction: row; align-items: center; justify-content: space-between; padding: 28px 32px; }
}

/* ---------------------------------------------------------------- proceso */
.steps { display: grid; gap: 20px; counter-reset: paso; }
@media (min-width: 700px) { .steps { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1080px) { .steps { grid-template-columns: repeat(4, 1fr); } }
.step {
  position: relative; padding: 28px 24px;
  border: 1px solid var(--line); border-radius: var(--radius); background: #fff;
}
.step::before {
  counter-increment: paso; content: "0" counter(paso);
  display: block; font: 800 2rem/1 var(--font-head); color: var(--cyan); margin-bottom: 14px;
}
.step h3 { font-size: 1.125rem; font-weight: 800; }
.step p { margin-top: 8px; font-size: .9375rem; color: var(--muted); }

/* ----------------------------------------------------- complementarias/M365 */
.m365 { display: grid; gap: 40px; align-items: center; }
.m365__art { max-width: 520px; margin-inline: auto; width: 100%; }
.m365 h2 { font-size: clamp(1.75rem, 3.6vw, 2.5rem); font-weight: 800; margin-top: 12px; }
.m365__lead { margin-top: 16px; font-size: 1.0625rem; }
.m365 .checks { margin-top: 24px; gap: 12px; }
.m365 .checks li { font-size: 1rem; }
.m365 .btn { margin-top: 32px; }
@media (min-width: 960px) { .m365 { grid-template-columns: 1fr 1fr; gap: 64px; } }

.extras { display: grid; gap: 20px; margin-top: 56px; }
@media (min-width: 800px) { .extras { grid-template-columns: repeat(2, 1fr); } }
.extra {
  padding: 28px; border-radius: var(--radius);
  background: rgba(255, 255, 255, .05); border: 1px solid rgba(255, 255, 255, .14);
}
.extra h3 { font-size: 1.1875rem; font-weight: 800; }
.extra p { margin-top: 8px; font-size: .9688rem; }
.extra a { display: inline-flex; align-items: center; gap: 6px; margin-top: 14px; color: #fff; font-weight: 600; }
.extra a:hover { color: var(--cyan-300); }
.extra a .icon { width: 18px; height: 18px; }

/* ---------------------------------------------------------------- canales */
.channels { display: grid; gap: 24px; }
@media (min-width: 860px) { .channels { grid-template-columns: repeat(2, 1fr); } }
.channel {
  display: flex; flex-direction: column; align-items: flex-start;
  padding: 32px; border-radius: var(--radius);
  background: #fff; border: 1px solid var(--line); box-shadow: var(--shadow);
}
.channel__icon {
  width: 56px; height: 56px; border-radius: 14px; display: grid; place-items: center; color: #fff;
}
.channel__icon .icon { width: 28px; height: 28px; }
.channel--wa .channel__icon { background: var(--wa); }
.channel--tk .channel__icon { background: var(--navy); }
.channel__tag {
  margin-top: 20px; font-size: .75rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
}
.channel--wa .channel__tag { color: var(--wa); }
.channel--tk .channel__tag { color: var(--cyan-700); }
.channel h3 { font-size: 1.375rem; font-weight: 800; margin-top: 6px; }
.channel > p { margin-top: 10px; }
.channel .checks { margin-bottom: 28px; }
.channel .btn { margin-top: auto; }
@media (max-width: 479px) { .channel { padding: 24px; } .channel .btn { width: 100%; } }

/* --------------------------------------------------------------- contacto */
.contact {
  display: grid; overflow: hidden;
  background: #fff; border: 1px solid var(--line); border-radius: 20px; box-shadow: var(--shadow);
}
.contact__info { padding: 32px 24px; }
.contact__info h2 { font-size: clamp(1.75rem, 3.6vw, 2.25rem); font-weight: 800; margin-top: 12px; }
.contact__info > p { margin-top: 14px; }
.contact__list { margin-top: 32px; display: grid; gap: 22px; }
.contact__item { display: flex; gap: 16px; align-items: flex-start; }
.contact__item .pillar__icon { border-radius: 50%; }
.contact__item dt { font-family: var(--font-head); font-weight: 700; color: var(--ink); }
.contact__item dd { font-size: .9688rem; overflow-wrap: anywhere; }
.contact__item dd a { font-weight: 500; }

.contact__aside {
  position: relative; overflow: hidden;
  display: flex; flex-direction: column; justify-content: flex-end;
  min-height: 280px; padding: 32px 24px;
  background: linear-gradient(160deg, var(--navy-2), var(--navy));
  color: #c5d4e0;
}
.contact__aside::before {
  content: ""; position: absolute; inset: 0;
  background: url("../img/patron-red.svg") center / 700px auto; opacity: .45;
}
.contact__aside > * { position: relative; }
.contact__aside img { width: 190px; margin-bottom: 20px; }
.contact__aside p { max-width: 38ch; }
.contact__aside strong { display: block; font: 800 1.375rem/1.25 var(--font-head); color: #fff; margin-bottom: 8px; }
@media (min-width: 900px) {
  .contact { grid-template-columns: 1.15fr .85fr; }
  .contact__info { padding: 56px; }
  .contact__aside { padding: 56px 48px; }
}

/* ----------------------------------------------------------------- footer */
.site-footer { background: #071726; color: #a9bccb; padding-block: 56px 96px; font-size: .9375rem; }
.site-footer__grid { display: grid; gap: 36px; }
.site-footer img { width: 170px; }
.site-footer__about p { margin-top: 16px; max-width: 40ch; }
.site-footer h2 {
  font: 700 .8125rem/1 var(--font-body); letter-spacing: .08em; text-transform: uppercase;
  color: #fff; margin-bottom: 14px;
}
.site-footer li + li { margin-top: 4px; }
.site-footer a { display: inline-block; padding: 5px 0; color: #d3e0ea; text-decoration: none; }
.site-footer a:hover { color: #fff; text-decoration: underline; }
.site-footer__bottom {
  margin-top: 40px; padding-top: 24px; border-top: 1px solid rgba(255, 255, 255, .12);
  font-size: .875rem;
}
@media (min-width: 800px) {
  .site-footer__grid { grid-template-columns: 1.6fr 1fr 1fr; gap: 48px; }
  .site-footer { padding-bottom: 56px; }
}

/* ------------------------------------------------------ WhatsApp flotante */
.wa-float {
  position: fixed; right: 16px; bottom: 16px; z-index: 90;
  display: inline-flex; align-items: center; gap: 10px;
  min-height: 56px; padding: 0 16px;
  background: var(--wa); color: #fff; text-decoration: none; font-weight: 600;
  border-radius: 999px; border: 2px solid #fff;
  box-shadow: 0 10px 28px rgba(10, 31, 51, .3);
  transition: background-color .2s, transform .2s;
}
.wa-float:hover { background: var(--wa-hover); color: #fff; transform: translateY(-2px); }
.wa-float:focus-visible { outline-color: var(--navy); }
.wa-float .icon { width: 26px; height: 26px; }
.wa-float__text { display: none; }
@media (min-width: 700px) {
  .wa-float { right: 24px; bottom: 24px; padding: 0 22px 0 18px; }
  .wa-float__text { display: inline; }
}

/* ------------------------------------------------------------ animaciones */
.js .reveal { opacity: 0; transform: translateY(18px); transition: opacity .6s ease, transform .6s ease; }
.js .reveal.is-visible { opacity: 1; transform: none; }

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

@media print {
  .site-header, .wa-float, .nav-toggle { display: none !important; }
  .js .reveal { opacity: 1; transform: none; }
}
