/********** Template CSS **********/
:root {
    --primary: #FF800F;
    --secondary: #001064;
    --light: #F6F7F8;
    --dark: #010A35;
    --gradient-primary: linear-gradient(135deg, #FF800F 0%, #FF9A40 100%);
    --gradient-secondary: linear-gradient(135deg, #001064 0%, #002080 100%);
    --shadow-light: 0 2px 15px rgba(0,0,0,0.05);
    --shadow-medium: 0 5px 25px rgba(0,0,0,0.15);
    --shadow-dark: 0 10px 35px rgba(0,0,0,0.25);
    --border-radius: 12px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Smooth scrolling for modern browsers */
html {
    scroll-behavior: smooth;
    overflow-x: hidden;
    max-width: 100%;
}

/* Modern scrollbar styling */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--light);
}

::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--secondary);
}

body {
    overflow-x: hidden;
    max-width: 100%;
}

.back-to-top {
    position: fixed;
    display: none;
    right: 30px;
    bottom: 30px;
    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 {
    transition: var(--transition);
    border-radius: var(--border-radius);
    font-weight: 500;
    letter-spacing: 0.5px;
    box-shadow: var(--shadow-light);
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.5s;
    z-index: -1;
}

.btn:hover::before {
    left: 100%;
}

.btn.btn-primary {
    background: var(--gradient-primary);
    border: none;
    color: #FFFFFF;
    box-shadow: var(--shadow-medium);
}

.btn.btn-primary:hover {
    background: var(--gradient-secondary);
    transform: translateY(-2px);
    box-shadow: var(--shadow-dark);
}

.btn.btn-secondary {
    background: var(--gradient-secondary);
    border: none;
    color: #FFFFFF;
    box-shadow: var(--shadow-medium);
}

.btn.btn-secondary:hover {
    background: var(--gradient-primary);
    transform: translateY(-2px);
    box-shadow: var(--shadow-dark);
}

.btn.btn-outline-primary:hover,
.btn.btn-outline-secondary:hover {
    color: #FFFFFF;
    transform: translateY(-2px);
}

.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 ***/
.navbar.sticky-top {
    top: -100px;
    transition: var(--transition);
    backdrop-filter: blur(10px);
    background: rgba(255, 255, 255, 0.95) !important;
    box-shadow: var(--shadow-light);
}

.navbar .navbar-brand img {
    max-height: 60px;
    transition: var(--transition);
}

.navbar .navbar-nav .nav-link {
    margin-left: 25px;
    padding: 12px 16px;
    color: #696E77;
    font-weight: 500;
    outline: none;
    border-radius: 8px;
    transition: var(--transition);
    position: relative;
    min-height: 44px;
    display: flex;
    align-items: center;
}

.navbar .navbar-nav .nav-link:hover,
.navbar .navbar-nav .nav-link.active {
    color: var(--primary);
    background: rgba(255, 128, 15, 0.1);
    transform: translateY(-2px);
}

.navbar .navbar-nav .nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background: var(--gradient-primary);
    transition: var(--transition);
    transform: translateX(-50%);
}

.navbar .navbar-nav .nav-link:hover::after,
.navbar .navbar-nav .nav-link.active::after {
    width: 80%;
}

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

/* Enhanced navbar toggler */
.navbar-toggler {
    border: none;
    padding: 8px 12px;
    border-radius: var(--border-radius);
    background: var(--gradient-primary);
    box-shadow: var(--shadow-light);
    transition: var(--transition);
    min-height: 44px;
    min-width: 44px;
}

.navbar-toggler:hover {
    transform: scale(1.05);
    box-shadow: var(--shadow-medium);
}

.navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28255, 255, 255, 1%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='m4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

