/* ============================================
   NEOFARM PAGE
   ============================================ */

body:has(.nf-hero) {
    --section-line-color: rgba(255,255,255,0.30);
}

/* Couche noire continue depuis la 1re section après le héros jusqu'au bas du footer */
body:has(.nf-hero) .footer {
    background: rgba(0,0,0,0.30);
    margin-top: 0;
    margin-bottom: 0;
    padding-top: 40px;
    padding-bottom: 32px;
}


/* ── HERO ── */
.nf-hero {
    --nf-title-size: clamp(64px, 12vw, 160px);
    position: relative;
    margin: 0;
    padding: 80px 32px 0;
    border-bottom: none;
}
.nf-hero::after {
    content: '';
    position: absolute;
    left: var(--section-line-inset);
    right: var(--section-line-inset);
    bottom: 0;
    height: 1px;
    background: var(--section-line-color);
}

.nf-title {
    font-family: 'Monda', sans-serif;
    font-weight: 700;
    font-size: var(--nf-title-size);
    letter-spacing: -0.02em;
    line-height: 1;
    margin: 0;
    text-align: center;
    animation: nfSlideInUp 1s cubic-bezier(0.22, 1, 0.36, 1) 0.1s both;
}

@keyframes nfSlideInUp {
    from { transform: translateY(80px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

.nf-hero-meta {
    position: absolute;
    left: 32px;
    top: calc(80px + var(--nf-title-size) + 64px);
    display: flex;
    flex-direction: column;
    gap: 4px;
    font-size: 11px;
    color: rgba(255,255,255,0.70);
    letter-spacing: 0.05em;
    z-index: 3;
}

.nf-hero-meta .meta-tag {
    color: #FFFFFF;
}

.nf-hero-image {
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: flex-end;
    margin-top: calc(var(--nf-title-size) * -0.36 - 32px);
    position: relative;
    z-index: 2;
}

.nf-hero-image img {
    max-width: 760px;
    width: 72%;
    height: auto;
    display: block;
    position: relative;
    z-index: 0;
}

.nf-hero-image::after {
    content: '';
    position: absolute;
    inset: 0;
    background: transparent;
    pointer-events: none;
    z-index: 1;
}

.nf-hero-label {
    position: absolute;
    bottom: 32px;
    right: 32px;
    font-size: 24px;
    color: #FFFFFF;
    letter-spacing: 0.02em;
    z-index: 4;
}

/* ── A PROPOS ── */
.nf-about {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 40px;
    padding: 48px 32px 0;
    border-bottom: none;
    background: rgba(0,0,0,0.30);
    margin: 0;
}

.nf-role-label {
    font-size: 14px;
    color: rgba(255,255,255,0.60);
    opacity: 1;
    margin-bottom: 8px;
    letter-spacing: 0.05em;
}

.nf-role-value {
    font-size: 16px;
    opacity: 0.85;
}

.nf-section-title {
    font-size: 20px;
    font-weight: 700;
    letter-spacing: 0.05em;
    color: #FFFFFF;
    margin-bottom: 24px;
}

.nf-about-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0;
}

.nf-about-list li {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    font-size: 15px;
    color: rgba(255,255,255,0.55);
    border-bottom: 1px solid rgba(255,255,255,0.30);
}

.nf-about-list li:last-child { border-bottom: none; }

.nf-num {
    font-size: 12px;
    color: rgba(255,255,255,0.60);
    opacity: 1;
    letter-spacing: 0.1em;
}

/* ── DESCRIPTION ── */
.nf-description {
    padding: 48px 32px;
    margin: 0;
    background: rgba(0,0,0,0.30);
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 16px;
    font-size: 20px;
    line-height: 1.7;
    color: rgba(255,255,255,0.85);
}

.nf-description p {
    max-width: 780px;
}

.nf-description p:last-of-type {
    color: rgba(255,255,255,0.6);
}

.nf-description::after {
    content: '';
    position: absolute;
    left: var(--section-line-inset);
    right: var(--section-line-inset);
    bottom: 0;
    height: 1px;
    background: var(--section-line-color);
}

/* ── COLUMNS override for this page ── */
.nf-columns {
    border-bottom: none;
    padding-left: 32px;
    padding-right: 32px;
}

.nf-sub-columns {
    margin-top: 0;
    padding: 48px 0 0;
    border-top: none;
    border-bottom: none;
    position: relative;
    background: transparent;
}
.nf-sub-columns::before {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    top: 0;
    height: 1px;
    background: var(--section-line-color);
}
.nf-sub-columns::after {
    display: none;
}

/* ── BLOCKS (accordion-style sections) ── */
.nf-block {
    padding: 48px 32px;
    margin: 0;
    border-bottom: none;
    background: rgba(0,0,0,0.30);
    position: relative;
}
.nf-block::after {
    content: '';
    position: absolute;
    left: var(--section-line-inset);
    right: var(--section-line-inset);
    bottom: 0;
    height: 1px;
    background: var(--section-line-color);
}

.nf-block-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 28px;
    cursor: pointer;
    user-select: none;
}

.nf-block-header .nf-section-title { margin-bottom: 0; }

.nf-toggle-btn {
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.15);
    border-radius: 8px;
    width: 36px; height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #FFFFFF;
    cursor: pointer;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.nf-toggle-btn:hover {
    background: rgba(255,255,255,0.12);
    border-color: rgba(255,255,255,0.3);
}

.nf-icon-plus {
    transition: transform 0.3s ease;
}

.nf-block-header.is-open .nf-icon-plus {
    transform: rotate(45deg);
}

.nf-block-body {
    overflow: hidden;
    max-height: 0;
    opacity: 0;
    transition: max-height 0.5s ease, opacity 0.4s ease;
}

.nf-block-body.is-open {
    max-height: 2000px;
    opacity: 1;
}

.nf-block-header-static { cursor: default; }
.nf-block-static { display: block; }

/* ── FIGMA ICON BUTTON (header right) ── */
.nf-figma-icon-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 52px;
    padding: 0;
    border-radius: 12px;
    background: transparent;
    border: none;
    color: rgba(255,255,255,0.85);
    text-decoration: none;
    flex-shrink: 0;
    transition: transform 0.2s ease;
}
.nf-figma-icon-btn:hover {
    color: #FFFFFF;
}
.nf-figma-icon-btn:active { transform: scale(0.96); }

