/* FILE: /assets/css/commercial-pillar.css (CORRECTED VERSION) */
/* ===================================================================
 * STYLESHEET FOR COMMERCIAL ROOFING PILLAR PAGE
 * =================================================================== */

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* --- Commercial Hero Section --- */
.roofing-services.cr {
    position: relative;
    z-index: 2;
    background-color: transparent;
    color: var(--color-light);
    text-align: center;
    padding-top: 85px;
    padding-bottom: 40px;
}

.roofing-services.cr .hero-animated-content {
    animation: fadeIn 1s ease-in-out;
}

.roofing-services.cr h1 {
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 700;
    line-height: 1.2;
    margin: 15px 0;
}

.roofing-services.cr::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100vw;
    height: 100%;
    z-index: -1;
    background: #000 url('https://idealroofingco.com/wp-content/uploads/commercial_roofing_header.jpg') center center/cover no-repeat;
    box-shadow: inset 0 0 0 100vw rgba(0, 0, 0, 0.50);
}

.roofing-services.cr .hero-intro-container p {
    color: rgba(255, 255, 255, 0.95);
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
    margin-bottom: var(--element-gap);
}

/* --- Mobile Hero Sizing --- */
@media (max-width: 767px) {
    .roofing-services.cr { 
        padding: 0;
    }
    .roofing-services.cr::before { 
        width: 100%; 
        left: 0; 
        transform: none; 
    }
    .cr .services-container { 
        padding: 0;
    }
    .cr .hero-animated-content { 
        padding: 2rem 1.5rem;
    }
    .roofing-services.cr h1 { 
        font-size: 1.5rem;
        line-height: 1.4;
        margin-bottom: 1.5rem;
    }
    .cities-section-hp { 
        display: none;
    }
    .cr .btn-primary { 
        background-color: var(--color-secondary);
        border-color: var(--color-secondary);
    }
    .cr .btn-primary:hover { 
        background-color: #1e6e1a;
        border-color: #1e6e1a;
    }
}

/* --- Desktop Hero Sizing --- */
@media (min-width: 768px) {
    .roofing-services.cr h1 {
        font-size: 32px !important;
        margin: 20px 0 25px 0 !important;
        padding: 10px 0 !important;
    }
}

@media (min-width: 48rem) {
    .services-container {
        padding-left: var(--container-padding);
        padding-right: var(--container-padding);
        box-sizing: border-box;
        width: 100%;
    }
    .hero-intro-container p { 
        text-align: left; 
        margin-bottom: 20px; 
        color: inherit; 
    }
    .cities-section-hp {
        text-align: center;
        margin: 22px auto;
        padding-top: 2rem;
    }
    .cities-section-hp h3 { 
        font-size: 1.125rem; 
        margin-bottom: 15px; 
        color: var(--color-light); 
    }
    .cities-container-hp { 
        display: flex; 
        justify-content: center; 
        flex-wrap: wrap; 
        gap: 50px; 
    }
    .city-item-hp h4 { 
        color: var(--color-light) !important; 
        font-size: 20px; 
        font-weight: 400; 
        transition: all 0.3s ease; 
        padding: 5px; 
        margin: 0; 
        text-transform: none; 
    }
    .city-item-hp h4:hover { 
        color: #FFCC00 !important; 
        background-color: #000; 
        transform: scale(1.2); 
    }
    .roofing-services.cr h1 { 
        font-size: 2rem; 
    }
}

/* ===================================================================
 * LAYOUT AND COMPONENT STYLES - MATCHING RESIDENTIAL EXACTLY
 * =================================================================== */

