/* ====== CONTENEDOR GENERAL ====== */
.stories-container {
    max-width: 1200px;
    margin: 2rem auto;
    padding: 1.5rem;
    background-color: transparent;
    border-radius: 12px;
    text-align: center;
    max-height: calc(100vh - 150px);
    overflow-y: auto;
}

/* ====== TÍTULO DE LA SECCIÓN ====== */
.stories-title {
    font-family: 'Good Luck', cursive;
    font-size: 3em;
    color: #ffffff;
    font-style: italic;
    margin-bottom: 1rem;
    text-shadow: 2px 2px 10px rgba(0,0,0,0.6);
}

/* ====== GRID DE TARJETAS ====== */
.stories-grid {
    display: grid;
    gap: 2rem;
    grid-template-columns: repeat(3, 1fr);
    justify-items: center;
}

/* CENTRADO Y TAMAÑO CONTROLADO CUANDO SOLO HAY UNA TARJETA */
.stories-grid.one-card {
    grid-template-columns: 1fr;
}
.stories-grid.one-card .story-card {
    max-width: 350px;
    width: 100%;
}

/* ====== TARJETAS CUADRADAS ====== */
.story-card {
    position: relative;
    background-size: cover;
    background-position: center;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0,0,0,0.15);
    cursor: pointer;
    transition: transform 0.3s, box-shadow 0.3s, filter 0.3s;
    border: 3px solid #563263;
    aspect-ratio: 1 / 1;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
}

/* ====== EFECTO HOVER ====== */
.story-card:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 30px rgba(0,0,0,0.3);
    filter: brightness(1.1);
}

/* ====== TÍTULO EN LAS TARJETAS ====== */
.story-title {
    position: relative;
    color: #ffffff;
    font-family: 'EB Garamond', serif;
    font-size: 2em;
    text-shadow: 3px 3px 15px rgba(0,0,0,0.8);
    z-index: 2;
    pointer-events: none;
    max-width: 80%;
    text-align: center;
}

/* ====== RESPONSIVO ====== */
@media (max-width: 991px) {
    .stories-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 600px) {
    .stories-grid {
        grid-template-columns: 1fr;
    }
    .story-title {
        font-size: 1.8em;
        max-width: 90%;
    }
}
/* Eliminar borde azul al hacer clic (focus) */
.story-card:focus {
    outline: none;
    box-shadow: none;
}

/* Evitar selección del contenido */
.story-card {
    user-select: none;
    -webkit-user-select: none;
}
