/* ============================================================================
   McDaniel Construction — Company Website Stylesheet
   ============================================================================
   Design: Deep navy + warm amber, Playfair Display headings, Source Sans 3 body
   Architecture: Single-page application with section-based routing
   ============================================================================ */

/* ---- 1. CUSTOM PROPERTIES ---- */
:root {
    /* Palette */
    --navy:        #1b2a4a;
    --navy-dark:   #111d33;
    --amber:       #c8913a;
    --amber-light: #d4a85c;
    --amber-dark:  #a67520;
    --white:       #ffffff;
    --off-white:   #f5f2ed;
    --light-gray:  #e8e4df;
    --charcoal:    #2d2d2d;
    --medium-gray: #6b6b6b;

    /* Typography */
    --font-heading: 'Playfair Display', Georgia, serif;
    --font-body:    'Source Sans 3', 'Segoe UI', Roboto, sans-serif;

    /* Layout */
    --max-width:   1200px;
    --header-h:    80px;
    --section-pad: 80px;

    /* Transitions */
    --ease: cubic-bezier(0.4, 0, 0.2, 1);
}


/* ---- 2. RESET & BASE ---- */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

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

body {
    font-family: var(--font-body);
    font-weight: 400;
    line-height: 1.6;
    color: var(--charcoal);
    background: var(--white);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

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

a:hover {
    color: var(--amber-dark);
}

ul, ol {
    list-style: none;
}

button {
    cursor: pointer;
    border: none;
    background: none;
    font-family: var(--font-body);
}


/* ---- 3. TYPOGRAPHY ---- */
h1, h2, h3, h4, h5 {
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1.2;
    color: var(--navy);
}

h1 { font-size: 3rem; }
h2 { font-size: 2.25rem; margin-bottom: 1rem; }
h3 { font-size: 1.5rem; margin-bottom: 0.75rem; }
h4 { font-size: 1.25rem; margin-bottom: 0.5rem; }

p {
    margin-bottom: 1rem;
    color: var(--charcoal);
}

.section-subtitle {
    font-family: var(--font-body);
    font-size: 1.125rem;
    font-weight: 300;
    color: var(--medium-gray);
    max-width: 700px;
    margin: 0 auto 2rem;
    text-align: center;
}

.text-amber { color: var(--amber); }
.text-navy  { color: var(--navy); }
.text-white { color: var(--white); }


/* ---- 4. LAYOUT UTILITIES ---- */
.container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 24px;
}

.text-center { text-align: center; }

.section-padding {
    padding: var(--section-pad) 0;
}

.bg-white     { background: var(--white); }
.bg-off-white { background: var(--off-white); }
.bg-navy      { background: var(--navy); color: var(--white); }
.bg-navy h2, .bg-navy h3, .bg-navy h4 { color: var(--white); }
.bg-navy p { color: rgba(255,255,255,0.85); }
.bg-navy .section-subtitle { color: rgba(255,255,255,0.7); }


/* ---- 5. BUTTONS ---- */
.btn {
    display: inline-block;
    padding: 14px 32px;
    font-family: var(--font-body);
    font-size: 0.875rem;
    font-weight: 600;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    border-radius: 3px;
    transition: all 0.3s var(--ease);
    cursor: pointer;
}

.btn-primary {
    background: var(--amber);
    color: var(--white);
    border: 2px solid var(--amber);
}

.btn-primary:hover {
    background: var(--amber-dark);
    border-color: var(--amber-dark);
    color: var(--white);
}

.btn-outline {
    background: transparent;
    color: var(--white);
    border: 2px solid var(--white);
}

.btn-outline:hover {
    background: var(--white);
    color: var(--navy);
}

.btn-outline-navy {
    background: transparent;
    color: var(--navy);
    border: 2px solid var(--navy);
}

.btn-outline-navy:hover {
    background: var(--navy);
    color: var(--white);
}


