/* --------------------------------------- */
/* ----- Basic Setup ----- */
/* --------------------------------------- */

@font-face {
    font-family: 'Hk Grotesk';
    font-style: normal;
    font-weight: 400;
    src: url('./fonts/HKGrotesk-Regular.woff') format('woff');
}

@font-face {
    font-family: 'Jost';
    font-style: normal;
    font-weight: 400;
    src: url('./fonts/Jost-Regular.ttf') format('woff');
}

* {
    margin: 0;
    padding: 0;
    box-sizing: inherit;
}

:root {
    --font-size-small: clamp(1.6rem, 1.1vw + 1.2rem, 1.8rem);
    --font-size-normal: clamp(1.9rem, 1.2vw + 1.3rem, 2.2rem);
    --font-size-medium: clamp(2.2rem, 1.6vw + 1.4rem, 2.8rem);
    --font-size-medium-1: clamp(2.8rem, 2.6vw + 1.6rem, 3.6rem);
    --font-size-large: clamp(3.6rem, 4.0vw + 2.0rem, 5.5rem);
    --font-size-huge: clamp(4.2rem, 6.0vw + 2.2rem, 7.5rem);
    --font-stack: 'Hk Grotesk', sans-serif;

    --line-height-normal: 1.7;
    --line-height-small: 1.2;

    --black: #000;
    --pink: #d72638;
    --white: #f0e9f2;
    --white-1: #e5e5e6da;


    --container-max-width: min(1180px, 92vw);
    --container-normal-width: min(800px, 92vw);
    --container-medium-width: min(700px, 92vw);
    --container-small-width: min(500px, 92vw);

    --gutter-huge: clamp(6rem, 8vw, 12rem);
    --gutter-medium: clamp(3rem, 4vw, 6rem);
    --gutter-normal: clamp(1.6rem, 2.2vw, 3rem);
    --gutter-small-1: clamp(1.2rem, 1.6vw, 2.5rem);
    --gutter-small: clamp(1rem, 1.4vw, 2rem);

    --border-light: 1px solid rgb(36, 35, 35);

    --skills-bg: #070707;
    --skills-card-bg: #1a1a1a;
    --skills-primary: #d72638;
    --skills-secondary: #b2b2b2;
    --skills-text-color: #f2f2f2;
}

html {
    font-size: 62.5%;
    /* (16/10)*100 = 62.5% => 1rem = 10px */
    box-sizing: border-box;
    scroll-behavior: smooth;
}

@media(max-width: 1000px) {
    html {
        font-size: 52%;
    }
}

body {
    font-size: var(--font-size-small);
    font-family: var(--font-stack);
    font-weight: 400;
    color: var(--white-1);
    line-height: var(--line-height-normal);
    background: var(--black);
    overflow-x: hidden;
}

.row {
    max-width: var(--container-max-width);
    margin: 0 auto;
}

@media(max-width: 1340px) {
    .row {
        max-width: 1100px;
    }
}

@media(max-width: 1240px) {
    .row {
        padding: 0 var(--gutter-medium);
    }
}

@media (max-width: 600px) {
    .row {
        padding: 0 var(--gutter-small);
    }
}

section {
    padding: var(--gutter-huge) 0;
    border-bottom: var(--border-light);
}

img {
    object-fit: contain;
    max-width: 100%;
}

/* --------------------------------------- */
/* ----- Headlines and Paragraphs ----- */
/* --------------------------------------- */

h1,
h2,
h3 {
    font-family: 'Jost', sans-serif;
    font-weight: 400;
    line-height: var(--line-height-small);
    color: var(--white);
}

.heading-primary {
    line-height: 1;
    font-size: var(--font-size-huge);
    font-weight: 400;
}

@media(max-width: 900px) {
    .heading-primary {
        font-size: 6.5rem;
    }
}

h2 {
    font-size: var(--font-size-large);
    margin-bottom: var(--gutter-medium);
}

h2::after {
    content: '';
    display: block;
    height: 2px;
    width: 10rem;
    background: var(--pink);
    margin: var(--gutter-small) 0;
}

