/* --- Global Styles & Variables --- */
:root {
    --primary-bg-gray: #E9ECEF; /* Light gray main background */
    --card-bg-white: #FFFFFF;   /* White for content cards/panels */

    --text-color-blue: #0D47A1;      /* Deep, professional blue for headings/accents */
    --text-color-red: #D32F2F;       /* Strong red for accents/CTAs */
    --text-color-white: #FFFFFF;     /* White text, mainly for dark backgrounds (e.g., hero, footer) */
    --text-color-dark-gray: #343A40; /* Dark gray for body text on light backgrounds */
    --text-color-medium-gray: #6c757d; /* Medium gray for subtitles or less prominent text */
    --text-color-light-gray-footer: #adb5bd; /* Light gray for footer text */

    --border-color: #ced4da; /* Lighter border color for forms etc. */
    --shadow-light: 0 4px 15px rgba(0, 0, 0, 0.06);
    --shadow-medium: 0 8px 25px rgba(0, 0, 0, 0.1);

    --font-headings: 'Raleway', sans-serif;
    --font-body: 'Open Sans', sans-serif;

    --container-width: 1140px;
    --border-radius-main: 8px;
    --transition-speed: 0.3s ease;
}

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

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-body);
    line-height: 1.7;
    color: var(--text-color-dark-gray); /* Default body text color */
    background-color: var(--primary-bg-gray); /* Main gray background */
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.container {
    width: 90%;
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 15px;
}

/* Text Color Utility Classes */
.text-blue { color: var(--text-color-blue) !important; }
.text-red { color: var(--text-color-red) !important; }
.text-white { color: var(--text-color-white) !important; }
.text-dark-gray { color: var(--text-color-dark-gray) !important; }
.text-medium-gray { color: var(--text-color-medium-gray) !important; }
.text-light-gray { color: var(--text-color-light-gray-footer) !important; }

.hover-text-red:hover { color: var(--text-color-red) !important; }
.hover-text-blue:hover { color: var(--text-color-blue) !important; }
.hover-text-white:hover { color: var(--text-color-white) !important; }


h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-headings);
    font-weight: 700;
    /* Default heading color will be blue, can be overridden by utility classes */
    color: var(--text-color-blue);
    line-height: 1.3;
}

h1 { font-size: 2.8rem; margin-bottom: 1rem; font-weight: 900;} /* Raleway Black for H1 */
h2 { font-size: 2.2rem; margin-bottom: 0.75rem; }
h3 { font-size: 1.5rem; margin-bottom: 0.5rem; }
h4 { font-size: 1.2rem; margin-bottom: 0.5rem; }

.section-title {
    text-align: center;
    margin-bottom: 20px;
    font-size: 2.5rem; /* Adjusted from h2 for consistency */
}
.section-subtitle {
    text-align: center;
    font-size: 1.05rem;
    max-width: 650px;
    margin: 0 auto 50px auto;
    font-family: var(--font-body);
}

p {
    margin-bottom: 1rem;
    font-family: var(--font-body);
}

a {
    text-decoration: none;
    /* Default link color */
    color: var(--text-color-red);
    transition: color var(--transition-speed);
}
a:hover {
    color: var(--text-color-blue); /* Default link hover */
}

img { max-width: 100%; height: auto; display: block; }
ul { list-style: none; }

/* Sections on Gray Background */
.section-on-gray {
    padding: 70px 0;
}
/* Card-like sections on gray background */
.card-like-section {
    background-color: var(--card-bg-white);
    padding: 40px;
    border-radius: var(--border-radius-main);
    box-shadow: var(--shadow-medium);
    margin-top: 30px; /* Add some space if it's the first element after a title */
    margin-bottom: 30px;
}
/* Ensure first card-like section has top padding if it's the main content of a .section-on-gray */
.section-on-gray > .container:first-child > .card-like-section:first-child {
    margin-top: 0;
}