/* ---- 6. HEADER & NAVIGATION ---- */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    height: var(--header-h);
    display: flex;
    align-items: center;
    transition: background 0.4s var(--ease), box-shadow 0.4s var(--ease);
    background: transparent;
}

.site-header.scrolled {
    background: var(--navy);
    box-shadow: 0 2px 20px rgba(0,0,0,0.15);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 24px;
}

.header-logo img {
    height: 69px;
    width: auto;
    max-width: 400px;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 8px;
}

.nav-links a {
    color: var(--white);
    font-size: 0.8125rem;
    font-weight: 600;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    padding: 8px 14px;
    border-radius: 3px;
    transition: background 0.3s var(--ease), color 0.3s var(--ease);
}

.nav-links a:hover,
.nav-links a.active {
    background: rgba(255,255,255,0.12);
    color: var(--amber-light);
}

/* Services dropdown */
.nav-dropdown {
    position: relative;
}

.nav-dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 220px;
    background: var(--white);
    box-shadow: 0 8px 30px rgba(0,0,0,0.12);
    border-radius: 4px;
    padding: 8px 0;
    opacity: 0;
    visibility: hidden;
    transform: translateY(8px);
    transition: all 0.25s var(--ease);
}

.nav-dropdown:hover .nav-dropdown-menu,
.nav-dropdown.open .nav-dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.nav-dropdown-menu a {
    display: block;
    padding: 10px 20px;
    color: var(--charcoal);
    font-size: 0.8125rem;
    text-transform: none;
    letter-spacing: 0;
}

.nav-dropdown-menu a:hover {
    background: var(--off-white);
    color: var(--amber);
}

/* Hamburger (mobile) */
.hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    padding: 8px;
    cursor: pointer;
}

.hamburger span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--white);
    transition: all 0.3s var(--ease);
}

.hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }


/* ---- 7. HERO SECTIONS ---- */
.hero {
    position: relative;
    min-height: 85vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    padding: 120px 24px 80px;
}

.hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(
        180deg,
        rgba(27, 42, 74, 0.75) 0%,
        rgba(27, 42, 74, 0.6) 50%,
        rgba(27, 42, 74, 0.8) 100%
    );
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 800px;
}

.hero h1 {
    font-size: 3.5rem;
    color: var(--white);
    margin-bottom: 0.75rem;
    letter-spacing: -0.5px;
}

.hero p {
    font-size: 1.25rem;
    color: rgba(255,255,255,0.85);
    font-weight: 300;
    margin-bottom: 2rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

/* Est. badge */
.est-badge {
    display: inline-block;
    font-family: var(--font-heading);
    font-size: 1rem;
    color: var(--amber);
    letter-spacing: 3px;
    text-transform: uppercase;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid rgba(200, 145, 58, 0.4);
}

/* Sub-page heroes (shorter) */
.hero-sub {
    min-height: 45vh;
    padding-top: 120px;
}

.hero-sub h1 {
    font-size: 2.75rem;
}


/* ---- 8. METRIC BAR ---- */
.metric-bar {
    background: var(--navy-dark);
    padding: 40px 0;
}

.metric-bar .container {
    display: flex;
    justify-content: center;
    gap: 60px;
    flex-wrap: wrap;
}

.metric-item {
    text-align: center;
}

.metric-number {
    font-family: var(--font-heading);
    font-size: 2.75rem;
    font-weight: 700;
    color: var(--amber);
    line-height: 1;
    margin-bottom: 6px;
}

.metric-label {
    font-size: 0.8125rem;
    font-weight: 600;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: rgba(255,255,255,0.6);
}


/* ---- 9. SERVICE CARDS ---- */
.services-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
    margin-top: 2rem;
}

.service-card {
    position: relative;
    overflow: hidden;
    border-radius: 4px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
    cursor: pointer;
    transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease);
}

.service-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 30px rgba(0,0,0,0.15);
}

.service-card-img {
    width: 100%;
    height: 280px;
    object-fit: cover;
    transition: transform 0.5s var(--ease);
}

