/* Couteau Mora — atelier-derived custom styles */

body {
    font-family: 'Open Sans', 'Roboto', ui-sans-serif, system-ui, sans-serif;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: 'Roboto', 'Open Sans', ui-sans-serif, system-ui, sans-serif;
}

h1.font-display {
    font-weight: 900;
}

h2,
h3,
h4,
h5,
h6 {
    font-weight: 800;
}

.font-display {
    font-family: 'Roboto', 'Open Sans', ui-sans-serif, system-ui, sans-serif;
    font-weight: 800;
}

.font-display.font-bold,
h2.font-bold,
h3.font-bold {
    font-weight: 800;
}

html {
    scroll-behavior: smooth;
}

#header.scrolled {
    background-color: rgba(242, 245, 240, 0.93);
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 3px 0 rgb(0 0 0 / 0.08);
}

#mobile-menu {
    transition: opacity 0.25s ease-out, max-height 0.3s ease-out;
}

.img-zoom img {
    transition: transform 0.55s cubic-bezier(0.16, 1, 0.32, 1);
}

.img-zoom:hover img {
    transform: scale(1.04);
}

.hover-lift {
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.hover-lift:hover {
    transform: translateY(-3px);
    box-shadow: 0 20px 40px -24px rgba(44, 61, 51, 0.35);
}

.hide-scrollbar {
    scrollbar-width: none;
}

.hide-scrollbar::-webkit-scrollbar {
    display: none;
}

a:focus-visible,
button:focus-visible,
summary:focus-visible {
    outline: 2px solid #c45c26;
    outline-offset: 2px;
}

details summary {
    list-style: none;
}

details summary::-webkit-details-marker {
    display: none;
}

/* Header — menus déroulants (desktop) */
.nav-dropdown > summary.nav-dropdown-summary {
    list-style: none;
    cursor: pointer;
    user-select: none;
    padding: 0.5rem 0.35rem;
    border-radius: 0.375rem;
    display: inline-flex;
    align-items: center;
    gap: 0.2rem;
}

.nav-dropdown > summary.nav-dropdown-summary:hover {
    opacity: 1;
}

.nav-dropdown > summary.nav-dropdown-summary .caret {
    font-size: 0.62rem;
    opacity: 0.55;
}

.nav-dropdown[open] > summary.nav-dropdown-summary {
    opacity: 1;
}

.nav-dropdown-panel {
    position: absolute;
    left: 0;
    top: calc(100% + 6px);
    min-width: 12rem;
    padding: 0.45rem 0;
    border-radius: 0.75rem;
    border: 1px solid hsl(140 12% 88%);
    background-color: rgba(242, 245, 240, 0.97);
    backdrop-filter: blur(10px);
    box-shadow: 0 16px 40px -20px rgba(44, 61, 51, 0.35);
    z-index: 60;
}

.nav-dropdown-link {
    display: block;
    padding: 0.55rem 1rem;
    font-size: 0.9375rem;
    font-weight: 600;
    text-transform: none;
    letter-spacing: 0.02em;
    color: inherit;
    text-decoration: none;
}

.nav-dropdown-link:hover {
    background-color: hsl(130 18% 94%);
}

/* Mobile — sections repliables */
.mobile-nav-row {
    display: block;
    font-family: 'Roboto', 'Open Sans', ui-sans-serif, system-ui, sans-serif;
    font-size: 1rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    padding: 0.85rem 0;
    border-bottom: 1px solid hsl(140 12% 88% / 0.65);
    color: inherit;
    text-decoration: none;
}

.mobile-nav-details {
    border-bottom: 1px solid hsl(140 12% 88% / 0.65);
}

.mobile-nav-details > summary.mobile-nav-summary {
    list-style: none;
    cursor: pointer;
    font-family: 'Roboto', 'Open Sans', ui-sans-serif, system-ui, sans-serif;
    font-size: 1rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    padding: 0.85rem 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
}

.mobile-nav-details > summary.mobile-nav-summary::after {
    content: '+';
    font-weight: 700;
    opacity: 0.45;
    font-size: 1.1rem;
}

.mobile-nav-details[open] > summary.mobile-nav-summary::after {
    content: '−';
}

.mobile-nav-submenu {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    padding: 0 0 0.85rem 0.75rem;
}

.mobile-nav-submenu a {
    font-size: 0.95rem;
    font-weight: 600;
    padding: 0.45rem 0;
    color: inherit;
    text-decoration: none;
    border-radius: 0.25rem;
}

.mobile-nav-submenu a:hover {
    color: #c45c26;
}

/* Articles — intertitres */
.article-h2 {
    font-family: 'Roboto', 'Open Sans', ui-sans-serif, system-ui, sans-serif;
    font-size: clamp(1.125rem, 2.5vw, 1.375rem);
    font-weight: 800;
    line-height: 1.25;
    color: hsl(150 25% 18%);
    margin-top: 2.25rem;
    margin-bottom: 0.4rem;
    scroll-margin-top: 5.5rem;
}

.article-body > .article-h2:first-of-type {
    margin-top: 0;
}

/* Homepage — étapes « Structurer son apprentissage » */
.journey-steps-wrap {
    box-shadow:
        inset 0 1px 0 hsl(140 14% 100% / 0.65),
        0 1px 2px hsl(140 18% 20% / 0.06);
}

.journey-step-card {
    position: relative;
    overflow: hidden;
}

.journey-step-cap {
    height: 0.3125rem;
    background: linear-gradient(
        90deg,
        #c45c26 0%,
        hsl(28 82% 48%) 40%,
        hsl(142 22% 36%) 100%
    );
    opacity: 0.92;
}

.journey-step-card:hover .journey-step-cap {
    opacity: 1;
}

.journey-step-num {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2.75rem;
    height: 2.75rem;
    border-radius: 0.75rem;
    font-family: 'Roboto', 'Open Sans', ui-sans-serif, system-ui, sans-serif;
    font-size: 0.875rem;
    font-weight: 900;
    letter-spacing: -0.04em;
    color: hsl(150 28% 16%);
    background: linear-gradient(145deg, hsl(130 22% 96%) 0%, hsl(130 14% 90%) 100%);
    border: 1px solid hsl(140 12% 86%);
    box-shadow:
        inset 0 1px 0 hsl(0 0% 100% / 0.88),
        0 6px 16px -8px rgba(44, 61, 51, 0.28);
}

.journey-step-card:hover .journey-step-num {
    border-color: hsl(28 62% 55% / 0.45);
    color: hsl(150 26% 12%);
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    .img-zoom img,
    .hover-lift {
        transition: none;
    }

    .img-zoom:hover img {
        transform: none;
    }

    .journey-step-card {
        transition: none;
        transform: none;
    }

    .journey-step-card:hover {
        transform: none;
    }
}
