/********** Template CSS **********/
html {
    scroll-behavior: smooth;
}

/* Performance optimizations */
* {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

img {
    image-rendering: -webkit-optimize-contrast;
}

/* Optimize scrolling performance */
html {
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
}

/* Reduce repaints on scroll */
.nav-bar.sticky-top {
    transform: translateZ(0);
}

/* Offset for anchor links to account for sticky navbar */
section[id],
div[id] {
    scroll-margin-top: 100px;
}

:root {
    --primary: #95713F;
    --primary-dark: #7a5d33;
    --primary-light: #b08a5f;
    --secondary: #020202;
    --light: #DAD5D1;
    --dark: #020202;
}

body {
    background-color: #020202;
    color: #95713F;
}

/* Ensure text is visible on dark background */
h1, h2, h3, h4, h5, h6 {
    color: #95713F;
}

p, span, li, td, th {
    color: #95713F;
}

/* Light backgrounds should have dark text */
.bg-light, .bg-white {
    background-color: #f8f9fa !important;
}

.bg-light h1, .bg-light h2, .bg-light h3, .bg-light h4, .bg-light h5, .bg-light h6,
.bg-white h1, .bg-white h2, .bg-white h3, .bg-white h4, .bg-white h5, .bg-white h6 {
    color: #020202 !important;
}

.bg-light p, .bg-light span, .bg-light li,
.bg-white p, .bg-white span, .bg-white li {
    color: #020202 !important;
}

.text-dark {
    color: #020202 !important;
}

.text-muted {
    color: #6c757d !important;
}

/* Dark backgrounds should have light text */
.bg-dark, .bg-primary, .footer-dark {
    color: #ffffff !important;
}

.bg-dark h1, .bg-dark h2, .bg-dark h3, .bg-dark h4, .bg-dark h5, .bg-dark h6,
.bg-primary h1, .bg-primary h2, .bg-primary h3, .bg-primary h4, .bg-primary h5, .bg-primary h6,
.footer-dark h1, .footer-dark h2, .footer-dark h3, .footer-dark h4, .footer-dark h5, .footer-dark h6 {
    color: #ffffff !important;
}

.bg-dark p, .bg-dark span, .bg-dark li,
.bg-primary p, .bg-primary span, .bg-primary li,
.footer-dark p, .footer-dark span, .footer-dark li {
    color: #ffffff !important;
}

.fw-medium {
    font-weight: 600 !important;
}

.back-to-top {
    position: fixed;
    display: none;
    right: 45px;
    bottom: 45px;
    z-index: 99;
}


/*** Spinner ***/
#spinner {
    opacity: 0;
    visibility: hidden;
    transition: opacity .5s ease-out, visibility 0s linear .5s;
    z-index: 99999;
}

#spinner.show {
    transition: opacity .5s ease-out, visibility 0s linear 0s;
    visibility: visible;
    opacity: 1;
}


/*** Button ***/
.btn {
    font-weight: 600;
    transition: all 0.2s ease;
}

.btn.btn-primary,
.btn.btn-secondary {
    color: #FFFFFF;
}

.btn-square {
    width: 38px;
    height: 38px;
}

.btn-sm-square {
    width: 32px;
    height: 32px;
}

.btn-lg-square {
    width: 48px;
    height: 48px;
}

.btn-square,
.btn-sm-square,
.btn-lg-square {
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: normal;
}


/*** Navbar ***/
.top-bar {
    height: 75px;
    padding: 0 4rem;
}

.nav-bar {
    position: relative;
    padding: 0 4.75rem;
    transition: padding 0.2s ease;
    z-index: 9999;
}

.nav-bar.sticky-top {
    position: sticky;
    padding: 0;
    z-index: 9999;
}

.navbar .dropdown-toggle::after {
    border: none;
    content: "\f107";
    font-family: "Font Awesome 5 Free";
    font-weight: 900;
    vertical-align: middle;
    margin-left: 8px;
}

.navbar-light .navbar-nav {
    display: flex;
    justify-content: center;
    align-items: center;
}

.navbar-light .navbar-nav .nav-link {
    margin-right: 30px;
    padding: 25px 0;
    color: var(--dark);
    font-size: 15px;
    font-weight: 600;
    text-transform: uppercase;
    outline: none;
}

.navbar-light .navbar-nav .nav-link:hover,
.navbar-light .navbar-nav .nav-link.active {
    color: var(--primary);
}

