/* General Styles */
:root {
    --primary-color: #0056b3;
    --secondary-color: #003366;
    --accent-color: #1e88e5;
    --light-color: #f8f9fa;
    --dark-color: #343a40;
    --text-color: #333;
    --gray-color: #6c757d;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    margin: 0;
    padding: 0;
    color: var(--text-color);
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
}

a {
    text-decoration: none;
    transition: all 0.3s ease;
}

.btn {
    padding: 0.6rem 1.5rem;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.btn-primary {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

.btn-primary:hover {
    background-color: var(--secondary-color);
    border-color: var(--secondary-color);
}

.btn-outline-light:hover {
    color: var(--primary-color);
}

.section-header {
    margin-bottom: 50px;
}

.section-header h2 {
    font-size: 2.5rem;
    font-weight: 700;
    position: relative;
    margin-bottom: 20px;
}

.section-header h2::after {
    content: '';
    position: absolute;
    width: 60px;
    height: 3px;
    background-color: var(--primary-color);
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
}

.section-subheading {
    font-size: 1.1rem;
    color: var(--gray-color);
}

/* Navigation */
#mainNav {
    background-color: rgba(0, 0, 0, 0.7);
    transition: all 0.3s ease;
    padding: 10px 0;
    z-index: 1000;
    position: relative;
}

#mainNav.navbar-shrink {
    padding-top: 5px;
    padding-bottom: 5px;
    background-color: rgba(0, 0, 0, 0.9);
}

.logo-img {
    height: 60px;
    width: auto;
    filter: brightness(1.5);
}

.navbar-dark .navbar-nav .nav-link {
    color: rgba(255, 255, 255, 0.85);
    padding: 0.75rem 1rem;
    font-weight: 500;
}

.navbar-dark .navbar-nav .nav-link:hover,
.navbar-dark .navbar-nav .nav-link:focus {
    color: #fff;
}

/* Hero Section */
.hero-section {
    background: linear-gradient(135deg, #00223E, #0056b3);
    height: 100vh;
    min-height: 600px;
    position: relative;
    display: flex;
    align-items: center;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('assets/banner.png');
    background-size: cover;
    opacity: 0.15;
}

.hero-section h1 {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 20px;
}

.hero-section p {
    font-size: 1.25rem;
    margin-bottom: 30px;
}

.hero-image {
    max-height: 400px;
    filter: drop-shadow(0 5px 10px rgba(0,0,0,0.2));
}

.hero-buttons {
    margin-top: 30px;
}

/* Services Section */
.service-card {
    background-color: #fff;
    border-radius: 10px;
    padding: 30px 20px;
    height: 100%;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    position: relative;
    overflow: hidden;
    z-index: 1;
    margin-bottom: 20px;
}

.service-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.1);
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(30,136,229,0.1), rgba(0,86,179,0.1));
    z-index: -1;
    opacity: 0;
    transition: all 0.3s ease;
}

.service-card:hover::before {
    opacity: 1;
}

.service-icon {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 20px;
}

.service-card h3 {
    font-size: 1.5rem;
    margin-bottom: 15px;
    color: var(--dark-color);
}

.service-card p {
    margin-bottom: 20px;
    color: var(--gray-color);
}

.service-card ul {
    padding-left: 20px;
    color: var(--gray-color);
}

.service-card ul li {
    margin-bottom: 5px;
}

/* About Section */
.about-image {
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

.icon-box {
    background-color: var(--primary-color);
    color: white;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    flex-shrink: 0;
}

.feature-box {
    padding: 20px;
    border-radius: 10px;
    transition: all 0.3s ease;
    background: #fff;
    height: 100%;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

.feature-box:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.1);
}

.feature-icon {
    font-size: 2rem;
    color: var(--primary-color);
    margin-bottom: 15px;
}

.feature-box h4 {
    font-size: 1.2rem;
    margin-bottom: 10px;
}

