:root{
    --black:#0b0b0b; 
    --white:#fff;
    --gold1:#8a5a00; 
    --gold2:#f4cc67;
    --per: 3.5s;   /* duración por foto (3–4s) */
    --count: 3;    /* cantidad de imágenes */
    --total: calc(var(--per) * var(--count)); /* período total del carrusel */
  }
  html { 
    scroll-behavior: smooth; 
  }             
  /* anclas suaves */
section {
    scroll-margin-top: 88px; 
  }          
  /* que el nav fijo no tape los títulos */
  
  /* Mejoras generales para móviles */
  * {
    -webkit-tap-highlight-color: transparent;
  }
  
  body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    font-family: 'Inter', sans-serif;
  }
  
  /* Mejorar el scroll en móviles */
  @media (max-width: 768px) {
    section {
      scroll-margin-top: 80px;
    }
  }

  body{
    margin:0;
    padding:0;
    box-sizing:border-box;
    opacity: 0;
    animation: fadeInPage 0.8s ease-in-out forwards;
  
    background:
    linear-gradient(to bottom, rgba(0,0,0,1), rgba(0,0,0,.95));
  background-size: cover;      /* la imagen "cubre" el contenedor */
  background-position: center; /* centra el foco */
  }

  /* Animación de entrada de la página */
  @keyframes fadeInPage {
    0% {
      opacity: 0;
      transform: translateY(20px);
    }
    100% {
      opacity: 1;
      transform: translateY(0);
    }
  }

  /* Animación específica para el hero */
  @keyframes heroFadeIn {
    0% {
      opacity: 0;
      transform: scale(1.05);
    }
    100% {
      opacity: 1;
      transform: scale(1);
    }
  }

  /* Animación para elementos que aparecen desde abajo */
  @keyframes slideInUp {
    0% {
      opacity: 0;
      transform: translateY(30px);
    }
    100% {
      opacity: 1;
      transform: translateY(0);
    }
  }

  /* Clase para controlar la visibilidad del contenido */
  .page-loading {
    opacity: 0;
    transition: opacity 0.5s ease-in-out;
  }

  .page-ready {
    opacity: 1;
  }

  /* Animación para secciones que aparecen al hacer scroll */
  .fade-in-section {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
  }

  .fade-in-section.visible {
    opacity: 1;
    transform: translateY(0);
  }

  /* Scroll snap para navegación por pantallas */
  main {
    scroll-snap-type: y proximity;
  }
  
  section {
    scroll-snap-align: start;
  }

  /* Botón volver arriba */
  .backtop {
    position: fixed;
    right: 14px;
    bottom: 14px;
    z-index: 60;
    padding: 0.7rem 1rem;
    border-radius: 999px;
    background: #111;
    color: #fff;
    opacity: 0;
    pointer-events: none;
    transition: 0.2s;
    text-decoration: none;
    font-weight: 700;
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
  }
  
  .backtop.show {
    opacity: 0.92;
    pointer-events: auto;
  }
  
  .backtop:hover {
    background: #f4cc67;
    color: #111;
    transform: translateY(-2px);
  }

  /* Índice de secciones sticky */
  .section-tabs {
    position: sticky;
    top: 56px;
    z-index: 50;
    display: flex;
    gap: 0.5rem;
    justify-content: center;
    padding: 0.5rem;
    backdrop-filter: blur(6px);
    background: rgba(0,0,0,0.4);
  }
  
  .section-tabs a {
    color: #fff;
    text-decoration: none;
    font-weight: 700;
    padding: 0.4rem 0.8rem;
    border-radius: 999px;
    background: rgba(255,255,255,0.08);
    transition: all 0.2s ease;
  }
  
  .section-tabs a:hover {
    background: rgba(255,255,255,0.15);
    transform: translateY(-1px);
  }
  
  .section-tabs a.active {
    background: #f4cc67;
    color: #111;
  }

  /* Bottom dock para móvil */
  @media (max-width: 640px) {
    .dock {
      position: fixed;
      left: 50%;
      bottom: 10px;
      transform: translateX(-50%);
      display: flex;
      gap: 12px;
      z-index: 70;
      background: rgba(0,0,0,0.65);
      backdrop-filter: blur(6px);
      padding: 8px 12px;
      border-radius: 999px;
    }
    
    .dock a {
      display: grid;
      place-items: center;
      width: 42px;
      height: 42px;
      background: #111;
      color: #fff;
      border-radius: 50%;
      text-decoration: none;
      font-size: 1.1rem;
      transition: all 0.2s ease;
    }
    
    .dock a:hover {
      transform: translateY(-2px);
      box-shadow: 0 4px 12px rgba(0,0,0,0.3);
    }
    
    .dock a:last-child {
      background: linear-gradient(90deg, #8A5A00, #F4CC67);
      color: #111;
    }
  }
  
  /* Ocultar dock en desktop */
  @media (min-width: 641px) {
    .dock {
      display: none;
    }
  }

  /* Barra de progreso de lectura */
  #progressbar {
    position: fixed;
    left: 0;
    top: 0;
    height: 3px;
    width: 0;
    z-index: 80;
    background: #f4cc67;
    box-shadow: 0 0 10px #f4cc67;
    transition: width 0.1s ease;
  }
  .hero{
    min-height:92vh; 
    display:grid; 
    place-items:center; 
    text-align:center; 

    color:var(--white);
    background-image:
      linear-gradient(to bottom, rgba(0,0,0,.55), rgba(0,0,0,.55)),
      url('barberia-header.webp');             /* tu foto optimizada */
    background-size:cover; 
    background-position:center;
    -webkit-mask-image: linear-gradient(to bottom, transparent 0, black 10%, black 90%, transparent 100%);
    mask-image: linear-gradient(to bottom, transparent 0, black 10%, black 90%, transparent 100%);
  }
  .container{
    max-width: 1200px; margin: 0 auto; padding: 0 16px;
  }
  .nav{
    position: fixed; inset: 0 0 auto 0; z-index: 1000;
    background: transparent; transition: background .25s, box-shadow .25s;
    backdrop-filter: none;
  }

  .logo-nav{
    width: 150px;
    height: 30px;

  }

  .nav .container{ 
    display:flex; 
    align-items:center; 
    justify-content:space-between; 
    height:64px; 
  }
  
  /* Menú hamburguesa para móviles */
  .menu-toggle {
    display: none;
    flex-direction: column;
    cursor: pointer;
    padding: 8px;
  }
  
  .menu-toggle span {
    width: 25px;
    height: 3px;
    background: var(--white);
    margin: 3px 0;
    transition: 0.3s;
    border-radius: 2px;
  }
  
  .menu-toggle.active span:nth-child(1) {
    transform: rotate(-45deg) translate(-5px, 6px);
  }
  
  .menu-toggle.active span:nth-child(2) {
    opacity: 0;
  }
  
  .menu-toggle.active span:nth-child(3) {
    transform: rotate(45deg) translate(-5px, -6px);
  }
  .brand{ 
    display:flex; 
    align-items:center; 
    gap:10px; 
    color:#fff; 
    text-decoration:none; 
    font-weight:700; 
  }
  .brand img{ 
    width:130px; 
    height:32px; 
    border-radius:4px; 
  }
  .menu{ 
    display:flex; 
    gap:18px; 
    list-style:none; 
    margin:0; 
    padding:0; 
  }
  .menu a{
    color:#ddd; text-decoration:none; padding:8px 10px; border-radius:10px;
    transition: color .2s, background .2s, text-underline-offset .2s, box-shadow .2s, transform .2s;
    text-underline-offset: 3px; text-decoration-thickness: 2px;
  }
  .menu a:hover{ 
    color:#fff; 
    background:rgba(255,255,255,.06); 
    box-shadow: 0 0 15px rgba(226, 222, 213, 0.3);
    transform: translateY(-1px);
  }
  .menu a.active{ 
    color:#F4CC67; 
    box-shadow: 0 0 10px rgba(197, 193, 184, 0.4);
    animation: navGlow 2s ease-in-out infinite alternate;
  }

  /* Efecto de brillo para enlaces activos del nav */
  @keyframes navGlow {
    0% {
      box-shadow: 0 0 10px rgba(255, 255, 255, 0.4);
    }
    100% {
      box-shadow: 0 0 20px rgba(184, 181, 175, 0.6);
    }
  }
  
  /* Estilos responsive para el menú */
  @media (max-width: 768px) {
    .menu {
      position: fixed;
      top: 64px;
      left: 0;
      width: 100%;
      background: rgba(0,0,0,.95);
      backdrop-filter: blur(10px);
      flex-direction: column;
      padding: 20px 0;
      transform: translateY(-100%);
      opacity: 0;
      visibility: hidden;
      transition: all 0.3s ease;
      box-shadow: 0 4px 20px rgba(0,0,0,.3);
    }
    
    .menu.active {
      transform: translateY(0);
      opacity: 1;
      visibility: visible;
    }
    
    .menu li {
      width: 100%;
      text-align: center;
    }
    
    .menu a {
      display: block;
      padding: 15px 20px;
      font-size: 1.1rem;
      border-radius: 0;
    }
    
    .menu-toggle {
      display: flex;
    }
  }
  .logo{
    width: 40vw;
    height: 100px;
    margin-bottom: 1rem;
    object-fit: contain;
    filter: drop-shadow(0 0 20px rgba(219, 214, 202, 0.6)) drop-shadow(0 0 40px rgba(244, 204, 103, 0.3));
  }

  
  /* Optimizaciones responsive para el hero */
  @media (max-width: 768px) {
    .hero {
      padding: 0 16px;
    }
    
    .hero__content {
      max-width: 90%;
      margin-inline: auto;
    }
    
    .logo {
      width: 60vw;
      height: 80px;
      margin-bottom: 1.5rem;
    }
    
    .hero p {
      font-size: 1rem;
      margin: 1rem 0 2rem 0;
      line-height: 1.5;
    }
  }
  
  @media (max-width: 480px) {
    .logo {
      width: 70vw;
      height: 70px;
    }
    
    .hero p {
      font-size: 0.95rem;
    }
  }
  

  .scrolled .nav{
    background: rgba(0,0,0,.72); backdrop-filter: blur(6px);
    box-shadow: 0 2px 12px rgba(0,0,0,.28);
  }
  .hero__content{ 
    max-width:60ch; 
    margin-inline:16px; 
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
  }
  .hero h1{ 
    font-family:"Cinzel", serif; 
    font-weight:900; 
    letter-spacing:.5px;
    font-size:clamp(2.2rem, 6vw, 4.2rem); 
    margin:.1em 0 .3em; 
    text-shadow: 0 0 20px rgba(244, 204, 103, 0.3);
  }
  .hero p{ 
    font-family:"Poppins", system-ui, sans-serif; 
    font-size:clamp(1rem,2.2vw,1.25rem); 
    opacity: 0.95; 
    margin: 0.5rem 0 1.5rem 0;
    text-shadow: 0 0 10px rgba(244, 204, 103, 0.2);
  }
  .btn{ 
    display:inline-block; 
    border-radius:999px; 
    padding:10px 18px; 
    font-weight:700; 
    text-decoration:none; 
    margin:4px; 
    transition: all 0.3s ease;
    min-width: 140px;
    text-align: center;
  }
  
  /* Mejoras responsive para botones */
  @media (max-width: 768px) {
    .btn {
      padding: 12px 20px;
      font-size: 0.95rem;
      min-width: 160px;
    }
  }
  
  @media (max-width: 480px) {
    .btn {
      padding: 14px 24px;
      font-size: 1rem;
      min-width: 180px;
    }
  }
  .btn.primary{ 
    background:linear-gradient(90deg,var(--gold1),var(--gold2)); 
    color:#111; 
    box-shadow: 0 0 20px rgba(244, 204, 103, 0.4);
    transition: all 0.3s ease;
  }
  
  .btn.primary:hover {
    box-shadow: 0 0 30px rgba(244, 204, 103, 0.6);
    transform: translateY(-2px);
  }
  .btn.ghost{
    outline:2px solid var(--white); 
    color:var(--white); 
  }
  .btn.ghost:hover{ 
    background:var(--white); 
    color:#111; 
  }
  .cta{
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
  }
  @media (min-width: 640px) {
    .cta{
      flex-direction: row;
      justify-content: center;
    }
  }

  .service-container{
    display: flex;
    justify-content: center;
    align-items: center;
    width: 95vw;
    height: 80vh;
  }

