/* ==========================================================================
   RF SOLUTIONS — hoja de estilos principal
   Servicios informáticos y telecomunicaciones · Videovigilancia y seguridad
   ========================================================================== */

/* ---- Fuentes ---- */
@import url('https://fonts.googleapis.com/css2?family=Big+Shoulders+Display:wght@600;700;800;900&family=IBM+Plex+Sans:wght@400;500;600;700&family=IBM+Plex+Mono:wght@400;500;600&display=swap');

/* ---- Tokens de diseño ---- */
:root{
  /* superficies */
  --ink:        #0b1220;   /* fondo oscuro principal */
  --ink-2:      #101b2d;   /* tarjetas / paneles sobre oscuro */
  --ink-3:      #16233a;   /* bordes sobre oscuro */
  --paper:      #f5f7fa;   /* fondo claro principal */
  --paper-2:    #ffffff;   /* tarjetas sobre claro */
  --paper-3:    #eceff4;   /* franjas sutiles sobre claro */

  /* texto */
  --text-on-dark:       #eef2f7;
  --text-on-dark-muted: #93a2ba;
  --text-on-light:      #0b1220;
  --text-on-light-muted:#57657c;

  /* acento — tomado del punto cian del isotipo */
  --signal:      #00c2d6;
  --signal-2:    #0891a8;
  --signal-soft: rgba(0, 194, 214, .12);
  --signal-soft-2: rgba(0, 194, 214, .22);

  /* líneas */
  --line-on-dark:  rgba(255,255,255,.10);
  --line-on-light: rgba(11,18,32,.10);

  /* tipografía */
  --font-display: 'Big Shoulders Display', 'Arial Narrow', sans-serif;
  --font-body: 'IBM Plex Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-mono: 'IBM Plex Mono', ui-monospace, 'SFMono-Regular', Menlo, monospace;

  /* forma / ritmo */
  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 22px;
  --container: 1240px;
  --gutter: clamp(20px, 4vw, 48px);

  --shadow-sm: 0 2px 10px rgba(11,18,32,.06);
  --shadow-md: 0 12px 30px rgba(11,18,32,.10);
  --shadow-lg: 0 24px 60px rgba(11,18,32,.18);
  --shadow-signal: 0 10px 26px rgba(0,194,214,.28);

  --ease: cubic-bezier(.22,.9,.32,1);
}

