:root {
  /* System Colors */
  --color-dominant: #B22222;    /* Rojo Teatro Profundo */
  --color-accent: #FFFFC5;      /* Amarillo Luz / Cálido */
  --color-title: #783b18;       /* Marrón para Títulos */
  --color-bg: #FCFBF9;          /* Blanco roto elegante */
  --color-text: #333333;        /* Gris muy oscuro */
  --color-surface: #FFFFFF;     /* Blanco Puro */
  
  /* Typography */
  --font-heading: 'Playfair Display', serif;
  --font-body: 'Open Sans', system-ui, sans-serif;
  
  /* Borders and Radii - Premium Shadows */
  --shadow-pop: 0 10px 30px rgba(120, 59, 24, 0.08);
  --shadow-pop-hover: 0 20px 40px rgba(178, 34, 34, 0.15);
  --radius-card: 8px;
  --radius-button: 4px;
  --border-thick: 1px solid rgba(120, 59, 24, 0.15);
  --border-thin: 1px solid rgba(120, 59, 24, 0.08);
}

/* RESET & BASE */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  overflow-x: hidden;
  width: 100%;
  max-width: 100vw;
}

body {
  font-family: var(--font-body);
  color: var(--color-text);
  background-color: var(--color-bg);
  line-height: 1.6;
  position: relative;
  overflow-x: hidden;
}

h1, h2, h3, h4, .logo-text, .btn-primary, .btn-accent, .btn-secondary, .accordion-title {
  font-family: var(--font-heading);
  font-weight: 700;
  letter-spacing: 0.5px;
}

h1, h2, h3, h4 {
  color: var(--color-title);
}

/* VIBRANT BACKGROUND DYNAMICS */
.dynamic-background {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  z-index: -1;
  pointer-events: none;
  overflow: hidden;
  background: var(--color-bg);
}

.bg-layer {
  position: absolute;
  top: 0; left: 0;
  opacity: 0.25; 
  mix-blend-mode: multiply;
}

.bg-purple { fill: var(--color-dominant); }
.bg-yellow { fill: var(--color-accent); opacity: 0.4; }
.bg-purple-light { fill: #E3C2B0; opacity: 0.15; }

.wave-1 { animation: float-wave 15s infinite alternate ease-in-out; }
.wave-2 { animation: float-wave 20s infinite alternate-reverse ease-in-out; }
.blob-1 { animation: float-blob 25s infinite alternate ease-in-out; transform-origin: center; }
.blob-2 { animation: float-blob 18s infinite alternate-reverse ease-in-out; transform-origin: center; }

@keyframes float-wave {
  0% { transform: scale(1.1) translateY(0) translateX(0); }
  50% { transform: scale(1.2) translateY(-3%) translateX(4%); }
  100% { transform: scale(1.1) translateY(3%) translateX(-4%); }
}

@keyframes float-blob {
  0% { transform: scale(1) translate(0,0); }
  50% { transform: scale(1.5) translate(5%, -10%); }
  100% { transform: scale(1.2) translate(-5%, 5%); }
}

/* REUSABLE COMPONENTS: BADGES & BUTTONS */
.badge {
  display: inline-block;
  background: var(--color-dominant);
  color: #fff;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.hero-badge { margin-bottom: 20px; }

/* BUTTONS */
.btn-primary, .btn-accent, .btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 28px;
  font-size: 1rem;
  font-weight: 600;
  border-radius: var(--radius-button);
  cursor: pointer;
  transition: all 0.4s ease;
  text-decoration: none;
  color: var(--color-text);
  border: var(--border-thick);
  box-shadow: var(--shadow-pop);
}
.btn-accent:hover {
  transform: translate(2px, 2px);
  box-shadow: var(--shadow-pop-hover);
}

.btn-primary {
  background: var(--color-dominant);
  color: #fff;
  border: 2px solid var(--color-dominant);
  box-shadow: 4px 4px 0px rgba(108, 92, 231, 0.4);
}
.btn-primary:hover {
  transform: translate(2px, 2px);
  box-shadow: 2px 2px 0px rgba(108, 92, 231, 0.4);
}

.btn-accent {
  background-color: var(--color-accent);
  color: var(--color-title);
  border: 1px solid var(--color-accent);
}

.btn-accent:hover {
  background-color: #ffe880;
  box-shadow: var(--shadow-pop-hover);
  transform: translateY(-2px);
}

.btn-secondary {
  background: var(--color-surface);
  color: var(--color-text);
  border: var(--border-thick);
  box-shadow: var(--shadow-pop);
}
.btn-secondary:hover {
  transform: translate(2px, 2px);
  box-shadow: var(--shadow-pop-hover);
}

/* HEADER */
.header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 5%;
  position: sticky;
  top: 0;
  background: rgba(248, 249, 250, 0.85);
  /* backdrop-filter: blur(12px); */
  background: var(--color-surface);
  z-index: 100;
  border-bottom: var(--border-thin);
}
.logo-container { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; }
.logo-text { font-size: 1.5rem; font-weight: 800; color: var(--color-text); }
.logo-container .badge { font-size: 0.65rem; padding: 2px 8px; }
.desktop-nav { display: flex; gap: 25px; }
.desktop-nav a { text-decoration: none; color: var(--color-text); font-weight: 500; transition: color 0.3s; }
.desktop-nav a:hover { color: var(--color-dominant); }

