/*
 * AVOCATS WILSON BÉZIERS
 * HOME HERO — V1
 * Palette : blanc, noir, bronze rouille.
 */

body.awb-home {
    margin: 0;
    background: #fff;
}

.awb-home .awb-skip-link {
    position: absolute;
    left: -9999px;
    top: 10px;
    z-index: 20;
}

.awb-home .awb-skip-link:focus {
    left: 10px;
    background: white;
    padding: 12px;
}

.awb-hero,
.awb-hero * {
    box-sizing: border-box;
}

.awb-hero {
    --awb-bronze-soft: #C6A07E;

    --rust: #8A5A3B;
    --deep: #70230f;

    position: relative;
    isolation: isolate;
    overflow: hidden;

    min-height: 100svh;
    padding: 30px 0 45px;

    color: #151515;
    background: #ffffff;

    /* AWB_BACKGROUND_SLOW_R14 */
    animation:
        awb-hero-color-cycle 32s ease-in-out infinite,
        awb-hero-ink-cycle 32s ease-in-out infinite;
    font-family: var(--awb-font-body);
}

/* Fond animé : blanc vers bronze rouille très pâle. */
.awb-hero__wash {
    position: absolute;
    inset: -12%;
    z-index: -3;
    pointer-events: none;

    background:
        radial-gradient(
            ellipse 60% 70% at 15% 25%,
            rgba(255,255,255,.10),
            transparent 75%
        ),
        radial-gradient(
            ellipse 55% 65% at 100% 50%,
            rgba(0,0,0,.045),
            transparent 80%
        );

    opacity: .25;

    animation:
        awb-background-breathe
        20s ease-in-out infinite;
}

.awb-hero::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -2;
    pointer-events: none;

    background: linear-gradient(
        140deg,
        rgba(255,255,255,.18),
        transparent 52%,
        rgba(30,28,28,.035)
    );
}

.awb-hero__container {
    position: relative;
    z-index: 3;

    width: min(
        calc(100% - 110px),
        1550px
    );

    min-height: calc(100svh - 75px);
    margin: auto;

    display: flex;
    flex-direction: column;
}

/* Identité du cabinet */
.awb-hero__brand {
    display: flex;
    align-items: center;
    gap: 26px;
    min-height: 75px;
}

.awb-hero__monogram {
    display: flex;
    align-items: baseline;

    font: normal 68px/.95 Georgia, serif;
    letter-spacing: -.12em;
}

.awb-hero__monogram span:last-child {
    color: var(--rust);
    animation: awb-hero-accent-cycle
        32s ease-in-out infinite;
    padding-right: .1em;
}

.awb-hero__brand-rule {
    width: 1px;
    height: 65px;
    background: var(--deep);
}

.awb-hero__brand-name {
    position: relative;

    font-size: clamp(15px, 1.75vw, 28px);
    font-weight: 700;
    letter-spacing: .22em;
    white-space: nowrap;
}

.awb-hero__brand-name::after {
    content: "";
    position: absolute;
    bottom: -16px;
    left: 0;

    width: 160px;
    height: 3px;
    background: var(--rust);
    animation: awb-hero-line-cycle
        32s ease-in-out infinite;
}

/* Texte principal */
.awb-hero__intro {
    position: relative;
    z-index: 4;

    max-width: min(63%, 880px);
    margin-top: clamp(50px, 7vh, 110px);
}

.awb-hero__title {
    font: 700 clamp(39px, 4.2vw, 72px)/1.12
          Georgia, serif;

    letter-spacing: -.035em;
    margin: 0 0 29px;
}

.awb-hero__title em {
    display: block;
    color: var(--rust);
    font-weight: 400;
    font-style: italic;

    animation: awb-hero-accent-cycle 32s ease-in-out infinite;
}

.awb-hero__description {
    max-width: 740px;

    font-size: clamp(17px, 1.48vw, 24px);
    line-height: 1.44;

    margin: 0 0 36px;
}

/* Boutons visuels — destinations à créer */
.awb-hero__actions {
    display: flex;
    align-items: center;
    gap: 24px;
    flex-wrap: wrap;
}

.awb-hero__action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 15px;

    min-height: 61px;
    padding: 0 30px;

    border-radius: 10px;
    border: 2px solid var(--rust);

    font-size: clamp(15px, 1.25vw, 20px);
    font-weight: 600;
    white-space: nowrap;

    cursor: default;
    user-select: none;
}