@media (max-width: 991.98px) {
    .nav-bar {
        padding: 0;
    }

    .navbar-light .navbar-nav .nav-link  {
        margin-right: 0;
        padding: 10px 0;
    }

    .navbar-light .navbar-nav {
        margin-top: 1rem;
        padding-top: 1rem;
        border-top: 1px solid #EEEEEE;
    }
}

@media (min-width: 992px) {
    .navbar .nav-item .dropdown-menu {
        display: block;
        border: none;
        margin-top: 0;
        top: 150%;
        opacity: 0;
        visibility: hidden;
        transition: .5s;
    }

    .navbar .nav-item:hover .dropdown-menu {
        top: 100%;
        visibility: visible;
        transition: .5s;
        opacity: 1;
    }
}


/*** Header ***/
.header-carousel {
    height: 100vh;
    overflow: hidden;
}

.header-carousel .owl-carousel-item {
    height: 100vh;
}

.header-carousel .owl-carousel-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 1;
}

.header-carousel .owl-carousel-item > div {
    z-index: 2;
}

.header-carousel .container,
.page-header .container {
    position: relative;
    padding: 45px 0 45px 35px;
    border-left: 15px solid #FFFFFF;
}

.header-carousel .container::before,
.header-carousel .container::after,
.page-header .container::before,
.page-header .container::after {
    position: absolute;
    content: "";
    top: 0;
    left: 0;
    width: 100px;
    height: 15px;
    background: #FFFFFF;
}

.header-carousel .container::after,
.page-header .container::after {
    top: 100%;
    margin-top: -15px;
}

@media (max-width: 768px) {
    .header-carousel {
        height: 100vh;
    }
    
    .header-carousel .owl-carousel-item {
        position: relative;
        height: 100vh;
    }
    
    .header-carousel .owl-carousel-item img {
        position: absolute;
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

    .header-carousel .owl-carousel-item h5,
    .header-carousel .owl-carousel-item p {
        font-size: 14px !important;
        font-weight: 400 !important;
    }

    .header-carousel .owl-carousel-item h1 {
        font-size: 30px;
        font-weight: 600;
    }
}

.header-carousel .owl-nav {
    position: absolute;
    top: 50%;
    right: 8%;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
}

.header-carousel .owl-nav .owl-prev,
.header-carousel .owl-nav .owl-next {
    margin: 7px 0;
    width: 45px;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #FFFFFF;
    background: transparent;
    border: 1px solid #FFFFFF;
    border-radius: 45px;
    font-size: 22px;
    transition: .5s;
}

.header-carousel .owl-nav .owl-prev:hover,
.header-carousel .owl-nav .owl-next:hover {
    background: var(--primary);
    border-color: var(--primary);
    transition: background 0.2s ease, border-color 0.2s ease;
}

.page-header {
    background: linear-gradient(rgba(0, 0, 0, .4), rgba(0, 0, 0, .4)), url(../img/bg.jpg) center center no-repeat;
    background-size: cover;
}

.breadcrumb-item + .breadcrumb-item::before {
    color: var(--light);
}


/*** Facts ***/
.fact {
    background: linear-gradient(rgba(0, 0, 0, .4), rgba(0, 0, 0, .4)), url(../img/drvo.jpg) center center no-repeat;
    background-size: cover;
}


/*** Service ***/
.service-item-top {
    border-radius: 8px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    height: 100%;
}

/* Ensure columns have equal heights */
#usluge .row > [class*="col-"] {
    display: flex;
}

#usluge .row > [class*="col-"] > .service-item-top {
    width: 100%;
}

.service-item-top .overflow-hidden {
    height: 300px;
    overflow: hidden;
    flex-shrink: 0;
}