/* Portfolio Section */
.portfolio-item {
    position: relative;
    overflow: hidden;
    border-radius: 10px;
    margin-bottom: 30px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.portfolio-item img {
    width: 100%;
    height: 250px;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.portfolio-item:hover img {
    transform: scale(1.1);
}

.portfolio-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
    overflow: hidden;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: 0.5s ease;
    display: flex;
    align-items: flex-end;
}

.portfolio-item:hover .portfolio-overlay {
    opacity: 1;
}

.portfolio-info {
    color: white;
    padding: 20px;
    width: 100%;
}

.portfolio-info h4 {
    margin-bottom: 5px;
}

.portfolio-btn:hover {
    background-color: white;
    color: var(--dark-color);
}

/* Stats Section */
.stats-section {
    background: linear-gradient(135deg, #00223E, #0056b3);
    padding: 80px 0;
    position: relative;
    overflow: hidden;
}

.stats-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('https://img.freepik.com/free-vector/abstract-technology-particle-background_52683-25766.jpg');
    background-size: cover;
    opacity: 0.15;
}

.stat-item {
    position: relative;
    z-index: 1;
}

.stat-item h2 {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 10px;
    color: white;
}

.stat-item p {
    font-size: 1.1rem;
    color: rgba(255, 255, 255, 0.8);
}

/* Testimonials */
.testimonial-card {
    background: #fff;
    border-radius: 10px;
    padding: 30px;
    height: 100%;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    transition: all 0.3s ease;
}

.testimonial-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.1);
}

.testimonial-content {
    position: relative;
}

.testimonial-content p {
    font-style: italic;
    color: var(--gray-color);
}

.testimonial-content p::before {
    content: '\201C';
    font-size: 4rem;
    position: absolute;
    left: -20px;
    top: -30px;
    color: rgba(0,86,179,0.1);
    font-family: Georgia, serif;
}

.testimonial-author img {
    width: 50px;
    height: 50px;
    object-fit: cover;
}

/* Contact Section */
.contact-info {
    padding: 30px;
    border-radius: 10px;
    background-color: #fff;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    height: 100%;
}

.contact-icon {
    background-color: var(--light-color);
    color: var(--primary-color);
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    flex-shrink: 0;
    font-size: 1rem;
}

.contact-form {
    padding: 10px;
    border-radius: 10px;
    background-color: #fff;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    height: 100%;
}

.form-control {
    border-radius: 4px;
    padding: 0.6rem 1rem;
    border: 1px solid #ddd;
}

.form-control:focus {
    box-shadow: 0 0 0 0.2rem rgba(0,86,179,0.25);
    border-color: var(--primary-color);
}

.social-links {
    display: flex;
}

.social-icon {
    background-color: var(--light-color);
    color: var(--primary-color);
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    margin-right: 10px;
    transition: all 0.3s ease;
}

.social-icon:hover {
    background-color: var(--primary-color);
    color: white;
}

.google-map {
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

/* Call to Action */
.cta-section {
    background: linear-gradient(135deg, #00223E, #0056b3);
    padding: 80px 0;
    position: relative;
    overflow: hidden;
}

.cta-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('https://img.freepik.com/free-vector/abstract-technology-particle-background_52683-25766.jpg');
    background-size: cover;
    opacity: 0.15;
}

.cta-section h2, .cta-section p {
    position: relative;
    z-index: 1;
}

/* Footer */
.footer {
    position: relative;
}

.footer-logo {
    height: 70px;
    width: auto;
    filter: brightness(1.5);
}

.footer-links {
    list-style: none;
    padding: 0;
}

.footer-links li {
    margin-bottom: 10px;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.7);
}

.footer-links a:hover {
    color: #fff;
}

.newsletter-form .input-group {
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    overflow: hidden;
}

.newsletter-form .form-control {
    border: none;
    background-color: transparent;
    color: white;
}

.newsletter-form .form-control::placeholder {
    color: rgba(255, 255, 255, 0.6);
}

/* Team Section Styles */
.team-slider {
    display: flex;
    scroll-snap-type: x mandatory;
    gap: 2rem;
    padding: 20px 50px;
    padding-bottom: 2rem;
}
.team-member {
    flex: 0 0 300px;
    background: #fff;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    padding: 15px;
    margin: 10px;
    scroll-snap-align: start;
    transition: transform 0.3s ease;
}
.team-member:hover {
    transform: translateY(-10px) scale(1.03);
    box-shadow: 0 15px 30px rgba(0,0,0,0.1);
}
.team-member img {
    width: 140px;
    height: 140px;
    object-fit: cover;
    border-radius: 50%;
    margin: 0 auto 15px;
    border: 4px solid var(--primary-color);
    transition: border-color 0.3s ease;
    display: block;
}
.team-member:hover img {
    border-color: var(--accent-color);
}
.team-member h5 {
    margin-bottom: 5px;
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--secondary-color);
}
.team-member p {
    color: var(--gray-color);
    font-size: 1rem;
    margin-bottom: 0;
}
@media (max-width: 767px) {
    .team-slider {
        gap: 1rem;
        padding: 10px;
    }
    .team-member {
        flex: 0 0 220px;
        padding: 10px;
    }
    .team-member img {
        width: 90px;
        height: 90px;
    }
}