.service-card:hover .service-card-img {
    transform: scale(1.05);
}

.service-card-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(27,42,74,0.9) 0%, transparent 60%);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 24px;
}

.service-card-overlay h3 {
    color: var(--white);
    font-size: 1.375rem;
    margin-bottom: 4px;
}

.service-card-overlay p {
    color: rgba(255,255,255,0.7);
    font-size: 0.875rem;
    margin-bottom: 0;
}


/* ---- 10. CONTENT SECTIONS ---- */
.content-block {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.content-block.reverse {
    direction: rtl;
}

.content-block.reverse > * {
    direction: ltr;
}

.content-block-text h2 {
    margin-bottom: 1rem;
}

.content-block-text p {
    color: var(--medium-gray);
    line-height: 1.8;
}

.content-block-img {
    border-radius: 4px;
    overflow: hidden;
    box-shadow: 0 8px 30px rgba(0,0,0,0.1);
}

.content-block-img img {
    width: 100%;
    height: 400px;
    object-fit: cover;
}

/* Feature list */
.feature-list {
    margin: 1.5rem auto 0;
    max-width: fit-content;
}

.feature-list li {
    padding: 8px 0;
    padding-left: 28px;
    position: relative;
    color: var(--medium-gray);
    line-height: 1.6;
}

.feature-list li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 16px;
    width: 12px;
    height: 2px;
    background: var(--amber);
}

/* Service areas */
.service-areas {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 1rem;
    justify-content: center;
}

.service-areas span {
    display: inline-block;
    padding: 6px 16px;
    background: var(--off-white);
    border-radius: 3px;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--navy);
    letter-spacing: 0.5px;
}

span.service-areas-note {
    background: transparent;
}


/* ---- 10b. HISTORY ARCHIVE PHOTOS ---- */
.history-photos {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
    margin-top: 2.5rem;
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
}

.history-photo {
    cursor: pointer;
    position: relative;
    overflow: hidden;
    border-radius: 8px;
}

.history-photo img {
    width: 100%;
    height: 280px;
    object-fit: cover;
    border-radius: 8px;
    filter: sepia(15%);
    transition: filter 0.3s ease, transform 0.3s ease;
}

.history-photo:hover img {
    filter: sepia(0%);
    transform: scale(1.02);
}

.history-photo-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 2rem 0.75rem 0.75rem;
    background: linear-gradient(transparent, rgba(0,0,0,0.7));
    color: #fff;
    font-size: 0.8125rem;
    font-style: italic;
    line-height: 1.4;
    text-align: center;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.history-photo:hover .history-photo-caption {
    opacity: 1;
}

@media (max-width: 600px) {
    .history-photos {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    .history-photo img {
        height: 220px;
    }
}


/* ---- 11. HISTORY TIMELINE ---- */
.timeline {
    position: relative;
    max-width: 800px;
    margin: 3rem auto 0;
    padding-left: 40px;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 15px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--light-gray);
}

.timeline-item {
    position: relative;
    padding-bottom: 3rem;
}

.timeline-item:last-child {
    padding-bottom: 0;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: -33px;
    top: 6px;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: var(--amber);
    border: 3px solid var(--white);
    box-shadow: 0 0 0 2px var(--amber);
}

.timeline-year {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--navy);
    margin-bottom: 0.25rem;
}

.timeline-text {
    color: var(--medium-gray);
    line-height: 1.7;
}


/* ---- 12. GALLERY ---- */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
    margin-top: 2rem;
}

.gallery-item {
    position: relative;
    overflow: hidden;
    border-radius: 3px;
    cursor: pointer;
    aspect-ratio: 1;
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s var(--ease);
}

.gallery-item:hover img {
    transform: scale(1.08);
}

.gallery-item::after {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(27, 42, 74, 0);
    transition: background 0.3s var(--ease);
}

.gallery-item:hover::after {
    background: rgba(27, 42, 74, 0.25);
}

