/**
 * Styles pour le portfolio vidéo
 */

/* Police globale pour tous les éléments du portfolio */
.rm-portfolio-container,
.rm-portfolio-filters,
.rm-filter,
.rm-portfolio-item,
.rm-portfolio-title,
.rm-portfolio-content,
.rm-portfolio-badge,
.rm-portfolio-category,
.rm-video-modal,
h1 {
    font-family: 'Bebas Neue', sans-serif !important;
}

/* Conteneur principal avec dégradé */
.rm-portfolio-container {
    margin-bottom: 50px;
    position: relative;
    width: 90%;
    margin: 0 auto 50px;
    padding: 0 15px;
}

/* Fond dégradé noir-jaune */
.video-portfolio-section,
.portfolio-page {
    background: linear-gradient(90deg, #000000 0%, #000000 60%, rgba(247, 200, 0, 0.3) 100%);
    position: relative;
    padding: 60px 0 80px;
    min-height: 100vh;
}

/* En-tête du portfolio */
.rm-portfolio-header {
    margin-bottom: 40px;
}

.rm-portfolio-title {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 20px;
    color: #ffffff;
}

/* Filtres */
.rm-portfolio-filters {
    display: flex;
    flex-wrap: wrap;
    margin-bottom: 30px;
    justify-content: flex-start;
    gap: 20px;
}

.rm-filter {
    background: none;
    border: none;
    color: #ffffff;
    cursor: pointer;
    font-size: 16px;
    font-weight: 600;
    padding: 5px 0;
    position: relative;
    text-transform: uppercase;
    transition: all 0.3s ease;
}

.rm-filter:after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background-color: #ecc900;
    transition: width 0.3s ease;
}

.rm-filter.active {
    color: #ecc900;
}

.rm-filter.active:after,
.rm-filter:hover:after {
    width: 100%;
}

.rm-filter:hover {
    color: #ecc900;
}

.rm-filter:focus {
    outline: none;
}

/* Grille de portfolio */
.rm-portfolio-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr) !important;
    grid-gap: 30px;
    margin-bottom: 50px;
    width: 100%;
}

.rm-portfolio-grid.columns-2,
.rm-portfolio-grid.columns-3,
.rm-portfolio-grid.columns-4 {
    grid-template-columns: repeat(2, 1fr) !important;
}

/* Éléments du portfolio */
.rm-portfolio-item {
    margin-bottom: 30px;
    transition: all 0.3s ease;
    position: relative;
    transform: translateZ(0);
    backface-visibility: hidden;
    width: 100% !important;
}

.rm-portfolio-item-inner {
    background-color: transparent;
    border-radius: 0;
    overflow: hidden;
    position: relative;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.rm-portfolio-item-inner:hover {
    transform: translateY(-5px);
}

/* Badge nouveauté */
.rm-portfolio-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    background-color: #ecc900;
    color: #000000;
    padding: 5px 10px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    z-index: 5;
    border-radius: 0;
    letter-spacing: 0.5px;
}

/* Miniature */
.rm-portfolio-thumbnail {
    position: relative;
    overflow: hidden;
    aspect-ratio: 16/9;
}

.rm-portfolio-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.rm-portfolio-item:hover .rm-portfolio-thumbnail img {
    transform: scale(1.05);
}

/* Contenu */
.rm-portfolio-content {
    position: absolute;
    bottom: 0;
    left: 0;
    padding: 20px;
    width: 100%;
    z-index: 3;
    text-align: left;
    background-color: rgba(0, 0, 0, 0.5);
    color: #ffffff;
}

.rm-portfolio-title {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 10px;
    color: #ffffff;
} 

.rm-portfolio-title a {
    color: #ffffff;
    text-decoration: none;
    transition: color 0.3s ease;
}

.rm-portfolio-title a:hover {
    color: #ecc900;
}

.rm-portfolio-categories {
    margin-top: 5px;
    font-size: 14px;
    color: #ecc900;
}

.rm-portfolio-categories a {
    color: #ecc900;
    text-decoration: none;
}

.rm-portfolio-categories a:hover {
    text-decoration: underline;
}

