/* GRC Services - Complete Archive Match CSS for GeneratePress */

/* ==========================================================================
   1. Color Variables & Font Setup
   ========================================================================== */
:root {
    --grc-red: #ec1d25;
    --grc-red-dark: #d80f0f;
    --grc-dark: #191919;
    --grc-yellow: #faee1e;
    --grc-gray: #f3f3f3;
    --grc-text: rgb(91,91,91);
}

html, body {
    overflow-x: hidden;
    margin: 0 !important;
    padding: 0 !important;
}

body {
    font-family: "Lato", sans-serif;
    color: var(--grc-text);
    background-color: var(--grc-gray);
    width: 100% !important;
    max-width: 100% !important;
    position: relative !important;
}

/* Hide sidebar on all pages - full width content */
body.page #right-sidebar,
body.single #right-sidebar,
body.page .sidebar,
body.single .sidebar,
body.page aside.widget-area,
body.single aside.widget-area,
#right-sidebar,
.sidebar,
aside.widget-area {
    display: none !important;
}

body.page .site-content,
body.single .site-content,
.site-content {
    display: block !important;
}

body.page .content-area,
body.single .content-area,
.content-area {
    width: 100% !important;
    float: none !important;
}

/* ==========================================================================
   1.1 GeneratePress Container Width Overrides - Force Full Width
   ========================================================================== */

/* Make page container full viewport width */
#page.site,
.site.grid-container,
body > .site {
    width: 100% !important;
    max-width: 100% !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
    overflow-x: hidden !important;
}

/* Override GeneratePress default container widths */
.container,
.grid-container,
.inside-article,
.entry-content {
    max-width: 100% !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
}

/* Ensure main content wrapper is full width */
.site-content .content-area {
    max-width: 100% !important;
    width: 100% !important;
}

/* GeneratePress specific - remove content area constraint */
.separate-containers .inside-article {
    padding: 0 !important;
}

/* Force full width on site-main - remove GeneratePress right margin */
.site-main {
    margin-right: 0 !important;
    margin-left: 0 !important;
    width: 100% !important;
    max-width: 100% !important;
}

.separate-containers .site-main > article,
.separate-containers .inside-article,
body.page .inside-article,
body.home .inside-article {
    margin: 0 !important;
    padding: 0 !important;
    background: transparent !important;
}

/* Full-width sections - match body width */
.hero-section,
.footer-cta,
.services-section {
    width: 100% !important;
    max-width: 100% !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
    box-sizing: border-box !important;
}

/* Hero cover blocks - full width within content area */
.wp-block-cover,
.wp-block-cover.alignfull,
.entry-content > .alignfull,
.entry-content > .wp-block-cover,
body.page .wp-block-cover,
body.home .wp-block-cover {
    width: 100% !important;
    max-width: 100% !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
    box-sizing: border-box !important;
}

/* Ensure blocks inside entry-content can go full width */
.entry-content,
.site-content {
    overflow-x: hidden !important;
    overflow-y: visible !important;
}

/* Override any GeneratePress padding on full-width elements */
body .site-content .content-area .inside-article {
    padding: 0 !important;
}

/* Remove GeneratePress container width limits */
body.page .site-content,
body.home .site-content,
body.page .content-area,
body.home .content-area {
    max-width: 100% !important;
    width: 100% !important;
}

