/* =========================================
   THE CAROLINA COMMERCIAL ROOFING EXPERTS
   Main Website Styles
========================================= */

:root {
    --navy: #082d52;
    --blue: #0867b8;
    --bright-blue: #0878d1;
    --light-blue: #eef7fd;
    --white: #ffffff;
    --dark: #17202a;
    --gray: #66727d;
    --light-gray: #f5f8fa;
    --border: #dce5eb;
}


/* =========================================
   RESET
========================================= */

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: Arial, Helvetica, sans-serif;
    color: var(--dark);
    background: var(--white);
    line-height: 1.6;
}

img {
    width: 100%;
    display: block;
}

a {
    text-decoration: none;
    color: inherit;
}

ul {
    list-style: none;
}


/* =========================================
   CONTAINER
========================================= */

.container {
    width: 90%;
    max-width: 1180px;
    margin: 0 auto;
}


/* =========================================
   HEADER
========================================= */

header {
    background: var(--white);
    border-bottom: 1px solid #e5e5e5;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.navbar {
    max-width: 1180px;
    min-height: 92px;

    margin: 0 auto;
    padding: 8px 20px;

    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 30px;
}


/* LOGO */

.logo {
    display: flex;
    align-items: center;
}

.logo img {
    width: 115px;
    height: auto;
}


/* NAVIGATION */

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

.nav-links a {
    color: var(--dark);
    font-size: 14px;
    font-weight: 600;

    position: relative;

    transition: color 0.25s ease;
}

.nav-links a:hover {
    color: var(--blue);
}

.nav-links a::after {
    content: "";

    position: absolute;
    left: 0;
    bottom: -10px;

    width: 0;
    height: 3px;

    background: var(--blue);

    transition: width 0.25s ease;
}

.nav-links a:hover::after {
    width: 100%;
}


/* PHONE BUTTON */

.phone-button {
    background: var(--blue);
    color: white;

    padding: 12px 20px;

    border-radius: 5px;

    font-size: 14px;
    font-weight: 700;

    white-space: nowrap;

    transition: background 0.25s ease;
}

.phone-button:hover {
    background: var(--navy);
}


/* =========================================
   HERO
========================================= */

.hero {
    min-height: 470px;

    display: flex;
    align-items: center;

    background:
        linear-gradient(90deg,
            rgba(4, 31, 57, 0.85) 0%,
            rgba(4, 31, 57, 0.55) 50%,
            rgba(4, 31, 57, 0.25) 100%),
        url("../images/project-5.png");

    background-size: cover;
    background-position: center;
}

.hero-content {
    max-width: 1180px;
    width: 90%;

    margin: 0 auto;

    color: white;
}

.hero-eyebrow {
    font-size: 13px;
    font-weight: 700;

    letter-spacing: 2px;

    margin-bottom: 8px;
}

.hero h1 {
    max-width: 650px;

    font-size: clamp(42px, 6vw, 68px);

    line-height: 0.98;

    text-transform: uppercase;

    margin-bottom: 20px;
}

.hero-description {
    max-width: 570px;

    font-size: 17px;

    margin-bottom: 25px;

    color: #f1f5f8;
}


/* HERO BUTTON */

.primary-button {
    display: inline-block;

    background: var(--blue);
    color: white;

    padding: 13px 24px;

    border-radius: 4px;

    font-size: 13px;
    font-weight: 700;

    text-transform: uppercase;

    transition:
        background 0.25s ease,
        transform 0.2s ease;
}

.primary-button:hover {
    background: var(--bright-blue);
    transform: translateY(-2px);
}


/* =========================================
   TRUST / CHECKLIST
========================================= */

.hero-services {
    margin-top: 25px;

    display: grid;
    grid-template-columns: repeat(2, max-content);

    gap: 5px 25px;
}

.hero-services li {
    font-size: 13px;
    font-weight: 600;
}

.hero-services li::before {
    content: "✓";

    color: #ffffff;

    font-weight: bold;

    margin-right: 7px;
}