h3 {
    font-size: var(--font-size-medium-1);
    margin-bottom: var(--gutter-small);
}

@media(max-width: 500px) {
    .heading-primary {
        font-size: var(--font-size-large);
    }

    h2 {
        font-size: var(--font-size-medium-1);
    }

    h3 {
        font-size: var(--font-size-medium);
    }
}

p {
    margin: var(--gutter-small-1) 0;
}

@media(max-width: 900px) {
    p {
        max-width: var(--container-small-width);
    }
}

/* --------------------------------------- */
/* ----- Buttons and Links ----- */
/* --------------------------------------- */

a {
    color: var(--white);
    font-weight: 400;
    font-family: 'Jost', sans-serif;
    transition: all .2s;
    outline: 2px solid transparent;
}

::-moz-focus-inner {
    border: 0;
}

button:focus,
a:focus {
    outline: 2px solid var(--pink);
}

body:not(.user-is-tabbing) button:focus,
body:not(.user-is-tabbing) a:focus {
    outline: none;
}

.link:hover {
    color: var(--pink);
}

.btn {
    position: relative;
    display: inline-block;
    padding: 1rem 4.2rem;
    text-decoration: none;
    color: inherit;
    border: 1px solid var(--pink);
    font-weight: 400;
}

.btn:focus {
    outline: none;
}

.btn::after {
    content: '';
    display: block;
    position: absolute;
    top: 0;
    left: 0;
    right: 100%;
    background: var(--white);
    height: 100%;
    z-index: -1;
    transition: all 0.2s cubic-bezier(1, 0.68, 0.16, 0.9);
}

.btn:hover::after,
.btn:focus::after {
    right: 0;
    background: var(--pink);
}

.btn--pink {
    background: var(--pink);
    transition: all 0.2s;
}

.btn--pink::after {
    display: none;
}

.btn--pink:hover,
.btn--pink:focus {
    background: transparent;
}

.link__text {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: .6rem;
    color: inherit;
    text-decoration: none;
    border-bottom: 1px solid var(--pink);
}

.link__text::after {
    content: '';
    display: block;
    position: absolute;
    top: 0;
    left: 0;
    right: 100%;
    background: var(--white);
    height: 100%;
    z-index: -1;
    transition: all 0.2s cubic-bezier(1, 0.68, 0.16, 0.9);
}

.link__text:focus {
    outline: none;
}

.link__text:hover::after,
.link__text:focus:after {
    right: 0;
    background: var(--pink);
}

.link__text img {
    width: 20px;
    height: auto;
    transition: transform 0.3s ease;
}

.link__text:hover img {
    transform: translateY(-3px);
}

/* ----- Back to Top ----- */

.back-to-top {
    position: fixed;
    bottom: 4rem;
    right: 4rem;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 5.5rem;
    width: 5.5rem;
    background-color: var(--pink);
    border-radius: 50%;
    z-index: 10;
    visibility: hidden;
    transition: all .4s;
}

.back-to-top__image {
    height: 70%;
}

@media(max-width: 900px) {
    .back-to-top {
        right: 2rem;
    }
}

@media(max-width: 500px) {
    .back-to-top {
        right: 1rem;
    }
}

/* --------------------------------------- */
/* ----- Navigation ----- */
/* --------------------------------------- */

.nav {
    display: flex;
    justify-content: flex-end;
    padding: var(--gutter-normal) 0;
}

.nav__items {
    display: flex;
    list-style: none;
    flex-wrap: wrap;
    gap: var(--gutter-small);
}

.nav__item:not(:last-child) {
    margin-right: var(--gutter-medium);
}

@media(max-width: 500px) {
    .nav {
        justify-content: center;
    }
}

@media(max-width: 400px) {
    .nav__item:not(:last-child) {
        margin-right: var(--gutter-normal);
    }
}

@media(max-width: 300px) {
    .nav {
        font-size: var(--font-size-small);
    }
}

.nav__link {
    position: relative;
    display: inline-block;
    padding: 1rem 0;
    text-decoration: none;
    color: inherit;
    transition: all .2s;
}

