/* General Styles */
:root {
    --primary-color: #0d0d0d; /* Dark background */
    --secondary-color: #1a1a1a; /* Slightly lighter dark for sections */
    --accent-color: #00bcd4; /* Metallic blue for highlights */
    --text-color: #e0e0e0; /* Light text on dark background */
    --light-text-color: #a0a0a0; /* Lighter text for subtle info */
    --border-color: #333;
    --button-bg: var(--accent-color);
    --button-text: #ffffff;
    --error-color: #ff6b6b;
    --max-width: 1200px;
    --spacing-unit: 20px;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Montserrat', sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--primary-color);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 var(--spacing-unit);
}

a {
    color: var(--accent-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: #4dd0e1; /* Lighter accent on hover */
}

ul {
    list-style: none;
}

h1, h2, h3, h4 {
    font-family: 'Montserrat', sans-serif;
    font-weight: 600;
    margin-bottom: var(--spacing-unit);
    color: #ffffff;
}

h1 { font-size: 3.2em; font-weight: 300; line-height: 1.2; }
h2 { font-size: 2.5em; font-weight: 600; }
h3 { font-size: 1.8em; font-weight: 400; }
h4 { font-size: 1.4em; font-weight: 400; }

p {
    margin-bottom: var(--spacing-unit);
    font-family: 'Roboto', sans-serif;
    font-weight: 300;
}

.section {
    padding: 80px 0;
    text-align: center;
}

.section-title {
    margin-bottom: 60px;
    position: relative;
    display: inline-block;
    padding-bottom: 10px;
}

.section-title::after {
    content: '';
    position: absolute;
    left: 50%;
    bottom: 0;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background-color: var(--accent-color);
}

/* Header */
.header {
    background-color: var(--primary-color);
    padding: var(--spacing-unit) 0;
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo a {
    font-size: 1.8em;
    font-weight: 600;
    color: #ffffff;
    letter-spacing: 1px;
}

.nav-list {
    display: flex;
}

.nav-list li {
    margin-left: 40px;
}

.nav-list a {
    color: var(--light-text-color);
    font-weight: 400;
    font-size: 1.1em;
    position: relative;
    padding-bottom: 5px;
}

.nav-list a::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 0;
    height: 2px;
    background-color: var(--accent-color);
    transition: width 0.3s ease;
}

.nav-list a:hover::after {
    width: 100%;
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--text-color);
    font-size: 1.8em;
    cursor: pointer;
}

/* Hero Section */
.hero {
    background: linear-gradient(rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.7)), url('https://images.unsplash.com/photo-1507679799977-c33a9257d27e?crop=entropy&cs=tinysrgb&fit=max&fm=jpg&ixid=MnwzNjVseDF8MHwxfHNlYXJjaHw0fHxjb29sJTIwb2ZmaWNlJTIwaW50ZXJpb3J8ZW58MHx8fHwxNzIwOTQ1OTY2&ixlib=rb-4.0.3&q=80&w=1080') no-repeat center center/cover;
    min-height: 70vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: #ffffff;
    padding: 0 var(--spacing-unit);
}

.hero-content {
    max-width: 800px;
}

.hero-content h1 {
    font-size: 3.8em;
    margin-bottom: var(--spacing-unit);
    font-weight: 300;
    letter-spacing: 1px;
}

.hero-content p {
    font-size: 1.3em;
    margin-bottom: 40px;
    font-weight: 300;
    color: var(--light-text-color);
}

.cta-button {
    display: inline-block;
    background-color: var(--button-bg);
    color: var(--button-text);
    padding: 15px 35px;
    border-radius: 5px;
    font-size: 1.1em;
    font-weight: 600;
    transition: background-color 0.3s ease, transform 0.3s ease;
    border: none;
    cursor: pointer;
}

.cta-button:hover {
    background-color: #4dd0e1; /* Lighter accent on hover */
    transform: translateY(-3px);
}

/* About Section */
.about-section {
    background-color: var(--secondary-color);
}

.about-grid {
    display: flex;
    align-items: center;
    gap: 60px;
    text-align: left;
    max-width: 1000px;
    margin: 0 auto;
}

.about-text {
    flex: 1;
}

.about-text h3 {
    color: var(--accent-color);
    margin-bottom: var(--spacing-unit);
}

.about-text p {
    color: var(--light-text-color);
    font-size: 1.05em;
}

.about-image {
    flex: 1;
    min-width: 300px;
}

.about-image img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
}

/* Services Section */
.services-section {
    background-color: var(--primary-color);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 40px;
    max-width: 1000px;
    margin: 0 auto;
}

.service-card {
    background-color: var(--secondary-color);
    padding: 40px;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    text-align: center;
    border: 1px solid var(--border-color);
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.4);
}

.service-icon {
    font-size: 3.5em;
    color: var(--accent-color);
    margin-bottom: var(--spacing-unit);
}

.service-card h3 {
    font-size: 1.6em;
    margin-bottom: 15px;
    color: #ffffff;
}