/* =========================================
   ABOUT SECTION
========================================= */

.about {
    padding: 65px 0;

    background: var(--white);
}

.about-grid {
    display: grid;

    grid-template-columns: 1fr 1fr;

    gap: 45px;

    align-items: center;
}

.about-image {
    width: 100%;
    overflow: hidden;
    border-radius: 3px;
}

.about-image img {
    width: 100%;
    height: 350px;
    display: block;
    object-fit: cover;
}

.section-label {
    color: var(--blue);

    font-size: 11px;
    font-weight: 800;

    letter-spacing: 2px;

    text-transform: uppercase;

    margin-bottom: 5px;
}

.about h2 {
    color: var(--navy);

    font-size: 35px;

    line-height: 1.1;

    margin-bottom: 18px;
}

.about p {
    color: var(--gray);

    font-size: 14px;

    margin-bottom: 20px;
}


/* =========================================
   SERVICES
========================================= */

.services {
    padding: 65px 0;

    background: var(--light-blue);

    text-align: center;
}

.services-heading {
    margin-bottom: 40px;
}

.services-heading h2 {
    color: var(--navy);

    font-size: 34px;

    line-height: 1.15;
}


/* SERVICE GRID */

.service-grid {
    display: grid;

    grid-template-columns: repeat(4, 1fr);

    gap: 20px;
}


/* SERVICE CARD */

.service-card {
    background: white;

    padding: 28px 18px;

    border: 1px solid var(--border);

    transition:
        transform 0.25s ease,
        box-shadow 0.25s ease;
}

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

    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.08);
}


/* ICON */

.service-icon {
    width: 55px;
    height: 55px;

    margin: 0 auto 15px;

    border-radius: 50%;

    background: #edf7ff;

    display: flex;
    align-items: center;
    justify-content: center;

    color: var(--blue);

    font-size: 25px;
}

.service-card h3 {
    color: var(--navy);

    font-size: 17px;

    margin-bottom: 8px;
}

.service-card p {
    color: var(--gray);

    font-size: 12px;
}


/* =========================================
   OUR WORK
========================================= */

.work {
    padding: 70px 0;

    background: white;
}

.work-heading {
    text-align: center;

    margin-bottom: 35px;
}

.work-heading h2 {
    color: var(--navy);

    font-size: 34px;
}

.work-grid {
    display: grid;

    grid-template-columns: repeat(3, 1fr);

    gap: 18px;
}

.work-item {
    overflow: hidden;

    height: 250px;

    position: relative;
}

.work-item img {
    width: 100%;
    height: 100%;

    object-fit: cover;

    transition: transform 0.4s ease;
}

.work-item:hover img {
    transform: scale(1.06);
}


/* =========================================
   CONTACT CTA
========================================= */

.contact-cta {
    padding: 60px 0;

    color: white;

    background:
        linear-gradient(rgba(5, 40, 72, 0.9),
            rgba(5, 40, 72, 0.9)),
        url("../images/contact-background.jpg");

    background-size: cover;
    background-position: center;
}

.contact-grid {
    display: grid;

    grid-template-columns: 1fr 1fr;

    align-items: center;

    gap: 40px;
}

.contact-cta h2 {
    font-size: 38px;

    line-height: 1.1;

    margin-bottom: 10px;
}

.contact-cta p {
    color: #dce9f3;

    margin-bottom: 20px;
}

.contact-details {
    display: flex;
    flex-direction: column;

    gap: 7px;
}

.contact-details span {
    font-size: 14px;
}


/* =========================================
   FOOTER
========================================= */

footer {
    background: #061d34;

    color: #b9c7d3;

    padding: 25px 0;

    font-size: 12px;
}

.footer-grid {
    display: flex;

    justify-content: space-between;

    align-items: center;

    gap: 20px;
}

/* =========================================
   INNER PAGE HERO
========================================= */

.page-hero {
    padding: 90px 0;

    background:
        linear-gradient(rgba(5, 40, 72, 0.88),
            rgba(5, 40, 72, 0.88)),
        url("../images/project-5.png");

    background-size: cover;
    background-position: center;

    color: white;
}