/* Responsive */
@media (max-width: 991px) {
    .rm-portfolio-grid,
    .rm-portfolio-grid.columns-2,
    .rm-portfolio-grid.columns-3,
    .rm-portfolio-grid.columns-4 {
        grid-template-columns: repeat(2, 1fr) !important;
    }
}

@media (max-width: 767px) {
    .rm-portfolio-item {
        width: 100%;
        margin: 0 0 30px;
    }
    
    .rm-video-modal-content {
        width: 95%;
        padding-bottom: 56.25%;
    }
    
    .rm-video-modal-close {
        top: -30px;
        right: 0;
    }
}

/* Styles additionnels pour le portfolio */
.rm-portfolio-grid {
    display: block;
    width: 100%;
    margin: 0 auto;
    overflow: hidden;
}

.rm-portfolio-item {
    width: calc(50% - 15px);
    margin: 0 7.5px 30px;
    position: relative;
    float: left;
    box-sizing: border-box;
}

.rm-portfolio-thumbnail {
    position: relative;
    overflow: hidden;
    border-radius: 4px;
    aspect-ratio: 16/9;
}

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

.rm-portfolio-item:hover .rm-portfolio-thumbnail img {
    transform: scale(1.05);
}

.rm-portfolio-content {
    position: absolute;
    bottom: 0;
    left: 0;
    padding: 20px;
    width: 100%;
    z-index: 3;
    text-align: left;
    background: linear-gradient(to top, rgba(0,0,0,0.7) 0%, rgba(0,0,0,0) 100%);
}

.rm-portfolio-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    background-color: #ecc900;
    color: #000000;
    padding: 5px 10px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    border-radius: 3px;
    z-index: 5;
}

.rm-portfolio-title {
    color: #ffffff;
    margin: 0 0 5px 0;
    font-size: 18px;
    font-weight: 700;
    text-shadow: 1px 1px 3px rgba(0,0,0,0.5);
}

.rm-portfolio-category {
    color: #ecc900;
    margin: 0;
    font-size: 14px;
    font-weight: 500;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.5);
}

.rm-portfolio-filters {
    margin-bottom: 30px;
    text-align: center;
}

.rm-filter {
    display: inline-block;
    padding: 8px 15px;
    margin: 0 5px 10px;
    background-color: #f5f5f5;
    color: #333;
    border-radius: 3px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.rm-filter:hover,
.rm-filter.active {
    background-color: #ecc900;
    color: #000;
}

/* Styles pour le bouton de lecture */
.rm-portfolio-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 50px;
    height: 50px;
    background-color: #ecc900;
    border-radius: 50%;
    color: #000;
    font-size: 20px;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    opacity: 0.9;
    transition: all 0.3s ease;
    z-index: 4;
}

.rm-portfolio-link:hover {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1.1);
}

/* Modal vidéo */
.rm-video-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999;
    display: none;
    align-items: center;
    justify-content: center;
}

.rm-video-modal.active {
    display: flex;
}

.rm-video-modal-backdrop {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.rm-video-modal-content {
    position: relative;
    width: 80%;
    max-width: 1200px;
    height: 0;
    padding-bottom: 45%;
    background-color: #000;
    z-index: 10;
    border-radius: 4px;
    box-shadow: 0 0 30px rgba(0, 0, 0, 0.5);
    overflow: hidden;
}

.rm-video-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.rm-video-modal-close {
    position: absolute;
    top: -40px;
    right: -40px;
    width: 40px;
    height: 40px;
    background-color: transparent;
    border: none;
    color: #fff;
    font-size: 30px;
    cursor: pointer;
    z-index: 11;
    transition: all 0.3s ease;
}

.rm-video-modal-close:hover {
    transform: scale(1.2);
    color: #ecc900;
}

body.rm-modal-open {
    overflow: hidden;
}

/* Fix pour Isotope */
.isotope-item {
    z-index: 2;
}

.isotope-hidden.isotope-item {
    pointer-events: none;
    z-index: 1;
}

/* Responsive */
@media (max-width: 767px) {
    .rm-portfolio-item {
        width: 100%;
        margin: 0 0 30px;
    }
    
    .rm-video-modal-content {
        width: 95%;
        padding-bottom: 56.25%;
    }
    
    .rm-video-modal-close {
        top: -30px;
        right: 0;
    }
}
