/* ============================================================
   Votes — Enfin Lire
   ============================================================ */

/* ---- Accès restreint ---- */
.eflv-gate {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 48px 32px;
    border-radius: 16px;
    border: 1.5px solid #e5e7eb;
    background: #fff;
    max-width: 440px;
    margin: 0 auto;
    font-family: 'Quicksand', sans-serif;
}

.eflv-gate-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: #f1f5f9;
    color: #64748b;
    margin-bottom: 18px;
}

.eflv-gate-icon--lock {
    background: #fef9c3;
    color: #ca8a04;
}

.eflv-gate-title {
    font-family: 'Nunito', sans-serif;
    font-size: 21px;
    font-weight: 800;
    color: #111;
    margin: 0 0 10px;
}

.eflv-gate-text {
    font-size: 15px;
    color: #555;
    margin: 0 0 20px;
    line-height: 1.6;
}

.eflv-gate-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 26px;
    border-radius: 999px;
    background: #111;
    color: #fff;
    font-family: 'Quicksand', sans-serif;
    font-size: 15px;
    font-weight: 700;
    text-decoration: none;
    transition: background .2s;
}

.eflv-gate-btn:hover {
    background: #333;
    color: #fff;
}

/* ---- Progress bar ---- */
.eflv-progress-wrap {
    font-family: 'Quicksand', sans-serif;
    margin-bottom: 24px;
}

.eflv-progress-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 8px;
}

.eflv-progress-label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 15px;
    font-weight: 700;
    color: #222;
}

.eflv-progress-label svg {
    flex-shrink: 0;
    color: #FDC71C;
}

.eflv-progress-counter {
    font-size: 15px;
    font-weight: 700;
    color: #222;
}

.eflv-progress-counter #eflv-progress-count {
    color: #FDC71C;
}

.eflv-progress-bar-track {
    height: 10px;
    background: #f0f0f0;
    border-radius: 999px;
    overflow: hidden;
}

.eflv-progress-bar-fill {
    height: 100%;
    border-radius: 999px;
    background: linear-gradient(90deg, #FDC71C 0%, #2f9140 100%);
    transition: width 0.35s ease;
}

/* ---- Grid ---- */
.eflv-wrapper {
    font-family: 'Quicksand', sans-serif;
    position: relative;
    padding-bottom: 90px;
}

.eflv-closed-banner {
    padding: 12px 16px;
    background: #f3f4f6;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 600;
    color: #555;
    margin-bottom: 20px;
}

.eflv-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.eflv-card--hidden {
    display: none !important;
}

/* ---- Card ---- */
.eflv-card {
    position: relative;
    background: #fff;
    border-radius: 16px;
    border: 2px solid #ebebeb;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: border-color 0.2s, box-shadow 0.2s;
    cursor: default;
}

.eflv-card.is-selected {
    border-color: #FDC71C;
    box-shadow: 0 4px 18px rgba(253, 199, 28, 0.25);
}

/* Rank badge overlay */
.eflv-rank-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
    background: #FDC71C;
    color: #fff;
    line-height: 1.3;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
    pointer-events: none;
}

.eflv-rank-badge sup {
    font-size: 9px;
    line-height: 1;
}

/* Cover */
.eflv-card-cover {
    width: 100%;
    overflow: hidden;
    background: #f5f5f5;
}

.eflv-card-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease;
}

.eflv-card:hover .eflv-card-cover img {
    transform: scale(1.03);
}

.eflv-card-cover-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f9f9f9;
}

/* Info */
.eflv-card-info {
    padding: 10px 12px 6px;
    flex: 1;
}