.page-hero h1 {
    max-width: 700px;

    font-size: clamp(40px, 5vw, 60px);

    line-height: 1.05;

    margin-bottom: 15px;
}

.page-hero p:not(.section-label) {
    max-width: 600px;

    color: #dce9f3;

    font-size: 17px;
}

/* =========================================
   SERVICES PAGE
========================================= */

.services-heading>p:not(.section-label) {
    max-width: 700px;

    margin: 15px auto 0;

    color: var(--gray);

    font-size: 15px;
}

.commercial-services {
    background: #ffffff;
}

.commercial-services .service-card {
    border-top: 4px solid var(--blue);
}

/* =========================================
   OUR WORK PAGE
========================================= */

.work-heading p:not(.section-label) {
    color: var(--gray);

    font-size: 15px;
}


/* PROJECT GRID */

.work-grid {
    display: grid;

    grid-template-columns: repeat(3, 1fr);

    gap: 25px;
}


/* PROJECT CARD */

.project-card {
    background: var(--white);

    border: 1px solid var(--border);

    overflow: hidden;

    transition:
        transform 0.25s ease,
        box-shadow 0.25s ease;
}

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

    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.10);
}


/* PROJECT IMAGE */

.project-image {
    height: 240px;

    overflow: hidden;
}

.project-image img {
    width: 100%;
    height: 100%;

    object-fit: cover;

    transition: transform 0.4s ease;
}

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


/* PROJECT INFORMATION */

.project-info {
    padding: 22px;
}

.project-info span {
    color: var(--blue);

    font-size: 10px;
    font-weight: 800;

    letter-spacing: 1.5px;
}

.project-info h3 {
    color: var(--navy);

    font-size: 19px;

    line-height: 1.2;

    margin: 7px 0 10px;
}

.project-info p {
    color: var(--gray);

    font-size: 13px;
}


/* =========================================
   WORK PAGE MOBILE
========================================= */

@media (max-width: 900px) {

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

}


@media (max-width: 600px) {

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

    .project-image {
        height: 230px;
    }

}

/* =========================================
   CONTACT PAGE
========================================= */

.contact-page {
    padding: 80px 0;
    background: var(--light-gray);
}

.contact-page-grid {
    display: grid;

    grid-template-columns: 0.85fr 1.15fr;

    gap: 60px;

    align-items: start;
}


/* CONTACT INFORMATION */

.contact-information {
    padding-top: 10px;
}

.contact-information h2 {
    color: var(--navy);

    font-size: 38px;

    line-height: 1.1;

    margin-bottom: 15px;
}

.contact-information>p:not(.section-label) {
    color: var(--gray);

    font-size: 15px;

    margin-bottom: 35px;

    max-width: 500px;
}


/* CONTACT ITEMS */

.contact-info-item {
    display: flex;

    align-items: flex-start;

    gap: 15px;

    margin-bottom: 25px;
}

.contact-info-icon {
    min-width: 45px;
    height: 45px;

    display: flex;

    align-items: center;
    justify-content: center;

    background: #e5f3fd;

    color: var(--blue);

    border-radius: 50%;

    font-size: 18px;
}

.contact-info-item h3 {
    color: var(--navy);

    font-size: 15px;

    margin-bottom: 2px;
}

.contact-info-item p,
.contact-info-item a {
    color: var(--gray);

    font-size: 14px;
}

.contact-info-item a:hover {
    color: var(--blue);
}


/* =========================================
   ESTIMATE FORM
========================================= */

.estimate-form-container {
    background: var(--white);

    padding: 40px;

    border: 1px solid var(--border);

    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.06);
}

.form-heading {
    margin-bottom: 25px;
}

.form-heading h2 {
    color: var(--navy);

    font-size: 30px;

    line-height: 1.15;

    margin-bottom: 8px;
}

.form-heading p:not(.section-label) {
    color: var(--gray);

    font-size: 14px;
}


