/* Shared content grid. Loaded after page styles and the cached homepage bundle.
   Keep cards, form controls, images and genuine split layouts independent. */
body :is(.one-copy-section--reading, .km-archive__text) {
    max-width: none;
}

body :is(.faq-accordion, .tech-accordion, .childrens-book-faq, .uv-edge-faq,
    .author-sign-page__faq-list, .isbn-barcode-page__faq-list, .spine-calculator-page__faq-list),
body :is(.faq-page, .contact-faq, .print-books-faq) .faq-accordion {
    max-width: none;
}

body :is(.faq-accordion, .tech-accordion) .accordion-body,
body :is(.faq-page, .contact-faq, .print-books-faq) .faq-accordion .accordion-body,
body :is(.childrens-book-faq, .uv-edge-faq, .author-sign-page__faq-list,
    .isbn-barcode-page__faq-list, .spine-calculator-page__faq-list) details > :not(summary) {
    max-width: none;
}

body :is(.interview-archive__body, .interview-archive__note, .gallery-interview,
    .gallery-interview__hero) {
    width: 100%;
    max-width: var(--km-crumb-container, 1320px);
    margin-left: auto;
    margin-right: auto;
}

@media (min-width: 992px) {
    /* Put the existing consultation trigger in the contacts row, not over text. */
    body .header__base_nav {
        display: grid !important;
        grid-template-columns: minmax(0, 1fr) auto;
        align-content: center;
        align-items: center !important;
        gap: 12px 20px;
    }

    body .header__contacts--desktop {
        grid-column: 1;
        grid-row: 1;
        justify-content: flex-end;
        gap: clamp(12px, 2vw, 30px);
    }

    body .header__base_nav > ul {
        grid-column: 1 / -1;
        grid-row: 2;
        gap: clamp(10px, 1vw, 20px);
    }

    body .header__actions {
        position: static;
        grid-column: 2;
        grid-row: 1;
        width: auto;
        height: auto;
    }

    body .header__base_nav .header__feedback_btn {
        display: inline-block !important;
        position: static;
        min-width: 0;
        min-height: 44px;
        margin: 0 !important;
        padding: 8px 14px;
        border-radius: 16px !important;
        box-shadow: none;
        transform: none;
        color: #212529;
        font-size: 15px;
        white-space: nowrap;
    }

    body .header__feedback_btn span {
        display: inline;
    }
}

@media (min-width: 992px) and (max-width: 1679.98px) {
    /* These containers formerly reserved 190px for the fixed side button. */
    body .print-books-page > .print-books-section,
    body .about-hero > .container,
    body .about-page :is(.about-hero, .about-facts, .about-section, .about-trust,
        .portfolio-gallery-section, .about-final),
    body .portfolio-page :is(.portfolio-hero > .container, .portfolio-filter,
        .portfolio-list-heading, .portfolio-list, .portfolio-final > .container),
    body .blog-index :is(.blog-index__hero > .container, .blog-index__tabs,
        .blog-index__list, .blog-index__final > .container),
    body .services-overview :is(.services-overview__hero > .container,
        .services-overview__heading, .services-overview__bindings > .container,
        .services-overview__list, .services-overview__process > .container,
        .services-overview__final > .container),
    body .reviews-page :is(.reviews-hero > .container, .reviews-list-heading,
        .reviews-list, .reviews-pagination, .reviews-final > .container,
        .review-detail > .container),
    body :is(.blog-detail-heading, .interview-archive__hero, .interview-archive__next),
    body :is(.poetry-page, .childrens-publishing-page) > .container {
        padding-right: calc(var(--bs-gutter-x, 3rem) * .5);
    }

    body .print-books-page > .binding-definition {
        padding-right: clamp(1.75rem, 5vw, 4rem);
    }

    body .print-books-binding-overview {
        padding-right: clamp(1.5rem, 3.5vw, 2.75rem);
    }

    body .interview-archive__hero {
        padding-right: clamp(28px, 5vw, 64px);
    }

    body .interview-archive__next {
        padding-right: clamp(28px, 5vw, 54px);
    }

    body .about-page :is(.about-hero, .about-facts, .about-section, .about-trust,
        .portfolio-gallery-section, .about-final):not(.container) {
        padding-right: 0;
    }

    /* The same side reservation also used fluid values and 126/200px. */
    body .home-section > .container,
    body .home-page ~ .footer-scroll-top-band .footer-scroll-top,
    body .footer > .container,
    body :is(.memoir-page, .book-title-page, .parasite-words-page, .book-design-price) > .container,
    body :is(.memoir-hero, .book-title-hero, .parasite-words-hero,
        .book-design-price-hero, .editing-choice-hero).container,
    body .calculator-page__hero .container,
    body .calculator-page__workspace.container,
    body .calculator-page__guide .container,
    body .isbn-barcode-page section > .container,
    body :is(.spine-calculator-page__hero, .spine-calculator-page__intro,
        .spine-calculator-page__steps, .spine-calculator-page__precision,
        .spine-calculator-page__faq, .spine-calculator-page__links) .container,
    body .spine-calculator-page__workspace.container {
        padding-right: calc(var(--bs-gutter-x, 3rem) * .5);
    }

    body .book-design-price > .book-design-price-start {
        padding-right: clamp(34px, 5vw, 62px);
    }

    body :is(.contact-hero, .faq-hero, .tech-hero) {
        padding-right: calc(var(--bs-gutter-x, 3rem) * .5);
    }

    body :is(.faq-page, .tech-page, .contact-page) > .section.container,
    body .contact-location > .container {
        width: 100%;
        max-width: var(--km-crumb-container, 1320px);
        margin-left: auto;
        margin-right: auto;
    }
}

@media (min-width: 1200px) {
    body .author-sign-page > section > .container {
        padding-right: calc(var(--bs-gutter-x, 3rem) * .5);
    }

    body .author-sign-page > section > .author-sign-page__cta-inner {
        padding-right: clamp(28px, 5vw, 52px);
    }
}

@media (min-width: 992px) and (max-width: 1599.98px) {
    body .binding-service-detail .binding-hero__content {
        padding-right: 0;
    }
}