.service-item-top img {
    transition: .5s;
    border-radius: 8px 8px 0 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.service-item-top:hover img {
    transform: scale(1.1);
}

.service-item-top .bg-light {
    border-radius: 0 0 8px 8px;
    flex-grow: 1;
}

.service-carousel .bg-light,
.bg-light.p-4 {
    border-radius: 8px;
}

.service-carousel .owl-dots {
    margin-top: 24px;
    display: flex;
    align-items: flex-end;
    justify-content: center;
}

.service-carousel .owl-dot {
    position: relative;
    display: inline-block;
    margin: 0 5px;
    width: 15px;
    height: 15px;
    background: var(--primary);
    border: 5px solid var(--light);
    border-radius: 50%;
    transition: background 0.2s ease, border-color 0.2s ease;
}

.service-carousel .owl-dot.active {
    background: var(--light);
    border-color: var(--primary);
}


/* Service detail sections (per-service pages) */
.service-detail-wrapper {
    display: flex;
    flex-direction: column;
    gap: 2.5rem;
}

.service-detail {
    display: none;
    opacity: 0;
    transform: translateY(10px);
    background-color: #f8f9fa;
    border-radius: 16px;
    padding: 2rem 1.75rem;
    box-shadow: 0 6px 24px rgba(0, 0, 0, 0.08);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.service-detail.is-active {
    display: block;
    opacity: 1;
    transform: translateY(0);
}

@media (min-width: 992px) {
    .service-detail {
        padding: 2.5rem 2.5rem;
    }
}

.service-detail-hero {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    border-left: 4px solid var(--primary);
    padding-left: 1.25rem;
    margin-bottom: 0.5rem;
    position: relative;
}

.service-detail-close {
    align-self: flex-end;
    margin-bottom: 0.25rem;
    white-space: nowrap;
    transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.service-detail-close:hover {
    background-color: var(--primary) !important;
    border-color: var(--primary) !important;
    color: #fff !important;
}

.service-detail-hero h2 {
    font-size: 1.8rem;
}

@media (min-width: 992px) {
    .service-detail-hero h2 {
        font-size: 2rem;
    }
}

.service-detail-intro {
    font-size: 1rem;
    line-height: 1.7;
    color: #343a40 !important;
}

.service-detail-content h4 {
    font-size: 1.25rem;
}

.service-detail-content p {
    color: #343a40 !important;
    line-height: 1.7;
}

/* Service detail – text-only layout (no gallery) */
.service-detail-text-only .service-detail-body {
    max-width: 720px;
    margin-top: 1.5rem;
}

@media (min-width: 992px) {
    .service-detail-text-only .service-detail-body {
        margin-top: 2rem;
    }
}

.service-detail-block {
    margin-bottom: 1.75rem;
}

.service-detail-subtitle {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--primary) !important;
    margin-bottom: 0.75rem;
    letter-spacing: 0.02em;
}

.service-detail-list {
    list-style: none;
    padding-left: 0;
    margin: 0;
}

.service-detail-list li {
    display: flex;
    align-items: center;
    padding: 0.35rem 0;
    color: #343a40 !important;
    line-height: 1.5;
}

.service-detail-list li i {
    flex-shrink: 0;
    font-size: 0.85rem;
}

.service-detail-steps {
    padding-left: 1.35rem;
    margin: 0;
    counter-reset: step;
}

.service-detail-steps li {
    position: relative;
    padding: 0.4rem 0;
    color: #343a40 !important;
    line-height: 1.6;
    list-style: decimal;
}

.service-detail-steps li::marker {
    color: var(--primary);
    font-weight: 600;
}

.service-detail-outro {
    font-size: 1rem;
    line-height: 1.75;
    color: #343a40 !important;
    padding-top: 0.5rem;
}

.service-detail-gallery {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.9rem;
}

@media (max-width: 991.98px) {
    .service-detail-gallery {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 575.98px) {
    .service-detail-gallery {
        grid-template-columns: 1fr 1fr;
    }
}

.service-detail-gallery-item {
    position: relative;
    overflow: hidden;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
}

.service-detail-gallery-item::after {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 20% 0%, rgba(149, 113, 63, 0.22), transparent 55%);
    opacity: 0;
    transition: opacity 0.25s ease;
}

.service-detail-gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.35s ease;
    display: block;
}

.service-detail-gallery-item:hover img {
    transform: scale(1.06);
}

.service-detail-gallery-item:hover::after {
    opacity: 1;
}


/*** Booking ***/
.video {
    position: relative;
    padding: 8rem 0 12rem 0;
    background: linear-gradient(rgba(0, 0, 0, .4), rgba(0, 0, 0, .4)), url(../img/carousel-1.jpg) center center no-repeat;
    background-size: cover;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.video .btn-play {
    position: relative;
    box-sizing: content-box;
    display: block;
    width: 32px;
    height: 44px;
    border-radius: 50%;
    border: none;
    outline: none;
    padding: 18px 20px 18px 28px;
    margin-bottom: 4rem;
}

.video .btn-play:before {
    content: "";
    position: absolute;
    z-index: 0;
    left: 50%;
    top: 50%;
    transform: translateX(-50%) translateY(-50%);
    display: block;
    width: 100px;
    height: 100px;
    background: #FFFFFF;
    border-radius: 50%;
    animation: pulse-border 1500ms ease-out infinite;
}

.video .btn-play:after {
    content: "";
    position: absolute;
    z-index: 1;
    left: 50%;
    top: 50%;
    transform: translateX(-50%) translateY(-50%);
    display: block;
    width: 100px;
    height: 100px;
    background: #FFFFFF;
    border-radius: 50%;
    transition: all 200ms;
}

.video .btn-play img {
    position: relative;
    z-index: 3;
    max-width: 100%;
    width: auto;
    height: auto;
}

.video .btn-play span {
    display: block;
    position: relative;
    z-index: 3;
    width: 0;
    height: 0;
    border-left: 32px solid var(--primary);
    border-top: 22px solid transparent;
    border-bottom: 22px solid transparent;
}

@keyframes pulse-border {
    0% {
        transform: translateX(-50%) translateY(-50%) translateZ(0) scale(1);
        opacity: 1;
    }

    100% {
        transform: translateX(-50%) translateY(-50%) translateZ(0) scale(1.5);
        opacity: 0;
    }
}

#videoModal {
    z-index: 99999;
}

#videoModal .modal-dialog {
    position: relative;
    max-width: 800px;
    margin: 60px auto 0 auto;
}

