/*
Theme Name: Lux Comunicaciones
Theme URI: https://luxchile.cl
Author: Lux Comunicaciones
Author URI: https://luxchile.cl
Description: Tema oficial de Agencia Lux Comunicaciones - Diseño Web, SEO y Marketing Digital en Chile.
Version: 1.0.0
License: GNU General Public License v2 or later
Text Domain: lux-theme
Tags: agency, digital, marketing, bilingual
*/

/* ============================================
   VARIABLES Y RESET
============================================ */
:root {
  --color-primary:    #E800B0;
  --color-secondary:  #6B00D7;
  --color-accent:     #4B00D9;
  --gradient:         linear-gradient(135deg, #E800B0 0%, #7B2FBE 50%, #4B00D9 100%);
  --gradient-hover:   linear-gradient(135deg, #4B00D9 0%, #7B2FBE 50%, #E800B0 100%);
  --dark:             #0D0D0D;
  --dark-2:           #141414;
  --dark-3:           #1E1E1E;
  --text:             #1A1A1A;
  --text-light:       #666666;
  --white:            #FFFFFF;
  --border:           rgba(255,255,255,0.08);
  --font-main:        'Inter', sans-serif;
  --font-display:     'Poppins', sans-serif;
  --radius:           12px;
  --radius-lg:        24px;
  --shadow:           0 8px 32px rgba(107, 0, 215, 0.15);
  --shadow-hover:     0 16px 48px rgba(107, 0, 215, 0.35);
  --transition:       all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; font-size: 16px; }

body {
  font-family: var(--font-main);
  color: var(--text);
  background: var(--white);
  line-height: 1.6;
  overflow-x: hidden;
}

img { max-width: 100%; height: auto; display: block; }
a { text-decoration: none; color: inherit; transition: var(--transition); }
ul { list-style: none; }
button { cursor: pointer; border: none; background: none; font-family: var(--font-main); }

/* ============================================
   TIPOGRAFÍA
============================================ */
h1, h2, h3, h4, h5 { font-family: var(--font-display); font-weight: 700; line-height: 1.2; }
h1 { font-size: clamp(2.2rem, 5vw, 4rem); }
h2 { font-size: clamp(1.8rem, 3.5vw, 2.8rem); }
h3 { font-size: clamp(1.2rem, 2vw, 1.6rem); }
p  { font-size: 1rem; color: var(--text-light); line-height: 1.75; }

.section-label {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 0.75rem;
}

/* ============================================
   LAYOUT
============================================ */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.section {
  padding: 6rem 0;
}

.section--dark {
  background: var(--dark);
  color: var(--white);
}

.section--dark p { color: rgba(255,255,255,0.65); }
.section--dark h2 { color: var(--white); }

.section__header {
  text-align: center;
  max-width: 640px;
  margin: 0 auto 4rem;
}

.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 2rem; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2rem; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.5rem; }

/* ============================================
   BOTONES
============================================ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.875rem 2rem;
  border-radius: 50px;
  font-weight: 600;
  font-size: 0.95rem;
  transition: var(--transition);
  white-space: nowrap;
}

.btn--primary {
  background: var(--gradient);
  color: var(--white);
  box-shadow: var(--shadow);
}

.btn--primary:hover {
  background: var(--gradient-hover);
  box-shadow: var(--shadow-hover);
  transform: translateY(-2px);
  color: var(--white);
}

.btn--outline {
  border: 2px solid var(--color-primary);
  color: var(--color-primary);
  background: transparent;
}

.btn--outline:hover {
  background: var(--gradient);
  color: var(--white);
  border-color: transparent;
  transform: translateY(-2px);
}

.btn--outline--white {
  border: 2px solid rgba(255,255,255,0.4);
  color: var(--white);
  background: transparent;
}

.btn--outline--white:hover {
  border-color: var(--color-primary);
  background: var(--gradient);
  transform: translateY(-2px);
}

/* ============================================
   NAVBAR
============================================ */
#navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: 1.25rem 0;
  transition: var(--transition);
}

#navbar.scrolled {
  background: rgba(13,13,13,0.95);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  padding: 0.875rem 0;
  box-shadow: 0 4px 24px rgba(0,0,0,0.3);
}