/* Buttons */
.btn {
    display: inline-block;
    padding: 12px 28px;
    font-family: var(--font-headings);
    font-weight: 700;
    text-align: center;
    border-radius: var(--border-radius-main);
    transition: all var(--transition-speed);
    cursor: pointer;
    border: 2px solid transparent;
    font-size: 0.95rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* --- Header --- */
#header {
    background-color: var(--card-bg-white); /* White header on gray body */
    box-shadow: var(--shadow-light);
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    padding: 12px 0;
}
#header.scrolled { /* Optional: Style for scrolled header */
    box-shadow: var(--shadow-medium);
    /* background-color: rgba(255, 255, 255, 0.95); backdrop-filter: blur(5px); */
}
#header nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.logo-container { display: flex; align-items: center; text-decoration: none; }
.logo-img { height: 50px; width: auto; margin-right: 10px; }
.logo-text { display: flex; flex-direction: column; }
.company-name-main {
    font-family: var(--font-headings);
    font-size: 1.5rem; font-weight: 900;
    color: var(--text-color-blue); line-height: 1;
}
.tagline-header {
    font-size: 0.75rem; color: var(--text-color-red);
    font-family: var(--font-body); font-weight: 400; letter-spacing: 0.5px;
}

.nav-links { display: flex; align-items: center; }
.nav-links li { margin-left: 22px; }
.nav-links a {
    font-family: var(--font-headings);
    color: var(--text-color-dark-gray); /* Dark gray nav links */
    font-weight: 700; font-size: 0.9rem;
    padding: 5px 0; position: relative; text-transform: uppercase;
}
.nav-links a::after {
    content: ''; position: absolute; bottom: -2px; left: 0;
    width: 0; height: 2px; background-color: var(--text-color-red);
    transition: width var(--transition-speed);
}
.nav-links a:hover::after, .nav-links a.active::after { width: 100%; }
.nav-links a:hover, .nav-links a.active { color: var(--text-color-red); }

.btn-nav-cta {
    background-color: var(--text-color-red); color: var(--text-color-white);
    padding: 9px 20px; font-size: 0.85rem; margin-left: 22px;
}
.btn-nav-cta:hover {
    background-color: var(--text-color-blue); color: var(--text-color-white);
    box-shadow: 0 2px 10px rgba(13, 71, 161, 0.3);
}

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

/* --- Hero Section --- */
.hero-section {
    position: relative;
    background: url('https://via.placeholder.com/1920x1080/343A40/FFFFFF?text=Modern+Tech+Canvas') no-repeat center center/cover;
    padding: 200px 0 150px; /* Adjusted padding for header */
    text-align: center;
    min-height: 85vh;
    display: flex; align-items: center; justify-content: center;
}
.hero-overlay {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    background-color: rgba(13, 71, 161, 0.6); /* Blue overlay to ensure white text readability */
}
.hero-content { position: relative; z-index: 1; }
.hero-title-blue { color: var(--text-color-white); /* Main hero title is white */ }
.hero-content .subtitle {
    font-size: 1.2rem; max-width: 700px;
    margin: 0 auto 35px auto;
    font-family: var(--font-body); font-weight: 400;
}
.hero-buttons .btn { margin: 0 8px; padding: 14px 32px; font-size: 1rem; }
.btn-hero-primary {
    background-color: var(--text-color-red); color: var(--text-color-white);
    border-color: var(--text-color-red);
}
.btn-hero-primary:hover { background-color: #A82424; border-color: #A82424; transform: translateY(-2px); }
.btn-hero-secondary {
    background-color: transparent; color: var(--text-color-white);
    border-color: var(--text-color-white);
}
.btn-hero-secondary:hover { background-color: var(--text-color-white); color: var(--text-color-blue); transform: translateY(-2px); }
.btn i { margin-left: 8px; }

/* --- Services Section --- */
/* .services-section is a .section-on-gray */
.service-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(270px, 1fr));
    gap: 25px;
}
.service-card {
    background-color: var(--card-bg-white); /* White cards */
    padding: 30px 25px;
    border-radius: var(--border-radius-main);
    box-shadow: var(--shadow-light);
    text-align: center;
    transition: transform var(--transition-speed), box-shadow var(--transition-speed);
    border-top: 3px solid transparent;
}
.service-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-medium);
    border-top-color: var(--text-color-red);
}
.service-icon-bg {
    width: 70px; height: 70px;
    background-color: rgba(209, 47, 47, 0.1); /* Light red bg for icon */
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    margin: 0 auto 20px auto;
}
.service-icon { font-size: 2.2rem; /* color: var(--text-color-blue); Handled by utility class */ }
.service-card h3 { font-size: 1.3rem; margin-bottom: 12px; } /* color: var(--text-color-blue); Handled by utility */
.service-card p { font-size: 0.9rem; margin-bottom: 20px; min-height: 70px; } /* color: var(--text-color-dark-gray); Handled by utility */
.service-link {
    font-family: var(--font-headings); font-weight: 700;
    text-transform: uppercase; font-size: 0.85rem;
}
.service-link i { font-size: 0.75rem; transition: transform var(--transition-speed); }
.service-link:hover i { transform: translateX(4px); }