.eflv-card-title {
    font-family:"Nunito";
    font-size: 14px;
    font-weight: 700;
    color: #222;
    margin: 0 0 3px;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.eflv-card-author {
    font-family: "Quicksand";
    font-size: 12px;
    font-weight: 500;
    color: #888;
    margin: 0;
}

/* Medal buttons */
.eflv-card-medals {
    display: flex;
    gap: 6px;
    padding: 8px 12px 12px;
}

.eflv-medal-btn {
    flex: 1;
    display: flex !important;
    align-items: center;
    justify-content: center;
    height: 38px;
    border-radius: 15px !important;
    border: 1.5px solid #e5e5e5 !important;
    background: #fafafa;
    cursor: pointer !important;
    transition: border-color 0.15s, background 0.15s, transform 0.1s !important;
    font-size: 18px !important;
    line-height: 1;
    padding: 0 !important;
}

.eflv-medal-btn:hover:not(:disabled) {
    background: #fff7da !important;
    border-color: #FDC71C !important;
    transform: translateY(-2px) !important;
}

.eflv-medal-btn.is-active {
    background: #FDC71C;
    border-color: #f0b800;
    box-shadow: 0 2px 8px rgba(253, 199, 28, 0.35);
}

.eflv-medal-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.eflv-medal-emoji {
    display: block;
    line-height: 1;
}

/* ---- Load more ---- */
.eflv-load-more-wrap {
    text-align: center;
    margin: 24px 0;
}

.eflv-load-more {
    border-radius: 15px !important;
    border: 1.5px solid #FDC71C !important;
    background: #fff7da;
    padding: 10px 24px !important;
    font-size: 14px !important;
    font-weight: 700 !important;
    font-family: 'Quicksand', sans-serif;
    color: #5b4a1f !important;
    cursor: pointer !important;
    transition: background 0.15s !important;
}

.eflv-load-more:hover {
    background: #ffe9b4 !important;
}

/* ---- Sticky bar ---- */
.eflv-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 999;
    background: #fff;
    border-top: 2px solid #FDC71C;
    box-shadow: 0 -4px 24px rgba(0,0,0,0.10);
    padding: 12px 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
    font-family: 'Quicksand', sans-serif;
}

.eflv-bar-pills {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    flex: 1;
}

.eflv-bar-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 999px;
    border: 1.5px solid #e5e5e5;
    background: #fafafa !important;
    font-size: 13px;
    font-weight: 600;
    color: #aaa !important;
    transition: border-color 0.2s, background 0.2s, color 0.2s;
    max-width: 220px;
}

.eflv-bar-pill.is-filled {
    border-color: #FDC71C;
    background: #fff7da;
    color: #222;
}

.eflv-bar-pill-emoji {
    font-size: 16px;
    line-height: 1;
    flex-shrink: 0;
}

.eflv-bar-pill-title {
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.eflv-bar-pill-remove {
    background: none;
    border: none !important;
    padding: 0 !important;
    margin-left: 2px;
    cursor: pointer !important;
    font-size: 16px !important;
    line-height: 1;
    color: #bbb !important;
    display: flex !important;
    align-items: center;
    flex-shrink: 0;
    transition: color 0.15s !important;
}

.eflv-bar-pill-remove:hover {
    color: #e03b3b;
    background: none !important;
}

.eflv-bar-action {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 4px;
    flex-shrink: 0;
}

.eflv-submit-btn {
    display: inline-flex !important;
    align-items: center;
    gap: 8px;
    padding: 12px 24px !important;
    border-radius: 15px !important;
    border: none !important;
    background: #FDC71C !important;
    color: #fff !important;
    font-family: 'Quicksand', sans-serif;
    font-size: 15px !important;
    font-weight: 700 !important;
    cursor: pointer !important;
    white-space: nowrap !important;
    transition: background 0.15s, transform 0.1s !important;
}

.eflv-submit-btn:hover:not(:disabled) {
    background: #f0b800;
    transform: translateY(-1px);
}

.eflv-submit-btn:disabled {
    opacity: 0.55;
    cursor: not-allowed;
    transform: none;
}

.eflv-bar-msg {
    font-size: 12px;
    font-weight: 600;
    color: #2f9140;
    text-align: right;
}

.eflv-bar-msg.is-error {
    color: #e03b3b;
}

/* ---- Responsive ---- */
@media (max-width: 1100px) {
    .eflv-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .eflv-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 14px;
    }

    .eflv-bar {
        padding: 10px 14px;
    }

    .eflv-bar-pill {
        max-width: 160px;
    }
}

@media (max-width: 480px) {
    .eflv-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .eflv-bar {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
    }

    .eflv-bar-pills {
        justify-content: center;
    }

    .eflv-bar-action {
        align-items: stretch;
    }

    .eflv-submit-btn {
        text-align: center;
    }
}