.nav__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
}

.nav__logo img { height: 44px; width: auto; }

.nav__menu {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.nav__menu a {
  color: rgba(255,255,255,0.85);
  font-weight: 500;
  font-size: 0.9rem;
  padding: 0.5rem 0.875rem;
  border-radius: 8px;
  transition: var(--transition);
}

.nav__menu a:hover,
.nav__menu a.active {
  color: var(--white);
  background: rgba(255,255,255,0.08);
}

.nav__actions {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.lang-switcher {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  background: rgba(255,255,255,0.08);
  border-radius: 20px;
  padding: 0.25rem;
}

.lang-switcher button {
  color: rgba(255,255,255,0.6);
  font-size: 0.8rem;
  font-weight: 600;
  padding: 0.25rem 0.6rem;
  border-radius: 16px;
  transition: var(--transition);
}

.lang-switcher button.active {
  background: var(--gradient);
  color: var(--white);
}

.nav__toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 4px;
}

.nav__toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--white);
  border-radius: 2px;
  transition: var(--transition);
}

/* ============================================
   HERO
============================================ */
#hero {
  min-height: 100vh;
  background: var(--dark);
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
  padding-top: 5rem;
}

.hero__bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero__orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.35;
}

.hero__orb--1 {
  width: 600px;
  height: 600px;
  background: var(--color-primary);
  top: -200px;
  right: -100px;
  animation: float 8s ease-in-out infinite;
}

.hero__orb--2 {
  width: 500px;
  height: 500px;
  background: var(--color-accent);
  bottom: -200px;
  left: -100px;
  animation: float 10s ease-in-out infinite reverse;
}

@keyframes float {
  0%, 100% { transform: translateY(0px) scale(1); }
  50% { transform: translateY(-30px) scale(1.05); }
}

.hero__inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}

.hero__content { color: var(--white); }

.hero__badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 50px;
  padding: 0.5rem 1rem;
  font-size: 0.8rem;
  color: rgba(255,255,255,0.8);
  margin-bottom: 1.5rem;
}

.hero__badge::before {
  content: '';
  width: 8px;
  height: 8px;
  background: var(--color-primary);
  border-radius: 50%;
  animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(1.3); }
}

.hero__title {
  color: var(--white);
  margin-bottom: 1.5rem;
}

.hero__title .gradient-text {
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero__subtitle {
  font-size: 1.1rem;
  color: rgba(255,255,255,0.65);
  margin-bottom: 2.5rem;
  max-width: 480px;
}

.hero__actions {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.hero__stats {
  display: flex;
  gap: 2rem;
  margin-top: 3.5rem;
  padding-top: 2rem;
  border-top: 1px solid rgba(255,255,255,0.08);
}

.stat__number {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 800;
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.stat__label {
  font-size: 0.8rem;
  color: rgba(255,255,255,0.5);
  margin-top: 0.2rem;
}

.hero__visual {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
}

.hero__card-stack {
  position: relative;
  width: 100%;
  max-width: 420px;
}

.hero__card {
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.1);
  backdrop-filter: blur(12px);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  color: var(--white);
}

.hero__card--main {
  position: relative;
  z-index: 2;
}

.hero__card--behind {
  position: absolute;
  top: -1rem;
  left: 1rem;
  right: -1rem;
  z-index: 1;
  opacity: 0.5;
}

.card-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: var(--gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  margin-bottom: 1rem;
}

.card-title { font-size: 1rem; font-weight: 600; margin-bottom: 0.5rem; }
.card-sub   { font-size: 0.82rem; color: rgba(255,255,255,0.55); margin-bottom: 1rem; }

.card-progress-bar {
  height: 4px;
  background: rgba(255,255,255,0.1);
  border-radius: 2px;
  overflow: hidden;
}

.card-progress-fill {
  height: 100%;
  background: var(--gradient);
  border-radius: 2px;
  animation: progress 3s ease-in-out infinite alternate;
}

@keyframes progress {
  from { width: 40%; }
  to   { width: 90%; }
}

/* ============================================
   SERVICIOS
============================================ */
.service-card {
  background: var(--white);
  border: 1px solid #F0F0F0;
  border-radius: var(--radius-lg);
  padding: 2rem;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.service-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--gradient);
  transform: scaleX(0);
  transition: var(--transition);
}

.service-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-hover);
  border-color: transparent;
}

