/* H Holding Group LLC — sitio del grupo. Azul marino + dorado (misma paleta que la web de H Business Services). */
:root {
  --bg: #f7f8fb; --bg-alt: #eef2f8; --surface: #ffffff;
  --ink: #0f1a2e; --ink-soft: #46526a; --line: #dbe2ee;
  --gold: #8a6a1f; --gold-fill: #c9a24a; --gold-ink: #0f1a2e;
  --night: #0b1a33; --night-2: #12264a; --night-ink: #eef2f9; --night-soft: #b9c4d8;
  --night-line: #243a62; --gold-on-night: #e2c17a;
  --ok: #2f6b3a; --soon: #8a4b12; --soon-bg: #fbeedd; --focus: #1f5fbf;
  --radius: 16px;
  --shadow: 0 1px 2px rgba(15,26,46,.06), 0 10px 30px rgba(15,26,46,.07);
  --shadow-up: 0 2px 6px rgba(15,26,46,.08), 0 22px 48px rgba(15,26,46,.16);
  --serif: "Playfair Display", Georgia, "Times New Roman", serif;
  --sans: "Inter", "Segoe UI", system-ui, -apple-system, Roboto, Arial, sans-serif;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #08111f; --bg-alt: #0d1a2f; --surface: #111f38; --ink: #eef2f9; --ink-soft: #b9c4d8;
    --line: #22355a; --gold: #e0b95e; --gold-fill: #d4af5a; --gold-ink: #0b1a33;
    --night: #060e1c; --night-2: #0d1b35; --night-line: #1f3358; --ok: #7cc68a; --focus: #8ab4ff;
    --soon: #f3c48a; --soon-bg: #3a2a14;
    --shadow: 0 1px 2px rgba(0,0,0,.4), 0 10px 30px rgba(0,0,0,.35);
    --shadow-up: 0 2px 6px rgba(0,0,0,.45), 0 22px 48px rgba(0,0,0,.5);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #08111f; --bg-alt: #0d1a2f; --surface: #111f38; --ink: #eef2f9; --ink-soft: #b9c4d8;
  --line: #22355a; --gold: #e0b95e; --gold-fill: #d4af5a; --gold-ink: #0b1a33;
  --night: #060e1c; --night-2: #0d1b35; --night-line: #1f3358; --ok: #7cc68a; --focus: #8ab4ff;
  --soon: #f3c48a; --soon-bg: #3a2a14;
  --shadow: 0 1px 2px rgba(0,0,0,.4), 0 10px 30px rgba(0,0,0,.35);
  --shadow-up: 0 2px 6px rgba(0,0,0,.45), 0 22px 48px rgba(0,0,0,.5);
  color-scheme: dark;
}

/* Idioma: español por defecto; inglés como opción */
html:not(.l-en) .en { display: none !important; }
html.l-en .es { display: none !important; }

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: var(--sans); font-size: 17px; line-height: 1.6;
  -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: var(--gold); }
a:focus-visible, button:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 6px; }
h1, h2, h3 { font-family: var(--serif); line-height: 1.2; margin: 0 0 .5em; }
h2 { font-size: clamp(1.8rem, 4vw, 2.6rem); }
h3 { font-size: 1.3rem; }
p { margin: 0 0 1em; }
.wrap { width: min(1140px, 100% - 32px); margin-inline: auto; }
.salto { position: absolute; left: -999px; top: 8px; background: var(--gold-fill); color: var(--gold-ink); padding: 8px 14px; z-index: 99; }
.salto:focus { left: 16px; }