@media (max-width: 991.98px) {
    .navbar .navbar-brand img {
        max-height: 45px;
        transition: var(--transition);
    }
    
    .navbar .navbar-brand img:hover {
        transform: scale(1.05);
    }

    .navbar-toggler {
        border: none !important;
        padding: 6px 10px;
        border-radius: 8px;
        background-color: var(--primary);
        z-index: 1060;
        position: relative;
    }
    
    .navbar-toggler:focus {
        box-shadow: 0 0 0 3px rgba(255, 128, 15, 0.3);
        outline: none;
    }
    
    .navbar-collapse {
        background: rgba(255, 255, 255, 0.98);
        backdrop-filter: blur(15px);
        border-radius: var(--border-radius);
        padding: 0 !important;
        margin-top: 10px;
        box-shadow: var(--shadow-medium);
        z-index: 1050;
        position: relative;
    }

    .navbar .navbar-nav {
        margin: 0;
        padding: 20px;
        background: transparent !important;
    }
    
    .navbar .navbar-nav .nav-link {
        margin: 8px 0;
        padding: 12px 15px; /* Adjusted padding */
        border-radius: var(--border-radius);
        font-size: 15px; /* Adjusted font size */
        min-height: 48px; /* Adjusted min-height */
        display: flex;
        align-items: center;
        background: rgba(246, 247, 248, 0.5);
        transition: var(--transition);
    }
    
    .navbar .navbar-nav .nav-link:hover,
    .navbar .navbar-nav .nav-link.active,
    .navbar .navbar-nav .nav-link.btn-quote {
        background: var(--gradient-primary);
        color: white;
        transform: translateX(8px);
        box-shadow: var(--shadow-medium);
    }

    .navbar .nav-item .dropdown-menu {
        padding-left: 30px;
        background: rgba(255, 255, 255, 0.95);
        backdrop-filter: blur(10px);
        border: none;
        box-shadow: var(--shadow-medium);
        border-radius: var(--border-radius);
        margin-top: 10px;
    }
    
    .navbar .dropdown-item {
        padding: 12px 20px;
        border-radius: 8px;
        margin: 4px 0;
        transition: var(--transition);
        min-height: 44px;
    }
    
    .navbar .dropdown-item:hover {
        background: var(--gradient-primary);
        color: white;
        transform: translateX(5px);
    }
}

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

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


/*** Header ***/
.carousel-caption {
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    background: rgba(1, 10, 53, .8);
    z-index: 1;
}

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

.carousel-control-prev-icon,
.carousel-control-next-icon {
    width: 3rem;
    height: 3rem;
    background-color: var(--dark);
    border: 12px solid var(--dark);
    border-radius: 3rem;
}

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

.page-header {
    background: var(--gradient-secondary) !important;
    border-bottom: 5px solid var(--primary);
    box-shadow: var(--shadow-medium);
    position: relative;
    overflow: hidden;
}

.page-header::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, rgba(255,255,255,0) 70%);
    transform: rotate(30deg);
    animation: rotate 20s linear infinite;
}

@keyframes rotate {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

.page-header .breadcrumb-item a,
.page-header .breadcrumb-item+.breadcrumb-item::before {
    color: var(--light);
}

.page-header .breadcrumb-item a:hover,
.page-header .breadcrumb-item.active {
    color: var(--primary);
}


/*** Cool Modern Stats Section ***/
.facts {
    background: linear-gradient(135deg, rgba(1, 10, 53, 0.95) 0%, rgba(255, 128, 15, 0.9) 100%);
    position: relative;
    overflow: hidden;
}

.facts::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grid" width="10" height="10" patternUnits="userSpaceOnUse"><path d="M 10 0 L 0 0 0 10" fill="none" stroke="rgba(255,255,255,0.1)" stroke-width="0.5"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
    animation: backgroundMove 20s linear infinite;
}

@keyframes backgroundMove {
    0% { transform: translateX(0) translateY(0); }
    100% { transform: translateX(-100px) translateY(-100px); }
}

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

/* Individual Stat Cards */
.facts .col-sm-6.col-lg-3 {
    position: relative;
    perspective: 1000px;
}

.stat-card {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(20px);
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 20px;
    padding: 40px 20px;
    text-align: center;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    overflow: hidden;
    transform-style: preserve-3d;
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.7s;
}

.stat-card:hover::before {
    left: 100%;
}