.nf-figma-icon-img {
    width: 50px;
    height: 50px;
    object-fit: contain;
    display: block;
}

/* ── SOUS-TITRES UNIFIÉS (20px / blanc 60%) ── */
.nf-subtitle,
.nf-sub-columns .column-title,
.nf-typo-col-name .nf-typo-col-label,
.nf-color-block .nf-sub-label,
.nf-result-label {
    font-size: 18px;
    font-weight: 700;
    color: rgba(255,255,255,0.60);
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

/* ── BULLET LIST (DEMARCHE UX columns) ── */
.nf-bullet-list {
    list-style: disc;
    padding-left: 20px;
}
.nf-bullet-list li {
    padding-left: 4px;
}
.nf-bullet-list li::marker {
    color: rgba(255,255,255,0.60);
}

/* ── TAG LABEL ── */
.nf-tag-label {
    font-size: 14px;
    color: rgba(255,255,255,0.60);
    opacity: 1;
    letter-spacing: 0.05em;
}

.nf-ds-list {
    max-width: 50vw;
}

.nf-block .list-letter,
.nf-ds-list .list-letter {
    font-size: 12px;
    color: rgba(255,255,255,0.60);
    letter-spacing: 0.1em;
    white-space: nowrap;
}

.nf-num,
.nf-tag-label,
.nf-typo-tag,
.nf-hero-meta .meta-tag {
    white-space: nowrap;
}

/* ── ARBORESCENCE ── */
.nf-arbo {
    width: 100%;
    border: 1px solid rgba(255,255,255,0.15);
    border-radius: 12px;
    padding: 8px;
    overflow: hidden;
    background: rgba(255,255,255,0.02);
}

.nf-arbo img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 6px;
}

