:root {
    --primary-color: #d63384;
    --secondary-color: #222222;
    --bg-color: #fdfbf7;
    --text-color: #333;
    --white: #ffffff;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Montserrat', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    line-height: 1.6;
    overflow-x: hidden;
    padding-bottom: 120px;
}

h1, h2, h3, h4 {
    font-family: 'Playfair Display', serif;
    color: var(--secondary-color);
}

/* HEADER */
header {
    background-color: var(--white);
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    position: sticky;
    top: 0;
    z-index: 100;
}

.logo {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--primary-color);
    display: flex;
    align-items: center;
    gap: 10px;
}

.cart-icon {
    position: relative;
    cursor: pointer;
    font-size: 1.5rem;
    color: var(--secondary-color);
}

.cart-count {
    position: absolute;
    top: -10px;
    right: -10px;
    background-color: var(--primary-color);
    color: white;
    font-size: 0.8rem;
    border-radius: 50%;
    padding: 2px 6px;
    font-weight: bold;
}

/* HERO / POLICIES */
.hero {
    text-align: center;
    padding: 3rem 1rem;
    background-color: var(--white);
    margin-bottom: 2rem;
}

.hero h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
    letter-spacing: 2px;
}

.hero h2 {
    font-size: 2rem;
    color: var(--primary-color);
    margin-bottom: 1.5rem;
}

.policies {
    max-width: 600px;
    margin: 0 auto;
    font-size: 0.95rem;
    text-align: center;
}

.policies strong {
    display: block;
    margin-top: 1rem;
    font-size: 1.1rem;
}

/* SERVICES GRID */
.services-container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 1rem;
}

.service-card {
    display: flex;
    background-color: var(--white);
    border-radius: 15px;
    overflow: hidden;
    margin-bottom: 3rem;
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
    min-height: 400px;
}

.service-card.reverse {
    flex-direction: row-reverse;
}

.service-info {
    flex: 1;
    padding: 3rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
}

.service-info h3 {
    font-size: 2rem;
    margin-bottom: 1rem;
    text-transform: capitalize;
}

.service-info p {
    font-size: 1rem;
    color: #666;
    margin-bottom: 1.5rem;
}

.service-info .price {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--primary-color);
    margin-bottom: 1.5rem;
}

.btn {
    display: inline-block;
    padding: 12px 24px;
    background-color: var(--primary-color);
    color: var(--white);
    text-decoration: none;
    border-radius: 25px;
    font-weight: 600;
    text-align: center;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: 'Montserrat', sans-serif;
}

.btn:hover {
    background-color: #b0246b;
    transform: translateY(-2px);
}

.btn-outline {
    background-color: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
}

.btn-outline:hover {
    background-color: var(--primary-color);
    color: var(--white);
}

/* IMAGE CONTAINER & HOVER EFFECTS */
.service-image {
    flex: 1;
    position: relative;
    background-color: #eee;
    overflow: hidden;
}

.service-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

/* Hover Overlay (Transformación de la imagen) */
.hover-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(255, 255, 255, 0.98);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 2rem;
    text-align: center;
    opacity: 0;
    transition: opacity 0.4s ease;
    z-index: 5;
    pointer-events: none; /* Permite que los clics pasen al botón de galería si es necesario */
}

.service-image:hover .hover-overlay {
    opacity: 1;
    pointer-events: auto; /* Activa los clics cuando es visible */
}

.service-image:hover img {
    transform: scale(1.1);
}

.hover-overlay h3 {
    font-size: 2rem;
    margin-bottom: 1rem;
}

.hover-overlay p {
    font-size: 1rem;
    color: #555;
    margin-bottom: 1.5rem;
}

/* Gallery Button */
.gallery-btn {
    position: absolute;
    top: 20px;
    right: 20px; /* Por defecto a la derecha */
    background-color: rgba(255, 255, 255, 0.9);
    color: var(--secondary-color);
    border: none;
    padding: 10px 20px;
    border-radius: 20px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    z-index: 10; /* Asegura que esté por encima del hover overlay */
}

.gallery-btn:hover {
    background-color: var(--primary-color);
    color: var(--white);
}

/* Si la tarjeta está invertida (imagen a la izquierda), el botón va a la izquierda */
.service-card.reverse .gallery-btn {
    right: auto;
    left: 20px;
}