#videoModal .modal-body {
    position: relative;
    padding: 0px;
}

#videoModal .close {
    position: absolute;
    width: 30px;
    height: 30px;
    right: 0px;
    top: -30px;
    z-index: 999;
    font-size: 30px;
    font-weight: normal;
    color: #FFFFFF;
    background: #000000;
    opacity: 1;
}

.bootstrap-datetimepicker-widget.bottom {
    top: auto !important;
}

.bootstrap-datetimepicker-widget .table * {
    border-bottom-width: 0px;
}

.bootstrap-datetimepicker-widget .table th {
    font-weight: 500;
}

.bootstrap-datetimepicker-widget.dropdown-menu {
    padding: 10px;
    border-radius: 2px;
}

.bootstrap-datetimepicker-widget table td.active,
.bootstrap-datetimepicker-widget table td.active:hover {
    background: var(--primary);
}

.bootstrap-datetimepicker-widget table td.today::before {
    border-bottom-color: var(--primary);
}


/*** Team ***/
.team-item img {
    transition: transform 0.25s ease;
}

.team-item:hover img {
    transform: scale(1.03);
}

.team-item .team-text {
    height: 90px;
    overflow: hidden;
}

.team-item .team-text .bg-light,
.team-item .team-text .bg-primary {
    position: relative;
    height: 90px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    transition: margin-top 0.3s ease;
}

.team-item .team-text .bg-primary {
    flex-direction: row;
}

.team-item:hover .team-text .bg-light {
    margin-top: -90px;
}

.team-item .team-text .bg-primary .btn {
    color: var(--primary);
    background: #FFFFFF;
}

.team-item .team-text .bg-primary .btn:hover {
    color: #FFFFFF;
    background: var(--secondary)
}


/*** Testimonial ***/
.testimonial-carousel .owl-item .testimonial-text,
.testimonial-carousel .owl-item.center .testimonial-text * {
    position: relative;
    transition: background 0.3s ease, color 0.3s ease;
}

.testimonial-carousel .owl-item.center .testimonial-text {
    background: var(--primary) !important;
}

.testimonial-carousel .owl-item.center .testimonial-text * {
    color: #FFFFFF !important;
}

.testimonial-carousel .owl-item .testimonial-text::after {
    position: absolute;
    content: "";
    width: 0;
    height: 0;
    left: 50%;
    bottom: -30px;
    transform: translateX(-50%);
    border: 15px solid;
    border-color: var(--light) transparent transparent transparent;
    transition: border-color 0.3s ease;
}

.testimonial-carousel .owl-item.center .testimonial-text::after {
    border-color: var(--primary) transparent transparent transparent;
}

.testimonial-carousel .owl-nav {
    position: absolute;
    width: 350px;
    bottom: 100px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    justify-content: space-between;
    opacity: 0;
    transition: .5s;
    z-index: 1;
}