.stat-card:hover {
    transform: translateY(-15px) rotateY(5deg) rotateX(5deg);
    border-color: rgba(255, 255, 255, 0.4);
    box-shadow: 
        0 20px 40px rgba(0, 0, 0, 0.3),
        0 0 30px rgba(255, 128, 15, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.stat-card .display-4 {
    font-size: 4rem;
    font-weight: 900;
    background: linear-gradient(45deg, #ffffff 0%, #FFD700 50%, #FF800F 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 15px;
    text-shadow: 0 0 30px rgba(255, 215, 0, 0.5);
    animation: glow 2s ease-in-out infinite alternate;
}

@keyframes glow {
    from {
        filter: drop-shadow(0 0 5px rgba(255, 215, 0, 0.5));
    }
    to {
        filter: drop-shadow(0 0 20px rgba(255, 215, 0, 0.8));
    }
}

.stat-card .text-primary {
    color: #ffffff !important;
    font-size: 1.1rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    position: relative;
}

.stat-card .text-primary::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 50%;
    transform: translateX(-50%);
    width: 30px;
    height: 2px;
    background: linear-gradient(90deg, #FF800F, #FFD700);
    border-radius: 2px;
}

/* Cool Icon Effects */
.stat-card::after {
    content: '';
    position: absolute;
    top: 15px;
    right: 15px;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    opacity: 0;
    transform: scale(0);
    transition: all 0.3s ease;
}

.stat-card:hover::after {
    opacity: 1;
    transform: scale(1);
}

/* Add specific icons for each stat */
.stat-card[data-stat="clients"]::after {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%23ffffff' viewBox='0 0 24 24'%3E%3Cpath d='M12 12c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm0 2c-2.67 0-8 1.34-8 4v2h16v-2c0-2.66-5.33-4-8-4z'/%3E%3C/svg%3E");
    background-size: 20px;
    background-repeat: no-repeat;
    background-position: center;
}

.stat-card[data-stat="projects"]::after {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%23ffffff' viewBox='0 0 24 24'%3E%3Cpath d='M9 11H7v6h2v-6zm4 0h-2v6h2v-6zm4 0h-2v6h2v-6zm2.5-5H18V4c0-1.1-.9-2-2-2h-4c-1.1 0-2 .9-2 2v2H5.5l-.5 0v2h1.5L7.27 19c.15 1.1 1.1 2 2.23 2h5c1.13 0 2.08-.9 2.23-2L18 8h1.5V6l-.5 0zM10 4h4v2h-4V4z'/%3E%3C/svg%3E");
    background-size: 20px;
    background-repeat: no-repeat;
    background-position: center;
}

.stat-card[data-stat="awards"]::after {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%23ffffff' viewBox='0 0 24 24'%3E%3Cpath d='M12 2l3.09 6.26L22 9.27l-5 4.87 1.18 6.88L12 17.77l-6.18 3.25L7 14.14 2 9.27l6.91-1.01L12 2z'/%3E%3C/svg%3E");
    background-size: 20px;
    background-repeat: no-repeat;
    background-position: center;
}

.stat-card[data-stat="team"]::after {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%23ffffff' viewBox='0 0 24 24'%3E%3Cpath d='M16 4c0-1.11.89-2 2-2s2 .89 2 2-.89 2-2 2-2-.89-2-2zm4 18v-6h2.5l-2.54-7.63A3.001 3.001 0 0 0 17 6.5c-.83 0-1.58.34-2.12.89L13 9.25V12h2v8h2zm-6.5-12L9.4 8.2C8.6 7.5 7.6 7.1 6.5 7.1S4.4 7.5 3.6 8.2L1.5 10v2h2v8h2v-8h2v8h2v-8h2v-2zm-5-1c1.11 0 2-.89 2-2s-.89-2-2-2-2 .89-2 2 .89 2 2 2z'/%3E%3C/svg%3E");
    background-size: 20px;
    background-repeat: no-repeat;
    background-position: center;
}

/* Floating Particles Effect */
.facts::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        radial-gradient(2px 2px at 20% 30%, rgba(255, 255, 255, 0.3), transparent),
        radial-gradient(2px 2px at 40% 70%, rgba(255, 128, 15, 0.4), transparent),
        radial-gradient(1px 1px at 90% 40%, rgba(255, 255, 255, 0.3), transparent),
        radial-gradient(1px 1px at 60% 80%, rgba(255, 215, 0, 0.4), transparent);
    background-repeat: repeat;
    background-size: 100px 100px, 120px 120px, 80px 80px, 140px 140px;
    animation: floatingParticles 15s linear infinite;
    pointer-events: none;
}

@keyframes floatingParticles {
    0% { transform: translateY(0px) translateX(0px); }
    100% { transform: translateY(-100px) translateX(50px); }
}

/* Mobile Responsiveness for Stats */
@media (max-width: 768px) {
    .facts {
        padding: 40px 0 !important;
    }
    
    .facts .container {
        padding: 20px 0 !important;
    }
    
    .facts .row {
        gap: 20px !important;
    }
    
    .stat-card {
        padding: 30px 15px;
        margin-bottom: 20px;
        border-radius: 15px;
    }
    
    .stat-card .display-4 {
        font-size: 3rem;
    }
    
    .stat-card .text-primary {
        font-size: 1rem;
    }
    
    .stat-card:hover {
        transform: translateY(-8px) rotateY(0deg) rotateX(0deg);
    }
    
    .stat-card::after {
        width: 30px;
        height: 30px;
        top: 10px;
        right: 10px;
    }
    
    .facts::before {
        animation-duration: 30s;
    }
    
    .facts::after {
        animation-duration: 20s;
        background-size: 60px 60px, 80px 80px, 50px 50px, 90px 90px;
    }
}

@media (max-width: 576px) {
    .stat-card {
        padding: 25px 10px;
    }
    
    .stat-card .display-4 {
        font-size: 2.5rem;
    }
    
    .stat-card .text-primary {
        font-size: 0.9rem;
        letter-spacing: 0.5px;
    }
    
    .stat-card::after {
        width: 25px;
        height: 25px;
    }
}


/*** Quote ***/
@media (min-width: 992px) {
    .container.quote {
        max-width: 100% !important;
    }

    .container.quote .quote-text {
        padding-left: calc(((100% - 960px) / 2) + .75rem);
    }

    .container.quote .quote-form {
        padding-right: calc(((100% - 960px) / 2) + .75rem);
    }
}

@media (min-width: 1200px) {
    .container.quote .quote-text  {
        padding-left: calc(((100% - 1140px) / 2) + .75rem);
    }

    .container.quote .quote-form  {
        padding-right: calc(((100% - 1140px) / 2) + .75rem);
    }
}

@media (min-width: 1400px) {
    .container.quote .quote-text  {
        padding-left: calc(((100% - 1320px) / 2) + .75rem);
    }

    .container.quote .quote-form  {
        padding-right: calc(((100% - 1320px) / 2) + .75rem);
    }
}

.container.quote .quote-text {
    background: rgba(1, 10, 53, .8);
}

.container.quote .quote-form {
    background: rgba(255, 255, 255, .8);
}

.container.quote .quote-text .h-100,
.container.quote .quote-form .h-100 {
    padding: 6rem 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
}


/*** Service ***/
.service-item {
    transition: var(--transition);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow-light);
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    position: relative;
    z-index: 1;
}

.service-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--gradient-primary);
    opacity: 0;
    transition: var(--transition);
    z-index: -1;
}

