/* ========================================
   SERVICIOS SECTION - V2.5 HÍBRIDO
   Fondos fotográficos sutiles + Iconos protagonistas
   ======================================== */

/* Grid de servicios */
#serviciosGrid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
    margin-top: 2rem;
}

/* Card individual con fondo fotográfico */
.servicio-card {
    position: relative;
    background-size: cover;
    background-position: center;
    border-radius: 20px;
    padding: 2.5rem 2rem;
    text-align: center;
    transition: all 0.4s ease;
    overflow: hidden;
    min-height: 480px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

/* Cards con foto: centrar botones verticalmente */
.servicio-card-foto {
    justify-content: center;
    padding: 2.5rem 2rem; /* Padding normal, badge compacto */
}

.servicio-card-foto .servicio-contenido {
    flex: 0;
    margin-bottom: auto;
}

.servicio-card-foto .servicio-botones {
    margin-top: auto;
}

/* Overlay sutil sobre la foto de fondo */
.servicio-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--card-overlay-color, #ffffff);
    opacity: var(--card-overlay-opacity, 0.92);
    backdrop-filter: blur(3px);
    z-index: 1;
    transition: all 0.4s ease;
}

/* Al hacer hover, el overlay se vuelve un poco más transparente */
.servicio-card:hover::before {
    opacity: calc(var(--card-overlay-opacity, 0.92) * 0.9);
    backdrop-filter: blur(5px);
}

/* Todo el contenido de la card sobre el overlay */
.servicio-card > * {
    position: relative;
    z-index: 2;
}

/* Hover effect */
.servicio-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 50px rgba(212, 175, 55, 0.3);
}