/* Centered content wrapper for sections that need it */
.centered-content-wrapper {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Hide page titles on all pages including service subpages */
body.page .entry-header,
body.single .entry-header,
body.home .entry-header,
.page .entry-header,
.single .entry-header,
.home .entry-header,
.entry-header {
    display: none !important;
}

/* ==========================================================================
   2. Header Styles - GeneratePress Specific
   ========================================================================== */
.site-header,
header.site-header,
#masthead,
.main-navigation,
#site-navigation,
nav.main-navigation,
.inside-navigation {
    background-color: var(--grc-red) !important;
}

/* Force compact header height */
.site-header,
.inside-header {
    padding-top: 5px !important;
    padding-bottom: 5px !important;
}

/* Logo sizing - match archive at 135px width */
.site-header .site-branding img,
.custom-logo,
.site-logo img {
    max-height: 80px !important;
    width: 135px !important;
    height: auto !important;
}

/* Site branding compact */
.site-branding {
    padding: 3px 0 !important;
}

/* Hide site title and description text next to logo */
.site-title,
.site-branding .site-title,
h1.site-title,
.main-title {
    display: none !important;
}

.site-description {
    display: none !important;
}

/* Navigation menu styling */
.main-navigation a,
.menu > li > a,
.main-nav ul li a {
    color: #ffffff !important;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    font-size: 16px !important;
    padding: 10px 12px !important;
    line-height: 1.2 !important;
}

.main-navigation a:hover,
.main-nav ul li a:hover {
    color: rgba(255,255,255,0.8) !important;
}

/* Desktop navigation in one line */
@media (min-width: 769px) {
    .main-navigation ul,
    .main-nav > ul {
        display: flex !important;
        flex-wrap: nowrap !important;
        align-items: center !important;
        justify-content: flex-end !important;
    }

    .main-navigation ul li,
    .main-nav > ul > li {
        white-space: nowrap !important;
    }

    /* Dropdown menu container - HIDDEN BY DEFAULT */
    #site-navigation .sub-menu,
    #primary-menu .sub-menu,
    .main-navigation .sub-menu,
    .main-nav ul ul,
    .sf-menu ul,
    #menu-item-55 > .sub-menu,
    #menu-item-55-sub-menu {
        display: none !important;
        visibility: hidden !important;
        opacity: 0 !important;
        position: absolute !important;
        top: 100% !important;
        left: 0 !important;
        min-width: 200px !important;
        background-color: var(--grc-red) !important;
        flex-direction: column !important;
        z-index: 9999 !important;
        box-shadow: 0px 4px 8px rgba(0,0,0,0.2) !important;
        transition: opacity 0.2s ease, visibility 0.2s ease !important;
    }

    /* Show on hover - FLEX COLUMN for vertical layout */
    #site-navigation li.menu-item-has-children:hover > .sub-menu,
    #primary-menu li.menu-item-has-children:hover > .sub-menu,
    .main-navigation li.menu-item-has-children:hover > .sub-menu,
    .main-nav ul li.menu-item-has-children:hover > ul,
    #menu-item-55:hover > .sub-menu,
    #menu-item-55:hover > #menu-item-55-sub-menu {
        display: flex !important;
        visibility: visible !important;
        opacity: 1 !important;
        flex-direction: column !important;
    }

    /* Dropdown menu list items - BLOCK display for vertical stacking */
    #site-navigation .sub-menu li,
    #primary-menu .sub-menu li,
    .main-navigation .sub-menu li,
    .main-nav ul ul li {
        display: block !important;
        width: 100% !important;
        float: none !important;
    }

    /* Dropdown menu items - white text on red background, FULL WIDTH */
    #site-navigation .sub-menu a,
    #primary-menu .sub-menu a,
    .main-navigation .sub-menu a,
    .main-nav ul ul a {
        display: block !important;
        width: 100% !important;
        white-space: nowrap !important;
        font-size: 12px !important;
        padding: 10px 15px !important;
        background-color: var(--grc-red) !important;
        color: #ffffff !important;
        font-weight: 700 !important;
        text-transform: uppercase !important;
        letter-spacing: 0.03em !important;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1) !important;
    }

    /* Dropdown menu item hover */
    #site-navigation .sub-menu a:hover,
    #primary-menu .sub-menu a:hover,
    .main-navigation .sub-menu a:hover,
    .main-nav ul ul a:hover {
        background-color: var(--grc-red-dark) !important;
        color: #ffffff !important;
    }

    /* Remove border from last item */
    #site-navigation .sub-menu li:last-child a,
    #primary-menu .sub-menu li:last-child a,
    .main-navigation .sub-menu li:last-child a,
    .main-nav ul ul li:last-child a {
        border-bottom: none !important;
    }
}

/* ==========================================================================
   2.1 Top Bar - Custom PHP output styling
   ========================================================================== */
.grc-top-bar {
    background-color: var(--grc-dark) !important;
    color: #ffffff;
    padding: 6px 0 !important;
    font-size: 12px !important;
    line-height: 1.3 !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 !important;
    box-sizing: border-box !important;
}