.service-item:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: var(--shadow-dark);
}

.service-item:hover::before {
    opacity: 0.1;
}

.service-item:hover .service-icon {
    transform: scale(1.1);
    background: rgba(255, 255, 255, 0.2);
}

.service-item:hover h4 {
    color: var(--primary);
}

.service-item .service-icon {
    width: 90px;
    height: 90px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    border-radius: 50%;
    background: rgba(255, 128, 15, 0.1);
}

.service-item .service-icon img {
    max-width: 60px;
    max-height: 60px;
    transition: var(--transition);
}

/* Modern card glassmorphism effects */
.bg-light {
    background: rgba(255, 255, 255, 0.9) !important;
    backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.card, .service-item, .testimonial-item {
    border-radius: var(--border-radius);
    transition: var(--transition);
}

.card:hover, .testimonial-item:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-medium);
}


/*** Team ***/
.team-item .team-img::before,
.team-item .team-img::after {
    position: absolute;
    content: "";
    width: 0;
    height: 100%;
    top: 0;
    left: 0;
    background: rgba(1, 10, 53, .8);
    transition: .5s;
}

.team-item .team-img::after {
    left: auto;
    right: 0;
}

.team-item:hover .team-img::before,
.team-item:hover .team-img::after {
    width: 50%;
}

