/* =========================================================
   BackMobile — Pages statiques premium
   (mentions légales, CGU, confidentialité, recrutement, fibre)
   S'appuie sur les variables de app.css (chargé avant ce fichier).
   ========================================================= */

/* ============================ HERO GÉNÉRIQUE ============================ */
.page-hero {
    position: relative;
    isolation: isolate;
    color: var(--text-inv);
    padding: clamp(96px, 14vw, 168px) 0 clamp(64px, 9vw, 104px);
    background: radial-gradient(120% 140% at 80% 0%, #16451f 0%, #0c2c12 45%, #070707 100%);
    overflow: hidden;
}
.page-hero--recrut {
    background: radial-gradient(120% 140% at 85% -10%, #1f7f2d 0%, #0e3d18 42%, #070707 100%);
}
.page-hero--fibre {
    background: radial-gradient(120% 140% at 15% -10%, #0e4d18 0%, #0a2e3a 45%, #070707 100%);
}
.page-hero-overlay {
    position: absolute;
    inset: 0;
    z-index: -1;
    background:
        radial-gradient(40% 60% at 90% 100%, rgba(182, 214, 61, 0.16), transparent 70%),
        url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='40' height='40'%3E%3Cpath d='M0 39.5H40M39.5 0V40' stroke='%23ffffff' stroke-opacity='0.04'/%3E%3C/svg%3E");
}
.page-hero-inner { max-width: 820px; }
.page-hero .kicker { margin-bottom: 18px; }
.page-hero h1 { margin-bottom: 22px; }
.page-hero-sub {
    font-size: clamp(16px, 2vw, 20px);
    line-height: 1.6;
    color: var(--text-inv-muted);
    max-width: 640px;
    margin-bottom: 32px;
}
.page-hero-cta { display: flex; flex-wrap: wrap; gap: 14px; }

/* ============================ SECTIONS GÉNÉRIQUES ============================ */
.feature-section { padding: var(--section-pad) 0; }
.feature-section .section-head { margin-bottom: clamp(36px, 5vw, 56px); }

/* ============================ PERKS / AVANTAGES ============================ */
.perks-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 22px;
}
.perk-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 30px 28px;
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}
.perk-card::before {
    content: "";
    display: block;
    width: 38px;
    height: 4px;
    border-radius: 4px;
    background: var(--lime);
    margin-bottom: 18px;
}
.perk-card h3 { font-size: 19px; margin-bottom: 10px; }
.perk-card p { color: var(--text-muted); font-size: 15px; line-height: 1.6; }
.perk-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 18px 40px rgba(14, 77, 24, 0.12);
    border-color: var(--lime-soft);
}

/* ============================ MÉTIERS ============================ */
.jobs-section { padding: var(--section-pad) 0; }
.jobs-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}
.job-card {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius);
    padding: 28px 26px;
    color: var(--text-inv);
    transition: transform 0.25s ease, background 0.25s ease, border-color 0.25s ease;
}
.job-card:hover {
    transform: translateY(-4px);
    background: rgba(255, 255, 255, 0.07);
    border-color: rgba(182, 214, 61, 0.5);
}
.job-tag {
    display: inline-block;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--black);
    background: var(--lime);
    padding: 4px 10px;
    border-radius: 999px;
    margin-bottom: 14px;
}
.job-card h3 { font-size: 18px; margin-bottom: 10px; line-height: 1.2; }
.job-card p { color: var(--text-inv-muted); font-size: 14.5px; line-height: 1.6; }
.jobs-note {
    margin-top: 34px;
    text-align: center;
    color: var(--text-inv-muted);
    font-size: 15px;
}

/* ============================ PROCESSUS ============================ */
.steps-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}
.step-card {
    padding: 26px 24px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--white);
    position: relative;
}
.step-num {
    font-family: var(--font-display);
    font-size: 30px;
    font-weight: 800;
    color: var(--green);
    line-height: 1;
    margin-bottom: 14px;
}
.step-card h3 { font-size: 17px; margin-bottom: 8px; }
.step-card p { color: var(--text-muted); font-size: 14.5px; line-height: 1.55; }

