/* Variables de color y fuentes */
:root {
    --primary-color: #880e4f;
    --secondary-color: #c2185b;
    --light-bg: #fce4ec;
    --white: #ffffff;
    --text-color: #444444;
    --text-light: #6b6b6b;
    --bg-cream: #faf5f1;
    --bg-blush: #fdf3f5;
    --transition: all 0.3s ease;
}

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

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    color: var(--text-color);
    background-color: var(--white);
    line-height: 1.6;
    scroll-behavior: smooth;
    overflow-x: hidden;
    width: 100%;
}

/* Navegación (Fija y dinámica) */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    padding: 20px 0;
    background-color: transparent;
    transition: var(--transition);
    z-index: 1000;
}

.navbar.scrolled {
    background-color: var(--white);
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    padding: 15px 0;
}

.navbar.scrolled .logo,
.navbar.scrolled .nav-links a {
    color: var(--primary-color);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 20px;
}

.logo {
    color: var(--white);
    font-size: 1.8rem;
    font-weight: bold;
    transition: var(--transition);
}
.navbar .logo {
    text-decoration: none !important;
}

.navbar a.logo {
    text-decoration: none !important;
}

.nav-links {
    list-style: none;
    display: flex;
    gap: 30px;
}

.nav-links a {
    text-decoration: none;
    color: var(--white);
    font-weight: 500;
    transition: var(--transition);
}

.nav-links a:hover {
    color: var(--secondary-color) !important;
}

/* Botones */
.btn-primary {
    background-color: var(--secondary-color);
    color: var(--white);
    border: none;
    padding: 10px 25px;
    border-radius: 25px;
    text-decoration: none;
    font-weight: bold;
    transition: var(--transition);
    cursor: pointer;
    position: relative;
    overflow: hidden;
    animation: pulseGlow 2s infinite;
}

.btn-primary::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 50%;
    height: 100%;
    background: linear-gradient(to right, rgba(255,255,255,0) 0%, rgba(255,255,255,0.5) 50%, rgba(255,255,255,0) 100%);
    transform: skewX(-25deg);
    animation: shineSweep 3s infinite;
}

.btn-primary:hover {
    background-color: var(--primary-color);
    transform: translateY(-2px);
    animation: none;
}

@keyframes pulseGlow {
    0% { box-shadow: 0 0 0 0 rgba(194, 24, 91, 0.7); }
    70% { box-shadow: 0 0 0 15px rgba(194, 24, 91, 0); }
    100% { box-shadow: 0 0 0 0 rgba(194, 24, 91, 0); }
}

@keyframes shineSweep {
    0% { left: -100%; }
    20% { left: 200%; }
    100% { left: 200%; }
}

.btn-secondary {
    padding: 10px 25px;
    border-radius: 25px;
    text-decoration: none;
    font-weight: bold;
    transition: var(--transition);
    cursor: pointer;
    background-color: transparent;
    color: var(--white);
    border: 2px solid var(--white);
}

.btn-secondary:hover {
    background-color: var(--white);
    color: var(--primary-color);
}

/* Cabecera / Hero */
.hero {
    position: relative;
    height: 100vh;
    min-height: 600px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: var(--white);
    padding: 0 20px;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(rgba(136, 14, 79, 0.7), rgba(194, 24, 91, 0.7)), 
                url('https://images.unsplash.com/photo-1560066984-138dadb4c035?auto=format&fit=crop&w=1920&q=80') center/cover;
    z-index: -1;
    animation: zoomBackground 20s ease-in-out infinite alternate;
}

.hero-content {
    position: relative;
    z-index: 1;
}

@keyframes zoomBackground {
    0% { transform: scale(1); }
    100% { transform: scale(1.15); }
}

.hero h1 {
    font-size: 4rem;
    margin-bottom: 20px;
    letter-spacing: 2px;
    perspective: 1000px;
    display: inline-block;
}

.hover-letter {
    display: inline-block;
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275), color 0.3s, text-shadow 0.3s;
    cursor: default;
}

.hover-letter:hover {
    transform: translateY(-15px) scale(1.2) rotateX(15deg) rotateY(-15deg);
    color: var(--light-bg);
    text-shadow: 0px 2px 0px var(--secondary-color), 0px 4px 0px var(--secondary-color), 0px 6px 0px var(--primary-color), 0px 15px 15px rgba(0,0,0,0.5);
    z-index: 10;
    position: relative;
}

.hover-letter.space { width: 20px; }
.hero p { font-size: 1.5rem; margin-bottom: 30px; }

