/* CSS Variables - Customizable Theme */
:root {
    --primary-color: #FF8C00;
    --secondary-color: #64748b;
    --accent-color: #0ea5e9;
    --background-color: #ffffff;
    --surface-color: #f8fafc;
    --text-primary: #1e293b;
    --text-secondary: #64748b;
    --border-color: #e2e8f0;
    --heading-font: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    --body-font: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    --base-size: 16px;
}

/* Reset */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--body-font);
    font-size: var(--base-size);
    color: var(--text-primary);
    background: var(--background-color);
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* Navigation */
.header {
    background: transparent;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    border-bottom: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    box-shadow: none;
    transition: all 0.3s ease;
}

.header.scrolled {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.nav {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    transition: all 0.3s ease;
}

.nav-logo {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-primary);
    text-decoration: none;
    font-family: var(--heading-font);
}

.nav-links {
    list-style: none;
    display: flex;
    gap: 0.75rem;
    justify-content: flex-end;
    flex: 1;
    margin-right: 2rem;
}

.nav-links a {
    text-decoration: none;
    color: #ffffff;
    font-size: 0.95rem;
    transition: color 0.3s ease;
    font-weight: 600;
    font-family: 'Lora', serif;
    padding: 8px 16px;
}

.header.scrolled .nav-links a {
    color: #000000;
}

.nav-links a:hover {
    color: #FF8C00;
}

.nav-links .btn-primary {
    color: #ffffff;
}

.nav-links .btn-primary:hover {
    background: #000000;
    color: #ffffff;
}

/* Hero Section */
.hero {
    padding: 6rem 1.5rem;
    text-align: left;
    background: var(--surface-color);
    border-bottom: 1px solid var(--border-color);
}

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

.hero-headline {
    font-family: var(--heading-font);
    font-size: 3rem;
    font-weight: 800;
    color: var(--text-primary);
    margin-bottom: 1.5rem;
    line-height: 1.2;
}

.hero-description {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
    line-height: 1.6;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 0.875rem 2rem;
    border-radius: 0px;
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s;
    cursor: pointer;
    border: none;
}

.btn-primary {
    background: var(--primary-color);
    color: #ffffff;
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: #ffffff;
    transition: left 0.5s ease;
    z-index: -1;
}

.btn-primary:hover::before {
    left: 0;
}

.btn-primary:hover {
    color: var(--primary-color);
    transform: translateY(-1px);
}

/* Content Section */
.content-section {
    padding: 5rem 0;
    text-align: center;
}