/* ---- Reset básico ---- */
*, *::before, *::after{ box-sizing: border-box; }
html{ scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body, h1, h2, h3, h4, p, figure, blockquote, dl, dd{ margin: 0; }
ul, ol{ list-style: none; margin: 0; padding: 0; }
img, picture, svg{ display: block; max-width: 100%; }
button, input, textarea, select{ font: inherit; color: inherit; }
a{ color: inherit; text-decoration: none; }
button{ background: none; border: 0; cursor: pointer; }

@media (prefers-reduced-motion: reduce){
  html{ scroll-behavior: auto; }
  *, *::before, *::after{
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}

body{
  background: var(--paper);
  color: var(--text-on-light);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  overflow-x: hidden;
}

.container{
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

section{ position: relative; }
section[id], div[id]{ scroll-margin-top: 96px; }

/* ---- Texto utilitario ---- */
.eyebrow{
  display: inline-flex;
  align-items: center;
  gap: .55em;
  font-family: var(--font-mono);
  font-size: .78rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--signal-2);
  font-weight: 500;
}
.eyebrow::before{
  content: '';
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--signal);
  box-shadow: 0 0 0 3px var(--signal-soft);
  flex: none;
}
.on-dark .eyebrow{ color: var(--signal); }

h1, h2, h3, h4{
  font-family: var(--font-display);
  font-weight: 800;
  line-height: 1.02;
  letter-spacing: -.01em;
  text-wrap: balance;
}

h2.section-title{
  font-size: clamp(1.9rem, 3.6vw, 2.9rem);
  margin-top: .35em;
}
.section-head{
  max-width: 640px;
  margin-bottom: clamp(2rem, 5vw, 3.4rem);
}
.section-head p{
  margin-top: .9rem;
  color: var(--text-on-light-muted);
  font-size: 1.05rem;
}
.on-dark .section-head p{ color: var(--text-on-dark-muted); }

.section-pad{ padding-block: clamp(4rem, 9vw, 7.5rem); }
.on-dark{ background: var(--ink); color: var(--text-on-dark); }
.on-paper2{ background: var(--paper-2); }

/* ---- Botones ---- */
.btn{
  --btn-bg: var(--ink);
  --btn-fg: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .55em;
  padding: .95em 1.6em;
  border-radius: 999px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: .96rem;
  background: var(--btn-bg);
  color: var(--btn-fg);
  border: 1px solid transparent;
  box-shadow: var(--shadow-sm);
  transform: translateY(0);
  transition: transform .22s var(--ease), box-shadow .22s var(--ease), background-color .22s var(--ease), color .22s var(--ease), border-color .22s var(--ease);
  white-space: nowrap;
}
.btn svg{ width: 1.15em; height: 1.15em; flex: none; }
.btn:hover{ transform: translateY(-2px); box-shadow: var(--shadow-md); }
.btn:active{ transform: translateY(0px) scale(.98); box-shadow: var(--shadow-sm); }
.btn:focus-visible{ outline: 2px solid var(--signal); outline-offset: 3px; }

.btn-primary{ --btn-bg: var(--signal); --btn-fg: #04222a; }
.btn-primary:hover{ box-shadow: var(--shadow-signal); }

.btn-ghost{
  --btn-bg: transparent; --btn-fg: var(--text-on-light);
  border-color: var(--line-on-light);
  box-shadow: none;
}
.btn-ghost:hover{ border-color: var(--signal); color: var(--signal-2); box-shadow: var(--shadow-sm); }
.on-dark .btn-ghost, .btn-ghost.on-dark{ --btn-fg: var(--text-on-dark); border-color: var(--line-on-dark); }
.on-dark .btn-ghost:hover, .btn-ghost.on-dark:hover{ color: var(--signal); border-color: var(--signal); }

.btn-light{ --btn-bg: #fff; --btn-fg: var(--ink); }
.btn-block{ width: 100%; }

.hero-actions .btn-ghost{
  background: rgba(255,255,255,.08);
  border-color: rgba(255,255,255,.4);
  backdrop-filter: blur(6px);
}
.hero-actions .btn-ghost:hover{ background: rgba(255,255,255,.14); }

/* ==========================================================================
   HEADER + MEGA MENÚ
   ========================================================================== */
.site-header{
  position: fixed;
  inset-inline: 0;
  top: 0;
  z-index: 100;
  padding-block: 16px;
  transition: padding .3s var(--ease), background-color .3s var(--ease), box-shadow .3s var(--ease), border-color .3s var(--ease);
  border-bottom: 1px solid transparent;
}
.site-header::before{
  content: '';
  position: absolute; inset: 0;
  background: rgba(11,18,32,0);
  backdrop-filter: blur(0px);
  transition: background-color .3s var(--ease), backdrop-filter .3s var(--ease);
  z-index: -1;
}
.site-header.is-scrolled{
  padding-block: 10px;
  border-color: var(--line-on-dark);
  box-shadow: 0 8px 30px rgba(0,0,0,.18);
}
.site-header.is-scrolled::before{
  background: rgba(11,18,32,.86);
  backdrop-filter: blur(14px) saturate(140%);
}

.header-row{
  position: relative;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand{ display: flex; align-items: center; gap: .7rem; flex: none; }
.brand img{ height: 34px; width: auto; }
.brand-text{
  font-family: var(--font-mono);
  font-size: .68rem;
  letter-spacing: .16em;
  color: var(--text-on-dark-muted);
  text-transform: uppercase;
  line-height: 1.3;
}
.brand-text b{ display:block; color: var(--text-on-dark); font-size: .78rem; letter-spacing: .1em; }

.main-nav{ display: flex; align-items: center; gap: 2px; }
.main-nav > ul{ display: flex; align-items: center; gap: 2px; }
.nav-link{
  display: flex; align-items: center; gap: .4em;
  padding: .7em 1em;
  border-radius: 999px;
  font-size: .93rem;
  font-weight: 500;
  color: var(--text-on-dark-muted);
  transition: color .2s var(--ease), background-color .2s var(--ease);
}
.nav-link:hover, .nav-link:focus-visible{ color: var(--text-on-dark); background: rgba(255,255,255,.06); }
.nav-link.is-active{ color: var(--signal); }
.nav-link .chev{ width: 14px; height: 14px; transition: transform .25s var(--ease); opacity: .7; }
.has-mega:hover .chev, .has-mega:focus-within .chev{ transform: rotate(180deg); }

.header-cta{ display: flex; align-items: center; gap: 10px; flex: none; }
.header-phone{
  display: flex; align-items: center; gap: .5em;
  font-family: var(--font-mono);
  font-size: .85rem;
  color: var(--text-on-dark-muted);
}
.header-phone svg{ width: 16px; height: 16px; color: var(--signal); }

/* Mega menú */
.has-mega{ position: relative; }
.mega-panel{
  position: absolute;
  top: calc(100% + 14px);
  left: 50%;
  transform: translate(-50%, 8px);
  width: min(760px, 86vw);
  background: var(--ink-2);
  border: 1px solid var(--line-on-dark);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  padding: 20px;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity .22s var(--ease), transform .22s var(--ease), visibility .22s;
  z-index: 50;
}
.has-mega:hover .mega-panel,
.has-mega:focus-within .mega-panel{
  opacity: 1; visibility: visible; pointer-events: auto;
  transform: translate(-50%, 0);
}
.mega-grid{
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}
.mega-item{
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 14px;
  border-radius: var(--radius-md);
  transition: background-color .2s var(--ease), transform .2s var(--ease);
}
.mega-item:hover{ background: rgba(255,255,255,.05); transform: translateX(2px); }
.mega-icon{
  flex: none;
  width: 42px; height: 42px;
  border-radius: 12px;
  display: grid; place-items: center;
  background: var(--signal-soft);
  color: var(--signal);
}
.mega-icon svg{ width: 22px; height: 22px; }
.mega-item h4{ font-family: var(--font-body); font-size: .95rem; font-weight: 600; margin-bottom: .25em; color: var(--text-on-dark); }
.mega-item p{ font-size: .82rem; color: var(--text-on-dark-muted); line-height: 1.5; }
.mega-foot{
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid var(--line-on-dark);
  display: flex; align-items: center; justify-content: space-between;
  font-family: var(--font-mono); font-size: .78rem; color: var(--text-on-dark-muted);
}
.mega-foot a{ color: var(--signal); font-weight: 500; }

/* Botón hamburguesa (móvil) */
.mobile-nav{ display: none; }

.nav-toggle{
  display: none;
  flex: none;
  width: 44px; height: 44px;
  border-radius: 50%;
  align-items: center; justify-content: center;
  border: 1px solid var(--line-on-dark);
  color: var(--text-on-dark);
}
.nav-toggle svg{ width: 20px; height: 20px; }
.nav-toggle .icon-close{ display: none; }
.nav-toggle.is-open .icon-open{ display: none; }
.nav-toggle.is-open .icon-close{ display: block; }

/* ==========================================================================
   HERO + SLIDER
   ========================================================================== */
.hero{
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: flex-end;
  background: var(--ink);
  overflow: hidden;
}
.hero-video-wrap{ position: absolute; inset: 0; background: var(--ink); }
.hero-video{
  width: 100%; height: 100%;
  object-fit: cover;
  animation: hero-video-in 1.8s var(--ease);
}
@keyframes hero-video-in{
  0%{ opacity: 0; transform: scale(1.06); }
  100%{ opacity: 1; transform: scale(1); }
}
.hero-video-wrap::after{
  content: '';
  position: absolute; inset: 0;
  background:
    linear-gradient(0deg, rgba(5,9,16,.9) 2%, rgba(5,9,16,.5) 38%, rgba(5,9,16,.28) 62%, rgba(5,9,16,.68) 100%),
    linear-gradient(100deg, rgba(5,9,16,.82) 0%, rgba(5,9,16,.58) 30%, rgba(5,9,16,.18) 56%, rgba(5,9,16,.08) 100%);
}

.hero-content{
  position: relative;
  z-index: 5;
  width: 100%;
  padding-block: clamp(6rem, 15vw, 7.4rem) clamp(1.8rem, 4vw, 2.6rem);
  color: #fff;
}
.hero-badge{
  display: inline-flex; align-items: center; gap: .6em;
  font-family: var(--font-mono);
  font-size: .74rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: #d9e4ef;
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.16);
  padding: .5em 1em;
  border-radius: 999px;
  margin-bottom: 1.4rem;
  backdrop-filter: blur(6px);
}
.hero-badge .pulse-dot{ width: 8px; height: 8px; border-radius: 50%; background: var(--signal); position: relative; flex:none; }
.hero-badge .pulse-dot::after{
  content:''; position:absolute; inset:-5px; border-radius:50%;
  border: 1.5px solid var(--signal); animation: pulse-ring 2.2s var(--ease) infinite;
}
@keyframes pulse-ring{
  0%{ transform: scale(.4); opacity: .9; }
  80%{ transform: scale(1.6); opacity: 0; }
  100%{ opacity: 0; }
}

.hero h1{
  font-size: clamp(2.2rem, 5.6vw, 4.1rem);
  max-width: 19ch;
  color: #fff;
}
.hero h1 em{
  font-style: normal;
  color: var(--signal);
}
.hero-sub{
  margin-top: 1.3rem;
  max-width: 46ch;
  font-size: clamp(1rem, 1.6vw, 1.18rem);
  color: #cbd6e3;
}
.hero-actions{ display: flex; flex-wrap: wrap; gap: 14px; margin-top: 1.8rem; }

.hero-foot{
  position: relative; z-index: 5;
  display: flex; align-items: center; justify-content: space-between;
  gap: 20px;
  margin-top: clamp(1.8rem, 5vw, 2.8rem);
  padding-top: 1.2rem;
  border-top: 1px solid rgba(255,255,255,.14);
  flex-wrap: wrap;
}
.hero-caption{
  max-width: 34ch;
  font-size: .92rem;
  color: #cbd6e3;
}
.hero-live{
  display: inline-flex; align-items: center; gap: .55em;
  font-family: var(--font-mono);
  font-size: .78rem;
  letter-spacing: .06em;
  color: #eef2f7;
  flex: none;
  white-space: nowrap;
}
.hero-live .pulse-dot{ width: 7px; height: 7px; border-radius: 50%; background: var(--signal); position: relative; flex: none; }
.hero-live .pulse-dot::after{
  content:''; position:absolute; inset:-5px; border-radius:50%;
  border: 1.5px solid var(--signal); animation: pulse-ring 2.2s var(--ease) infinite;
}

.scroll-cue{
  position: absolute; right: var(--gutter); bottom: 26px; z-index: 6;
  display: none;
  writing-mode: vertical-rl;
  font-family: var(--font-mono); font-size: .72rem; letter-spacing: .18em;
  color: rgba(255,255,255,.55);
  align-items: center; gap: 10px;
}
.scroll-cue::after{ content:''; width: 1px; height: 34px; background: rgba(255,255,255,.4); }

/* ==========================================================================
   FRANJA DE VALORES
   ========================================================================== */
.values{
  background: var(--ink);
  border-top: 1px solid var(--line-on-dark);
}
.values-grid{
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--line-on-dark);
  border-radius: var(--radius-lg);
  overflow: hidden;
}
.value-card{
  background: var(--ink);
  padding: clamp(1.6rem, 3vw, 2.4rem);
  transition: background-color .25s var(--ease);
}
.value-card:hover{ background: var(--ink-2); }
.value-num{
  font-family: var(--font-mono);
  font-size: .78rem;
  color: var(--signal);
  letter-spacing: .12em;
}
.value-card h3{
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 1.2rem;
  margin-top: .7rem;
  margin-bottom: .55rem;
  letter-spacing: 0;
}
.value-card p{ color: var(--text-on-dark-muted); font-size: .95rem; }

/* ==========================================================================
   SERVICIOS
   ========================================================================== */
.services-grid{
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}
.service-card{
  position: relative;
  background: linear-gradient(165deg, var(--ink-2) 0%, var(--ink) 100%);
  border: 1px solid var(--ink-3);
  border-radius: var(--radius-lg);
  padding: clamp(1.6rem, 3vw, 2.2rem);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: transform .28s var(--ease), box-shadow .28s var(--ease), border-color .28s var(--ease);
}
.service-card:hover{
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg), var(--shadow-signal);
  border-color: var(--signal-soft-2);
}
.service-card::before{
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(120deg, transparent 30%, var(--signal-soft) 48%, transparent 66%);
  transform: translateX(-120%);
  transition: transform .8s var(--ease);
  pointer-events: none;
}
.service-card:hover::before{ transform: translateX(120%); }

.service-top{ display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.service-ch{ font-family: var(--font-mono); font-size: .78rem; color: var(--text-on-dark-muted); letter-spacing: .08em; }
.service-icon{
  width: 52px; height: 52px; border-radius: 14px;
  background: var(--signal-soft);
  border: 1px solid var(--signal-soft-2);
  color: var(--signal);
  display: grid; place-items: center;
  margin-top: 1.1rem;
}
.service-icon svg{ width: 27px; height: 27px; }
.service-card h3{
  font-family: var(--font-body);
  font-size: 1.28rem; font-weight: 800;
  color: #fff;
  margin-top: 1.1rem; margin-bottom: .55rem;
  letter-spacing: 0;
}
.service-card p{ color: var(--text-on-dark-muted); font-size: .97rem; }
.service-tags{ display: flex; flex-wrap: wrap; gap: 8px; margin-top: 1.1rem; }
.service-tag{
  font-family: var(--font-mono);
  font-size: .72rem;
  color: var(--signal);
  background: var(--signal-soft);
  border: 1px solid var(--signal-soft-2);
  padding: .35em .7em;
  border-radius: 999px;
}

/* ==========================================================================
   NOSOTROS
   ========================================================================== */
.about-wrap{
  display: grid;
  grid-template-columns: 1.05fr .95fr;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
}
.about-copy p{ color: var(--text-on-light-muted); font-size: 1.05rem; margin-top: 1rem; }
.about-copy p:first-of-type{ margin-top: 1.4rem; }
.about-stats{
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
  margin-top: 2rem;
}
.about-stat{
  border: 1px solid var(--line-on-light);
  border-radius: var(--radius-md);
  padding: 1.1rem 1.2rem;
  background: var(--paper-2);
}
.about-stat b{
  display: block;
  font-family: var(--font-display);
  font-size: 1.7rem;
  color: var(--signal-2);
}
.about-stat span{ font-size: .86rem; color: var(--text-on-light-muted); }

.about-frame{
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  aspect-ratio: 4/5;
  box-shadow: var(--shadow-lg);
}
.about-frame img{ width: 100%; height: 100%; object-fit: cover; }
.about-frame img.pancho-photo{ object-position: center 30%; }
.about-frame::after{
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(0deg, rgba(6,10,18,.75), transparent 45%);
}
.about-frame-tag{
  position: absolute; left: 18px; bottom: 18px; z-index: 2;
  color: #fff;
  font-family: var(--font-mono);
  font-size: .78rem;
  display: flex; align-items: center; gap: .5em;
}
.about-frame-tag .pulse-dot{ width: 7px; height: 7px; border-radius: 50%; background: var(--signal); }

/* ==========================================================================
   EQUIPO
   ========================================================================== */
.team-grid{
  display: grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap: 20px;
  max-width: 760px;
}
.team-card{
  background: var(--paper-2);
  border: 1px solid var(--line-on-light);
  border-radius: var(--radius-lg);
  padding: 1.8rem;
  transition: transform .25s var(--ease), box-shadow .25s var(--ease);
}
.team-card:hover{ transform: translateY(-5px); box-shadow: var(--shadow-md); }
.team-avatar{
  width: 62px; height: 62px; border-radius: 50%;
  background: var(--ink);
  color: var(--signal);
  display: grid; place-items: center;
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 800;
  border: 2px solid var(--signal-soft-2);
}
.team-card h3{
  font-family: var(--font-body); font-weight: 700;
  font-size: 1.1rem; margin-top: 1.1rem;
}
.team-role{
  font-family: var(--font-mono);
  font-size: .76rem;
  color: var(--signal-2);
  letter-spacing: .06em;
  text-transform: uppercase;
  margin-top: .3rem;
  display: block;
}
.team-card p{ margin-top: .8rem; color: var(--text-on-light-muted); font-size: .93rem; }

/* ==========================================================================
   GALERÍA DE PROYECTOS
   ========================================================================== */
.gallery-grid{
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-auto-rows: 210px;
  gap: 14px;
}
.gallery-item{
  position: relative;
  border-radius: var(--radius-md);
  overflow: hidden;
  cursor: zoom-in;
  background: var(--ink);
}
.gallery-item.tall{ grid-row: span 2; }
.gallery-item.wide{ grid-column: span 2; }
.gallery-item img{
  width: 100%; height: 100%; object-fit: cover;
  transition: transform .6s var(--ease);
}
.gallery-item:hover img{ transform: scale(1.06); }
.gallery-caption{
  position: absolute; inset: auto 0 0 0;
  padding: 14px 16px;
  background: linear-gradient(0deg, rgba(6,10,18,.88), transparent);
  color: #fff;
  font-size: .84rem;
  transform: translateY(8px);
  opacity: 0;
  transition: transform .3s var(--ease), opacity .3s var(--ease);
}
.gallery-item:hover .gallery-caption{ transform: translateY(0); opacity: 1; }
.gallery-scan{
  position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 46%, rgba(0,194,214,.22) 50%, transparent 54%);
  transform: translateY(-100%);
  transition: transform .7s var(--ease);
  pointer-events: none;
}
.gallery-item:hover .gallery-scan{ transform: translateY(100%); }

/* Lightbox */
.lightbox{
  position: fixed; inset: 0; z-index: 300;
  display: none;
  align-items: center; justify-content: center;
  background: rgba(6,10,18,.94);
  padding: 5vh 5vw;
}
.lightbox.is-open{ display: flex; }
.lightbox figure{ max-width: 1100px; width: 100%; }
.lightbox img{ width: 100%; max-height: 78vh; object-fit: contain; border-radius: var(--radius-md); }
.lightbox figcaption{ color: #cbd6e3; font-size: .9rem; margin-top: 14px; text-align: center; font-family: var(--font-mono); }
.lightbox-close{
  position: absolute; top: 22px; right: 22px;
  width: 46px; height: 46px; border-radius: 50%;
  border: 1px solid rgba(255,255,255,.24);
  color: #fff; display: grid; place-items: center;
}
.lightbox-close:hover{ background: rgba(255,255,255,.12); }
.lightbox-close svg{ width: 18px; height: 18px; }
.lightbox-nav{
  position: absolute; top: 50%; transform: translateY(-50%);
  width: 48px; height: 48px; border-radius: 50%;
  border: 1px solid rgba(255,255,255,.24); color: #fff;
  display: grid; place-items: center;
}
.lightbox-nav:hover{ background: rgba(255,255,255,.12); }
.lightbox-nav svg{ width: 18px; height: 18px; }
.lightbox-prev{ left: 22px; } .lightbox-next{ right: 22px; }

/* ==========================================================================
   CONTACTO
   ========================================================================== */
.contact-wrap{
  display: grid;
  grid-template-columns: .95fr 1.05fr;
  gap: clamp(2rem, 5vw, 3.6rem);
}
.contact-info-card{
  background: var(--ink-2);
  border: 1px solid var(--line-on-dark);
  border-radius: var(--radius-lg);
  padding: clamp(1.8rem, 3vw, 2.4rem);
}
.contact-info-row{
  display: flex; align-items: flex-start; gap: 14px;
  padding-block: 1rem;
  border-top: 1px solid var(--line-on-dark);
}
.contact-info-row:first-child{ border-top: 0; padding-top: 0; }
.contact-info-row .ic{
  width: 42px; height: 42px; border-radius: 12px; flex: none;
  background: var(--signal-soft); color: var(--signal);
  display: grid; place-items: center;
}
.contact-info-row .ic svg{ width: 20px; height: 20px; }
.contact-info-row h4{ font-family: var(--font-body); font-size: .96rem; font-weight: 600; color: var(--text-on-dark); }
.contact-info-row a, .contact-info-row span{ color: var(--text-on-dark-muted); font-size: .92rem; }
.contact-info-row a:hover{ color: var(--signal); }

.contact-form{
  background: var(--paper-2);
  border: 1px solid var(--line-on-light);
  border-radius: var(--radius-lg);
  padding: clamp(1.8rem, 3vw, 2.6rem);
  box-shadow: var(--shadow-md);
}
.form-row{ display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.field{ margin-bottom: 18px; }
.field label{
  display: block; font-family: var(--font-mono); font-size: .74rem;
  letter-spacing: .08em; text-transform: uppercase;
  color: var(--text-on-light-muted); margin-bottom: .5em;
}
.field input, .field select, .field textarea{
  width: 100%;
  padding: .85em 1em;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line-on-light);
  background: var(--paper);
  font-family: var(--font-body);
  font-size: .96rem;
  transition: border-color .2s var(--ease), box-shadow .2s var(--ease);
}
.field textarea{ resize: vertical; min-height: 120px; }
.field input:focus, .field select:focus, .field textarea:focus{
  outline: none; border-color: var(--signal); box-shadow: 0 0 0 4px var(--signal-soft);
}
.field-hint{ font-size: .78rem; color: var(--text-on-light-muted); margin-top: 1rem; }
.form-status{
  display: none;
  align-items: center; gap: .6em;
  font-size: .9rem; font-weight: 600;
  padding: .9em 1.1em; border-radius: var(--radius-sm);
  margin-bottom: 16px;
}
.form-status.is-visible{ display: flex; }
.form-status.ok{ background: var(--signal-soft); color: var(--signal-2); }
.form-status.err{ background: #ffe6e0; color: #b3401f; }

/* ==========================================================================
   FOOTER
   ========================================================================== */
.site-footer{
  background: var(--ink);
  color: var(--text-on-dark-muted);
  padding-top: clamp(3rem, 6vw, 4.5rem);
}
.footer-top{
  display: grid;
  grid-template-columns: 1.3fr .8fr .8fr 1fr;
  gap: 2rem;
  padding-bottom: clamp(2.4rem, 5vw, 3.5rem);
  border-bottom: 1px solid var(--line-on-dark);
}
.footer-brand img{ height: 30px; margin-bottom: 1rem; }
.footer-brand p{ font-size: .92rem; max-width: 34ch; line-height: 1.6; }
.footer-col h5{
  font-family: var(--font-mono); font-size: .74rem; letter-spacing: .1em;
  text-transform: uppercase; color: var(--text-on-dark);
  margin-bottom: 1.1rem;
}
.footer-col ul{ display: flex; flex-direction: column; gap: .7rem; }
.footer-col a{ font-size: .92rem; transition: color .2s var(--ease); }
.footer-col a:hover{ color: var(--signal); }
.footer-bottom{
  display: flex; align-items: center; justify-content: space-between;
  padding-block: 1.6rem; gap: 12px; flex-wrap: wrap;
  font-size: .82rem;
}
.footer-social{ display: flex; gap: 10px; }
.footer-social a{
  width: 38px; height: 38px; border-radius: 50%;
  border: 1px solid var(--line-on-dark);
  display: grid; place-items: center;
}
.footer-social a:hover{ border-color: var(--signal); color: var(--signal); }
.footer-social svg{ width: 17px; height: 17px; }

/* ==========================================================================
   BOTÓN DE SONIDO
   ========================================================================== */
.sound-toggle{
  position: fixed;
  left: clamp(16px, 4vw, 30px);
  bottom: clamp(16px, 4vw, 30px);
  z-index: 200;
  width: 50px; height: 50px;
  border-radius: 50%;
  background: var(--ink-2);
  border: 1px solid var(--line-on-dark);
  color: var(--text-on-dark);
  display: grid; place-items: center;
  box-shadow: var(--shadow-md);
  transition: transform .25s var(--ease), box-shadow .25s var(--ease), border-color .25s var(--ease), color .25s var(--ease);
}
.sound-toggle:hover{ transform: translateY(-3px); border-color: var(--signal); color: var(--signal); box-shadow: var(--shadow-lg); }
.sound-toggle:active{ transform: translateY(-1px) scale(.96); }
.sound-toggle svg{ width: 21px; height: 21px; }
.sound-toggle .ic-sound-off{ display: none; }
.sound-toggle.is-muted .ic-sound-on{ display: none; }
.sound-toggle.is-muted .ic-sound-off{ display: block; }
.sound-toggle-tooltip{
  position: absolute; left: 60px; top: 50%; transform: translateY(-50%);
  background: var(--ink); color: #fff;
  padding: .55em 1em; border-radius: 8px;
  font-size: .84rem; white-space: nowrap;
  opacity: 0; visibility: hidden; transition: opacity .2s var(--ease);
}
.sound-toggle:hover .sound-toggle-tooltip{ opacity: 1; visibility: visible; }

/* ==========================================================================
   REVEAL AL HACER SCROLL
   ========================================================================== */
.reveal{ opacity: 0; transform: translateY(26px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.reveal.is-visible{ opacity: 1; transform: translateY(0); }
.reveal-stagger > *{ transition-delay: calc(var(--i, 0) * 90ms); }

.skip-link{
  position: absolute; left: 12px; top: -60px;
  background: var(--signal); color: #04222a; font-weight: 700;
  padding: .8em 1.2em; border-radius: 8px; z-index: 999;
  transition: top .2s var(--ease);
}
.skip-link:focus{ top: 12px; }

/* ==========================================================================
   RESPONSIVE
   ========================================================================== */
@media (max-width: 1080px){
  .main-nav{ display: none; }
  .header-phone{ display: none; }
  .nav-toggle{ display: flex; }

  .mobile-nav{
    position: fixed; inset: 0; z-index: 1;
    background: var(--ink);
    padding: 100px 24px 40px;
    display: flex; flex-direction: column; gap: 4px;
    transform: translateX(100%);
    transition: transform .35s var(--ease);
    overflow-y: auto;
    visibility: hidden;
  }
  .mobile-nav.is-open{ visibility: visible; }
  .mobile-nav.is-open{ transform: translateX(0); }
  .mobile-nav a.nav-link{ font-size: 1.15rem; padding: .9em .3em; color: var(--text-on-dark); justify-content: flex-start; }
  .mobile-accordion summary{
    display: flex; align-items: center; justify-content: space-between;
    padding: .9em .3em; font-size: 1.15rem; color: var(--text-on-dark); cursor: pointer;
    list-style: none;
  }
  .mobile-accordion summary::-webkit-details-marker{ display:none; }
  .mobile-accordion summary svg{ width: 18px; height: 18px; transition: transform .25s var(--ease); }
  .mobile-accordion[open] summary svg{ transform: rotate(180deg); }
  .mobile-sub{ padding: 4px 0 14px 8px; display: flex; flex-direction: column; gap: 2px; }
  .mobile-sub a{
    display: flex; align-items: center; gap: 12px;
    padding: .7em .5em; border-radius: 10px; color: var(--text-on-dark-muted); font-size: .96rem;
  }
  .mobile-sub a:hover{ background: rgba(255,255,255,.05); color: #fff; }
  .mobile-sub .mega-icon{ width: 34px; height: 34px; }
  .mobile-sub .mega-icon svg{ width: 18px; height: 18px; }
  .mobile-nav-actions{ margin-top: auto; padding-top: 20px; display: flex; flex-direction: column; gap: 12px; }

  .about-wrap{ grid-template-columns: 1fr; }
  .about-frame{ order: -1; aspect-ratio: 16/10; }
  .about-frame img.pancho-photo{ object-position: center 35%; }
  .contact-wrap{ grid-template-columns: 1fr; }
  .services-grid{ grid-template-columns: 1fr 1fr; }
}

@media (max-width: 860px){
  .values-grid{ grid-template-columns: 1fr; }
  .gallery-grid{ grid-template-columns: repeat(2, 1fr); grid-auto-rows: 190px; }
  .gallery-item.wide{ grid-column: span 2; }
  .gallery-item.tall{ grid-row: span 1; }
  .footer-top{ grid-template-columns: 1fr 1fr; row-gap: 2.2rem; }
}

@media (max-width: 680px){
  .services-grid{ grid-template-columns: 1fr; }
  .team-grid{ grid-template-columns: 1fr; }
  .form-row{ grid-template-columns: 1fr; }
  .about-stats{ grid-template-columns: 1fr 1fr; }
  .hero-foot{ justify-content: center; text-align: center; }
  .hero-actions{ justify-content: center; }
  .hero{ align-items: flex-end; }
  .hero-content{ padding-bottom: 84px; }
  .footer-top{ grid-template-columns: 1fr; }
  .footer-bottom{ flex-direction: column; text-align: center; }
  .gallery-grid{ grid-template-columns: 1fr; grid-auto-rows: 240px; }
  .gallery-item.wide{ grid-column: span 1; }
}

@media (min-width: 1400px){
  .scroll-cue{ display: flex; }
}

/* ---- Móviles pequeños (teléfonos ≤ 480px) ---- */
@media (max-width: 480px){
  html{ font-size: 15px; }

  .hero-foot{
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }
  .hero-actions{ flex-direction: column; align-items: stretch; }
  .hero-actions .btn{ width: 100%; }
  .hero-badge{ font-size: .68rem; padding: .45em .85em; }

  .about-stats{ grid-template-columns: 1fr 1fr; gap: 10px; }
  .about-stat{ padding: .9rem 1rem; }

  .value-card{ padding: 1.4rem; }

  .service-card{ padding: 1.3rem; }
  .team-card{ padding: 1.4rem; }

  .gallery-grid{ gap: 10px; grid-auto-rows: 200px; }

  .contact-info-card, .contact-form{ padding: 1.4rem; }

  .footer-top{ gap: 1.8rem; }
  .sound-toggle{ width: 44px; height: 44px; }
  .sound-toggle svg{ width: 18px; height: 18px; }
  .sound-toggle-tooltip{ display: none; }

  .lightbox-nav{ width: 40px; height: 40px; }
  .lightbox-close{ width: 40px; height: 40px; top: 14px; right: 14px; }
  .lightbox-prev{ left: 10px; } .lightbox-next{ right: 10px; }
}

/* ---- Teléfonos muy angostos (≤ 360px) ---- */
@media (max-width: 360px){
  .about-stats{ grid-template-columns: 1fr; }
  .hero-live{ display: none; }
}

/* ---- Móviles en horizontal (poca altura) ---- */
@media (max-height: 500px) and (orientation: landscape){
  .hero{ min-height: auto; }
  .hero-content{ padding-block: 96px 1.6rem; }
  .hero-foot{ margin-top: 1.2rem; }
}

/* ---- Pantallas táctiles: sin estados hover pegajosos ---- */
@media (hover: none){
  .service-card:hover{ transform: none; box-shadow: var(--shadow-sm); }
  .team-card:hover{ transform: none; box-shadow: none; }
  .gallery-item .gallery-caption{ transform: translateY(0); opacity: 1; }
}