/* =========================================
   EFECTO DE TARJETAS APILADAS (STACKED CARDS)
   ========================================= */
.main-stack-container {
    position: relative;
    width: 100%;
}

section {
    position: sticky;
    top: 0;
    height: 100vh;
    width: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 40px 20px;
    background-color: var(--white);
    box-shadow: 0 -15px 35px rgba(0, 0, 0, 0.15);
    overflow: hidden;
}

#servicios {
    z-index: 2;
    background-color: var(--white);
}

#galeria {
    z-index: 3;
    background-color: var(--bg-cream);
}

#promociones {
    z-index: 4;
    background-color: var(--bg-blush);
}

.footer {
    position: sticky;
    top: 0;
    height: 100vh;
    width: 100%;
    background-color: var(--primary-color);
    color: var(--white);
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    text-align: center;
    padding: 40px 40px;
    overflow-y: auto;
    z-index: 5;
    box-shadow: 0 -20px 40px rgba(0, 0, 0, 0.3);
}

.section-title {
    text-align: center;
    margin-bottom: 40px;
}

.section-title h2 {
    color: var(--primary-color);
    font-size: 2.5rem;
    margin-bottom: 10px;
}

.section-title p {
    color: var(--text-light);
    font-size: 1.1rem;
}

/* Grid y Tarjetas */
.grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 25px;
    max-width: 1200px;
    width: 100%;
    margin: 0 auto;
}

.card {
    background: var(--white);
    padding: 30px 20px;
    border-radius: 12px;
    text-align: center;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
    transition: var(--transition);
    border-bottom: 3px solid transparent;
}

.card:hover {
    transform: translateY(-10px);
    border-bottom: 3px solid var(--secondary-color);
    box-shadow: 0 15px 40px rgba(0,0,0,0.1);
}

.card-icon {
    font-size: 2.5rem;
    color: var(--secondary-color);
    margin-bottom: 15px;
    display: inline-block;
    animation: floatElegant 3s ease-in-out infinite;
}

@keyframes floatElegant {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-8px); }
    100% { transform: translateY(0px); }
}

.card h3 {
    color: var(--primary-color);
    margin-bottom: 10px;
    font-size: 1.3rem;
}

.card p {
    color: var(--text-light);
    font-size: 0.95rem;
}

/* Promociones */
.promo-card {
    border: 1px solid var(--light-bg);
    position: relative;
    overflow: hidden;
}

.promo-badge {
    position: absolute;
    top: -15px;
    right: -15px;
    background-color: var(--secondary-color);
    color: var(--white);
    width: 75px;
    height: 75px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    font-weight: bold;
    padding-top: 15px;
    padding-right: 15px;
    animation: liquidBlob 4s ease-in-out infinite;
    box-shadow: inset 0px 0px 10px rgba(0,0,0,0.1), 0px 5px 15px rgba(194, 24, 91, 0.4);
}

@keyframes liquidBlob {
    0%, 100% { border-radius: 50% 50% 50% 50% / 50% 50% 50% 50%; }
    33% { border-radius: 60% 40% 55% 45% / 55% 45% 60% 40%; }
    66% { border-radius: 40% 60% 45% 55% / 45% 55% 40% 60%; }
}

/* Footer Estilo Tarjeta */
.footer-brand {
    margin-top: auto;
    margin-bottom: 25px;
}