.nav__link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 100%;
    display: inline-block;
    height: 1rem;
    background: var(--white);
    transition: all 0.25s cubic-bezier(1, 0.68, 0.16, 0.9);
}

.nav__link:hover {
    color: var(--pink);
}

.nav__link:hover::after {
    right: 0;
    height: 2px;
    background: var(--pink);
}

/* --------------------------------------- */
/* ----- Header ----- */
/* --------------------------------------- */

.header {
    background: linear-gradient(rgba(0, 0, 0, .1), rgba(0, 0, 0, .4)),
        url('./images/header.png');
    height: 100vh;
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    font-size: var(--font-size-normal);
}

.header__text {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
}

.header__text p {
    margin: 1.5rem 0 3.5rem;
    max-width: var(--container-medium-width);
    font-family: 'Jost', sans-serif;
    font-size: var(--font-size-medium);
}

@media(max-width: 500px) {
    .header {
        text-align: center;
    }

    .header__text p {
        transform: scale(.8);
    }
}

@supports (-webkit-touch-callout: none) {
    .header {
        background-attachment: scroll;
    }
}

/* --------------------------------------- */
/* ----- Work ----- */
/* --------------------------------------- */

.work__box {
    display: flex;
    align-items: center;
}

@media(max-width: 900px) {
    .work__box {
        align-items: initial;
        flex-direction: column-reverse;
    }
}

.work__box:not(:last-child) {
    margin-bottom: clamp(6rem, 8vw, 20rem);
}

@media(max-width: 500px) {
    .work__box:not(:last-child) {
        margin-bottom: 20rem;
    }
}

.work__links {
    display: flex;
    align-items: center;
}

.work__text {
    flex: 0 0 30%;
}

.work__list {
    list-style-position: inside;
    margin-bottom: var(--gutter-normal);
}

.work__code {
    display: block;
    height: 3rem;
    margin-left: var(--gutter-normal);
    transition: all .3s;
}

.work__code:hover {
    transform: scale(1.2);
}

.work__image-box {
    margin-bottom: var(--gutter-normal);
}

.work__image-box>video {
    width: 100%;
    height: auto;
    object-fit: cover;
    border-radius: 1.5rem;
    box-shadow: 0 0 0 rgba(0, 0, 0, 0);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}


@media (min-width: 901px) {
    .work__image-box {
        flex: 1;
        margin: 0 0 0 10rem;
    }

    .work__box {
        align-items: flex-start;
        gap: clamp(2rem, 4vw, 6rem);
    }

    .work__text {
        flex: 0 0 clamp(28%, 32vw, 36%);
    }
}

@media(max-width: 900px) {
    .work__code {
        height: 4rem;
    }
}

/* ====== Slider (shared) ====== */
.slider-container {
    position: relative;
    overflow: hidden;
    width: 100%;
    border-radius: 1.5rem;
    transition: box-shadow 0.35s ease, border-color 0.35s ease;
}

.slider-container:hover {
    box-shadow: 0 0 20px rgba(255, 50, 88, 0.4);
    border: 1px solid rgba(255, 50, 88, 0.4);
}

.slider {
    display: flex;
    will-change: transform;
    transition: transform 0.5s ease;
}

.slider img,
.slider video {
    flex: 0 0 100%;
    width: 100%;
    object-fit: cover;
    border-radius: inherit;
    display: block;
    transition: transform 0.35s cubic-bezier(.2, .6, .2, 1),
        box-shadow 0.35s cubic-bezier(.2, .6, .2, 1);
}

.slider img {
    cursor: pointer;
}

.slider img:hover {
    transform: scale(1.02);
    box-shadow: 0 4px 15px rgba(255, 50, 88, 0.25);
}

/* ====== Dots ====== */
.dots {
    position: absolute;
    bottom: 1.5rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: clamp(0.4rem, 1vw, 0.6rem);
    z-index: 1001;
    padding: 0.4rem 0.8rem;
    border-radius: 1rem;
    background: rgba(0, 0, 0, 0.4);
}

