/********** Template CSS **********/
:root {
    --primary: #B8860B;
    --secondary: #F6F6F6;
    --light: #FFFFFF;
    --dark: #000000;
    --green: #228B22;
}

h1,
h2,
.font-weight-bold {
    font-weight: 700 !important;
}

h3,
h4,
.font-weight-semi-bold {
    font-weight: 600 !important;
}

h5,
h6,
.font-weight-medium {
    font-weight: 500 !important;
}

.pt-6 {
    padding-top: 90px;
}

.pb-6 {
    padding-bottom: 90px;
}

.py-6 {
    padding-top: 90px;
    padding-bottom: 90px;
}

.btn {
    font-family: 'Barlow', sans-serif;
    font-weight: 600;
    transition: .5s;
}

.btn-primary {
    color: #FFFFFF;
    background-color: var(--primary);
    border-color: var(--primary);
}

.btn-primary:hover {
    background-color: var(--green);
    border-color: var(--green);
}

.text-primary {
    color: var(--primary) !important;
}

.bg-primary {
    background-color: var(--primary) !important;
}

.bg-green {
    background-color: var(--green) !important;
}

.text-green {
    color: var(--green) !important;
}

.badge.bg-green {
    background-color: var(--green) !important;
    color: white;
}

body, p, h1, h2, h3, h4, h5, h6 {
    color: var(--dark);
}

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

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

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

.btn-square,
.btn-sm-square,
.btn-lg-square {
    padding-left: 0;
    padding-right: 0;
    text-align: center;
}

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

.top-shape::before {
    position: absolute;
    content: "";
    width: 35px;
    height: 100%;
    top: 0;
    left: -17px;
    background: var(--primary);
    transform: skew(40deg);
}

/* Header z-index to ensure it stays above all content */
.container-fluid.bg-secondary:first-of-type {
    position: relative;
    z-index: 2000;
}

.navbar {
    position: relative;
    z-index: 2000;
}

.navbar-brand {
    display: flex;
    align-items: center;
    padding: 0;
}

.navbar-brand h3 {
    display: flex;
    align-items: center;
    margin: 0;
    white-space: nowrap;
    font-size: 1.2rem;
}

.navbar-brand img {
    flex-shrink: 0;
    display: block;
}

.navbar-toggler {
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 0.25rem;
}

/* Modal z-index to appear above header (header is 2000) - High priority */
body .modal {
    z-index: 3000 !important;
    position: fixed !important;
}

body .modal-backdrop {
    z-index: 2999 !important;
    position: fixed !important;
}

body .modal-dialog {
    z-index: 3001 !important;
    position: relative !important;
}

body .modal-content {
    position: relative !important;
    z-index: 3002 !important;
}

body .modal.show,
body .modal.fade.show {
    z-index: 3000 !important;
    display: block !important;
}

body .modal.show .modal-dialog,
body .modal.fade.show .modal-dialog {
    z-index: 3001 !important;
}

body .modal.show .modal-content,
body .modal.fade.show .modal-content {
    z-index: 3002 !important;
}

.navbar-light .navbar-nav .nav-link {
    font-family: 'Barlow', sans-serif;
    padding: 35px 15px;
    font-size: 18px;
    text-transform: uppercase;
    color: var(--dark);
    outline: none;
    transition: .5s;
}

.sticky-top.navbar {
    z-index: 2000;
}

.sticky-top.navbar-light .navbar-nav .nav-link {
    padding: 20px 15px;
}

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

@media (max-width: 991.98px) {
    /* Navbar mobile fixes */
    .navbar {
        padding-left: 1rem !important;
        padding-right: 1rem !important;
    }

    .navbar-brand {
        display: flex !important;
        align-items: center !important;
        flex: 0 1 auto;
    }

    .navbar-brand h3 {
        display: flex !important;
        align-items: center !important;
        margin: 0 !important;
        white-space: nowrap;
        font-size: 1rem !important;
        line-height: 1.2;
    }

    .navbar-brand img {
        width: 40px !important;
        height: 40px !important;
        margin-right: 8px !important;
        flex-shrink: 0;
    }

    .navbar-toggler {
        padding: 0.25rem 0.5rem !important;
        border: 1px solid rgba(0, 0, 0, 0.1) !important;
        border-radius: 0.25rem;
        margin-left: auto;
    }

    .navbar-toggler:focus {
        box-shadow: 0 0 0 0.2rem rgba(0, 0, 0, 0.1);
        outline: none;
    }

    .navbar-toggler-icon {
        width: 1.5em;
        height: 1.5em;
        display: inline-block;
        background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%2833, 37, 41, 0.75%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
        background-repeat: no-repeat;
        background-position: center;
        background-size: 100%;
    }

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

    .navbar-collapse {
        margin-top: 1rem;
        padding: 1rem;
        background-color: rgba(255, 255, 255, 0.98);
        border-radius: 0.25rem;
        box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    }
}