/* ============================ COMPARATIF FIBRE ============================ */
.compare-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
}
.compare-card {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: var(--radius-lg);
    padding: 36px 32px;
    color: var(--text-inv);
}
.compare-card--accent {
    background: linear-gradient(160deg, rgba(31, 127, 45, 0.5), rgba(14, 77, 24, 0.25));
    border-color: rgba(182, 214, 61, 0.55);
}
.compare-card h3 {
    font-size: 24px;
    margin-bottom: 6px;
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 10px;
}
.compare-card h3 span {
    font-family: var(--font-sans);
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--lime);
}
.compare-card > p { color: var(--text-inv-muted); margin-bottom: 20px; line-height: 1.6; }
.check-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; }
.check-list li {
    position: relative;
    padding-left: 30px;
    font-size: 15px;
    color: var(--text-inv);
}
.check-list li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 3px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--lime);
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='black' d='M9 16.2 4.8 12l-1.4 1.4L9 19 21 7l-1.4-1.4z'/%3E%3C/svg%3E") center / 14px no-repeat;
    mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='black' d='M9 16.2 4.8 12l-1.4 1.4L9 19 21 7l-1.4-1.4z'/%3E%3C/svg%3E") center / 14px no-repeat;
}

/* ============================ CAS D'USAGE ============================ */
.usecase-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}
.usecase-item {
    border-left: 3px solid var(--lime);
    padding: 6px 0 6px 18px;
}
.usecase-item strong { display: block; font-size: 17px; margin-bottom: 6px; color: var(--text); }
.usecase-item span { color: var(--text-muted); font-size: 14.5px; line-height: 1.55; }

.cta-mail { color: var(--lime); font-weight: 700; text-decoration: underline; }

/* ============================ PAGES LÉGALES ============================ */
.legal-hero {
    color: var(--text-inv);
    padding: clamp(88px, 12vw, 140px) 0 clamp(48px, 7vw, 80px);
    background: radial-gradient(120% 140% at 80% 0%, #16451f 0%, #0c2c12 50%, #070707 100%);
}
.legal-hero h1 { margin-bottom: 16px; }
.legal-hero-sub { color: var(--text-inv-muted); max-width: 640px; font-size: 16px; line-height: 1.6; }

.legal-section { padding: clamp(48px, 7vw, 90px) 0 var(--section-pad); }
.legal-content { max-width: 820px; }
.legal-updated { color: var(--text-dim); font-size: 14px; margin-bottom: 38px; }
.legal-content article { margin-bottom: 36px; }
.legal-content h2 {
    font-size: clamp(20px, 2.4vw, 24px);
    margin-bottom: 14px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--border);
}
.legal-content p { color: var(--text-muted); line-height: 1.7; margin-bottom: 12px; }
.legal-content ul { color: var(--text-muted); line-height: 1.7; padding-left: 20px; margin: 0 0 12px; }
.legal-content li { margin-bottom: 6px; }
.legal-content a { color: var(--green); text-decoration: underline; }
.legal-content a:hover { color: var(--green-strong); }

.legal-info { list-style: none; padding: 0; margin: 0; display: grid; gap: 0; }
.legal-info li {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 16px;
    padding: 12px 0;
    border-bottom: 1px solid var(--border);
}
.legal-info li span { flex: 0 0 220px; color: var(--text-dim); font-size: 14px; }
.legal-info li strong { color: var(--text); font-weight: 600; }
.legal-info li a { color: var(--green); }

.todo {
    background: #fff3cd;
    color: #7a5b00;
    padding: 1px 7px;
    border-radius: 5px;
    font-style: italic;
    font-size: 0.95em;
    white-space: nowrap;
}
.legal-back { margin-top: 44px; }

/* ============================ RESPONSIVE ============================ */
@media (max-width: 980px) {
    .perks-grid,
    .jobs-grid { grid-template-columns: repeat(2, 1fr); }
    .steps-grid { grid-template-columns: repeat(2, 1fr); }
    .compare-grid { grid-template-columns: 1fr; }
    .usecase-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 760px) {
    .page-hero-cta { flex-direction: column; }
    .page-hero-cta .btn { width: 100%; text-align: center; }
    .perks-grid,
    .jobs-grid,
    .steps-grid,
    .usecase-grid { grid-template-columns: 1fr; }
    .compare-card { padding: 28px 24px; }
    .legal-info li span { flex-basis: 100%; }
}