.awb-hero__action svg {
    width: 26px;
    height: 26px;

    fill: none;
    stroke: currentColor;
    stroke-width: 1.7;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.awb-hero__action--primary {
    background: var(--deep);
    color: white;
    box-shadow: 0 9px 17px rgba(87,28,13,.08);
}

.awb-hero__action--secondary {
    background: rgba(255,255,255,.7);
    color: #151515;
}

.awb-hero__action--secondary span {
    font-size: 27px;
    color: var(--rust);
}

/* Home A : photo du cabinet, fondu latéral et inférieur. */

body.awb-home:not(.awb-home--proposal-b) .awb-hero__portrait {
    position: absolute;
    top: -2%;
    right: -1%;
    bottom: auto;
    width: 54%;
    height: 96%;
    max-width: none;
    overflow: visible;
    opacity: 1;

    -webkit-mask-image:
        linear-gradient(
            to right,
            transparent 0%,
            rgba(0,0,0,.08) 10%,
            rgba(0,0,0,.40) 23%,
            rgba(0,0,0,.84) 36%,
            #000 45%,
            #000 60%,
            rgba(0,0,0,.92) 68%,
            rgba(0,0,0,.62) 78%,
            rgba(0,0,0,.23) 90%,
            transparent 100%
        ),
        linear-gradient(
            to bottom,
            transparent 0%,
            rgba(0,0,0,.72) 3%,
            #000 7%,
            #000 58%,
            rgba(0,0,0,.82) 64%,
            rgba(0,0,0,.35) 71%,
            transparent 78%,
            transparent 100%
        );

    -webkit-mask-composite: source-in;

    mask-image:
        linear-gradient(
            to right,
            transparent 0%,
            rgba(0,0,0,.08) 10%,
            rgba(0,0,0,.40) 23%,
            rgba(0,0,0,.84) 36%,
            #000 45%,
            #000 60%,
            rgba(0,0,0,.92) 68%,
            rgba(0,0,0,.62) 78%,
            rgba(0,0,0,.23) 90%,
            transparent 100%
        ),
        linear-gradient(
            to bottom,
            transparent 0%,
            rgba(0,0,0,.72) 3%,
            #000 7%,
            #000 58%,
            rgba(0,0,0,.82) 64%,
            rgba(0,0,0,.35) 71%,
            transparent 78%,
            transparent 100%
        );

    mask-composite: intersect;
}

body.awb-home:not(.awb-home--proposal-b) .awb-hero__portrait img {
    display: block;
    width: 100%;
    height: 100%;
    max-height: none;
    object-fit: contain;
    object-position: center top;
    filter: saturate(.90) contrast(1.05) brightness(.95);
    -webkit-mask-image: none;
    mask-image: none;
}

body.awb-home:not(.awb-home--proposal-b) .awb-hero__portrait::after {
    content: none;
}

/* Bouton secondaire clair, sans modifier le CTA principal. */
body.awb-home:not(.awb-home--proposal-b) .awb-hero__action--secondary {
    color: #272321;
    background-color: #e9e5e1;
    border-color: var(--rust);
}

body.awb-home:not(.awb-home--proposal-b) .awb-hero__action--secondary:hover,
body.awb-home:not(.awb-home--proposal-b) .awb-hero__action--secondary:focus-visible {
    color: #171717;
    background-color: #fff;
}

/* Mobile : photo dans le flux, jamais derrière le texte. */
@media (max-width: 760px) {
    body.awb-home:not(.awb-home--proposal-b) .awb-hero__portrait {
        position: relative;
        display: block;
        top: auto;
        right: auto;
        bottom: auto;
        left: auto;
        width: min(100%, 380px);
        height: clamp(210px, 60vw, 300px);
        max-width: none;
        margin: 18px auto 8px;
        overflow: hidden;
        opacity: 1;

        -webkit-mask-image: linear-gradient(
            to bottom,
            transparent 0%,
            #000 11%,
            #000 76%,
            transparent 100%
        );

        mask-image: linear-gradient(
            to bottom,
            transparent 0%,
            #000 11%,
            #000 76%,
            transparent 100%
        );
    }

    body.awb-home:not(.awb-home--proposal-b) .awb-hero__portrait img {
        display: block;
        width: 100%;
        height: 100%;
        max-height: none;
        object-fit: contain;
        object-position: center top;
        -webkit-mask-image: none;
        mask-image: none;
    }
}

/* Portrait original en noir et blanc */
.awb-hero__portrait {
    position: absolute;
    z-index: 1;
    right: -1%;
    top: 0;

    width: 51%;
    height: 79%;

    pointer-events: none;

    /* AWB_PORTRAIT_EDGES_R11
       Fondu gauche, droite et bas du portrait. */
    -webkit-mask-image:
        linear-gradient(
            to right,
            transparent 0%,
            black 14%,
            black 84%,
            transparent 100%
        ),
        linear-gradient(
            to bottom,
            black 0%,
            black 76%,
            transparent 100%
        );

    -webkit-mask-composite: source-in;

    mask-image:
        linear-gradient(
            to right,
            transparent 0%,
            black 14%,
            black 84%,
            transparent 100%
        ),
        linear-gradient(
            to bottom,
            black 0%,
            black 76%,
            transparent 100%
        );

    mask-composite: intersect;
}

.awb-hero__portrait img {
    width: 100%;
    height: 100%;

    object-fit: cover;
    object-position: center 23%;

    filter: grayscale(1);
}

.awb-hero__portrait::after {
    /* Le fondu est désormais géré par le masque. */
    content: none;
}

/* Courbes bronze rouille, sans doré */
.awb-hero__waves {
    position: absolute;
    z-index: 2;

    left: 0;
    right: 0;
    bottom: 108px;

    width: 100%;
    height: 275px;

    pointer-events: none;

    animation:
        awb-waves-drift
        20s ease-in-out infinite alternate;
}

/* Les quatre expertises */
.awb-hero__services {
    position: relative;
    z-index: 5;

    display: grid;
    grid-template-columns: repeat(4, minmax(0,1fr));
    gap: 20px;

    margin-top: auto;
    padding-top: clamp(80px, 11vh, 140px);
}

.awb-hero__service {
    color: #151515;
    min-width: 0;
    min-height: 150px;
    padding: 20px;

    background: rgba(255,255,255,.87);
    border-radius: 22px;
    border-bottom: 4px solid var(--deep);

    box-shadow: 0 14px 25px rgba(38,23,21,.18);
    backdrop-filter: blur(6px);

    transition:
        transform .35s ease,
        box-shadow .35s ease;
}

.awb-hero__service:hover {
    transform: translateY(-7px);
    box-shadow: 0 20px 30px rgba(47,21,16,.18);
}

.awb-hero__service-heading {
    display: flex;
    align-items: center;
    gap: 15px;
    min-height: 65px;
}

.awb-hero__service-heading svg {
    flex: 0 0 50px;
    width: 50px;
    height: 50px;

    fill: none;
    stroke: var(--rust);
    stroke-width: 2.6;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.awb-hero__service-heading h2 {
    font: 700 clamp(17px, 1.7vw, 28px)/1.12
          Georgia, serif;

    letter-spacing: -.035em;
    margin: 0;

    padding-left: 17px;
    border-left: 2px solid var(--rust);
}

.awb-hero__service p {
    text-align: center;
    font-size: clamp(13px, 1.15vw, 18px);
    line-height: 1.35;

    margin: 11px 0 0;
}

/* Animations */
/*
 * AWB — Cycle chromatique du fond
 * Blanc -> bronze rouille pâle -> blanc
 * Cycle complet : 32 secondes
 */
/* AWB_ANTHRACITE_R16 */
@keyframes awb-hero-color-cycle {
    0%, 100% {
        background-color: #ffffff;
    }

    18%, 82% {
        background-color: #eeeeed;
    }

    35%, 65% {
        background-color: #8d8887;
    }

    50% {
        background-color: #292626;
    }
}


/* Texte principal synchronisé avec le fond */
@keyframes awb-hero-ink-cycle {
    0%, 36%, 64%, 100% {
        color: #151515;
    }

    40%, 60% {
        color: #ffffff;
    }
}

/* Accent clair sur fond anthracite */
@keyframes awb-hero-accent-cycle {
    0%, 36%, 64%, 100% {
        color: #8A5A3B;
    }
    40%, 60% {
        color: #C6A07E;
    }
}


/* Ligne de l'identité du cabinet */
@keyframes awb-hero-line-cycle {
    0%, 36%, 64%, 100% {
        background-color: #8A5A3B;
    }
    40%, 60% {
        background-color: #C6A07E;
    }
}


@keyframes awb-background-breathe {
    0%, 100% {
        opacity: .22;
        transform: translate3d(-1%,0,0) scale(1.025);
    }

    50% {
        opacity: 1;
        transform: translate3d(1.4%,-1%,0) scale(1.065);
    }
}

@keyframes awb-rust-shift {
    0% { color: #70230f; }
    100% { color: #ab462e; }
}

@keyframes awb-waves-drift {
    0% {
        transform: translateY(2px);
        opacity: .8;
    }

    100% {
        transform: translateY(-8px);
        opacity: 1;
    }
}

/* Groupement du titre sur petit ecran */
.awb-hero__title-keep {
    display: contents;
}

/* Responsive consolide, y compris entre les seuils fractionnaires. */

@media (max-width: 1150px) {
    .awb-hero__container {
        width: min(calc(100% - 64px), 1000px);
    }

    .awb-hero__intro {
        max-width: 67%;
    }

    .awb-hero__portrait {
        width: 52%;
        height: 73%;
    }

    .awb-hero__services {
        gap: 12px;
    }

    .awb-hero__service {
        padding: 17px 12px;
        min-height: 137px;
    }

    .awb-hero__service-heading {
        gap: 8px;
    }

    .awb-hero__service-heading svg {
        flex-basis: 36px;
        width: 36px;
        height: 36px;
    }

    .awb-hero__service-heading h2 {
        padding-left: 10px;
    }

}

@media (min-width: 761px) {
    .awb-hero {
        padding: 24px 0 30px;
    }

    .awb-hero__container {
        min-height: calc(100svh - 54px);
    }

    .awb-hero__brand {
        min-height: 58px;
        gap: 18px;
    }

    .awb-hero__monogram {
        font-size: 50px;
    }

    .awb-hero__brand-rule {
        height: 48px;
    }

    .awb-hero__brand-name::after {
        bottom: -11px;
        height: 2px;
        width: 108px;
    }

    .awb-hero__intro {
        max-width: min(64%, 760px);
        margin-top: clamp(32px, calc(100svh - 600px), 180px);
    }

    .awb-hero__title {
        font-size: clamp(38px, 3.3vw, 54px);
        line-height: 1.13;
        margin-bottom: 20px;
    }

    .awb-hero__description {
        max-width: 640px;
        font-size: clamp(15px, 1.12vw, 19px);
        margin-bottom: 26px;
    }

    .awb-hero__actions {
        gap: 16px;
    }

    .awb-hero__action {
        min-height: 50px;
        padding: 0 22px;
        font-size: clamp(14px, 1vw, 16px);
        gap: 10px;
        border-radius: 9px;
    }

    .awb-hero__action svg {
        width: 21px;
        height: 21px;
    }

    .awb-hero__action--secondary span {
        font-size: 22px;
    }

    .awb-hero__services {
        gap: 16px;
        padding-top: clamp(8px, 1.5vh, 20px);
        transform: translateY(clamp(-24px, calc(64px - 10svh), 0px));
    }

    .awb-hero__service {
        min-height: 120px;
        padding: 14px 16px;
        border-radius: 16px;
    }

    .awb-hero__service-heading {
        min-height: 52px;
        gap: 10px;
    }

    .awb-hero__service-heading svg {
        flex: 0 0 36px;
        width: 36px;
        height: 36px;
    }

    .awb-hero__service-heading h2 {
        font-size: clamp(16px, 1.35vw, 22px);
        padding-left: 11px;
    }

    .awb-hero__service p {
        font-size: clamp(12px, .9vw, 15px);
        margin-top: 9px;
    }

    .awb-hero__waves {
        height: 190px;
        bottom: 82px;
    }

    .awb-hero__brand-name {
        font-size: clamp(12px, 1.05vw, 17px);
        letter-spacing: .16em;
    }

    .awb-hero__portrait {
        transform: none;
        width: min(28vw, 450px);
        max-width: 450px;
        right: 34px;
        bottom: 18px;
        overflow: visible;
        -webkit-mask-image: none;
        mask-image: none;
    }

    .awb-hero__portrait img {
        height: auto;
        max-height: min(70vh, 600px);
        object-fit: contain;
        object-position: bottom center;
        -webkit-mask-image: linear-gradient(
            to right,
            #000 0%,
            #000 83%,
            transparent 100%
            ),
            linear-gradient(
            to bottom,
            #000 0%,
            #000 72%,
            transparent 100%
            );
        -webkit-mask-composite: source-in;
        mask-image: linear-gradient(
            to right,
            #000 0%,
            #000 83%,
            transparent 100%
            ),
            linear-gradient(
            to bottom,
            #000 0%,
            #000 72%,
            transparent 100%
            );
        mask-composite: intersect;
    }

}

@media (min-width: 761px) and (max-width: 1150px) {
    .awb-hero__intro {
        max-width: 67%;
        margin-top: clamp(100px, 14vh, 135px);
    }

    .awb-hero__title {
        font-size: clamp(34px, 4vw, 48px);
    }

    .awb-hero__services {
        gap: 12px;
        transform: translateY(clamp(-18px, calc(64px - 10svh), 0px));
        padding-top: 10px;
    }

    .awb-hero__service {
        padding: 14px 10px;
    }

    .awb-hero__service-heading h2 {
        font-size: 18px;
    }

    .awb-hero__service p {
        font-size: 13px;
    }

    .awb-hero__brand-name {
        font-size: 15px;
    }

    .awb-hero__portrait {
        width: min(30vw, 390px);
        max-width: 390px;
        right: 16px;
        bottom: 10px;
    }

    .awb-hero__portrait img {
        max-height: min(64vh, 520px);
    }

}

@media (max-width: 760px) {
    .awb-hero__title-keep {
        display: inline-block;
        white-space: nowrap;
    }

    .awb-hero__title .awb-hero__title-keep em {
        display: inline;
    }

    .awb-hero__container {
        width: calc(100% - 36px);
        min-height: 0;
    }

    .awb-hero__brand-name {
        white-space: normal;
        font-size: clamp(9px, 2.4vw, 13px);
        letter-spacing: .10em;
    }

    .awb-hero__brand-name::after {
        width: 75px;
        bottom: -8px;
        height: 2px;
    }

    .awb-hero__intro {
        max-width: 100%;
        margin-top: 44px;
    }

    .awb-hero__actions {
        gap: 11px;
    }

    .awb-hero__portrait {
        position: relative;
        top: auto;
        right: auto;
        margin-top: 15px;
        height: 290px;
        margin-inline: auto;
        width: min(68vw, 290px);
        max-width: 290px;
        -webkit-mask-image: none;
        mask-image: none;
    }

    .awb-hero__portrait img {
        object-position: center bottom;
        object-fit: contain;
        max-height: 360px;
    }

    .awb-hero__services {
        grid-template-columns: repeat(2,minmax(0,1fr));
        padding-top: 4px;
        gap: 10px;
        transform: translateY(-8px);
    }

    .awb-hero__service-heading {
        align-items: flex-start;
        flex-direction: column;
        gap: 6px;
    }

    .awb-hero__service-heading h2 {
        border: 0;
        padding-left: 0;
        font-size: clamp(16px, 4vw, 18px);
    }

    .awb-hero__service-heading svg {
        height: 31px;
        width: 31px;
    }

    .awb-hero__service p {
        text-align: left;
        font-size: 12px;
        margin-top: 7px;
    }

    .awb-hero {
        padding: 18px 0 22px;
    }

    .awb-hero__brand {
        min-height: 43px;
        gap: 10px;
    }

    .awb-hero__monogram {
        font-size: 39px;
    }

    .awb-hero__brand-rule {
        height: 37px;
    }

    .awb-hero__title {
        font-size: clamp(30px, 7.4vw, 42px);
        line-height: 1.13;
        margin-bottom: 16px;
    }

    .awb-hero__description {
        font-size: 14px;
        line-height: 1.45;
        margin-bottom: 20px;
    }

    .awb-hero__action {
        min-height: 44px;
        padding: 0 13px;
        font-size: 13px;
    }

    .awb-hero__waves {
        height: 140px;
    }

    .awb-hero__service {
        min-height: 116px;
        padding: 12px;
        border-radius: 13px;
    }

}

@media (max-width: 420px) {
    .awb-hero__action {
        width: 100%;
    }

}

/* Accessibilité : animations désactivables */
@media (prefers-reduced-motion: reduce) {
    .awb-hero,
    .awb-hero__wash,
    .awb-hero__waves,
    .awb-hero__title em,
    .awb-hero__monogram span:last-child,
    .awb-hero__brand-name::after {
        animation: none !important;
    }

    .awb-hero__service {
        transition: none !important;
    }
}


/* Navigation native des cartes Wilson. */
a.awb-hero__service:link,
a.awb-hero__service:visited,
a.awb-hero__service:hover,
a.awb-hero__service:active {
    color: inherit;
    text-decoration: none;
}

a.awb-hero__action--secondary:link,
a.awb-hero__action--secondary:visited,
a.awb-hero__action--secondary:hover,
a.awb-hero__action--secondary:active {
    text-decoration: none;
}