.team-item .team-img .team-social {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: .5s;
    z-index: 3;
    opacity: 0;
}

.team-item:hover .team-img .team-social {
    transition-delay: .3s;
    opacity: 1;
}


/*** Testimonial ***/
.animated.pulse {
    animation-duration: 1.5s;
}

.testimonial-left,
.testimonial-right {
    position: relative;
}

.testimonial-left img,
.testimonial-right img {
    position: absolute;
    border-radius: 70px;
}

.testimonial-left img:nth-child(1),
.testimonial-right img:nth-child(3) {
    width: 70px;
    height: 70px;
    top: 10%;
    left: 50%;
    transform: translateX(-50%);
}

.testimonial-left img:nth-child(2),
.testimonial-right img:nth-child(2) {
    width: 60px;
    height: 60px;
    top: 50%;
    left: 10%;
    transform: translateY(-50%);
}

.testimonial-left img:nth-child(3),
.testimonial-right img:nth-child(1) {
    width: 50px;
    height: 50px;
    bottom: 10%;
    right: 10%;
}

.testimonial-carousel .owl-item img {
    width: 100px;
    height: 100px;
    border-radius: 100px;
}

.testimonial-carousel .owl-nav {
    margin-top: 30px;
    display: flex;
    justify-content: center;
}

.testimonial-carousel .owl-nav .owl-prev,
.testimonial-carousel .owl-nav .owl-next {
    margin: 0 5px;
    width: 45px;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #FFFFFF;
    background: var(--primary);
    border-radius: 45px;
    font-size: 22px;
    transition: .5s;
}

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


/*** Footer ***/
.footer {
    color: #7F8499;
}

.footer .btn.btn-link {
    display: block;
    margin-bottom: 5px;
    padding: 0;
    text-align: left;
    color: #7F8499;
    font-weight: normal;
    text-transform: capitalize;
    transition: .3s;
}

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

.footer .btn.btn-link:hover {
    color: var(--primary);
    letter-spacing: 1px;
    box-shadow: none;
}

.footer .btn.btn-square {
    color: #7F8499;
    border: 1px solid #7F8499;
}

.footer .btn.btn-square:hover {
    color: var(--light);
    border-color: var(--primary);
}

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

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

.footer .copyright a:hover {
    color: #FFFFFF;
}

/*** Modern Form Enhancements ***/
.form-control, .form-select {
    border-radius: var(--border-radius);
    border: 2px solid rgba(0, 16, 100, 0.1);
    transition: var(--transition);
    font-size: 16px;
    min-height: 50px;
    padding: 12px 20px;
    box-shadow: var(--shadow-light);
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
}

.form-control:focus, .form-select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(255, 128, 15, 0.1);
    background: rgba(255, 255, 255, 1);
    transform: scale(1.02);
}

.form-control:hover, .form-select:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow-medium);
}

.form-floating > label {
    color: #696E77;
    font-weight: 500;
    transition: var(--transition);
}

.form-floating > .form-control:focus ~ label {
    color: var(--primary);
    transform: scale(0.85) translateY(-0.75rem) translateX(0.15rem);
}

/* Enhanced textarea */
textarea.form-control {
    min-height: 120px;
    resize: vertical;
}

/* Mobile form optimizations */
@media (max-width: 768px) {
    .form-control, .form-select {
        font-size: 18px; /* Prevents zoom on iOS */
        min-height: 54px;
        padding: 15px 20px;
    }
    
    textarea.form-control {
        min-height: 140px;
    }
    
    .btn {
        min-height: 50px;
        padding: 15px 25px;
        font-size: 16px;
    }
}

/*** Loading Animation ***/
@keyframes shimmer {
    0% {
        background-position: -1000px 0;
    }
    100% {
        background-position: 1000px 0;
    }
}

.loading {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 1000px 100%;
    animation: shimmer 2s infinite;
}

/*** Scroll Animations ***/
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.animate-on-scroll {
    opacity: 0;
    transition: var(--transition);
}