.dot {
    width: clamp(0.6rem, 1.2vw, 0.8rem);
    height: clamp(0.6rem, 1.2vw, 0.8rem);
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.6);
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.3s ease;
}

.dot:hover {
    transform: scale(1.15);
}

.dot.active {
    background-color: var(--pink);
}

/* ====== Arrows ====== */
.prev,
.next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    font-size: clamp(2.4rem, 3.5vw, 3rem);
    color: var(--white);
    cursor: pointer;
    z-index: 1001;
    padding: 0 1rem;
    transition: transform 0.25s ease, color 0.25s ease;
    outline: none;
}

.prev:hover,
.next:hover {
    transform: translateY(-50%) scale(1.2);
    color: var(--pink);
}

.slider-container .prev {
    left: 1rem;
}

.slider-container .next {
    right: 1rem;
}

/* ====== Gallery Modal ====== */
.gallery-modal {
    display: none;
    position: fixed;
    z-index: 1000;
    inset: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(4px);
    justify-content: center;
    align-items: center;
}

.gallery-modal.active {
    display: flex;
}

.gallery-content {
    position: relative;
    width: 100%;
    max-width: 800px;
    height: 80%;
    overflow: hidden;
}

.gallery-content .slider {
    display: flex;
    height: 100%;
    position: relative;
}

.gallery-modal .slider img {
    object-fit: contain;
    pointer-events: none;
    cursor: default;
}

.close-button {
    position: absolute;
    top: 2rem;
    right: 2rem;
    font-size: 3rem;
    background: none;
    border: none;
    color: var(--white);
    cursor: pointer;
    z-index: 1003;
    transition: transform 0.25s ease;
}

.close-button:hover {
    transform: scale(1.2);
    color: var(--pink);
}

/* Modal arrows & dots */
.gallery-content .prev,
.gallery-content .next {
    font-size: 4rem;
    position: fixed;
}

.gallery-content .prev {
    left: 2rem;
}

.gallery-content .next {
    right: 2rem;
}

.gallery-content .dots {
    bottom: 1rem;
    gap: 0.6rem;
}

body:has(.gallery-modal.active) .slider-container .prev,
body:has(.gallery-modal.active) .slider-container .next,
body:has(.gallery-modal.active) .slider-container .dots {
    display: none !important;
}

/* ====== Touch support targets ====== */
.prev,
.next,
.close-button,
.dot {
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
    user-select: none;
    pointer-events: auto;
}

/* --------------------------------------- */
/* ----- Skills ----- */
/* --------------------------------------- */

.skills {
    background-color: var(--skills-bg);
    padding: 6rem 0;
    color: var(--skills-text-color);
    z-index: 0;
}


.section-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 2rem;
}

.section-header {
    display: flex;
    justify-content: center;
    flex-wrap: nowrap;
    gap: 2rem;
    overflow-x: auto;
    margin-bottom: 2.5rem;
    padding-bottom: 1rem;
}


.section-header-wrapper {
    max-width: 700px;
    margin: 0 auto 2.5rem auto;
    padding: 0 1rem;
}

.section-header button {
    padding: 1rem 2.4rem;
    border-radius: 999px;
    font-size: 1.5rem;
    font-weight: 700;
    border: 1px solid var(--skills-secondary);
    background-color: transparent;
    color: var(--skills-secondary);
    transition: all 0.25s ease-in-out;
    box-shadow: 0 1px 6px rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(2px);
}

.section-header button:hover {
    color: var(--skills-primary);
    border-color: var(--skills-primary);
    box-shadow: 0 4px 12px rgba(255, 50, 88, 0.08);
}

.section-header button.active {
    background-color: var(--skills-primary);
    color: var(--skills-text-color);
    border-color: var(--skills-primary);
    box-shadow: 0 4px 14px rgba(255, 50, 88, 0.2);
}

.section-content {
    display: none;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.3s ease;
}

.section-content.active {
    display: block;
    opacity: 1;
    transform: translateY(0);
}