/* ── TYPOGRAPHIE BLOCK ── */
.nf-typo-block {
    display: grid;
    grid-template-columns: 2.2fr 1fr 1fr 1.4fr;
    align-items: stretch;
    gap: 0;
    padding: 0;
    border-bottom: 1px solid rgba(255,255,255,0.30);
    margin-bottom: 40px;
    position: relative;
    min-height: 280px;
}
.nf-typo-block::before {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    top: 0;
    height: 1px;
    background: var(--section-line-color);
    z-index: 5;
}

.nf-typo-col {
    position: relative;
    display: flex;
    flex-direction: column;
    padding: 32px 24px;
    overflow: hidden;
}

.nf-typo-col + .nf-typo-col::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 1px;
    background: rgba(255,255,255,0.30);
}

.nf-typo-col-tag::before {
    display: none;
}

.nf-typo-col-label {
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.18em;
    color: rgba(255,255,255,0.85);
    text-transform: uppercase;
}

.nf-typo-col-name {
    padding-left: 0;
    gap: 24px;
}

.nf-typo-display {
    font-family: 'Raleway', sans-serif;
    font-weight: 700;
    font-size: clamp(48px, 7vw, 104px);
    color: rgba(255,255,255,0.55);
    line-height: 1;
}

.nf-typo-col-sample {
    align-items: flex-start;
    justify-content: flex-start;
}

.nf-typo-regular,
.nf-typo-bold {
    font-family: 'Raleway', sans-serif;
    font-size: clamp(120px, 18vw, 280px);
    color: rgba(255,255,255,0.55);
    line-height: 0.85;
    margin-top: auto;
    margin-left: -24px;
    margin-bottom: -24px;
    align-self: flex-end;
    pointer-events: none;
}

.nf-typo-regular { font-weight: 400; }
.nf-typo-bold { font-weight: 700; }

.nf-typo-col-bold {
    transform: translateX(-38%);
    transition: transform 0.45s cubic-bezier(0.22, 1, 0.36, 1);
    will-change: transform;
    background:
        linear-gradient(rgba(0,0,0,0.30), rgba(0,0,0,0.30)),
        url(assets/Noise.png),
        #000;
    z-index: 2;
}

.nf-typo-col-regular {
    z-index: 1;
}

.nf-typo-col-regular:hover + .nf-typo-col-bold {
    transform: translateX(0);
}

.nf-typo-col-tag {
    align-items: flex-end;
    padding-right: 0;
}

.nf-typo-tag {
    font-size: 14px;
    color: rgba(255,255,255,0.60);
    letter-spacing: 0.05em;
}

/* ── COLORIMETRIE ── */
.nf-color-block {
    margin-bottom: 40px;
}

.nf-sub-label {
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.18em;
    color: #FFFFFF;
    margin-bottom: 24px;
    text-transform: uppercase;
}

.nf-swatches {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
    justify-content: center;
}

.nf-swatch-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 6px 28px 6px 10px;
    border-radius: 999px;
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.2);
    flex: 1 1 220px;
    max-width: 260px;
    backdrop-filter: blur(10px);
}

.nf-swatch {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    flex-shrink: 0;
}

.nf-swatch-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.nf-swatch-name {
    font-size: 13px;
    color: rgba(255,255,255,0.85);
    letter-spacing: 0.02em;
}

.nf-swatch-hex {
    font-size: 11px;
    color: rgba(255,255,255,0.45);
    letter-spacing: 0.08em;
}

/* ── FIGMA LINK ── */
.nf-figma-block { margin-top: 40px; }

.nf-figma-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: rgba(255,255,255,0.65);
    text-decoration: none;
    font-size: 13px;
    letter-spacing: 0.05em;
    border-bottom: 1px solid rgba(255,255,255,0.20);
    padding-bottom: 2px;
    transition: color 0.3s ease, border-color 0.3s ease;
}

.nf-figma-link:hover {
    color: #FFFFFF;
    border-color: rgba(255,255,255,0.6);
}