.content-section h2 {
    font-family: var(--heading-font);
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.content-section p {
    font-size: 1.1rem;
    color: var(--text-secondary);
    max-width: 700px;
    margin: 0 auto;
    line-height: 1.7;
}

/* Features Section */
.features-section {
    padding: 5rem 0;
    background: var(--surface-color);
}

.features-section h2 {
    font-family: var(--heading-font);
    font-size: 2rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 3rem;
    color: var(--text-primary);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.feature-card {
    background: var(--background-color);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 2rem;
    text-align: center;
    transition: transform 0.2s, box-shadow 0.2s;
}

.feature-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.feature-card h3 {
    font-family: var(--heading-font);
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
    color: var(--text-primary);
}

.feature-card p {
    font-size: 0.95rem;
    color: var(--text-secondary);
    line-height: 1.6;
}

/* CTA Section */
.cta-section {
    padding: 5rem 0;
    text-align: center;
}

.cta-section h2 {
    font-family: var(--heading-font);
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.cta-section p {
    font-size: 1.1rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

/* Footer */
.footer {
    padding: 2rem 0;
    text-align: center;
    border-top: 1px solid var(--border-color);
    background: var(--surface-color);
}

.footer p {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

/* ─── Hamburger Menu ─────────────────────────────────────────── */
.hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 10px;
    z-index: 1001;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background-color: #ffffff;
    transition: all 0.3s ease;
    border-radius: 2px;
}

.hamburger.active span:nth-child(1) { transform: rotate(45deg) translate(8px, 8px); }
.hamburger.active span:nth-child(2) { opacity: 0; }
.hamburger.active span:nth-child(3) { transform: rotate(-45deg) translate(7px, -7px); }

/* ─── Services Grid (base) ───────────────────────────────────── */
.services-grid {
    grid-template-columns: repeat(4, 260px);
}

/* Desktop (1029.33x593px and similar) — show exactly 2 cards at a time */
@media (min-width: 1025px) {
    .services-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        max-width: 800px !important;
        gap: 2rem !important;
        margin: 0 auto !important;
    }
    .service-card {
        width: 100% !important;
        padding: 2rem !important;
    }
}

.service-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 12px rgba(0, 0, 0, 0.15) !important;
}

/* ─── Responsive Breakpoints ─────────────────────────────────── */

/* Map section — stack on tablet and below */
@media (max-width: 1024px) {
    .map-contact-section .container > div {
        grid-template-columns: 1fr !important;
        gap: 2rem !important;
    }
    .map-contact-section .container > div > div:first-child { order: 1; }
    .map-contact-section .container > div > div:last-child { order: 2; }
}

/* Desktop footer — left-aligned (>1024px) */
@media (min-width: 1025px) {
    .footer > .container > div { justify-content: space-between !important; }
    .footer > .container > div > div { text-align: left !important; }
    .footer > .container > div > div:first-child img,
    .footer > .container > div > div:first-child p { text-align: left !important; }
}

/* Tablet footer — centered (769px–1024px) */
@media (max-width: 1024px) and (min-width: 769px) {
    .footer > .container > div {
        justify-content: center !important;
        text-align: center !important;
    }
    .footer > .container > div > div { text-align: center !important; }
}

/* Tablet — iPad mini and iPad (768px–1024px): 2-column services grid + About Us stacked */
@media (min-width: 768px) and (max-width: 1024px) {
    .services-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        max-width: 700px !important;
        gap: 1.5rem !important;
        justify-content: center !important;
        margin: 0 auto !important;
    }
    .service-card {
        width: 100% !important;
        max-width: 320px !important;
        padding: 1.2rem !important;
    }
    .service-card h3 { font-size: 1.2rem !important; }
    .service-card p { font-size: 0.85rem !important; }
    .service-icon { width: 50px !important; height: 50px !important; }
    .service-icon span { font-size: 2rem !important; }
    
    /* About Us section — stack paragraph and image vertically on tablet */
    .about-section .container > div[style*="grid-template-columns"] {
        grid-template-columns: 1fr !important;
        gap: 2rem !important;
    }
    .about-section .container > div[style*="grid-template-columns"] > div:first-child {
        order: 1;
    }
    .about-section .container > div[style*="grid-template-columns"] > div:last-child {
        order: 2;
    }
}

/* Small mobile landscape — 2-column services (481px–767px) */
@media (max-width: 767px) and (min-width: 481px) {
    .services-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        max-width: 600px !important;
    }
    .service-card {
        width: 100% !important;
        padding: 1.2rem !important;
    }
    .service-card h3 { font-size: 1.3rem !important; }
    .service-card p { font-size: 0.85rem !important; }
}

/* 820x1180 dimension devices — About Us section constrained to 820px max-width */
@media (min-width: 820px) and (max-width: 820px) {
    .about-section {
        max-width: 820px !important;
        margin: 0 auto !important;
        padding-left: 0 !important;
        padding-right: 0 !important;
    }
    .about-section .container {
        max-width: 820px !important;
        width: 100% !important;
        padding-left: 1.5rem !important;
        padding-right: 1.5rem !important;
    }
    .about-section .container > div {
        max-width: 820px !important;
        width: 100% !important;
    }
    .about-section img,
    .about-section .stats-grid,
    .about-section h2,
    .about-section p {
        max-width: 100% !important;
    }
}

/* Mobile (≤767px): hamburger nav, single-column services, stacked footer */
@media (max-width: 767px) {
    .hamburger { display: flex; }

    /* Merged nav-links: slide-in panel + gap from original styles.css */
    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 70%;
        max-width: 300px;
        height: 100vh;
        background-color: #ffffff;
        flex-direction: column;
        gap: 1rem;
        padding: 120px 20px 20px;
        box-shadow: -2px 0 10px rgba(0, 0, 0, 0.1);
        transition: right 0.3s ease;
        z-index: 1000;
        overflow-y: auto;
        justify-content: flex-start;
    }
    .nav-links.active { right: 0; }
    .nav-links li { width: 100%; text-align: center; margin: 10px 0; }
    .nav-links a { display: block; padding: 12px 20px; font-size: 1.1rem; }

    .hero { padding: 4rem 1.5rem; }
    .hero-headline { font-size: 2rem; }
    .hero-description { font-size: 1.05rem; }
    .hero-content { padding: 2rem 1rem !important; }
    .hero-subheadline { font-size: 1.2rem !important; }

    .features-grid { grid-template-columns: 1fr; }

    .services-grid {
        grid-template-columns: 1fr !important;
        max-width: 400px !important;
    }
    .service-card { padding: 1.5rem !important; }

    .footer > .container > div {
        flex-direction: column !important;
        text-align: center !important;
        align-items: center !important;
    }
    .footer > .container > div > div {
        text-align: center !important;
        width: 100% !important;
    }
}