/* --- About Us Section --- */
/* .about-section is a .section-on-gray, content in .card-like-section */
.about-content-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr; /* Text takes slightly more space */
    gap: 40px;
    align-items: center;
}
.founder-intro { font-size: 1.05rem; margin-bottom: 18px; }
.about-text-content h4 { margin-top: 25px; margin-bottom: 12px; }
.about-text-content ul { padding-left: 0; }
.about-text-content ul li {
    margin-bottom: 8px; font-family: var(--font-body);
    display: flex; align-items: center; font-size: 0.95rem;
}
.about-text-content ul li i { margin-right: 10px; font-size: 1.1rem; /* color: var(--text-color-red); Handled by utility */ }
.about-image-content img {
    border-radius: var(--border-radius-main);
    box-shadow: var(--shadow-light);
}

/* --- Portfolio Section --- */
/* .portfolio-section is a .section-on-gray */
.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 25px;
}
.portfolio-item {
    position: relative; overflow: hidden;
    border-radius: var(--border-radius-main);
    box-shadow: var(--shadow-light);
}
.portfolio-item img { transition: transform 0.5s ease; display: block; width: 100%; }
.portfolio-item:hover img { transform: scale(1.08); }
.portfolio-overlay {
    position: absolute; bottom: 0; left: 0; right: 0;
    background: linear-gradient(to top, rgba(13, 71, 161, 0.85), transparent); /* Blue overlay */
    padding: 25px 18px 18px;
    opacity: 0; /* Hidden by default */
    transform: translateY(20px); /* Start slightly down */
    transition: opacity var(--transition-speed), transform var(--transition-speed);
}
.portfolio-item:hover .portfolio-overlay { opacity: 1; transform: translateY(0); }
.portfolio-overlay h3 { font-size: 1.2rem; margin-bottom: 5px; /* color: var(--text-color-white); Handled by utility */ }

/* --- Contact Section --- */
/* .contact-section is a .section-on-gray, content in .card-like-section */
.contact-wrapper {
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 40px;
}
.contact-info-container h3 { margin-bottom: 12px; }
.contact-info-container p { margin-bottom: 18px; font-size: 0.95rem; }

.form-row { display: flex; gap: 18px; margin-bottom: 18px; }
.form-row .form-group { flex: 1; margin-bottom: 0; }
.form-group { margin-bottom: 18px; }
.form-group label {
    display: block; font-family: var(--font-headings); font-weight: 700;
    margin-bottom: 6px; font-size: 0.85rem;
}
.form-group input, .form-group textarea, .form-group select {
    width: 100%; padding: 10px 12px;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius-main);
    font-family: var(--font-body); font-size: 0.95rem;
    transition: border-color var(--transition-speed);
    background-color: var(--primary-bg-gray); /* Light gray input fields */
    color: var(--text-color-dark-gray);
}
.form-group input::placeholder, .form-group textarea::placeholder { color: var(--text-color-medium-gray); }
.form-group input:focus, .form-group textarea:focus, .form-group select:focus {
    outline: none; border-color: var(--text-color-blue);
    box-shadow: 0 0 0 0.15rem rgba(13, 71, 161, 0.1);
    background-color: var(--card-bg-white);
}
.btn-form-submit {
    background-color: var(--text-color-red); color: var(--text-color-white);
    width: 100%; padding: 12px; font-size: 1rem;
}
.btn-form-submit:hover { background-color: var(--text-color-blue); }