/* MOBILE LAYOUT */
@media (max-width: 767px) {
    .desktop-layout-only { display: none; }
    .mobile-layout-only { display: block; padding-top: var(--section-gap); }
    .desktop-only-p { display: none; }
    .mobile-only-p { display: block; }
    
    .mobile-layout-only .info-block { 
        background-color: var(--color-primary); 
        color: var(--color-light); 
        border-radius: var(--border-radius); 
        overflow: hidden; 
    }
    .mobile-layout-only .info-block + .info-block { 
        margin-top: 2.5rem; 
    }
    .mobile-layout-only .info-block-image img { 
        width: 100%; 
        height: 375px; /* Match residential height */
        object-fit: cover; 
        display: block; 
        object-position: center center; 
    }
    .mobile-layout-only .info-block-content { 
        padding: 1.75rem 1.5rem; 
    }
    .mobile-layout-only .info-block-content h3 { 
        text-align: center; 
        color: #fff; 
        font-size: 1.4rem; 
        line-height: 1.25; 
        text-transform: uppercase; 
        margin-top: 0; 
        margin-bottom: 1.25rem; 
        border-bottom: 2px solid var(--color-accent); 
        padding-bottom: 0.75rem; 
    }
    .mobile-layout-only [data-service] > .info-block-content > p { 
        font-size: 1rem; 
        line-height: 1.6; 
        margin-bottom: 1.5rem; 
    }
    .mobile-layout-only .service-list { 
        padding-left: 0; 
        list-style: none; 
        margin-bottom: 1.5rem; 
    }
    .mobile-layout-only .check-item { 
        position: relative; 
        padding-left: 1.75rem; 
        margin-bottom: 0.85rem; 
        color: var(--color-light); 
        font-size: 1rem; 
        line-height: 1.5; 
    }
    .mobile-layout-only .check-item::before { 
        content: '\27A5'; 
        color: var(--color-light); 
        opacity: 0.9; 
        position: absolute; 
        left: 0; 
        top: -0.1em; 
        font-weight: bold; 
        font-size: 1.4em; 
        line-height: 1.2; 
    }
    .mobile-layout-only .wp-block-button { 
        text-align: left; 
        margin-top: 1.5rem; 
    }
    .mobile-layout-only .btn-secondary { 
        width: 100%; 
        text-align: center; 
    }
    .mobile-layout-only .phone-highlight-centered { 
        background: rgba(255, 255, 255, 0.95); 
        padding: 1.25rem; 
        border-radius: var(--border-radius); 
        text-align: center; 
        margin-top: 1.25rem; 
    }
    .mobile-layout-only .call-now { 
        color: #000; 
        font-weight: 600; 
        margin-bottom: 0.5rem; 
        font-size: 0.95rem; 
        text-transform: uppercase; 
    }
    .mobile-layout-only .phone-number { 
        color: #1a73e8; 
        font-size: 1.35rem; 
        font-weight: 700; 
        display: block; 
        margin-top: 0.25rem; 
    }
}

