@import url(reset.css);
@import url('https://fonts.googleapis.com/css2?family=Gloria+Hallelujah&family=Schoolbell&display=swap');

:root {
    --color-text: rgb(27, 27, 27);
    --color-accent: #e62c27;
    --color-sun: #ffcc07;

    --color-progress: rgb(240, 206, 207);
    --color-footer: #97703A;
    --color-chapter-1: #CBCBCB;
    --color-chapter-5: #A1F6FF;

    --font-main: "Schoolbell", cursive;
    --font-title: "Gloria Hallelujah", cursive;
}

body {
    font-family: var(--font-main);
    font-size: 24px;
    color: var(--color-text);
}

img {
    display: block;
    object-fit: contain;
}

h1 {
    position: absolute;
    top: 40%;
    transform: translateY(-70%);
    font-size: 176px;
    font-family: var(--font-title);
    line-height: 1;
    width: 8ch;
}

h2 {
    position: absolute;
    top: 70%;
    transform: translate(-50%, -50%);
    left: 50%;
}

h3 {
    color: var(--color-accent);
}

p {
    font-size: 18px;
}

.chapter-content {
    z-index: 1;

    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.chapter-content__play-button {
    background: transparent;
    border: none;
    padding: 0;
    cursor: pointer;
    width: 10%;
}

.chapter-content__play-button img {
    width: 100%;
    display: block;
}

.chapter-content__page {
    width: 30vw;
    height: calc(30vw * 1.414);
    padding: 5%;
    background: url("../assets/img/feuille.png");
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 2%;
    position: fixed;
    top: 1%;
    left: 50%;
    transform: translateX(-50%);
    width: 90vw;
    z-index: 100;
}

.chapter-list {
    display: flex;
    justify-content: space-between;
    gap: 2%;
    flex-grow: 1;
}

.chapter-list a {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-grow: 1;
    text-decoration: none;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.chapter-list .progress-bar {
    position: absolute;
    transform-origin: left;
    width: 100%;
    height: 100%;
    transform: scaleX(0);
    background-color: var(--color-progress);
    z-index: -1;
}

.chapter-list .stroke {
    position: absolute;
    width: 100%;
    height: 100%;
    overflow: visible;
    z-index: 0;
}

.chapter-list .text {
    color: var(--color-text);
    z-index: 1;
}

section {
    height: 150vh;
    padding-left: 5%;
    padding-right: 5%;
    margin: 0;
}

.chapter--transition {
    position: relative;
    overflow: visible;
    z-index: 60;
}

.chapter--transition img {
    width: 100%;
}

.chapter--transition img:first-child {
    position: relative;
}

.chapter--transition img:not(:first-child) {
    position: absolute;
    bottom: 0;
    left: 0;
}

.chapter--transition:nth-of-type(1) {
    background: linear-gradient(180deg, rgba(128, 209, 244, 1) 0%, rgba(255, 255, 255, 1) 50%, rgba(203, 203, 203, 1) 50%, rgba(203, 203, 203, 1) 100%);
}

.chapter--transition:nth-of-type(2) {
    background: #CBCBCB;
    background: linear-gradient(180deg, rgba(203, 203, 203, 1) 0%, rgba(255, 255, 255, 1) 50%, rgba(195, 159, 109, 1) 50%, rgba(195, 159, 109, 1) 100%);
}

.volume {
    width: 10%;
    max-width: 12vh;
}

.volume:hover {
    cursor: pointer;
    background-color: rgba(255, 255, 255, 0.2);
}

.vol-1 {
    fill: none;
}

.vol-1,
.vol-2 {
    stroke: var(--color-text);
    stroke-linecap: round;
    stroke-width: 46px;
}

.vol-2 {
    fill: var(--color-text);
}

.vol-3 {
    fill: var(--color-accent);
}

.hidden {
    display: none;
}

.play:hover {
    cursor: pointer;
}

#home {
    display: flex;
    align-items: center;
    position: relative;
    height: 100vh;
    background: #01A3E8;
    background: linear-gradient(180deg, rgba(1, 163, 232, 1) 0%, rgba(128, 209, 244, 1) 100%);
}

.soleil {
    position: absolute;
    width: 35vh;
    right: 5vh;
    top: 5vh;
}

.sol-1 {
    fill: var(--color-sun);
}

.sol-2 {
    fill: none;
    stroke: var(--color-sun);
    stroke-linecap: round;
    stroke-width: 27px;
}

.ois-1 {
    fill: #fff;
}

.oiseau {
    --scale-factor: 1;
    align-self: flex-start;
    width: calc(3vw * var(--scale-factor) + 3vw);
    position: absolute;
}

#chapter-2,
#chapter-3,
#chapter-4,
#chapter-5 {
    position: relative;
    overflow: hidden;
    background-size: cover;
}