/* Sección completa, llena y con mask suave */
.servicios{
  min-height: 80vh;
  padding: clamp(24px, 4vw, 64px) 16px;
  background:
    linear-gradient(to bottom, rgba(0,0,0,.85), rgba(0,0,0,.9)),
    url('barberia-chaplin.jpg') center/cover fixed no-repeat;
  -webkit-mask-image: linear-gradient(to bottom, transparent 0, black 8%, black 92%, transparent 100%);
  mask-image: linear-gradient(to bottom, transparent 0, black 8%, black 92%, transparent 100%);
}
  
/* Grid responsivo: 3/2/1 cols */
.svc-grid{
  max-width: 1200px;
  margin-inline: auto;
  display: grid;
  gap: clamp(16px, 2.5vw, 24px);
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
@media (max-width: 1024px){ .svc-grid{ grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .svc-grid{ grid-template-columns: 1fr; } }

/* Card con elevación suave */
.svc-card{
  border-radius: 18px;
  overflow: hidden;
  background: rgba(0,0,0,.78);
  box-shadow: 0 12px 30px rgba(0,0,0,.35);
  transition: transform .2s ease, box-shadow .2s ease;
}
.svc-card:hover{
  transform: translateY(-4px);
  box-shadow: 0 18px 40px rgba(0,0,0,.45);
}

/* Layout interno: media + texto */
.svc-card > summary{
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 14px;
  cursor: pointer;
}
.svc-card > summary::-webkit-details-marker{ display:none; }

.svc-card .media{ aspect-ratio: 16/9; background:#000; }
.svc-card video{ width:100%; height:100%; display:block; object-fit:cover; aspect-ratio:16/9; }

.svc-card .head{
  padding: clamp(14px, 2vw, 18px) clamp(14px, 2vw, 20px) 20px;
  display: grid; gap: 6px;
  text-align: center;
}
.svc-card h3{ margin:0; color:#fff; font-family:"Cinzel", serif; font-weight:900; font-size: clamp(1.1rem, 2.2vw, 1.4rem); }
.svc-card p{ margin:0; color:#cfcfcf; font: 500 clamp(.9rem,1.8vw,1rem)/1.45 "Inter", system-ui, sans-serif; }
.svc-card .hint{ margin-top: 6px; color:#f4cc67; font-weight:700; font-size:.95rem; }

/* Panel acordeón sin JS */
.svc-card .panel{
  display: grid; gap: 12px;
  padding: 0 clamp(14px, 2vw, 20px) clamp(16px, 2vw, 20px);
  max-height: 0; overflow: hidden;
  transition: max-height .35s ease, opacity .35s ease;
  opacity: 0;
}
.svc-card[open] .panel{
  max-height: 320px;
  opacity: 1;
}
.svc-card .panel ul{ margin: 10px 0 0; color:#ddd; padding-left: 1.1rem; }
.svc-card .price{ color:#f4cc67; font-weight:800; font-size: 1.1rem; }

/* Botón (reutiliza tu primario dorado) */
.btn{
  display:inline-block; border-radius:999px;
  padding:10px 18px; font-weight:800; text-decoration:none; margin-top:8px;
}
.btn.primary{ background:linear-gradient(90deg,#8A5A00,#F4CC67); color:#111; }
.btn.primary:hover{ filter:brightness(1.05); }

/* Accesibilidad */
@media (prefers-reduced-motion: reduce){
  .svc-card .panel{ transition:none; }
}

.gallery3 figure:nth-child(1){ transform: translate(-8%,  -10px); }
.gallery3 figure:nth-child(2){ transform: translate( 0%,   14px); }
.gallery3 figure:nth-child(3){ transform: translate( 8%,   -4px); }

/* Sombra y borde sutil para que “floten” */
.mini-slider{ box-shadow: 0 16px 40px rgba(0,0,0,.35); border:1px solid #1f1f1f; }
  .quienes{ 
    min-height: 70vh;
    background:#0b0b0b; 
    color:#eee; 
    padding:72px 16px;
  }
.bio{ 
  display:grid; 
  grid-template-columns:1fr 1fr; 
  gap:28px; 
  align-items:center; 
  max-width:1100px; 
  margin:auto;
}

/* Mejoras responsive para bio */
@media (max-width: 1024px) {
  .bio {
    gap: 24px;
    max-width: 900px;
  }
}

@media (max-width: 768px) {
  .bio {
    grid-template-columns: 1fr;
    gap: 20px;
    text-align: center;
  }
  
  .quienes {
    padding: 50px 16px;
  }
  
  .bio .text h2 {
    font-size: 1.8rem;
    margin-bottom: 1rem;
  }
  
  .bio .text p {
    font-size: 1rem;
    line-height: 1.6;
    margin-bottom: 1.5rem;
  }
  
  .bio .text ul {
    text-align: left;
    max-width: 400px;
    margin: 0 auto;
  }
}

@media (max-width: 480px) {
  .quienes {
    padding: 40px 12px;
  }
  
  .bio .text h2 {
    font-size: 1.6rem;
  }
  
  .bio .text p {
    font-size: 0.95rem;
  }
}

/* Nueva sección de muestras de experiencias */
.muestras {
  min-height: 80vh;
  background: #0b0b0b;
  color: #fff;
  padding: 80px 0;
}

.section-title {
  font-family: "Cinzel", serif;
  font-size: 2.5rem;
  font-weight: 900;
  text-align: center;
  margin-bottom: 60px;
  color: #F4CC67;
  letter-spacing: 1px;
}

.experience-section {
  margin-bottom: 80px;
}

.experience-section:last-child {
  margin-bottom: 0;
}

/* Desktop: Layout grid con 2 columnas */
@media (min-width: 769px) {
  .experience-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
  }

  .experience-content.reverse {
    grid-template-columns: 1fr 1fr;
  }

  .experience-content.reverse .experience-text {
    order: 1;
  }

  .experience-content.reverse .experience-slider {
    order: 2;
  }
}

/* Estilos base para todos los dispositivos */
.experience-content {
  max-width: 1200px;
  margin: 0 auto;
}

/* RESPONSIVE: Cambiar a layout vertical en móviles */
@media (max-width: 768px) {
  .experience-content {
    display: flex;
    flex-direction: column;
    gap: 20px;
    text-align: center;
    max-width: 100%;
    margin: 0 auto;
    padding: 0 16px;
  }
  
  .experience-content.reverse {
    display: flex;
    flex-direction: column;
  }
  
  .experience-content .experience-slider {
    order: 1;
    width: 100%;
    margin-bottom: 20px;
  }
  
  .experience-content .experience-text {
    order: 2;
    width: 100%;
    text-align: center;
  }
  
  .experience-content.reverse .experience-text {
    order: 2;
  }
  
  .experience-content.reverse .experience-slider {
    order: 1;
  }
}

.experience-text h3 {
  font-family: "Cinzel", serif;
  font-size: 2rem;
  font-weight: 700;
  color: #F4CC67;
  margin-bottom: 20px;
  letter-spacing: 0.5px;
}

.experience-text p {
  font-size: 1.1rem;
  line-height: 1.7;
  color: #cfcfcf;
  margin-bottom: 24px;
}

.experience-text ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.experience-text li {
  padding: 8px 0;
  color: #e0e0e0;
  font-size: 1rem;
  position: relative;
  padding-left: 24px;
}

.experience-text li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: #F4CC67;
  font-weight: bold;
  font-size: 1.1rem;
}

.experience-slider {
  position: relative;
  width: 100%;
}

/* Responsive para nueva sección de experiencias */
@media (max-width: 1024px) {
  .muestras {
    padding: 60px 0;
  }
  
  .section-title {
    font-size: 2.2rem;
    margin-bottom: 50px;
  }
  
  .experience-content {
    gap: 40px;
    padding: 0 16px;
  }
  
  .experience-section {
    margin-bottom: 60px;
  }
  
  .experience-text h3 {
    font-size: 1.8rem;
  }
  
  .experience-text p {
    font-size: 1rem;
  }
}

/* Centrado solo para responsive - NO afecta desktop */
@media (max-width: 768px) {
  .experience-slider {
    display: flex;
    justify-content: center;
    align-items: center;
  }
  
  .mini-slider {
    margin: 0 auto;
    display: block;
  }
}

@media (max-width: 900px) {
  .muestras {
    padding: 55px 0;
  }
  
  .section-title {
    font-size: 2.1rem;
    margin-bottom: 45px;
  }
  
  .experience-content {
    gap: 35px;
    padding: 0 20px;
  }
  
  .experience-section {
    margin-bottom: 55px;
  }
  
  .experience-text h3 {
    font-size: 1.7rem;
  }
  
  .experience-text p {
    font-size: 0.98rem;
  }
  
  .experience-slider {
    max-width: 100%;
    width: 100%;
  }
  
  .mini-slider {
    aspect-ratio: 4/3;
    border-radius: 14px;
    width: 100%;
    height: auto;
    min-height: 220px;
    display: block;
    position: relative;
    overflow: hidden;
    background: #000;
  }
  
  .mini-slider figcaption {
    position: absolute;
    left: 12px;
    bottom: 12px;
    z-index: 10;
    color: #fff;
    font-weight: 700;
    letter-spacing: 0.5px;
    background: rgba(0,0,0,.6);
    padding: 6px 12px;
    border-radius: 999px;
    font-size: 0.9rem;
  }
  
  .mini-slider img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    will-change: opacity;
    animation: xfade 12.6s linear infinite both;
  }
}

@media (max-width: 768px) {
  .muestras {
    padding: 50px 0;
  }
  
  .section-title {
    font-size: 2rem;
    margin-bottom: 40px;
  }
  
  /* Layout móvil: estructura secuencial ordenada */
  .experience-content {
    display: flex;
    flex-direction: column;
    gap: 20px;
    text-align: center;
    max-width: 100%;
    margin: 0 auto;
    padding: 0 16px;
  }
  
  .experience-content.reverse {
    display: flex;
    flex-direction: column;
  }
  
  /* Orden consistente: slider siempre primero, texto después */
  .experience-content .experience-slider {
    order: 1;
    width: 100%;
    margin-bottom: 20px;
  }
  
  .experience-content .experience-text {
    order: 2;
    width: 100%;
    text-align: center;
  }
  
  .experience-section {
    margin-bottom: 60px;
    padding: 0;
  }
  
  .experience-section:last-child {
    margin-bottom: 0;
  }
  
  .experience-text h3 {
    font-size: 1.6rem;
    margin-bottom: 16px;
    text-align: center;
  }
  
  .experience-text p {
    font-size: 0.95rem;
    margin-bottom: 20px;
    text-align: center;
    line-height: 1.6;
  }
  
  .experience-text ul {
    text-align: center;
    max-width: 100%;
    margin: 0 auto;
    padding: 0;
    list-style: none;
  }
  
  .experience-text li {
    font-size: 0.9rem;
    padding: 8px 0;
    text-align: center;
    position: relative;
    padding-left: 0;
  }
  
  /* Corregir los checkmarks en móvil - centrados */
  .experience-text li::before {
    content: "✓";
    color: #F4CC67;
    font-weight: bold;
    font-size: 1rem;
    margin-right: 8px;
    position: static;
    left: auto;
  }
  
  .experience-slider {
    max-width: 100%;
    width: 100%;
  }
  
  .mini-slider {
    aspect-ratio: 16/10;
    border-radius: 12px;
    width: 100%;
    height: auto;
    min-height: 200px;
    display: block;
    position: relative;
    overflow: hidden;
    background: #000;
    box-shadow: 0 8px 24px rgba(0,0,0,0.3);
  }
  
  .mini-slider figcaption {
    position: absolute;
    left: 12px;
    bottom: 12px;
    z-index: 10;
    color: #fff;
    font-weight: 700;
    letter-spacing: 0.5px;
    background: rgba(0,0,0,.7);
    padding: 8px 12px;
    border-radius: 999px;
    font-size: 0.9rem;
  }
  
  .mini-slider img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    will-change: opacity;
    animation: xfade 12.6s linear infinite both;
  }
}

@media (max-width: 480px) {
  .muestras {
    padding: 40px 0;
  }
  
  .section-title {
    font-size: 1.8rem;
    margin-bottom: 30px;
  }
  
  /* Layout móvil pequeño: estructura secuencial ordenada */
  .experience-content {
    display: flex;
    flex-direction: column;
    gap: 16px;
    text-align: center;
    max-width: 100%;
    margin: 0 auto;
    padding: 0 12px;
  }
  
  .experience-content.reverse {
    display: flex;
    flex-direction: column;
  }
  
  /* Orden consistente: slider siempre primero, texto después */
  .experience-content .experience-slider {
    order: 1;
    width: 100%;
    margin-bottom: 16px;
    display: flex;
    justify-content: center;
    align-items: center;
  }
  
  .experience-content .experience-text {
    order: 2;
    width: 100%;
    text-align: center;
  }
  
  .experience-section {
    margin-bottom: 50px;
    padding: 0;
  }
  
  .experience-section:last-child {
    margin-bottom: 0;
  }
  
  .experience-text h3 {
    font-size: 1.4rem;
    margin-bottom: 12px;
    text-align: center;
  }
  
  .experience-text p {
    font-size: 0.9rem;
    margin-bottom: 16px;
    text-align: center;
    line-height: 1.5;
  }
  
  .experience-text ul {
    text-align: center;
    max-width: 100%;
    margin: 0 auto;
    padding: 0;
    list-style: none;
  }
  
  .experience-text li {
    font-size: 0.85rem;
    padding: 6px 0;
    text-align: center;
    position: relative;
    padding-left: 0;
  }
  
  /* Corregir los checkmarks en móvil pequeño - centrados */
  .experience-text li::before {
    content: "✓";
    color: #F4CC67;
    font-weight: bold;
    font-size: 0.9rem;
    margin-right: 6px;
    position: static;
    left: auto;
  }
  
  .experience-slider {
    max-width: 100%;
    width: 100%;
  }
  
  .mini-slider {
    aspect-ratio: 16/10;
    border-radius: 10px;
    width: 100%;
    height: auto;
    min-height: 180px;
    display: block;
    position: relative;
    overflow: hidden;
    background: #000;
    box-shadow: 0 6px 20px rgba(0,0,0,0.3);
    margin: 0 auto;
  }
  
  .mini-slider figcaption {
    position: absolute;
    left: 10px;
    bottom: 10px;
    z-index: 10;
    color: #fff;
    font-weight: 700;
    letter-spacing: 0.5px;
    background: rgba(0,0,0,.7);
    padding: 6px 10px;
    border-radius: 999px;
    font-size: 0.8rem;
  }
  
  .mini-slider img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    will-change: opacity;
    animation: xfade 12.6s linear infinite both;
  }
}

/* Marco/estilo */
.mini-slider{
  position:relative; aspect-ratio:4/3; border-radius:16px;
  overflow:hidden; background:#000;
  /* timing base */
  --count:3;                /* 3 imágenes por slider */
  --per:4.2s;               /* duración por foto más lenta y natural */
  --total: calc(var(--per) * var(--count));
}
.mini-slider figcaption{
  position:absolute; left:12px; bottom:10px; z-index:2;
  color:#fff; font-weight:700; letter-spacing:.5px;
  background:rgba(0,0,0,.35); padding:6px 10px; border-radius:999px;
}

/* Todas las imágenes apiladas, animación compartida */
.mini-slider img{
  position:absolute; inset:0; width:100%; height:100%;
  object-fit:cover; opacity:0; will-change:opacity;
  animation: xfade var(--total) linear infinite both;
  /* cada img recibe su desfase vía --i (lo pone el JS) + delay aleatorio */
  animation-delay: calc(var(--random-delay, 0s) + var(--i) * var(--per));
}


/* Cross-fade para 3 imágenes: segmento ≈ 33% (sin parpadeos) */
@keyframes xfade{
  0%   { opacity:0; }   /* fuera de su ventana */
  4%   { opacity:1; }   /* fade-in más suave y lento */
  29%  { opacity:1; }   /* permanece visible más tiempo */
  33%  { opacity:0; }   /* fade-out al cierre del segmento */
  100% { opacity:0; }
}

/* Responsive: 2 col / 1 col */
@media (max-width: 900px){
  .muestras .gallery3{ grid-template-columns:repeat(2,1fr); }
}
@media (max-width: 600px){
  .muestras .gallery3{ grid-template-columns:1fr; }
}

/* Carrusel horizontal en móvil para muestras */
@media (max-width: 700px) {
  .muestras .gallery3 {
    display: flex;
    overflow-x: auto;
    gap: 12px;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 8px;
  }
  
  .muestras .mini-slider {
    flex: 0 0 85%;
    scroll-snap-align: center;
  }
}


.frame{ background: linear-gradient(90deg,#8A5A00,#F4CC67);
  padding:3px; border-radius:20px; box-shadow:0 16px 40px rgba(0,0,0,.35); }

.slider{
position:relative; aspect-ratio:4/5; border-radius:17px;
overflow:hidden; background:#000;
}

/* Todas comparten MISMA animación y duran el ciclo completo */
.slider img{
position:absolute; inset:0; width:100%; height:100%; object-fit:cover;
opacity:0; will-change:opacity;
animation: xfade var(--total) linear infinite both;
}

/* Desfase exacto por índice (i-1)*per */
.slider img:nth-child(1){ animation-delay: calc(0 * var(--per)); }
.slider img:nth-child(2){ animation-delay: calc(1 * var(--per)); }
.slider img:nth-child(3){ animation-delay: calc(2 * var(--per)); }

/* Keyframes xfade ya definido arriba - eliminando duplicado */

/* Accesibilidad: menos movimiento */
/* Accesibilidad - prefers-reduced-motion */
@media (prefers-reduced-motion: reduce) {
  * {
    animation: none !important;
    transition: none !important;
  }
  
  html {
    scroll-behavior: auto;
  }
  
  .slider img {
    animation: none;
  }
  
  .slider img:not(:first-child) {
    display: none;
  }
  
  .backtop {
    transition: none;
  }
  
  .section-tabs a {
    transition: none;
  }
  
  .dock a {
    transition: none;
  }
}

.contacto{ min-height: 70vh; background:#0b0b0b; color:#fff; padding:72px 0; }
.contacto h2{ font-family:"Cinzel",serif; text-align:center; margin:0 0 18px; }
.contact-form{ max-width:840px; margin: 0 auto; display:grid; gap:14px; }
.contact-form .row{ display:grid; grid-template-columns:1fr 1fr; gap:14px; }
.contact-form label{ display:grid; gap:6px; color:#cfcfcf; }
.contact-form input, .contact-form select, .contact-form textarea{
  background:#121212; border:1px solid #1f1f1f; color:#fff;
  padding:10px 12px; border-radius:10px; outline:none;
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}
.contact-form input:focus, .contact-form select:focus, .contact-form textarea:focus{
  border-color:#D19A2A; box-shadow:0 0 0 3px rgba(209,154,42,.2);
}
.contact-form .actions{ display:flex; gap:10px; justify-content:center; margin-top:8px; }

/* Mejoras responsive para contacto */
@media (max-width: 768px) {
  .contacto {
    padding: 50px 16px;
  }
  
  .contacto h2 {
    font-size: 1.8rem;
    margin-bottom: 24px;
  }
  
  .contact-form {
    gap: 16px;
  }
  
  .contact-form .row {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  
  .contact-form input, 
  .contact-form select, 
  .contact-form textarea {
    padding: 12px 14px;
    font-size: 1rem;
  }
  
  .contact-form .actions {
    flex-direction: column;
    gap: 12px;
    margin-top: 16px;
  }
  
  .contact-form .actions .btn {
    width: 100%;
    max-width: 300px;
    margin: 0 auto;
  }
}

@media (max-width: 480px) {
  .contacto {
    padding: 40px 12px;
  }
  
  .contacto h2 {
    font-size: 1.6rem;
  }
  
  .contact-form input, 
  .contact-form select, 
  .contact-form textarea {
    padding: 14px 16px;
  }
}

.whatsapp{
  position:fixed; right:16px; bottom:16px; z-index: 1200;
  background: linear-gradient(90deg,#8A5A00,#F4CC67); color:#111;
  padding:10px 14px; border-radius:999px; font-weight:800; text-decoration:none;
  box-shadow:0 12px 28px rgba(0,0,0,.35);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.whatsapp:hover {
  transform: translateY(-2px);
  box-shadow:0 16px 32px rgba(0,0,0,.4);
}

/* Mejoras responsive para botón WhatsApp */
@media (max-width: 768px) {
  .whatsapp {
    right: 12px;
    bottom: 12px;
    padding: 12px 16px;
    font-size: 0.9rem;
  }
}

@media (max-width: 480px) {
  .whatsapp {
    right: 8px;
    bottom: 8px;
    padding: 14px 18px;
    font-size: 1rem;
  }
}
@media (max-width: 640px){ .contact-form .row{ grid-template-columns:1fr; } }
