/* --- CSS VARIABLES & RESET --- */
:root {
    /* Color Palette */
    --primary-navy: #002147;
    --primary-navy-light: #003366;
    --accent-orange: #FF8C00;
    --accent-orange-hover: #e67e00;
    --text-dark: #1a1a1a;
    --text-gray: #555555;
    --bg-light: #f4f6f8;
    --white: #ffffff;
    --border-color: #e0e0e0;
    
    /* Spacing & Sizing */
    --container-width: 1200px;
    --nav-height: 70px;
    --radius-sm: 4px;
    --radius-md: 8px;
    
    /* Typography */
    --font-heading: 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    --font-body: 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

/* Prevent horizontal scrolling globally */
html, body {
    overflow-x: hidden;
    width: 100%;
    position: relative;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    line-height: 1.6;
    color: var(--text-dark);
    background-color: var(--white);
}

h1, h2, h3, h4 {
    font-family: var(--font-heading);
    color: var(--primary-navy);
    line-height: 1.2;
    margin-bottom: 1rem;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.2s ease;
}

ul {
    list-style: none;
}

/* --- UTILITIES --- */
.container {
    width: 90%;
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 1rem;
}

.section-pad {
    padding: 5rem 0;
}

.bg-light { background-color: var(--bg-light); }
.bg-navy { background-color: var(--primary-navy); }
.text-white { color: var(--white); }
.text-center { text-align: center; }


.btn {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    font-weight: 600;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all 0.2s ease;
    border: 2px solid transparent;
    text-align: center;
}

.btn-primary {
    background-color: var(--accent-orange);
    color: var(--white);
}

.btn-primary:hover {
    background-color: var(--accent-orange-hover);
    transform: translateY(-2px);
}

.btn-outline {
    background-color: transparent;
    border-color: var(--white);
    color: var(--white);
}

.btn-outline:hover {
    background-color: var(--white);
    color: var(--primary-navy);
}

.btn-large {
    padding: 1rem 2rem;
    font-size: 1.1rem;
}

/* --- NAVIGATION --- */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    height: var(--nav-height);
    background-color: var(--primary-navy);
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.nav-container {
    height: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.brand-logo {
    color: var(--white);
    font-size: 1.5rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    z-index: 1002; /* Ensures it stays on top of mobile menu */
}

.accent-text {
    color: var(--accent-orange);
    font-weight: 400;
}

.nav-links {
    display: flex;
    gap: 2rem;
    align-items: center;
}

.nav-item {
    color: #cccccc;
    font-weight: 500;
}

.nav-item:hover {
    color: var(--white);
}

.nav-cta {
    padding: 0.5rem 1.25rem;
    font-size: 0.9rem;
}

/* Mobile Toggle */
.mobile-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--white);
    font-size: 1.5rem;
    cursor: pointer;
    z-index: 1001;
}

/* --- HERO SECTION --- */
.hero-section {
    position: relative;
    height: 100vh;
    min-height: 600px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: url('hero\ background\ photo.avif') center/cover no-repeat;
    margin-top: 0;
}

.hero-overlay {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(135deg, rgba(0, 33, 71, 0.9) 0%, rgba(0, 33, 71, 0.7) 100%);
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    color: var(--white);
    max-width: 800px;
}

.hero-title {
    font-size: 3.5rem;
    color: var(--white);
    margin-bottom: 1.5rem;
}

