* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    text-decoration: none;
    border: none;
    outline: none;
    font-family: 'Poppins', sans-serif;
}

:root {
    --bg-color: #1f242d;
    --second-bg-color: #323946;
    --text-color: #fff;
    --main-color: #0ef;
}

html, body {
    font-size: 62.5%;
    background: var(--bg-color);
    color: var(--text-color);
    height: 100%;
    overflow: hidden;
}

/* ============ SECTION TRANSITIONS ============ */
.cube-wrapper {
    width: 100%;
    height: 100vh;
    overflow: hidden;
    position: relative;
}

.cube {
    width: 100%;
    height: 100%;
    position: relative;
}

.section {
    position: absolute;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    display: none;
    align-items: center;
    justify-content: space-between;
    padding: 0 9% 8rem;
    background: var(--bg-color);
    overflow-y: auto;
    overflow-x: hidden;
    pointer-events: none;
    opacity: 1;
    visibility: hidden;
    z-index: 1;
}

.section.active {
    display: flex;
    opacity: 1;
    pointer-events: all;
    visibility: visible;
    z-index: 10;
}

/* Effet directionnel : la section sortante glisse vers le haut */
.section.leaving {
    display: none;
    pointer-events: none;
    visibility: hidden;
    z-index: 5;
}


/* ============ TOOLTIPS ============ */
[data-tooltip] {
    position: relative;
}

[data-tooltip]::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: calc(100% + 1rem);
    left: 50%;
    transform: translateX(-50%);
    background: var(--main-color);
    color: var(--second-bg-color);
    font-size: 1.2rem;
    font-weight: 600;
    padding: .4rem 1rem;
    border-radius: 2rem;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity .3s ease, transform .3s ease;
    transform: translateX(-50%) translateY(5px);
}

[data-tooltip]:hover::after {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

/* ============ NAVBAR ============ */
.navbar {
    position: fixed;
    bottom: 2.5rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1000;
    background: var(--second-bg-color);
    padding: 1.2rem 2.5rem;
    border-radius: 5rem;
    box-shadow: 0 0 2rem rgba(0, 0, 0, .3);
}

.nav-links {
    display: flex;
    gap: 3rem;
    align-items: center;
}

.nav-btn {
    font-size: 2.4rem;
    color: var(--text-color);
    transition: color .3s ease;
    display: flex;
    align-items: center;
}

.nav-btn:hover,
.nav-btn.active {
    color: var(--main-color);
}

/* ============ BOUTON ============ */
.btn {
    display: inline-block;
    padding: 1.2rem 2.8rem;
    background: var(--main-color);
    border-radius: 4rem;
    box-shadow: 0 0 1rem var(--main-color);
    font-size: 1.6rem;
    color: var(--second-bg-color);
    letter-spacing: .1rem;
    font-weight: 600;
    cursor: pointer;
    transition: .5s ease;
}

.btn:hover {
    box-shadow: none;
}

/* ============ CERCLE PHOTO (partagé) ============ */
.img-box {
    position: relative;
    width: 32rem;
    height: 32rem;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    background: var(--bg-color);
    box-shadow:
        0 0 0 .5rem var(--bg-color),
        0 0 0 1rem var(--main-color),
        0 0 3rem var(--main-color),
        0 0 6rem rgba(0, 238, 255, .3);
    transition: box-shadow .5s ease, transform .5s ease;
    cursor: pointer;
    overflow: hidden;
}

.img-box:hover {
    transform: scale(1.05);
    box-shadow:
        0 0 0 .5rem var(--bg-color),
        0 0 0 1rem var(--main-color),
        0 0 5rem var(--main-color),
        0 0 10rem rgba(0, 238, 255, .5);
}

.img-box img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top;
    border-radius: 50%;
    -webkit-mask-image: radial-gradient(circle, white 65%, transparent 90%);
    mask-image: radial-gradient(circle, white 65%, transparent 90%);
    filter: brightness(1.05) contrast(1.02);
}

/* ============ HOME ============ */
.home-content {
    max-width: 55rem;
}

.home-content h3 {
    font-size: 3rem;
    font-weight: 600;
}

.home-content h1 {
    font-size: 5.6rem;
    font-weight: 800;
    color: var(--main-color);
    line-height: 1.2;
    margin: .5rem 0;
}

.home-content .subtitle {
    font-size: 2.6rem;
    font-weight: 700;
    margin-bottom: 2rem;
}