/* ── RESULTAT ── */
.nf-result-label {
    font-size: 20px !important;
    letter-spacing: 0.05em;
    margin-bottom: 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.nf-result-label .nf-tag-label {
    font-size: 14px !important;
    font-weight: 400;
    letter-spacing: 0.05em;
    text-transform: none;
    color: rgba(255,255,255,0.60);
}

.nf-result-images {
    display: flex;
    justify-content: center;
}

.nf-result-main {
    margin-bottom: 0;
    max-width: 920px;
    width: 100%;
}

.nf-result-main,
.nf-result-main:hover,
.nf-result-main:active {
    transform: none;
    box-shadow: none;
}

.nf-result-main img,
.nf-result-main:hover img {
    transform: none;
}

.nf-result::after {
    display: none;
}

/* ── RESPONSIVE ── */

/* Tablette */
@media (max-width: 1024px) {
    .nf-hero { padding: 64px 24px 0; }
    .nf-hero-image img { width: 80%; }
    .nf-typo-block { min-height: 220px; }
    .nf-typo-regular,
    .nf-typo-bold { font-size: clamp(110px, 16vw, 220px); }
    .nf-typo-display { font-size: clamp(40px, 6vw, 80px); }
}

/* Mobile large */
@media (max-width: 900px) {
    body { font-size: 14px; }
    .nf-role-label,
    .nf-tag-label,
    .nf-typo-tag { font-size: 12px; }
    .nf-result-label .nf-tag-label { font-size: 12px !important; }
    .nf-hero {
        position: relative;
        padding: 24px 20px 0;
        --nf-title-size: clamp(56px, 14vw, 110px);
    }
    .nf-hero-meta {
        position: absolute;
        top: 24px;
        left: 20px;
        margin: 0;
        font-size: 12px;
        max-width: 50%;
    }
    .nf-hero-label {
        position: absolute;
        top: 24px;
        right: 20px;
        margin: 0;
        text-align: right;
        font-size: 14px;
        max-width: 45%;
        bottom: auto;
    }
    .nf-title { margin-top: 96px; }
    .nf-hero-image { margin-top: calc(var(--nf-title-size) * -0.36 - 16px); }
    .nf-hero-image img { width: 100%; max-width: none; }
    .nf-ds-list { max-width: none; }

    /* Hierarchisation: hide Arborescence tag in responsive */
    .nf-block-header .nf-tag-label { display: none; }

    /* Sub-columns alignment: align EXISTANT/CIBLE/BESOINS with section content */
    .nf-sub-columns .column { padding: 0; }
    .nf-sub-columns .column-list,
    .nf-sub-columns .column-title { padding-left: 0; }
    .nf-bullet-list { padding-left: 0; list-style-position: inside; }

    .nf-about {
        grid-template-columns: 1fr;
        gap: 32px;
        padding: 32px 20px 0;
    }

    .nf-description { padding: 32px 20px; font-size: 14px; }
    .nf-role-value { font-size: 14px; }
    .nf-about-list li { font-size: 14px; }
    .project-list li { font-size: 14px; }
    .column-text, .column-list, .column-list li { font-size: 14px; }

    .nf-block { padding: 32px 20px; }

    .nf-sub-columns { padding-top: 32px; }

    .nf-typo-block {
        grid-template-columns: 2fr 1fr 1fr;
        min-height: 0;
        margin-top: 32px;
        margin-bottom: 24px;
    }
    .nf-typo-col-tag { display: none; }

    .nf-typo-col { padding: 16px 0; min-height: 140px; }
    .nf-typo-col-name { padding-top: 0; padding-left: 0; }

    .nf-typo-col-regular,
    .nf-typo-col-bold { padding: 16px 12px; }

    .nf-typo-col + .nf-typo-col::before {
        background: rgba(255,255,255,0.30);
    }
    .nf-typo-col-bold::after {
        content: '';
        position: absolute;
        right: 0; top: 0; bottom: 0;
        width: 1px;
        background: rgba(255,255,255,0.30);
    }

    .nf-typo-regular,
    .nf-typo-bold {
        font-size: clamp(64px, 14vw, 110px);
        margin-left: 0;
        margin-bottom: 0;
        align-self: flex-end;
    }
    .nf-typo-col-bold { transform: translateX(-30%); }

    .nf-swatches { gap: 10px; }
    .nf-swatch-item { flex: 1 1 180px; max-width: none; }
    .nf-swatch-name { font-size: 10px; white-space: nowrap; }
    .nf-typo-col-label { font-size: 12px; }

    .nf-result-main { max-width: 100%; }

    .nf-figma-icon-img { width: 38px; height: 38px; }
    .nf-figma-icon-btn { width: 44px; height: 40px; }
}

/* Mobile */
@media (max-width: 600px) {
    body { padding-top: 16px; }
    .header { font-size: 11px; }
    .header .header-inner {
        flex-direction: row;
        gap: 12px;
        padding: 14px 16px;
        align-items: center;
        justify-content: space-between;
    }
    .header .portfolio-tag { display: none; }
    .footer .header-inner { padding: 14px 16px; gap: 10px; flex-direction: row; justify-content: flex-end; }
    .footer .footer-left { display: none; }

    .nf-hero { padding: 24px 16px 0; }
    .nf-hero-meta { top: 20px; left: 16px; font-size: 11px; }
    .nf-hero-label { top: 20px; right: 16px; padding: 0; font-size: 13px; }
    .nf-title { font-size: clamp(48px, 16vw, 80px); margin-top: 88px; }
    .nf-hero-image img { width: 100%; max-width: none; }

    .nf-about,
    .nf-description,
    .nf-block { padding-left: 16px; padding-right: 16px; }

    .nf-section-title { font-size: 18px; margin-bottom: 16px; }
    .nf-about-list li { font-size: 14px; padding: 10px 0; }

    .columns.nf-columns { padding: 24px 16px; gap: 24px; grid-template-columns: 1fr; }

    .nf-sub-columns { padding-top: 24px; grid-template-columns: 1fr !important; gap: 24px; }
    .nf-sub-columns .column {
        padding: 0 0 16px;
        border-bottom: 1px solid rgba(255,255,255,0.30);
    }
    .nf-sub-columns .column:last-child { border-bottom: none; padding-bottom: 0; }
    .nf-sub-columns .column:not(:last-child)::after { display: none; }

    .nf-typo-block {
        grid-template-columns: 2fr 1fr 1fr;
        min-height: 0;
        margin-top: 24px;
    }
    .nf-typo-col { padding: 12px 0; min-height: 110px; }
    .nf-typo-col-name { padding-left: 0; }
    .nf-typo-col-regular,
    .nf-typo-col-bold { padding: 12px 8px; }
    .nf-typo-display { font-size: 32px; }
    .nf-typo-regular,
    .nf-typo-bold {
        font-size: clamp(48px, 16vw, 90px);
        margin-left: 0;
        margin-bottom: 0;
        align-self: flex-end;
    }
    .nf-typo-col-bold { transform: translateX(-30%); }

    .nf-swatches { gap: 8px; justify-content: flex-start; }
    .nf-swatch-item { flex: 1 1 calc(50% - 8px); padding: 6px 14px 6px 6px; }
    .nf-swatch { width: 28px; height: 28px; }
    .nf-swatch-name { font-size: 9px; white-space: nowrap; }
    .nf-swatch-hex { font-size: 10px; }
    .nf-typo-col-label { font-size: 12px; }

    .nf-figma-icon-img { width: 32px; height: 32px; }
    .nf-figma-icon-btn { width: 38px; height: 36px; }

    .nf-result-label { font-size: 16px !important; flex-wrap: wrap; gap: 8px; }
    .nf-result-label .nf-tag-label { font-size: 12px !important; }

    body:has(.nf-hero) .footer { padding-top: 24px; padding-bottom: 20px; }
}

/* Très petit */
@media (max-width: 380px) {
    .nf-title { font-size: 44px; }
    .nf-hero-image img { max-width: none; width: 100%; }
    .nf-typo-display { font-size: 32px; }
}