.grc-top-bar-container {
    max-width: 100%;
    margin: 0 auto;
    padding: 0 20px;
}

.grc-top-bar-content {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    flex-wrap: wrap;
}

.grc-top-bar-text {
    color: #ffffff;
}

.grc-top-bar-phone {
    color: #ffffff !important;
    text-decoration: none;
    font-weight: 700;
    transition: color 0.3s ease;
}

.grc-top-bar-phone:hover {
    color: var(--grc-yellow) !important;
}

.grc-phone-number {
    letter-spacing: 0.5px;
}

/* Mobile top bar - stacked */
@media (max-width: 767px) {
    .grc-top-bar {
        padding: 12px 15px !important;
    }

    .grc-top-bar-content {
        flex-direction: column;
        gap: 10px;
    }

    .grc-top-bar-separator {
        display: none;
    }

    .grc-top-bar-phone {
        display: inline-block;
        background-color: var(--grc-red);
        padding: 12px 24px;
        border-radius: 4px;
        min-height: 48px;
        line-height: 24px;
        font-size: 16px;
        font-weight: 700;
        text-align: center;
        width: auto;
        box-shadow: 0 2px 4px rgba(0,0,0,0.2);
    }

    .grc-top-bar-phone:active {
        transform: scale(0.98);
    }

    .grc-top-bar-text {
        text-align: center;
        font-size: 16px;
        line-height: 1.4;
    }

    .grc-top-bar-call {
        font-size: 16px;
    }
}

/* ==========================================================================
   3. Hero Section Styles
   ========================================================================== */
/* Full-width hero section - break out of GeneratePress container */
.wp-block-cover.alignfull,
.wp-block-cover.hero-section {
    min-height: 500px;
    background-size: cover !important;
    background-position: center center !important;
    background-attachment: fixed !important;
    width: 100% !important;
    max-width: none !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
    box-sizing: border-box !important;
}

.wp-block-cover.hero-section .wp-block-cover__image-background {
    background-size: cover !important;
    background-position: center center !important;
    background-attachment: fixed !important;
}

.hero-cta-container {
    background: var(--grc-red) !important;
    padding: 25px !important;
    color: #fff !important;
    border: 3px solid #fff !important;
    box-shadow: 0px 0px 8px 0px rgba(0,0,0,0.34) !important;
    margin-top: 30px !important;
    margin-bottom: 70px !important;
}

.hero-right-container {
    background: rgba(0,0,0,0.4) !important;
    padding: 25px !important;
    color: #fff !important;
    margin-top: 30px !important;
}

.hero-tagline-1,
.wp-block-heading.hero-tagline-1 {
    margin-top: 0px !important;
    color: #fff !important;
    font-size: 2.3em !important;
    letter-spacing: 1px !important;
}

.hero-tagline-2,
.wp-block-heading.hero-tagline-2 {
    margin-top: 0px !important;
    color: #fff !important;
}

.hero-tagline-3,
.wp-block-heading.hero-tagline-3 {
    margin-top: 25px !important;
    color: var(--grc-yellow) !important;
    font-size: 1.8em !important;
    letter-spacing: 1px !important;
}

/* ==========================================================================
   4. Services Grid Styles
   ========================================================================== */
.services-section {
    padding: 40px 20px;
}

.services-section h2 {
    text-align: center;
    color: #fff;
    text-shadow: 2px 2px 2px rgba(0,0,0,0.3);
}

.services-section p {
    text-align: center;
    color: #fff;
    text-shadow: 2px 2px 2px rgba(0,0,0,0.3);
    font-size: 1.3em;
}

.services-grid {
    display: grid;
    gap: 25px;
    max-width: 1200px;
    margin: 20px auto;
}

.services-row-4 {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 25px;
    margin-bottom: 20px;
}

.services-row-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 25px;
    max-width: 900px;
    margin: 0 auto;
}

.service-card {
    background: rgba(236,29,37,0.8);
    padding: 12px;
    box-shadow: 0px 0px 8px 0px rgba(0,0,0,0.34);
    text-align: center;
}