.service-card:hover::before { transform: scaleX(1); }

.service-card__icon {
  width: 56px;
  height: 56px;
  border-radius: 14px;
  background: linear-gradient(135deg, rgba(232,0,176,0.1), rgba(75,0,217,0.1));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
  margin-bottom: 1.25rem;
}

.service-card__title {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
  color: var(--text);
}

.service-card__desc {
  font-size: 0.9rem;
  margin-bottom: 1.5rem;
}

.service-card__link {
  font-size: 0.85rem;
  font-weight: 600;
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}

/* ============================================
   PLANES / PRECIOS (sin precios visibles)
============================================ */
.plan-card {
  border-radius: var(--radius-lg);
  padding: 2.5rem;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.plan-card--light {
  background: #F8F6FF;
  border: 2px solid transparent;
}

.plan-card--dark {
  background: var(--dark-3);
  border: 2px solid var(--border);
  color: var(--white);
}

.plan-card--featured {
  background: var(--gradient);
  color: var(--white);
}

.plan-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-hover);
}

.plan-badge {
  display: inline-block;
  background: rgba(255,255,255,0.2);
  color: var(--white);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.3rem 0.8rem;
  border-radius: 20px;
  margin-bottom: 1rem;
}

.plan-card--light .plan-badge {
  background: var(--gradient);
}

.plan-name {
  font-size: 1.3rem;
  font-weight: 800;
  margin-bottom: 0.5rem;
}

.plan-desc {
  font-size: 0.88rem;
  margin-bottom: 2rem;
  opacity: 0.75;
}

.plan-features {
  margin-bottom: 2rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.plan-features li {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  font-size: 0.9rem;
}

.plan-features li::before {
  content: '✓';
  font-weight: 700;
  color: var(--color-primary);
  flex-shrink: 0;
  margin-top: 0.05rem;
}

.plan-card--featured .plan-features li::before,
.plan-card--dark .plan-features li::before {
  color: var(--white);
}

/* ============================================
   PORTAFOLIO
============================================ */
.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.portfolio-item {
  border-radius: var(--radius-lg);
  overflow: hidden;
  position: relative;
  aspect-ratio: 4/3;
  background: var(--dark-3);
  cursor: pointer;
}

.portfolio-item__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.portfolio-item__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(13,13,13,0.95) 0%, transparent 60%);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 1.5rem;
  opacity: 0;
  transition: var(--transition);
}

.portfolio-item:hover .portfolio-item__img { transform: scale(1.06); }
.portfolio-item:hover .portfolio-item__overlay { opacity: 1; }

.portfolio-item__title { color: var(--white); font-size: 1rem; font-weight: 700; }
.portfolio-item__cat   { color: rgba(255,255,255,0.6); font-size: 0.8rem; }

/* Placeholder para items sin imagen */
.portfolio-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--dark-3), var(--dark-2));
  font-size: 2.5rem;
}

/* ============================================
   CLIENTES
============================================ */
.clients-track-wrapper {
  overflow: hidden;
  mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
  -webkit-mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
}

.clients-track {
  display: flex;
  gap: 3rem;
  animation: slide 30s linear infinite;
  width: max-content;
}

.clients-track:hover { animation-play-state: paused; }

@keyframes slide {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

.client-logo {
  flex-shrink: 0;
  background: #F5F5F7;
  border-radius: var(--radius);
  padding: 1rem 1.75rem;
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 160px;
  height: 70px;
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--text-light);
  white-space: nowrap;
  transition: var(--transition);
}

.client-logo:hover {
  background: linear-gradient(135deg, rgba(232,0,176,0.08), rgba(75,0,217,0.08));
  color: var(--color-secondary);
}

/* ============================================
   QUIENES SOMOS
============================================ */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 5rem;
  align-items: center;
}