.category-title {
    font-size: 2rem;
    margin-bottom: 1.5rem;
    color: var(--skills-primary);
    font-weight: bold;
}


.skill-item {
    background: var(--skills-card-bg);
    border-radius: 0.6rem;
    padding: 1.5rem;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    transition: background-color 0.3s, transform 0.3s, box-shadow 0.3s;
    position: relative;
}

.skill-item:hover {
    background: #2a2a2a;
    transform: scale(1.01);
    box-shadow: 0 4px 12px rgba(255, 50, 88, 0.08);
}

.skill-item.tip-open {
    z-index: 10000;
}

.skill-name {
    flex-grow: 1;
    font-size: 1.4rem;
}

.skills__logo {
    width: 24px;
    height: 24px;
    margin-right: 1rem;
    object-fit: contain;
    filter: none;
    transition: none;
}

.info-icon {
    cursor: pointer;
}

.info-tooltip {
    position: absolute;
    bottom: calc(100% + 8px);
    right: 1rem;
    max-width: 260px;
    padding: .8rem 1rem;
    font-size: 1.3rem;
    line-height: 1.4;
    color: var(--white);
    background: rgba(12, 12, 12, 0.92);
    border: 1px solid rgba(215, 38, 56, 0.35);
    border-radius: 8px;
    box-shadow: 0 6px 20px rgba(0, 0, 0, .35);
    z-index: 10001;

    opacity: 0;
    visibility: hidden;
    transform: translateY(6px);
    transition: opacity .18s ease, transform .18s ease, visibility 0s linear .18s;
    pointer-events: none;
}

.info-tooltip::after {
    content: "";
    position: absolute;
    top: 100%;
    right: 1.2rem;
    border: 8px solid transparent;
    border-top-color: rgba(12, 12, 12, 0.92);
}

.info-tooltip.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    transition: opacity .18s ease, transform .18s ease;
    pointer-events: auto;
}

@media (max-width: 420px) {
    .info-tooltip {
        bottom: auto;
        top: calc(100% + 8px);
    }

    .info-tooltip::after {
        top: -16px;
        transform: rotate(180deg);
    }
}

@media (hover: none) and (pointer: coarse) {
    .info-icon {
        cursor: pointer;
    }
}

.info-icon {
    font-size: 1.6rem;
    color: var(--skills-primary);
    margin-left: 1rem;
    cursor: help;
}

.languages-grid {
    display: grid;
    grid-template-columns: 1fr minmax(260px, 420px);
    gap: clamp(2rem, 4vw, 4rem);
    margin-top: 2rem;
}

@media (max-width: 860px) {
    .languages-grid {
        grid-template-columns: 1fr;
    }
}

.language-bar {
    background: var(--skills-card-bg);
    border-radius: 0.6rem;
    padding: 1.5rem;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    transition: background-color 0.3s, transform 0.3s, box-shadow 0.3s;
}

.language-bar:hover {
    background: #2a2a2a;
    transform: scale(1.01);
    box-shadow: 0 4px 12px rgba(255, 50, 88, 0.08);
}

.language-name {
    font-size: 1.4rem;
    font-weight: 500;
    color: var(--skills-text-color);
    text-align: right;
    padding-right: 0.5rem;
}

.bar-wrapper {
    flex-grow: 1;
    margin: 0 1rem;
}

.bar {
    width: 100%;
    height: 10px;
    background-color: #444;
    border-radius: 5px;
    overflow: hidden;
}

.fill {
    height: 100%;
    background-color: var(--skills-primary);
    border-radius: 5px;
    transition: width 0.4s ease;
}

.level-label {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--skills-secondary);
    text-align: left;
    padding-left: 0.5rem;
}

.cefr-legend {
    font-size: 1.2rem;
    color: var(--skills-secondary);
    text-align: center;
    margin-top: 1rem;
    max-width: 280px;
}

.language-staircase {
    display: flex;
    flex-direction: row;
    gap: 2rem;
    align-items: flex-end;
    justify-content: center;
    padding: 0;
    margin: 2rem 0;
    list-style: none;
}


.language-staircase .level {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
}