/* Badge configuracion global */
.servicio-titulo-badge {
    position: absolute;
    top: 14px;
    left: 11px;
    background: linear-gradient(135deg, #f4d704 0%, #ffff28 100%);
    padding: 0.5rem 1.2rem;
    border-radius: 19px;
    z-index: 3;
    box-shadow: 0 4px 12px rgba(255, 107, 53, 0.4);
    backdrop-filter: blur(5px);
    border: 2px solid rgba(255, 255, 255, 0.2);
}

.servicio-titulo-badge .servicio-titulo {
    color: #000000;
    font-size: 0.95rem;
    font-weight: 700;
    margin: 0;
    letter-spacing: 1.2px;
    text-shadow: none;
    font-family: inherit;
    text-transform: capitalize;
}

/* Badge "DESTACADO" */
.servicio-destacado-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    background: linear-gradient(135deg, #FFD700 0%, #FFA500 100%);
    color: #000;
    padding: 0.4rem 1rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    z-index: 3;
    box-shadow: 0 4px 12px rgba(255, 215, 0, 0.4);
}

.servicio-destacado-badge i {
    margin-right: 0.3rem;
    font-size: 0.85rem;
}

/* Estrella pequeña para cards con foto */
.servicio-estrella-badge {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #FFD700 0%, #FFA500 100%);
    color: #000;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    z-index: 4;
    box-shadow: 0 4px 15px rgba(255, 215, 0, 0.5);
    transition: transform 0.3s ease;
    border: 3px solid white;
}

.servicio-estrella-badge:hover {
    transform: scale(1.15) rotate(15deg);
}

/* Contenedor del icono circular */
.servicio-icon-wrapper {
    width: 120px;
    height: 120px;
    margin: 0 auto 1.5rem;
    border-radius: 50%;
    background: linear-gradient(135deg, #F4D03F 0%, #D4AF37 50%, #C4A030 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 25px rgba(212, 175, 55, 0.4);
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.servicio-card:hover .servicio-icon-wrapper {
    transform: scale(1.15) rotate(5deg);
    box-shadow: 0 12px 35px rgba(212, 175, 55, 0.6);
}

.servicio-icon-wrapper i {
    font-size: 3rem;
    color: white;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

/* Título del servicio */
.servicio-titulo {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: #1a1a1a;
    font-family: 'Cormorant Garamond', serif;
    text-shadow: 0 2px 4px rgba(255, 255, 255, 0.8);
}

/* Agregar margen superior al título cuando no hay icono */
.servicio-contenido:not(:has(.servicio-icon-wrapper)) .servicio-titulo {
    margin-top: 3rem;
}

/* Texto más legible cuando hay imagen de fondo */
.servicio-card[style*="background-image"] .servicio-titulo {
    text-shadow: 
        0 2px 8px rgba(255, 255, 255, 0.9),
        0 0 20px rgba(255, 255, 255, 0.7),
        2px 2px 4px rgba(0, 0, 0, 0.3);
}

.servicio-card[style*="background-image"] .servicio-descripcion-corta {
    text-shadow: 
        0 1px 4px rgba(255, 255, 255, 0.9),
        0 0 10px rgba(255, 255, 255, 0.6),
        1px 1px 2px rgba(0, 0, 0, 0.2);
}

/* Descripción */
.servicio-descripcion-corta {
    font-size: 1rem;
    color: #555;
    line-height: 1.6;
    margin-bottom: 1.5rem;
    text-shadow: 0 1px 2px rgba(255, 255, 255, 0.8);
}

/* Contenedor de botones */
.servicio-botones {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin-top: auto;
}

/* Cards con foto: botones más prominentes */
.servicio-card-foto .servicio-botones {
    gap: 0.8rem;
}

/* Botón "Ver más" */
.servicio-ver-mas {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.8rem 2rem;
    background: transparent;
    color: #D4AF37;
    border: 2px solid #D4AF37;
    border-radius: 30px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
    text-transform: uppercase;
}

/* Botones sobre foto: fondo blanco con transparencia */
.servicio-card-foto .servicio-ver-mas {
    background: rgba(255, 255, 255, 0.95);
    color: #D4AF37;
    border: 2px solid #D4AF37;
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.servicio-ver-mas:hover {
    background: #D4AF37;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(212, 175, 55, 0.4);
}

.servicio-card-foto .servicio-ver-mas:hover {
    background: #D4AF37;
    color: white;
    border-color: #D4AF37;
    box-shadow: 0 6px 20px rgba(212, 175, 55, 0.5);
}

.servicio-ver-mas i {
    transition: transform 0.3s ease;
}

.servicio-ver-mas:hover i {
    transform: translateX(3px);
}

/* Botón "¿Hablamos?" (ya tiene estilos en management-contact.css) */
/* Solo agregamos pequeño ajuste para consistencia */
a.servicio-ver-mas.service-btn-contact {
    margin-top: 0 !important;
}

/* Ajuste para cards con foto */
.servicio-card-foto .service-btn-contact {
    background: rgba(244, 208, 63, 0.95) !important;
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.servicio-card-foto .service-btn-contact:hover {
    background: linear-gradient(135deg, #FFE66D 0%, #F4D03F 50%, #D4AF37 100%) !important;
    box-shadow: 0 6px 20px rgba(244, 208, 63, 0.5);
}

/* ========================================
   COLORES DE OVERLAY POR SERVICIO
   ======================================== */

/* Models - Azul muy claro */
.servicio-card[data-color="#f0f8ff"]::before {
    --card-overlay: rgba(240, 248, 255, 0.92);
    --card-overlay-hover: rgba(240, 248, 255, 0.85);
}

/* School - Amarillo muy claro */
.servicio-card[data-color="#fff8e1"]::before {
    --card-overlay: rgba(255, 248, 225, 0.92);
    --card-overlay-hover: rgba(255, 248, 225, 0.85);
}

/* Management - Púrpura muy claro */
.servicio-card[data-color="#f3e5f5"]::before {
    --card-overlay: rgba(243, 229, 245, 0.92);
    --card-overlay-hover: rgba(243, 229, 245, 0.85);
}

/* Mannequins - Verde muy claro */
.servicio-card[data-color="#e8f5e9"]::before {
    --card-overlay: rgba(232, 245, 233, 0.92);
    --card-overlay-hover: rgba(232, 245, 233, 0.85);
}

/* ========================================
   RESPONSIVE
   ======================================== */

/* Tablet */
@media (max-width: 1200px) {
    #serviciosGrid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.5rem;
    }
}

/* Mobile */
@media (max-width: 768px) {
    #serviciosGrid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
        padding: 0 1rem;
    }

    .servicio-card {
        min-height: 420px;
        padding: 2rem 1.5rem;
    }

    .servicio-icon-wrapper {
        width: 100px;
        height: 100px;
    }

    .servicio-icon-wrapper i {
        font-size: 2.5rem;
    }

    .servicio-titulo {
        font-size: 1.5rem;
    }

    .servicio-descripcion-corta {
        font-size: 0.95rem;
    }

    .servicio-card:hover {
        transform: translateY(-5px);
    }
}

@media (max-width: 576px) {
    .servicio-card {
        min-height: 400px;
    }

    .servicio-destacado-badge {
        font-size: 0.7rem;
        padding: 0.3rem 0.8rem;
    }
}

/* ========================================
   SMOOTH ANIMATIONS
   ======================================== */

.servicio-card {
    backface-visibility: hidden;
    perspective: 1000px;
}

/* Fade in animation cuando se cargan las cards */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.servicio-card {
    animation: fadeInUp 0.6s ease-out;
}

.servicio-card:nth-child(1) { animation-delay: 0.1s; }
.servicio-card:nth-child(2) { animation-delay: 0.2s; }
.servicio-card:nth-child(3) { animation-delay: 0.3s; }
.servicio-card:nth-child(4) { animation-delay: 0.4s; }