.animate-on-scroll.in-view {
    opacity: 1;
    animation: fadeInUp 0.6s ease-out forwards;
}

/*** Enhanced Back to Top Button ***/
.back-to-top {
    background: var(--gradient-primary) !important;
    border: none !important;
    box-shadow: var(--shadow-medium);
    transition: var(--transition);
    backdrop-filter: blur(10px);
}

.back-to-top:hover {
    transform: translateY(-3px) scale(1.1);
    box-shadow: var(--shadow-dark);
    background: var(--gradient-secondary) !important;
}

/*** Modern Social Media Icons ***/
.btn-square {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: var(--transition);
    min-height: 44px;
    min-width: 44px;
}

.btn-square:hover {
    background: var(--gradient-primary);
    transform: translateY(-3px) scale(1.1);
    box-shadow: var(--shadow-medium);
}

/*** Improved Image Responsiveness ***/
.img-fluid {
    transition: var(--transition);
    border-radius: var(--border-radius);
}

.img-fluid:hover {
    transform: scale(1.05);
    box-shadow: var(--shadow-medium);
}

/* Touch-friendly improvements */
@media (max-width: 768px) {
    .btn-square, .btn-lg-square, .btn-sm-square {
        min-height: 44px;
        min-width: 44px;
    }
    
    .navbar .navbar-nav .nav-link {
        min-height: 50px;
        padding: 15px 20px;
        font-size: 18px;
    }
    
    /* Improved carousel controls for mobile */
    .carousel-control-prev, .carousel-control-next {
        width: 20%;
        opacity: 0.8;
    }
    
    .carousel-control-prev-icon,
    .carousel-control-next-icon {
        width: 2rem;
        height: 2rem;
    }
}

@media (max-width: 576px) {
    .carousel-caption h1 {
        font-size: 2.5rem;
    }

    .carousel-caption .btn {
        display: block;
        width: 100%;
        margin-bottom: 10px;
    }

    .carousel-caption .btn-secondary {
        margin-left: 0 !important;
    }
}

/*** Mobile Text Overflow Prevention ***/
.footer p {
    word-wrap: break-word;
    overflow-wrap: break-word;
}

/* Prevent email addresses and long text from causing horizontal overflow */
h5, p, small, span, .small {
    word-wrap: break-word;
    overflow-wrap: break-word;
    word-break: break-word;
}

/*** Contact Information Styling ***/
/* Topbar contact styling */
.topbar .d-inline-flex small {
    font-size: 14px;
    font-weight: 500;
    color: #ffffff;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

/* About section contact styling */
.border-top .d-flex.align-items-center {
    margin-bottom: 20px;
    padding: 15px;
    background: rgba(255, 128, 15, 0.05);
    border-radius: var(--border-radius);
    transition: var(--transition);
}

.border-top .d-flex.align-items-center:hover {
    background: rgba(255, 128, 15, 0.1);
    transform: translateX(5px);
}

.border-top .d-flex.align-items-center h5 {
    font-size: 16px;
    font-weight: 600;
    color: var(--dark);
    margin: 0;
    word-wrap: break-word;
    overflow-wrap: break-word;
    line-height: 1.4;
}

.border-top .btn-lg-square {
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--gradient-primary);
    box-shadow: var(--shadow-light);
    flex-shrink: 0;
}

/* Location section contact styling */
.bg-light .d-flex.align-items-start {
    margin-bottom: 15px;
    padding: 10px 0;
}

.bg-light .d-flex.align-items-start p {
    font-size: 15px;
    font-weight: 500;
    color: var(--dark);
    margin: 0;
    word-wrap: break-word;
    overflow-wrap: break-word;
    line-height: 1.5;
}

/* Service Areas Desktop Styling */
.bg-light .d-flex.align-items-center {
    padding: 8px 0;
    transition: var(--transition);
}

.bg-light .d-flex.align-items-center:hover {
    transform: translateX(3px);
}

.bg-light .d-flex.align-items-center i {
    color: var(--primary);
    font-size: 14px;
    margin-right: 10px;
}

.bg-light .d-flex.align-items-center span {
    font-size: 14px;
    font-weight: 500;
    color: var(--dark);
}

