body {
    margin: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    background-color: #0f0f0f;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    overflow: hidden;
}

.container {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 95%;
    max-width: 1200px;
}

.wrapper-foto {
    width: 100%;
    display: flex;
    justify-content: center;
    margin-bottom: 30px;
    overflow: hidden; /* CRITICO: evita que la imagen tape los botones al hacer zoom */
    border-radius: 15px;
    cursor: zoom-in; /* Cambia el cursor para indicar que se puede interactuar */
}

img {
    width: auto;
    max-width: 100%;
    height: auto;
    max-height: 65vh;
    border-radius: 15px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.9);
    background-color: #222;
    
    /* Cambiamos la transición para que el zoom sea fluido pero no lento */
    transition: opacity 0.4s ease-out, transform 0.1s ease-out; 
    transform: scale(1);
    will-change: transform; /* Optimización de rendimiento para el navegador */
}

.foto-oculta {
    opacity: 0;
    transform: scale(0.95);
    transition: none !important;
}

/* CONTROLES MÚLTIPLES */
.controles {
    display: flex;
    flex-direction: column;
    gap: 20px;
    align-items: center;
    background: #1a1a1a;
    padding: 20px;
    border-radius: 20px;
    border: 1px solid #333;
}

#categorias-wrap {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
}

/* Estilo de los "botones" de categoría */
#categorias-wrap label {
    background: #2a2a2a;
    color: #aaa;
    padding: 8px 15px;
    border-radius: 25px;
    cursor: pointer;
    font-size: 0.9rem;
    border: 1px solid #444;
    transition: all 0.2s;
}

/* Escondemos el checkbox real */
#categorias-wrap input {
    display: none;
}

/* Cuando el checkbox está marcado */
#categorias-wrap label:has(input:checked) {
    background: #ff4757; /* Color coral/rojo */
    color: white;
    border-color: #ff6b81;
    box-shadow: 0 0 15px rgba(255, 71, 87, 0.3);
}

#categorias-wrap label:hover {
    border-color: #666;
}

button {
    width: 60px;
    height: 60px;
    font-size: 1.8rem;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    background: #333;
    color: white;
    border: none;
    border-radius: 50%;
    transition: all 0.2s ease;
    box-shadow: 0 4px 15px rgba(0,0,0,0.5);
}

button:hover {
    background-color: #444;
    transform: scale(1.1) rotate(15deg);
}

button:active {
    transform: scale(0.9);
}