@media (max-width: 480px) {
    .perk-card,
    .job-card { padding: 24px 22px; }
    .todo { white-space: normal; }
}

/* ============================ HERO BACKGROUND PHOTO (ken-burns) ============================ */
.page-hero-bg {
    position: absolute;
    inset: 0;
    z-index: -2;
    overflow: hidden;
}
.page-hero-bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.42;
    animation: kenburns 20s ease-out forwards;
}
.page-hero-bg::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(7,7,7,0.45) 0%, rgba(7,7,7,0.78) 100%);
}
@keyframes kenburns {
    from { transform: scale(1.14); }
    to { transform: scale(1); }
}

/* ============================ FIBRE — SPLIT INTRO ============================ */
.fibre-split {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: clamp(32px, 5vw, 64px);
    align-items: center;
}
.fibre-split-text .btn { margin-top: 26px; }
.fibre-split-media img {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    border-radius: var(--radius-lg);
    box-shadow: 0 28px 56px rgba(14, 77, 24, 0.16);
}

/* ============================ FIBRE — BANDE DATACENTER ============================ */
.fibre-band {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    color: var(--text-inv);
    padding: clamp(80px, 10vw, 150px) 0;
}
.fibre-band-bg { position: absolute; inset: 0; z-index: -2; }
.fibre-band-bg img { width: 100%; height: 100%; object-fit: cover; }
.fibre-band-bg::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(110deg, rgba(7,7,7,0.92) 0%, rgba(12,44,18,0.78) 55%, rgba(31,127,45,0.45) 100%);
}
.fibre-band-inner { max-width: 760px; }
.fibre-band-inner .kicker { margin-bottom: 16px; }
.fibre-band-inner h2 { margin-bottom: 18px; }

/* ============================ FLUID STAGGERED REVEALS ============================ */
.perks-grid .perk-card,
.usecase-grid .usecase-item,
.compare-grid .compare-card,
.steps-grid .step-card,
.jobs-grid .job-card {
    opacity: 0;
    transform: translateY(22px);
    transition: opacity .6s ease, transform .6s cubic-bezier(.2,.8,.2,1),
                box-shadow .25s ease, border-color .25s ease, background .25s ease;
}
section.is-visible .perk-card,
section.is-visible .usecase-item,
section.is-visible .compare-card,
section.is-visible .step-card,
section.is-visible .job-card { opacity: 1; transform: none; }
section.is-visible .perk-card:nth-child(2),
section.is-visible .job-card:nth-child(2),
section.is-visible .step-card:nth-child(2),
section.is-visible .usecase-item:nth-child(2),
section.is-visible .compare-card:nth-child(2) { transition-delay: .08s; }
section.is-visible .perk-card:nth-child(3),
section.is-visible .job-card:nth-child(3),
section.is-visible .step-card:nth-child(3),
section.is-visible .usecase-item:nth-child(3) { transition-delay: .16s; }
section.is-visible .perk-card:nth-child(4),
section.is-visible .job-card:nth-child(4),
section.is-visible .step-card:nth-child(4),
section.is-visible .usecase-item:nth-child(4) { transition-delay: .24s; }
section.is-visible .perk-card:nth-child(5),
section.is-visible .job-card:nth-child(5) { transition-delay: .32s; }
section.is-visible .perk-card:nth-child(6),
section.is-visible .job-card:nth-child(6) { transition-delay: .40s; }

@media (max-width: 980px) {
    .fibre-split { grid-template-columns: 1fr; }
    .fibre-split-media { order: -1; }
}
@media (prefers-reduced-motion: reduce) {
    .page-hero-bg img { animation: none; }
    .perks-grid .perk-card,
    .usecase-grid .usecase-item,
    .compare-grid .compare-card,
    .steps-grid .step-card,
    .jobs-grid .job-card { opacity: 1 !important; transform: none !important; transition: none !important; }
}
