/* City and state location pages. Loaded only on modern local templates. */

html, body {
    overflow-x: hidden;
    max-width: 100%;
}

.post-layout-update #city-hero .city-head {
    max-height: none !important;
    min-height: auto !important;
    height: auto !important;
    overflow: visible !important;
}

.post-layout-update #city-hero .city-head::before {
    background: transparent !important;
}

.post-layout-update #city-hero .city-head .city-hero__review-logo {
    position: static;
    width: auto;
    max-width: 60px;
    height: 20px;
}

#city-hero .city-hero__content,
#city-hero .city-hero__headline,
#city-hero .city-hero__subtitle {
    text-align: center !important;
}

.city-hero {
    position: relative;
    width: 100vw;
    margin-left: calc(-50vw + 50%);
    background: var(--primary-color);
    overflow-x: hidden;
    overflow-y: visible;
    max-width: 100%;
    box-sizing: border-box;
}

.city-hero__inner {
    position: relative;
    max-width: 100%;
}

.city-hero__content {
    position: relative;
    z-index: 2;
    padding: 1.75rem 1.25rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    text-align: center;
    align-items: center;
    max-width: 100%;
    box-sizing: border-box;
    overflow-x: hidden;
}

.city-hero__trust-bar {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    gap: 1.5rem;
    flex-wrap: wrap;
    margin-bottom: 0.9rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

.city-hero__review-widget,
.city-hero__trustpilot-widget {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.city-hero__review-logo {
    height: 22px;
    width: auto;
}

.city-hero__review-stars {
    display: flex;
    gap: 2px;
}

.city-hero__review-stars svg {
    width: 14px;
    height: 14px;
    fill: var(--rating-star-color);
}

.city-hero__review-text {
    font-size: 0.75rem;
    color: var(--color-on-primary);
    margin-left: 0.25rem;
}

.city-hero__trustpilot-widget {
    flex: 0 1 320px;
    width: min(100%, 320px);
    max-width: 100%;
    justify-content: center;
}

.city-hero__trustpilot-widget .trustpilot-widget {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Desktop iframe is ~68px; mobile uses data-style-height="24px" — do not reserve 68px on mobile
   or the short iframe sits at the top while Google is vertically centered in the row. */
.city-hero__trustpilot-widget .trustpilot_desktop {
    display: block;
    min-height: 68px;
}

.city-hero__trustpilot-widget .trustpilot_mobile {
    display: none;
    min-height: auto;
}

.city-hero__headline {
    font-family: "General Sans", sans-serif;
    font-size: clamp(1.75rem, 5vw, 3.25rem);
    font-weight: 800;
    color: var(--color-on-primary);
    margin: 0 0 0.6rem;
    line-height: 1.1;
    text-align: center;
    text-wrap: balance;
}

.city-hero__headline-location {
    display: inline-block;
}

.city-hero__subtitle {
    font-family: "Montserrat", sans-serif;
    font-size: 1rem;
    color: rgba(255,255,255,0.8);
    margin-bottom: 1rem;
    line-height: 1.5;
    text-align: center;
    max-width: 48rem;
    margin-left: auto;
    margin-right: auto;
}

.city-hero__ctas {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 0.75rem;
    align-items: center;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

.city-hero__cta-row {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    align-items: center;
    justify-content: center;
    width: 100%;
}

/*
 * Global style.css sets `.wrusa-hero-ctas { align-items: stretch }` and
 * `.text-center .wrusa-hero-ctas { margin: auto }` — this hero has no `.text-center`
 * wrapper, so stretch + max-width was leaving the strip optically left-heavy.
 */
.city-hero .city-hero__ctas .wrusa-hero-ctas {
    align-items: center;
    margin-left: auto;
    margin-right: auto;
}

.city-hero__ctas .btn.dumpster-btn {
    overflow: visible;
    white-space: nowrap;
}

.city-hero__ctas .btn.dumpster-btn svg {
    width: 1.25rem;
    height: 1.25rem;
    flex-shrink: 0;
    display: block;
    margin: 0;
}

.city-hero__ctas .btn.dumpster-btn svg.quote_icon {
    width: 1.25rem;
    height: 1.25rem;
    min-width: 1.25rem;
    overflow: visible;
    margin: 0;
}

.city-hero .city-hero__ctas a.dumpster-btn {
    background-color: var(--tertiary-color);
    border: 2px solid var(--tertiary-color);
    color: var(--color-on-primary) !important;
    text-decoration: none !important;
    font-family: "General Sans", sans-serif;
    font-weight: 500;
}

.city-hero .city-hero__ctas a.dumpster-btn svg {
    fill: var(--color-on-primary);
}

.city-hero .city-hero__ctas a.dumpster-btn:hover {
    background-color: var(--tertiary-color);
    border-color: var(--tertiary-color);
    color: var(--color-on-primary) !important;
    transform: translateY(-2px);
    filter: brightness(0.97);
    text-decoration: none !important;
    box-shadow: 0 6px 20px rgba(55, 55, 63, 0.32);
}

.city-hero .city-hero__ctas a.dumpster-btn:active {
    transform: translateY(0);
    filter: brightness(0.94);
    box-shadow: none;
}

.city-hero .city-hero__ctas a.dumpster-btn:focus-visible {
    outline: 2px solid var(--color-on-primary);
    outline-offset: 2px;
}

.city-hero .city-hero__ctas a.dumpster-btn:hover svg {
    fill: var(--color-on-primary) !important;
}

.city-hero .city-head__hours {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 0.35rem;
}

.city-hero .city-head__hours,
.city-hero .city-head__hours-label,
.city-hero .city-head__hours-time {
    color: rgba(255,255,255,0.9);
}

.city-hero .city-head__hours-icon {
    fill: rgba(255,255,255,0.9);
}

.city-hero__visual {
    display: none;
}

@media (max-width: 767px) {
    .city-hero {
        background:
            linear-gradient(
                180deg,
                rgba(var(--primary-color-rgb), 0.88) 0%,
                rgba(var(--primary-color-rgb), 0.75) 55%,
                rgba(var(--primary-color-rgb), 0.65) 100%
            ),
            var(--city-hero-image, url('/wp-content/uploads/construction-dumpster-rental-local.webp')) center/cover no-repeat;
    }

    .city-hero__content {
        padding: 1.75rem 1.25rem;
        text-align: center;
    }

    .city-hero .city-hero__content,
    .city-hero .city-hero__content .city-hero__headline,
    .city-hero .city-hero__content .city-hero__subtitle {
        text-align: center !important;
    }

    .city-hero .city-hero__content .city-hero__subtitle {
        margin-left: auto !important;
        margin-right: auto !important;
    }

    .city-hero__trust-bar {
        flex-direction: row;
        gap: 1rem;
        align-items: flex-start;
        justify-content: center;
        flex-wrap: wrap;
    }

    .city-hero__review-widget,
    .city-hero__trustpilot-widget {
        flex: 0 0 auto;
        justify-content: center;
    }

    .city-hero__trustpilot-widget .trustpilot_desktop {
        display: none;
    }
    .city-hero__trustpilot-widget .trustpilot_mobile {
        display: block;
    }

    /* Mobile: quote + order. Desktop business hours: hide quote (call + order). */
    .city-hero .wrusa-hero-ctas > .btn.city-hero__cta-phone {
        display: none !important;
    }
}

@media (min-width: 768px) {
    .city-hero .city-hero-cta-surface--business.wrusa-hero-ctas > .btn.city-hero__cta-quote {
        display: none !important;
    }

    .city-hero__inner {
        display: block;
        position: relative;
        min-height: 460px;
        width: 100%;
    }

    .city-hero__content {
        position: relative;
        z-index: 2;
        width: 60%;
        padding: 2.75rem 2.5rem 3rem;
        text-align: center;
        align-items: center;
        min-width: 0;
    }

    .city-hero__trust-bar {
        justify-content: center;
        align-items: flex-start;
        flex-wrap: nowrap;
        gap: 1.25rem;
        max-width: 33rem;
        margin-left: auto;
        margin-right: auto;
    }

    .city-hero__trustpilot-widget {
        width: min(100%, 310px);
    }

    .city-hero__review-logo {
        height: 26px;
    }

    .city-hero__review-stars svg {
        width: 16px;
        height: 16px;
    }

    .city-hero__review-text {
        font-size: 0.9rem;
    }

    .city-hero__ctas {
        flex-direction: row;
        justify-content: center;
        align-items: center;
        flex-wrap: nowrap;
    }

    .city-hero__cta-row {
        flex-direction: row;
        flex-wrap: nowrap;
        width: auto;
    }

    .city-hero .city-head__hours {
        justify-content: center;
    }

    .city-hero__visual {
        display: block;
        position: absolute;
        top: 0;
        right: 0;
        bottom: 0;
        width: 40%;
        background: var(--city-hero-image, url('/wp-content/uploads/construction-dumpster-rental-local.webp')) center/cover no-repeat;
        background-size: cover;
        background-position: center right;
        overflow: hidden;
    }

    .city-hero__visual::before {
        content: "";
        position: absolute;
        inset: 0;
        background: linear-gradient(
            to right,
            var(--primary-color) 0%,
            rgba(var(--primary-color-rgb), 0.35) 22%,
            rgba(var(--primary-color-rgb), 0.14) 100%
        );
        z-index: 1;
        pointer-events: none;
    }
}

@media (min-width: 768px) and (max-width: 991px) {
    .city-hero__content {
        padding: 2.4rem 1.75rem 2.75rem;
    }

    .city-hero__trust-bar {
        flex-wrap: nowrap;
        gap: 1rem;
    }

    .city-hero__review-widget,
    .city-hero__trustpilot-widget {
        flex: 0 0 auto;
        min-width: 0;
        max-width: 100%;
    }

    .city-hero__trustpilot-widget {
        width: min(100%, 290px);
        max-width: 290px;
    }

    .city-hero__ctas {
        flex-wrap: nowrap;
    }

    /* Same width and spacing as desktop for consistent layout */
    .city-hero__ctas .btn.dumpster-btn,
    .city-hero__ctas a.dumpster-btn {
        width: 14rem;
        min-width: 14rem;
        max-width: 14rem;
        box-sizing: border-box;
        padding-left: 0.6rem;
        padding-right: 0.6rem;
        font-size: clamp(0.875rem, 2vw, 1rem);
    }

    .city-hero__ctas .btn.dumpster-btn svg {
        flex-shrink: 0;
        min-width: 1.25rem;
        min-height: 1.25rem;
    }
}

/* Stack CTAs before they hit the edge (before ~930px) */
@media (max-width: 960px) {
    .city-hero__ctas {
        flex-direction: column;
        align-items: center;
    }

    .city-hero__ctas .btn.dumpster-btn,
    .city-hero__ctas a.dumpster-btn {
        width: 100%;
        max-width: 20rem;
        min-width: 0;
    }
}

@media (min-width: 992px) {
    .city-hero__inner {
        min-height: 500px;
    }

    .city-hero__content {
        padding: 3rem 3rem 3.25rem;
    }

    .city-hero__trust-bar {
        max-width: 34rem;
    }

    .city-hero__headline {
        margin-bottom: 1rem;
    }

    .city-hero__subtitle {
        font-size: 1.1rem;
    }

    /* CTAs: size, equal width, centered in hero */
    .city-hero__ctas {
        flex-direction: row;
        justify-content: center;
        align-items: center;
    }

    .city-hero__ctas .btn.dumpster-btn,
    .city-hero__ctas a.dumpster-btn {
        font-size: 1.4rem;
        width: 14rem;
        min-width: 14rem;
        box-sizing: border-box;
    }

    /* Keep both phone and quote icons visible (prevent flex shrink) */
    .city-hero__ctas .btn.dumpster-btn svg {
        flex-shrink: 0;
        min-width: 1.25rem;
        min-height: 1.25rem;
    }
}