.testimonial-carousel:hover .owl-nav {
    width: 300px;
    opacity: 1;
}

.testimonial-carousel .owl-nav .owl-prev,
.testimonial-carousel .owl-nav .owl-next {
    font-size: 30px;
    color: var(--primary);
}

.testimonial-carousel .owl-nav .owl-prev:hover,
.testimonial-carousel .owl-nav .owl-next:hover {
    color: var(--dark);
}


/*** Why Choose Us Section - Hover Effects ***/
#zasto-mi .bg-light {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    cursor: pointer;
}

#zasto-mi .bg-light:hover {
    transform: scale(1.05);
    box-shadow: 0 8px 20px rgba(149, 113, 63, 0.3);
}

#zasto-mi .bg-light .rounded-circle {
    transition: transform 0.3s ease;
}

#zasto-mi .bg-light:hover .rounded-circle {
    transform: scale(1.1);
}

/*** Footer ***/
.footer-dark {
    background-color: #3d2e1f !important;
    position: relative;
}

/* Modern footer with thin horizontal lines */
.footer-dark::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(to right, transparent, rgba(255, 255, 255, 0.2), transparent);
}

.footer-dark .container {
    position: relative;
}

.footer-dark .row {
    position: relative;
}

.footer-dark .row::after {
    content: "";
    position: absolute;
    bottom: -1.5rem;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(to right, transparent, rgba(255, 255, 255, 0.15), transparent);
}

.footer-dark .col-lg-4 {
    position: relative;
    padding-bottom: 2rem;
}

.footer-dark .col-lg-4:not(:last-child)::after {
    content: "";
    position: absolute;
    right: 0;
    top: 0;
    bottom: 0;
    width: 1px;
    background: linear-gradient(to bottom, transparent, rgba(255, 255, 255, 0.1), transparent);
}

@media (max-width: 991.98px) {
    .footer-dark .col-lg-4:not(:last-child)::after {
        display: none;
    }
    
    .footer-dark .col-lg-4::before {
        content: "";
        position: absolute;
        bottom: 0;
        left: 0;
        right: 0;
        height: 1px;
        background: linear-gradient(to right, transparent, rgba(255, 255, 255, 0.1), transparent);
    }
    
    .footer-dark .col-lg-4:last-child::before {
        display: none;
    }
}

.footer-dark h4 {
    position: relative;
    padding-bottom: 1rem;
    margin-bottom: 1.5rem;
}

.footer-dark h4::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    width: 50px;
    height: 1px;
    background: rgba(255, 255, 255, 0.3);
}

.footer-dark .btn.btn-social {
    margin-right: 5px;
    width: 35px;
    height: 35px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--light);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 35px;
    transition: all 0.2s ease;
}

.footer-dark .btn.btn-social:hover {
    color: var(--primary);
    border-color: var(--primary);
    background-color: rgba(149, 113, 63, 0.1);
}

.footer .btn.btn-social:hover {
    color: var(--primary);
}

.footer .btn.btn-link {
    display: block;
    margin-bottom: 5px;
    padding: 0;
    text-align: left;
    color: rgba(255, 255, 255, 0.8);
    font-size: 15px;
    font-weight: normal;
    text-transform: capitalize;
    transition: all 0.2s ease;
}

.footer .btn.btn-link::before {
    position: relative;
    content: "\f105";
    font-family: "Font Awesome 5 Free";
    font-weight: 900;
    margin-right: 10px;
}

.footer .btn.btn-link:hover {
    letter-spacing: 1px;
    color: #FFFFFF;
    box-shadow: none;
}

.footer .copyright {
    padding: 25px 0;
    font-size: 15px;
    border-top: 1px solid rgba(256, 256, 256, .1);
}

.footer .copyright a {
    color: var(--light);
}

/*** Override Bootstrap Colors ***/
:root {
    --bs-primary: #95713F !important;
}

/* Force override Bootstrap primary color everywhere */
* {
    --bs-primary-rgb: 149, 113, 63 !important;
}

.bg-primary {
    background-color: #95713F !important;
}

.border-primary {
    border-color: #95713F !important;
}

.btn-primary,
a.btn-primary,
button.btn-primary {
    background-color: #95713F !important;
    border-color: #95713F !important;
    color: #FFFFFF !important;
}