/* DESKTOP LAYOUT - MATCHING RESIDENTIAL EXACTLY */
@media (min-width: 768px) {
    .mobile-layout-only { display: none; }
    .desktop-layout-only { display: block; }
    .mobile-only-p { display: none; }
    .desktop-only-p { display: block; }
    
    /* Match residential grid structure */
    .desktop-layout-only .roofing-columns, 
    .desktop-layout-only .roofing-columns-blk, 
    .desktop-layout-only .process-steps-container { 
        display: grid; 
        gap: var(--grid-gap-md); 
    }
    .desktop-layout-only .roofing-columns, 
    .desktop-layout-only .roofing-columns-blk { 
        grid-template-columns: 1fr 1fr; 
    }
    .desktop-layout-only .process-steps-container { 
        grid-template-columns: 1fr 1fr; 
        gap: 2rem; 
    }
    
    /* Section titles - EXACT MATCH to residential */
    .desktop-layout-only .section-title-heading { 
        text-align: center; 
        margin-bottom: 3rem; 
        font-size: 2.25rem !important;
        font-weight: 600 !important;
        color: #222 !important;
        text-transform: uppercase !important;
        margin: 2rem 0 1.75rem 0 !important;
    }
    
    /* Roofing columns with background images */
    .desktop-layout-only .roofing-col { 
        background-size: cover; 
        background-position: center; 
        padding: 2.5rem; 
        border-radius: var(--border-radius); 
        color: var(--color-light); 
        position: relative; 
        display: flex; 
        flex-direction: column; 
        box-shadow: 0 8px 25px rgba(0,0,0,0.2); 
        transition: transform 0.3s ease, box-shadow 0.3s ease; 
        min-height: 550px; /* Match residential height */
    }
    .desktop-layout-only .roofing-col:hover { 
        transform: translateY(-5px); 
        box-shadow: 0 12px 30px rgba(0,0,0,0.25); 
    }
    
    /* Commercial specific background images */
    .desktop-layout-only .commercial-replacement-col { 
        background-image: url('https://idealroofingco.com/wp-content/uploads/commercial-roofing-replacements-flint.jpg'); 
    }
    .desktop-layout-only .commercial-repair-col { 
        background-image: url('https://idealroofingco.com/wp-content/uploads/commercial_roofing_repairs_flint.jpg'); 
    }
    
    .desktop-layout-only .roofing-col::before { 
        content: ''; 
        position: absolute; 
        top: 0; 
        left: 0; 
        right: 0; 
        bottom: 0; 
        background: linear-gradient(0deg, rgba(0, 0, 0, 0.8) 0%, rgba(0, 0, 0, 0.4) 100%); 
        z-index: 1; 
        border-radius: inherit; 
    }
    .desktop-layout-only .roofing-col .content-wrapper { 
        position: relative; 
        z-index: 2; 
        flex-grow: 1; 
    }
    
    /* Text columns */
    .desktop-layout-only .text-col-blk { 
        border-left: 6px solid var(--color-secondary); 
        background: white; 
        padding: 2rem; 
        box-shadow: 0 4px 12px rgba(0,0,0,0.15); 
    }
    
    /* Images */
    .desktop-layout-only .image-col-blk img { 
        width: 100%; 
        height: 100%; 
        object-fit: cover; 
        border-radius: var(--border-radius); 
    }
    
    /* Headings - EXACT MATCH to residential */
    .desktop-layout-only .service-heading, 
    .desktop-layout-only .service-heading-blk { 
        font-size: 1.5rem !important;
        margin-bottom: 1rem !important;
        border-bottom: 2px solid var(--color-accent) !important;
        padding-bottom: 0.5rem !important;
        font-weight: 600 !important;
        text-transform: uppercase !important;
        letter-spacing: 0.5px !important;
    }
    .desktop-layout-only .roofing-col .service-heading { 
        color: #fff; 
    }
    .desktop-layout-only .text-col-blk .service-heading-blk { 
        color: var(--color-dark); 
    }
    
    /* Paragraphs - EXACT MATCH to residential */
    .desktop-layout-only p {
        margin-bottom: var(--element-gap) !important;
        line-height: 1.6 !important;
        font-size: 1.1rem !important;
    }
    
    /* Lists */
    .desktop-layout-only .service-list { 
        list-style: none; 
        padding-left: 0; 
    }
    .desktop-layout-only .service-list li { 
        margin-bottom: 0.75rem; 
        line-height: 1.5 !important;
    }
    .desktop-layout-only .benefits-list .check-item::before { 
        color: var(--color-secondary); 
    }
    
    /* Process steps */
    .desktop-layout-only .process-step { 
        background-color: #f8fafc; 
        border: 1px solid #e2e8f0; 
        border-top: 4px solid var(--color-primary); 
        padding: 2rem; 
        border-radius: var(--border-radius); 
        transition: transform 0.3s ease, box-shadow 0.3s ease; 
        box-shadow: 0 4px 6px rgba(0,0,0,0.05); 
    }
    .desktop-layout-only .process-step:hover { 
        transform: translateY(-5px); 
        box-shadow: 0 10px 20px rgba(0,0,0,0.07); 
        border-top-color: var(--color-accent); 
    }
    .desktop-layout-only .process-step .step-number { 
        display: grid; 
        margin-left: auto; 
        margin-right: auto; 
        margin-bottom: 1.5rem; 
        place-items: center; 
        background-color: transparent; 
        border: 2px solid var(--color-primary); 
        color: var(--color-primary); 
        font-weight: 700; 
        width: 45px; 
        height: 45px; 
        font-size: 1.4rem; 
        border-radius: 50%; 
        transition: transform 0.6s ease-out, border-color 0.4s ease, color 0.4s ease; 
    }
    .desktop-layout-only .process-step:hover .step-number { 
        transform: rotate(360deg); 
        color: var(--color-secondary); 
        border-color: var(--color-secondary); 
    }
    .desktop-layout-only .process-step .step-content h3 { 
        font-size: 1.3rem; 
        margin-bottom: 0.75rem; 
        text-transform: none; 
    }
    
    /* FAQ */
    .desktop-layout-only .faq-accordion { 
        width: 100%; 
        margin: 0 auto; 
        border-radius: var(--border-radius); 
        border: 1px solid #e2e8f0; 
        box-shadow: 0 4px 12px rgba(0,0,0,0.1); 
        overflow: hidden; 
    }
    .desktop-layout-only .faq-item { 
        border-bottom: 1px solid #e2e8f0; 
        background: white; 
    }
    .desktop-layout-only .faq-item:last-child { 
        border-bottom: none; 
    }
    .desktop-layout-only .faq-question { 
        display: flex; 
        justify-content: space-between; 
        align-items: center; 
        width: 100%; 
        padding: 1.5rem 2rem; 
        background: white; 
        border: none; 
        cursor: pointer; 
        font-family: var(--font-heading); 
        font-size: 1.2rem; 
        font-weight: 700; 
        color: var(--color-dark); 
        text-align: left; 
        text-transform: uppercase; 
        letter-spacing: 0.5px; 
        transition: background-color 0.3s ease, color 0.3s ease; 
    }
    .desktop-layout-only .faq-question:hover, 
    .desktop-layout-only .faq-question.active { 
        background-color: #054A90 !important; 
        color: white !important; 
    }
    .desktop-layout-only .faq-answer { 
        background-color: var(--color-light); 
        overflow: hidden; 
        transition: max-height 0.4s ease-out; 
    }
    .desktop-layout-only .faq-answer p { 
        padding: 0 2rem 1.5rem 2rem; 
        margin: 0; 
        line-height: 1.6; 
        color: var(--color-dark); 
        text-transform: none; 
    }
    .desktop-layout-only .faq-icon { 
        position: relative; 
        width: 16px; 
        height: 16px; 
        flex-shrink: 0; 
        margin-left: 1rem; 
    }
    .desktop-layout-only .faq-icon::before, 
    .desktop-layout-only .faq-icon::after { 
        content: ''; 
        position: absolute; 
        background-color: currentColor; 
        transition: transform 0.3s ease-out; 
        border-radius: 2px; 
    }
    .desktop-layout-only .faq-icon::before { 
        top: 50%; 
        left: 0; 
        width: 100%; 
        height: 3px; 
        margin-top: -1.5px; 
    }
    .desktop-layout-only .faq-icon::after { 
        top: 0; 
        left: 50%; 
        width: 3px; 
        height: 100%; 
        margin-left: -1.5px; 
        transform: rotate(90deg); 
    }
    .desktop-layout-only .faq-question.active .faq-icon::after { 
        transform: rotate(0deg); 
    }
    
    /* CTA section */
    .desktop-layout-only .info-block { 
        display: grid; 
        grid-template-columns: 1fr 1fr; 
        gap: 2rem; 
        align-items: center; 
        background: linear-gradient(to right, #f8fafc, #f0f9ff); 
        border-left: 6px solid var(--color-secondary); 
        border-radius: 0.75rem; 
        overflow: hidden; 
    }
    .desktop-layout-only .info-block-image img { 
        width: 100%; 
        height: 100%; 
        object-fit: cover; 
        display: block; 
    }
    .desktop-layout-only .info-block-content { 
        padding: 2rem; 
    }
    .desktop-layout-only .phone-highlight-centered { 
        background: rgba(255, 255, 255, 0.95); 
        padding: 1.25rem; 
        border-radius: var(--border-radius); 
        text-align: center; 
        margin-top: 1.5rem; 
    }
    .desktop-layout-only .call-now { 
        color: #000; 
        font-weight: 600; 
        margin-bottom: 0.5rem; 
        font-size: 0.95rem; 
        text-transform: uppercase; 
    }
    .desktop-layout-only .phone-number { 
        color: #1a73e8; 
        font-size: 1.35rem; 
        font-weight: 700; 
        display: block; 
        margin-top: 0.25rem; 
    }
    
    /* Reverse layout */
    .desktop-layout-only .roofing-columns-blk.reverse-layout .text-col-blk { 
        order: 1; 
    }
    .desktop-layout-only .roofing-columns-blk.reverse-layout .image-col-blk { 
        order: -1; 
    }
}