/* Bootstrap 5 + Swiper compatibility with legacy theme */

body { padding-top: 70px; }

.img-circle { border-radius: 50%; }

.thumbnail button.more {
    display: block;
    z-index: 4;
    position: absolute;
    top: -100px;
    left: 50%;
    margin-left: -41px;
    width: 80px;
    height: 80px;
    font-size: 40px;
    color: #fff;
    line-height: 70px;
    text-align: center;
    background: transparent;
    border: none;
    cursor: pointer;
}

.thumbnail:hover button.more {
    top: 40%;
    margin-top: -40px;
    transition: all 0.3s ease-out;
}

.site-navbar .btn-navbar {
    border: none;
    background: #F79420;
    color: #181A1C;
    padding: 8px 12px;
    border-radius: 0;
}

.site-navbar .btn-navbar .icon-menu:before { color: #181A1C; }

.site-navbar.navbar {
    background: #181A1C !important;
    min-height: 70px;
    margin-bottom: 0;
    border: none;
    box-shadow: none;
    border-radius: 0;
}

.site-navbar .navbar-brand img { width: 120px; height: 40px; }

.site-navbar .nav-link {
    text-transform: uppercase;
    font-size: 15px;
    color: #fff !important;
    border: 1px solid #181A1C;
    margin: 10px 3px;
    padding: 8px 12px !important;
    transition: border-color 1s ease;
}

.site-navbar .nav-link:hover,
.site-navbar .nav-link.active {
    border: 1px solid #F79420 !important;
    color: #fff !important;
    background: #181A1C !important;
}

#menu_lang {
    float: none;
    list-style: none;
    margin: 0;
    padding-top: 15px;
    display: inline-flex;
    align-items: center;
}

#menu_lang li { opacity: 0.85; }
#menu_lang li:hover { opacity: 1; }

#home { padding: 0; }

/* Swiper as legacy da-slider */
.hero-swiper.da-slider {
    width: 100%;
    min-width: 320px;
    height: 520px;
    position: relative;
    margin: 0 auto;
    overflow: hidden;
    background: transparent url(/assets/images/Slider.png) repeat-x 0% center;
    background-size: auto 100%;
}

.hero-swiper .mask {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #F79420;
    opacity: 0.85;
    z-index: 1;
    pointer-events: none;
}

.hero-swiper .triangle {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    z-index: 3;
    margin: 0;
    width: 0;
    height: 0;
    border: none;
    border-top: 40px solid #181A1C;
    border-left: 18px solid transparent;
    border-right: 18px solid transparent;
}

.hero-swiper .swiper-wrapper { position: relative; z-index: 2; height: 100%; }

.hero-swiper .swiper-slide {
    height: 520px;
    position: relative;
}

.hero-swiper .da-slide-inner {
    position: relative;
    height: 100%;
    max-width: 1170px;
    margin: 0 auto;
    padding: 0 15px;
}

.hero-swiper .swiper-slide h2 {
    position: absolute;
    top: 120px;
    left: 10%;
    width: 50%;
    font-size: 33px;
    font-weight: bold;
    color: #181A1C;
    text-transform: uppercase;
    margin: 0;
}

.hero-swiper .swiper-slide h4 {
    position: absolute;
    top: 175px;
    left: 10%;
    width: 50%;
    font-size: 22px;
    font-weight: normal;
    color: #181A1C;
    text-transform: uppercase;
    margin: 0;
}

.hero-swiper .swiper-slide p {
    position: absolute;
    top: 230px;
    left: 10%;
    width: 45%;
    padding: 0;
    color: #fff;
    height: auto;
    max-height: 120px;
    overflow: hidden;
    font-weight: 400;
}

.hero-swiper .swiper-slide .da-link {
    position: absolute;
    top: 340px;
    left: 10%;
}

.hero-swiper .swiper-slide .da-img {
    position: absolute;
    top: 80px;
    left: 60%;
    width: 40%;
    text-align: center;
}

.hero-swiper .swiper-slide .da-img img { max-width: 320px; width: 100%; height: auto; }

.hero-swiper .swiper-button-prev,
.hero-swiper .swiper-button-next {
    width: 45px;
    height: 100%;
    top: 0;
    margin: 0;
    z-index: 10;
    background: transparent no-repeat center center;
    color: transparent;
}

.hero-swiper .swiper-button-prev::after,
.hero-swiper .swiper-button-next::after { display: none; }

.hero-swiper .swiper-button-prev { left: 15px; background-image: url(/assets/images/Left.png); }
.hero-swiper .swiper-button-next { right: 15px; background-image: url(/assets/images/Right.png); }