/* Gallery section headings (categorized gallery) */
.gallery-section {
    margin-bottom: 3rem;
}

.gallery-section:last-child {
    margin-bottom: 0;
}

.gallery-section-title {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    color: var(--navy);
    margin-bottom: 1.5rem;
    text-align: center;
}

.gallery-section-title::after {
    content: '';
    display: block;
    width: 40px;
    height: 2px;
    background: var(--amber);
    margin: 0.5rem auto 0;
}

/* Service sub-page galleries */
.service-gallery {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    margin-top: 2rem;
}

.service-gallery .gallery-item {
    aspect-ratio: 1;
}

@media (max-width: 1024px) {
    .service-gallery {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .service-gallery {
        grid-template-columns: 1fr;
    }
}


/* ---- 12b. REMODEL ACCORDION CATEGORIES ---- */
.remodel-categories {
    text-align: left;
    margin-top: 2rem;
}

.remodel-category {
    border-bottom: 1px solid var(--light-gray);
}

.remodel-category:first-child {
    border-top: 1px solid var(--light-gray);
}

.remodel-category-toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 1.25rem 0.5rem;
    background: none;
    border: none;
    cursor: pointer;
    transition: color 0.2s var(--ease);
}

.remodel-category-toggle h3 {
    font-family: var(--font-heading);
    font-size: 1.35rem;
    font-weight: 700;
    color: var(--navy);
    margin: 0;
}

.remodel-category-toggle:hover h3 {
    color: var(--amber);
}

.toggle-icon {
    font-size: 1.5rem;
    font-weight: 300;
    color: var(--amber);
    transition: transform 0.3s var(--ease);
    line-height: 1;
    user-select: none;
}

.remodel-category.open .toggle-icon {
    transform: rotate(45deg);
}

.remodel-category-grid {
    display: none;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    padding: 0 0.5rem 1.5rem;
}

.remodel-category.open .remodel-category-grid {
    display: grid;
}

.remodel-category-grid .gallery-item {
    aspect-ratio: 1;
}

@media (max-width: 1024px) {
    .remodel-category-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .remodel-category-grid {
        grid-template-columns: 1fr;
    }

    .remodel-category-toggle h3 {
        font-size: 1.15rem;
    }
}


/* ---- 13. LIGHTBOX ---- */
.lightbox {
    position: fixed;
    inset: 0;
    z-index: 2000;
    background: rgba(0, 0, 0, 0.92);
    display: none;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s var(--ease);
}

.lightbox.active {
    display: flex;
    opacity: 1;
}

.lightbox-img {
    max-width: 90vw;
    max-height: 85vh;
    object-fit: contain;
    border-radius: 2px;
}

.lightbox-close {
    position: absolute;
    top: 20px;
    right: 24px;
    font-size: 2rem;
    color: var(--white);
    cursor: pointer;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.3s;
    background: none;
    border: none;
}

.lightbox-close:hover {
    color: var(--amber);
}

.lightbox-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    font-size: 2.5rem;
    color: var(--white);
    cursor: pointer;
    width: 56px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background 0.3s, color 0.3s;
    background: none;
    border: none;
}

.lightbox-nav:hover {
    background: rgba(255,255,255,0.1);
    color: var(--amber);
}

.lightbox-prev { left: 16px; }
.lightbox-next { right: 16px; }

.lightbox-counter {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    color: rgba(255,255,255,0.6);
    font-size: 0.875rem;
    letter-spacing: 2px;
}


/* ---- 14. CONTACT FORM ---- */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: start;
}

.contact-info h3 {
    margin-bottom: 1.5rem;
}

.contact-info-item {
    display: flex;
    gap: 16px;
    margin-bottom: 1.5rem;
    align-items: flex-start;
}

.contact-info-icon {
    width: 20px;
    flex-shrink: 0;
    margin-top: 3px;
    color: var(--amber);
    font-size: 1.125rem;
}

.contact-info-text strong {
    display: block;
    font-size: 0.8125rem;
    letter-spacing: 1px;
    text-transform: uppercase;
    color: var(--navy);
    margin-bottom: 2px;
}

