/* B22G — Shell CSS: header (nav) + footer + chrome común
 * Aplicado en todas las páginas para unificar diseño con el home (estilo dark).
 * Extraído de index.html (rebrand v1.0 mayo 2026).
 *
 * Carga DESPUÉS de styles.css para tener precedencia sobre el chrome legacy.
 * NO toca el contenido interior de la página — eso sigue usando styles.css.
 */

/* ----- Variables de marca (rebrand v1.0) ----- */
:root {
  --b22g-bg: #0a0a0a;
  --b22g-bg2: #141414;
  --b22g-bg3: #1c1c1c;
  --b22g-orange: #e8491d;
  --b22g-orange2: #ff6b35;
  --b22g-cream: #f5f0e8;
  --b22g-w: #fafafa;
  --b22g-g: #8a8a8a;
  --b22g-g2: #555;
  --b22g-line: rgba(255, 255, 255, .08);
  --b22g-f: 'Inter', system-ui, sans-serif;
  --b22g-fd: 'Bricolage Grotesque', 'Space Grotesk', sans-serif;
}

/* ----- Override de variables legacy para dark mode ----- */
/* Cuando .b22g-shell está activo, redefinimos las variables del sistema
 * legacy (styles.css) para que TODOS los componentes hereden la paleta dark
 * del home sin necesidad de reescribir el HTML.
 */
body.b22g-shell {
  --primary:        #e8491d;
  --primary-dark:   #c93a12;
  --primary-light:  #ff6b3d;
  --secondary:      #0a0a0a;
  --secondary-light:#141414;
  --accent:         #f0b429;
  --accent-light:   rgba(240, 180, 41, .08);
  --teal:           #45c2b1;

  --dark:           #0a0a0a;
  --dark-card:      #141414;
  --dark-border:    rgba(255, 255, 255, .08);
  --surface:        #0a0a0a;
  --bg:             #0a0a0a;
  --border:         rgba(255, 255, 255, .08);
  --text:           #fafafa;
  --text-secondary: #b8b8b8;
  --text-muted:     #8a8a8a;

  --color-primary:    var(--primary);
  --color-dark:       #fafafa;
  --color-text-light: #b8b8b8;
  --bg-light:         #141414;
  --shadow-sm:  0 2px 8px rgba(0,0,0,.5);
  --shadow-md:  0 8px 30px rgba(0,0,0,.6);
  --shadow-lg:  0 20px 50px rgba(0,0,0,.7);
  --shadow-xl:  0 25px 60px rgba(0,0,0,.8);
  --shadow-glow:0 0 40px rgba(232,73,29,.35);

  background: var(--b22g-bg);
  color: var(--b22g-w);
  font-family: var(--b22g-f);
  -webkit-font-smoothing: antialiased;
}
body.b22g-shell ::selection { background: var(--b22g-orange); color: var(--b22g-bg); }

/* ----- Overrides de componentes legacy (styles.css) ----- */

/* Tipografía heading con Bricolage Grotesque */
body.b22g-shell h1, body.b22g-shell h2, body.b22g-shell h3 {
  font-family: var(--b22g-fd);
  color: var(--b22g-w);
  letter-spacing: -.02em;
}
body.b22g-shell h1 { font-weight: 800; line-height: 1.05; }
body.b22g-shell h2 { font-weight: 700; line-height: 1.1; }
body.b22g-shell p { color: var(--b22g-g); }
body.b22g-shell strong, body.b22g-shell b { color: var(--b22g-w); }
body.b22g-shell a { color: var(--b22g-w); }
body.b22g-shell a:hover { color: var(--b22g-orange); }