.btn-primary:hover,
.btn-primary:focus,
.btn-primary:active,
a.btn-primary:hover,
button.btn-primary:hover {
    background-color: #7a5d33 !important;
    border-color: #7a5d33 !important;
    color: #FFFFFF !important;
}

a.text-primary,
.text-primary {
    color: #95713F !important;
}

a.text-primary:hover {
    color: #7a5d33 !important;
}

.bg-primary {
    background-color: #95713F !important;
    border-radius: 8px;
}

/* Ensure text is white on primary background (except white backgrounds inside) */
.bg-primary p:not(.text-secondary):not(.text-white),
.bg-primary h1:not(.text-secondary):not(.text-white),
.bg-primary h2:not(.text-secondary):not(.text-white),
.bg-primary h3:not(.text-secondary):not(.text-white),
.bg-primary h4:not(.text-secondary):not(.text-white),
.bg-primary h5:not(.text-secondary):not(.text-white),
.bg-primary h6:not(.text-secondary):not(.text-white),
.bg-primary span:not(.text-secondary):not(.text-white) {
    color: #FFFFFF !important;
}

.border-primary {
    border-color: #8B4513 !important;
}

.btn-outline-primary {
    color: #95713F !important;
    border-color: #95713F !important;
}

.btn-outline-primary:hover {
    background-color: #95713F !important;
    border-color: #95713F !important;
    color: #FFFFFF !important;
}

/* Additional overrides for Bootstrap classes */
.bg-primary {
    background-color: #95713F !important;
}

/* Don't apply background to text-primary elements inside bg-primary */
.bg-primary .text-primary:not(.bg-white) {
    background-color: transparent !important;
    color: #FFFFFF !important;
}

/* Rounded corners for all primary backgrounds (except full height columns) */
.bg-primary:not(.w-100.h-100) {
    border-radius: 8px !important;
}

/* Rounded corners for light backgrounds in service sections */
.service-carousel .bg-light,
.bg-light.p-4,
.service-item-top .bg-light {
    border-radius: 8px !important;
}

/* Ensure images in service cards are rounded */
.service-carousel .overflow-hidden img {
    border-radius: 8px 8px 0 0;
}

/* Rounded corners for navbar contact box */
.nav-bar .bg-primary {
    border-radius: 8px;
    margin-top: 0.5rem !important;
    margin-bottom: 0.5rem !important;
    margin-right: 0.5rem !important;
}

/* Rounded corners for about section contact box */
.bg-primary.d-flex.align-items-center {
    border-radius: 8px;
}

/* Ensure all text in primary backgrounds is white (except white backgrounds inside) */
.bg-primary .text-primary:not(.bg-white *) {
    color: #FFFFFF !important;
}

.text-primary,
.text-primary * {
    color: #8B4513 !important;
}

/* Ensure text-primary doesn't have background */
.text-primary {
    background-color: transparent !important;
}

/* Ensure paragraphs with text-primary are visible on light backgrounds */
.bg-light .text-primary,
p.text-primary,
p.fw-medium.text-primary {
    color: #95713F !important;
    background-color: transparent !important;
}

/* Override any background on text-primary elements */
p.text-primary,
p.fw-medium.text-primary,
.text-primary.fw-medium {
    background-color: transparent !important;
    background: transparent !important;
}

/* Spinner border color */
.spinner-border.text-primary {
    border-color: #95713F !important;
    border-right-color: transparent !important;
}

/* Additional Bootstrap overrides */
.btn-primary:not(:disabled):not(.disabled):active,
.btn-primary:not(:disabled):not(.disabled).active {
    background-color: #7a5d33 !important;
    border-color: #7a5d33 !important;
}

/* Link colors */
a {
    color: inherit;
}

a:hover {
    color: #95713F !important;
}

/* Ensure all Bootstrap primary utility classes use new color */
.bg-primary,
.badge-primary,
.alert-primary {
    background-color: #95713F !important;
}

.border-primary {
    border-color: #95713F !important;
}

.text-primary {
    color: #95713F !important;
}

.btn-primary,
a.btn-primary,
button.btn-primary {
    background-color: #95713F !important;
    border-color: #95713F !important;
    color: #FFFFFF !important;
}

/* Navbar brand logo styling */
.navbar-brand img {
    max-height: 60px;
    width: auto;
    object-fit: contain;
}

.navbar-brand {
    margin-right: 1rem !important;
}