/* HERO SECTION (Dos Columnas + Título Principal) */
.hero {
  min-height: 90vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 100px 5% 60px;
  position: relative;
}
.hero-brand-header {
  text-align: center;
  margin-bottom: 60px;
  width: 100%;
  z-index: 10;
  animation: fadeInDown 0.8s ease;
}
.brand-title {
  font-family: var(--font-heading);
  font-size: clamp(3.5rem, 7vw, 6rem);
  font-weight: 800;
  color: var(--color-dominant);
  margin-bottom: 5px;
  line-height: 1.1;
  text-shadow: none;
}
.brand-tagline {
  font-family: var(--font-body);
  font-size: clamp(0.9rem, 1.8vw, 1.3rem);
  font-weight: 500;
  color: var(--color-text);
  letter-spacing: 5px;
  text-transform: uppercase;
}
@keyframes fadeInDown {
  from { opacity: 0; transform: translateY(-20px); }
  to { opacity: 1; transform: translateY(0); }
}
.hero-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 50px;
  align-items: center;
  max-width: 1200px;
  margin: 0 auto;
  position: relative;
  z-index: 10;
}
.hero-text {
  text-align: left;
  background: rgba(255,255,255,0.7);
  padding: 40px;
  border-radius: var(--radius-card);
  border: var(--border-thin);
  box-shadow: var(--shadow-pop);
  background: rgba(255, 255, 255, 0.96);
}
/* Reducción del tamaño y color del Hero H2 (antiguo H1) */
.hero h2 { 
  font-size: clamp(1.6rem, 2.8vw, 2.3rem); 
  font-weight: 800; 
  line-height: 1.25; 
  margin-bottom: 24px; 
  color: var(--color-dominant); 
}
.hero .subtitle { font-size: clamp(1rem, 2vw, 1.15rem); color: #4b5563; margin-bottom: 30px; }
.hero-actions { display: flex; gap: 20px; justify-content: flex-start; flex-wrap: wrap; }
.hero-image {
  display: flex;
  justify-content: center;
  align-items: center;
}

.hero-photo {
  width: 100%;
  max-width: 500px;
  aspect-ratio: 4/3;
  transform: rotate(-2deg);
}
.hero-photo:hover {
  transform: rotate(0deg) translate(-4px, -4px);
}

/* STATS SECTION */
.stats-section {
  background: var(--color-dominant);
  color: #fff;
  padding: 50px 5%;
  position: relative;
  z-index: 20;
  border-top: var(--border-thin);
  border-bottom: var(--border-thin);
  box-shadow: 0px 8px 0px rgba(30, 39, 46, 0.1);
}
.stats-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-around;
  flex-wrap: wrap;
  gap: 30px;
}
.stat-item {
  text-align: center;
  flex: 1;
  min-width: 150px;
}
.stat-item h3 {
  font-size: 3rem;
  color: var(--color-accent);
  margin-bottom: 5px;
  text-shadow: 2px 2px 0px var(--color-text);
}
.stat-item p {
  font-size: 1.1rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* NUESTROS SERVICIOS (FLASHCARDS) */
.servicios-section { padding: 80px 5%; max-width: 1200px; margin: 0 auto; text-align: center; }
.servicios-header h2 { font-size: 2.5rem; margin-bottom: 10px; color: var(--color-text); }
.servicios-subtitle { font-size: 1.5rem; font-family: var(--font-heading); color: var(--color-dominant); margin-bottom: 15px; }
.servicios-desc { font-size: 1.1rem; max-width: 700px; margin: 0 auto 50px auto; color: #4b5563; }
.flashcard-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 30px; }
.flashcard { perspective: 1000px; height: 450px; cursor: pointer; }
.flashcard-inner { position: relative; width: 100%; height: 100%; text-align: center; transition: transform 0.8s cubic-bezier(0.175, 0.885, 0.32, 1.275); transform-style: preserve-3d; }
.flashcard:hover .flashcard-inner { transform: rotateY(180deg); }
.flashcard-front, .flashcard-back { position: absolute; width: 100%; height: 100%; backface-visibility: hidden; border-radius: var(--radius-card); border: var(--border-thin); box-shadow: var(--shadow-pop); overflow: hidden; display: flex; flex-direction: column; }
.flashcard-front { background-color: var(--color-surface); }
.flashcard-photo { height: 60%; width: 100%; overflow: hidden; }
.flashcard-photo img { width: 100%; height: 100%; object-fit: cover; }
.flashcard-front-content { height: 40%; padding: 20px; position: relative; display: flex; flex-direction: column; justify-content: center; }
.flashcard-icon { position: absolute; top: -25px; left: 50%; transform: translateX(-50%); font-size: 2rem; background: var(--color-accent); width: 50px; height: 50px; border-radius: 50%; display: flex; align-items: center; justify-content: center; border: var(--border-thin); box-shadow: 2px 2px 0px var(--color-text); }
.flashcard-front-content h3 { font-size: 1.4rem; margin-bottom: 5px; color: var(--color-text); }
.flashcard-front-content p { font-size: 1rem; color: #666; font-weight: 500; }
.flashcard-back { 
  background-color: var(--color-dominant); color: #fff; transform: rotateY(180deg); 
  padding: 30px 25px; justify-content: flex-start; align-items: flex-start; text-align: left; 
  border-color: var(--color-text); overflow-y: auto; 
}
.flashcard-back::-webkit-scrollbar { width: 6px; }
.flashcard-back::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.3); border-radius: 4px; }
.flashcard-back-header {
  display: flex; align-items: center; gap: 15px; margin-bottom: 15px; width: 100%;
}
.flashcard-icon-back { font-size: 2.2rem; flex-shrink: 0; margin-bottom: 0; }
.flashcard-back h3 { font-size: 1.25rem; margin-bottom: 0; color: var(--color-accent); text-align: left; line-height: 1.2; }
.flashcard-info { font-size: 1rem; line-height: 1.5; margin-bottom: 20px; text-align: left; }
.flashcard-keywords { display: flex; flex-wrap: wrap; gap: 8px; justify-content: flex-start; }
.flashcard-keywords span { font-size: 0.8rem; background: rgba(255,255,255,0.2); padding: 5px 12px; border-radius: 20px; font-weight: 600; }