.hero-swiper .swiper-pagination {
    bottom: 20px;
    z-index: 10;
}

.hero-swiper .swiper-pagination-bullet {
    width: 50px;
    height: 3px;
    border-radius: 0;
    background: #fff;
    opacity: 1;
    margin: 0 5px 0 0 !important;
}

.hero-swiper .swiper-pagination-bullet-active { background: #29383F; }

/* Portfolio filters as nav-pills */
#portfolio-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px 20px;
    list-style: none;
    padding: 0;
    margin: 0 0 20px;
}

#portfolio-grid > .portfolio-item {
    float: none;
    width: auto;
    margin: 0;
    padding: 0;
}

#portfolio-grid .thumbnail {
    margin-bottom: 0;
}

@media (max-width: 991px) {
    #portfolio-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 575px) {
    #portfolio-grid { grid-template-columns: 1fr; }
}

.portfolio-filters.nav-pills { justify-content: center; flex-wrap: wrap; margin-bottom: 2rem; }
.portfolio-filters .filter-btn {
    background: transparent;
    border: 1px solid #181A1C;
    border-radius: 0;
    color: inherit;
    margin: 0 5px 5px 0;
    padding: 8px 25px;
    cursor: pointer;
}
.secondary-section .portfolio-filters .filter-btn,
.secondary-section .portfolio-filters .nav-link.filter-btn {
    border-color: #181A1C;
    color: #181A1C;
    background: transparent;
    border-radius: 0;
}
.secondary-section .portfolio-filters .filter-btn.active,
.secondary-section .portfolio-filters .filter-btn:hover,
.secondary-section .portfolio-filters .nav-link.filter-btn.active,
.secondary-section .portfolio-filters .nav-link.filter-btn:hover {
    background: #181A1C;
    color: #fff;
}

/* Portfolio detail panel */
.single-project {
    margin-bottom: 30px;
    background: #181A1C;
    padding: 15px;
    display: none;
}
.single-project.open { display: block; }
.single-project .project-title {
    margin-top: 15px;
    margin-bottom: 15px;
    border-bottom: 1px solid #F79420;
    overflow: hidden;
}
.single-project .project-title h3 { float: left; color: #F79420; margin: 0; }
.single-project .close-detail {
    float: right;
    width: 40px;
    height: 40px;
    border: none;
    background: transparent;
    color: #F79420;
    font-size: 28px;
    cursor: pointer;
}
.single-project .project-info span { color: #F79420; width: 80px; display: inline-block; }

/* Skills legacy bars */
.skill-bar { margin-bottom: 30px; position: relative; background: #fff; height: 40px; padding: 1px; }
.skill-bar h3 {
    position: relative;
    font-size: 15px;
    padding: 0 0 0 10px;
    margin: 0;
    line-height: 40px;
    z-index: 2;
    color: #181A1C;
}
.skill-bar .bar-fill {
    height: 40px;
    position: absolute;
    top: 1px;
    left: 1px;
    background-color: #F79420;
    width: 0;
    z-index: 1;
    transition: width 1s ease;
}

/* Map background */
.map-canvas {
    background: #181A1C url(/assets/images/mappa_bg.jpg) no-repeat center center;
    background-size: cover;
}

.map-wrapper { position: relative; height: 500px; }
.map-wrapper .container { position: relative; z-index: 2; }

.contact-form.centered { float: none; margin: 0 auto; }

.scroll-top.scrollup {
    display: none;
    text-align: center;
    width: 39px;
    height: 39px;
    border-radius: 5px;
    position: fixed;
    bottom: 30px;
    right: 20px;
    border: 1px solid #fff;
    background: #F79420;
    color: #fff;
    line-height: 37px;
    z-index: 1000;
    text-decoration: none;
}
.scroll-top.scrollup.visible { display: block; }

.section .title h1,
.section .title h2 { font-weight: normal; }

@media (max-width: 991px) {
    .hero-swiper .swiper-slide h2,
    .hero-swiper .swiper-slide h4,
    .hero-swiper .swiper-slide p,
    .hero-swiper .swiper-slide .da-link,
    .hero-swiper .swiper-slide .da-img {
        position: static;
        width: auto;
        left: auto;
        top: auto;
        text-align: center;
        margin: 0 auto 12px;
    }
    .hero-swiper .da-slide-inner {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        height: 100%;
        padding-top: 40px;
    }
    .hero-swiper.da-slider { height: auto; min-height: 520px; }
    .hero-swiper .swiper-slide { height: auto; min-height: 520px; padding: 20px 0; }
}

@media (max-width: 767px) {
    .triangle {
        border-left-width: 50vw !important;
        border-right-width: 50vw !important;
    }
}