.home-content p {
    font-size: 1.6rem;
    line-height: 1.8;
    margin-bottom: 3rem;
}

.home-sci {
    display: flex;
    align-items: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.sci {
    display: flex;
    gap: 1.2rem;
}

.sci a {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 4rem;
    height: 4rem;
    border: .2rem solid var(--main-color);
    border-radius: 50%;
    font-size: 2rem;
    color: var(--main-color);
    transition: .5s ease;
}

.sci a:hover {
    background: var(--main-color);
    color: var(--second-bg-color);
    box-shadow: 0 0 1rem var(--main-color);
}

/* ============ ABOUT ============ */
.about-content {
    max-width: 55rem;
}

.about-content .heading {
    font-size: 4.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    text-align: left;
}

.about-content .heading span {
    color: var(--main-color);
}

.about-content h3 {
    font-size: 2.6rem;
    font-weight: 700;
    color: var(--main-color);
    margin-bottom: 2rem;
}

.about-content p {
    font-size: 1.6rem;
    line-height: 1.8;
    margin-bottom: 3rem;
}
/* ============ RESUME ============ */
.resume-section {
    flex-direction: column;
    justify-content: flex-start;
    align-items: stretch;
    padding: 2.5rem 5% 9rem;
    overflow-y: auto;
}

.resume-container {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    height: 100%;
}

.modern-resume {
    max-width: 110rem;
    margin: 0 auto;
    overflow-y: auto;
    padding: 1rem 2rem 5rem;
}

.resume-header {
    max-width: 68rem;
    margin: 0 auto 2.5rem;
    text-align: center;
}

.resume-header p {
    color: #aaa;
    font-size: 1.35rem;
    line-height: 1.7;
}

.resume-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 5rem;
}

.resume-column {
    min-width: 0;
}

.resume-block {
    margin-bottom: 2.8rem;
}

.resume-section-title {
    color: var(--text-color);
    font-size: 2rem;
    margin-bottom: 1.8rem;
    padding-bottom: .8rem;
    border-bottom: .15rem solid var(--main-color);
    width: fit-content;
}

.timeline-item {
    position: relative;
    padding: 0 0 2rem 1.8rem;
    border-left: .15rem solid #3f4a55;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: -.55rem;
    top: .35rem;
    width: .8rem;
    height: .8rem;
    background: var(--bg-color);
    border: .15rem solid var(--main-color);
    border-radius: 50%;
}

.timeline-item:last-child {
    padding-bottom: 0;
}

.timeline-item .year {
    color: var(--main-color);
    font-size: 1.25rem;
    font-weight: 600;
}

.timeline-item h4 {
    font-size: 1.6rem;
    margin: .4rem 0;
}

.timeline-item p,
.resume-list {
    color: #aaa;
    font-size: 1.25rem;
    line-height: 1.65;
}

.timeline-item .company {
    color: #d2d2d2;
    margin-bottom: .35rem;
}

.resume-list {
    padding-left: 1.8rem;
}

.resume-list li {
    margin-bottom: .5rem;
}

.skill-level {
    margin-bottom: 1.35rem;
}

.skill-level > div {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    color: #d2d2d2;
    font-size: 1.2rem;
    margin-bottom: .5rem;
}

.skill-level b {
    color: var(--main-color);
    font-size: 1.1rem;
    white-space: nowrap;
}

.skill-track {
    display: block;
    height: .55rem;
    background: #26313a;
    border-radius: 1rem;
    overflow: hidden;
}

.skill-track > span {
    display: block;
    height: 100%;
    background: var(--main-color);
    border-radius: inherit;
    box-shadow: 0 0 .7rem rgba(0, 238, 255, .45);
}

.cert-links {
    display: flex;
    flex-direction: column;
    gap: .8rem;
}

.cert-links a {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    padding: 1rem 1.2rem;
    border-radius: .7rem;
    background: var(--second-bg-color);
    color: #d2d2d2;
    font-size: 1.25rem;
    transition: color .3s ease, transform .3s ease;
}

.cert-links a:hover {
    color: var(--main-color);
    transform: translateX(.4rem);
}

.cert-links i {
    color: var(--main-color);
}

.resume-title {
    font-size: 4rem;
    font-weight: 700;
    text-align: center;
    color: var(--text-color);
}