.service-card p {
    color: var(--light-text-color);
    font-size: 0.95em;
}

/* Portfolio Section */
.portfolio-section {
    background-color: var(--secondary-color);
}

.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 40px;
    max-width: 1000px;
    margin: 0 auto;
}

.portfolio-item {
    background-color: var(--primary-color);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    text-align: left;
    border: 1px solid var(--border-color);
}

.portfolio-item:hover {
    transform: translateY(-10px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.4);
}

.portfolio-item img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease;
}

.portfolio-item:hover img {
    transform: scale(1.05);
}

.portfolio-info {
    padding: var(--spacing-unit);
}

.portfolio-info h4 {
    color: var(--accent-color);
    margin-bottom: 10px;
    font-size: 1.3em;
}

.portfolio-info p {
    color: var(--light-text-color);
    font-size: 0.9em;
    margin-bottom: 0;
}

/* Contact Section */
.contact-section {
    background-color: var(--primary-color);
}

.contact-intro {
    font-size: 1.1em;
    color: var(--light-text-color);
    margin-bottom: 40px;
}

.contact-form {
    max-width: 600px;
    margin: 0 auto;
    background-color: var(--secondary-color);
    padding: 40px;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    border: 1px solid var(--border-color);
    text-align: left;
}

.form-group {
    margin-bottom: var(--spacing-unit);
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 400;
    color: #ffffff;
    font-size: 1.05em;
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: 5px;
    background-color: var(--primary-color);
    color: var(--text-color);
    font-size: 1em;
    font-family: 'Roboto', sans-serif;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    border-color: var(--accent-color);
    outline: none;
    box-shadow: 0 0 0 3px rgba(0, 188, 212, 0.3);
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

.error-message {
    color: var(--error-color);
    font-size: 0.9em;
    margin-top: 5px;
    height: 1.2em; /* Ensure space even when empty */
}

.input-error {
    border-color: var(--error-color) !important;
}

/* Footer */
.footer {
    background-color: var(--primary-color);
    color: var(--light-text-color);
    padding: 60px 0 30px;
    border-top: 1px solid var(--border-color);
    text-align: center;
}

.footer-content {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 40px;
    gap: var(--spacing-unit);
}

.footer-logo {
    font-size: 1.6em;
    font-weight: 600;
    color: #ffffff;
    letter-spacing: 1px;
}

.footer-nav ul {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
}

.footer-nav li {
    margin: 0 15px;
}

.footer-nav a {
    color: var(--light-text-color);
    font-weight: 300;
    font-size: 0.95em;
}

.social-links a {
    color: var(--light-text-color);
    font-size: 1.5em;
    margin: 0 10px;
    transition: color 0.3s ease;
}

.social-links a:hover {
    color: var(--accent-color);
}

.copyright {
    margin-top: 20px;
    font-size: 0.85em;
    color: #666;
}

/* Responsive Design */
@media (max-width: 768px) {
    h1 { font-size: 2.5em; }
    h2 { font-size: 2em; }
    h3 { font-size: 1.5em; }

    .header .container {
        flex-wrap: wrap;
        justify-content: center;
    }

    .logo {
        width: 100%;
        text-align: center;
        margin-bottom: var(--spacing-unit);
    }

    .nav {
        width: 100%;
        text-align: center;
    }

    .nav-list {
        display: none; /* Hidden by default on mobile */
        flex-direction: column;
        width: 100%;
        margin-top: var(--spacing-unit);
        border-top: 1px solid var(--border-color);
        padding-top: var(--spacing-unit);
    }

    .nav-list.active {
        display: flex;
    }

    .nav-list li {
        margin: 10px 0;
    }

    .menu-toggle {
        display: block;
        position: absolute;
        right: var(--spacing-unit);
        top: var(--spacing-unit);
    }

    .hero-content h1 {
        font-size: 2.8em;
    }

    .hero-content p {
        font-size: 1.1em;
    }

    .about-grid {
        flex-direction: column;
        text-align: center;
    }

    .about-text, .about-image {
        flex: none;
        width: 100%;
    }

    .about-image img {
        margin: 0 auto;
    }

    .services-grid, .portfolio-grid {
        grid-template-columns: 1fr;
    }

    .service-card, .portfolio-item {
        margin: 0 auto;
        max-width: 400px;
    }

    .footer-content {
        flex-direction: column;
        gap: 30px;
    }

    .footer-nav ul {
        flex-direction: column;
        gap: 10px;
    }

    .footer-nav li {
        margin: 0;
    }
}

@media (max-width: 480px) {
    h1 { font-size: 2em; }
    h2 { font-size: 1.8em; }
    .hero-content h1 {
        font-size: 2.2em;
    }
    .cta-button {
        padding: 12px 25px;
        font-size: 1em;
    }
    .section {
        padding: 60px 0;
    }
    .section-title {
        margin-bottom: 40px;
    }
    .contact-form {
        padding: 30px;
    }
}