/**
 * wp-rengodb plugin page width/padding overrides.
 *
 * The plugin defines its page wrappers under `@layer property { ... }`.
 * Any unlayered CSS in this file automatically wins the cascade over
 * layered styles, so no !important is required.
 *
 * Goal: align the inner content of property detail pages, search pages
 * and the detail-page footer block with the header / breadcrumb / footer
 * edges, which are positioned using `padding-inline: var(--content-spacing)`
 * with `--main-width: 1200px`.
 *
 * PC only — mobile layout is intentionally left untouched.
 */

@media (min-width: 768px) {
    /*
     * Switch from the plugin's `max-width + margin:auto + fixed padding` centering
     * to the theme's `full-width + padding-inline: var(--content-spacing)` pattern
     * used by the header, breadcrumb, and footer.
     * This ensures the content edges align at every viewport width.
     */
    .detail-page,
    .detail-page-footer {
        max-width: none;
        margin-inline: 0;
        padding-inline: var(--content-spacing);
    }

    .search-page {
        max-width: none;
        margin-inline: 0;
        padding-inline: var(--content-spacing);
    }

    .results-list {
        max-width: none;
    }
}

/*
 * Mobile-only fix: the wp-rengodb plugin renders a fixed footer
 * + 38px button + 10px padding); 60px gives a small safety margin.
 */
@media (max-width: 768px) {
    body.wp-rengodb-has-contact-button .footer {
        padding-bottom: 60px;
    }
}
