/* Global Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Arial', sans-serif;
    color: #333;
    line-height: 1.6;
}

/* Header */
header {
    background: skyblue;
    color: white;
    height: 80px;
    padding: 0.1rem 0;
    position: sticky;
    top: 0;
    z-index: 1000;
}

header .container {
    margin-top: -20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

header h1 {
    margin-left: 20px;
    color: white;
}

/* Navigation Styles */
header nav ul {
    list-style: none;
    display: flex;
    margin-right: 20px;
}

header nav ul li {
    margin-right: 20px;
}

header nav ul li a {
    color: white;
    text-decoration: none;
    font-size: 18px;
    transition: color 0.3s ease;
}

header nav ul li a:hover {
    color: #f90;
}

/* Hamburger Menu */
.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    margin-right: 20px;
}

.hamburger span {
    height: 3px;
    width: 25px;
    background: white;
    margin: 3px 0;
    transition: 0.3s;
}

/* Hero Section */
.hero {
    height: 50vh;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    color: #002366;
    padding: 50px;
}

.hero h2 {
    font-size: 20px;
    margin-bottom: 1rem;
    animation: fadeIn 1.5s ease-out;
}

.hero .btn {
    position: absolute;
    margin-top: 200px;
    padding: 10px 20px;
    background: #f90;
    color: white;
    border: none;
    cursor: pointer;
    transition: background 0.3s ease;
}

.hero .btn:hover {
    background: #e68a00;
}

@keyframes fadeIn {
    0% { opacity: 0; transform: translateY(-50px); }
    100% { opacity: 1; transform: translateY(0); }
}

/* About Section */
.about-section {
    display: flex;
    margin-left: 20px;
    align-items: center;
    justify-content: space-between;
    padding: 50px 0;
}

.about-section .about-content {
    width: 50%;
}

.about-section .about-content h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.about-section .about-content p {
    font-size: 1.2rem;
    margin-bottom: 1.5rem;
}

.about-section .about-content .btn {
    padding: 10px 20px;
    background: #f90;
    color: white;
    text-decoration: none;
    transition: background 0.3s ease;
}

.about-section .about-content .btn:hover {
    background: #e68a00;
}

.about-section .about-img {
    width: 35%;
    height: 400px;
    background-size: cover;
    background-position: center;
    border-radius: 10px;
    animation: about 60s infinite ease-in-out; /* Extended duration and added easing */
    transition: background-image 0.5s ease-in-out; /* Smooth background transition */
}

@keyframes about {
    0% { background-image: url('/assets/hallow.jpeg'); opacity: 1; }
    8% { background-image: url('/assets/1.jpeg'); opacity: 0.8; }
    16% { background-image: url('/assets/2.jpeg'); opacity: 0.6; }
    24% { background-image: url('/assets/3.jpeg'); opacity: 0.8; }
    32% { background-image: url('/assets/4.jpeg'); opacity: 1; }
    40% { background-image: url('/assets/5.jpeg'); opacity: 0.8; }
    48% { background-image: url('/assets/6.jpeg'); opacity: 0.6; }
    56% { background-image: url('/assets/7.jpeg'); opacity: 0.8; }
    64% { background-image: url('/assets/8.jpeg'); opacity: 1; }
    72% { background-image: url('/assets/9.jpeg'); opacity: 0.8; }
    80% { background-image: url('/assets/10.jpeg'); opacity: 0.6; }
    88% { background-image: url('/assets/11.jpeg'); opacity: 0.8; }
    94% { background-image: url('/assets/12.jpeg'); opacity: 1; }
    100% { background-image: url('/assets/hallow.jpeg'); opacity: 1; }
}

/* Services Section */
.services-section {
    background: #f9f9f9;
    padding: 50px 0;
    text-align: center;
}

.services-section h2 {
    font-size: 2.5rem;
    margin-bottom: 2rem;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.service {
    background: #333;
    color: white;
    padding: 20px;
    border-radius: 10px;
    text-align: center;
}

.service i {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.service h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.service p {
    font-size: 1rem;
}

/* Portfolio Section */
.portfolio-section {
    padding: 50px 0;
}

.portfolio-section h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 2rem;
}

.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
}

.portfolio-item {
    position: relative;
    overflow: hidden;
    border-radius: 10px;
}

.portfolio-item img {
    width: 100%;
    transition: transform 0.3s ease;
}

.portfolio-item:hover img {
    transform: scale(1.1);
}

.portfolio-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    color: white;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.portfolio-item:hover .portfolio-overlay {
    opacity: 1;
}

/* Contact Section */
.contact-section {
    padding: 50px 0;
    text-align: center;
}

.contact-section h2 {
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
}

/* Footer */
footer {
    background: #333;
    color: white;
    text-align: center;
    padding: 1rem 0;
}

/* Responsive Styles */
@media (max-width: 768px) {
    .about-section {
        flex-direction: column;
        align-items: center;
        padding: 20px;
    }

    .about-section .about-content,
    .about-section .about-img {
        width: 100%;
        text-align: center;
    }

    .about-section .about-content {
        margin-bottom: 20px;
    }

    .services-grid {
        grid-template-columns: 1fr;
    }

    .portfolio-grid {
        grid-template-columns: 1fr;
    }

    .hero {
        height: auto;
        padding: 50px 20px;
    }

    .hero h2 {
        font-size: 1.5rem;
    }

    .hero .btn {
        margin-top: 200px;
        position: absolute;
    }

    /* Hamburger Menu - when navigation is hidden */
header nav ul {
    display: none;
    flex-direction: column;
    position: fixed; /* Change to fixed to make sure it fills the viewport */
    top: 80px;
    left: 0;
    right: 0;
    background: #333;
    padding: 0.6rem 0;
    z-index: 1000;
    width: 100%; /* Ensure the background takes full width */
}

/* When hamburger menu is active */
header nav ul.active {
    display: flex; /* Show the navigation when active */
}


    header nav ul.active {
        display: flex;
    }

    header nav ul li {
        margin: 10px 0;
    }
    header nav ul li a{
        margin: 10px 0;
        margin-left: 45%;
    }

    .hamburger {
        display: flex;
    }

    .hamburger.active span:nth-child(1) {
        transform: rotate(45deg) translate(5px, 5px);
    }

    .hamburger.active span:nth-child(2) {
        opacity: 0;
    }

    .hamburger.active span:nth-child(3) {
        transform: rotate(-45deg) translate(5px, -5px);
    }
}

/* For extra small screens below 576px */
@media (max-width: 576px) {
    .about-section {
        padding: 10px;
    }

    .hero h2 {
        font-size: 1.2rem;
    }

    .hero .btn {
        padding: 8px 16px;
    }

    .services-grid, .portfolio-grid {
        gap: 1rem;
    }
}