.language-staircase .label {
    padding: 0 0.4rem;
    height: 1.6rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: bold;
    color: #fff;
    border-radius: 4px;
    white-space: nowrap;
}

.language-staircase .level .step {
    width: 100%;
    height: 1.6rem;
    border-radius: 4px;
}


/* === Colors for each level === */
.level-A1 .label,
.level-A1 .step {
    background-color: #e67e22;
}

.level-A2 .label,
.level-A2 .step {
    background-color: #3498db;
}

.level-B1 .label,
.level-B1 .step {
    background-color: #f1c40f;
}

.level-B2 .label,
.level-B2 .step {
    background-color: #27ae60;
}

.level-C1 .label,
.level-C1 .step {
    background-color: #2ecc71;
}

.level-C2 .label,
.level-C2 .step {
    background-color: #1abc9c;
}

/* Responsive: reduce size slightly on mobile */
@media (max-width: 768px) {
    .language-staircase {
        gap: 1.2rem;
    }

    .language-staircase .step {
        width: 1.2rem;
        height: 1.2rem;
    }
}


/* --------------------------------------- */
/* ----- About ----- */
/* --------------------------------------- */

.about__content {
    display: flex;
    flex-direction: row-reverse;
    align-items: center;
}

@media(max-width: 900px) {
    .about__content {
        flex-direction: column-reverse;
        align-items: initial;
    }
}

.about__photo-container {
    margin-bottom: var(--gutter-normal);
}

@media(min-width: 901px) {
    .about__text {
        flex: 0 0 35%;
    }

    .about__photo-container {
        flex: 1;
        margin: 0 var(--gutter-huge) 0 0;
    }
}

.about__photo {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border-radius: 12px;
    box-shadow: 0 0 0 rgba(0, 0, 0, 0);
}

.about__photo:hover {
    transform: scale(1.05);
    box-shadow: 0 0 20px rgba(255, 50, 88, 0.4);
}

.resume-dropdown {
    position: relative;
    display: inline-block;
}

.resume-dropdown:hover .resume-menu {
    display: block;
}

.resume-dropdown:hover .resume-toggle {
    border-color: var(--pink);
    background: rgba(255, 50, 88, 0.4);
    color: var(--white);
}

.resume-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background: var(--black);
    border: 1px solid var(--pink);
    border-radius: 4px;
    z-index: 10;
}

.resume-menu .resume-option {
    display: block;
    padding: 0.8rem 1.2rem;
    color: var(--white);
    text-decoration: none;
    white-space: nowrap;
}

.resume-menu .resume-option:hover {
    color: var(--pink);
    background: rgba(255, 50, 88, 0.2);
}

.cv-modal {
    display: none;
    position: fixed;
    z-index: 999;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(4px);
    justify-content: center;
    align-items: center;
}

.cv-content {
    width: 90%;
    max-width: 800px;
    height: 80%;
    background: #000;
    display: flex;
    justify-content: center;
    align-items: center;
}

.cv-frame {
    width: 100%;
    height: 100%;
    border: none;
}

.cv-modal__close {
    position: absolute;
    top: 2rem;
    right: 2rem;
    font-size: 4rem;
    color: var(--white);
    cursor: pointer;
    transition: 0.2s;
}

.cv-modal__close:hover {
    color: var(--pink);
}


/* --------------------------------------- */
/* ----- Contact ----- */
/* --------------------------------------- */

.contact__info {
    max-width: var(--container-medium-width);
}

.contact__container {
    display: flex;
    flex-wrap: wrap;
    gap: 4rem;
    justify-content: space-between;
}

.contact__form {
    flex: 1;
    min-width: 300px;
    max-width: 500px;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 1rem;
    border: none;
    border-radius: 5px;
    font-family: inherit;
    font-size: 1.6rem;
    background-color: var(--skills-card-bg);
    color: var(--skills-text-color);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    transition: all 0.2s;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border: 1px solid var(--pink);
    background-color: #2a2a2a;
}

@media (max-width: 768px) {
    .contact__container {
        flex-direction: column;
    }
}

