:root {
    --violet: rgba(140, 91, 255, 1);
    --jaune: #e0ef39;
    --white: #faf5eb;
}

* {
    margin: 0;
    padding: 0;
    list-style-type: none;
    user-select: none;
}

a {
    text-decoration: none;
}

@font-face {
    font-family: "Already Broken";
    src: url("../fonts/alreadybroken.otf") format("opentype");
}

@font-face {
    font-family: "Helvetica Neue";
    src: url("../fonts/HelveticaNeue.ttc") format("truetype-collection");
}

@font-face {
    font-family: "Luxurious";
    src: url("../fonts/LuxuriousScript-Regular.ttf") format("truetype");
}

@font-face {
    font-family: "Space";
    src: url("../fonts/SpaceMono.ttf") format("truetype");
}

body {
    background-color: var(--white);
    font-size: 16px;
    font-family: "Helvetica Neue";
}

body::after {
    content: "";
    position: fixed;
    z-index: 102;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    background: url(../media/webp/texture3.webp);
    background-size: cover;
    opacity: 70%;
    mix-blend-mode: overlay;
    pointer-events: none;
}

.page-animation {
    position: fixed;
    top: 0;
    left: 0;
    z-index: 100;
    width: 100%;
    height: 100svh;
    display: grid;
    grid-template-columns: 1fr 1fr 1fr 1fr 1fr;
    grid-template-rows: 33.3333% 33.3333% 33.3333%;
    pointer-events: none;
    gap: 0;
}

.page-animation img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    pointer-events: none;
}

.page-animation :nth-child(9) {
    grid-row: 2/3;
    grid-column: 3/4;

}

.loading-percentage {
    grid-row: 2/3;
    grid-column: 3/4;
    width: 100%;
    height: 100%;
    z-index: 101;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    background-color: var(--violet);
    color: var(--white);
    font-size: 180px;
}

