/* ==============================================
   LYUM ADVENT CALENDAR - STYLES FRONT-END
   ============================================== */

/* --- BANNIÈRE MODE TEST --- */
.lacc-test-mode-banner {
    background: linear-gradient(135deg, #ff9800 0%, #ff5722 100%);
    color: white;
    padding: 15px 20px;
    text-align: center;
    font-size: 1.2em;
    font-weight: 700;
    border-radius: 8px;
    margin-bottom: 30px;
    box-shadow: 0 4px 15px rgba(255, 152, 0, 0.4);
    animation: pulse-banner 2s infinite;
}

@keyframes pulse-banner {
    0%, 100% {
        transform: scale(1);
        box-shadow: 0 4px 15px rgba(255, 152, 0, 0.4);
    }
    50% {
        transform: scale(1.02);
        box-shadow: 0 6px 20px rgba(255, 152, 0, 0.6);
    }
}

/* --- WRAPPER & HEADER --- */
.lacc-calendar-wrapper {
    max-width: 1400px;
    margin: 0 auto;
    padding: 40px 20px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
}

.lacc-calendar-header {
    text-align: center;
    margin-bottom: 50px;
}

.lacc-title {
    font-size: 2.5em;
    margin-bottom: 10px;
    color: #2c3e50;
    font-weight: 700;
}

.lacc-subtitle {
    font-size: 1.2em;
    color: #7f8c8d;
    margin: 0;
}

/* --- GRILLE DE CARTES --- */
.lacc-calendar-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 20px;
    perspective: 1000px;
}

.lacc-calendar-grid[data-columns="4"] {
    grid-template-columns: repeat(4, 1fr);
}

.lacc-calendar-grid[data-columns="8"] {
    grid-template-columns: repeat(8, 1fr);
}

/* --- CARTE INDIVIDUELLE --- */
.lacc-card {
    position: relative;
    aspect-ratio: 2/3;
    cursor: pointer;
    transition: transform 0.3s ease;
}

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

.lacc-card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    transition: transform 0.6s;
    transform-style: preserve-3d;
}

.lacc-card.lacc-opened .lacc-card-inner {
    transform: rotateY(180deg);
}

.lacc-card-back,
.lacc-card-front {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
}

/* --- DOS DE CARTE --- */
.lacc-card-back {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
}

.lacc-card-number {
    position: absolute;
    top: 15px;
    right: 15px;
    background: rgba(255, 255, 255, 0.9);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.2em;
    color: #667eea;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.lacc-back-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.lacc-default-back {
    text-align: center;
    color: white;
    padding: 20px;
}

.lacc-logo {
    font-size: 2.5em;
    font-weight: 900;
    margin-bottom: 20px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.lacc-day-badge {
    background: rgba(255, 255, 255, 0.2);
    padding: 10px 20px;
    border-radius: 25px;
    font-size: 1.1em;
    font-weight: 600;
}

/* --- OVERLAY VERROUILLÉ --- */
.lacc-lock-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(3px);
}

.lacc-lock-icon {
    font-size: 3em;
    animation: pulse 2s infinite;
}

.lacc-card.lacc-locked {
    cursor: not-allowed;
}

.lacc-card.lacc-locked:hover {
    transform: none;
}

/* --- EFFET SCINTILLANT (DÉVERROUILLÉ) --- */
.lacc-sparkle-effect {
    position: absolute;
    top: 10px;
    left: 10px;
    font-size: 2em;
    animation: sparkle 1.5s infinite;
    pointer-events: none;
}

@keyframes sparkle {
    0%, 100% {
        transform: scale(1) rotate(0deg);
        opacity: 1;
    }
    50% {
        transform: scale(1.3) rotate(180deg);
        opacity: 0.7;
    }
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
}

/* --- FACE AVANT (CARTE RÉVÉLÉE) --- */
.lacc-card-front {
    background: #f8f9fa;
    transform: rotateY(180deg);
    position: relative;
}

.lacc-card-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.lacc-card-foil {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(
        45deg,
        transparent 30%,
        rgba(255, 255, 255, 0.3) 50%,
        transparent 70%
    );
    pointer-events: none;
    animation: foil-shine 3s infinite;
}

@keyframes foil-shine {
    0% {
        transform: translateX(-100%);
    }
    100% {
        transform: translateX(100%);
    }
}

/* --- DATE DE DÉVERROUILLAGE --- */
.lacc-unlock-date {
    text-align: center;
    margin-top: 8px;
    font-size: 0.85em;
    color: #7f8c8d;
    font-weight: 500;
}

/* --- MODALE --- */
.lacc-modal {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    animation: fadeIn 0.3s;
}

.lacc-modal.active {
    display: block;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.lacc-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(5px);
}

.lacc-modal-content {
    position: relative;
    margin: 5% auto;
    max-width: 900px;
    background: white;
    border-radius: 20px;
    box-shadow: 0 10px 50px rgba(0, 0, 0, 0.5);
    animation: slideUp 0.4s ease-out;
}

@keyframes slideUp {
    from {
        transform: translateY(50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.lacc-modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 1.5em;
    cursor: pointer;
    z-index: 10;
    transition: all 0.3s;
}

.lacc-modal-close:hover {
    background: rgba(0, 0, 0, 0.9);
    transform: rotate(90deg);
}

.lacc-modal-body {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    padding: 40px;
}

.lacc-modal-image {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.2);
}

.lacc-modal-image img {
    width: 100%;
    height: auto;
    display: block;
}

.lacc-card-foil-modal {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(
        45deg,
        transparent 30%,
        rgba(255, 255, 255, 0.4) 50%,
        transparent 70%
    );
    pointer-events: none;
    animation: foil-shine 3s infinite;
}

.lacc-modal-text {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.lacc-modal-text h3 {
    font-size: 2em;
    margin: 0 0 20px 0;
    color: #2c3e50;
}

.lacc-modal-text p {
    font-size: 1.1em;
    line-height: 1.6;
    color: #555;
}

/* --- RESPONSIVE --- */
@media (max-width: 1200px) {
    .lacc-calendar-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

@media (max-width: 768px) {
    .lacc-calendar-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 15px;
    }
    
    .lacc-modal-body {
        grid-template-columns: 1fr;
        gap: 30px;
        padding: 30px 20px;
    }
    
    .lacc-title {
        font-size: 1.8em;
    }
}

@media (max-width: 480px) {
    .lacc-calendar-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }
    
    .lacc-card-number {
        width: 30px;
        height: 30px;
        font-size: 1em;
    }
}