/*
 * Mobile overrides
 *
 * Purpose:
 * - Keep mobile-specific fixes isolated from the current desktop baseline.
 * - Apply responsive corrections here, section by section.
 *
 * Rules:
 * - Default to targeted patches instead of broad global overrides.
 * - Prefer max-width media queries while the existing desktop CSS remains the source of truth.
 * - Add changes incrementally and verify both mobile and desktop after each update.
 */

@media (max-width: 860px) {
    html {
        font-size: 100%;
    }

    .site-header,
    .site-header.is-scrolled {
        position: fixed;
        inset: 0 0 auto;
        background: transparent;
        box-shadow: none;
        backdrop-filter: none;
    }

    .page-home .hero {
        padding: 0;
    }

    .page-home .hero__panel {
        justify-self: center;
        align-self: center;
        margin-inline: auto;
    }

    .page-home #contact .contact-form .field-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 0.7rem 0.65rem;
    }

    .page-home #contact .contact-form .field-grid > :nth-child(n + 3) {
        grid-column: 1 / -1;
    }

    .page-home #contact .contact-form .field-grid label {
        margin-bottom: 0;
    }

    .page-home #avis-clients .reviews-slider {
        padding: 0.55rem;
    }

    .page-home #avis-clients .slider-card__viewport {
        min-height: 500px;
    }

    .page-home #avis-clients .reviews-slider__viewport {
        min-height: 300px;
    }

    .page-home #avis-clients .review-slide__content {
        gap: 0.35rem;
        padding: 0.85rem 0.85rem 0.8rem;
    }

    .page-home #avis-clients .review-slide__meta {
        gap: 0.4rem;
        min-height: 0;
    }

    .page-home #avis-clients .review-slide__identity {
        gap: 0.6rem;
    }

    .page-home #avis-clients .review-slide__avatar {
        width: 2.45rem;
        height: 2.45rem;
    }

    .page-home #avis-clients .review-slide__response {
        padding: 0.68rem 0.75rem;
    }

    .eyebrow {
        font-size: 0.624rem;
    }

    .contact-layout__eyebrow {
        font-size: 0.507rem;
    }

    .page-home .hero__copy .eyebrow {
        font-size: clamp(0.546rem, 0.598vw, 0.624rem);
    }

    h1 {
        font-size: clamp(2.1rem, 5.25vw, 4.35rem);
    }

    .hero__copy h1 {
        font-size: clamp(2.25rem, 3.75vw, 3.75rem);
    }

    .news-hero .section-head h1,
    .news-section--actualites .section-head h1 {
        font-size: clamp(1.2375rem, 2.1vw, 1.875rem);
    }

    h2 {
        font-size: clamp(1.4025rem, 2.38vw, 2.125rem);
    }

    .slider-card__header h2,
    .catalog-stack__header h2 {
        font-size: clamp(1.105rem, 1.445vw, 1.445rem);
    }

    .page-news .news-section--catalogues .news-section__head h2 {
        font-size: clamp(1.3175rem, 2.295vw, 1.785rem);
    }

    .realization-modal__body h2 {
        font-size: clamp(1.2325rem, 1.7vw, 1.87rem);
    }

    h3 {
        font-size: clamp(1.02rem, 1.7vw, 1.275rem);
    }

    .service-card h3 {
        font-size: clamp(1.122rem, 1.4875vw, 1.428rem);
    }

    .service-family h3,
    .page-home #prestations .service-family h3 {
        font-size: clamp(1.1475rem, 2.55vw, 1.36rem);
    }

    .contact-layout__intro h3,
    .page-home #contact .contact-layout__intro h3 {
        font-size: clamp(1.3175rem, 1.7vw, 1.7rem);
    }

    .catalog-partners__panel-head h3,
    .page-news .news-section--catalogues .catalog-partners__panel-head h3 {
        font-size: 0.765rem;
    }

    .catalog-feature__body h3,
    .page-news .news-section--catalogues .catalog-feature__body h3 {
        font-size: clamp(1.156rem, 1.615vw, 1.496rem);
    }

    .catalog-rail__body h3,
    .page-news .news-section--catalogues .catalog-rail__body h3 {
        font-size: 0.765rem;
    }

    .page-news #realisations-list .realization-card__body h3 {
        font-size: 0.884rem;
    }

    .page-home #realisations .portfolio-card__body h3 {
        font-size: 0.918rem;
    }

    .slide__body h3,
    .page-news .news-section--actualites .slide__body h3 {
        font-size: 1.037rem;
    }

    .page-home #presentation .intro__card h3 {
        font-size: clamp(1.02rem, 1.7vw, 1.275rem);
    }

    .reviews-slider .slider-card__header h3 {
        font-size: clamp(0.9775rem, 1.36vw, 1.2325rem);
    }

    body {
        font-size: 0.85rem;
    }

    .hero__lead,
    .page-home .hero__lead {
        font-size: clamp(0.918rem, 1.445vw, 1.105rem);
    }

    .contact-layout__summary {
        font-size: 0.833rem;
    }

    .contact-layout__note span {
        font-size: 0.782rem;
    }

    .form-shell__intro {
        font-size: 0.799rem;
    }

    .form-note {
        font-size: 0.782rem;
    }

    .news-section__lead > p,
    .news-section--actualites .news-section__lead > p {
        font-size: 0.85rem;
    }

    .news-hero .section-head p:last-child,
    .news-section--actualites .section-head p:last-child {
        font-size: 0.748rem;
    }

    .news-history__head p:last-child {
        font-size: 0.765rem;
    }

    .catalog-partners__panel-head p {
        font-size: 0.765rem;
    }

    .catalog-feature__body p {
        font-size: 0.85rem;
    }

    .catalog-rail__body p {
        font-size: 0.663rem;
    }

    .catalog-stack__label {
        font-size: 0.624rem;
    }

    .catalog-partners__video-label {
        font-size: 0.656rem;
    }

    .news-history__count {
        font-size: 0.736rem;
    }

    .page-news #realisations-list .realization-card__body p {
        font-size: 0.748rem;
    }

    .page-home .portfolio-card__body p,
    .page-home #realisations .portfolio-card__body p {
        font-size: 0.8075rem;
    }

    .realization-modal__body p {
        font-size: 0.85rem;
    }

    .slide__body p,
    .page-news .news-section--actualites .slide__body p {
        font-size: 0.714rem;
    }

    .review-slide__author {
        font-size: 0.8925rem;
    }

    .review-slide__text {
        font-size: 0.8075rem;
    }

    .review-slide__response-title {
        font-size: 0.85rem;
    }

    .review-slide__response time,
    .review-slide__response-text {
        font-size: 0.7225rem;
    }

    .page-home #presentation .intro__card p,
    .page-home #presentation .intro__band span {
        font-size: 0.85rem;
    }

    .chip {
        font-size: 0.592rem;
    }

    .meta-row time {
        font-size: 0.656rem;
    }

    .slide__support-title,
    .page-news .news-section--actualites .slide__support-title {
        font-size: 0.624rem;
    }

    .slide__support-list,
    .page-news .news-section--actualites .slide__support-list {
        font-size: 0.656rem;
    }

    .catalog-feature__tag,
    .catalog-rail__pages {
        font-size: 0.64rem;
    }

    .review-slide__meta time {
        font-size: 0.704rem;
    }

    .review-slide__rating-label {
        font-size: 0.704rem;
    }

    .review-slide__response-author {
        font-size: 0.656rem;
    }

    button,
    .button,
    .news-pagination__link {
        font-size: 0.9rem;
    }

    .site-nav__link {
        font-size: 1.044rem;
    }

    .page-news .news-section--actualites .slide__actions .button {
        font-size: 0.666rem;
    }

    .contact-box__phone {
        font-size: clamp(0.9rem, 1.215vw, 1.062rem);
    }

    .hero__contact-card a,
    .page-home .hero__contact-card a {
        font-size: 1.17rem;
    }

    .site-footer {
        font-size: 0.7rem;
    }

    .site-footer__brand p {
        font-size: 0.665rem;
    }

    .site-footer__column a,
    .site-footer__column p,
    .site-footer__credit {
        font-size: 0.651rem;
    }

    .site-footer__hours-label {
        font-size: 0.644rem;
    }

    .site-footer__hours-value {
        font-size: 0.63rem;
    }

    .site-footer__column h2 {
        font-size: 0.756rem;
    }

    .intro__team figcaption,
    .page-home #presentation .intro__team figcaption {
        font-size: clamp(1.71rem, 6.3vw, 2.205rem);
    }

    .site-header__inner {
        justify-content: flex-end;
    }

    .site-header .brand {
        display: none;
        margin-left: 0;
    }

    .site-header[data-mobile-brand-visible="true"] .site-header__inner {
        justify-content: space-between;
    }

    .site-header[data-mobile-brand-visible="true"] .brand {
        display: inline-flex;
        margin-left: -1.1rem;
    }
}

