/* --- Default / Light Theme Colors --- */
:root {
    --nav-bg: #ffffff;
    --brand-text: #333333;
    --brand-accent: #0056b3; /* Primary Blue */
    --text-main: #333333;
    --text-muted: #666666;
    --bg-light: #f4f6f9;
    --white: #ffffff;
    --card-border: #eaeaea;
}

/* --- Dark Theme Colors (Auto-Triggers on user's device) --- */
@media (prefers-color-scheme: dark) {
    :root {
        --nav-bg: #1a1a1a;
        --brand-text: #ffffff;
        --brand-accent: #71ff4d; /* Lighter blue for dark mode */
        --text-main: #e0e0e0;
        --text-muted: #a0a0a0;
        --bg-light: #121212;
        --white: #1e1e1e;
        --card-border: #333333;
    }
}

/* --- Global Resets --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
}

body {
    color: var(--text-main);
    background-color: var(--bg-light);
    line-height: 1.6;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

main {
    flex: 1; /* Pushes the footer down on empty pages */
}

/* --- Navigation Bar --- */
.navbar {
    background-color: var(--nav-bg);
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 5%;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: background-color 0.3s ease;
}

/* --- Brand Logo Layout --- */
.brand-link {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
}

.logo-icon {
    height: 40px;
    width: auto;
}

.brand-text {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--brand-text);
    letter-spacing: -0.5px;
    transition: color 0.3s ease;
}

.brand-accent {
    color: var(--brand-accent);
    transition: color 0.3s ease;
}

/* --- Nav Links --- */
.nav-links {
    list-style: none;
    display: flex;
    gap: 2rem;
}

.nav-links a {
    text-decoration: none;
    color: var(--brand-text);
    font-weight: 600;
    font-size: 0.95rem;
    transition: color 0.3s ease;
}

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

/* --- Layout Utility Classes --- */
.container {
    max-width: 1200px;
    margin: 0 auto;
}

.page-content {
    padding: 4rem 5%;
}

.page-card {
    padding: 3rem;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    border: 1px solid var(--card-border);
}

.bg-white {
    background-color: var(--white);
    transition: background-color 0.3s ease;
}

h2 {
    color: var(--brand-text);
}

/* --- Hero Section (Home Only) --- */
.hero {
    min-height: calc(100vh - 82px);
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    background: linear-gradient(135deg, var(--bg-light) 0%, var(--white) 100%);
    padding: 0 5%;
}

.hero h1 {
    font-size: 4rem;
    color: var(--brand-accent);
    margin-bottom: 1rem;
}

.hero p {
    font-size: 1.25rem;
    color: var(--text-muted);
    margin-bottom: 2.5rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.cta-button {
    display: inline-block;
    padding: 1rem 2.5rem;
    background-color: var(--brand-accent);
    color: #ffffff; /* Keep button text white in both modes */
    text-decoration: none;
    border-radius: 4px;
    font-weight: bold;
    font-size: 1.1rem;
    transition: background-color 0.3s, transform 0.2s;
}

.cta-button:hover {
    filter: brightness(0.9);
    transform: translateY(-2px);
}

/* --- Services Grid --- */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.service-card {
    background-color: var(--white);
    padding: 2.5rem;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    border: 1px solid var(--card-border);
    transition: transform 0.3s, background-color 0.3s ease;
}

.service-card:hover {
    transform: translateY(-5px);
}

.service-card h3 {
    margin-bottom: 1rem;
    color: var(--brand-accent);
}

/* --- Contact Info --- */
.contact-info {
    display: flex;
    justify-content: center; /* Centers the group perfectly */
    flex-wrap: wrap;
    gap: 4rem;              /* Forces a perfect, permanent 4-column gap between items */
    text-align: center;
    margin-top: 2rem;
}

.contact-item {
    min-width: 200px;       /* Gives every block a balanced starting width */
}

/* --- Footer --- */
footer {
    background-color: var(--brand-text);
    color: var(--nav-bg); /* Inverts color for high contrast */
    text-align: center;
    padding: 2rem;
    font-size: 0.9rem;
    transition: background-color 0.3s ease;
}

/* --- Mobile Responsiveness --- */
@media (max-width: 768px) {
    .navbar {
        flex-direction: column;
        padding: 1rem;
    }
    
    .nav-links {
        margin-top: 1rem;
        flex-wrap: wrap;
        justify-content: center;
        gap: 1rem;
    }

    .hero h1 {
        font-size: 2.5rem;
    }
}