/* Barra superior */
.barra { position: sticky; top: 0; z-index: 50; background: color-mix(in srgb, var(--night) 92%, transparent);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-bottom: 1px solid var(--night-line); color: var(--night-ink); }
.barra .wrap { display: flex; align-items: center; gap: 16px; min-height: 64px; }
.marca { display: flex; align-items: center; gap: 10px; color: var(--night-ink); text-decoration: none; font-weight: 700; letter-spacing: .2px; }
.marca-h { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center;
  background: linear-gradient(135deg, #e2c17a, #b08a35); color: #0b1a33; font-family: var(--serif); font-size: 1.3rem; font-weight: 800; }
.marca small { display: block; font-weight: 400; color: var(--night-soft); font-size: .72rem; letter-spacing: .6px; text-transform: uppercase; }
.menu { display: flex; gap: 4px; margin-left: auto; align-items: center; }
.menu a { color: var(--night-soft); text-decoration: none; padding: 8px 12px; border-radius: 10px; font-size: .95rem; }
.menu a:hover { color: var(--night-ink); background: var(--night-2); }
.botones { display: flex; gap: 6px; }
.btn-ico { background: transparent; border: 1px solid var(--night-line); color: var(--night-ink); border-radius: 10px;
  min-width: 40px; height: 40px; padding: 0 10px; cursor: pointer; font: 600 .85rem var(--sans); }
.btn-ico:hover { border-color: var(--gold-on-night); color: var(--gold-on-night); }
.hamb { display: none; }
@media (max-width: 860px) {
  .hamb { display: inline-block; margin-left: auto; }
  .menu { display: none; position: absolute; top: 64px; left: 0; right: 0; flex-direction: column; align-items: stretch;
    background: var(--night); border-bottom: 1px solid var(--night-line); padding: 8px 16px 16px; }
  .menu.abierto { display: flex; }
  .menu a { padding: 12px; }
}

/* Héroe */
.heroe { position: relative; background: radial-gradient(1200px 500px at 80% -10%, #1d3a6e 0%, transparent 60%),
  linear-gradient(180deg, var(--night) 0%, var(--night-2) 100%); color: var(--night-ink); overflow: hidden; padding: 96px 0 104px; }
.heroe::after { content: ""; position: absolute; inset: auto -10% -60px -10%; height: 120px; background: var(--bg); border-radius: 50% 50% 0 0 / 100% 100% 0 0; }
.heroe .wrap { position: relative; z-index: 1; display: grid; grid-template-columns: 1.25fr .9fr; gap: 48px; align-items: center; }
.etiqueta { display: inline-flex; gap: 8px; align-items: center; font-size: .8rem; letter-spacing: 1.2px; text-transform: uppercase;
  color: var(--gold-on-night); border: 1px solid #5a4a22; border-radius: 999px; padding: 6px 14px; margin-bottom: 20px; }
.heroe h1 { font-size: clamp(2.3rem, 6vw, 4rem); }
.heroe h1 em { font-style: normal; color: var(--gold-on-night); }
.heroe .lead { font-size: 1.15rem; color: var(--night-soft); max-width: 36em; }
.acciones { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.btn { display: inline-flex; align-items: center; gap: 8px; padding: 13px 22px; border-radius: 12px; font-weight: 600; text-decoration: none;
  transition: transform .2s ease, box-shadow .2s ease, background .2s; }
.btn-oro { background: var(--gold-fill); color: var(--gold-ink); box-shadow: 0 8px 24px rgba(201,162,74,.25); }
.btn-oro:hover { transform: translateY(-2px); box-shadow: 0 12px 30px rgba(201,162,74,.35); }
.btn-borde { border: 1px solid var(--night-line); color: var(--night-ink); }
.btn-borde:hover { border-color: var(--gold-on-night); }
/* Torre de pisos (ilustración original, solo CSS) */
.torre { justify-self: center; width: min(320px, 100%); display: flex; flex-direction: column; gap: 6px; }
.torre .piso { display: flex; align-items: center; gap: 12px; background: rgba(255,255,255,.05); border: 1px solid var(--night-line);
  border-radius: 10px; padding: 9px 14px; font-size: .9rem; color: var(--night-soft); opacity: 0; transform: translateX(20px);
  animation: entra .6s ease forwards; }
.torre .piso b { color: var(--gold-on-night); font-family: var(--serif); min-width: 1.4em; }
.torre .piso .luz { margin-left: auto; width: 8px; height: 8px; border-radius: 50%; background: #e2c17a; box-shadow: 0 0 10px #e2c17a; animation: late 3s ease-in-out infinite; }
.torre .piso:nth-child(odd) .luz { animation-delay: 1.4s; }
@keyframes entra { to { opacity: 1; transform: none; } }
@keyframes late { 0%,100% { opacity: .35; } 50% { opacity: 1; } }
@media (max-width: 860px) { .heroe { padding: 64px 0 96px; } .heroe .wrap { grid-template-columns: 1fr; } .torre { width: 100%; } }

/* Secciones */
section { padding: 88px 0; }
.alt { background: var(--bg-alt); }
.cabeza { max-width: 760px; margin-bottom: 40px; }
.cabeza .sup { color: var(--gold); font-weight: 700; text-transform: uppercase; letter-spacing: 1.4px; font-size: .8rem; }
.cabeza p { color: var(--ink-soft); font-size: 1.08rem; }
.rejilla { display: grid; gap: 22px; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.tarjeta { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 26px; box-shadow: var(--shadow);
  transition: transform .25s ease, box-shadow .25s ease; }
.tarjeta:hover { transform: translateY(-4px); box-shadow: var(--shadow-up); }
.tarjeta p { color: var(--ink-soft); }
.icono-num { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; background: var(--bg-alt);
  color: var(--gold); font-family: var(--serif); font-weight: 800; font-size: 1.2rem; margin-bottom: 14px; border: 1px solid var(--line); }
.mision { border-left: 4px solid var(--gold-fill); padding: 8px 0 8px 22px; font-family: var(--serif); font-size: clamp(1.25rem, 2.6vw, 1.6rem); margin: 32px 0 0; }

/* Empresas */
.empresa { display: grid; grid-template-columns: 88px 1fr; gap: 22px; align-items: start; }
.empresa + .empresa { margin-top: 22px; }
.empresa .avatar { width: 88px; height: 88px; border-radius: 22px; object-fit: cover; border: 1px solid var(--line); }
.avatar-letra { width: 88px; height: 88px; border-radius: 22px; display: grid; place-items: center; font-family: var(--serif); font-size: 2rem; font-weight: 800;
  background: linear-gradient(135deg, var(--night), var(--night-2)); color: var(--gold-on-night); }
.empresa h3 { font-size: 1.55rem; margin-bottom: .2em; }
.rol { color: var(--gold); font-weight: 600; font-size: .95rem; margin-bottom: .8em; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 4px 0 14px; padding: 0; list-style: none; }
.chips li { font-size: .85rem; border: 1px solid var(--line); border-radius: 999px; padding: 4px 12px; background: var(--bg); }
.chips li.pronto { color: var(--soon); background: var(--soon-bg); border-color: transparent; }
.sello { display: inline-block; font-size: .75rem; font-weight: 700; letter-spacing: .6px; text-transform: uppercase; border-radius: 999px; padding: 4px 11px; }
.sello.pronto { background: var(--soon-bg); color: var(--soon); }
.sello.vivo { background: color-mix(in srgb, var(--ok) 16%, transparent); color: var(--ok); }
.sello.prep { background: var(--bg-alt); color: var(--ink-soft); border: 1px solid var(--line); }
.enlace { font-weight: 600; text-decoration: none; }
.enlace:hover { text-decoration: underline; }
@media (max-width: 560px) { .empresa { grid-template-columns: 1fr; } }

/* Juegos */
.juegos { display: grid; gap: 22px; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); margin-top: 22px; }
.juego { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow);
  transition: transform .25s ease, box-shadow .25s ease; display: flex; flex-direction: column; }
.juego:hover { transform: translateY(-4px); box-shadow: var(--shadow-up); }
.juego .foto { position: relative; aspect-ratio: 16/9; overflow: hidden; background: var(--night); }
.juego .foto img { width: 100%; height: 100%; object-fit: cover; transition: opacity .6s ease, transform .6s ease; }
.juego:hover .foto img { transform: scale(1.04); }
.juego .foto img.b { position: absolute; inset: 0; opacity: 0; }
.juego .foto.cambia img.b { opacity: 1; }
.juego .foto .sello { position: absolute; top: 12px; left: 12px; }
.juego .cuerpo { padding: 20px 22px 22px; display: flex; flex-direction: column; gap: 6px; }
.juego .titulo { display: flex; gap: 12px; align-items: center; }
.juego .titulo img { width: 52px; height: 52px; border-radius: 12px; }
.juego h4 { font-family: var(--serif); font-size: 1.25rem; margin: 0; }
.edad { font-size: .8rem; font-weight: 700; color: var(--ink-soft); }
.juego p { color: var(--ink-soft); margin: 6px 0 0; font-size: .97rem; }
.mini { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); margin-top: 22px; }
.mini .tarjeta { padding: 20px; }

/* Cifras reales */
.cifras { display: flex; flex-wrap: wrap; gap: 14px; margin: 6px 0 12px; }
.cifra { background: var(--bg); border: 1px solid var(--line); border-radius: 12px; padding: 10px 16px; }
.cifra b { display: block; font-family: var(--serif); font-size: 1.5rem; color: var(--gold); }
.cifra span { font-size: .82rem; color: var(--ink-soft); }
.nota { font-size: .85rem; color: var(--ink-soft); }

/* Pasos (cómo trabajamos) */
.pasos { counter-reset: p; display: grid; gap: 22px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.pasos .tarjeta { position: relative; padding-top: 30px; }
.pasos .tarjeta::before { counter-increment: p; content: counter(p, decimal-leading-zero); position: absolute; top: 18px; right: 22px;
  font-family: var(--serif); font-size: 2rem; color: var(--line); font-weight: 800; }
.edificio { margin-top: 40px; display: grid; gap: 8px; }
.edificio .fila { display: grid; grid-template-columns: 70px 1fr; gap: 14px; align-items: center; background: var(--surface);
  border: 1px solid var(--line); border-radius: 12px; padding: 12px 16px; }
.edificio .fila b { font-family: var(--serif); color: var(--gold); }
.edificio .fila span { color: var(--ink-soft); }

/* Contacto */
.contacto { background: linear-gradient(180deg, var(--night), var(--night-2)); color: var(--night-ink); }
.contacto .cabeza p { color: var(--night-soft); }
.contacto .cabeza .sup { color: var(--gold-on-night); }
.datos { display: grid; gap: 18px; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.dato { border: 1px solid var(--night-line); border-radius: var(--radius); padding: 24px; background: rgba(255,255,255,.03); }
.dato small { color: var(--night-soft); text-transform: uppercase; letter-spacing: 1px; font-size: .75rem; }
.dato a, .dato strong { display: block; color: var(--gold-on-night); font-size: 1.1rem; margin-top: 6px; word-break: break-word; font-weight: 600; }

/* Pie */
footer { background: var(--night); color: var(--night-soft); padding: 40px 0; font-size: .92rem; border-top: 1px solid var(--night-line); }
footer .wrap { display: flex; flex-wrap: wrap; gap: 16px 32px; justify-content: space-between; }
footer a { color: var(--night-soft); }
footer a:hover { color: var(--gold-on-night); }
footer nav { display: flex; gap: 18px; flex-wrap: wrap; }

/* Páginas legales */
.legal { padding: 56px 0 80px; }
.legal .wrap { max-width: 820px; }
.borrador { background: var(--soon-bg); color: var(--soon); border-radius: 12px; padding: 14px 18px; font-weight: 600; margin-bottom: 28px; }
.legal h2 { font-size: 1.4rem; margin-top: 1.6em; }
.legal p, .legal li { color: var(--ink-soft); }

/* Animación al aparecer */
.aparece { opacity: 0; transform: translateY(22px); transition: opacity .7s ease, transform .7s ease; }
.aparece.visto { opacity: 1; transform: none; }
html.sin-js .aparece { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  .aparece, .torre .piso { opacity: 1; transform: none; }
}