.footer-logo {
    font-size: 2rem;
    letter-spacing: 3px;
    margin-bottom: 6px;
    text-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.footer-desc {
    max-width: 520px;
    margin: 8px auto 15px;
    opacity: 0.9;
    font-size: 1rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
    width: 100%;
    max-width: 1100px;
    text-align: left;
    margin-bottom: 25px;
}

.footer-col h3 {
    font-size: 1.1rem;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 2px solid rgba(255, 255, 255, 0.15);
}

.footer-col ul {
    list-style: none;
}

.footer-col li {
    margin-bottom: 10px;
    font-size: 0.95rem;
    opacity: 0.9;
    display: flex;
    align-items: center;
    gap: 8px;
}

.footer-col a {
    color: var(--white);
    text-decoration: none;
    transition: color 0.3s;
}

.footer-col a:hover {
    color: var(--light-bg);
}

.newsletter-form {
    display: flex;
    gap: 10px;
    margin-top: 12px;
}

.newsletter-form input {
    flex: 1;
    min-width: 0;
    padding: 10px 16px;
    border: none;
    border-radius: 25px;
    outline: none;
    font-size: 0.9rem;
}

.newsletter-form button {
    background: var(--secondary-color);
    color: var(--white);
    border: none;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    cursor: pointer;
    flex-shrink: 0;
    transition: all 0.3s ease;
}

.newsletter-form button:hover {
    background: var(--light-bg);
    color: var(--primary-color);
    transform: scale(1.1);
}

.footer-tagline {
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    padding-top: 15px;
    margin-bottom: auto;
    font-style: italic;
    opacity: 0.8;
}

/* =========================================
   GALERÍA 3D (Coverflow Style)
   ========================================= */
.gallery-3d-wrapper {
    position: relative;
    width: 100%;
    max-width: 900px;
    margin: 0 auto;
    padding: 10px 0;
    perspective: 1200px;
}

.gallery-3d-container {
    position: relative;
    height: 380px;
    display: flex;
    justify-content: center;
    align-items: center;
    transform-style: preserve-3d;
}

.gallery-item {
    position: absolute;
    width: 280px;
    height: 360px;
    border-radius: 15px;
    overflow: hidden;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.6s, z-index 0.6s;
    box-shadow: 0 15px 35px rgba(0,0,0,0.3);
    cursor: pointer;
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    pointer-events: none;
}

.gallery-item.active {
    transform: translateX(0) scale(1) translateZ(0);
    z-index: 3;
    opacity: 1;
    box-shadow: 0 20px 40px rgba(136, 14, 79, 0.5); 
    border: 3px solid var(--secondary-color);
}

.gallery-item.prev-1 {
    transform: translateX(-45%) scale(0.8) translateZ(-150px) rotateY(20deg);
    z-index: 2;
    opacity: 0.8;
}

.gallery-item.next-1 {
    transform: translateX(45%) scale(0.8) translateZ(-150px) rotateY(-20deg);
    z-index: 2;
    opacity: 0.8;
}

.gallery-item.prev-2 {
    transform: translateX(-80%) scale(0.6) translateZ(-300px) rotateY(35deg);
    z-index: 1;
    opacity: 0.5;
}

.gallery-item.next-2 {
    transform: translateX(80%) scale(0.6) translateZ(-300px) rotateY(-35deg);
    z-index: 1;
    opacity: 0.5;
}

/* Controles flotantes a los costados */
.gallery-controls {
    position: absolute;
    top: 50%;
    left: 0;
    width: 100%;
    display: flex;
    justify-content: space-between;
    transform: translateY(-50%);
    pointer-events: none; 
    z-index: 10;
    padding: 0 10px;
}

.gallery-controls button {
    background-color: var(--primary-color);
    color: var(--white);
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    font-size: 1.2rem;
    cursor: pointer;
    transition: var(--transition);
    box-shadow: 0 5px 15px rgba(136, 14, 79, 0.4);
    pointer-events: auto; 
    display: flex;
    align-items: center;
    justify-content: center;
}

.gallery-controls button:hover {
    background-color: var(--secondary-color);
    transform: scale(1.15) translateY(-2px);
}

/* Botón Flotante de Música */
.floating-music-btn {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background-color: var(--secondary-color); 
    color: var(--white);
    border: none;
    border-radius: 50%;
    width: 55px;
    height: 55px;
    font-size: 1.3rem;
    cursor: pointer;
    z-index: 9999; 
    box-shadow: 0px 4px 15px rgba(194, 24, 91, 0.5); 
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.3s ease, background-color 0.3s ease;
}

.floating-music-btn:hover {
    transform: scale(1.1);
    background-color: var(--primary-color);
}

/* Iconos de Redes Sociales */
.social-links {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 20px;
    margin-bottom: 15px;
}

.social-links a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    background-color: rgba(255, 255, 255, 0.1); 
    color: var(--white); 
    border-radius: 50%;
    font-size: 1.2rem;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.social-links a:hover {
    background-color: var(--secondary-color); 
    color: var(--white);
    transform: translateY(-5px); 
    box-shadow: 0 8px 15px rgba(194, 24, 91, 0.4); 
}

/* Responsive */
@media (max-width: 768px) {
    .nav-links { display: none; }
    .hero h1 { font-size: 2.8rem; }
    .footer { padding: 40px 20px; justify-content: flex-start; overflow-y: auto; }
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 30px;
        text-align: center;
    }
    .footer-col li { justify-content: center; }
    .newsletter-form { justify-content: center; }
    .gallery-item { width: 200px; height: 280px; }
    .gallery-3d-container { height: 300px; }
}