.resume-tabs {
    display: flex;
    justify-content: space-between;
    border-bottom: .2rem solid #444;
    padding: 0;
}

.tab-btn {
    background: none;
    font-size: 1.8rem;
    font-weight: 600;
    color: #666;
    padding: .8rem 0 1.2rem;
    cursor: pointer;
    border: none;
    border-bottom: .3rem solid transparent;
    margin-bottom: -.2rem;
    transition: color .3s ease, border-color .3s ease;
    font-family: 'Poppins', sans-serif;
    flex: 1;
    text-align: left;
}

.tab-btn:nth-child(2) { text-align: center; }
.tab-btn:nth-child(3) { text-align: right; }

.tab-btn:hover { color: var(--text-color); }

.tab-btn.active {
    color: var(--main-color);
    border-bottom-color: var(--main-color);
}

.tab-content { display: none; }
.tab-content.active { display: block; }

.resume-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}

.resume-card {
    background: var(--second-bg-color);
    border-radius: 1.2rem;
    padding: 2rem 2.2rem;
    display: flex;
    flex-direction: column;
    gap: .8rem;
    transition: transform .3s ease, box-shadow .3s ease;
    border: .15rem solid transparent;
}

.resume-card:hover {
    transform: translateY(-4px);
    border-color: var(--main-color);
    box-shadow: 0 0 1.5rem rgba(0, 238, 255, .15);
}

.resume-card .year {
    font-size: 1.4rem;
    color: var(--main-color);
    font-weight: 500;
}

.resume-card h3 {
    font-size: 1.9rem;
    font-weight: 700;
    color: var(--text-color);
}

.resume-card .company {
    display: flex;
    align-items: center;
    gap: .8rem;
    font-size: 1.5rem;
    color: #aaa;
}

.resume-card .dot {
    width: 1rem;
    height: 1rem;
    background: var(--main-color);
    border-radius: 50%;
    flex-shrink: 0;
}

.resume-card p:last-child {
    font-size: 1.4rem;
    color: #999;
    line-height: 1.6;
}

/* ============ SERVICES ============ */
.services-intro {
    max-width: 62rem;
    margin: 0 auto 2.5rem;
    text-align: center;
}

.services-intro p {
    color: #aaa;
    font-size: 1.45rem;
    line-height: 1.7;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    max-width: 110rem;
    margin: 0 auto;
}

.service-card {
    position: relative;
    background: var(--second-bg-color);
    border: .15rem solid transparent;
    border-radius: 1.4rem;
    padding: 2.5rem 2.2rem 2.2rem;
    overflow: hidden;
    transition: transform .3s ease, border-color .3s ease, box-shadow .3s ease;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: .3rem;
    background: var(--main-color);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform .3s ease;
}

.service-card:hover {
    transform: translateY(-.5rem);
    border-color: var(--main-color);
    box-shadow: 0 0 2rem rgba(0, 238, 255, .12);
}

.service-card:hover::before {
    transform: scaleX(1);
}

.service-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 4.8rem;
    height: 4.8rem;
    border-radius: 1rem;
    background: rgba(0, 238, 255, .1);
    color: var(--main-color);
    font-size: 2.7rem;
    margin-bottom: 1.5rem;
}

.service-number {
    position: absolute;
    top: 2.7rem;
    right: 2.2rem;
    color: #68737c;
    font-size: 1.4rem;
    font-weight: 700;
}

.service-card h3 {
    font-size: 2rem;
    line-height: 1.3;
    margin-bottom: 1rem;
}

.service-card > p {
    color: #aaa;
    font-size: 1.35rem;
    line-height: 1.7;
    margin-bottom: 1.5rem;
}

.service-card ul {
    padding-left: 1.8rem;
    color: #d2d2d2;
    font-size: 1.25rem;
    line-height: 1.7;
    min-height: 8.5rem;
}

.service-card li::marker {
    color: var(--main-color);
}

.service-tags {
    display: flex;
    flex-wrap: wrap;
    gap: .6rem;
    margin-top: 1.8rem;
}

.service-tags span {
    padding: .35rem .8rem;
    border: .1rem solid #53606a;
    border-radius: 2rem;
    color: #bfc8ce;
    font-size: 1.1rem;
}

.services-cta {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1.5rem;
    margin: 3rem auto 1rem;
    color: #aaa;
    font-size: 1.4rem;
}