/* --------------------------------------- */
/* ----- Footer ----- */
/* --------------------------------------- */

.footer {
    text-align: center;
    padding: var(--gutter-medium) 0 var(--gutter-normal);
}

.footer__social-links {
    display: flex;
    justify-content: center;
    padding: var(--gutter-normal) 0;
    list-style: none;
}

.footer__social-link-item:not(:last-of-type) {
    margin-right: var(--gutter-small);
}

.footer__social-image {
    height: 4rem;
}

.footer__github-buttons {
    display: flex;
    justify-content: center;
}

.footer__github-buttons iframe {
    height: 2.5rem;
    width: 84px;
    transform: translateY(3px);
}

.footer__copyright {
    font-size: 0.85em;
    opacity: 0.6;
    margin-top: 1rem;
    text-align: center;
}

@media(max-width: 500px) {
    .footer {
        padding: var(--gutter-medium) 0;
    }
}

/* ===== WhatsApp QR Modal ===== */

.qr-modal {
    display: none;
    position: fixed;
    z-index: 999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(4px);
    justify-content: center;
    align-items: center;
}

.qr-modal__image {
    max-width: 300px;
    max-height: 80vh;
    border-radius: 8px;
    box-shadow: 0 0 20px rgba(255, 50, 88, 0.5);
}

.qr-modal__close {
    position: absolute;
    top: 2rem;
    right: 3rem;
    font-size: 4rem;
    color: var(--white);
    cursor: pointer;
    transition: 0.2s;
}

.qr-modal__close:hover {
    color: var(--pink);
}

/* ===== Cookie Banner & Privacy Modal (optimized) ===== */

/* Helper vars (local to banner area) */
#cookie-banner {
    --sep-white-35: rgba(255, 255, 255, 0.35);
    --sep-white-15: rgba(255, 255, 255, 0.15);
    --pink-18: rgba(215, 38, 56, 0.18);
    --pink-22: rgba(215, 38, 56, 0.22);
    --pink-25: rgba(215, 38, 56, 0.25);
    --pink-35: rgba(215, 38, 56, 0.35);
}

/* Hidden by default; becomes visible with .show */
#cookie-banner {
    position: fixed;
    inset: auto 20px 20px auto;
    /* bottom-right */
    max-width: 420px;
    display: none;

    background: rgba(12, 12, 12, 0.86);
    color: var(--white-1);
    border: 1px solid var(--pink-18);
    border-radius: 14px;
    padding: 1.2rem 1.4rem 1.2rem 1.2rem;
    z-index: 1000;

    /* layout */
    display: none;
    grid-template-columns: 36px 1fr auto;
    grid-template-rows: auto auto;
    grid-column-gap: 1rem;
    grid-row-gap: .4rem;

    /* fx */
    box-shadow: 0 10px 30px var(--pink-25), 0 2px 8px rgba(0, 0, 0, 0.35);
    backdrop-filter: blur(6px);
    animation: cookieSlideIn .45s cubic-bezier(.16, .84, .44, 1);
}

#cookie-banner.show {
    display: grid;
}

#cookie-banner .cookie-icon {
    grid-row: 1 / span 2;
    width: 36px;
    height: 36px;
    display: grid;
    place-items: center;
    border-radius: 10px;
    background: rgba(215, 38, 56, 0.12);
    border: 1px solid var(--pink-22);
}

#cookie-banner .cookie-text {
    font-size: 1.35rem;
    line-height: 1.55;
}

#cookie-banner .actions {
    display: flex;
    align-items: center;
    gap: .6rem;
    grid-column: 2 / 4;
}

/* Buttons (shared rules first) */
#cookie-banner .btn-ghost,
#cookie-banner .btn-solid {
    font-family: 'Jost', sans-serif;
    border-radius: 10px;
    padding: .6rem 1.1rem;
    font-size: 1.3rem;
    cursor: pointer;
    border: 1px solid transparent;
    transition: transform .15s ease, box-shadow .2s ease, border-color .2s ease, background .2s ease;
}