.about-visual {
  position: relative;
}

.about-main-card {
  background: var(--dark);
  border-radius: var(--radius-lg);
  padding: 3rem;
  color: var(--white);
  position: relative;
  overflow: hidden;
}

.about-main-card::before {
  content: '';
  position: absolute;
  top: -40%;
  right: -20%;
  width: 300px;
  height: 300px;
  background: var(--gradient);
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.3;
}

.about-year {
  font-family: var(--font-display);
  font-size: 5rem;
  font-weight: 900;
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1;
  margin-bottom: 0.5rem;
}

.about-since { color: rgba(255,255,255,0.55); font-size: 0.9rem; margin-bottom: 2rem; }

.dept-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  position: relative;
  z-index: 1;
}

.dept-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.88rem;
  color: rgba(255,255,255,0.75);
}

.dept-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--gradient);
  flex-shrink: 0;
}

.about-float-card {
  position: absolute;
  bottom: -1.5rem;
  right: -1.5rem;
  background: var(--white);
  border-radius: var(--radius);
  padding: 1rem 1.25rem;
  box-shadow: 0 8px 32px rgba(0,0,0,0.12);
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.85rem;
  font-weight: 600;
}

.about-float-icon {
  font-size: 1.4rem;
}

.about-content h2 { margin-bottom: 1.25rem; }
.about-content p  { margin-bottom: 1.25rem; }

.values-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-top: 2rem;
}

.value-item {
  background: #F8F6FF;
  border-radius: var(--radius);
  padding: 1.25rem;
}

.value-icon { font-size: 1.5rem; margin-bottom: 0.5rem; }
.value-title { font-size: 0.9rem; font-weight: 700; margin-bottom: 0.3rem; color: var(--text); }
.value-desc  { font-size: 0.8rem; }

/* ============================================
   FORMULARIO DE COTIZACIÓN
============================================ */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 4rem;
  align-items: start;
}

.contact-info h2 { color: var(--white); margin-bottom: 1rem; }
.contact-info p  { margin-bottom: 2rem; }

.contact-channels {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.contact-channel {
  display: flex;
  align-items: center;
  gap: 1rem;
  color: rgba(255,255,255,0.8);
  font-size: 0.9rem;
  transition: var(--transition);
}

.contact-channel:hover { color: var(--color-primary); }

.channel-icon {
  width: 44px;
  height: 44px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  flex-shrink: 0;
}

.quote-form {
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: 2.5rem;
  box-shadow: var(--shadow-hover);
}

.quote-form h3 {
  font-size: 1.3rem;
  margin-bottom: 0.5rem;
  color: var(--text);
}

.form-subtitle {
  font-size: 0.88rem;
  margin-bottom: 2rem;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  margin-bottom: 1rem;
}

.form-group label {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text);
}

.form-group input,
.form-group select,
.form-group textarea {
  padding: 0.75rem 1rem;
  border: 1.5px solid #E8E8E8;
  border-radius: var(--radius);
  font-family: var(--font-main);
  font-size: 0.9rem;
  color: var(--text);
  transition: var(--transition);
  background: #FAFAFA;
  width: 100%;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--color-secondary);
  background: var(--white);
  box-shadow: 0 0 0 3px rgba(107, 0, 215, 0.08);
}

.form-group textarea { resize: vertical; min-height: 110px; }

.form-group--full { grid-column: 1 / -1; }

/* ============================================
   FOOTER
============================================ */
#footer {
  background: #080808;
  color: rgba(255,255,255,0.6);
  padding: 4rem 0 0;
}

.footer__grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: 3rem;
  padding-bottom: 3rem;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}

.footer__logo { margin-bottom: 1rem; }
.footer__logo img { height: 40px; }
.footer__tagline { font-size: 0.88rem; margin-bottom: 1.5rem; }

.footer__social {
  display: flex;
  gap: 0.75rem;
}

.social-icon {
  width: 38px;
  height: 38px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  transition: var(--transition);
  color: rgba(255,255,255,0.6);
}

.social-icon:hover {
  background: var(--gradient);
  border-color: transparent;
  color: var(--white);
  transform: translateY(-2px);
}