.services-cta .btn {
    display: inline-flex;
    align-items: center;
    gap: .7rem;
    padding: 1rem 1.8rem;
    font-size: 1.35rem;
}

/* ============ SKILLS GRID ============ */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
    margin-top: 1.5rem;
    max-width: 96rem;
    margin-left: auto;
    margin-right: auto;
}

.skill-card {
    background: var(--second-bg-color);
    border-radius: 1rem;
    padding: 2rem 1rem 1.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    border: .15rem solid transparent;
    transition: transform .3s ease, border-color .3s ease, box-shadow .3s ease;
    cursor: default;
    aspect-ratio: 1;
}

.skill-card:hover {
    transform: translateY(-5px);
    border-color: var(--main-color);
    box-shadow: 0 0 1.5rem rgba(0, 238, 255, .15);
}

.skill-card img {
    width: 6.5rem;
    height: 6.5rem;
    object-fit: contain;
}

.skill-card:hover img {
    transform: scale(1.1);
    transition: transform .3s ease;
}

.skill-card span {
    font-size: 1.3rem;
    color: var(--text-color);
    font-weight: 500;
    text-align: center;
}

/* ============ CERTIFICATIONS ============ */
.cert-title {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-color);
    margin-top: 2rem;
    margin-bottom: .5rem;
    padding-bottom: .8rem;
    border-bottom: .15rem solid var(--second-bg-color);
}

.cert-card .year {
    display: flex;
    align-items: center;
    gap: .6rem;
    color: #0077b5;
    font-size: 1.4rem;
}

.cert-card .year i {
    font-size: 2rem;
    color: #0077b5;
}

/* ============ CERTIFICAT EXTERNAL LINK ============ */
.cert-card {
    position: relative;
}

.cert-link {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
    font-size: 2rem;
    color: #666;
    transition: color .3s ease, text-shadow .3s ease, transform .3s ease;
    z-index: 10;
}

.cert-card:hover .cert-link {
    color: var(--text-color);
}

.cert-link:hover {
    color: var(--main-color) !important;
    text-shadow: 0 0 1rem var(--main-color);
    transform: scale(1.2);
}

/* ============ PORTFOLIO ============ */
.portfolio-section {
    display: block !important;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    padding: 3rem 7% 9rem;
    overflow-y: auto;
}

.portfolio-section > .resume-container {
    height: auto;
    min-height: 100%;
    margin: 0 auto;
}

.portfolio-section .heading {
    margin-bottom: 3rem;
    font-size: 4rem;
    font-weight: 700;
}

.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    align-items: center;
    gap: 2.5rem;
    max-width: 1200px;
    width: 100%;
    margin-top: 2rem;
}

.portfolio-box {
    position: relative;
    border-radius: 2rem;
    box-shadow: 0 0 1rem var(--bg-color);
    overflow: hidden;
    display: flex;
    aspect-ratio: 4/3;
}

.portfolio-img {
    width: 100%;
    height: 100%;
    background: var(--second-bg-color);
}

.portfolio-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: .5s ease;
}

.portfolio-box:hover .portfolio-img img {
    transform: scale(1.1);
}

.portfolio-layer {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(rgba(0, 0, 0, .1), var(--main-color));
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    text-align: center;
    padding: 0 4rem;
    transform: translateY(100%);
    transition: .5s ease;
}

.portfolio-box:hover .portfolio-layer {
    transform: translateY(0);
}

.portfolio-layer h4 {
    font-size: 2.4rem;
    font-weight: 700;
    color: var(--text-color);
}

.portfolio-layer p {
    font-size: 1.4rem;
    margin: .5rem 0 1.5rem;
    color: var(--text-color);
    line-height: 1.6;
}

.portfolio-layer a {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 4.5rem;
    height: 4.5rem;
    background: var(--text-color);
    border-radius: 50%;
}

.portfolio-layer a i {
    font-size: 2rem;
    color: var(--second-bg-color);
}

@media (hover: none) {
    .portfolio-layer {
        transform: translateY(0);
        height: auto;
        min-height: 45%;
        justify-content: flex-end;
        padding: 1.5rem;
        background: linear-gradient(transparent, rgba(0, 0, 0, .9) 35%);
    }

    .portfolio-layer p {
        display: none;
    }
}

/* ============ PROCESSUS ============ */
.process-section {
    max-width: 110rem;
    width: 100%;
    margin: 4rem auto 1rem;
    padding-top: 3rem;
    border-top: .1rem solid rgba(255, 255, 255, .1);
}