.service-card img {
    width: 100%;
    height: auto;
    margin-bottom: 10px;
}

.service-card a {
    display: block;
    background: var(--grc-red);
    border: 2px solid #fff;
    color: #fff !important;
    padding: 12px 10px;
    text-decoration: none !important;
    font-weight: 700;
    text-transform: uppercase;
    border-radius: 4px;
    font-size: 12px;
    transition: all 0.3s ease;
    line-height: 1.4;
    min-height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.service-card a:hover {
    background: var(--grc-red);
    border-color: var(--grc-dark);
}

/* WordPress Blocks version */
.wp-block-columns.services-row {
    gap: 25px;
    margin-bottom: 25px;
}

.wp-block-column.service-item {
    background: rgba(236,29,37,0.8);
    padding: 12px;
    box-shadow: 0px 0px 8px 0px rgba(0,0,0,0.34);
    text-align: center;
}

.wp-block-column.service-item .wp-block-image {
    margin-bottom: 10px;
}

.wp-block-column.service-item .wp-block-button__link {
    background: var(--grc-dark) !important;
    border: 2px solid #fff !important;
    width: 100%;
    font-size: 12px;
    padding: 12px 10px !important;
    line-height: 1.4;
    min-height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.wp-block-column.service-item .wp-block-button__link:hover {
    background: var(--grc-dark) !important;
}

/* Target service columns with has-background class */
.wp-block-column.has-background {
    box-shadow: 0px 0px 8px 0px rgba(0,0,0,0.34);
}

.wp-block-column.has-background .wp-block-button__link {
    background: var(--grc-dark) !important;
    border: 2px solid #fff !important;
}

/* Center the second row of services (3 columns) - Archive match */
.wp-block-columns:has(> .wp-block-column.has-background):has(> .wp-block-column:nth-child(3):last-child) {
    max-width: 900px;
    margin-left: auto !important;
    margin-right: auto !important;
}

/* ==========================================================================
   5. Licensed & Insured Section
   ========================================================================== */
.licensed-section {
    max-width: 1200px;
    margin: 40px auto;
    padding: 20px;
}

.licensed-section .wp-block-columns {
    align-items: center;
}

.licensed-section img {
    max-width: 100%;
}

.licensed-section h2,
.licensed-section h3 {
    color: #272727;
    font-weight: 700;
    font-size: 2em;
    margin-bottom: 15px;
}

/* Target h3 headings that are followed by h6 (the license section) */
h3.wp-block-heading + h6.wp-block-heading {
    color: var(--grc-red) !important;
    margin-top: 10px !important;
    font-size: 1.5em !important;
    font-weight: 700 !important;
    line-height: 1.4 !important;
}

.license-numbers,
h2.license-numbers,
h6.license-numbers,
.licensed-section h6.wp-block-heading {
    color: var(--grc-red) !important;
    margin-top: 10px !important;
    font-size: 1.5em !important;
    font-weight: 700 !important;
    line-height: 1.4 !important;
}

.licensed-section p {
    color: var(--grc-text);
    font-size: 1em;
    line-height: 1.6;
}

/* ==========================================================================
   6. Footer CTA Section
   ========================================================================== */
/* Full-width footer CTA - break out of GeneratePress container */
.wp-block-cover.footer-cta {
    min-height: 400px;
    background-size: cover !important;
    background-position: center center !important;
    background-attachment: fixed !important;
    width: 100% !important;
    max-width: 100% !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
    position: relative !important;
    box-sizing: border-box !important;
}

.wp-block-cover.footer-cta .wp-block-cover__image-background {
    background-size: cover !important;
    background-position: center center !important;
    background-attachment: fixed !important;
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100% !important;
    height: 100% !important;
    z-index: 0 !important;
}

.wp-block-cover.footer-cta .wp-block-cover__inner-container {
    position: relative !important;
    z-index: 1 !important;
}

.footer-cta-container {
    background-color: rgba(25,25,25,0.5) !important;
    padding: 60px 20px !important;
    width: 100%;
}

.footer-cta-inner {
    background-color: rgba(236,29,37,0.9) !important;
    padding: 25px !important;
    border-radius: 12px !important;
    border: 3px solid #fff !important;
    color: #fff !important;
    text-align: center;
    max-width: 600px;
    margin: 0 auto;
}

.footer-cta-headline-1,
.wp-block-heading.footer-cta-headline-1 {
    color: #ffffff !important;
    font-size: 2em !important;
    letter-spacing: 1px !important;
    margin-top: 0px !important;
}

.footer-cta-headline-2,
.wp-block-heading.footer-cta-headline-2 {
    color: var(--grc-yellow) !important;
    font-size: 1.4em !important;
    letter-spacing: 1px !important;
    margin-top: 15px !important;
}

.greener-text {
    color: #bbff00 !important;
}

.wp-block-cover.footer-cta h2 {
    font-size: 2.3em !important;
    text-align: center !important;
}

.wp-block-cover.footer-cta .wp-block-button__link {
    background-color: var(--grc-red) !important;
}

/* CRITICAL FIX: Override inline dark button style in footer CTA
   The footer CTA cover block may not have .footer-cta class,
   so we target it by the red box with white border that contains the button */
.wp-block-cover .wp-block-group.has-white-border-color .wp-block-button__link {
    background-color: var(--grc-red) !important;
    border: 2px solid #fff !important;
    border-radius: 30px !important;
}

.wp-block-cover.footer-cta p a {
    color: #fff !important;
    font-weight: bold !important;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.wp-block-cover.footer-cta p a:hover {
    text-decoration: underline;
    color: var(--grc-dark) !important;
}

/* ==========================================================================
   7. Buttons
   ========================================================================== */
.wp-block-button__link {
    background-color: var(--grc-red) !important;
    border: 2px solid #fff !important;
    color: #fff !important;
    padding: 15px 30px !important;
    font-weight: 700 !important;
    text-transform: uppercase !important;
    border-radius: 4px !important;
    text-shadow: 0 0.075em 0.075em rgba(0,0,0,0.5);
    transition: all 0.3s ease;
}

.wp-block-button__link:hover {
    background-color: var(--grc-red) !important;
    border-color: rgba(255,255,255,0.8) !important;
    color: #fff !important;
}

.cta-button .wp-block-button__link {
    font-size: 1.2em;
    padding: 18px 40px !important;
}

/* ==========================================================================
   8. Footer Styles - GeneratePress specific
   ========================================================================== */
.site-footer,
.site-info,
footer.site-footer {
    background-color: var(--grc-dark) !important;
    color: #fff !important;
}

.site-footer a,
.site-info a {
    color: #fff !important;
}

/* GRC Custom Footer */
.grc-custom-footer {
    background-color: var(--grc-dark);
    padding: 30px 0;
    color: #fff;
}

.grc-footer-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.grc-footer-navigation {
    text-align: center;
    margin-bottom: 20px;
}

.grc-footer-menu {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    justify-content: center;
    gap: 30px;
}

.grc-footer-menu li {
    display: inline-block;
}

.grc-footer-menu a {
    color: #fff !important;
    text-decoration: none;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.085em;
    font-size: 14px;
    transition: color 0.3s ease;
}

.grc-footer-menu a:hover {
    color: var(--grc-yellow) !important;
}

.grc-footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
}

.grc-footer-logo-copyright {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 1;
    min-width: 0; /* Allow shrinking */
    max-width: 100%;
}

.grc-footer-logo-copyright .custom-logo {
    width: 60px !important;
    height: auto !important;
    max-width: 60px !important;
}

.grc-copyright {
    color: #fff;
    font-size: 14px;
}

.grc-footer-badges {
    display: flex;
    gap: 15px;
    align-items: center;
}

.grc-footer-badges a {
    display: inline-block;
    transition: transform 0.3s ease;
}

.grc-footer-badges a:hover {
    transform: translateY(-3px);
}

.grc-footer-badges img {
    display: block;
    height: auto;
}

/* Mobile Footer Styles */
@media (max-width: 767px) {
    .grc-custom-footer {
        padding: 25px 0;
    }

    .grc-footer-container {
        padding: 0 15px;
    }

    .grc-footer-menu {
        flex-direction: column;
        gap: 10px;
    }

    .grc-footer-menu a {
        display: block;
        padding: 12px 20px;
        min-height: 44px;
        font-size: 16px;
        line-height: 20px;
        box-sizing: border-box;
    }

    .grc-footer-content {
        flex-direction: column;
        text-align: center;
        gap: 25px;
    }

    .grc-footer-logo-copyright {
        flex-direction: column;
        min-width: unset;
        width: 100%;
        text-align: center;
    }

    .grc-copyright {
        font-size: 16px;
        line-height: 1.5;
    }

    .grc-footer-badges {
        justify-content: center;
        gap: 20px;
    }

    .grc-footer-badges img {
        max-width: 70px;
        height: auto;
    }
}

/* ==========================================================================
   9. Typography
   ========================================================================== */
h1, h2, h3, h4, h5, h6 {
    font-family: "Lato", sans-serif;
    font-weight: 700;
    color: #272727;
}

a {
    color: var(--grc-red);
}

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

.text-link {
    color: #fff !important;
    font-size: 1.1em;
    font-weight: bold;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.text-link:hover {
    text-decoration: underline;
    color: var(--grc-dark) !important;
}

.hero-right-container a,
.footer-cta-inner a {
    color: #fff !important;
}

/* ==========================================================================
   10. Mobile Navigation Styles - GeneratePress
   ========================================================================== */
@media (max-width: 768px) {
    /* Mobile menu toggle button */
    .menu-toggle,
    button.menu-toggle {
        background-color: var(--grc-red) !important;
        color: #ffffff !important;
        border: 2px solid #ffffff !important;
        border-radius: 4px;
        padding: 10px 12px;
    }

    /* Mobile navigation */
    .main-navigation.toggled ul,
    .main-navigation.toggled .main-nav ul {
        background-color: var(--grc-red) !important;
    }

    .main-navigation.toggled a,
    .main-navigation.toggled .main-nav ul li a {
        color: #ffffff !important;
        padding: 15px 20px !important;
        border-bottom: 1px solid rgba(255, 255, 255, 0.2);
        min-height: 48px;
    }

    .main-navigation.toggled a:hover {
        background-color: rgba(0, 0, 0, 0.2) !important;
    }

    /* Submenu styling */
    .main-navigation.toggled .sub-menu a {
        padding-left: 40px !important;
    }
}

/* ==========================================================================
   11. Responsive Styles
   ========================================================================== */

/* Tablet (768px - 979px) */
@media (max-width: 979px) {
    .services-row-4,
    .services-row-3 {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }

    .wp-block-cover.hero-section {
        min-height: 450px;
    }

    .hero-tagline-1,
    .wp-block-heading.hero-tagline-1 {
        font-size: 2em !important;
    }

    .hero-tagline-3,
    .wp-block-heading.hero-tagline-3 {
        font-size: 1.6em !important;
    }

    .licensed-section .wp-block-columns {
        flex-direction: column;
        text-align: center;
    }
}

/* Mobile (max-width: 767px) - Hero Section */
@media (max-width: 767px) {
    .wp-block-cover.hero-section {
        min-height: 600px !important;
        background-attachment: scroll !important;
        padding: 30px 15px !important;
    }

    .hero-cta-container,
    .hero-right-container {
        width: 100% !important;
        max-width: 100% !important;
        padding: 20px !important;
    }

    .hero-tagline-1,
    .wp-block-heading.hero-tagline-1 {
        font-size: 1.75em !important;
        text-shadow: 2px 2px 4px rgba(0,0,0,0.8) !important;
    }

    .hero-tagline-2,
    .wp-block-heading.hero-tagline-2 {
        font-size: 1.1em !important;
        text-shadow: 2px 2px 4px rgba(0,0,0,0.8) !important;
    }

    .hero-tagline-3,
    .wp-block-heading.hero-tagline-3 {
        font-size: 1.5em !important;
        text-shadow: 2px 2px 4px rgba(0,0,0,0.8) !important;
    }

    .hero-cta-container .wp-block-button__link,
    .hero-right-container .wp-block-button__link {
        width: 100% !important;
        padding: 18px 30px !important;
        min-height: 48px !important;
    }

    .wp-block-cover.hero-section .wp-block-columns {
        flex-direction: column !important;
        gap: 20px !important;
    }
}

/* Mobile (max-width: 575px) - Single column services */
@media (max-width: 575px) {
    .services-row-4,
    .services-row-3 {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .service-card a {
        padding: 16px 20px;
        font-size: 16px;
        min-height: 52px;
    }

    .wp-block-columns.services-row {
        flex-direction: column;
        gap: 20px;
    }

    .wp-block-column.service-item {
        width: 100% !important;
        flex-basis: 100% !important;
    }

    .wp-block-column.service-item .wp-block-button__link {
        width: 100%;
        min-height: 52px;
        padding: 16px 20px !important;
        font-size: 16px !important;
    }

    /* Footer CTA Mobile */
    .wp-block-cover.footer-cta {
        min-height: auto;
        padding: 40px 0 !important;
    }

    .footer-cta-inner {
        padding: 20px 15px !important;
    }

    .footer-cta-headline-1,
    .wp-block-heading.footer-cta-headline-1 {
        font-size: 1.4em !important;
    }

    .footer-cta-headline-2,
    .wp-block-heading.footer-cta-headline-2 {
        font-size: 1.1em !important;
    }
}

/* Small mobile (max-width: 480px) */
@media (max-width: 480px) {
    .wp-block-cover.hero-section {
        min-height: 550px !important;
        padding: 20px 12px !important;
    }

    .hero-tagline-1,
    .wp-block-heading.hero-tagline-1 {
        font-size: 1.5em !important;
    }

    .hero-tagline-3,
    .wp-block-heading.hero-tagline-3 {
        font-size: 1.3em !important;
    }
}

/* Touch device optimizations */
@media (hover: none) and (pointer: coarse) {
    .service-card a,
    .wp-block-column.service-item .wp-block-button__link {
        min-height: 52px;
        padding: 16px 20px !important;
    }

    .service-card a:active,
    .wp-block-column.service-item .wp-block-button__link:active {
        background: var(--grc-red-dark) !important;
        transform: scale(0.98);
    }
}

/* ==========================================================================
   12. Contact Form 7 Styling
   ========================================================================== */
.page-template-default .entry-content,
body.page-id-7 .entry-content {
    max-width: 800px;
    margin: 0 auto;
    padding: 40px 20px;
}

.page-template-default .entry-title,
body.page-id-7 .entry-title {
    text-align: center;
    color: var(--grc-dark);
    font-size: 2.5em;
    margin-bottom: 20px;
}

.wpcf7-form {
    background: #ffffff;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.wpcf7-form p {
    margin-bottom: 20px;
}

.wpcf7-form label {
    display: block;
    font-weight: 600;
    color: var(--grc-dark);
    margin-bottom: 8px;
    font-size: 14px;
}

.wpcf7-form input[type="text"],
.wpcf7-form input[type="email"],
.wpcf7-form input[type="tel"],
.wpcf7-form textarea {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #e0e0e0;
    border-radius: 4px;
    font-size: 16px;
    font-family: "Lato", sans-serif;
    transition: border-color 0.3s ease;
    box-sizing: border-box;
}

.wpcf7-form input[type="text"]:focus,
.wpcf7-form input[type="email"]:focus,
.wpcf7-form input[type="tel"]:focus,
.wpcf7-form textarea:focus {
    outline: none;
    border-color: var(--grc-red);
    box-shadow: 0 0 0 3px rgba(236, 29, 37, 0.1);
}

.wpcf7-form textarea {
    min-height: 150px;
    resize: vertical;
}

.wpcf7-form input[type="submit"] {
    background-color: var(--grc-red) !important;
    color: #ffffff !important;
    border: 2px solid #ffffff !important;
    padding: 15px 40px !important;
    font-size: 18px !important;
    font-weight: 700 !important;
    text-transform: uppercase !important;
    border-radius: 30px !important;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 6px rgba(0,0,0,0.2);
    min-height: 48px;
}

.wpcf7-form input[type="submit"]:hover {
    background-color: var(--grc-red-dark) !important;
    transform: translateY(-2px);
    box-shadow: 0 6px 10px rgba(0,0,0,0.3);
}

.wpcf7-not-valid-tip {
    color: var(--grc-red);
    font-size: 13px;
    margin-top: 5px;
}

.wpcf7-response-output {
    border: 2px solid;
    padding: 15px;
    margin: 20px 0 0;
    border-radius: 4px;
    text-align: center;
}

/* Mobile Contact Form */
@media (max-width: 767px) {
    .page-template-default .entry-content,
    body.page-id-7 .entry-content {
        padding: 30px 15px;
    }

    .wpcf7-form {
        padding: 20px 15px;
    }

    .page-template-default .entry-title,
    body.page-id-7 .entry-title {
        font-size: 2em;
    }

    .wpcf7-form input[type="submit"] {
        width: 100%;
        padding: 18px 30px !important;
    }
}

/* ==========================================================================
   13. Responsive Reflow Fixes - Prevent Horizontal Scrolling
   ========================================================================== */

/* Global container responsiveness */
*,
*::before,
*::after {
    box-sizing: border-box;
}

/* Ensure all images are responsive */
img {
    max-width: 100%;
    height: auto;
}

/* Prevent any element from exceeding viewport */
.entry-content > *,
.site-content > *,
article > * {
    max-width: 100%;
}

/* WordPress block responsiveness */
.wp-block-columns {
    flex-wrap: wrap !important;
}

.wp-block-column {
    min-width: 0 !important; /* Allow flex items to shrink */
    max-width: 100% !important;
}

/* Tablet breakpoint (900px - 1200px) - Reflow services grid */
@media (max-width: 1200px) and (min-width: 769px) {
    /* Services grid - make 4-column become 2x2 */
    .wp-block-columns.services-row:first-of-type {
        flex-wrap: wrap !important;
    }

    .wp-block-columns.services-row .wp-block-column {
        flex-basis: calc(50% - 12px) !important;
        flex-grow: 0 !important;
    }

    /* Licensed section - stack image and text */
    .licensed-section .wp-block-columns {
        flex-wrap: wrap !important;
    }

    .licensed-section .wp-block-column {
        flex-basis: 100% !important;
        text-align: center;
    }

    .licensed-section .wp-block-column:first-child {
        margin-bottom: 20px;
    }

    .licensed-section img {
        max-width: 300px;
        margin: 0 auto;
        display: block;
    }
}

/* Smaller desktop (769px - 900px) */
@media (max-width: 900px) and (min-width: 769px) {
    /* Hero section - reduce padding */
    .hero-cta-container,
    .hero-right-container {
        padding: 20px !important;
    }

    .hero-tagline-1,
    .wp-block-heading.hero-tagline-1 {
        font-size: 1.8em !important;
    }

    .hero-tagline-3,
    .wp-block-heading.hero-tagline-3 {
        font-size: 1.4em !important;
    }

    /* Footer badges - allow wrap */
    .grc-footer-content {
        flex-wrap: wrap;
        justify-content: center;
        gap: 15px;
    }

    .grc-footer-logo-copyright {
        justify-content: center;
        text-align: center;
    }
}

/* Contact page responsive layout */
.contact-layout {
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
}

.contact-info-column {
    flex: 1 1 300px;
    min-width: 0;
    max-width: 100%;
}

.contact-form-column {
    flex: 2 1 400px;
    min-width: 0;
    max-width: 100%;
}

/* Map container */
.contact-map iframe,
.wp-block-html iframe {
    max-width: 100% !important;
    width: 100% !important;
}

/* Table responsiveness */
table {
    max-width: 100%;
    overflow-x: auto;
    display: block;
}

/* Prevent text overflow */
h1, h2, h3, h4, h5, h6, p, li, a, span {
    word-wrap: break-word;
    overflow-wrap: break-word;
}

/* Long URLs and text */
.entry-content a {
    word-break: break-word;
}

/* Service page content - ensure readable width */
body.page:not(.home) .entry-content {
    max-width: 900px;
    margin: 0 auto;
    padding: 40px 20px;
}

/* Prevent horizontal scroll on service pages */
body.page:not(.home) .wp-block-cover,
body.page:not(.home) .alignfull {
    width: 100% !important;
    max-width: 100% !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
}