/* Media Queries */
@media (max-width: 991px) {
    .hero-section {
        height: auto;
        padding: 120px 0 80px;
    }
    
    .hero-section h1 {
        font-size: 2.5rem;
    }
}

@media (max-width: 767px) {
    .section-header h2 {
        font-size: 2rem;
    }
    
    .hero-section h1 {
        font-size: 2rem;
    }
    
    .hero-buttons .btn {
        display: block;
        width: 100%;
        margin-bottom: 10px;
    }
    
    .hero-buttons .btn + .btn {
        margin-left: 0 !important;
    }
}

/* Slick Carousel Arrow Customization for Team Slider */
.team-slider .slick-arrow {
    position: absolute;
    top: 50%;
    z-index: 2;
    width: 48px;
    height: 48px;
    background: var(--primary-color);
    color: #fff;
    border: none;
    border-radius: 50%;
    transform: translateY(-50%);
    font-size: 2rem;
    opacity: 0.85;
    transition: background 0.2s, opacity 0.2s;
    box-shadow: 0 2px 8px rgba(0,0,0,0.12);
}
.team-slider .slick-arrow:hover {
    background: var(--accent-color);
    opacity: 1;
}
.team-slider .slick-prev {
    left: 0;
}
.team-slider .slick-next {
    right: 0;
}
.team-slider {
    position: relative; /* Ensure arrows are positioned relative to slider */
}

/* Hide default Slick arrow text and use only icons */
.team-slider .slick-prev:before,
.team-slider .slick-next:before {
    font-family: 'slick';
    font-size: 32px;
    line-height: 1;
    opacity: 1;
    color: #fff;
}

.team-slider .slick-prev:before {
    content: '←';
}

.team-slider .slick-next:before {
    content: '→';
}

/* Hide the actual button text */
.team-slider .slick-prev,
.team-slider .slick-next {
    font-size: 0 !important;
}

/* Popup Contact Form Styles */
.contact-popup {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.7);
    background: white;
    border-radius: 15px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    z-index: 9999;
    max-width: 400px;
    width: 85%;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    border: 2px solid var(--primary-color);
    max-height: 90vh; /* Prevent overflow on small screens */
    overflow-y: auto; /* Allow scrolling if needed */
}

.contact-popup.show {
    opacity: 1;
    visibility: visible;
    transform: translate(-50%, -50%) scale(1);
}

.contact-popup-content {
    padding: 25px;
    position: relative; /* For close button positioning */
}

.contact-popup-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid var(--light-color);
    position: relative;
}

.contact-popup-header h3 {
    color: var(--primary-color);
    margin: 0;
    font-size: 1.3rem;
    font-weight: 600;
    flex: 1; /* Take available space */
    margin-right: 20px; /* Space for close button */
}

.close-popup {
    background: var(--primary-color);
    border: none;
    font-size: 1.2rem;
    color: white;
    cursor: pointer;
    padding: 8px;
    border-radius: 50%;
    width: 35px;
    height: 35px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    position: absolute;
    top: -5px;
    right: -5px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    z-index: 10; /* Ensure it's above other elements */
}

.close-popup:hover {
    background-color: var(--secondary-color);
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.contact-form .form-group {
    margin-bottom: 15px;
    opacity: 1;
    transform: translateY(0);
}

.contact-form label {
    display: block;
    margin-bottom: 6px;
    font-weight: 600;
    color: var(--dark-color);
    font-size: 0.9rem;
}

.contact-form .form-control {
    width: 100%;
    padding: 10px 12px;
    border: 2px solid #e9ecef;
    border-radius: 6px;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    background-color: #fff;
    box-sizing: border-box;
}

.contact-form .form-control:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(0, 86, 179, 0.1);
    transform: translateY(-1px);
}

.contact-form .form-control:hover {
    border-color: var(--accent-color);
}

.contact-form .form-control::placeholder {
    color: #adb5bd;
    opacity: 0.7;
}

.contact-form textarea.form-control {
    resize: vertical;
    min-height: 80px;
}

.contact-form .btn {
    padding: 12px 18px;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 6px;
    transition: all 0.3s ease;
    margin-top: 8px;
    cursor: pointer;
    width: 100%; /* Full width on all devices */
}

.contact-form .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 86, 179, 0.3);
}

.contact-form .btn:active {
    transform: translateY(0);
}