.process-section > h3 {
    text-align: center;
    font-size: 2.4rem;
    margin-bottom: 2rem;
}

.process-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
}

.process-grid article {
    position: relative;
    padding: 2rem 1.5rem;
    background: var(--second-bg-color);
    border-radius: 1rem;
    text-align: center;
}

.process-grid article > span {
    position: absolute;
    top: 1rem;
    right: 1.2rem;
    color: var(--main-color);
    font-size: 1.2rem;
    font-weight: 700;
}

.process-grid i {
    display: block;
    color: var(--main-color);
    font-size: 2.8rem;
    margin-bottom: 1rem;
}

.process-grid h4 {
    font-size: 1.6rem;
    margin-bottom: .6rem;
}

.process-grid p {
    color: #aaa;
    font-size: 1.2rem;
    line-height: 1.6;
}

/* ============ CONTACT ============ */
.contact-section {
    display: block !important;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 5rem 5% 10rem;
    overflow-y: auto;
}

.contact-container {
    width: 100%;
    max-width: 110rem;
    margin: 0 auto;
    transform: none;
}
.contact-header { text-align: center; margin-bottom: 3.5rem; }
.contact-header .heading {
    margin-bottom: 1rem;
    font-size: 4.5rem;
    font-weight: 700;
}

.contact-header .heading span {
    color: var(--main-color);
}

.contact-header > p, .contact-intro {
    color: #aaa;
    font-size: 1.5rem;
}

.contact-layout {
    display: grid;
    grid-template-columns: minmax(26rem, .85fr) minmax(0, 1.4fr);
    gap: 3rem;
}

.contact-card {
    background: rgba(50, 57, 70, .72);
    border-radius: 1.4rem;
    padding: 3rem;
    border: .15rem solid rgba(255, 255, 255, .04);
}

.contact-card h3 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.contact-intro {
    line-height: 1.7;
    margin-bottom: 2.8rem;
}

.contact-detail {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    margin: 2rem 0;
}

.contact-detail > i {
    color: var(--main-color);
    font-size: 2.5rem;
    width: 3rem;
    text-align: center;
}

.contact-detail div { display: flex; flex-direction: column; gap: .35rem; }
.contact-detail strong { font-size: 1.5rem; }
.contact-detail span, .contact-detail a { color: #aaa; font-size: 1.25rem; }
.contact-detail a:hover { color: var(--main-color); }

.contact-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-top: 3rem;
}

.contact-action {
    display: inline-flex;
    align-items: center;
    gap: .7rem;
    padding: 1.1rem 1.7rem;
    border-radius: 3rem;
    color: #fff;
    font-size: 1.25rem;
    font-weight: 600;
    transition: transform .3s ease, box-shadow .3s ease;
}

.contact-action:hover { transform: translateY(-.2rem); }
.email-action { background: #0799ed; }
.whatsapp-action { background: #16b873; }

.contact-form { width: 100%; }

.contact-form .input-box {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1.5rem;
}

.contact-form label {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.contact-form .input-box input,
.contact-form textarea {
    width: calc(50% - .75rem);
    padding: 1.5rem;
    font-size: 1.6rem;
    color: var(--text-color);
    background: rgba(31, 36, 45, .7);
    border: .1rem solid #47515d;
    border-radius: .8rem;
    margin: 0;
    box-shadow: none;
}

.contact-form textarea {
    resize: vertical;
    width: 100%;
    margin-top: 1.5rem;
    min-height: 14rem;
}

.contact-form input:focus,
.contact-form textarea:focus {
    border-color: var(--main-color);
    box-shadow: 0 0 0 .2rem rgba(0, 238, 255, .12);
}

.contact-form-actions {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    margin-top: 2rem;
}

.contact-form .btn {
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 1rem;
    transition: .5s ease, opacity .3s ease;
}

.contact-form .btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    box-shadow: none;
}

.btn-secondary {
    background: #f4f4f4;
    color: #1f242d;
    box-shadow: none;
}

.form-status {
    font-size: 1.5rem;
    font-weight: 500;
    padding: 1rem 1.5rem;
    border-radius: .8rem;
    margin-top: 1rem;
    display: none;
    text-align: center;
    animation: fadeInUp .4s ease;
}

.form-status.success {
    display: block;
    background: rgba(0, 238, 100, .1);
    border: .15rem solid rgba(0, 238, 100, .4);
    color: #00ee64;
}

.form-status.error {
    display: block;
    background: rgba(255, 60, 60, .1);
    border: .15rem solid rgba(255, 60, 60, .4);
    color: #ff3c3c;
}

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

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        scroll-behavior: auto !important;
        transition-duration: .01ms !important;
        animation-duration: .01ms !important;
        animation-iteration-count: 1 !important;
    }
}