@media (max-width: 991.98px) {
    .navbar-brand img {
        max-height: 50px;
    }
}

/* Enhanced Theme */
:root {
    --primary-dark: #7a5d33;
    --primary-light: #b08a5f;
}

/* Enhanced gradient for primary buttons - optimized */
.btn-primary {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%) !important;
    border: none !important;
    box-shadow: 0 2px 8px rgba(149, 113, 63, 0.2);
    transition: all 0.2s ease;
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 100%) !important;
    box-shadow: 0 4px 12px rgba(149, 113, 63, 0.3);
}

/* Enhanced primary background with brown theme - optimized */
.bg-primary {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%) !important;
}

/*** Gallery ***/
.gallery-item {
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    overflow: hidden;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.gallery-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(149, 113, 63, 0.2);
}

.gallery-item .gallery-overlay {
    pointer-events: none;
}

.gallery-item:hover .gallery-overlay {
    background: rgba(149, 113, 63, 0.8) !important;
}

.gallery-item:hover .gallery-overlay i {
    opacity: 1 !important;
    transform: scale(1.2);
}

.gallery-item img {
    transition: transform 0.25s ease;
    width: 100%;
    display: block;
}

.gallery-item:hover img {
    transform: scale(1.02);
}

/* Lightbox Modal Styles */
#lightboxModal .modal-content {
    background: transparent;
}

#lightboxModal .modal-header {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 1051;
    padding: 0;
}

#lightboxModal .btn-close {
    background-color: rgba(0, 0, 0, 0.5);
    border-radius: 50%;
    padding: 10px;
    opacity: 1;
}

#lightboxModal .btn-close:hover {
    background-color: rgba(0, 0, 0, 0.7);
}

#lightboxModal img {
    max-height: 90vh;
    object-fit: contain;
}

/* Contact Section Map Styles */
#kontakt-sekcija {
    padding-top: 3rem !important;
    padding-bottom: 3rem !important;
}

#kontakt-sekcija .row {
    align-items: stretch;
}

#kontakt-sekcija .col-lg-6 {
    display: flex;
}

#kontakt-sekcija .col-lg-6 .bg-light {
    width: 100%;
    display: flex;
    flex-direction: column;
}

#kontakt-sekcija .col-lg-6 .bg-light ul {
    flex-grow: 1;
}

@media (min-width: 992px) {
    #kontakt-sekcija .col-lg-6 .bg-light {
        min-height: 300px;
    }
    
    #kontakt-sekcija .col-lg-6:first-child .bg-light {
        justify-content: space-between;
    }
    
    #kontakt-sekcija .col-lg-6:last-child .bg-light > div:last-child {
        flex: 1;
        min-height: 0;
        display: flex;
    }
    
    #kontakt-sekcija .col-lg-6:last-child iframe {
        height: 100% !important;
        width: 100% !important;
        min-height: 0;
    }
}

@media (max-width: 991.98px) {
    #kontakt-sekcija .col-lg-6 .bg-light {
        min-height: auto;
    }
    
    #kontakt-sekcija .col-lg-6:last-child iframe {
        height: 300px;
        min-height: 300px;
    }
}

/* Services List Section Styles */
#delatnosti {
    position: relative;
    overflow: hidden;
}

#delatnosti::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5));
    z-index: 1;
}

#delatnosti .container {
    position: relative;
    z-index: 2;
}

#delatnosti .bg-white {
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
    border: 2px solid transparent !important;
}

#delatnosti .bg-white:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(149, 113, 63, 0.2) !important;
    border-color: var(--primary) !important;
}

#delatnosti .service-list-item {
    transition: padding 0.15s ease;
    padding: 5px 0;
}

#delatnosti .service-list-item:hover {
    padding-left: 8px;
}

#delatnosti .service-list-item i {
    transition: transform 0.15s ease;
}

#delatnosti .service-list-item:hover i {
    transform: scale(1.1);
}

#delatnosti .rounded-circle {
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    box-shadow: 0 2px 8px rgba(139, 69, 19, 0.2);
}

#delatnosti .bg-white:hover .rounded-circle {
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(139, 69, 19, 0.3);
}

/* Background attachment removed for better performance */
#delatnosti {
    background-attachment: scroll !important;
}

/*** Gallery CTA Section ***/
.gallery-preview-item {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.gallery-preview-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(149, 113, 63, 0.3);
    text-decoration: none;
}

