/*
 * Define the default responsive.
 */

/* === Main variables === */
:root {
    /* Positions */
    --presentation-margin: var(--spacing-xl) 0% 0% 0%;
    --arrow-1-margin: var(--spacing-s) 0% 0% 0%;
    --about-margin: var(--spacing-xxl) 0% 0% 0%;
    --arrow-2-margin: var(--spacing-xs) 0% 0% 0%;
    --personal-projects-margin: var(--spacing-xxl) 0% 0% 0%;
    --college-projects-margin: var(--spacing-xs) 0% 10% 0%;
    --footer-margin: var(--spacing-xxl) 0% 0% 0%;

    /* Body */
    --body-margin: 0 var(--spacing-m);

    /* Header */
    --header-padding: var(--spacing-3xs);
    --header-gap: 100px;

    /* Presentation */
    --presentation-h2: 7em;
    --presentation-p: var(--text-size-l);

    /* About */
    --about-content-padding: 5%;
    --about-content-gap: 70px;
    --about-content-width: 80%;
    --about-p-size: var(--text-size-xs);

    /* Projects */
    --project-gap: 5%;
    --project-top: 14%;
    --project-right: 10%;
    --project-bottom: 5%;
    --project-left: 10%;
    --project-padding: 1% 2%;
    --project-content-gap: 3%;
    --left-content-width: 47%;
    --right-content-width: 50%;
    --repo-width: 60%;
    --repo-padding: 2% 0%;

    /* Footer */
    --links-gap: 30%;

    /* Title */
    --prm-size: 1em;
    --sdr-size: 0.55em;

    /* Img sizes */
    --profile-img-size: 185px;
    --fablab-img-size: 175px;
    --college-img-size: 165px;
    --close-button-size: 30px;
    --iframe-video-height: 350px;
    --link-sizes: 25px;

    /* Text */
    --header-a-size: var(--text-size-s);
    --h2-size: var(--title-size-l);
    --h3-size: var(--title-size-s);
    --p-size: var(--text-size-s);
    --a-size: var(--text-size-s);
    --preview-p-size: var(--text-size-xs);

    --arrow-size-text: var(--text-size-xs);
    --arrow-size-symbol: var(--text-size-s);
    --arrow-weight-symbol: var(--text-weight-s);

    /* Other */
    --column-number: repeat(3, 1fr);
}

/* === HTML === */
html {
    margin: 0;
    padding: 0;

    width: 100%;
    height: auto;

    scroll-behavior: var(--scroll-behavior);
}

/* === BODY === */
body {
    top: 0;

    margin: var(--body-margin);
    padding: 0;

    width: auto;
    min-height: 100vh;

    display: flex;
    flex-direction: column;
    justify-content: center;
}

body::before {
    position: fixed;

    inset: 0;
    z-index: -1;

    transform: scale(1.1);
}

body.no-scroll {
    overflow: hidden;
}

/* === HEADER === */
header {
    position: sticky;

    top: 0;

    margin: 0;
    padding: var(--header-padding);

    width: auto;

    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;

    z-index: 100;
}

header nav {
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: center;

    gap: var(--header-gap);
}

header a {
    font-size: var(--header-a-size);
}

/* === Title === */
h1 {
    display: inline-flex;
    flex-direction: column;
    align-items: stretch;
}

h1 span {
    line-height: 85%;
}

.h1-primary {
    font-size: var(--prm-size);
}

.h1-secondary {
    width: 100%;

    text-align: center;

    font-size: var(--sdr-size);
    letter-spacing: 0.02em;
}

/* === MAIN === */
main {
    display: flex;
    flex-direction: column;
    align-items: center;
}

section {
    z-index: 98;
    scroll-margin-top: var(--scroll-margin-top);
}

section h2 {
    /*margin-bottom: 5%;*/
    font-size: var(--h2-size);
}

section p {
    font-size: var(--text-size-s);
}

#home {
    margin: 0;
    padding: 0;
    width: 0;
    height: 0;
    scroll-margin-top: 0px;
}

/* === Arrow === */
.arrow1 {
    margin: var(--arrow-1-margin);
}

.arrow2 {
    margin: var(--arrow-2-margin);
}

.arrow1,
.arrow2 {
    display: flex;
    justify-content: center;
}