/* FORM ROW */

.form-row {
    display: grid;

    grid-template-columns: 1fr 1fr;

    gap: 15px;
}


/* FORM GROUP */

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

.form-group label {
    display: block;

    color: var(--navy);

    font-size: 13px;

    font-weight: 700;

    margin-bottom: 7px;
}


/* INPUTS */

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;

    padding: 13px 14px;

    border: 1px solid var(--border);

    border-radius: 4px;

    background: white;

    color: var(--dark);

    font-family: inherit;

    font-size: 14px;

    outline: none;

    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease;
}


.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    border-color: var(--blue);

    box-shadow:
        0 0 0 3px rgba(8, 103, 184, 0.10);
}


.form-group textarea {
    resize: vertical;

    min-height: 120px;
}


/* SUBMIT BUTTON */

.form-submit {
    width: 100%;

    border: none;

    background: var(--blue);

    color: white;

    padding: 15px 20px;

    border-radius: 4px;

    font-family: inherit;

    font-size: 14px;

    font-weight: 800;

    text-transform: uppercase;

    cursor: pointer;

    transition:
        background 0.25s ease,
        transform 0.2s ease;
}

.form-submit:hover {
    background: var(--navy);

    transform: translateY(-2px);
}


/* FORM NOTE */

.form-note {
    color: #7a858e;

    font-size: 11px;

    line-height: 1.5;

    text-align: center;

    margin-top: 12px;
}


/* =========================================
   CONTACT PAGE MOBILE
========================================= */

@media (max-width: 900px) {

    .contact-page-grid {
        grid-template-columns: 1fr;

        gap: 45px;
    }

}


@media (max-width: 600px) {

    .contact-page {
        padding: 55px 0;
    }

    .estimate-form-container {
        padding: 25px 20px;
    }

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

    .contact-information h2 {
        font-size: 30px;
    }

}


/* =========================================
   MOBILE
========================================= */

@media (max-width: 900px) {

    .navbar {
        flex-wrap: wrap;
        justify-content: center;
    }

    .nav-links {
        order: 3;

        width: 100%;

        justify-content: center;
    }

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

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

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


@media (max-width: 600px) {

    .navbar {
        padding: 12px 15px;
    }

    .logo img {
        width: 90px;
    }

    .nav-links {
        gap: 15px;

        flex-wrap: wrap;
    }

    .nav-links a {
        font-size: 12px;
    }

    .phone-button {
        font-size: 12px;

        padding: 9px 12px;
    }


    .hero {
        min-height: 600px;
    }

    .hero h1 {
        font-size: 42px;
    }

    .hero-description {
        font-size: 15px;
    }

    .hero-services {
        grid-template-columns: 1fr;
    }


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

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

    .work-item {
        height: 220px;
    }


    .about h2 {
        font-size: 30px;
    }

    .services-heading h2 {
        font-size: 29px;
    }


    .footer-grid {
        flex-direction: column;

        text-align: center;
    }
}

/* =========================================
   BEFORE & AFTER PROJECTS
========================================= */

.before-after-section {
    padding: 70px 0;
    background: #f7f9fb;
}

.before-after-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
}

.comparison-card {
    background: white;
    border: 1px solid var(--border);
    overflow: hidden;
}

.comparison-images {
    display: grid;
    grid-template-columns: 1fr 1fr;
}

.comparison-image {
    position: relative;
    height: 330px;
    overflow: hidden;
}

.comparison-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.comparison-label {
    position: absolute;
    top: 15px;
    left: 15px;

    z-index: 2;

    background: var(--navy);
    color: white;

    padding: 8px 14px;

    font-size: 12px;
    font-weight: 800;
    letter-spacing: 1px;

    border-radius: 3px;
}


@media (max-width: 900px) {

    .before-after-grid {
        grid-template-columns: 1fr;
    }

}


@media (max-width: 600px) {

    .comparison-images {
        grid-template-columns: 1fr;
    }

    .comparison-image {
        height: 280px;
    }

}