.decor-img {
    position: absolute;
    max-width: 100%;
    z-index: 0;
}

#chapter-1 {
    position: relative;
    background-color: var(--color-chapter-1);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

#chapter-1>img {
    width: 50%;
}

#chapter-1 .chapter-content {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);

    right: 14%;
}

#chapter-2 {
    background-image: url('../assets/img/chapitre-2-background.png');
}

#chapter-2 .chapter-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.chapter-2__portail {
    top: 25%;
    left: 5%;
    width: 25%;
}

.chapter-2__naruto {
    top: 5%;
    left: 70%;
    width: 30%;
}

.chapter-2__chat {
    top: 70%;
    left: 7%;
    width: 30%;
}

.chapter-2__onigiri {
    top: 60%;
    left: 70%;
    width: 20%;
}

#chapter-3 {
    background-image: url('../assets/img/chapitre-3-background.png');
}

#chapter-3 .chapter-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.chapter-3__calcul {
    top: 5%;
    left: 30%;
    width: 20%;
}

.chapter-3__ecole-nule {
    top: 40%;
    left: 5%;
    width: 30%;
}

.chapter-3__coeur {
    top: 65%;
    right: 10%;
    width: 15%;
}

.chapter-3__etoile {
    top: 80%;
    left: 10%;
    width: 10%;
}

.chapter-3__smile {
    top: 30%;
    left: 80%;
    width: 10%;
}

#chapter-4 {
    background-image: url('../assets/img/chapitre-4-background.png');
}

#chapter-4 .chapter-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.chapter-4__couteau {
    top: 5%;
    left: 5%;
    height: 100%;
}

.chapter-4__fourchette {
    top: 5%;
    right: 5%;
    height: 100%;
}

.chapter-4__assiette {
    top: 50%;
    left: 50%;
    width: 50%;
    transform: translate(-50%, -50%);
    z-index: 1;
}

.chapter-4__serviette {
    top: 50%;
    left: 50%;
    width: 50%;
    z-index: 0;
    transform: translate(-50%, -50%);
}

#chapter-5 {
    background-color: var(--color-chapter-5);
}

#chapter-5 .chapter-content {
    position: absolute;
    top: 50%;
    left: 25%;
    transform: translate(-50%, -50%);
}

.chapter-5__fille {
    bottom: 17%;
    left: 55%;
    z-index: 1;
    width: 30%;
}

.chapter-5__herbe {
    bottom: 0;
    left: 0;
    z-index: 0;
    width: 100%;
}

.chapter-5__soleil {
    top: 5%;
    right: 5%;
    width: 25%;
}

.dataviz {
    height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3rem;
    background: url('../assets/img/chapitre-2-background.png');
    background-size: cover;

    color: white;
}

.dataviz span {
    font-size: 2.5rem;
}

.viz-container {
    display: flex;
    align-items: flex-end;
    justify-content: center;
    gap: 4rem;
}

.col {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

.cake-bar {
    width: 200px;
    position: relative;
    background-image: url('../assets/img/gateau.png');
    background-size: 300px;
    background-position: top center;
    z-index: 2;
}

select {
    padding: 10px 20px;
    font-size: 1rem;
    border-radius: 8px;
    border: none;
    font-family: inherit;
    cursor: pointer;
}

footer {
    width: 100%;
    height: 33vh;
    padding-left: 10vw;
    background-color: var(--color-footer);
    display: flex;
    flex-direction: column;
    justify-content: center;
}

footer h3,
footer h4,
footer p {
    color: white;
}

footer h4 {
    font-size: 36px;
}

footer .footer-container {
    display: flex;
    gap: 5%;
}