.go-next {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.next-section {
    font-size: var(--arrow-size-text);
}

.next-arrow {
    font-size: var(--arrow-size-symbol);
    font-weight: var(--arrow-weight-symbol);
}

/* === Presentation === */
#presentation {
    margin: var(--presentation-margin);
    text-align: center;
}

#presentation h2 {
    position: relative;
    font-size: var(--presentation-h2);
}

#presentation p {
    font-size: var(--presentation-p);
}

/* === About === */
#about {
    margin: var(--about-margin);

    width: 90%;
    height: auto;

    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.about-content {
    padding: var(--about-content-padding);

    width: var(--about-content-width);
    height: auto;

    display: flex;
    flex-direction: column;
    gap: var(--about-content-gap);
}

.profile,
.fablab,
.degree {
    width: auto;
    height: auto;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5%;
}

.profile div,
.fablab div,
.degree div {
    display: flex;
    flex-direction: column;
    justify-content: start;
    align-items: center;
}

.about-content h3 {
    font-size: var(--h3-size);
}

.about-content p {
    font-size: var(--about-p-size);
}

/* --- Profil --- */
.profile div {
    align-items: start;
}

.profile img {
    width: var(--profile-img-size);
    height: var(--profile-img-size);
}

/* --- FabLab --- */
.fablab div {
    align-items: end;
    text-align: start;
}

.fablab img {
    width: var(--fablab-img-size);
    height: var(--fablab-img-size);
}

/* --- Degree --- */
.degree div {
    align-items: start;
}

.degree img {
    width: auto;
    height: var(--college-img-size);
}

/* === Project Preview === */
#personal-projects {
    margin: var(--personal-projects-margin);

    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
}

#college-projects {
    margin: var(--college-projects-margin);

    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.projects-grid-selection {
    width: 85%;
    display: grid;
    grid-template-columns: var(--column-number);
    grid-column-gap: 5%;
    grid-row-gap: 10%;
}

.project-preview {
    padding: 3%;
    height: var(--box-height);

    display: flex;
    flex-direction: column;
}

.project-preview h3 {
    font-size: var(--h3-size);
}

.description {
    font-size: var(--preview-p-size);
}

.project-preview img {
    width: 100%;
    min-height: 80px;
    max-height: 80px;
}

.project-preview-content {
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: start;
    justify-content: space-between;
    overflow-y: hidden;
}

.learn-more {
    width: 100%;
    display: flex;
    justify-content: space-between;
}

.learn-more p {
    font-size: var(--preview-p-size);
}

.click-info {
    font-size: var(--preview-p-size);
}

/* === Project === */
.project {
    margin: 0;
    padding: var(--project-padding);

    position: fixed;

    inset: var(--project-top) var(--project-right) var(--project-bottom)
        var(--project-left);

    width: auto;
    height: 80%;

    z-index: 99;

    display: none;
    box-sizing: border-box;
}

.project.is-open {
    display: flex;
    flex-direction: column;
    justify-content: start;
    gap: var(--project-gap);
}

.project-header {
    width: 100%;
    height: auto;
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
}

.project-header h3 {
    font-size: var(--h2-size);
}

.project-header img {
    padding: 1%;
    width: var(--close-button-size);
    height: var(--close-button-size);
}

.project-content {
    width: 100%;
    flex: 1;
    display: flex;
    flex-direction: row;
    gap: var(--project-content-gap);
    min-height: 0;
    overflow: hidden;
}

.left-content,
.right-content {
    height: 100%;

    display: flex;
    flex-direction: column;
    justify-content: start;
    align-items: start;
}

.left-content {
    overflow-y: scroll;
    width: var(--left-content-width);
}

.left-content iframe,
.left-content img {
    width: 100%;
    height: var(--iframe-video-height);
}

.right-content {
    overflow-y: hidden;
    width: var(--right-content-width);
    display: flex;
    flex-direction: column;
    align-items: center;
}

.repo {
    padding: var(--repo-padding);
    width: var(--repo-width);
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: center;
    gap: 5%;
}

.repo:hover {
    transform: scale(0.96);
}

/* === FOOTER === */
footer {
    padding: 5% 3% 6% 3%;

    width: 100%;

    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
}

.links {
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: center;
    gap: var(--links-gap);
}

.links img {
    width: var(--link-sizes);
    height: auto;
}

.links a {
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: center;
    gap: 10%;
}

.links a:hover {
    transform: scale(0.92);
}