.contact-form .btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}

.popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    z-index: 9998;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    backdrop-filter: blur(5px);
    pointer-events: none; /* Make overlay non-clickable */
}

.popup-overlay.show {
    opacity: 1;
    visibility: visible;
    pointer-events: none; /* Keep overlay non-clickable even when visible */
}

.form-message {
    margin-top: 20px;
    opacity: 0;
    transform: translateY(10px);
    transition: all 0.3s ease;
}

.form-message.show {
    opacity: 1;
    transform: translateY(0);
}

.form-message .alert {
    border-radius: 8px;
    border: none;
    padding: 15px 20px;
    font-weight: 500;
}

.form-message .alert-success {
    background-color: #d4edda;
    color: #155724;
    border-left: 4px solid #28a745;
}

.form-message .alert-danger {
    background-color: #f8d7da;
    color: #721c24;
    border-left: 4px solid #dc3545;
}

/* Responsive Design for Popup */
@media (max-width: 768px) {
    .contact-popup {
        width: 90%;
        margin: 15px;
        max-width: 350px;
        top: 45%; /* Adjust position for mobile */
    }
    
    .contact-popup-content {
        padding: 20px 15px;
    }
    
    .contact-popup-header h3 {
        font-size: 1.2rem;
        margin-right: 40px; /* Make space for close button */
    }
    
    .contact-form .btn {
        padding: 12px 16px;
        font-size: 0.95rem;
    }
    
    .contact-form .form-group {
        margin-bottom: 12px;
    }
    
    .contact-form label {
        font-size: 0.85rem;
        margin-bottom: 5px;
    }
    
    .contact-form .form-control {
        padding: 8px 10px;
        font-size: 0.9rem;
    }
    
    .contact-form textarea.form-control {
        min-height: 70px;
    }
}

@media (max-width: 480px) {
    .contact-popup {
        width: 95%;
        margin: 10px;
        max-width: 320px;
        top: 40%; /* Better position for small mobile */
    }
    
    .contact-popup-content {
        padding: 15px 12px;
    }
    
    .contact-popup-header {
        flex-direction: column;
        text-align: center;
        gap: 15px;
        margin-bottom: 15px;
    }
    
    .contact-popup-header h3 {
        font-size: 1.1rem;
        margin-right: 0;
    }
    
    .close-popup {
        position: absolute;
        top: -5px;
        right: -5px;
        width: 30px;
        height: 30px;
        font-size: 1rem;
    }
    
    .contact-form .form-group {
        margin-bottom: 10px;
    }
    
    .contact-form label {
        font-size: 0.8rem;
        margin-bottom: 4px;
    }
    
    .contact-form .form-control {
        padding: 7px 8px;
        font-size: 0.85rem;
        border-radius: 4px;
    }
    
    .contact-form textarea.form-control {
        min-height: 60px;
    }
    
    .contact-form .btn {
        padding: 10px 14px;
        font-size: 0.9rem;
        margin-top: 6px;
    }
}

@media (max-width: 360px) {
    .contact-popup {
        width: 98%;
        margin: 5px;
        max-width: 300px;
        top: 35%;
    }
    
    .contact-popup-content {
        padding: 12px 10px;
    }
    
    .contact-popup-header h3 {
        font-size: 1rem;
    }
    
    .contact-form .form-group {
        margin-bottom: 8px;
    }
    
    .contact-form label {
        font-size: 0.75rem;
    }
    
    .contact-form .form-control {
        padding: 6px 7px;
        font-size: 0.8rem;
    }
    
    .contact-form textarea.form-control {
        min-height: 50px;
    }
    
    .contact-form .btn {
        padding: 8px 12px;
        font-size: 0.85rem;
    }
}

/* Landscape orientation for mobile devices */
@media (max-height: 500px) and (orientation: landscape) {
    .contact-popup {
        top: 50%;
        max-height: 90vh;
        overflow-y: auto;
    }
    
    .contact-popup-content {
        padding: 15px;
    }
    
    .contact-form .form-group {
        margin-bottom: 8px;
    }
    
    .contact-form textarea.form-control {
        min-height: 50px;
    }
}

/* High DPI displays */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    .contact-popup {
        border-width: 1px; /* Thinner border for retina displays */
    }
    
    .close-popup {
        box-shadow: 0 1px 4px rgba(0, 0, 0, 0.2);
    }
}

/* Loading spinner animation */
@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.fa-spin {
    animation: spin 1s linear infinite;
}