/* MODALS */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.8);
    z-index: 1000;
    justify-content: center;
    align-items: center;
}

.modal-content {
    background-color: var(--white);
    width: 90%;
    max-width: 900px;
    max-height: 90vh;
    border-radius: 15px;
    overflow-y: auto;
    padding: 2rem;
    position: relative;
}

.close-modal {
    position: absolute;
    top: 15px;
    right: 20px;
    font-size: 2rem;
    cursor: pointer;
    color: var(--secondary-color);
}

.modal-title {
    text-align: center;
    margin-bottom: 2rem;
    font-size: 2rem;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1rem;
}

.gallery-grid img {
    width: 100%;
    height: 250px;
    object-fit: cover;
    border-radius: 8px;
    transition: transform 0.3s ease;
}

.gallery-grid img:hover {
    transform: scale(1.05);
}

/* CART SIDEBAR */
#cart-sidebar {
    position: fixed;
    top: 0;
    right: -400px;
    width: 350px;
    height: 100vh;
    background-color: var(--white);
    box-shadow: -5px 0 15px rgba(0,0,0,0.1);
    z-index: 1001;
    transition: right 0.3s ease;
    padding: 2rem;
    display: flex;
    flex-direction: column;
}

#cart-sidebar.open {
    right: 0;
}

.cart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    border-bottom: 1px solid #eee;
    padding-bottom: 1rem;
}

.cart-items {
    flex: 1;
    overflow-y: auto;
}

.cart-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
    border-bottom: 1px solid #f0f0f0;
}

.cart-item-info h5 {
    font-size: 1rem;
    margin-bottom: 0.2rem;
}

.cart-item-info span {
    color: var(--primary-color);
    font-weight: bold;
}

.remove-item {
    color: #ff4d4d;
    cursor: pointer;
    background: none;
    border: none;
    font-size: 1.2rem;
}

.cart-footer {
    margin-top: 1rem;
    border-top: 1px solid #eee;
    padding-top: 1rem;
}

/* FLOATING BUTTONS */
.floating-buttons {
    position: fixed;
    bottom: 20px;
    right: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    z-index: 999;
}

.btn-whatsapp {
    background-color: #25D366;
    color: white;
    width: 70px;
    height: 70px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 2.5rem;
    text-decoration: none;
    box-shadow: 0 4px 10px rgba(37, 211, 102, 0.4);
    transition: transform 0.3s ease;
}

.btn-whatsapp:hover {
    transform: scale(1.1);
}

.social-buttons {
    display: flex;
    gap: 10px;
}

.btn-social {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1.5rem;
    color: white;
    text-decoration: none;
    transition: transform 0.3s ease;
}

.btn-facebook { background-color: #1877F2; }
.btn-instagram { background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%); }

.btn-social:hover { transform: scale(1.1); }

/* BOOKING PAGE (Cita.html) */
.booking-page {
    padding-bottom: 2rem;
}

.booking-container {
    max-width: 800px;
    margin: 2rem auto;
    background-color: var(--white);
    padding: 3rem;
    border-radius: 15px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
}

.booking-container h2 {
    text-align: center;
    margin-bottom: 2rem;
    font-size: 2.5rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
}

.form-group input, .form-group select {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-family: 'Montserrat', sans-serif;
    font-size: 1rem;
}

.time-range {
    display: flex;
    gap: 1rem;
}

.time-range select {
    flex: 1;
}

.cart-summary {
    background-color: #f9f9f9;
    padding: 1.5rem;
    border-radius: 8px;
    margin-bottom: 2rem;
}

.cart-summary h4 {
    margin-bottom: 1rem;
}

.cart-summary ul {
    list-style: none;
    margin-bottom: 1rem;
}

.cart-summary li {
    display: flex;
    justify-content: space-between;
    padding: 0.5rem 0;
    border-bottom: 1px solid #eee;
}

/* RESPONSIVE */
@media (max-width: 768px) {
    .service-card, .service-card.reverse {
        flex-direction: column;
    }
    .service-image {
        height: 250px;
    }
    .hero h1 { font-size: 2rem; }
    .hero h2 { font-size: 1.5rem; }
    .time-range { flex-direction: column; }
    #cart-sidebar { width: 100%; right: -100%; }
    .service-info { padding: 2rem; }
    .gallery-btn { top: 10px; right: 10px; }
    .service-card.reverse .gallery-btn { left: 10px; right: auto; }
}