@media (max-width: 1024px) {
    .site-footer {
        padding: 0.75rem 1rem 1rem;
    }

    .site-footer__panel {
        grid-template-columns: 1fr;
        justify-items: center;
        gap: 0.3rem;
        padding: 0.95rem;
        border-radius: 24px;
        text-align: center;
    }

    .site-footer__brand {
        justify-items: center;
        gap: 0;
        margin-bottom: -0.08rem;
    }

    .site-footer__brand img {
        width: clamp(150px, 32vw, 210px);
    }

    .site-footer__column {
        width: min(100%, 420px);
        justify-items: center;
        gap: 0;
    }

    .site-footer__column h2 {
        width: 100%;
        margin: 0;
        font-size: 0.86rem;
    }

    .site-footer__accordion-toggle {
        width: 100%;
        min-height: 34px;
        padding: 0.18rem 0.82rem;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        gap: 0.42rem;
        border-radius: 999px;
        cursor: pointer;
    }

    .site-footer__accordion-toggle::after {
        content: "";
        width: 0.48rem;
        height: 0.48rem;
        border-right: 2px solid currentColor;
        border-bottom: 2px solid currentColor;
        transform: translateY(-0.12rem) rotate(45deg);
        transition: transform 0.2s ease;
    }

    .site-footer__column.is-open .site-footer__accordion-toggle::after {
        transform: translateY(0.1rem) rotate(225deg);
    }

    .site-footer__accordion-content {
        width: 100%;
        justify-items: center;
        gap: 0.36rem;
        padding: 0.25rem 0 0.15rem;
    }

    .site-footer__accordion-content[hidden] {
        display: none;
    }

    .site-footer__hours-list {
        justify-items: center;
        gap: 0.34rem;
    }

    .site-footer__hours-item {
        justify-items: center;
    }

    .site-footer__column--social {
        width: auto;
        margin-top: 0.08rem;
        justify-items: center;
    }

    .site-footer__social-copy {
        display: none;
    }

    .site-footer__social-title {
        display: none;
    }

    .site-footer__socials {
        justify-content: center;
        align-items: center;
        gap: 0.58rem;
    }

    .site-footer__social-link {
        width: 40px;
        height: 40px;
    }

    .site-footer__social-link svg {
        width: 18px;
        height: 18px;
    }

    .site-footer__bottom {
        padding-top: 0.55rem;
    }
}