.contact-details-list { margin-top: 18px; }
.contact-details-list li {
    display: flex; align-items: center;
    margin-bottom: 12px; font-size: 0.95rem;
}
.contact-details-list li i {
    font-size: 1.2rem; margin-right: 12px;
    width: 22px; text-align: center; /* color: var(--text-color-red); Handled by utility */
}
.contact-info-container h4 { margin-top: 25px; margin-bottom: 12px; }
.social-links-contact .social-icon {
    display: inline-block; width: 36px; height: 36px;
    line-height: 36px; text-align: center;
    border-radius: 50%;
    background-color: var(--primary-bg-gray); /* Match input fields */
    color: var(--text-color-blue);
    margin-right: 8px; font-size: 1.1rem;
    transition: all var(--transition-speed);
}
.social-links-contact .social-icon:hover {
    background-color: var(--text-color-blue); color: var(--text-color-white);
    transform: translateY(-2px);
}
.social-links-contact .social-icon.facebook:hover { background-color: #3b5998; }
.social-links-contact .social-icon.tiktok:hover { background-color: #000000; }
.social-links-contact .social-icon.youtube:hover { background-color: #FF0000; }
.social-links-contact .social-icon.github:hover { background-color: #333; }


/* --- Footer Section --- */
#footer {
    background-color: var(--text-color-dark-gray); /* Dark gray footer */
    padding: 50px 0 18px;
    font-family: var(--font-body);
}
.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 28px;
    margin-bottom: 35px;
}
.footer-logo-img { height: 55px; width: auto; margin-bottom: 12px; }
.footer-company-name {
    font-family: var(--font-headings); font-size: 1.2rem; font-weight: 700;
    margin-bottom: 8px;
}
.footer-col h4 {
    font-family: var(--font-headings); font-size: 1.1rem;
    margin-bottom: 18px; position: relative; padding-bottom: 8px;
}
.footer-col h4::after {
    content: ''; position: absolute; bottom: 0; left: 0;
    width: 35px; height: 2px; background-color: var(--text-color-red);
}
.footer-col ul li { margin-bottom: 8px; }
.footer-col ul li a, .footer-col p a {
    font-size: 0.9rem;
    transition: color var(--transition-speed), padding-left var(--transition-speed);
}
.footer-col ul li a:hover, .footer-col p a:hover { padding-left: 4px; }
.footer-col p { font-size: 0.9rem; margin-bottom: 8px; }
.footer-col p i { margin-right: 6px; /* color: var(--text-color-red); Handled by utility */ }

.social-links-footer a {
    display: inline-block; font-size: 1.2rem;
    margin-right: 12px;
    transition: color var(--transition-speed), transform var(--transition-speed);
}
.social-links-footer a:hover { transform: translateY(-2px); }

.footer-bottom {
    text-align: center; padding-top: 18px;
    border-top: 1px solid #495057; /* Slightly darker border */
    font-size: 0.85rem;
}

/* --- Responsive Design --- */
@media (max-width: 992px) {
    .section-title { font-size: 2.2rem; }
    .hero-content h1 { font-size: 2.5rem; }
    .about-content-grid { grid-template-columns: 1fr; }
    .about-image-content { margin-top: 25px; text-align: center; }
    .contact-wrapper { grid-template-columns: 1fr; }
    .contact-info-container { margin-top: 35px; }
    .nav-links { display: none; flex-direction: column; width: 100%;
        position: absolute; top: 73px; /* Adjust if header height changes */
        left: 0; background-color: var(--card-bg-white);
        box-shadow: var(--shadow-medium); padding: 8px 0;
    }
    .nav-links.active { display: flex; }
    .nav-links li { margin: 8px 0; text-align: center; width: 100%;}
    .nav-links a { display: block; padding: 8px; width: 100%; }
    .menu-toggle { display: block; }
    .btn-nav-cta { display: none; }
}

@media (max-width: 768px) {
    html { font-size: 15px; }
    .hero-content h1 { font-size: 2.2rem; }
    .hero-buttons .btn { padding: 11px 22px; font-size: 0.9rem; }
    .form-row { flex-direction: column; gap:0; margin-bottom: 0;}
    .form-row .form-group { margin-bottom: 18px; }
}

@media (max-width: 576px) {
    .hero-content h1 { font-size: 1.8rem; }
    .logo-img { height: 40px; margin-right: 6px; }
    .company-name-main { font-size: 1.2rem; }
    .tagline-header { font-size: 0.65rem; }
    .section-title { font-size: 1.8rem; }
    .section-subtitle { font-size: 0.95rem; margin-bottom: 25px; }
    .footer-grid { text-align: center; }
    .footer-col h4::after { left: 50%; transform: translateX(-50%); }
}