.contact-info-text span,
.contact-info-text a {
    color: var(--medium-gray);
    font-size: 0.9375rem;
}

.contact-form {
    background: var(--white);
    padding: 40px;
    border-radius: 4px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 16px;
}

.form-group {
    margin-bottom: 16px;
}

.form-group label {
    display: block;
    font-size: 0.8125rem;
    font-weight: 600;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    color: var(--navy);
    margin-bottom: 6px;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid var(--light-gray);
    border-radius: 3px;
    font-family: var(--font-body);
    font-size: 0.9375rem;
    color: var(--charcoal);
    transition: border-color 0.3s var(--ease);
    background: var(--white);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--amber);
}

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

.form-group input.error,
.form-group textarea.error {
    border-color: #c0392b;
}

.form-error {
    font-size: 0.75rem;
    color: #c0392b;
    margin-top: 4px;
    display: none;
}

.form-group.has-error .form-error {
    display: block;
}

.form-success {
    background: #d4edda;
    color: #155724;
    padding: 16px;
    border-radius: 3px;
    margin-bottom: 16px;
    display: none;
    text-align: center;
}

.form-success.visible {
    display: block;
}


/* ---- 15. FOOTER ---- */
.site-footer {
    background: var(--navy-dark);
    color: rgba(255,255,255,0.7);
    padding: 60px 0 30px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 40px;
}

.footer-brand img {
    height: 50px;
    width: auto;
    max-width: 280px;
    margin-bottom: 1rem;
    filter: brightness(1.2);
}

.footer-brand p {
    color: rgba(255,255,255,0.5);
    font-size: 0.875rem;
    line-height: 1.7;
    max-width: 300px;
}

.footer-heading {
    font-family: var(--font-body);
    font-size: 0.8125rem;
    font-weight: 600;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: var(--white);
    margin-bottom: 1.25rem;
}

.footer-links a {
    display: block;
    color: rgba(255,255,255,0.5);
    font-size: 0.875rem;
    padding: 4px 0;
    transition: color 0.3s;
}

.footer-links a:hover {
    color: var(--amber);
}

.footer-contact-item {
    font-size: 0.875rem;
    margin-bottom: 0.75rem;
    color: rgba(255,255,255,0.5);
}

.footer-contact-item strong {
    color: rgba(255,255,255,0.7);
}

.footer-social {
    display: flex;
    gap: 12px;
    margin-top: 1rem;
}

.footer-social a {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 1px solid rgba(255,255,255,0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255,255,255,0.6);
    font-size: 0.875rem;
    transition: all 0.3s var(--ease);
}

.footer-social a:hover {
    background: var(--amber);
    border-color: var(--amber);
    color: var(--white);
}

.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.8125rem;
    color: rgba(255,255,255,0.35);
}


/* ---- 16. SPA SECTION VISIBILITY ---- */
.page-section {
    display: none;
}

.page-section.active {
    display: block;
}


/* ---- 17. SCROLL ANIMATIONS ---- */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}

.animate-on-scroll.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Staggered children */
.stagger-children .animate-on-scroll:nth-child(2) { transition-delay: 0.1s; }
.stagger-children .animate-on-scroll:nth-child(3) { transition-delay: 0.2s; }
.stagger-children .animate-on-scroll:nth-child(4) { transition-delay: 0.3s; }


/* ---- 18. DIVIDERS & DECORATIVE ---- */
.section-divider {
    width: 60px;
    height: 2px;
    background: var(--amber);
    margin: 0 auto 2rem;
}

.bg-navy .section-divider {
    background: var(--amber);
}


/* ---- 19. RESPONSIVE — TABLET (max 1024px) ---- */
@media (max-width: 1024px) {
    :root {
        --section-pad: 60px;
    }

    h1 { font-size: 2.5rem; }
    h2 { font-size: 1.875rem; }

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

    .services-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }

    .content-block {
        gap: 40px;
    }

    .gallery-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: 30px;
    }

    .contact-grid {
        gap: 40px;
    }
}