/* ============ RESPONSIVE — TABLETTE (≤ 900px) ============ */
@media (max-width: 900px) {

    html, body { font-size: 55%; }

    .section {
        padding: 0 5% 10rem;
    }

    /* Home & About : empiler verticalement */
    #home, #about {
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 3rem;
        padding-top: 4rem;
    }

    #about { flex-direction: column-reverse; }

    .img-box {
        width: 22rem;
        height: 22rem;
    }

    .home-content, .about-content {
        max-width: 100%;
        text-align: center;
    }

    .home-sci {
        justify-content: center;
    }

    /* Resume & Portfolio : grilles 2 colonnes */
    .resume-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .resume-layout {
        gap: 2.5rem;
    }

    .skills-grid {
        grid-template-columns: repeat(4, 1fr);
    }

    .portfolio-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .services-grid {
        grid-template-columns: 1fr;
    }

    .process-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    /* Navbar */
    .nav-links { gap: 2rem; }
}

/* ============ RESPONSIVE — MOBILE (≤ 600px) ============ */
@media (max-width: 600px) {

    html, body { font-size: 50%; }

    .section {
        padding: 2rem 4% 10rem;
    }

    /* Home */
    .home-content h1 { font-size: 4.2rem; }
    .home-content h3 { font-size: 2.4rem; }
    .home-content .subtitle { font-size: 2rem; }

    .img-box {
        width: 18rem;
        height: 18rem;
    }

    /* Grilles → 1 colonne */
    .resume-grid {
        grid-template-columns: 1fr;
    }

    .skills-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .portfolio-grid {
        grid-template-columns: 1fr;
    }

    .services-cta {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }

    .process-grid {
        grid-template-columns: 1fr;
    }

    .contact-layout {
        grid-template-columns: 1fr;
    }

    .contact-card {
        padding: 2.2rem;
    }

    .contact-form .input-box {
        flex-direction: column;
        gap: 1.5rem;
    }

    .contact-form .input-box input {
        width: 100%;
    }

    /* Resume section padding */
    .resume-section {
        padding: 2rem 4% 10rem;
    }

    .modern-resume {
        padding: 1rem 0 5rem;
    }

    .resume-layout {
        grid-template-columns: 1fr;
        gap: 0;
    }

    .resume-header {
        margin-bottom: 2rem;
    }

    .resume-title {
        font-size: 3.2rem;
    }

    .portfolio-section {
        padding: 2rem 4% 10rem;
    }

    /* Onglets : taille réduite */
    .tab-btn {
        font-size: 1.5rem;
    }

    /* Contact : inputs en colonne */
    .contact-form .input-box {
        flex-direction: column;
    }

    .contact-form .input-box input {
        width: 100%;
    }

    /* Navbar */
    .navbar {
        padding: 1rem 1.8rem;
        bottom: 1.5rem;
    }

    .nav-links { gap: 1.5rem; }

    .nav-btn { font-size: 2rem; }
}

/* ── Language Selector ─────────────────────────────────────────── */
.lang-selector {
  position: fixed;
  top: 1rem;
  right: 1.2rem;
  z-index: 9999;
  display: flex;
  gap: 0.3rem;
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 50px;
  padding: 0.3rem 0.5rem;
  box-shadow: 0 4px 20px rgba(0,0,0,0.2);
}

.lang-btn {
  background: none;
  border: none;
  cursor: pointer;
  font-family: 'Poppins', sans-serif;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-color, #ccc);
  padding: 0.25rem 0.6rem;
  border-radius: 20px;
  transition: all 0.25s ease;
  opacity: 0.55;
  letter-spacing: 0.05em;
}

.lang-btn:hover { opacity: 1; transform: scale(1.05); }

.lang-btn.active {
  background: var(--primary-color, #6c63ff);
  color: #fff;
  opacity: 1;
  box-shadow: 0 2px 10px rgba(108, 99, 255, 0.4);
}