.hero-subtitle {
    font-size: 1.25rem;
    margin-bottom: 2.5rem;
    color: #e0e0e0;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* --- SERVICES --- */
.section-header h2 {
    font-size: 2.5rem;
}

.divider {
    width: 60px;
    height: 4px;
    background-color: var(--accent-orange);
    margin: 1rem auto;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.service-card {
    background: var(--white);
    padding: 2rem;
    border-radius: var(--radius-md);
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    transition: transform 0.3s ease;
    border-bottom: 3px solid transparent;
}

.service-card:hover {
    transform: translateY(-5px);
    border-bottom-color: var(--accent-orange);
}

.icon-wrapper {
    font-size: 2rem;
    color: var(--primary-navy);
    margin-bottom: 1rem;
}

/* --- ABOUT --- */
.about-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.eyebrow {
    color: var(--accent-orange);
    text-transform: uppercase;
    font-weight: 700;
    letter-spacing: 1px;
    font-size: 0.9rem;
}

.feature-list {
    margin-top: 1.5rem;
}

/* FIX: Top alignment ensures checkmarks look good even if text wraps */
.feature-list li {
    margin-bottom: 1rem;
    display: flex;
    align-items: flex-start; 
    gap: 0.75rem;
}

/* Slight top margin aligns icon with the first line of text */
.feature-list i {
    color: var(--accent-orange);
    margin-top: 4px; 
}

/* FIX: Fluid Image Block (Works on Laptop & Mobile) */
.img-block {
    background-color: #eee;
    width: 100%;
    aspect-ratio: 16 / 9; /* Maintains widescreen shape on all devices */
    border-radius: var(--radius-md);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: var(--text-gray);
    border: 2px dashed #ccc;
    overflow: hidden; /* Ensures .img-fluid inside doesn't spill out */
}

/* Fluid Image Utility (Used in About Section) */
.img-fluid {
    width: 100%;
    height: 100%;
    object-fit: cover; /* Ensures image fills box without stretching */
    display: block;
    border-radius: var(--radius-md);
}

/* --- CONTACT --- */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
}

.contact-info h2 {
    color: var(--white);
}

.info-item {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    margin-top: 2rem;
}

.info-item i {
    font-size: 1.5rem;
    color: var(--accent-orange);
    width: 30px;
}

.contact-link {
    color: #ccc;
    display: block;
}

.contact-link:hover {
    color: var(--accent-orange);
}

.form-card {
    background: var(--white);
    padding: 2rem;
    border-radius: var(--radius-md);
    color: var(--text-dark);
}

.form-group, .form-group-row {
    margin-bottom: 1.25rem;
}

.form-group-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

label {
    display: block;
    font-weight: 600;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

.required { color: red; }

input, select, textarea {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    font-family: inherit;
    font-size: 1rem;
}

input:focus, select:focus, textarea:focus {
    outline: 2px solid var(--primary-navy);
    border-color: transparent;
}

.full-width {
    width: 100%;
}

.form-status {
    margin-top: 1rem;
    font-weight: 600;
    text-align: center;
}

.status-success { color: green; }
.status-error { color: red; }

/* Success Message Styling */
.success-message {
    text-align: center;
    padding: 2rem;
    background-color: #f0fdf4; 
    border: 2px solid #4CAF50; 
    border-radius: 8px;
    animation: fadeIn 0.5s ease-in;
}

.success-message h3 {
    color: #2e7d32;
    margin-bottom: 0.5rem;
}

.success-message p {
    color: #1a1a1a;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* --- FOOTER --- */
footer {
    background-color: #00152e;
    color: #889bb0;
    padding: 4rem 0 2rem;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 3rem;
    margin-bottom: 3rem;
}

footer h4 {
    color: var(--white);
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
}

.footer-links li {
    margin-bottom: 0.75rem;
}

.footer-links a:hover {
    color: var(--accent-orange);
}

.footer-bottom {
    text-align: center;
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 2rem;
    font-size: 0.9rem;
}

/* Social Media Container */
.social-media {
    margin: 15px 0;
    text-align: center; 
}

.social-media a {
    text-decoration: none;
    display: inline-flex;     
    align-items: center;      
    justify-content: center;
    gap: 10px;                
    padding: 10px 20px;       
    background-color: #333;   
    color: #ffffff;           
    border-radius: 30px;      
    transition: all 0.3s ease;
    font-weight: bold;
    font-family: sans-serif;
}

.social-media a:hover {
    background-color: #1877F2; 
    transform: translateY(-3px);
    box-shadow: 0 4px 10px rgba(0,0,0,0.3);
}

/* --- RESPONSIVE MEDIA QUERIES --- */

/* 1. TABLET & SMALLER (Below 900px) */
@media (max-width: 900px) {
    .hero-title { font-size: 2.8rem; }
    
    /* Stack side-by-side sections vertically */
    .about-wrapper, 
    .contact-grid,
    .form-group-row { 
        grid-template-columns: 1fr; 
        gap: 2.5rem;
    }
}

/* 2. MOBILE PHONES (Below 768px) */
@media (max-width: 768px) {
    
    /* --- A. Layout & Scroll Fixes --- */
    .container { 
        width: 100%; 
        padding: 0 15px; /* Slightly reduced padding to give content more room */
    }

    .section-pad { padding: 3rem 0; }

    /* Fix: Force long emails/links to break so they don't widen the page */
    a, p, span {
        overflow-wrap: break-word;
        word-wrap: break-word;
        word-break: break-word; 
    }

    /* --- B. Form Specific Fixes (The 368px Bug) --- */
    .form-card {
        padding: 1.5rem 1rem; /* Smaller padding on sides */
        width: 100%;
        max-width: 100%; /* Ensures it never exceeds screen */
    }

    /* CRITICAL: Allows inputs to shrink below default browser widths */
    input, select, textarea { 
        font-size: 16px; 
        min-width: 0; 
        width: 100%;
    }

    /* Force inputs to stack perfectly */
    .form-group-row {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    /* --- C. Services Grid Fix --- */
    /* Forces cards to fit the screen, ignoring the 300px min-width */
    .services-grid { 
        display: flex;
        flex-direction: column;
        gap: 1.5rem;
    }

    /* --- D. Navigation --- */
    .mobile-toggle { display: block; }
    .brand-logo { font-size: 1.25rem; }

    .nav-links {
        position: fixed;
        top: 0; right: 0;
        height: 100vh;
        width: 80%; /* Slightly wider menu for better touch */
        max-width: 300px;
        background-color: var(--primary-navy);
        flex-direction: column;
        justify-content: center;
        transform: translateX(100%);
        transition: transform 0.3s ease-in-out;
        box-shadow: -5px 0 15px rgba(0,0,0,0.2);
    }
    
    .nav-links.active { transform: translateX(0); }

    /* --- E. Hero Section --- */
    .hero-section { 
        height: auto; 
        padding: 120px 0 60px; 
    }
    .hero-title { 
        font-size: 2rem; 
        line-height: 1.2;
    }
    .hero-buttons { 
        flex-direction: column; 
        gap: 15px; 
    }
    .btn { width: 100%; display: block; }
}