/* Footer contact styling */
.footer p {
    font-size: 14px;
    line-height: 1.6;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

/* Specific mobile optimizations for contact information */
@media (max-width: 768px) {
    /* Topbar - hidden on mobile by default */
    
    /* About section mobile fixes */
    .border-top .row {
        flex-direction: column;
        gap: 15px;
    }
    
    .border-top .d-flex.align-items-center {
        padding: 12px;
        margin-bottom: 15px;
    }
    
    .border-top .d-flex.align-items-center h5 {
        font-size: 14px;
        word-break: break-all;
        line-height: 1.3;
    }
    
    .border-top .btn-lg-square {
        width: 45px;
        height: 45px;
        margin-right: 12px;
    }
    
    /* Location section mobile fixes */
    .bg-light .d-flex.align-items-start {
        flex-direction: column;
        text-align: center;
        padding: 15px;
        background: rgba(255, 255, 255, 0.8);
        border-radius: var(--border-radius);
        margin-bottom: 20px;
    }
    
    .bg-light .d-flex.align-items-start i {
        margin-bottom: 8px;
        font-size: 18px;
        color: var(--primary);
    }
    
    .bg-light .d-flex.align-items-start p {
        font-size: 14px;
        word-break: break-all;
        text-align: center;
    }
    
    /* Footer mobile fixes */
    .footer p {
        font-size: 13px;
        word-break: break-all;
        text-align: center;
    }
    
    .footer p i {
        display: block;
        margin-bottom: 5px;
        font-size: 16px;
        color: var(--primary);
    }
    
    /* General container overflow prevention */
    .container-fluid, .container, .row, .col-md-6, .col-lg-6, .col-sm-6 {
        overflow-x: hidden;
        max-width: 100%;
    }
}

/*** Service Areas Mobile Optimization ***/
@media (max-width: 768px) {
    /* Service Areas Section */
    .bg-light .row.g-3 {
        gap: 10px !important;
    }
    
    .bg-light .col-6 {
        flex: 0 0 100%;
        max-width: 100%;
        margin-bottom: 12px;
    }
    
    .bg-light .d-flex.align-items-center {
        padding: 12px 15px;
        background: rgba(255, 128, 15, 0.05);
        border-radius: var(--border-radius);
        border-left: 3px solid var(--primary);
        transition: var(--transition);
        margin-bottom: 8px;
    }
    
    .bg-light .d-flex.align-items-center:hover {
        background: rgba(255, 128, 15, 0.1);
        transform: translateX(5px);
        box-shadow: var(--shadow-light);
    }
    
    .bg-light .d-flex.align-items-center i {
        font-size: 16px;
        color: var(--primary);
        margin-right: 12px;
        flex-shrink: 0;
    }
    
    .bg-light .d-flex.align-items-center span {
        font-size: 15px;
        font-weight: 500;
        color: var(--dark);
    }
    
    /* Location section mobile improvements */
    .container-xxl .row.g-5 {
        gap: 30px !important;
    }
    
    .bg-light {
        padding: 25px !important;
        margin-bottom: 20px;
    }
    
    .bg-light h3 {
        font-size: 1.5rem;
        margin-bottom: 20px;
        color: var(--dark);
        border-bottom: 2px solid var(--primary);
        padding-bottom: 10px;
    }
    
    .bg-light .mt-4 p {
        text-align: center;
        font-style: italic;
        color: var(--text-secondary);
        margin-top: 20px;
        padding-top: 15px;
        border-top: 1px solid rgba(255, 128, 15, 0.2);
    }
}

@media (max-width: 576px) {
    .bg-light {
        padding: 20px !important;
    }
    
    .bg-light .d-flex.align-items-center {
        padding: 10px 12px;
    }
    
    .bg-light .d-flex.align-items-center span {
        font-size: 14px;
    }
    
    .bg-light h3 {
        font-size: 1.3rem;
    }
}

@media (max-width: 576px) {
    .border-top .d-flex.align-items-center h5 {
        font-size: 13px;
    }
    
    .bg-light .d-flex.align-items-start p {
        font-size: 13px;
    }
    
    .footer p {
        font-size: 12px;
    }
}