@media (max-width: 576px) {
    /* Extra small screens - navbar fixes */
    .navbar {
        padding-left: 0.75rem !important;
        padding-right: 0.75rem !important;
        padding-top: 0.75rem !important;
        padding-bottom: 0.75rem !important;
    }

    .navbar-brand {
        display: flex !important;
        align-items: center !important;
        flex: 0 1 auto;
    }

    .navbar-brand h3 {
        font-size: 0.85rem !important;
        display: flex !important;
        align-items: center !important;
        margin: 0 !important;
        white-space: nowrap;
        line-height: 1.2;
    }

    .navbar-brand img {
        width: 35px !important;
        height: 35px !important;
        margin-right: 6px !important;
        flex-shrink: 0;
    }

    .navbar-toggler {
        padding: 0.2rem 0.4rem !important;
        margin-left: auto;
    }

    .navbar-toggler-icon {
        width: 1.3em;
        height: 1.3em;
    }
}

.carousel-caption {
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(21, 36, 64, .3);
    z-index: 1;
}

.carousel-caption > div {
    transform: translateY(0);
}

.carousel-item {
    height: 680px;
}

.carousel-item img {
    height: 100%;
    object-fit: cover;
}

/* Mobile responsiveness for carousel */
@media (max-width: 991.98px) {
    .carousel-item {
        height: 500px;
    }

    .carousel-caption {
        justify-content: center !important;
    }

    .carousel-caption > div {
        transform: translateY(0);
    }
}

@media (max-width: 768px) {
    .carousel-item {
        height: 450px;
    }

    .carousel-caption {
        justify-content: center !important;
    }

    .carousel-caption > div {
        transform: translateY(0);
    }

    .carousel-caption h5 {
        font-size: 13px;
        font-weight: 500 !important;
        margin-bottom: 0.75rem;
    }

    .carousel-caption h1 {
        font-size: 28px;
        font-weight: 600 !important;
        line-height: 1.2;
        margin-bottom: 1rem;
    }

    .carousel-caption .btn {
        padding: 0.75rem 1.5rem !important;
        font-size: 0.9rem;
        margin: 0.25rem;
    }
}

@media (max-width: 576px) {
    .carousel-item {
        height: 400px;
        min-height: 400px;
    }

    .carousel-caption {
        justify-content: center !important;
        padding: 1rem !important;
    }

    .carousel-caption > div {
        transform: translateY(0);
        max-width: 100% !important;
        padding-left: 1rem !important;
        padding-right: 1rem !important;
    }

    .carousel-caption h5 {
        font-size: 12px;
        font-weight: 500 !important;
        margin-bottom: 0.5rem;
        letter-spacing: 0.5px;
    }

    .carousel-caption h1 {
        font-size: 24px;
        font-weight: 600 !important;
        line-height: 1.3;
        margin-bottom: 1rem;
    }

    .carousel-caption .btn {
        padding: 0.6rem 1.2rem !important;
        font-size: 0.85rem;
        margin: 0.25rem 0.15rem;
        display: inline-block;
        width: auto;
    }
}

.carousel-control-prev,
.carousel-control-next {
    width: 10%;
}

.carousel-control-prev-icon,
.carousel-control-next-icon {
    width: 3rem;
    height: 3rem;
}

.service-item {
    position: relative;
    overflow: hidden;
    height: 350px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    transition: .3s;
}

.service-item::after {
    position: absolute;
    content: "";
    width: 100%;
    height: 50px;
    bottom: -50px;
    left: 0;
    background: var(--light);
    border-radius: 100% 100% 0 0;
    box-shadow: 0px -10px 5px #EEEEEE;
    transition: .5s;
}