/* SCENARIOS SECTION (ACCORDIONS) */
.escenarios-section { padding: 80px 5%; max-width: 900px; margin: 0 auto; }
.escenarios-section h2 { text-align: center; font-size: 2.5rem; margin-bottom: 40px; }

.accordion-container { display: flex; flex-direction: column; gap: 20px; }
.accordion-item {
  background: var(--color-surface); border: var(--border-thick); border-radius: var(--radius-card);
  box-shadow: var(--shadow-pop); overflow: hidden; transition: all 0.3s ease;
}
.accordion-header {
  width: 100%; text-align: left; background: none; border: none; padding: 25px 30px;
  display: flex; justify-content: space-between; align-items: center; cursor: pointer;
  font-size: 1.25rem; color: var(--color-text); font-weight: 700; transition: background 0.3s;
}
.accordion-header:hover { background: rgba(250, 207, 127, 0.2); }
.accordion-item.active .accordion-header { background: var(--color-dominant); color: #fff; }
.accordion-icon { font-size: 1.5rem; transition: transform 0.3s ease; }
.accordion-item.active .accordion-icon { transform: rotate(45deg); }
.accordion-body { max-height: 0; overflow: hidden; transition: max-height 0.35s cubic-bezier(0.4, 0, 0.2, 1); }
.accordion-item.active .accordion-body { max-height: 700px; }
.accordion-content { padding: 0 30px 30px 30px; display: flex; gap: 30px; align-items: flex-start; }
.accordion-text { flex: 1; }
.accordion-images-grid { display: grid; grid-template-columns: 1fr; gap: 15px; width: 300px; flex-shrink: 0; }
.accordion-image { border-radius: 12px; overflow: hidden; border: var(--border-thin); box-shadow: var(--shadow-pop); line-height: 0; }
.accordion-image img { width: 100%; height: auto; display: block; object-fit: cover; }
.accordion-text p { font-size: 1.1rem; margin-bottom: 20px; margin-top: 10px; }

.highlights { list-style: none; display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 15px; }
.highlights li {
  background: var(--color-bg); padding: 12px; border-radius: 8px; border: 1px solid var(--color-text);
  display: flex; align-items: center; font-weight: 500; font-size: 0.95rem;
}
.highlights li::before { content: "✨"; margin-right: 10px; }

/* PORTAFOLIO DE OBRAS */
.obras-section { padding: 80px 5%; max-width: 1200px; margin: 0 auto; overflow: hidden; }
.obras-header-container { text-align: center; margin-bottom: 50px; }
.obras-header-container h2 { font-size: 2.5rem; margin-bottom: 15px; }
.obras-subtitle { font-size: 1.1rem; max-width: 700px; margin: 0 auto; color: #4b5563; }
.obras-carousel {
  display: flex; gap: 30px; overflow-x: auto; scroll-snap-type: x mandatory; 
  padding: 20px 5px 40px 5px; scrollbar-width: thin; scrollbar-color: var(--color-dominant) transparent; text-align: left;
}
.obras-carousel::-webkit-scrollbar { height: 10px; }
.obras-carousel::-webkit-scrollbar-track { background: transparent; }
.obras-carousel::-webkit-scrollbar-thumb { background: var(--color-dominant); border-radius: 5px; }
.obra-card { 
  scroll-snap-align: center; flex: 0 0 calc(100% - 40px); max-width: 380px;
  background: var(--color-surface); border: var(--border-thin); border-radius: var(--radius-card); 
  box-shadow: var(--shadow-pop); overflow: hidden; transition: transform 0.3s; 
}
.obra-card:hover { transform: translateY(-8px); box-shadow: 8px 8px 0px var(--color-text); }
.obra-photo { position: relative; width: 100%; aspect-ratio: 16/9; background: #eaeaea; overflow: hidden; border-bottom: var(--border-thin); }
.obra-photo img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s; }
.obra-card:hover .obra-photo img { transform: scale(1.05); }
.obra-badge { position: absolute; top: 15px; left: 15px; z-index: 2; box-shadow: 2px 2px 0px rgba(0,0,0,0.2); }
.obra-info { padding: 30px; }
.obra-info h3 { font-size: 1.5rem; margin-bottom: 10px; color: var(--color-text); }
.obra-meta { font-size: 0.9rem; font-weight: 600; color: var(--color-dominant); margin-bottom: 20px; }
.obra-synopsis { font-size: 0.95rem; color: #333; line-height: 1.6; }
.obra-synopsis strong { display: block; margin-bottom: 5px; color: var(--color-text); }

/* NOSOTROS / LA DIRECTORA */
.nosotros-section { padding: 100px 5%; background: var(--color-dominant); color: var(--color-bg); border-top: var(--border-thin); border-bottom: var(--border-thin); }
.nosotros-container { max-width: 1200px; margin: 0 auto; display: grid; grid-template-columns: 1fr 1fr; gap: 60px; align-items: center; }
.nosotros-title { font-size: clamp(2rem, 3vw, 2.8rem); color: var(--color-accent); margin-bottom: 30px; line-height: 1.2; font-family: var(--font-heading); }
.nosotros-body p { font-size: 1.15rem; margin-bottom: 20px; line-height: 1.7; opacity: 0.9; }
.founder-block { display: flex; align-items: center; gap: 20px; margin-top: 40px; padding-top: 30px; border-top: 1px solid rgba(255,255,255,0.2); }
.founder-icon { width: 60px; height: 60px; background: var(--color-accent); border-radius: 50%; display: flex; align-items: center; justify-content: center; font-family: var(--font-heading); font-size: 1.5rem; font-weight: 800; color: var(--color-text); box-shadow: var(--shadow-pop); flex-shrink: 0; }
.founder-info strong { display: block; font-size: 1.3rem; color: var(--color-accent); font-family: var(--font-heading); margin-bottom: 5px; }
.founder-info span { font-size: 0.9rem; color: rgba(255, 255, 255, 0.9); line-height: 1.4; display: block; }
.nosotros-photo-wrapper { display: flex; justify-content: center; align-items: center; }
.photo-placeholder {
  width: 100%; max-width: 450px; aspect-ratio: 4/5; background: var(--color-accent);
  border-radius: var(--radius-card); box-shadow: var(--shadow-pop); border: var(--border-thin);
  overflow: hidden; transform: rotate(2deg); transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.photo-placeholder:hover { transform: rotate(0deg) translate(-4px, -4px); box-shadow: 12px 12px 0px var(--color-text); }
.photo-placeholder img { width: 100%; height: 100%; object-fit: cover; }

/* TESTIMONIOS SECTION (CAROUSEL) */
.testimonios-section { padding: 80px 5%; max-width: 1200px; margin: 0 auto; text-align: center; overflow: hidden; }
.testimonios-section h2 { font-size: 2.5rem; margin-bottom: 20px; }
.testimonios-carousel {
  display: flex; gap: 30px; overflow-x: auto; scroll-snap-type: x mandatory; 
  padding: 20px 5px 40px 5px; scrollbar-width: thin; scrollbar-color: var(--color-dominant) transparent; text-align: left;
}
.testimonios-carousel::-webkit-scrollbar { height: 10px; }
.testimonios-carousel::-webkit-scrollbar-track { background: transparent; }
.testimonios-carousel::-webkit-scrollbar-thumb { background: var(--color-dominant); border-radius: 5px; }
.testimonio-card {
  scroll-snap-align: center; flex: 0 0 calc(100% - 40px); max-width: 450px;
  background: var(--color-surface); padding: 40px; border-radius: var(--radius-card);
  border: var(--border-thin); box-shadow: var(--shadow-pop); transition: transform 0.2s;
}
.testimonio-card:hover { transform: translateY(-5px); box-shadow: 6px 6px 0px var(--color-text); }
.testimonio-rating { font-size: 1.2rem; margin-bottom: 15px; letter-spacing: 2px; }
.testimonio-text { font-size: 1.1rem; font-style: italic; margin-bottom: 25px; line-height: 1.7; color: #333; }
.testimonio-author strong { display: block; font-size: 1.1rem; color: var(--color-dominant); font-family: var(--font-heading); }
.testimonio-author span { font-size: 0.9rem; color: #666; }

/* BITACORA */
.bitacora-section { padding: 80px 5%; max-width: 1200px; margin: 0 auto; }
.bitacora-section h2 { text-align: center; font-size: 2.5rem; margin-bottom: 40px; }
.bitacora-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 30px; }
.bitacora-card {
  background: var(--color-surface); padding: 40px; border-radius: var(--radius-card);
  border: var(--border-thin); box-shadow: var(--shadow-pop); position: relative; transition: transform 0.2s;
}
.bitacora-card:hover { transform: translateY(-5px); box-shadow: 6px 6px 0px var(--color-text); }
.bitacora-badge { position: absolute; top: -15px; left: 30px; background: var(--color-accent); color: var(--color-text); border: 1px solid var(--color-text); }
.bitacora-card h3 { font-size: 1.25rem; margin-top: 10px; font-style: italic; font-family: var(--font-body); }

/* FORMULARIO INTERACTIVO */
.cotizar-section { padding: 80px 5%; background: rgba(255,255,255,0.6); background: rgba(255, 255, 255, 0.95); border-top: var(--border-thin); }
.form-widget {
  max-width: 700px; margin: 0 auto; background: var(--color-surface);
  border: var(--border-thick); border-radius: var(--radius-card); padding: 50px;
  box-shadow: 8px 8px 0px var(--color-dominant);
}
.form-widget h2 { text-align: center; font-size: 2rem; margin-bottom: 30px; }
.steps-indicator { display: flex; align-items: center; justify-content: center; margin-bottom: 40px; }
.step-dot {
  width: 40px; height: 40px; border-radius: 50%; background: var(--color-bg);
  border: var(--border-thick); display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-family: var(--font-heading); transition: all 0.3s;
}
.step-dot.active { background: var(--color-accent); box-shadow: var(--shadow-pop); }
.step-line { height: 2px; width: 50px; background: var(--color-text); margin: 0 10px; }
.form-step { display: none; animation: fadeIn 0.4s ease; }
.form-step.active { display: block; }
.form-step h3 { margin-bottom: 20px; font-size: 1.2rem; }

@keyframes fadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }

.radio-group { display: flex; flex-direction: column; gap: 15px; margin-bottom: 30px; }
.radio-card { display: block; position: relative; cursor: pointer; }
.radio-card input { position: absolute; opacity: 0; cursor: pointer; }
.radio-card span {
  display: block; padding: 15px 20px; background: var(--color-bg);
  border: var(--border-thin); border-radius: var(--radius-button); transition: all 0.2s; font-weight: 500;
}
.radio-card input:checked ~ span { background: var(--color-accent); box-shadow: var(--shadow-pop); transform: translate(-2px, -2px); }
.input-group { margin-bottom: 20px; }
.input-group input, .input-group textarea {
  width: 100%; padding: 15px; border: var(--border-thin); border-radius: var(--radius-button);
  font-family: var(--font-body); font-size: 1rem; background: var(--color-bg); transition: box-shadow 0.2s;
}
.input-group input:focus, .input-group textarea:focus { outline: none; box-shadow: var(--shadow-pop); }
.form-actions { display: flex; justify-content: space-between; gap: 15px; }

/* MODAL TERMINOS */
.modal {
  display: none; position: fixed; z-index: 2000; left: 0; top: 0;
  width: 100%; height: 100%; overflow: auto; background-color: rgba(30, 39, 46, 0.6); background: rgba(255, 255, 255, 0.95);
}
.modal-content {
  background-color: var(--color-surface); margin: 10% auto; padding: 40px;
  border: var(--border-thick); border-radius: var(--radius-card); width: 90%; max-width: 600px;
  box-shadow: 8px 8px 0px var(--color-dominant); position: relative; text-align: center; animation: fadeIn 0.3s ease;
}
.modal-content h2 { font-size: 2rem; margin-bottom: 20px; color: var(--color-dominant); }
.close-modal { position: absolute; top: 15px; right: 25px; color: var(--color-text); font-size: 35px; font-weight: bold; cursor: pointer; }
.close-modal:hover { color: var(--color-dominant); }

/* WHATSAPP FLOAT */
.floating-whatsapp {
  position: fixed; bottom: 30px; right: 30px; width: 60px; height: 60px;
  background: var(--color-accent); border: var(--border-thick); border-radius: 50%;
  display: flex; align-items: center; justify-content: center; color: var(--color-text);
  box-shadow: var(--shadow-pop); z-index: 1000; transition: all 0.2s;
}
.floating-whatsapp:hover { transform: translate(2px, 2px); box-shadow: var(--shadow-pop-hover); }

/* FOOTER */
.footer { background: var(--color-text); color: var(--color-bg); padding: 60px 5% 40px; text-align: center; }
.footer-title { font-size: 2rem; color: var(--color-accent); margin-bottom: 40px; }
.footer-contact { display: flex; justify-content: center; gap: 30px; flex-wrap: wrap; margin-bottom: 40px; font-size: 1.1rem; }
.footer-social { display: flex; justify-content: center; gap: 20px; }
.footer-social a { color: var(--color-bg); text-decoration: none; border-bottom: 1px solid var(--color-dominant); padding-bottom: 2px; transition: color 0.3s; }
.footer-social a:hover { color: var(--color-accent); }

/* RESPONSIVE */
@media (max-width: 900px) {
  .hero-container { grid-template-columns: 1fr; text-align: center; }
  .hero-text { text-align: center; }
  .hero .subtitle { margin: 0 auto 30px auto; }
  .hero-actions { justify-content: center; }
  .nosotros-container { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
  .header {
    flex-direction: column;
    padding: 10px 15px;
    gap: 8px;
    align-items: center;
  }
  .brand-logo {
    max-height: 55px !important;
  }
  .desktop-nav {
    display: flex !important;
    gap: 8px !important;
    overflow-x: auto;
    max-width: 100%;
    padding: 4px 5px;
    justify-content: flex-start;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }
  .desktop-nav::-webkit-scrollbar {
    display: none;
  }
  .desktop-nav a {
    font-size: 0.8rem !important;
    padding: 6px 12px !important;
    white-space: nowrap !important;
    background: rgba(120, 59, 24, 0.08);
    border-radius: 16px;
    flex-shrink: 0;
  }
  .header .btn-primary {
    width: 100%;
    text-align: center;
    padding: 9px 15px !important;
    font-size: 0.85rem !important;
    margin-left: 0 !important;
  }
  .footer-contact { flex-direction: column; gap: 15px; }
  .form-widget { padding: 25px 15px; }
  .hero h1 { font-size: 2rem; }
  .modal-content, .info-modal-content { margin: 15% auto; padding: 25px 20px; width: 92% !important; max-width: 95% !important; }
  .stats-container { gap: 15px; }
  .stat-item h3 { font-size: 1.8rem; }
  .accordion-content { flex-direction: column; }
  .accordion-images-grid { width: 100%; grid-template-columns: 1fr 1fr; }
}


.desktop-nav a:not(.btn-primary):hover { background-color: rgba(120, 59, 24, 0.08); }


/* --- OTROS SERVICIOS: 3D FLIP CARDS (OPTIMIZED) --- */
.flip-card-container {
  display: flex;
  justify-content: center;
  gap: 30px;
  flex-wrap: wrap;
  margin: 30px auto;
  max-width: 900px;
}

.flip-card {
  background-color: transparent;
  width: 220px;
  height: 220px;
  perspective: 1000px;
  border-radius: 50%;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.flip-card-inner {
  position: relative;
  width: 100%;
  height: 100%;
  text-align: center;
  transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
  transform-style: preserve-3d;
  border-radius: 50%;
  box-shadow: 0 8px 25px rgba(0,0,0,0.1);
  will-change: transform;
}

/* Hover only on desktop devices with mouse */
@media (hover: hover) and (pointer: fine) {
  .flip-card:hover .flip-card-inner {
    transform: rotateY(180deg);
  }
}

/* Touch toggle on mobile */
.flip-card.flipped .flip-card-inner {
  transform: rotateY(180deg);
}

.flip-card-front, .flip-card-back {
  position: absolute;
  width: 100%;
  height: 100%;
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
  border-radius: 50%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  overflow: hidden;
  transform: translateZ(0); /* Hardware accelerated */
}

.flip-card-front {
  background-color: var(--color-surface);
  color: var(--color-title);
}

.flip-card-front img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  position: absolute;
  top: 0;
  left: 0;
  opacity: 1;
  transition: opacity 0.3s;
}

.flip-card:hover .flip-card-front img {
  opacity: 1;
}

.flip-card-front h3 {
  position: relative;
  z-index: 2;
  background: rgba(255, 255, 255, 0.9);
  padding: 10px 20px;
  border-radius: 20px;
  font-family: var(--font-heading);
  font-size: 1.2rem;
  color: var(--color-dominant);
  margin: 0;
}

.flip-card-back {
  background: linear-gradient(135deg, var(--color-dominant), #5c0f18);
  color: white;
  transform: rotateY(180deg);
  padding: 30px;
  text-align: center;
}

.flip-card-back h3 {
  color: #ffffff !important;
  font-family: var(--font-heading);
  font-size: 1.3rem;
  margin-bottom: 15px;
}

.flip-card-back p {
  font-size: 0.9rem;
  margin-bottom: 20px;
  line-height: 1.4;
}

/* MOBILE OPTIMIZATIONS (ULTRA SMOOTH & FAST) */
@media (max-width: 768px) {
  /* Disable heavy background SVG infinite animations on mobile */
  .wave-1, .wave-2, .blob-1, .blob-2 {
    animation: none !important;
  }

  body {
    overflow-x: hidden;
    width: 100%;
  }

  .header {
    position: relative !important; /* Frees up mobile screen real estate and removes scrolling lag */
    flex-direction: column;
    padding: 15px 15px 12px 15px;
    gap: 12px;
    align-items: center;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
  }

  .brand-logo {
    max-height: 55px !important;
  }

  .desktop-nav {
    display: flex !important;
    gap: 8px !important;
    overflow-x: auto;
    max-width: 100%;
    width: 100%;
    padding: 4px 2px;
    justify-content: center;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
    flex-wrap: wrap;
  }

  .desktop-nav::-webkit-scrollbar {
    display: none;
  }

  .desktop-nav a {
    font-size: 0.8rem !important;
    padding: 6px 12px !important;
    white-space: nowrap !important;
    background: rgba(120, 59, 24, 0.08);
    border-radius: 20px;
  }

  .header .btn-primary {
    width: 100%;
    text-align: center;
    padding: 10px 15px !important;
    font-size: 0.9rem !important;
    margin-left: 0 !important;
    border-radius: 25px;
  }

  /* Carousel smooth native mobile swipe */
  .carousel-container {
    scroll-snap-type: x mandatory !important;
    -webkit-overflow-scrolling: touch !important;
    scroll-behavior: auto !important; /* Crucial: removes inertia conflict on iOS/Android */
    padding: 15px 15px 25px 15px !important;
    gap: 15px !important;
  }

  .montaje-card {
    scroll-snap-align: center !important;
    min-width: 280px !important;
    max-width: 85vw !important;
  }

  .empresa-card {
    scroll-snap-align: center !important;
  }

  .footer-contact { flex-direction: column; gap: 15px; }
  .form-widget { padding: 25px 15px !important; }
  .hero { padding: 40px 15px !important; min-height: auto !important; }
  .hero-container { gap: 25px !important; }
  .hero-text { padding: 25px 15px !important; }
  .hero h1 { font-size: 1.9rem !important; }
  .modal-content, .info-modal-content { 
    margin: 10% auto !important; 
    padding: 25px 18px !important; 
    width: 92% !important; 
    max-width: 95% !important; 
  }
  .stats-container { gap: 15px !important; }
  .stat-item h3 { font-size: 1.8rem !important; }
  .accordion-content { flex-direction: column !important; }
  .accordion-images-grid { width: 100% !important; grid-template-columns: 1fr 1fr !important; }
}


/* SUBPAGES RESPONSIVE POLISH */
.subpage-card {
  background: var(--color-surface);
  padding: 50px;
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-pop);
  border: var(--border-thin);
}

.subpage-metrics {
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
  margin-bottom: 50px;
}

@media (max-width: 768px) {
  .subpage-card {
    padding: 25px 18px !important;
  }
  .subpage-metrics {
    flex-direction: column !important;
    align-items: center !important;
    gap: 15px !important;
    margin-bottom: 35px !important;
  }
  .subpage-metrics > div {
    max-width: 100% !important;
    width: 100% !important;
    padding: 20px 20px !important;
  }
  .subpage-hero-title {
    font-size: clamp(2rem, 7vw, 3.2rem) !important;
    line-height: 1.2 !important;
  }
  .subpage-tagline {
    font-size: 1.2rem !important;
  }
}


/* =====================================================================
   INTEGRACIONES (Voiceflow + pagos manuales con QR)
   ===================================================================== */

/* Botón flotante de WhatsApp: se corre a la izquierda para no chocar
   con la burbuja del chatbot de Voiceflow (que queda abajo a la derecha). */
.floating-whatsapp { right: 100px; }

/* --- Modal de pagos manuales --- */
.pay-modal-content {
  max-width: 520px;
  text-align: left;
}
.pay-modal-content h2 { color: var(--color-title); margin-bottom: 15px; font-size: 1.7rem; }
.pay-modal-content h3 { font-size: 1.05rem; margin: 22px 0 10px; }

.pay-hint { font-size: 0.9rem; color: #555; margin-bottom: 15px; line-height: 1.5; }

.pay-field { margin-bottom: 15px; }
.pay-field label { display: block; font-weight: 600; margin-bottom: 5px; }

.pay-input {
  width: 100%;
  padding: 12px;
  border: var(--border-thin);
  border-radius: 8px;
  font-family: var(--font-body);
  font-size: 1rem;
  background: var(--color-bg);
  color: var(--color-text);
}
.pay-input:focus { outline: none; box-shadow: var(--shadow-pop); }

.pay-error {
  color: var(--color-dominant);
  font-size: 0.9rem;
  font-weight: 600;
  min-height: 1.3em;
  margin: 8px 0;
}

.pay-full-btn { width: 100%; padding: 15px; border-radius: 8px; font-size: 1.05rem; }

.pay-summary {
  display: flex;
  flex-direction: column;
  gap: 4px;
  background: var(--color-accent);
  border: var(--border-thick);
  border-radius: 8px;
  padding: 14px 16px;
  margin-bottom: 8px;
  color: var(--color-title);
  font-weight: 600;
}
.pay-summary strong {
  font-family: var(--font-heading);
  font-size: 1.9rem;
  color: var(--color-dominant);
  line-height: 1.1;
}

.pay-plans { margin-bottom: 10px; gap: 10px; }

.pay-accounts { display: grid; gap: 12px; margin: 10px 0 5px; }
.pay-account {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 14px;
  padding: 14px;
  border: var(--border-thick);
  border-radius: 8px;
  background: rgba(178, 34, 34, 0.04);
}
.pay-account-info { flex: 1; min-width: 160px; display: flex; flex-direction: column; gap: 4px; align-items: flex-start; }
.pay-account-name { font-family: var(--font-heading); font-weight: 700; color: var(--color-title); font-size: 1.1rem; }
.pay-account-detail { font-weight: 600; word-break: break-all; }
.pay-copy-btn {
  margin-top: 4px;
  padding: 5px 14px;
  font-family: inherit;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--color-dominant);
  background: transparent;
  border: 1px solid var(--color-dominant);
  border-radius: 20px;
  cursor: pointer;
  transition: all 0.2s;
}
.pay-copy-btn:hover { background: var(--color-dominant); color: #fff; }
.pay-qr {
  width: 130px;
  height: 130px;
  object-fit: contain;
  background: #fff;
  border: var(--border-thick);
  border-radius: 8px;
  padding: 4px;
}

.pay-notice {
  font-size: 0.85rem;
  line-height: 1.5;
  background: rgba(120, 59, 24, 0.06);
  border-left: 4px solid var(--color-dominant);
  border-radius: 4px;
  padding: 10px 12px;
  margin: 10px 0;
}

.pay-actions { display: flex; gap: 12px; margin-top: 10px; }
.pay-actions .pay-back-btn { flex: 1; padding: 15px; border-radius: 8px; background: transparent; color: var(--color-title); border: 1px solid #ccc; box-shadow: none; }
.pay-actions .pay-send-btn { flex: 2; padding: 15px; border-radius: 8px; font-size: 1rem; }

.pay-success { text-align: center; padding: 10px 0; }
.pay-success h2 { color: var(--color-dominant); }
.pay-success a { color: var(--color-dominant); font-weight: 700; }

@media (max-width: 768px) {
  .floating-whatsapp { right: 90px; bottom: 20px; }
  .pay-actions { flex-direction: column-reverse; }
  .pay-qr { width: 110px; height: 110px; }
  .pay-modal-content h2 { font-size: 1.4rem; }
}
