/* ===========================================
   MASTER STYLES - ARV 
   Ultra-Premium Corporate Accounting
   =========================================== */

/* ---------- CSS VARIABLES ---------- */
:root {
  --color-primary:       #0a1628;
  --color-primary-alt:   #0f1f3a;
  --color-primary-mid:   #152240;
  --color-accent:        #c8a45c;
  --color-accent-light:  #dbb97a;
  --color-accent-dark:   #a8873e;
  --color-accent-pale:   rgba(200,164,92,.08);
  --color-white:         #ffffff;
  --color-off-white:     #f8f7f4;
  --color-surface:       #f4f2ee;
  --color-light-gray:    #e8e6e1;
  --color-mid-gray:      #9a9490;
  --color-dark-gray:     #4a4440;
  --color-text:          #1a1614;
  --color-text-light:    #6b6560;
  --color-gradient-1:    linear-gradient(150deg, #0a1628 0%, #0f1f3a 50%, #152240 100%);
  --color-gradient-2:    linear-gradient(135deg, #b8903e 0%, #dbb97a 50%, #c8a45c 100%);
  --color-gradient-hero: linear-gradient(150deg, #060e1e 0%, #0a1628 40%, #0d1e38 100%);
  --font-display:        'Playfair Display', Georgia, serif;
  --font-body:           'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --shadow-sm:           0 2px 12px rgba(10,22,40,.07);
  --shadow-md:           0 8px 36px rgba(10,22,40,.12);
  --shadow-lg:           0 24px 64px rgba(10,22,40,.16);
  --shadow-card:         0 4px 24px rgba(10,22,40,.08), 0 1px 4px rgba(10,22,40,.05);
  --shadow-glow:         0 0 40px rgba(200,164,92,.18);
  --radius-sm:           10px;
  --radius-md:           16px;
  --radius-lg:           24px;
  --radius-xl:           32px;
  --transition:          .3s cubic-bezier(.22,.61,.36,1);
  --transition-slow:     .5s cubic-bezier(.22,.61,.36,1);
  --section-padding:     110px 0;
  --container-max:       1200px;
}

/* ---------- RESET ---------- */
*,*::before,*::after{box-sizing:border-box;margin:0;padding:0}
html{scroll-behavior:smooth;font-size:16px;scroll-padding-top:80px}
body{
  font-family:var(--font-body);
  color:var(--color-text);
  background:var(--color-white);
  line-height:1.7;
  -webkit-font-smoothing:antialiased;
  -moz-osx-font-smoothing:grayscale;
  overflow-x:hidden;
}
img{max-width:100%;display:block}
a{text-decoration:none;color:inherit}
ul{list-style:none}
button{cursor:pointer;border:none;background:none;font:inherit}
input,textarea,select{font:inherit;border:none;outline:none}

/* ---------- SELECTION ---------- */
::selection{background:var(--color-accent);color:var(--color-primary)}

/* ---------- CONTAINER ---------- */
.container{width:100%;max-width:var(--container-max);margin:0 auto;padding:0 24px}

/* ---------- SECTION PADDING ---------- */
.section-padding{padding:var(--section-padding)}

/* ---------- SECTION HEADER ---------- */
.section-header{text-align:center;max-width:680px;margin:0 auto 64px}
.section-badge{
  display:inline-flex;
  align-items:center;
  gap:8px;
  font-size:.7rem;
  font-weight:700;
  letter-spacing:3.5px;
  text-transform:uppercase;
  color:var(--color-accent-dark);
  background:rgba(200,164,92,.1);
  border:1px solid rgba(200,164,92,.25);
  padding:6px 20px;
  border-radius:100px;
  margin-bottom:24px;
}
.section-badge::before{
  content:'';
  display:inline-block;
  width:16px;
  height:1px;
  background:var(--color-accent);
  flex-shrink:0;
}
.section-title{
  font-family:var(--font-display);
  font-size:clamp(1.9rem,4vw,2.9rem);
  font-weight:700;
  color:var(--color-primary);
  line-height:1.18;
  margin-bottom:18px;
  letter-spacing:-.3px;
}
.section-desc{
  font-size:1rem;
  color:var(--color-text-light);
  line-height:1.85;
}

/* =====================
   HEADER / NAVBAR
   ===================== */
.header{
  position:fixed;
  top:0;left:0;right:0;
  z-index:1000;
  background:rgba(255,255,255,.95);
  backdrop-filter:blur(24px);
  -webkit-backdrop-filter:blur(24px);
  border-bottom:1px solid rgba(10,22,40,.07);
  transition:var(--transition);
}
.header::after{
  content:'';
  position:absolute;
  bottom:0;left:0;right:0;
  height:2px;
  background:var(--color-gradient-2);
  opacity:0;
  transition:opacity var(--transition);
}
.header.scrolled{
  box-shadow:0 4px 32px rgba(10,22,40,.1);
  background:rgba(255,255,255,.98);
}
.header.scrolled::after{opacity:1}
.navbar{
  display:flex;
  align-items:center;
  justify-content:space-between;
  height:92px;
}
/* Logo */
.logo{
  display:flex;
  align-items:center;
  gap:16px;
  position:relative;
  z-index:1;
}
.logo-mark{
  width:74px;
  height:74px;
  display:grid;
  place-items:center;
  border-radius:22px;
  background:linear-gradient(145deg, rgba(255,255,255,.96), rgba(244,242,238,.88));
  border:1px solid rgba(10,22,40,.08);
  box-shadow:0 16px 34px rgba(10,22,40,.1);
}
.logo-icon{
  font-size:1.6rem;
  color:var(--color-accent);
  line-height:1;
  transition:transform var(--transition);
}
.logo:hover .logo-icon{
  transform:rotate(-15deg) scale(1.1);
}
.logo-img{
  width:54px;height:54px;
  border-radius:0;
  object-fit:contain;
  flex-shrink:0;
  border:none;
  box-shadow:none;
  transition:opacity var(--transition), transform var(--transition);
}
.logo:hover .logo-img{
  opacity:.9;
  transform:scale(1.04);
}
.logo-copy{
  display:flex;
  flex-direction:column;
  gap:3px;
}
.logo-kicker{
  font-size:.68rem;
  font-weight:700;
  letter-spacing:3.4px;
  text-transform:uppercase;
  color:var(--color-accent-dark);
  line-height:1;
}
.logo-text{
  font-family:var(--font-display);
  font-size:clamp(1.3rem, 2vw, 1.7rem);
  font-weight:700;
  color:var(--color-primary);
  letter-spacing:-.4px;
  line-height:1.05;
}
.logo-highlight{color:var(--color-accent)}
/* Nav Menu */
.nav-menu{display:flex;align-items:center;gap:36px}
.nav-link{
  font-size:.82rem;
  font-weight:600;
  color:var(--color-text-light);
  letter-spacing:.6px;
  text-transform:uppercase;
  position:relative;
  padding:6px 0;
  transition:var(--transition);
}
.nav-link::after{
  content:'';
  position:absolute;
  bottom:-4px;left:50%;transform:translateX(-50%);
  width:0;height:2px;
  background:var(--color-gradient-2);
  border-radius:2px;
  transition:width var(--transition);
}
.nav-link:hover,.nav-link.active{color:var(--color-primary)}
.nav-link:hover::after,.nav-link.active::after{width:100%}
/* Nav Actions */
.nav-actions{display:flex;align-items:center;gap:16px}
.btn-phone{font-size:.8rem;padding:8px 20px}
.btn-whatsapp-nav{
  font-size:.8rem;
  padding:8px 20px;
  background:linear-gradient(135deg, #25d366 0%, #1fb856 100%);
  color:var(--color-white);
  box-shadow:0 12px 28px rgba(37,211,102,.22);
}
.btn-whatsapp-nav:hover{
  transform:translateY(-2px);
  box-shadow:0 16px 34px rgba(37,211,102,.28);
}

/* Menu Toggle */
.menu-toggle{
  display:none;
  flex-direction:column;
  gap:5px;
  padding:4px;
  cursor:pointer;
}
.bar{
  width:24px;height:2px;
  background:var(--color-primary);
  border-radius:2px;
  transition:var(--transition);
}

/* =====================
   BUTTONS
   ===================== */
.btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:8px;
  font-size:.875rem;
  font-weight:600;
  padding:14px 32px;
  border-radius:100px;
  transition:var(--transition);
  letter-spacing:.3px;
  white-space:nowrap;
  position:relative;
  overflow:hidden;
}
.btn-primary{
  background:var(--color-gradient-2);
  color:var(--color-primary);
  box-shadow:var(--shadow-glow);
}
.btn-primary::before{
  content:'';
  position:absolute;
  inset:0;
  background:linear-gradient(135deg, #dbb97a 0%, #e8ca8e 50%, #dbb97a 100%);
  opacity:0;
  transition:opacity var(--transition);
}
.btn-primary:hover::before{opacity:1}
.btn-primary:hover{
  transform:translateY(-2px);
  box-shadow:0 8px 40px rgba(200,164,92,.3);
}
.btn-primary span,.btn-primary .btn-arrow{position:relative;z-index:1}
.btn-primary::after{
  content:'';
  position:absolute;
  width:100%;height:100%;
  top:0;left:-100%;
  background:linear-gradient(90deg,transparent,rgba(255,255,255,.2),transparent);
  transition:left .5s;
}
.btn-primary:hover::after{left:100%}
.btn-outline{
  background:transparent;
  border:1.5px solid var(--color-primary);
  color:var(--color-primary);
}
.btn-outline:hover{
  background:var(--color-primary);
  color:var(--color-white);
  transform:translateY(-2px);
}
.btn-light{
  border-color:rgba(255,255,255,.4);
  color:var(--color-white);
}
.btn-light:hover{
  background:var(--color-white);
  color:var(--color-primary);
  border-color:var(--color-white);
}
.btn-sm{padding:10px 24px;font-size:.8rem}
.btn-submit{
  width:100%;
  padding:16px 32px;
  font-size:.95rem;
}
.btn-arrow{transition:transform .3s ease;position:relative;z-index:1}
.btn-submit:hover .btn-arrow{transform:translateX(4px)}

/* =====================
   HERO
   ===================== */
.hero{
  position:relative;
  min-height:100vh;
  display:flex;
  align-items:center;
  background:var(--color-gradient-hero);
  overflow:hidden;
  padding-top:80px;
}
.hero-overlay{
  position:absolute;
  inset:0;
  background:
    radial-gradient(ellipse at 72% 28%, rgba(200,164,92,.1) 0%, transparent 55%),
    radial-gradient(ellipse at 15% 80%, rgba(200,164,92,.05) 0%, transparent 45%);
  pointer-events:none;
}
.hero-bg-pattern{
  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:56px 56px;
  pointer-events:none;
}
.hero-content{
  position:relative;
  z-index:2;
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:60px;
  align-items:center;
  padding:40px 0;
}
/* Hero Text */
.hero-badge{
  display:inline-flex;
  align-items:center;
  gap:8px;
  font-size:.68rem;
  font-weight:700;
  letter-spacing:4px;
  text-transform:uppercase;
  color:var(--color-accent-light);
  background:rgba(200,164,92,.1);
  border:1px solid rgba(200,164,92,.2);
  padding:7px 20px;
  border-radius:100px;
  margin-bottom:28px;
  animation:fadeInDown .8s ease forwards;
  opacity:0;
}
.hero-badge::before{
  content:'';
  display:inline-block;
  width:18px;height:1px;
  background:var(--color-accent);
  flex-shrink:0;
}
.hero-title{
  font-family:var(--font-display);
  font-size:clamp(2.4rem,5vw,4.2rem);
  font-weight:700;
  color:var(--color-white);
  line-height:1.12;
  margin-bottom:24px;
  animation:fadeInUp 1s ease .2s forwards;
  opacity:0;
  letter-spacing:-.5px;
}
.hero-title-accent{
  background:var(--color-gradient-2);
  -webkit-background-clip:text;
  -webkit-text-fill-color:transparent;
  background-clip:text;
}
.hero-desc{
  font-size:1.05rem;
  color:rgba(255,255,255,.7);
  line-height:1.8;
  max-width:520px;
  margin-bottom:36px;
  animation:fadeInUp 1s ease .4s forwards;
  opacity:0;
}
.hero-buttons{
  display:flex;
  gap:16px;
  flex-wrap:wrap;
  margin-bottom:48px;
  animation:fadeInUp 1s ease .6s forwards;
  opacity:0;
}
.hero-stats{
  display:flex;
  gap:0;
  padding-top:36px;
  border-top:1px solid rgba(255,255,255,.08);
  animation:fadeInUp 1s ease .8s forwards;
  opacity:0;
}
.stat-item{
  position:relative;
  padding:0 40px 0 0;
  margin:0 40px 0 0;
}
.stat-item::after{
  content:'';
  position:absolute;
  right:0;top:4px;
  width:1px;height:calc(100% - 8px);
  background:rgba(255,255,255,.1);
}
.stat-item:last-child{
  padding:0;
  margin:0;
}
.stat-item:last-child::after{display:none}
.stat-number{
  font-family:var(--font-display);
  font-size:2.2rem;
  font-weight:700;
  color:var(--color-white);
  line-height:1;
}
.stat-plus,.stat-percent{
  font-size:1.3rem;
  font-weight:600;
  color:var(--color-accent);
  margin-left:2px;
}
.stat-label{
  display:block;
  font-size:.72rem;
  color:rgba(255,255,255,.45);
  margin-top:6px;
  letter-spacing:.8px;
  text-transform:uppercase;
}

@keyframes fadeInUp{
  from{opacity:0;transform:translateY(30px)}
  to{opacity:1;transform:translateY(0)}
}
@keyframes fadeInDown{
  from{opacity:0;transform:translateY(-20px)}
  to{opacity:1;transform:translateY(0)}
}

/* Hero Visual */
.hero-visual{
  position:relative;
  display:flex;
  justify-content:center;
  align-items:center;
  animation:fadeInRight 1s ease .5s forwards;
  opacity:0;
}
@keyframes fadeInRight{
  from{opacity:0;transform:translateX(40px)}
  to{opacity:1;transform:translateX(0)}
}
.hero-card{
  width:340px;
  background:rgba(255,255,255,.07);
  backdrop-filter:blur(20px);
  -webkit-backdrop-filter:blur(20px);
  border:1px solid rgba(255,255,255,.1);
  border-radius:var(--radius-lg);
  overflow:hidden;
  box-shadow:0 40px 80px rgba(0,0,0,.4), inset 0 1px 0 rgba(255,255,255,.06);
  transition:transform var(--transition), box-shadow var(--transition);
}
.hero-card:hover{
  transform:translateY(-10px) scale(1.01);
  box-shadow:0 60px 100px rgba(0,0,0,.45), inset 0 1px 0 rgba(255,255,255,.08);
}
.hero-card-header{
  display:flex;
  gap:8px;
  padding:16px 20px;
  border-bottom:1px solid rgba(255,255,255,.06);
}
.dot{
  width:10px;height:10px;
  border-radius:50%;
  transition:transform .2s;
}
.dot:hover{transform:scale(1.5)}
.dot-red{background:#ff5f56}
.dot-yellow{background:#ffbd2e}
.dot-green{background:#27c93f}
.hero-card-body{
  padding:24px 20px 20px;
}
.chart-bar-group{
  display:flex;
  align-items:flex-end;
  gap:12px;
  height:160px;
}
.chart-bar{
  flex:1;
  background:var(--color-gradient-2);
  border-radius:4px 4px 0 0;
  opacity:.8;
  transition:height 1s ease, opacity var(--transition);
  animation:barRise 1.2s ease forwards;
  transform-origin:bottom;
}
.chart-bar:hover{opacity:1}
@keyframes barRise{
  from{transform:scaleY(0)}
  to{transform:scaleY(1)}
}
.chart-bar:nth-child(1){animation-delay:.1s}
.chart-bar:nth-child(2){animation-delay:.2s}
.chart-bar:nth-child(3){animation-delay:.3s}
.chart-bar:nth-child(4){animation-delay:.4s}
.chart-bar:nth-child(5){animation-delay:.5s}
.chart-bar:nth-child(6){animation-delay:.6s}

.hero-card-footer{
  display:flex;
  justify-content:space-between;
  align-items:center;
  padding-top:16px;
  border-top:1px solid rgba(255,255,255,.06);
  margin-top:16px;
}
.card-footer-label{
  font-size:.75rem;
  color:rgba(255,255,255,.4);
  letter-spacing:1px;
  text-transform:uppercase;
}
.card-footer-value{
  font-family:var(--font-display);
  font-size:1.15rem;
  font-weight:700;
  color:var(--color-accent-light);
}
/* Hero shapes */
.hero-shape{
  position:absolute;
  border-radius:50%;
  pointer-events:none;
  filter:blur(60px);
  opacity:.12;
}
.shape-1{
  width:300px;height:300px;
  background:var(--color-accent);
  top:-80px;right:-80px;
  animation:float 6s ease-in-out infinite;
}
.shape-2{
  width:200px;height:200px;
  background:var(--color-accent-light);
  bottom:-40px;left:-40px;
  animation:float 8s ease-in-out infinite reverse;
}
@keyframes float{
  0%,100%{transform:translateY(0) scale(1)}
  50%{transform:translateY(-20px) scale(1.05)}
}

/* =====================
   SERVICIOS
   ===================== */
.servicios{background:var(--color-off-white);position:relative;overflow:hidden}
.servicios::before{
  content:'';
  position:absolute;
  top:0;left:0;right:0;
  height:3px;
  background:var(--color-gradient-2);
}
.servicios::after{
  content:'';
  position:absolute;
  inset:0;
  background-image:
    radial-gradient(circle at 80% 20%, rgba(200,164,92,.04) 0%, transparent 50%),
    radial-gradient(circle at 20% 80%, rgba(10,22,40,.03) 0%, transparent 50%);
  pointer-events:none;
}
.services-grid{
  display:grid;
  grid-template-columns:repeat(3,1fr);
  gap:28px;
  position:relative;
  z-index:1;
}
.service-card{
  background:var(--color-white);
  border-radius:var(--radius-md);
  padding:40px 32px;
  border:1px solid var(--color-light-gray);
  transition:var(--transition);
  position:relative;
  overflow:hidden;
  cursor:default;
}
.service-card::before{
  content:'';
  position:absolute;
  top:0;left:0;
  width:0;height:3px;
  background:var(--color-gradient-2);
  transition:width var(--transition-slow);
}
.service-card::after{
  content:'';
  position:absolute;
  bottom:0;right:0;
  width:80px;height:80px;
  background:radial-gradient(circle at 100% 100%, rgba(200,164,92,.06), transparent 70%);
  pointer-events:none;
  transition:opacity var(--transition);
  opacity:0;
}
.service-card:hover{
  transform:translateY(-10px);
  box-shadow:var(--shadow-lg), 0 0 0 1px rgba(200,164,92,.12);
  border-color:transparent;
}
.service-card:hover::before{width:100%}
.service-card:hover::after{opacity:1}
.service-icon{
  width:56px;height:56px;
  display:flex;
  align-items:center;
  justify-content:center;
  border-radius:14px;
  background:rgba(200,164,92,.08);
  color:var(--color-accent-dark);
  margin-bottom:24px;
  transition:var(--transition);
  border:1px solid rgba(200,164,92,.14);
}
.service-icon svg{width:26px;height:26px;stroke-width:1.6}
.service-card:hover .service-icon{
  background:var(--color-gradient-2);
  color:var(--color-primary);
  border-color:transparent;
  transform:scale(1.1) rotate(-5deg);
  box-shadow:var(--shadow-glow);
}
.service-title{
  font-family:var(--font-display);
  font-size:1.2rem;
  font-weight:600;
  color:var(--color-primary);
  margin-bottom:12px;
  line-height:1.3;
}
.service-desc{
  font-size:.875rem;
  color:var(--color-text-light);
  line-height:1.75;
  margin-bottom:24px;
}
.service-link{
  font-size:.8rem;
  font-weight:700;
  color:var(--color-accent-dark);
  transition:var(--transition);
  display:inline-flex;
  align-items:center;
  gap:6px;
  letter-spacing:.4px;
  text-transform:uppercase;
}
.service-link:hover{color:var(--color-primary);gap:10px}

/* =====================
   NOSOTROS
   ===================== */
.nosotros{background:var(--color-white);position:relative}
.nosotros-grid{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:80px;
  align-items:center;
}
.pilares{display:flex;flex-direction:column;gap:8px;margin:36px 0}
.pilar{
  display:flex;
  gap:20px;
  align-items:flex-start;
  padding:20px 24px;
  border-radius:var(--radius-sm);
  border:1px solid transparent;
  transition:var(--transition);
}
.pilar:hover{
  background:rgba(200,164,92,.05);
  border-color:rgba(200,164,92,.18);
  transform:translateX(6px);
  box-shadow:var(--shadow-sm);
}
.pilar-number{
  font-family:var(--font-display);
  font-size:1.3rem;
  font-weight:700;
  color:var(--color-accent);
  line-height:1;
  min-width:36px;
  opacity:.7;
}
.pilar-text h4{
  font-size:.95rem;
  font-weight:700;
  color:var(--color-primary);
  margin-bottom:5px;
  letter-spacing:.2px;
}
.pilar-text p{
  font-size:.85rem;
  color:var(--color-text-light);
  line-height:1.65;
}
/* Visual */
.nosotros-image-card{
  position:relative;
}
.nosotros-image-placeholder{
  width:100%;
  aspect-ratio:4/5;
  border-radius:var(--radius-lg);
  background:var(--color-gradient-1);
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  gap:12px;
  border:1px solid rgba(200,164,92,.15);
  box-shadow:var(--shadow-lg);
  transition:transform var(--transition);
}
.nosotros-image-placeholder:hover{
  transform:scale(1.02);
}
.placeholder-icon{
  font-size:3rem;
  color:var(--color-accent);
  opacity:.5;
}
.placeholder-text{
  font-family:var(--font-display);
  font-size:1.1rem;
  color:rgba(255,255,255,.5);
  letter-spacing:2px;
}
.nosotros-experience-badge{
  position:absolute;
  bottom:-24px;right:-24px;
  background:var(--color-gradient-2);
  color:var(--color-primary);
  padding:22px 28px;
  border-radius:var(--radius-md);
  text-align:center;
  box-shadow:var(--shadow-glow), var(--shadow-lg);
  animation:pulseBadge 3s ease-in-out infinite;
  border:2px solid rgba(255,255,255,.2);
}
@keyframes pulseBadge{
  0%,100%{box-shadow:0 0 20px rgba(200,164,92,.2)}
  50%{box-shadow:0 0 40px rgba(200,164,92,.4)}
}
.exp-number{
  display:block;
  font-family:var(--font-display);
  font-size:1.8rem;
  font-weight:700;
  line-height:1;
}
.exp-label{
  font-size:.7rem;
  font-weight:600;
  letter-spacing:.5px;
  margin-top:4px;
  opacity:.8;
}

/* =====================
   PROCESO
   ===================== */
.proceso{background:var(--color-off-white);position:relative;overflow:hidden}
.proceso::before{
  content:'';
  position:absolute;
  top:0;left:0;right:0;
  height:3px;
  background:var(--color-gradient-2);
}
.proceso-steps{
  display:flex;
  align-items:flex-start;
  justify-content:center;
  gap:0;
}
.step{
  text-align:center;
  flex:1;
  max-width:220px;
  transition:var(--transition);
  padding:8px;
}
.step:hover{transform:translateY(-10px)}
.step-circle{
  width:76px;height:76px;
  border-radius:50%;
  background:var(--color-white);
  border:2px solid rgba(200,164,92,.25);
  display:flex;
  align-items:center;
  justify-content:center;
  margin:0 auto 24px;
  box-shadow:var(--shadow-card);
  transition:var(--transition);
  position:relative;
}
.step-circle::before{
  content:'';
  position:absolute;
  inset:-5px;
  border-radius:50%;
  border:1.5px solid rgba(200,164,92,.12);
  transition:var(--transition);
}
.step:hover .step-circle{
  background:var(--color-gradient-2);
  border-color:transparent;
  transform:scale(1.08);
  box-shadow:var(--shadow-glow);
}
.step:hover .step-circle::before{
  border-color:rgba(200,164,92,.25);
  inset:-8px;
}
.step-num{
  font-family:var(--font-display);
  font-size:1.15rem;
  font-weight:700;
  color:var(--color-accent-dark);
  transition:color var(--transition);
}
.step:hover .step-num{color:var(--color-primary)}
.step-title{
  font-family:var(--font-display);
  font-size:1rem;
  font-weight:700;
  color:var(--color-primary);
  margin-bottom:10px;
  transition:color var(--transition);
  letter-spacing:.1px;
}
.step:hover .step-title{color:var(--color-accent-dark)}
.step-desc{
  font-size:.83rem;
  color:var(--color-text-light);
  line-height:1.65;
}
.step-connector{
  flex:0 0 60px;
  height:1px;
  background:linear-gradient(90deg, rgba(200,164,92,.4), rgba(200,164,92,.1));
  margin-top:38px;
  position:relative;
}
.step-connector::after{
  content:'';
  position:absolute;
  right:0;top:50%;
  transform:translateY(-50%);
  width:6px;height:6px;
  border-radius:50%;
  background:rgba(200,164,92,.3);
}

/* =====================
   TESTIMONIOS
   ===================== */
.testimonios{background:var(--color-white);position:relative;overflow:hidden}
.testimonios::before{
  content:'';
  position:absolute;
  inset:0;
  background:radial-gradient(ellipse at 50% 0%, rgba(200,164,92,.04) 0%, transparent 60%);
  pointer-events:none;
}
.testimonios-grid{
  display:grid;
  grid-template-columns:repeat(3,1fr);
  gap:28px;
  position:relative;
  z-index:1;
}
.testimonio-card{
  background:var(--color-off-white);
  border-radius:var(--radius-md);
  padding:36px 32px;
  border:1px solid var(--color-light-gray);
  transition:var(--transition);
  position:relative;
  overflow:hidden;
}
.testimonio-card::before{
  content:'';
  position:absolute;
  top:0;left:0;
  width:3px;height:0;
  background:var(--color-gradient-2);
  transition:height var(--transition-slow);
}
.testimonio-card::after{
  content:'\201C';
  position:absolute;
  top:12px;right:20px;
  font-family:var(--font-display);
  font-size:6rem;
  line-height:1;
  color:var(--color-accent);
  opacity:.07;
  pointer-events:none;
}
.testimonio-card:hover{
  transform:translateY(-8px);
  box-shadow:var(--shadow-lg);
  border-color:rgba(200,164,92,.18);
  background:var(--color-white);
}
.testimonio-card:hover::before{height:100%}
.testimonio-stars{
  color:var(--color-accent);
  font-size:.9rem;
  margin-bottom:18px;
  letter-spacing:3px;
}
.testimonio-text{
  font-size:.88rem;
  color:var(--color-text-light);
  line-height:1.8;
  margin-bottom:28px;
  font-style:italic;
  position:relative;
  z-index:1;
}
.testimonio-author{
  display:flex;
  align-items:center;
  gap:14px;
  padding-top:20px;
  border-top:1px solid var(--color-light-gray);
}
.author-avatar{
  width:46px;height:46px;
  border-radius:50%;
  background:var(--color-gradient-2);
  display:flex;
  align-items:center;
  justify-content:center;
  font-size:.78rem;
  font-weight:700;
  color:var(--color-primary);
  flex-shrink:0;
  border:2px solid rgba(200,164,92,.25);
}
.author-info{display:flex;flex-direction:column;gap:2px}
.author-name{
  font-size:.85rem;
  font-weight:700;
  color:var(--color-primary);
}
.author-role{
  font-size:.75rem;
  color:var(--color-mid-gray);
}

/* =====================
   CONTACTO
   ===================== */
.contacto{
  background:var(--color-gradient-hero);
  position:relative;
  overflow:hidden;
}
.contacto::before{
  content:'';
  position:absolute;
  inset:0;
  background:
    radial-gradient(ellipse at 18% 50%, rgba(200,164,92,.07) 0%, transparent 55%),
    linear-gradient(rgba(255,255,255,.015) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.015) 1px, transparent 1px);
  background-size:auto, 56px 56px, 56px 56px;
  pointer-events:none;
}
.contacto-grid{
  position:relative;
  z-index:1;
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:60px;
  align-items:center;
}
.contacto .section-badge{background:rgba(200,164,92,.15)}
.contacto .section-title{color:var(--color-white)}
.contacto .section-desc{color:rgba(255,255,255,.6)}
.contact-details{
  display:flex;
  flex-direction:column;
  gap:20px;
  margin-top:40px;
}
.contact-quick-actions{
  display:flex;
  flex-wrap:wrap;
  gap:14px;
  margin-top:30px;
}
.contact-item{
  display:flex;
  align-items:flex-start;
  gap:16px;
  padding:12px 16px;
  border-radius:var(--radius-sm);
  transition:var(--transition);
}
.contact-item:hover{
  background:rgba(200,164,92,.06);
  transform:translateX(4px);
}
.contact-icon{font-size:1.2rem;line-height:1.5;flex-shrink:0}
.contact-label{
  display:block;
  font-size:.7rem;
  font-weight:600;
  letter-spacing:1.5px;
  text-transform:uppercase;
  color:rgba(255,255,255,.4);
  margin-bottom:2px;
}
.contact-value{
  font-size:.9rem;
  color:rgba(255,255,255,.8);
  transition:var(--transition);
}
a.contact-value:hover{color:var(--color-accent)}
.btn-whatsapp{
  background:linear-gradient(135deg, #22c55e 0%, #16a34a 100%);
  color:var(--color-white);
  box-shadow:0 18px 34px rgba(34,197,94,.22);
}
.btn-whatsapp:hover{
  transform:translateY(-2px);
  box-shadow:0 22px 40px rgba(34,197,94,.26);
}
.contact-email-btn{
  border-color:rgba(255,255,255,.22);
  color:var(--color-white);
}
.contact-email-btn:hover{
  border-color:rgba(200,164,92,.5);
  color:var(--color-white);
}
/* Form */
.contacto-form-wrapper{
  background:rgba(255,255,255,.06);
  backdrop-filter:blur(24px);
  -webkit-backdrop-filter:blur(24px);
  border:1px solid rgba(255,255,255,.1);
  border-radius:var(--radius-lg);
  padding:44px;
  transition:var(--transition);
}
.contacto-form-wrapper:hover{
  border-color:rgba(200,164,92,.25);
  box-shadow:0 0 60px rgba(200,164,92,.07);
}
.contacto-form{display:flex;flex-direction:column;gap:22px}
.form-row{display:grid;grid-template-columns:1fr 1fr;gap:18px}
.form-group{display:flex;flex-direction:column;gap:8px}
.form-group label{
  font-size:.7rem;
  font-weight:700;
  letter-spacing:1.5px;
  text-transform:uppercase;
  color:rgba(255,255,255,.45);
}
.form-group input,.form-group textarea{
  padding:15px 20px;
  border-radius:var(--radius-sm);
  background:rgba(255,255,255,.07);
  border:1px solid rgba(255,255,255,.1);
  color:var(--color-white);
  font-size:.875rem;
  transition:var(--transition);
  font-family:var(--font-body);
}
.form-group input::placeholder,.form-group textarea::placeholder{
  color:rgba(255,255,255,.22);
}
.form-group input:focus,.form-group textarea:focus{
  border-color:rgba(200,164,92,.5);
  background:rgba(255,255,255,.1);
  box-shadow:0 0 0 4px rgba(200,164,92,.08);
  outline:none;
  transform:translateY(-2px);
}
.form-helper{
  font-size:.82rem;
  color:rgba(255,255,255,.5);
  margin-top:-4px;
}
.form-feedback{
  min-height:24px;
  font-size:.88rem;
  color:rgba(255,255,255,.75);
}
.form-feedback.is-success{color:#86efac}
.form-feedback.is-error{color:#fca5a5}

/* =====================
   FOOTER
   ===================== */
.footer{
  background:var(--color-primary);
  color:rgba(255,255,255,.6);
  padding:90px 0 0;
  position:relative;
}
.footer::before{
  content:'';
  position:absolute;
  top:0;left:0;right:0;
  height:3px;
  background:var(--color-gradient-2);
}
.footer-grid{
  display:grid;
  grid-template-columns:1.8fr 1fr 1fr 1fr;
  gap:60px;
  padding-bottom:64px;
  border-bottom:1px solid rgba(255,255,255,.06);
}
.footer .logo .logo-text{color:var(--color-white)}
.footer-desc{
  font-size:.84rem;
  margin:18px 0 28px;
  line-height:1.8;
  max-width:300px;
  color:rgba(255,255,255,.45);
}
.footer-social{display:flex;gap:10px}
.social-link{
  width:38px;height:38px;
  border-radius:50%;
  border:1px solid rgba(255,255,255,.1);
  display:flex;
  align-items:center;
  justify-content:center;
  font-size:.7rem;
  font-weight:700;
  color:rgba(255,255,255,.4);
  transition:var(--transition);
  text-transform:uppercase;
}
.social-link:hover{
  background:var(--color-accent);
  border-color:var(--color-accent);
  color:var(--color-primary);
  transform:translateY(-4px);
  box-shadow:0 8px 24px rgba(200,164,92,.25);
}
.footer-links h4{
  font-family:var(--font-display);
  font-size:.85rem;
  font-weight:700;
  color:var(--color-white);
  margin-bottom:24px;
  position:relative;
  padding-bottom:14px;
  letter-spacing:.3px;
  text-transform:uppercase;
}
.footer-links h4::after{
  content:'';
  position:absolute;
  bottom:0;left:0;
  width:28px;height:2px;
  background:var(--color-gradient-2);
  border-radius:2px;
}
.footer-links ul li{margin-bottom:12px}
.footer-links ul li a{
  font-size:.82rem;
  color:rgba(255,255,255,.4);
  transition:var(--transition);
  display:inline-flex;
  align-items:center;
  gap:6px;
}
.footer-links ul li a::before{
  content:'';
  display:inline-block;
  width:0;
  height:1px;
  background:var(--color-accent);
  transition:width var(--transition);
  flex-shrink:0;
}
.footer-links ul li a:hover{
  color:var(--color-accent);
  transform:translateX(6px);
}
.footer-links ul li a:hover::before{width:12px}
.footer-bottom{
  padding:28px 0;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:16px;
  flex-wrap:wrap;
  font-size:.78rem;
  color:rgba(255,255,255,.25);
}
.footer-admin-link{
  font-size:.84rem;
  color:rgba(255,255,255,.82);
  border-bottom:1px solid rgba(200,164,92,.35);
  transition:var(--transition);
}
.footer-admin-link:hover{
  color:var(--color-accent-light);
  border-bottom-color:var(--color-accent-light);
}

/* =====================
   BACK TO TOP
   ===================== */
.back-to-top{
  position:fixed;
  bottom:110px;right:22px;
  z-index:999;
  width:44px;height:44px;
  border-radius:50%;
  background:var(--color-primary);
  border:1px solid rgba(200,164,92,.3);
  color:var(--color-accent);
  display:flex;
  align-items:center;
  justify-content:center;
  font-size:1rem;
  box-shadow:var(--shadow-md);
  opacity:0;
  visibility:hidden;
  transform:translateY(20px);
  transition:var(--transition);
  cursor:pointer;
}
.back-to-top.visible{
  opacity:1;
  visibility:visible;
  transform:translateY(0);
}
.back-to-top:hover{
  background:var(--color-accent);
  color:var(--color-primary);
  border-color:var(--color-accent);
  transform:translateY(-4px);
  box-shadow:0 8px 30px rgba(200,164,92,.3);
}

/* =====================
   KEYFRAMES GLOBAL
   ===================== */
@keyframes shimmer{
  0%{background-position:-200% 0}
  100%{background-position:200% 0}
}

/* ===========================================
   ANIMATIONS - SCROLL
   =========================================== */
.fade-up{
  opacity:0;
  transform:translateY(30px);
  transition:opacity .6s ease,transform .6s ease;
}
.fade-up.visible{
  opacity:1;
  transform:translateY(0);
}

/* Stagger delays for service cards */
.service-card.fade-up:nth-child(1){transition-delay:0ms}
.service-card.fade-up:nth-child(2){transition-delay:100ms}
.service-card.fade-up:nth-child(3){transition-delay:200ms}
.service-card.fade-up:nth-child(4){transition-delay:300ms}
.service-card.fade-up:nth-child(5){transition-delay:400ms}
.service-card.fade-up:nth-child(6){transition-delay:500ms}

.testimonio-card.fade-up:nth-child(1){transition-delay:0ms}
.testimonio-card.fade-up:nth-child(2){transition-delay:150ms}
.testimonio-card.fade-up:nth-child(3){transition-delay:300ms}

.step.fade-up:nth-child(1){transition-delay:0ms}
.step.fade-up:nth-child(3){transition-delay:100ms}
.step.fade-up:nth-child(5){transition-delay:200ms}
.step.fade-up:nth-child(7){transition-delay:300ms}

/* ===========================================
   RESPONSIVE
   =========================================== */

/* ---- 1024px ---- */
@media(max-width:1024px){
  .hero-content{gap:40px}
  .hero-card{width:280px}
  .services-grid{grid-template-columns:repeat(2,1fr)}
  .testimonios-grid{grid-template-columns:repeat(2,1fr)}
  .footer-grid{grid-template-columns:1fr 1fr;gap:40px}
}

/* ---- 768px ---- */
@media(max-width:768px){
  .section-padding{padding:80px 0}
  .section-header{margin-bottom:44px}

  .navbar{height:84px}

  .logo{gap:12px}
  .logo-mark{
    width:60px;
    height:60px;
    border-radius:18px;
  }
  .logo-img{width:44px;height:44px}
  .logo-kicker{font-size:.58rem;letter-spacing:2.6px}
  .logo-text{font-size:1.08rem}

  /* Nav */
  .nav-menu{
    position:fixed;
    top:84px;left:0;right:0;
    flex-direction:column;
    background:rgba(255,255,255,.98);
    backdrop-filter:blur(20px);
    -webkit-backdrop-filter:blur(20px);
    padding:32px 24px;
    gap:20px;
    border-bottom:1px solid var(--color-light-gray);
    transform:translateY(-110%);
    opacity:0;
    transition:var(--transition);
    box-shadow:var(--shadow-md);
  }
  .nav-menu.active{
    transform:translateY(0);
    opacity:1;
  }
  .menu-toggle{display:flex}
  .menu-toggle.active .bar:nth-child(1){transform:rotate(45deg) translate(5px,5px)}
  .menu-toggle.active .bar:nth-child(2){opacity:0}
  .menu-toggle.active .bar:nth-child(3){transform:rotate(-45deg) translate(5px,-5px)}
  .btn-whatsapp-nav{display:none}
  .btn-phone{display:none}

  /* Hero */
  .hero-content{grid-template-columns:1fr;text-align:center;gap:48px}
  .hero-desc{margin:0 auto 36px}
  .hero-buttons{justify-content:center}
  .hero-stats{justify-content:center;gap:28px}
  .hero-visual{display:none}
  .hero-card{margin:0 auto;width:260px}
  .hero-visual .hero-card{display:block}
  .hero-visual{display:flex}

  /* Servicios */
  .services-grid{grid-template-columns:1fr}

  /* Nosotros */
  .nosotros-grid{grid-template-columns:1fr;gap:48px}
  .nosotros-visual{max-width:400px;margin:0 auto}

  /* Proceso */
  .proceso-steps{
    flex-direction:column;
    align-items:center;
    gap:32px;
  }
  .step{max-width:300px}
  .step-connector{
    width:2px;height:40px;
    flex:0 0 auto;
    background:linear-gradient(180deg, var(--color-accent), transparent);
    margin-top:0;
  }

  /* Testimonios */
  .testimonios-grid{grid-template-columns:1fr}

  /* Contacto */
  .contacto-grid{grid-template-columns:1fr;gap:40px}

  /* Footer */
  .footer-grid{grid-template-columns:1fr;gap:32px}
  .footer-brand{order:4}
}

/* ---- 480px ---- */
@media(max-width:480px){
  .container{padding:0 16px}
  .hero-title{font-size:1.9rem}
  .hero-stats{flex-wrap:wrap;gap:16px}
  .stat-number{font-size:1.5rem}
  .form-row{grid-template-columns:1fr}
  .contacto-form-wrapper{padding:24px}
  .nosotros-experience-badge{
    position:static;
    margin-top:24px;
    display:inline-block;
  }
  .btn{padding:12px 24px;font-size:.8rem}
}

/* ---- Prefers Reduced Motion ---- */
@media(prefers-reduced-motion:reduce){
  *,*::before,*::after{
    animation-duration:.01ms !important;
    animation-iteration-count:1 !important;
    transition-duration:.01ms !important;
  }
}

/* ===========================================
   CHATBOT - ARV Consultor
   (Apariencia estilo portal Sinergias)
   =========================================== */

/* ── Speech bubble flotante ── */
#chatInviteSpeech{
  position:fixed;
  right:90px;
  bottom:14px;
  max-width:220px;
  background:#fff;
  color:#15336f;
  font-size:.78rem;
  font-weight:600;
  line-height:1.4;
  padding:10px 14px;
  border-radius:16px 16px 4px 16px;
  box-shadow:0 4px 18px rgba(13,31,81,.18);
  border:1px solid rgba(36,82,173,.18);
  z-index:999;
  pointer-events:none;
  opacity:0;
  transform:scale(.85) translateY(6px);
  animation:chatSpeechIn .4s cubic-bezier(.34,1.56,.64,1) 1.5s forwards;
}
#chatInviteSpeech::after{
  content:'';
  position:absolute;
  right:-8px;
  bottom:10px;
  border:5px solid transparent;
  border-left-color:#fff;
  border-right:0;
  filter:drop-shadow(2px 0 1px rgba(13,31,81,.08));
}
@keyframes chatSpeechIn{
  to{opacity:1;transform:scale(1) translateY(0)}
}
@keyframes chatCursorBlink{
  0%,49%{opacity:1}
  50%,100%{opacity:0}
}

/* ── Cara flotante encima del launcher ── */
#chatInviteFace{
  position:fixed;
  right:41px;
  bottom:80px;
  font-size:18px;
  pointer-events:none;
  z-index:1000;
  animation:face-bounce 2.8s ease-in-out infinite;
  filter:drop-shadow(0 1px 4px rgba(0,0,0,.25));
  opacity:0;
  animation:chatSpeechIn .4s cubic-bezier(.34,1.56,.64,1) 1.5s forwards,face-bounce 2.8s ease-in-out 2s infinite;
}
@keyframes face-bounce{
  0%,100%{transform:translateY(0)}
  50%{transform:translateY(-4px)}
}

/* ── Mano agitando junto al launcher ── */
#chatInviteWave{
  position:fixed;
  right:72px;
  bottom:70px;
  font-size:22px;
  pointer-events:none;
  z-index:1000;
  transform-origin:95% 95%;
  filter:drop-shadow(0 1px 3px rgba(0,0,0,.3));
  opacity:0;
  animation:chatSpeechIn .4s cubic-bezier(.34,1.56,.64,1) 1.5s forwards,wave-hand 2.2s ease-in-out 2s infinite;
}
@keyframes wave-hand{
  0%{transform:rotate(0deg)}
  8%{transform:rotate(24deg)}
  16%{transform:rotate(-10deg)}
  24%{transform:rotate(20deg)}
  32%{transform:rotate(-6deg)}
  40%{transform:rotate(10deg)}
  48%,100%{transform:rotate(0deg)}
}

/* Ocultar burbuja/cara/mano cuando el chat está abierto */
.chatbot-toggle.open ~ #chatInviteSpeech,
.chatbot-toggle.open ~ #chatInviteFace,
.chatbot-toggle.open ~ #chatInviteWave{
  display:none;
}

/* ── Botón flotante del chat ── */
.chatbot-toggle{
  position:fixed;
  bottom:22px;
  right:22px;
  z-index:998;
  width:62px;
  height:62px;
  border-radius:50%;
  background:linear-gradient(165deg,#15336f 0%,#2452ad 55%,#77a7ff 100%);
  display:flex;
  align-items:center;
  justify-content:center;
  box-shadow:0 16px 32px rgba(13,31,81,.42),inset 0 1px 0 rgba(255,255,255,.4);
  cursor:pointer;
  border:1px solid rgba(255,255,255,.72);
  padding:0;
  overflow:visible;
  transition:transform .2s,box-shadow .2s;
  animation:launcher-restless 4s ease-in-out infinite;
}
@keyframes launcher-restless{
  0%,100%{box-shadow:0 16px 32px rgba(13,31,81,.42),inset 0 1px 0 rgba(255,255,255,.4)}
  50%{box-shadow:0 20px 40px rgba(13,31,81,.55),inset 0 1px 0 rgba(255,255,255,.4)}
}
.chatbot-toggle:hover{
  transform:scale(1.05);
  box-shadow:0 18px 36px rgba(12,30,74,.5);
  animation:none;
}
/* Punto verde "en línea" */
.chatbot-toggle::after{
  content:'';
  position:absolute;
  right:3px;
  top:3px;
  width:10px;
  height:10px;
  border-radius:50%;
  background:#4ade80;
  border:2px solid #fff;
  box-shadow:0 0 0 0 rgba(74,222,128,.52);
  animation:bp-pulse-dot 1.6s infinite;
}
.chat-toggle-logo{
  width:72%;
  height:72%;
  object-fit:contain;
  border-radius:0;
  display:block;
  filter:drop-shadow(0 2px 6px rgba(13,31,81,.45));
}
.chatbot-toggle .close-icon{
  display:none;
  font-size:1.3rem;
  color:#fff;
  font-weight:700;
}
.chatbot-toggle.open .chat-toggle-logo{display:none}
.chatbot-toggle.open .close-icon{display:block}
.chatbot-toggle.open::after{display:none}
.chatbot-toggle.open{opacity:0;pointer-events:none;transform:scale(.7)}

/* ── Contenedor del chat ── */
.chatbot-container{
  position:fixed;
  top:92px;
  bottom:18px;
  right:18px;
  z-index:997;
  width:min(380px,calc(100vw - 32px));
  height:auto;
  max-height:none;
  background:rgba(255,255,255,.88);
  border-radius:26px;
  border:1px solid rgba(255,255,255,.72);
  box-shadow:0 24px 60px rgba(17,37,84,.18);
  backdrop-filter:blur(16px);
  -webkit-backdrop-filter:blur(16px);
  display:none;
  flex-direction:column;
  overflow:hidden;
  animation:slideUpChat .35s cubic-bezier(.22,.61,.36,1) forwards;
  transform-origin:bottom right;
}
.chatbot-container.open{display:flex}
@keyframes slideUpChat{
  from{opacity:0;transform:translateY(20px) scale(.95)}
  to{opacity:1;transform:translateY(0) scale(1)}
}

/* ── Header ── */
.chatbot-header{
  background:linear-gradient(135deg,#17358f 0%,#1e40af 58%,#4f93ff 100%);
  color:#fff;
  padding:.75rem 1.2rem 1rem;
  display:flex;
  align-items:center;
  gap:.75rem;
  flex-shrink:0;
  position:relative;
  overflow:hidden;
}
.chatbot-header::after{
  content:'';
  position:absolute;
  inset:auto -40px -52px auto;
  width:170px;
  height:170px;
  border-radius:50%;
  background:radial-gradient(circle,rgba(255,255,255,.22) 0%,rgba(255,255,255,0) 72%);
  pointer-events:none;
}
.chatbot-header-logo{
  width:50px;
  height:50px;
  border-radius:50%;
  background:linear-gradient(165deg,#15336f 0%,#2452ad 55%,#77a7ff 100%);
  display:flex;
  align-items:center;
  justify-content:center;
  border:1px solid rgba(255,255,255,.7);
  flex-shrink:0;
  box-shadow:inset 0 1px 0 rgba(255,255,255,.5),0 10px 24px rgba(13,31,81,.18);
  overflow:hidden;
}
.chatbot-header-logo img{
  width:82%;
  height:82%;
  object-fit:contain;
  filter:drop-shadow(0 2px 6px rgba(13,31,81,.45));
}
.chatbot-header-info{flex:1;min-width:0}
.chatbot-header-title{
  font-size:.98rem;
  font-weight:700;
  letter-spacing:-.02em;
  line-height:1.2;
}
.chatbot-header-status{
  display:flex;
  align-items:center;
  gap:.4rem;
  font-size:.76rem;
  opacity:.88;
  margin-top:.1rem;
  color:rgba(255,255,255,.9);
}
.chatbot-header-status .dot-pulse{
  display:inline-block;
  width:8px;
  height:8px;
  border-radius:50%;
  background:#4ade80;
  box-shadow:0 0 0 0 rgba(74,222,128,.5);
  animation:bp-pulse-dot 1.6s infinite;
}
@keyframes bp-pulse-dot{
  0%{box-shadow:0 0 0 0 rgba(74,222,128,.55)}
  70%{box-shadow:0 0 0 7px rgba(74,222,128,0)}
  100%{box-shadow:0 0 0 0 rgba(74,222,128,0)}
}
.chatbot-close{
  width:30px;
  height:30px;
  border-radius:999px;
  background:rgba(200,30,30,.75);
  border:1px solid rgba(255,80,80,.5);
  color:#fff;
  font-size:1.05rem;
  cursor:pointer;
  display:flex;
  align-items:center;
  justify-content:center;
  flex-shrink:0;
  position:relative;
  z-index:10;
  transition:background .2s;
}
.chatbot-close:hover{background:rgba(220,30,30,.95)}

/* ── Área de mensajes ── */
.chat-messages{
  flex:1;
  overflow-y:auto;
  padding:1.3rem 1.05rem .9rem;
  display:flex;
  flex-direction:column;
  gap:.6rem;
  scroll-behavior:smooth;
  overscroll-behavior:contain;
  background:linear-gradient(180deg,rgba(255,255,255,.78) 0%,rgba(243,248,255,.92) 100%);
  min-height:180px;
}
.chat-messages::-webkit-scrollbar{width:4px}
.chat-messages::-webkit-scrollbar-track{background:transparent}
.chat-messages::-webkit-scrollbar-thumb{background:#d9e5f7;border-radius:99px}

/* ── Fila bot (avatar + burbuja) ── */
.bot-row{
  display:flex;
  align-items:flex-end;
  gap:.45rem;
  align-self:flex-start;
  max-width:88%;
  animation:bp-msg-in .32s cubic-bezier(.22,1,.36,1);
}
@keyframes bp-msg-in{
  from{opacity:0;transform:translateY(10px) scale(.97)}
  to{opacity:1;transform:translateY(0) scale(1)}
}
.bot-avatar-sm{
  width:32px;
  min-width:32px;
  height:32px;
  border-radius:50%;
  background:linear-gradient(165deg,#15336f 0%,#2452ad 55%,#77a7ff 100%);
  display:flex;
  align-items:center;
  justify-content:center;
  box-shadow:0 8px 18px rgba(20,35,61,.18);
  margin-bottom:2px;
  flex-shrink:0;
  border:1px solid rgba(255,255,255,.72);
  overflow:hidden;
}
.bot-avatar-sm img{
  width:76%;
  height:76%;
  object-fit:contain;
  filter:drop-shadow(0 2px 5px rgba(13,31,81,.4));
}

/* ── Mensajes ── */
.message{
  max-width:82%;
  padding:.72rem .95rem;
  border-radius:18px;
  font-size:.9rem;
  line-height:1.6;
  animation:bp-msg-in .32s cubic-bezier(.22,1,.36,1);
  box-shadow:0 12px 26px rgba(15,43,114,.08);
  word-wrap:break-word;
}
.bot-msg{
  background:#f6faff;
  border:1px solid #d7e7ff;
  color:#14233d;
  border-bottom-left-radius:6px;
}
.user-msg{
  background:linear-gradient(135deg,#1e40af 0%,#2f67dd 100%);
  color:#fff;
  align-self:flex-end;
  border-bottom-right-radius:6px;
  max-width:75%;
}
.msg-cursor{
  display:inline-block;
  width:2px;
  height:.82em;
  background:#60a5fa;
  margin-left:2px;
  vertical-align:middle;
  border-radius:1px;
  animation:bp-cursor-blink .75s steps(1) infinite;
}
@keyframes bp-cursor-blink{
  0%,49%{opacity:1}
  50%,100%{opacity:0}
}

/* ── Indicador de escritura ── */
.typing-indicator{
  background:#f6faff;
  border:1px solid #d7e7ff;
  border-radius:18px;
  border-bottom-left-radius:6px;
  padding:.72rem .95rem;
  display:flex;
  align-items:center;
  gap:4px;
  box-shadow:0 12px 26px rgba(15,43,114,.08);
}
.typing-indicator span{
  width:7px;
  height:7px;
  background:#60a5fa;
  border-radius:50%;
  animation:bp-typing-bounce 1.2s infinite ease-in-out;
}
.typing-indicator span:nth-child(2){animation-delay:.2s}
.typing-indicator span:nth-child(3){animation-delay:.4s}
@keyframes bp-typing-bounce{
  0%,80%,100%{transform:scale(.6);opacity:.45}
  40%{transform:scale(1);opacity:1}
}
.typing-label{
  font-size:.73rem;
  color:#5f718f;
  font-style:italic;
  margin-left:.35rem;
  white-space:nowrap;
}

/* ── Quick replies ── */
.quick-replies{
  display:flex;
  flex-wrap:wrap;
  gap:.5rem;
  align-self:flex-start;
  max-width:96%;
  animation:bp-msg-in .32s cubic-bezier(.22,1,.36,1);
  padding-bottom:.35rem;
  padding-left:36px;
}
.qr-btn{
  background:rgba(255,255,255,.92);
  border:1px solid rgba(96,165,250,.34);
  color:#1e40af;
  padding:.5rem .92rem;
  border-radius:999px;
  font-size:.83rem;
  font-weight:600;
  cursor:pointer;
  transition:transform .16s,background .16s,color .16s,border-color .16s,box-shadow .16s;
  touch-action:manipulation;
  -webkit-tap-highlight-color:transparent;
  box-shadow:0 10px 24px rgba(20,35,61,.06);
  white-space:normal;
  text-align:center;
  line-height:1.3;
}
.qr-btn:hover{
  background:#1e40af;
  color:#fff;
  border-color:#1e40af;
  transform:translateY(-1px);
  box-shadow:0 14px 30px rgba(30,64,175,.18);
}
.qr-btn:disabled{opacity:.7;cursor:default}
.qr-btn.region{font-size:.79rem;padding:.3rem .6rem}
.qr-btn.qr-recommended{
  background:linear-gradient(135deg,#1e40af 0%,#2f67dd 100%);
  color:#fff;
  border-color:#1e40af;
  box-shadow:0 16px 32px rgba(30,64,175,.24);
  font-size:.86rem;
}
.qr-btn.qr-recommended:hover{
  background:#17358f;
  border-color:#17358f;
}

/* ── Barra de progreso ── */
.chat-progress{
  padding:.72rem 1.2rem .52rem;
  background:linear-gradient(180deg,rgba(248,251,255,.95),rgba(241,247,255,.95));
  border-bottom:1px solid #d9e5f7;
  display:flex;
  align-items:center;
  gap:.75rem;
  flex-shrink:0;
}
.progress-track{
  flex:1;
  height:7px;
  background:rgba(96,165,250,.14);
  border-radius:99px;
  overflow:hidden;
}
.progress-fill{
  height:100%;
  background:linear-gradient(90deg,#1e40af 0%,#60a5fa 100%);
  border-radius:99px;
  transition:width .5s ease;
}
.progress-label{
  font-size:.72rem;
  color:#5f718f;
  font-weight:600;
  white-space:nowrap;
  min-width:72px;
  text-align:right;
}

/* ── Summary card ── */
.summary-card{
  background:linear-gradient(180deg,#fff 0%,#f7fbff 100%);
  border:1px solid #d9e5f7;
  border-radius:18px;
  overflow:hidden;
  font-size:.86rem;
  margin-top:.3rem;
  box-shadow:0 14px 28px rgba(15,43,114,.08);
}
.summary-row{
  display:flex;
  gap:.5rem;
  padding:.42rem .7rem;
  border-bottom:1px solid #d9e5f7;
}
.summary-row:last-child{border-bottom:none}
.summary-label{
  min-width:115px;
  font-weight:600;
  color:#5f718f;
  font-size:.8rem;
  flex-shrink:0;
}
.summary-value{color:#14233d;word-break:break-word}
.summary-row.summary-highlight{background:#edf5ff}
.summary-highlight .summary-value{color:#1e40af;font-weight:700}

/* ── Campo de texto ── */
.chat-input{
  border-top:1px solid #d9e5f7;
  padding:.9rem 1rem .9rem;
  display:none;
  align-items:center;
  gap:.5rem;
  background:#f8fbff;
  flex-shrink:0;
}
.chat-input input{
  flex:1;
  border:1px solid #d9e5f7;
  border-radius:16px;
  padding:.82rem 1rem;
  font-size:.9rem;
  outline:none;
  color:#14233d;
  transition:border-color .15s,box-shadow .15s,background .15s;
  background:rgba(255,255,255,.94);
}
.chat-input input:focus{
  border-color:rgba(96,165,250,.5);
  box-shadow:0 0 0 4px rgba(59,130,246,.22);
  background:#fff;
}
.chat-input input::placeholder{color:#94a3b8}
.send-btn{
  background:linear-gradient(135deg,#1e40af 0%,#2f67dd 100%);
  color:#fff;
  border:none;
  border-radius:16px;
  width:48px;
  height:48px;
  display:flex;
  align-items:center;
  justify-content:center;
  cursor:pointer;
  flex-shrink:0;
  transition:transform .14s,box-shadow .14s,filter .14s;
  box-shadow:0 14px 28px rgba(30,64,175,.22);
}
.send-btn:hover{filter:brightness(1.04);box-shadow:0 18px 34px rgba(30,64,175,.28)}
.send-btn:active{transform:scale(.94)}

/* ── Responsive ── */
@media(max-width:480px){
  .chatbot-container{
    width:calc(100vw - 24px);
    right:12px;
    top:80px;
    bottom:12px;
    height:auto;
    max-height:none;
    border-radius:22px;
  }
  .chatbot-toggle{bottom:14px;right:12px}
  .chat-messages{min-height:0}
  .chat-invite{right:84px;bottom:16px}
  .message{max-width:90%}
  .bot-row{max-width:94%}
  .quick-replies{padding-left:0}
}
