﻿.news-custom {
    width: 100%;
    background: linear-gradient(to bottom, #d8002e, #b8002a);
    height: 80vh;
    min-height: 400px;
    max-height: 800px;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 130px;
}

/* News Slider Container */
.faculty-news-slider-container {
    padding: 0;
    height: 90vh;
    min-height: 350px;
    max-height: 800px;
    width: min(90%, 2000px);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    overflow: hidden;
    position: absolute;
    top: 45px;
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    background: #d8002e;
}

.faculty-news-swiper {
    height: 100%;
}

.faculty-news-swiper .swiper-slide {
    position: relative;
    border-radius: 10px;
    overflow: hidden;
}

.faculty-news-slide-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* News Title Overlay - Centered with arrows on sides */
.faculty-news-title-overlay {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    bottom: 0px;
    width: clamp(300px, 60%, 800px);
    background: #FFFFFF;
    padding: clamp(15px, 2vw, 25px) clamp(20px, 3vw, 40px);
    border-radius: 8px 8px 0px 0px;
    text-align: center;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    z-index: 10;
    text-decoration: none;
    min-height: 150px;
    display: flex;
    align-items: center;
    -webkit-justify-content: center;
    justify-content: center;
}

    .faculty-news-title-overlay h3 {
        color: #000000;
        font-size: clamp(18px, 2.5vw, 26px);
        font-weight: 600;
        margin: 0 0 clamp(5px, 1vw, 10px) 0;
        transition: all 0.3s ease;
        line-height: 1.3;
    }

    .faculty-news-title-overlay h5 {
        color: #c80000;
        font-size: clamp(13px, 1.5vw, 16px);
        font-weight: 500;
        text-transform: uppercase;
        margin: 0;
    }

    .faculty-news-title-overlay:hover h3 {
        text-decoration: underline;
        text-underline-offset: 6px;
        text-decoration-thickness: 2px;
    }

/* Custom Navigation Arrows - Positioned on sides of title */
.faculty-news-button-prev,
.faculty-news-button-next {
    position: absolute;
    top: 86%;
    width: clamp(40px, 5vw, 50px);
    height: clamp(40px, 5vw, 50px);
    background-color: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 100;
    transition: all 0.3s ease;
    color: rgba(255, 255, 255, 0.5);
}

.faculty-news-button-prev {
    left: 13%;
}

.faculty-news-button-next {
    right: 13%;
}

    .faculty-news-button-prev:hover,
    .faculty-news-button-next:hover {
        background-color: rgba(255, 255, 255, 0.25);
        transform: scale(1.1);
        border-color: rgba(255, 255, 255, 0.4);
    }

    .faculty-news-button-prev span,
    .faculty-news-button-next span {
        width: clamp(8px, 1.5vw, 10px);
        height: clamp(8px, 1.5vw, 10px);
        display: flex;
        align-items: center;
        justify-content: center;
        background-color: transparent;
        position: relative;
        border: solid 2px white;
        border-left: 0;
        border-bottom: 0;
        transition: all 0.3s ease;
    }

.faculty-news-button-prev span {
    transform: rotate(-135deg);
}

.faculty-news-button-next span {
    transform: rotate(45deg);
}

    .faculty-news-button-prev span:after,
    .faculty-news-button-next span:after {
        content: '';
        position: absolute;
        background-color: white;
        width: 0px;
        height: 2px;
        transition: all 0.3s ease;
        transform: rotate(-45deg);
    }

.faculty-news-button-prev:hover span:after,
.faculty-news-button-next:hover span:after {
    width: calc(clamp(16px, 3vw, 20px) - 4px);
}

.faculty-news-button-prev.swiper-button-disabled,
.faculty-news-button-next.swiper-button-disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Remove default Swiper arrow content */
.faculty-news-button-prev::after,
.faculty-news-button-next::after {
    content: '';
    display: none;
}

/* Responsive Styles - Keep laptop/desktop as-is, optimize others */

/* Ultra-wide Screens - 2560px+ */
@media screen and (min-width: 2560px) {
    .faculty-news-slider-container {
        width: 75%;
        max-width: 2200px;
    }

    .faculty-news-title-overlay {
        width: clamp(400px, 50%, 900px);
    }

    .faculty-news-button-prev {
        left: 20%;
    }

    .faculty-news-button-next {
        right: 20%;
    }
}

/* Extra Large Desktop - 1920px to 2559px */
@media screen and (min-width: 1920px) and (max-width: 2559px) {
    .faculty-news-slider-container {
        width: 90%;
    }

    .faculty-news-title-overlay {
        width: clamp(350px, 55%, 850px);
    }

    .faculty-news-button-prev {
        left: 21%;
    }

    .faculty-news-button-next {
        right: 21%;
    }
}

/* Large Desktop - 1441px to 1919px */
@media screen and (min-width: 1441px) and (max-width: 1919px) {
    .news-custom {
        height: 85vh;
        max-height: 900px;
    }

    .faculty-news-slider-container {
        height: 85vh;
        max-height: 850px;
    }
}

/* Standard Laptop/Desktop - 1025px to 1440px - KEEP AS-IS */
@media screen and (min-width: 1025px) and (max-width: 1440px) {
    /* Your current design - no changes */
}

/* Tablet Landscape - 769px to 1024px */
/* iPad Air (4th & 5th Gen) - 820px x 1180px */
@media screen and (min-width: 820px) and (max-width: 1180px) {
    .news-custom {
        height: 63vh;
        min-height: 400px;
        margin-bottom: 110px;
    }

    .faculty-news-slider-container {
        height: 75vh;
        width: 98%;
        min-height: 350px;
    }

    .faculty-news-swiper {
        height: 100%;
    }

    .faculty-news-title-overlay {
        width: clamp(280px, 70%, 700px);
        bottom: 0px;
        min-height: 120px;
    }

    .faculty-news-button-prev,
    .faculty-news-button-next {
        width: 45px;
        height: 45px;
        top: 89%;
    }

    .faculty-news-button-prev {
        left: 7%;
    }

    .faculty-news-button-next {
        right: 7%;
    }
}

/* iPad Pro 11" - 834px x 1194px */
@media screen and (min-width: 834px) and (max-width: 1194px) {
    .news-custom {
        height: 65vh;
        min-height: 420px;
        margin-bottom: 130px;
    }

    .faculty-news-slider-container {
        height: 77vh;
        width: 96%;
        min-height: 370px;
    }

    .faculty-news-swiper {
        height: 100%;
    }

    .faculty-news-title-overlay {
        width: clamp(300px, 68%, 720px);
        bottom: 0px;
        min-height: 125px;
    }

    .faculty-news-button-prev,
    .faculty-news-button-next {
        width: 46px;
        height: 46px;
        top: 89%;
    }

    .faculty-news-button-prev {
        left: 8%;
    }

    .faculty-news-button-next {
        right: 8%;
    }
}

@media screen and (min-width: 1024px) and (max-width: 1366px) and (-webkit-min-device-pixel-ratio: 1.5) {
    .news-custom {
        height: 52vh;
        min-height: 450px;
        margin-bottom: 130px;
    }

    .faculty-news-slider-container {
        height: 80vh;
        width: 94%;
        min-height: 390px;
    }

    .faculty-news-swiper {
        height: 100%;
    }

    .faculty-news-title-overlay {
        width: clamp(320px, 65%, 750px);
        bottom: 0px;
        min-height: 130px;
    }

    .faculty-news-button-prev,
    .faculty-news-button-next {
        width: 48px;
        height: 48px;
        top: 88%;
    }

    .faculty-news-button-prev {
        left: 10%;
    }

    .faculty-news-button-next {
        right: 10%;
    }
}

@media screen and (min-width: 481px) and (max-width: 768px) {
    .news-custom {
        height: 60vh;
        min-height: 350px;
        margin-bottom: 120px;
    }

    .faculty-news-slider-container {
        height: 65vh;
        width: 98%;
        min-height: 320px;
        border-radius: 6px;
        top: 30px;
    }

    .faculty-news-swiper {
        height: 100%;
    }

    .faculty-news-title-overlay {
        width: clamp(260px, 75%, 600px);
        bottom: clamp(0px, 10vh, 0px);
        min-height: 100px;
        padding: clamp(12px, 2.5vw, 20px) clamp(15px, 3vw, 30px);
    }

        .faculty-news-title-overlay h3 {
            font-size: clamp(16px, 3vw, 22px);
        }

        .faculty-news-title-overlay h5 {
            font-size: clamp(12px, 2vw, 15px);
        }

    .faculty-news-button-prev,
    .faculty-news-button-next {
        width: 42px;
        height: 42px;
        top: 90%;
    }

    .faculty-news-button-prev {
        left: 4%;
    }

    .faculty-news-button-next {
        right: 4%;
    }

        .faculty-news-button-prev span,
        .faculty-news-button-next span {
            width: 8px;
            height: 8px;
        }
}

@media screen and (min-width: 376px) and (max-width: 480px) {
    .news-custom {
        height: 50vh;
        min-height: 300px;
        margin-bottom: 80px;
    }

    .faculty-news-slider-container {
        height: 52vh;
        width: 100%;
        min-height: 270px;
        top: 15px;
        border-radius: 0px;
    }

    .faculty-news-swiper{
        height: 100%;
    }

    .faculty-news-swiper .swiper-slide{
        border-radius: 0px;
    }

    .faculty-news-title-overlay {
        width: 95%;
        bottom: clamp(0px, 8vh, 0px);
        min-height: 85px;
        padding: 12px 15px;
    }

        .faculty-news-title-overlay h3 {
            font-size: 16px;
            margin-bottom: 5px;
        }

        .faculty-news-title-overlay h5 {
            font-size: 12px;
        }

    .faculty-news-button-prev,
    .faculty-news-button-next {
        width: 36px;
        height: 36px;
        top: 50%;
    }

    .faculty-news-button-prev {
        left: 2%;
    }

    .faculty-news-button-next {
        right: 2%;
    }

        .faculty-news-button-prev span,
        .faculty-news-button-next span {
            width: 7px;
            height: 7px;
            border-width: 1.5px;
        }
}

@media screen and (min-width: 321px) and (max-width: 375px) {
    .news-custom {
        height: 48vh;
        min-height: 280px;
        margin-bottom: 70px;
    }

    .faculty-news-slider-container {
        height: 52vh;
        width: 100%;
        min-height: 250px;
        top: 12px;
        border-radius: 0;
    }

    .faculty-news-swiper {
        height: 100%;
    }

        .faculty-news-swiper .swiper-slide {
            border-radius: 0px;
        }

    .faculty-news-title-overlay {
        width: 95%;
        bottom: 0px;
        min-height: 75px;
        padding: 10px 12px;
    }

        .faculty-news-title-overlay h3 {
            font-size: 15px;
            line-height: 1.2;
        }

        .faculty-news-title-overlay h5 {
            font-size: 11px;
        }

    .faculty-news-button-prev,
    .faculty-news-button-next {
        width: 33px;
        height: 33px;
        top: 50%;
    }

    .faculty-news-button-prev {
        left: 2%;
    }

    .faculty-news-button-next {
        right: 2%;
    }

        .faculty-news-button-prev span,
        .faculty-news-button-next span {
            width: 6px;
            height: 6px;
            border-width: 1.5px;
        }
}

/* Mobile Tiny - 280px to 320px */
@media screen and (max-width: 320px) {
    .news-custom {
        height: 45vh;
        min-height: 260px;
        margin-bottom: 60px;
    }

    .faculty-news-slider-container {
        height: 50vh;
        min-height: 230px;
        top: 10px;
    }

    .faculty-news-swiper {
        height: 100%;
    }

        .faculty-news-swiper .swiper-slide {
            border-radius: 0px;
        }

    .faculty-news-title-overlay {
        width: 95%;
        bottom: 0px;
        min-height: 70px;
        padding: 8px 10px;
    }

        .faculty-news-title-overlay h3 {
            font-size: 14px;
            line-height: 1.1;
            margin-bottom: 4px;
        }

        .faculty-news-title-overlay h5 {
            font-size: 10px;
        }

    .faculty-news-button-prev,
    .faculty-news-button-next {
        width: 30px;
        height: 30px;
        top: 50%;
    }

    .faculty-news-button-prev {
        left: 2%;
    }

    .faculty-news-button-next {
        right: 2%;
    }

        .faculty-news-button-prev span,
        .faculty-news-button-next span {
            width: 6px;
            height: 6px;
            border-width: 1.5px;
        }
}

/* Landscape Mobile Devices */
@media screen and (max-height: 500px) and (orientation: landscape) {
    .news-custom {
        height: 88vh;
        min-height: 280px;
        margin-bottom: 60px;
    }

    .faculty-news-slider-container {
        height: 88vh;
        min-height: 260px;
        top: 10px;
    }
    .faculty-news-swiper {
        height: 100%;
    }

        .faculty-news-swiper .swiper-slide {
            border-radius: 0px;
        }

    .faculty-news-title-overlay {
        bottom: 0px;
        min-height: 65px;
        padding: 8px 12px;
    }

        .faculty-news-title-overlay h3 {
            font-size: 15px;
        }

        .faculty-news-title-overlay h5 {
            font-size: 11px;
        }

    .faculty-news-button-prev,
    .faculty-news-button-next {
        top: 72%;
        width: 34px;
        height: 34px;
    }
}

/* Extra small devices - 280px */
@media screen and (max-width: 280px) {
    .faculty-news-swiper {
        height: 100%;
    }

        .faculty-news-swiper .swiper-slide {
            border-radius: 0px;
        }

    .faculty-news-button-prev {
        left: 3%;
    }

    .faculty-news-button-next {
        right: 3%;
    }

    .faculty-news-button-prev,
    .faculty-news-button-next {
        width: 28px;
        height: 28px;
    }

    .faculty-news-title-overlay {
        width: 92%;
    }
}