.gallery-preview-item img,
.gallery-preview-item video {
    transition: transform 0.5s ease;
}

.gallery-preview-item:hover img,
.gallery-preview-item:hover video {
    transform: scale(1.1);
}

.gallery-preview-item video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.gallery-preview-overlay {
    background: rgba(149, 113, 63, 0);
    transition: background 0.3s ease;
    pointer-events: none;
}

.gallery-preview-item:hover .gallery-preview-overlay {
    background: rgba(149, 113, 63, 0.4);
}

.gallery-preview-overlay i {
    opacity: 0;
    transform: scale(0.8);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.gallery-preview-item:hover .gallery-preview-overlay i {
    opacity: 1;
    transform: scale(1.2);
}

/* Icon circle styling */
.container-xxl .rounded-circle {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    box-shadow: 0 4px 12px rgba(149, 113, 63, 0.2);
}

.container-xxl .rounded-circle:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 20px rgba(149, 113, 63, 0.4);
}

/* Button styling */
.container-xxl .btn-primary {
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.container-xxl .btn-primary::before {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    transform: translate(-50%, -50%);
    transition: width 0.6s ease, height 0.6s ease;
}

.container-xxl .btn-primary:hover::before {
    width: 300px;
    height: 300px;
}

.container-xxl .btn-primary i {
    position: relative;
    z-index: 1;
}

/* Contact info section - modern card layout */
#kontakt-sekcija .contact-info-card {
    background-color: #f8f9fa;
    padding: 1.5rem;
    border-radius: 12px;
}

#kontakt-sekcija .contact-info-image-wrapper {
    width: 100%;
    overflow: hidden;
}

#kontakt-sekcija .contact-info-image {
    width: 100%;
    height: auto;
    max-height: 220px;
    object-fit: cover;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    display: block;
}

#kontakt-sekcija .contact-info-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary) !important;
    letter-spacing: -0.02em;
    margin-bottom: 1.25rem;
}

#kontakt-sekcija .contact-info-cards {
    margin-top: 0.25rem;
}

#kontakt-sekcija .contact-info-item {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    border: 1px solid rgba(149, 113, 63, 0.08);
    height: 100%;
}

#kontakt-sekcija .contact-info-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(149, 113, 63, 0.12);
}

#kontakt-sekcija .contact-info-icon {
    width: 44px;
    height: 44px;
    min-width: 44px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

#kontakt-sekcija .contact-info-label {
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--primary) !important;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

#kontakt-sekcija .contact-info-item .text-dark,
#kontakt-sekcija .contact-info-item p {
    color: #212529 !important;
    font-size: 0.95rem;
}

#kontakt-sekcija .contact-info-item a {
    color: var(--primary) !important;
}

#kontakt-sekcija .contact-info-item a:hover {
    color: var(--primary-dark) !important;
    text-decoration: underline !important;
}

/* Audience section - Za koga su namenjene usluge */
#delatnosti .audience-section {
    background: rgba(255, 255, 255, 0.96);
    padding: 2rem 2.25rem;
    border-radius: 16px;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.08);
    max-width: 100%;
}

#delatnosti .audience-section-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary) !important;
    text-align: center;
    margin-bottom: 1.75rem;
    letter-spacing: -0.02em;
    font-family: inherit;
}

#delatnosti .audience-grid {
    margin-top: 0.5rem;
}

#delatnosti .audience-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    text-align: center;
    padding: 1.5rem 1.25rem;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
    border: 1px solid rgba(149, 113, 63, 0.1);
    height: 100%;
    transition: transform 0.25s ease-in-out, box-shadow 0.25s ease-in-out;
}

#delatnosti .audience-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 28px rgba(149, 113, 63, 0.15);
    border-color: rgba(149, 113, 63, 0.2);
}

#delatnosti .audience-card-icon {
    width: 48px;
    height: 48px;
    min-width: 48px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 0.75rem;
    flex-shrink: 0;
    transition: transform 0.25s ease-in-out;
}

#delatnosti .audience-card:hover .audience-card-icon {
    transform: scale(1.05);
}

#delatnosti .audience-card-icon i {
    font-size: 1.25rem;
}

#delatnosti .audience-card-label {
    font-size: 1rem;
    font-weight: 600;
    color: #212529 !important;
    line-height: 1.35;
}
