/* Raise specificity using 'body' to forcefully override Betheme skin variables */
body .selected-works-section {
    background: #255259 !important;
    color: #ffffff !important;
    padding: 180px 13% 180px 10% !important;
    box-sizing: border-box !important;
    display: block !important;
}

.works-label {
    display: block !important;
    color: #9CA485 !important;
    font-size: 14px !important;
    letter-spacing: 4px !important;
    margin-bottom: 25px !important;
}

.works-header h2 {
    font-family: 'Syne', sans-serif !important;
    text-transform: uppercase !important;
    color: #ffffff !important;
    font-size: clamp(4rem, 10vw, 8rem) !important;
    line-height: .85 !important;
    margin-bottom: 100px !important;
}

.works-list {
    border-top: 1px solid rgba(255,255,255,.15) !important;
    display: block !important; 
}

/* Force flex row layout directly against Betheme's container block formatting */
body .selected-works-section .work-item {
    position: relative !important;
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 40px !important;
    padding: 45px 0 !important;
    border-bottom: 1px solid rgba(255,255,255,.15) !important;
    text-decoration: none !important;
    color: #ffffff !important;
    transition: .4s ease-in-out !important;
}

.work-number {
    width: 70px !important;
    color: #9CA485 !important;
    font-size: 18px !important;
    flex-shrink: 0 !important;
}

.work-content {
    flex: 1 !important;
    min-width: 0 !important;
    text-align: left !important;
}

.work-content h3 {
    font-size: clamp(2rem, 3vw, 3.5rem) !important;
    margin: 0 !important;
    line-height: 1 !important;
    white-space: nowrap !important;
    color: #ffffff !important;
    text-transform: uppercase !important;
}

body .selected-works-section .work-content p.work-category {
    margin-top: 10px !important;
    color: rgba(255,255,255,.7) !important;
    font-size: 18px !important;
    display: block !important;
    opacity: 1 !important;
    visibility: visible !important;
}

/* FIX: Set opacity to 0 and explicitly hide via visibility so Betheme cannot show it early */
body .selected-works-section .work-preview {
    width: 280px !important;
    height: 180px !important;
    flex-shrink: 0 !important;
    overflow: hidden !important;
    border-radius: 20px !important;
    opacity: 0 !important;
    visibility: hidden !important;
    transform: translateX(50px) !important;
    transition: opacity .4s ease, transform .4s ease, visibility .4s ease !important;
}

body .selected-works-section .work-preview img {
    width: 100% !important;
    height: 100% !important;  
    object-fit: cover !important;
    border-radius: 20px !important;
    transition: .8s ease !important;
}

/* Hover States */
body .selected-works-section .work-item:hover {
    padding-left: 20px !important;
}

body .selected-works-section .work-item:hover h3 {
    color: #9CA485 !important;
}

/* FIX: Pull opacity to 1 and instantly reverse visibility rules when hovered */
body .selected-works-section .work-item:hover .work-preview {
    opacity: 1 !important;
    visibility: visible !important;
    transform: translateX(0) !important;
}

body .selected-works-section .work-item:hover img {
    transform: scale(1.05) !important;
}

/* Responsive Mobile Rules */
@media (max-width: 991px) {
    body .selected-works-section {
        padding: 100px 25px !important;
    }
    .works-header h2 {
        font-size: clamp(3rem, 14vw, 5rem) !important;
        margin-bottom: 60px !important;
    }
    body .selected-works-section .work-item {
        display: block !important;
        padding: 35px 0 !important;
    }
    .work-number {
        display: block !important;
        margin-bottom: 15px !important;
    }
    .work-content h3 {
        font-size: clamp(2rem, 8vw, 3rem) !important;
        white-space: normal !important;
    }
    body .selected-works-section .work-preview {
        width: 100% !important;
        height: 220px !important;
        margin-top: 25px !important;
        opacity: 1 !important;
        visibility: visible !important;
        transform: none !important;
    }
}

/* Footer Linking Elements */
.works-more {
    padding-top: 60px !important;
    text-align: right !important;
}

.works-more-link {
    display: inline-flex !important;
    align-items: center !important;
    gap: 15px !important;
    color: #9CA485 !important;
    text-decoration: none !important;
    font-size: 1.2rem !important;
    font-weight: 700 !important;
    letter-spacing: 2px !important;
    transition: .4s ease !important;
}

.works-more-link:hover {
    color: #ffffff !important;
}

.arrow {
    width: 18px !important;
    height: 18px !important;
    border-top: 2px solid #9CA485 !important;
    border-right: 2px solid #9CA485 !important;
    transform: rotate(45deg) !important;
    display: inline-block !important;
    transition: .4s ease !important;
}

.works-more-link:hover .arrow {
    transform: rotate(45deg) translate(5px,-5px) !important;
}