.episode {
    -webkit-transform: translateZ(0);
    transform: translateZ(0);
    backface-visibility: hidden;
    z-index: 99;
    min-height: calc(100vh - 16px);
    padding: 8px;
    overflow-y: auto;
    display: grid;
    place-items: center;
    position: fixed;
    /* tous les épisodes superposés */
    inset: 0;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.episode.is-visible {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

/*intro*/

.intro {
    display: grid;
    gap: 20px;
    grid-template-rows: auto auto 1fr;
    overflow: hidden;
}

.intro p {
    width: fit-content;
    margin: 4px 4px 4px auto;
    padding: 20px 30px;
    font-size: 32px;
    font-family: "Already Broken";
    color: var(--violet);
    background-color: var(--jaune);
    border-radius: 12px;
}

.intro h1 {
    font-size: 12vw;
    line-height: 100%;
    color: var(--violet);
}
h1 :last-child{
    font-family: "Luxurious";
    font-size: 28vw;
    font-weight: 400;
    padding: 20px;
}
.split-word {
    display: inline-block;
    overflow-y: hidden;
  }
  

.video-intro-container {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 20px;
    position: relative;
    overflow: hidden;
    transform-origin: center;
}

.video-intro-container img {
    position: absolute;
    width: 100%;
    bottom: 50%;
    left: 50%;
    transform: translateX(-50%) translateY(50%);

}

.nav-episode {
    width: fit-content;
    padding: 12px 30px;
    font-size: 32px;
    font-family: "Already Broken";
    color: var(--jaune);
    background-color: var(--violet);
    border-radius: 12px;
    display: flex;
    gap: 12px;
    position: absolute;
    bottom: 50px;
    left: 50%;
    transform: translateX(-50%) scale(1);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.nav-episode::after {
    content: "";
    width: 30px;
    height: 30px;
    background: url(../media/webp/icone-4j.webp) no-repeat;
    background-size: contain;
}

.flair {
    pointer-events: none;
    position: fixed;
    opacity: 0;
    width: 80px;
    z-index: 100;
}

.intro-animation {
    width: 0;
    height: 0;
}


/*menu*/

.menu {
    overflow: hidden;
}

.container-menu {
    display: grid;
    grid-template-rows: 1fr 1fr 1fr;
    width: 100%;
    height: calc(100vh - 16px);
}

/*
.container-menu::after{
    content: "";
    width: 100%;
    height: 3px;
    background-color: var(--violet);
    opacity: 60%;
    grid-row: 2/3;
    z-index: -1;
}
.container-menu::before{
    content: "";
    width: 100%;
    height: 3px;
    background-color: var(--violet);
    opacity: 60%;
    grid-row: 4/5;
    z-index: -1;
}
    */
.link-menu {
    height: calc(100% - 40px);
    width: calc(100% - 40px);
    padding: 20px;
    display: grid;
    grid-template-columns: 1fr auto;
    grid-template-rows: auto auto;
    position: relative;
}

.number-menu {
    font-size: 100px;
    font-weight: 800;
    color: var(--violet);
    background-color: var(--jaune);
    padding: 10px;
    grid-row: 1/3;
    grid-column: 1/2;
    width: fit-content;
    height: fit-content;
    margin: auto auto auto 0;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
}

.title-menu {
    font-size: 70px;
    color: var(--violet);
    grid-row: 1/2;
    grid-column: 2/3;
    margin-top: auto;
}

.title-menu span {
    font-size: 100px;
    font-family: "Luxurious";
}

.number-parties {
    font-family: "Space";
    color: var(--violet);
    opacity: 80%;
    margin-bottom: auto;
    text-align: end;
}

.swipe-card {
    position: fixed;
    top: 0;
    left: 0;
    opacity: 0;
    display: grid;
    padding: 12px;
    gap: 24px;
    color: var(--violet);
    font-size: 20px;
    font-weight: 400;
    width: 300px;
    min-height: 370px;
    background-color: var(--jaune);
    visibility: hidden;
    transform: translateX(-50%) translateY(-50%);
    z-index: 9;
    opacity: 0;
    pointer-events: none;
}

.swipe-card img {
    width: 100%;
    position: relative;
}

.swipe-card p {
    margin-top: auto;
}

.swipe-card p::after {
    content: "";
    position: absolute;
    top: -10px;
    left: -10px;
    width: 40px;
    height: 40px;
    background: url(../media/webp/icone-5v.webp) no-repeat;
    background-size: contain;
}

.swipe-card::after {
    position: absolute;
    content: "";
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url(../media/webp/texture2.webp);
    mix-blend-mode: difference;
    opacity: 40%;
}

.swipe-card::before {
    content: "";
    position: absolute;
    z-index: 99;
    top: -10px;
    right: -10px;
    width: 50px;
    height: 50px;
    background: url(../media/webp/icone-3v.webp) no-repeat;
    background-size: contain;
    transform: rotate(12deg);
}

.list-menu:nth-child(2) .swipe-card {
    color: var(--jaune);
    background-color: var(--violet);
}

.list-menu:nth-child(2) .swipe-card::before {
    background: url(../media/webp/icone-3j.webp) no-repeat;
    background-size: contain;
}

.list-menu:nth-child(2) .swipe-card p::after {
    background: url(../media/webp/icone-5j.webp) no-repeat;
    background-size: contain;
}


.shape-background img {
    position: absolute;
    width: 220px;
    opacity: 20%;
    z-index: -1;
}

.shape-background img:nth-child(1) {
    position: absolute;
    width: 300px;
    opacity: 50%;
    top: 20%;
    left: 24%;
}

.shape-background img:nth-child(2) {
    position: absolute;
    width: 300px;
    opacity: 50%;
    bottom: -12%;
    left: 10%;
}

.shape-background img:nth-child(3) {
    position: absolute;
    width: 300px;
    opacity: 50%;
    top: 8%;
    right: 30%;
}

.shape-background img:nth-child(5) {
    position: absolute;
    width: 300px;
    opacity: 50%;
    bottom: 0%;
    right: 10%;
}

.shape-background img:nth-child(4) {
    position: absolute;
    width: 300px;
    opacity: 50%;
    top: 10%;
    left: -5%;
}

.shape-background img:nth-child(6) {
    position: absolute;
    width: 300px;
    opacity: 50%;
    top: 10%;
    right: -5%;
}

.shape-background {
    width: 0;
    height: 0;
}

/*capsule*/

.capsule {
    grid-template-columns: 1fr 3fr;
    grid-template-rows: auto 1fr;
    gap: 2px;
}

.axe-title {
    opacity: 1;
    width: calc(100% - 40px);
    grid-column: 1/3;
    grid-row: 1/2;
    padding: 10px 20px;
    display: grid;
    grid-template-columns: 1fr auto auto;
    font-size: 70px;
    color: var(--violet);
    background-color: var(--jaune);
    align-items: center;
}

.axe-title span {
    font-family: "Luxurious";
    font-size: 100px;
    font-weight: 400;
    margin: 0 20px;
}

.axe-title::before {
    z-index: 100;
    grid-row: 1/2;
    grid-column: 1/2;
    content: "";
    width: 120px;
    height: 120px;
}

.axe1 .axe-title::before {
    background: url(../media/webp/shape_3.webp) no-repeat;
    background-size: contain;
}

.axe2 .axe-title::before {
    background: url(../media/webp/shape_1.webp) no-repeat;
    background-size: contain;
}

.axe3 .axe-title::before {
    background: url(../media/webp/shape_5.webp) no-repeat;
    background-size: contain;
}

.capsule-card {
    opacity: 1;
    height: calc(100% - 40px);
    padding: 20px;
    background-color: var(--violet);
    color: var(--white);
    display: grid;
    grid-template-rows: 1fr auto;
    grid-row: 2/3;
    grid-column: 1/2;
    font-size: 18px;
    line-height: 24px;
}

.capsule-title {
    font-family: "Luxurious";
    font-size: 80px;
    color: var(--jaune);
    font-weight: 500;
    line-height: normal;
}

.video-container {
    position: relative;
    grid-row: 2/3;
    grid-column: 2/3;
    width: 100%;
    height: 100%;
}

.video-container video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 0;
}

.video-controls {
    position: absolute;
    bottom: 0;
    left: 0;
    width: calc(100% - 24px);
    padding: 20px 12px;
    display: flex;
    gap: 8px;
}

.video-controls :nth-child(3) {
    margin-left: auto;
}

.video-controls button {
    width: 40px;
    height: 40px;
    border-radius: 4px;
    border: none;
    background-size: 30px 30px;
    background-position: center;
    background-repeat: no-repeat;
    background-color: var(--jaune);
}

.link-capsule-container {
    position: absolute;
    top: 0px;
    left: 0px;
    display: flex;
    justify-content: center;
    gap: 12px;
    width: calc(100% - 24px);
    padding: 12px;
}

.link-capsule-container a {

    width: 40px;
    height: 40px;
    background-size: 60%;
    background-position: center;
    background-repeat: no-repeat;
    border-radius: 4px;
}

.intro-link {
    background: url(../media/webp/accueil.webp) var(--violet);
}

.previous-link {
    background: url(../media/webp/arrowlj.webp) var(--violet);
}

.next-link {
    background: url(../media/webp/arrowrj.webp) var(--violet);
}

.play-pause {
    background-image: url("../media/webp/play.webp");
}

.play-pause.is-playing {
    background-image: url("../media/webp/pause.webp");
}

.mute {
    background-image: url("../media/webp/volume-enable.webp");
}

.mute.is-muted {
    background-image: url("../media/webp/volume-disable.webp");
}

.fs {
    background-image: url("../media/webp/fullscreen.webp");
}

.fs.is-fullscreen {
    background-image: url("../media/webp/no-fullscreen.webp");
}

.progress-video,
.progress-next-capsule {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    appearance: none;
    border: none;
    background: transparent;
}

.progress-next-capsule {
    z-index: 10;
}

.progress-video::-webkit-progress-bar {
    background: transparent;
}

.progress-video::-webkit-progress-value {
    background: var(--violet);
}

.progress-video::-moz-progress-bar {
    background: var(--violet);
}

.progress-next-capsule::-webkit-progress-bar {
    background: transparent;
}

.progress-next-capsule::-webkit-progress-value {
    background: var(--jaune);
}

.progress-next-capsule::-moz-progress-bar {
    background: var(--jaune);
}

.container-link-capsule {
    position: absolute;
    bottom: 0;
    left: 0;
    width: calc(100% - 24px);
    padding: 32px 12px;
    display: flex;
    gap: 8px;
    justify-content: end;
}

.link-next-capsule {
    padding: 12px 30px;
    display: flex;
    gap: 10px;
    font-family: "Already Broken";
    font-size: 32px;
    color: var(--violet);
    background-color: var(--jaune);
    border-radius: 12px;
    align-items: center;
}

.link-next-capsule:not(section:last-child .link-next-capsule)::after {
    content: "";
    width: 30px;
    height: 30px;
    background: url(../media/webp/play.webp) no-repeat;
    background-size: contain;
}

.replay {
    width: 60px;
    height: 60px;
    border-radius: 12px;
    background: url(../media/webp/replay.webp) var(--jaune) no-repeat;
    background-size: 60%;
    background-position: center;
    border: none;
}

a,
button {
    transition: all 100ms ease-out;
    cursor: pointer;
}

a:not(.link-menu, .nav-episode):hover,
button:hover {
    transform: scale(1.05);
    transition: all 400ms ease-out;
}

.nav-episode:hover {
    transform: translateX(-50%) scale(1.05);
}
.link-menu{
    opacity: 0.7;
    transition: all 600ms ease-out;
}
.link-menu:hover{
    opacity: 1;
}