/* ---- 20. RESPONSIVE — MOBILE (max 768px) ---- */
@media (max-width: 768px) {
    :root {
        --section-pad: 48px;
        --header-h: 64px;
    }

    h1 { font-size: 2rem; }
    h2 { font-size: 1.5rem; }
    h3 { font-size: 1.25rem; }

    .header-logo img {
        height: 50px;
        max-width: 275px;
    }

    /* Mobile nav */
    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 280px;
        height: 100vh;
        background: var(--navy-dark);
        flex-direction: column;
        align-items: flex-start;
        padding: 100px 24px 24px;
        gap: 4px;
        transition: right 0.35s var(--ease);
        box-shadow: -4px 0 20px rgba(0,0,0,0.2);
    }

    .nav-links.open {
        right: 0;
    }

    .nav-links a {
        width: 100%;
        padding: 12px 16px;
        font-size: 0.875rem;
    }

    .nav-dropdown-menu {
        position: static;
        opacity: 1;
        visibility: visible;
        transform: none;
        box-shadow: none;
        background: rgba(255,255,255,0.05);
        border-radius: 0;
        padding: 0;
        margin-left: 16px;
        display: none;
    }

    .nav-dropdown.open .nav-dropdown-menu {
        display: block;
    }

    .nav-dropdown-menu a {
        color: rgba(255,255,255,0.7);
        font-size: 0.8125rem;
        padding: 10px 16px;
    }

    .nav-dropdown-menu a:hover {
        background: rgba(255,255,255,0.05);
        color: var(--amber);
    }

    .hamburger {
        display: flex;
    }

    /* Mobile nav overlay */
    .nav-overlay {
        display: none;
        position: fixed;
        inset: 0;
        background: rgba(0,0,0,0.4);
        z-index: 999;
    }

    .nav-overlay.active {
        display: block;
    }

    /* Hero */
    .hero {
        min-height: 70vh;
        padding: 100px 20px 60px;
    }

    .hero h1 { font-size: 2.25rem; }
    .hero p { font-size: 1.0625rem; }

    .hero-sub {
        min-height: 35vh;
    }

    /* Metric bar */
    .metric-bar .container {
        gap: 30px;
    }

    .metric-number {
        font-size: 2rem;
    }

    /* Service cards */
    .services-grid {
        grid-template-columns: 1fr;
    }

    .service-card-img {
        height: 220px;
    }

    /* Content blocks */
    .content-block {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    .content-block.reverse {
        direction: ltr;
    }

    .content-block-img img {
        height: 280px;
    }

    /* Gallery */
    .gallery-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
    }

    /* Contact */
    .contact-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .contact-form {
        padding: 24px;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    /* Footer */
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .footer-bottom {
        flex-direction: column;
        gap: 8px;
        text-align: center;
    }

    /* Lightbox */
    .lightbox-nav {
        width: 44px;
        height: 44px;
        font-size: 2rem;
    }

    .lightbox-prev { left: 8px; }
    .lightbox-next { right: 8px; }
}


/* ---- 21. RESPONSIVE — SMALL MOBILE (max 480px) ---- */
@media (max-width: 480px) {
    .hero h1 { font-size: 1.875rem; }
    .hero p { font-size: 1rem; }

    .metric-bar .container {
        flex-direction: column;
        gap: 20px;
    }

    .gallery-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .container {
        padding: 0 16px;
    }
}


/* ---- 22. PRINT ---- */
@media print {
    .site-header,
    .site-footer,
    .lightbox,
    .hamburger,
    .nav-overlay {
        display: none !important;
    }

    .page-section {
        display: block !important;
        page-break-before: always;
    }

    .hero {
        min-height: auto;
        padding: 40px 0;
    }

    .hero::before {
        display: none;
    }

    body {
        color: #000;
        background: #fff;
    }
}
