:root {
    --primary: #d22525;
    --secondary: #000000;
    --accent: #ffefef;
    --bg: #f6f8fa;
    --text: #222;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: 'Segoe UI', Arial, sans-serif;
    background: var(--bg);
    color: var(--text);
}

header {
    background-color: #000000;
   /* background: linear-gradient(135deg, black, #ffffff 200%); */
    color: #fff;
    position: relative; /* Allow scrolling */
    top: 0;
    z-index: 1000;
}

nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.2em 2em 0.5em 2em;
    max-width: 1200px;
    margin: 0 auto;
}

.logo {
    display: flex;
    align-items: center;
    height: 80px;
}

.logo img {
    height: 200px;
    width: auto;
    border-radius: 8px;
    display: block;
}

nav ul {
    list-style: none;
    display: flex;
    gap: 2em;
    margin: 0;
    padding: 0;
    
}

nav a {
    text-decoration: none;
    color: #fff;
    font-weight: 500;
    position: relative;
    transition: color 0.2s;
}

nav a.active,
nav a:hover {
    color: var(--accent);
}

.hero {
    text-align: center;
    padding: 4em 1em 3em 1em;
}

.hero h1 {
    font-size: 3em;
    margin-bottom: 0.3em;
}

.hero p {
    font-size: 1.4em;
    margin-bottom: 1.2em;
}

.cta-btn {
    background: var(--accent);
    color: var(--secondary);
    padding: 0.8em 2em;
    border: none;
    border-radius: 25px;
    font-size: 1.2em;
    font-weight: bold;
    text-decoration: none;
    cursor: pointer;
    transition: background 0.2s;
    display: inline-block;
}

.cta-btn:hover {
    background: #ff6666;
}

main {
    max-width: 1100px;
    margin: 0 auto;
    padding: 2em 1em;
}

.services {
    margin-bottom: 3em;
}

.services h2 {
    text-align: center;
    font-size: 2.2em;
    margin-bottom: 1.2em;
}

.service-group {
    margin-bottom: 2.5em;
}

.service-section-title {
    font-size: 1.4em;
    color: var(--primary);
    margin-bottom: 1em;
    text-align: left;
    padding-left: 8px;
    border-left: 4px solid var(--primary);
    margin-top: 1em;
}

.service-list {
    display: flex;
    flex-wrap: wrap;
    gap: 2em;
    justify-content: center;
}

.service-card {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(30, 144, 255, 0.06);
    padding: 1.5em;
    max-width: 320px;
    text-align: center;
    transition: box-shadow 0.2s;
    width: 100%; /* Ensure cards don't exceed the screen width */
}

.service-card img {
    width: 100%;
    height: 170px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 1em;
}

.service-card h4 {
    margin: 0.5em 0 0.6em 0;
    color: var(--primary);
}

.portfolio {
    margin-bottom: 3em;
}

.portfolio-intro {
    text-align: center;
    margin-bottom: 1em;
    color: #555;
}

.portfolio-gallery {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5em;
    justify-content: center;
}

.portfolio h2 {
    text-align: center;
    font-size: 2.2em;
    margin-bottom: 1.2em;
}

.portfolio-item {
    background: #fff;
    border-radius: 10px;
    box-shadow: 0 2px 12px rgba(30, 144, 255, 0.07);
    overflow: hidden;
    width: 220px;
    margin-bottom: 0.7em;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.portfolio-item img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    display: block;
}

.portfolio-caption {
    padding: 0.6em 1em;
    font-size: 1em;
    width: 100%;
    text-align: center;
    color: var(--primary);
    font-weight: 500;
}

.contact {
    background: #fff;
    border-radius: 12px;
    padding: 2em;
    box-shadow: 0 2px 12px rgba(30, 144, 255, 0.04);
    margin-top: 2em;
    display: flex;
    flex-wrap: wrap;
    gap: 2em;
    justify-content: center;
}

.contact-info {
    flex: 1 1 200px;
    min-width: 220px;
    max-width: 300px;
    align-self: flex-start;
    font-size: 1.07em;
}

.only-contact {
    margin: 0 auto;
    text-align: center;
}

footer {
    text-align: center;
    padding: 1.5em 0 1.2em 0;
    background: #e9f3fc;
    font-size: 1em;
    color: #555;
    margin-top: 3em;
    border-top: 1px solid #e4e4e4;
}

/* Hide the menu by default on smaller screens */
.nav-links {
    display: none;
    flex-direction: column;
    gap: 1em;
    background: var(--primary);
    padding: 1em;
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    z-index: 1000;
}

/* Show the menu toggle button on smaller screens */
.menu-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.5em;
    color: #fff;
    cursor: pointer;
}

/* Show nav-links when active on mobile */
.nav-links.active {
    display: flex;
}

/* Ensure nav-links are properly spaced on desktop */
@media (min-width: 901px) {
    nav {
        display: flex;
        align-items: center; /* Vertically align items */
    }

    .logo {
        margin-right: 0; /* Keep the logo on the far left */
    }

    .nav-links {
        display: flex; /* Show the menu on larger screens */
        flex-direction: row;
        gap: 2em; /* Add spacing between links */
        position: static; /* Reset position for desktop */
        background: none; /* Remove background for desktop */
        padding: 0; /* Remove padding for desktop */
        margin-left: 50%; /* Push the nav-links to the far right */
    }

    .menu-toggle {
        display: none; /* Hide the hamburger menu on larger screens */
    }
}

/* Responsive adjustments for smaller screens */
@media (max-width: 900px) {
    .menu-toggle {
        display: block;
    }

    .hero h1 {
        font-size: 2em;
    }

    .hero p {
        font-size: 1em;
    }

    .cta-btn {
        padding: 0.6em 1.5em;
        font-size: 1em;
    }

    .portfolio-item {
        width: 90%; /* Ensure portfolio items fit within the screen */
        max-width: 280px;
    }
}