.footer__col h4 {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--white);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 1.25rem;
}

.footer__col ul { display: flex; flex-direction: column; gap: 0.65rem; }

.footer__col ul li a {
  font-size: 0.88rem;
  color: rgba(255,255,255,0.5);
  transition: var(--transition);
}

.footer__col ul li a:hover { color: var(--color-primary); padding-left: 4px; }

.footer__bottom {
  padding: 1.5rem 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.82rem;
}

.footer__bottom a { color: rgba(255,255,255,0.4); }
.footer__bottom a:hover { color: var(--color-primary); }

/* ============================================
   WHATSAPP FLOTANTE
============================================ */
.whatsapp-float {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  z-index: 999;
  width: 58px;
  height: 58px;
  background: #25D366;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
  box-shadow: 0 6px 24px rgba(37, 211, 102, 0.4);
  transition: var(--transition);
  animation: bounce-in 0.6s 1s cubic-bezier(0.34, 1.56, 0.64, 1) both;
}

.whatsapp-float:hover {
  transform: scale(1.1);
  box-shadow: 0 10px 36px rgba(37, 211, 102, 0.6);
}

@keyframes bounce-in {
  from { transform: scale(0); opacity: 0; }
  to   { transform: scale(1); opacity: 1; }
}

/* ============================================
   ANIMACIONES DE ENTRADA
============================================ */
.reveal {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }
.reveal-delay-4 { transition-delay: 0.4s; }

/* ============================================
   RESPONSIVO
============================================ */
@media (max-width: 1024px) {
  .hero__inner      { grid-template-columns: 1fr; gap: 3rem; }
  .hero__visual     { display: none; }
  .about-grid       { grid-template-columns: 1fr; }
  .about-visual     { display: none; }
  .contact-grid     { grid-template-columns: 1fr; gap: 2.5rem; }
  .footer__grid     { grid-template-columns: 1fr 1fr; gap: 2rem; }
  .grid-4           { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
  .section { padding: 4rem 0; }
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
  .portfolio-grid   { grid-template-columns: repeat(2, 1fr); }
  .form-row         { grid-template-columns: 1fr; }
  .values-grid      { grid-template-columns: 1fr; }
  .footer__grid     { grid-template-columns: 1fr; }

  .nav__menu   { display: none; }
  .nav__toggle { display: flex; }

  .nav__menu.open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: rgba(13,13,13,0.98);
    backdrop-filter: blur(16px);
    padding: 1.5rem;
    gap: 0.25rem;
    border-top: 1px solid rgba(255,255,255,0.06);
  }

  .hero__stats { flex-wrap: wrap; gap: 1.5rem; }
  .footer__bottom { flex-direction: column; gap: 0.5rem; text-align: center; }
}

@media (max-width: 480px) {
  .portfolio-grid { grid-template-columns: 1fr; }
  .hero__actions  { flex-direction: column; align-items: flex-start; }
  .btn { width: 100%; justify-content: center; }
  .grid-4 { grid-template-columns: 1fr; }
}

/* ============================================
   WHATSAPP WIDGET MEJORADO
============================================ */
.whatsapp-widget {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  z-index: 999;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.75rem;
}

.whatsapp-bubble {
  background: var(--white);
  border-radius: 16px 16px 4px 16px;
  padding: 1rem 1.25rem;
  box-shadow: 0 8px 32px rgba(0,0,0,0.14);
  max-width: 240px;
  font-size: 0.85rem;
  color: var(--text);
  line-height: 1.5;
  position: relative;
  animation: slide-up 0.4s 2s cubic-bezier(0.34,1.56,0.64,1) both;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.whatsapp-bubble strong { font-size: 0.9rem; color: var(--text); }
.whatsapp-bubble span   { color: var(--text-light); }

.whatsapp-bubble-close {
  position: absolute;
  top: -8px;
  right: -8px;
  width: 22px;
  height: 22px;
  background: var(--text-light);
  color: var(--white);
  border-radius: 50%;
  font-size: 0.65rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  border: none;
  line-height: 1;
}

.whatsapp-btn {
  width: 58px;
  height: 58px;
  background: #25D366;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 6px 24px rgba(37,211,102,0.45);
  transition: var(--transition);
  animation: bounce-in 0.6s 1s cubic-bezier(0.34,1.56,0.64,1) both;
  flex-shrink: 0;
}

.whatsapp-btn:hover {
  transform: scale(1.1);
  box-shadow: 0 10px 36px rgba(37,211,102,0.65);
}

.whatsapp-btn svg { width: 28px; height: 28px; }

@keyframes slide-up {
  from { opacity:0; transform:translateY(16px); }
  to   { opacity:1; transform:translateY(0); }
}

/* ============================================
   POPUP DESCUENTO 20%
============================================ */
.popup-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.65);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s ease;
}