.service-item:hover::after {
    bottom: -25px;
}

.service-item p {
    transition: .3s;
}

.service-item:hover p {
    margin-bottom: 25px !important;
}

.team-item img {
    transform: scale(1.15);
    margin-left: -30px;
    transition: .5s;
}

.team-item:hover img {
    margin-left: 0;
}

.team-item .team-text {
    left: -100%;
    transition: .5s;
}

.team-item .team-text::after {
    position: absolute;
    content: "";
    width: 0;
    height: 0;
    top: 50%;
    right: -60px;
    margin-top: -30px;
    border: 30px solid;
    border-color: transparent transparent transparent var(--primary);
}

.team-item:hover .team-text {
    left: 0;
}

.blog-item img {
    transition: .5s;
}

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

/* Custom Alert System Styles */
.custom-alert-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: 99998;
}

.custom-alert-overlay.show {
    opacity: 1;
}

.custom-alert-modal {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.9);
    background: white;
    border-radius: 8px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    max-width: 500px;
    width: 90%;
    max-height: 90vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    opacity: 0;
    transition: all 0.3s ease;
    z-index: 99999;
}

.custom-alert-modal.show {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
}

.custom-alert-header {
    padding: 20px;
    color: white;
    display: flex;
    align-items: center;
    gap: 12px;
}

.custom-alert-header i {
    font-size: 24px;
}

.custom-alert-title {
    margin: 0;
    font-size: 20px;
    font-weight: 600;
    color: white;
}

.custom-alert-body {
    padding: 25px;
    flex: 1;
    overflow-y: auto;
}

.custom-alert-message {
    margin: 0;
    font-size: 16px;
    line-height: 1.6;
    color: var(--dark);
    word-wrap: break-word;
}

.custom-alert-footer {
    padding: 15px 20px;
    border-top: 1px solid #e0e0e0;
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

.custom-alert-footer button {
    min-width: 80px;
    padding: 8px 20px;
}

/* Notification Toast Styles */
.custom-notifications-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 99997;
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-width: 400px;
    width: auto;
}

.custom-notification {
    background: white;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    padding: 15px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
    min-width: 300px;
    transform: translateX(400px);
    opacity: 0;
    transition: all 0.3s ease;
}

.custom-notification.show {
    transform: translateX(0);
    opacity: 1;
}

.custom-notification-content {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
}

.custom-notification-content i {
    font-size: 20px;
    flex-shrink: 0;
}

.custom-notification-content span {
    font-size: 14px;
    line-height: 1.5;
    color: var(--dark);
}

.custom-notification-close {
    background: none;
    border: none;
    color: #666;
    cursor: pointer;
    padding: 5px;
    font-size: 16px;
    line-height: 1;
    transition: color 0.2s;
    flex-shrink: 0;
}

.custom-notification-close:hover {
    color: var(--dark);
}

.custom-notification-success {
    border-left: 4px solid #28a745;
}

.custom-notification-success .custom-notification-content i {
    color: #28a745;
}

.custom-notification-error {
    border-left: 4px solid #dc3545;
}

.custom-notification-error .custom-notification-content i {
    color: #dc3545;
}

.custom-notification-warning {
    border-left: 4px solid #ffc107;
}

.custom-notification-warning .custom-notification-content i {
    color: #ffc107;
}

.custom-notification-info {
    border-left: 4px solid #17a2b8;
}

.custom-notification-info .custom-notification-content i {
    color: #17a2b8;
}

@media (max-width: 576px) {
    .custom-alert-modal {
        max-width: 95%;
        width: 95%;
    }
    
    .custom-notifications-container {
        right: 10px;
        left: 10px;
        max-width: calc(100% - 20px);
    }
    
    .custom-notification {
        min-width: auto;
        width: 100%;
    }
}

/* Modal Border Radius Styles - Professional Curved Borders */
.modal-content {
    border-radius: 15px !important;
    overflow: hidden;
    border: none;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
}

.modal-header {
    border-radius: 15px 15px 0 0 !important;
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

.modal-footer {
    border-radius: 0 0 15px 15px !important;
    border-top: 1px solid rgba(0, 0, 0, 0.1);
}

.modal-body {
    padding: 1.5rem;
}