#cookie-banner .btn-ghost {
    background: transparent;
    color: var(--white);
    border-color: rgba(255, 255, 255, 0.14);
}

#cookie-banner .btn-ghost:hover {
    border-color: rgba(255, 255, 255, 0.28);
    transform: translateY(-1px);
}

#cookie-banner .btn-solid {
    background: var(--pink);
    color: #fff;
    border-color: rgba(215, 38, 56, 0.6);
    box-shadow: 0 4px 16px var(--pink-25);
}

#cookie-banner .btn-solid:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 20px var(--pink-35);
}

/* Inline link style in banner (used by #privacy-link too) */
#cookie-banner a.link {
    color: var(--white);
    text-decoration: none;
    border-bottom: 1px dashed var(--sep-white-35);
}

#cookie-banner a.link:hover {
    color: var(--pink);
    border-bottom-color: var(--pink);
}

#cookie-banner.show {
    animation: cookieSlideIn .45s cubic-bezier(.16, .84, .44, 1),
        cookiePulse 1.6s ease-in-out infinite;
    transform-origin: center;
}

.learn-more-block {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    margin-top: 2px;
    width: 100%;
}

#privacy-link {
    font-size: 0.85rem;
    opacity: 0.5;
    color: rgba(255, 255, 255, 0.6);
    text-decoration: none;
    margin-bottom: 2px;
}

#privacy-link:hover {
    opacity: 1;
    color: var(--pink);
}

.separator-line {
    width: 100%;
    border-bottom: 1px dashed var(--sep-white-15);
}

@keyframes cookieSlideIn {
    from {
        transform: translateY(12px) scale(.98);
        opacity: 0;
    }

    to {
        transform: translateY(0) scale(1);
        opacity: 1;
    }
}

@keyframes cookiePulse {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.04);
    }
}

/* --- Privacy Modal --- */
#privacy-modal {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 2000;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(6px);
    overflow-y: auto;
}

#privacy-content {
    background: #0b0b0b;
    color: var(--white-1);
    width: min(860px, 92vw);
    margin: 6rem auto;
    padding: 3rem 2.5rem;
    border-radius: 16px;
    border: 1px solid var(--pink-18);
    box-shadow: 0 18px 60px rgba(0, 0, 0, 0.55), 0 8px 24px rgba(215, 38, 56, 0.08);
    line-height: 1.7;
}

#privacy-content h1 {
    font-family: 'Jost', sans-serif;
    color: var(--pink);
    font-size: 2.6rem;
    margin-bottom: 1rem;
    text-align: center;
}

#privacy-content h2 {
    font-size: 2rem;
    margin: 2rem 0 .6rem;
    color: var(--white);
    text-align: left;
}

#privacy-content h3 {
    font-size: 1.7rem;
    margin: 1.2rem 0 .4rem;
    color: var(--white-1);
    text-align: left;
}

#privacy-content p {
    font-size: 1.45rem;
    margin-bottom: 1.2rem;
    text-align: justify;
}

#privacy-content ul {
    list-style: disc;
    padding-left: 2rem;
    margin-bottom: 1.5rem;
}

#privacy-content li {
    font-size: 1.4rem;
    margin-bottom: .6rem;
}

#privacy-content a {
    color: var(--pink);
    text-decoration: underline;
}

#privacy-content a:hover {
    color: #ef4a5a;
    /* plus clair pour hover */
}

#privacy-close {
    float: right;
    cursor: pointer;
    font-size: 2.6rem;
    font-weight: bold;
    color: var(--white-1);
    border-radius: 10px;
    padding: .2rem .6rem;
    transition: background-color .15s ease, color .15s ease;
}

#privacy-close:hover {
    background: rgba(215, 38, 56, 0.15);
    color: #fff;
}

/* Mobile tweaks */
@media (max-width: 520px) {
    #cookie-banner {
        inset: auto 12px 12px 12px;
        max-width: unset;
    }
}

/* === Consent lock: prevent scroll until accepted === */
html.consent-locked,
body.consent-locked {
    overflow: hidden !important;
    height: 100%;
}