/* Page-header (sub-hero de páginas internas) */
body.b22g-shell .page-header {
  background:
    linear-gradient(180deg, rgba(10,10,10,.78) 0%, rgba(10,10,10,.94) 100%),
    radial-gradient(ellipse 70% 50% at 80% 30%, rgba(232,73,29,.15) 0%, transparent 60%),
    radial-gradient(ellipse 60% 60% at 10% 80%, rgba(232,73,29,.06) 0%, transparent 60%),
    #0d0d0d;
  color: var(--b22g-w);
  padding: 140px 24px 80px;
  border-bottom: 1px solid var(--b22g-line);
  position: relative;
}
body.b22g-shell .page-header::before {
  content: '';
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.025) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: linear-gradient(180deg, transparent 0%, #000 30%, #000 70%, transparent 100%);
  -webkit-mask-image: linear-gradient(180deg, transparent 0%, #000 30%, #000 70%, transparent 100%);
  pointer-events: none;
}
body.b22g-shell .page-header > .container { position: relative; z-index: 1; }
body.b22g-shell .page-header h1 {
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  font-weight: 800; line-height: 1.05;
  margin-bottom: 1rem;
}
body.b22g-shell .page-header p {
  color: var(--b22g-g);
  font-size: clamp(1rem, 1.3vw, 1.15rem);
  max-width: 60ch;
  line-height: 1.6;
}
body.b22g-shell .page-header .breadcrumb {
  margin-bottom: 1.5rem;
}
body.b22g-shell .page-header .breadcrumb a,
body.b22g-shell .page-header .breadcrumb li {
  color: var(--b22g-g);
}
body.b22g-shell .page-header .breadcrumb .current {
  color: var(--b22g-w);
  font-weight: 600;
}

/* Secciones — todo dark */
body.b22g-shell .section--light,
body.b22g-shell .section--accent,
body.b22g-shell section.section--light,
body.b22g-shell section.section--accent {
  background: var(--b22g-bg);
  color: var(--b22g-w);
}
body.b22g-shell .section--dark {
  background: var(--b22g-bg2);
}
body.b22g-shell .section--gradient {
  background:
    linear-gradient(135deg, rgba(232,73,29,.18) 0%, rgba(10,10,10,1) 60%),
    var(--b22g-bg);
}
body.b22g-shell .section-label {
  color: var(--b22g-orange);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .15em;
}
body.b22g-shell .section-title {
  color: var(--b22g-w);
  font-family: var(--b22g-fd);
}
body.b22g-shell .section-subtitle {
  color: var(--b22g-g);
}

/* Cards (genéricas y específicas) */
body.b22g-shell .card,
body.b22g-shell .pricing-card,
body.b22g-shell .offer-card,
body.b22g-shell .scard {
  background: var(--b22g-bg2);
  border: 1px solid var(--b22g-line);
  color: var(--b22g-w);
  border-radius: 14px;
  transition: transform .25s, border-color .25s, background .25s;
}
body.b22g-shell .card:hover,
body.b22g-shell .pricing-card:hover,
body.b22g-shell .offer-card:hover,
body.b22g-shell .scard:hover {
  border-color: var(--b22g-orange);
  transform: translateY(-3px);
  background: var(--b22g-bg3);
}
body.b22g-shell .card-title,
body.b22g-shell .pricing-name {
  color: var(--b22g-w);
  font-family: var(--b22g-fd);
}
body.b22g-shell .card-text,
body.b22g-shell .pricing-description,
body.b22g-shell .pricing-features li {
  color: var(--b22g-g);
}
body.b22g-shell .pricing-features li {
  border-bottom: 1px solid var(--b22g-line);
  padding: 10px 0;
}
body.b22g-shell .pricing-price {
  color: var(--b22g-w);
  font-family: var(--b22g-fd);
}
body.b22g-shell .pricing-price .currency,
body.b22g-shell .pricing-price .period {
  color: var(--b22g-g);
}
body.b22g-shell .pricing-card.featured {
  border-color: var(--b22g-orange);
  background: linear-gradient(180deg, rgba(232,73,29,.06) 0%, var(--b22g-bg2) 100%);
}
body.b22g-shell .pricing-card.featured::before {
  content: attr(data-label);
  position: absolute; top: -12px; left: 24px;
  background: var(--b22g-orange); color: var(--b22g-bg);
  padding: 4px 12px; border-radius: 50px;
  font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em;
}
body.b22g-shell .pricing-card { position: relative; }

/* Botones */
body.b22g-shell .btn {
  font-weight: 700; letter-spacing: .03em;
  border-radius: 50px;
  transition: transform .15s, box-shadow .2s, background .2s, border-color .2s, color .2s;
}
body.b22g-shell .btn-primary {
  background: var(--b22g-orange);
  color: var(--b22g-bg);
  border: 0;
}
body.b22g-shell .btn-primary:hover {
  background: var(--b22g-w);
  transform: translateY(-1px);
}
body.b22g-shell .btn-ghost {
  background: transparent;
  color: var(--b22g-w);
  border: 1px solid rgba(255,255,255,.25);
}
body.b22g-shell .btn-ghost:hover {
  border-color: var(--b22g-orange);
  color: var(--b22g-orange);
}
body.b22g-shell .btn-white {
  background: var(--b22g-w);
  color: var(--b22g-bg);
}
body.b22g-shell .btn-whatsapp {
  background: #25d366;
  color: #fff;
}
body.b22g-shell .btn-whatsapp:hover {
  background: #1eb159;
  transform: translateY(-1px);
}

/* Formularios */
body.b22g-shell input[type="text"],
body.b22g-shell input[type="email"],
body.b22g-shell input[type="tel"],
body.b22g-shell input[type="number"],
body.b22g-shell textarea,
body.b22g-shell select {
  background: var(--b22g-bg2);
  color: var(--b22g-w);
  border: 1px solid var(--b22g-line);
  border-radius: 8px;
  padding: 12px 14px;
  font-family: inherit;
  font-size: 14px;
  width: 100%;
  transition: border-color .2s;
}
body.b22g-shell input:focus,
body.b22g-shell textarea:focus,
body.b22g-shell select:focus {
  outline: none;
  border-color: var(--b22g-orange);
}
body.b22g-shell label {
  color: var(--b22g-w);
  font-weight: 500;
  display: block;
  margin-bottom: 4px;
}

/* Tablas */
body.b22g-shell table {
  background: var(--b22g-bg2);
  color: var(--b22g-w);
  border-color: var(--b22g-line);
}
body.b22g-shell th, body.b22g-shell td {
  border-color: var(--b22g-line);
}

/* Split (text + image side by side) */
body.b22g-shell .split {
  background: transparent;
}
body.b22g-shell .split-img,
body.b22g-shell .split-img img {
  background: var(--b22g-bg2);
  border-radius: 14px;
}

/* List check */
body.b22g-shell .list-check li {
  color: var(--b22g-g);
}
body.b22g-shell .list-check li::before {
  color: var(--b22g-orange);
}

/* Trust pill (sectores/categorías) */
body.b22g-shell .trust-pill {
  background: var(--b22g-bg2);
  border-color: var(--b22g-line);
  color: var(--b22g-w);
}

/* Client result badge (en casos) */
body.b22g-shell .client-result {
  background: linear-gradient(90deg, var(--b22g-orange), rgba(232,73,29,.6));
  color: var(--b22g-bg);
  padding: 8px 18px;
  border-radius: 50px;
  display: inline-block;
  font-weight: 700;
  margin-top: 12px;
}

/* Ficha cliente / overrides para client-link */
body.b22g-shell .client-link--web {
  background: var(--b22g-bg3);
  color: var(--b22g-w);
  border: 1px solid var(--b22g-line);
}

/* FAQ details */
body.b22g-shell details {
  background: var(--b22g-bg2);
  border: 1px solid var(--b22g-line);
  border-radius: 10px;
  padding: 0;
  margin-bottom: 12px;
}
body.b22g-shell details summary {
  padding: 16px 20px;
  cursor: pointer;
  font-weight: 600;
  color: var(--b22g-w);
}
body.b22g-shell details p {
  padding: 0 20px 16px;
  color: var(--b22g-g);
}
body.b22g-shell details[open] summary {
  border-bottom: 1px solid var(--b22g-line);
  color: var(--b22g-orange);
}

/* Old site-header + site-footer leftovers (defensive) */
body.b22g-shell .site-header { display: none !important; }
body.b22g-shell .site-footer { display: none !important; }
body.b22g-shell .wa-float { display: none !important; }

/* ----- Header / nav (fixed, mix-blend) ----- */
.b22g-shell nav.b22g-nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  padding: 20px 0; mix-blend-mode: difference;
  transition: mix-blend-mode .15s, background .25s;
}
.b22g-shell nav.b22g-nav.sc,
.b22g-shell nav.b22g-nav:has(li.has-sub:hover),
.b22g-shell nav.b22g-nav:has(li.has-sub:focus-within),
.b22g-shell nav.b22g-nav:has(ul.b22g-links.op) {
  mix-blend-mode: normal;
  background: rgba(10, 10, 10, .92);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--b22g-line);
}
.b22g-shell .b22g-ni {
  max-width: 1480px; margin: 0 auto; padding: 0 40px;
  display: flex; justify-content: space-between; align-items: center;
}
.b22g-shell .b22g-logo {
  font-family: var(--b22g-fd); font-weight: 900; font-size: 24px;
  letter-spacing: -.04em; color: #fff; text-decoration: none;
  display: flex; align-items: center; gap: 12px;
}
.b22g-shell .b22g-logo b {
  display: inline-block; background: var(--b22g-orange); color: var(--b22g-bg);
  padding: 4px 10px; border-radius: 6px; font-size: 18px; font-weight: 900;
}
.b22g-shell ul.b22g-links {
  display: flex; gap: 36px; align-items: center; list-style: none; margin: 0; padding: 0;
}
.b22g-shell ul.b22g-links > li { position: relative; }
.b22g-shell ul.b22g-links a {
  font-size: 13px; font-weight: 500; color: #fff;
  position: relative; letter-spacing: -.01em; text-decoration: none;
  display: inline-flex; align-items: center; gap: 6px;
}
.b22g-shell ul.b22g-links a::after {
  content: ''; position: absolute; bottom: -6px; left: 0;
  width: 0; height: 1px; background: var(--b22g-orange);
  transition: width .35s cubic-bezier(.65, 0, .35, 1);
}
.b22g-shell ul.b22g-links a:hover::after,
.b22g-shell ul.b22g-links a:focus-visible::after { width: 100%; }
.b22g-shell ul.b22g-links .b22g-caret { font-size: 9px; opacity: .6; transition: transform .3s; }
.b22g-shell ul.b22g-links a.b22g-cta {
  background: var(--b22g-orange); color: var(--b22g-bg) !important;
  padding: 12px 22px; border-radius: 50px;
  font-weight: 700 !important; transition: all .3s;
}
.b22g-shell ul.b22g-links a.b22g-cta:hover { background: #fff; transform: translateY(-1px); }
.b22g-shell ul.b22g-links a.b22g-cta::after { display: none !important; }

/* Dropdowns */
.b22g-shell .b22g-sub {
  position: absolute; top: calc(100% + 14px); left: -16px;
  min-width: 240px; padding: 14px 0; margin: 0;
  background: rgba(20, 20, 20, .98);
  border: 1px solid var(--b22g-line); border-radius: 12px;
  list-style: none; opacity: 0; visibility: hidden;
  transform: translateY(-6px);
  transition: opacity .25s, transform .25s, visibility .25s;
  box-shadow: 0 20px 50px rgba(0, 0, 0, .45);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}
.b22g-shell .b22g-sub::before {
  content: ''; position: absolute; top: -10px; left: 0; right: 0; height: 14px;
}
.b22g-shell .b22g-sub li { display: block; }
.b22g-shell .b22g-sub a {
  display: block; padding: 9px 22px; font-size: 13px; font-weight: 500;
  color: rgba(255, 255, 255, .78); transition: all .2s;
}
.b22g-shell .b22g-sub a::after { display: none; }
.b22g-shell .b22g-sub a:hover,
.b22g-shell .b22g-sub a:focus-visible {
  color: var(--b22g-orange); background: rgba(232, 73, 29, .06); padding-left: 28px;
}
.b22g-shell .b22g-sub-divider {
  height: 1px; background: var(--b22g-line); margin: 8px 22px; list-style: none;
}
.b22g-shell ul.b22g-links > li.has-sub:hover > a .b22g-caret,
.b22g-shell ul.b22g-links > li.has-sub:focus-within > a .b22g-caret { transform: rotate(180deg); }
.b22g-shell ul.b22g-links > li.has-sub:hover > .b22g-sub,
.b22g-shell ul.b22g-links > li.has-sub:focus-within > .b22g-sub {
  opacity: 1; visibility: visible; transform: translateY(0);
}

/* Mobile toggle */
.b22g-shell .b22g-mt {
  display: none; background: none; border: 0; cursor: pointer; padding: 8px;
}
.b22g-shell .b22g-mt span {
  display: block; width: 24px; height: 2px; background: #fff;
  margin: 5px 0; transition: all .3s;
}
.b22g-shell .b22g-mt[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.b22g-shell .b22g-mt[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.b22g-shell .b22g-mt[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Offset para nav fixed (cuerpo no debe quedar tapado) */
.b22g-shell main, .b22g-shell .page-header { padding-top: 80px; }

/* ----- WhatsApp FAB ----- */
.b22g-shell a.b22g-wa {
  position: fixed; bottom: 24px; right: 24px; z-index: 99;
  width: 62px; height: 62px;
  background: #25d366; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 10px 40px rgba(37, 211, 102, .4);
  transition: transform .3s; will-change: transform;
}
.b22g-shell a.b22g-wa:hover { transform: scale(1.08); }
.b22g-shell a.b22g-wa svg { width: 30px; height: 30px; fill: #fff; }
.b22g-shell a.b22g-wa::before {
  content: ''; position: absolute; inset: -4px; border-radius: 50%;
  border: 2px solid #25d366; animation: b22g-ring 2.4s ease-out infinite; opacity: 0;
}
@keyframes b22g-ring {
  0%   { transform: scale(1);   opacity: 0; }
  30%  { opacity: .6; }
  100% { transform: scale(1.5); opacity: 0; }
}

/* ----- Footer ----- */
.b22g-shell footer.b22g-footer {
  padding: 100px 40px 40px; border-top: 1px solid var(--b22g-line);
  background: var(--b22g-bg2); color: var(--b22g-w);
  font-family: var(--b22g-f);
}
.b22g-shell .b22g-fwrap {
  max-width: 1480px; margin: 0 auto;
  display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr;
  gap: 60px; margin-bottom: 80px;
}
.b22g-shell .b22g-fcol h4 {
  font-family: var(--b22g-fd); font-size: 12px; font-weight: 700;
  color: #fff; margin: 0 0 22px;
  text-transform: uppercase; letter-spacing: .12em;
}
.b22g-shell .b22g-fcol p,
.b22g-shell .b22g-fcol a {
  font-size: 14px; color: var(--b22g-g); line-height: 2;
  display: block; transition: color .25s; text-decoration: none;
  margin: 0;
}
.b22g-shell .b22g-fcol a:hover,
.b22g-shell .b22g-fcol a:focus-visible { color: var(--b22g-orange); }
.b22g-shell .b22g-fcol .b22g-logo { font-size: 28px; margin-bottom: 24px; }
.b22g-shell .b22g-fbig {
  font-family: var(--b22g-fd); font-size: clamp(70px, 11vw, 180px);
  font-weight: 900; letter-spacing: -.06em; line-height: .9;
  color: transparent; -webkit-text-stroke: 1px var(--b22g-g2);
  text-align: center; padding: 60px 0;
  border-top: 1px solid var(--b22g-line); margin-top: 40px;
  text-transform: uppercase; overflow: hidden;
}
.b22g-shell .b22g-fbot {
  max-width: 1480px; margin: 0 auto; padding-top: 30px;
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: 20px; border-top: 1px solid var(--b22g-line);
}
.b22g-shell .b22g-fbot p {
  font-size: 11px; color: var(--b22g-g2);
  text-transform: uppercase; letter-spacing: .1em;
}
.b22g-shell .b22g-fbot .b22g-legal { display: flex; gap: 20px; }
.b22g-shell .b22g-fbot .b22g-legal a {
  font-size: 11px; color: var(--b22g-g2);
  text-transform: uppercase; letter-spacing: .1em;
}
.b22g-shell .b22g-fsoc { display: flex; gap: 12px; }
.b22g-shell .b22g-fsoc a {
  width: 42px; height: 42px; border-radius: 50%;
  border: 1px solid var(--b22g-line);
  display: flex; align-items: center; justify-content: center;
  transition: all .3s;
}
.b22g-shell .b22g-fsoc a:hover { background: var(--b22g-orange); border-color: var(--b22g-orange); }
.b22g-shell .b22g-fsoc a:hover svg { fill: var(--b22g-bg); }
.b22g-shell .b22g-fsoc svg { width: 14px; height: 14px; fill: var(--b22g-g); }
.b22g-shell .b22g-aje {
  margin-top: 18px; padding-top: 14px; border-top: 1px solid var(--b22g-line);
  font-size: 12px; color: var(--b22g-g);
}
.b22g-shell .b22g-aje::before {
  content: ''; display: inline-block; width: 8px; height: 8px;
  background: var(--b22g-orange); border-radius: 50%;
  margin-right: 8px; vertical-align: middle;
}
.b22g-shell .b22g-aje a { color: var(--b22g-w); font-weight: 600; }

/* ----- Responsive ----- */
@media (max-width: 1024px) {
  .b22g-shell .b22g-fwrap { grid-template-columns: 1fr 1fr; gap: 40px; }
}
@media (max-width: 768px) {
  .b22g-shell .b22g-ni { padding: 0 24px; }
  .b22g-shell ul.b22g-links { display: none; }
  .b22g-shell ul.b22g-links.op {
    display: flex; flex-direction: column; position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(10, 10, 10, .98);
    padding: 100px 30px 30px; gap: 20px; align-items: flex-start;
    z-index: 99; overflow-y: auto;
  }
  .b22g-shell ul.b22g-links.op a { font-size: 22px; }
  .b22g-shell ul.b22g-links.op .b22g-sub {
    position: static; opacity: 1; visibility: visible; transform: none;
    background: none; border: none; padding: 6px 0 0 16px; box-shadow: none;
    backdrop-filter: none; min-width: 0; margin-top: 4px;
  }
  .b22g-shell ul.b22g-links.op .b22g-sub a {
    font-size: 15px; padding: 6px 0; color: rgba(255, 255, 255, .6);
  }
  .b22g-shell ul.b22g-links.op .b22g-sub a:hover { padding-left: 8px; background: none; }
  .b22g-shell ul.b22g-links.op .b22g-sub-divider { display: none; }
  .b22g-shell ul.b22g-links.op .b22g-caret { display: none; }
  .b22g-shell .b22g-mt { display: block; position: relative; z-index: 101; }
  .b22g-shell footer.b22g-footer { padding: 80px 24px 30px; }
  .b22g-shell .b22g-fwrap { grid-template-columns: 1fr; gap: 36px; }
}

/* JS-anim removal */
html.js-anim .b22g-shell { /* placeholder */ }