.popup-overlay.active {
  opacity: 1;
  pointer-events: all;
}

.popup-card {
  background: var(--white);
  border-radius: var(--radius-lg);
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  max-width: 680px;
  width: 100%;
  overflow: hidden;
  position: relative;
  box-shadow: 0 32px 80px rgba(0,0,0,0.35);
  transform: scale(0.92) translateY(20px);
  transition: transform 0.35s cubic-bezier(0.34,1.56,0.64,1);
}

.popup-overlay.active .popup-card {
  transform: scale(1) translateY(0);
}

.popup-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  z-index: 2;
  width: 32px;
  height: 32px;
  background: rgba(255,255,255,0.15);
  border: none;
  border-radius: 50%;
  color: var(--white);
  font-size: 0.85rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition);
}

.popup-close:hover { background: rgba(255,255,255,0.3); }

/* Lado izquierdo */
.popup-left {
  background: var(--gradient);
  padding: 2.5rem 2rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 0.5rem;
}

.popup-badge {
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 0.15em;
  color: rgba(255,255,255,0.8);
  background: rgba(255,255,255,0.15);
  padding: 0.35rem 0.85rem;
  border-radius: 20px;
  margin-bottom: 0.5rem;
}

.popup-discount {
  font-family: var(--font-display);
  font-size: 5.5rem;
  font-weight: 900;
  color: var(--white);
  line-height: 1;
}

.popup-off {
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 800;
  color: rgba(255,255,255,0.9);
  letter-spacing: 0.08em;
}

.popup-desc {
  color: rgba(255,255,255,0.8);
  font-size: 0.85rem;
  line-height: 1.55;
  margin-top: 0.5rem;
}

.popup-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.75rem;
  font-weight: 600;
  color: rgba(255,255,255,0.7);
  background: rgba(255,255,255,0.12);
  padding: 0.35rem 0.75rem;
  border-radius: 20px;
  margin-top: 0.5rem;
}

.popup-tag::before {
  content: '⏱';
}

/* Lado derecho */
.popup-right {
  padding: 2.5rem 2rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.popup-title {
  font-size: 1.35rem;
  color: var(--text);
  margin-bottom: 0.25rem;
}

.popup-subtitle {
  font-size: 0.88rem;
  margin-bottom: 1rem;
}

.popup-legal {
  font-size: 0.75rem;
  color: var(--text-light);
  text-align: center;
  margin-top: 0.5rem;
}

.popup-legal a { color: var(--color-secondary); }

/* ============================================
   PÁGINAS LEGALES
============================================ */
.legal-content h2 {
  font-size: 1.2rem;
  margin: 2.5rem 0 0.75rem;
  color: var(--text);
  padding-bottom: 0.5rem;
  border-bottom: 2px solid #F0F0F0;
}

.legal-content h2:first-child { margin-top: 0; }

.legal-content p {
  margin-bottom: 1rem;
  font-size: 0.95rem;
}

/* ============================================
   POPUP RESPONSIVO
============================================ */
@media (max-width: 600px) {
  .popup-card {
    grid-template-columns: 1fr;
    max-height: 90vh;
    overflow-y: auto;
  }
  .popup-left { padding: 2rem 1.5rem 1.5rem; }
  .popup-discount { font-size: 4rem; }
  .popup-right { padding: 1.5rem; }
  .whatsapp-widget { bottom: 1.25rem; right: 1.25rem; }
}
