
#index-page .video-background {
	height: 130%;
	width: 100%;
	position: absolute;
	top: 0;
	left: 0;
	z-index: 1;
}

#index-page .video-background video {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

#index-page .parallax__title {
	z-index: 2;
	margin-bottom: 0;
	margin-right: 0;
	font-family: "Hanson", sans-serif;
	font-size: 10vw;
	font-weight: 800;
}

#index-page .parallax__fade {
	--color-dark-rgb: var(--my-white-bg-rgba);
	background: linear-gradient(to top,
		rgba(var(--color-dark-rgb), 1) 0%,
		rgba(var(--color-dark-rgb), 0.738) 19%,
		rgba(var(--color-dark-rgb), 0.541) 34%,
		rgba(var(--color-dark-rgb), 0.382) 47%,
		rgba(var(--color-dark-rgb), 0.278) 56.5%,
		rgba(var(--color-dark-rgb), 0.194) 65%,
		rgba(var(--color-dark-rgb), 0.126) 73%,
		rgba(var(--color-dark-rgb), 0.075) 80.2%,
		rgba(var(--color-dark-rgb), 0.042) 86.1%,
		rgba(var(--color-dark-rgb), 0.021) 91%,
		rgba(var(--color-dark-rgb), 0.008) 93.2%,
		rgba(var(--color-dark-rgb), 0.002) 95.2%,
		transparent 100%);
	z-index: 30;
	object-fit: cover;
	width: 100%;
	max-width: none;
	height: 20%;
	position: absolute;
	bottom: 0;
	left: 0;
}

[data-bs-theme="dark"] #index-page .parallax__fade {
	--color-dark-rgb: var(--my-dark-bg-rgba);
}


#index-page .parallax-item:nth-child(3) {
	min-height: 70vh;
	height: auto;
	z-index: 2;
}

#index-page #header-page > .row,
#index-page > .row {
  position: relative;
  width: 100%;
  max-width: var(--xds-page-max-width);
  margin-inline: auto;
}


@media (max-width: 991.98px) {
	/* Réinitialise la hauteur pour toutes les sections de contenu sur mobile */
	#index-page .parallax-item:nth-child(n+2) {
		min-height: auto;
	}

	/* Section Iframe (2) : On réduit le padding pour éviter l'effet "trop grand" */
	#index-page .parallax-item:nth-child(2) {
		padding-top: 1rem !important;
		padding-bottom: 1rem !important;
	}

	/* Sections Jeux (3), Articles (4), DreamRelax (5) : On aère pour éviter l'effet "serré" */
	#index-page .parallax-item:nth-child(n+3) {
		padding-top: 8rem !important;
        padding-bottom: 6rem !important;
	}
}


/* =============================================
   4. TWITCH ESPACE (Video + Chat)
   ============================================= */
.video-block {
	background-color: #007bff00;
	color: white;
    width: 100%;
}

.chat-block {
	background-color: #ffc10700;
	color: black;
    width: 100%;
    min-height: 24rem;
}

.twitch-button {
	display: none;
}

@media (max-width: 1199.98px) {
  .chat-block {
    display: none !important;
  }

  .chat-block {
    min-height: 30rem;
  }
}

@media (max-width: 767.98px) {
  .chat-block {
    min-height: 22rem;
  }
}

/* Grille adaptative */
.calendar-grid {
    display: grid;
    /* 2 colonnes par défaut (Mobile) */
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
    width: 100%;
}

/* Passage à 7 colonnes sur PC (Largeur > 992px) */
@media (min-width: 992px) {
    .calendar-grid {
        grid-template-columns: repeat(7, 1fr);
        gap: 12px;
    }
}

.day-card {
    border-radius: 8px;
    padding: 10px;
    display: flex;
    flex-direction: column;
    min-height: 90px;
    transition: all 0.2s ease;
}

/* Highlight du jour actuel */
.day-card.today {
    border: 2px solid #7700ff;
    background: #ffffff;
    box-shadow: 0 0 20px rgba(195, 0, 255, 0.25);
    transform: scale(1.03);
    z-index: 2;
}

[data-bs-theme="dark"] .day-card.today {
    background: linear-gradient(160deg, #1f1f23 0%, #2d2d35 100%);
}

.day-card.today .day-name {
    color: #7700ff;
    text-shadow: none;
}

[data-bs-theme="dark"] .day-card.today .day-name {
    color: #ffffff;
    text-shadow: 0 0 10px rgba(132, 0, 255, 0.8);
}

.day-name {
    font-weight: 800;
    font-size: 0.7rem;
    text-transform: uppercase;
    margin-bottom: 6px;
    letter-spacing: 0.5px;
}

.streams-container {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.stream-item {
    /* background défini dynamiquement */
    color: white;
    font-size: 0.7rem;
    font-weight: 600;
    padding: 4px 6px;
    border-radius: 4px;
    line-height: 1.2;
    text-shadow: 0 1px 2px rgba(0,0,0,0.3); /* Pour la lisibilité sur toutes les couleurs */
}

.time-label {
    display: block;
    font-size: 0.65rem;
    opacity: 0.9;
    margin-bottom: 2px;
    border-bottom: 1px solid rgba(255,255,255,0.2);
}

.no-stream {
    font-size: 0.65rem;
    color: #53535f;
    font-style: italic;
    margin-top: auto;
}

/* =============================================
   5. ARTICLES INDEX
   ============================================= */
.index-articles-layer-title {
    justify-content: center;
    align-items: center;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    position: relative;
}

.index-articles-title {
    pointer-events: auto;
    display: inline-block;
    text-align: center;
    text-transform: none;
    margin-top: 0;
    line-height: 0.8;
    margin-right: 0;
    font-family: "Hanson", sans-serif;
    font-size: 15.5vw;
    font-weight: 800;
    position: relative;
}

.index-articles-title-second-part {
    display: inline;
}

.article-floating-subtitle {
    position: static;
    display: block;
    font-family: 'Outfit';
    font-size: clamp(1rem, 1.5vw, 1.35rem);
    font-weight: 500;
    line-height: 1.2;
    text-align: center;
    text-transform: none;
    opacity: 0.92;
}

#index-page .index-articles-shell {
    max-width: min(1180px, 100%);
    margin-inline: auto;
}

#index-page .index-article .row {
    --bs-gutter-x: 1rem;
    --bs-gutter-y: 1rem;
}

@media (max-width: 767.98px) {
    .index-articles-title {
        font-size: 32vw;
    }
    .index-articles-layer-title {
        align-items: flex-start;
        gap: 0.5rem;
    }

    .index-articles-title-second-part {
        display: block;
        margin-top: 0.05em;
    }

    #index-page .index-articles-shell {
        max-width: 100%;
    }
}


#index-page .xds-big-text {
    position: relative;
	font-size: 8vw;
    min-height: 1.5em; /* Un peu plus haut pour voir l'effet */
    overflow: hidden;

    /* Le masque magique : transparent aux bords, noir (opaque) au centre */
    -webkit-mask-image: linear-gradient(
        to bottom,
        transparent 0%,
        black 20%,
        black 80%,
        transparent 100%
    );
    mask-image: linear-gradient(
        to bottom,
        transparent 0%,
        black 20%,
        black 80%,
        transparent 100%
    );
}

@media screen and (max-width: 768px) {
    #index-page .xds-big-text {
        font-size: calc(1.625rem + 3.5vw);
    }
}

#text-container {
    position: relative;
    width: 100%;
    height: 1.2em; /* Doit correspondre à la hauteur du texte */
}

.animated-msg {
    position: absolute;
    width: 100%;
    left: 0;
    top: 0;
    opacity: 0;
    text-align: center;
    /* On ne met pas de transform: translate ici, GSAP s'en chargera */
}

/* --- Jeux du moment (Minimalist) --- */
.scroll-highlight {
    --xds-highlight-scale: 0;
    position: relative;
    display: inline-block;
    isolation: isolate;
}

.scroll-highlight::after {
    content: "";
    position: absolute;
    left: -0.2em;
    right: -0.2em;
    top: 0.01em;
    bottom: 0.05em;
    border-radius: 10px;
    transform: scaleX(var(--xds-highlight-scale));
    transform-origin: left center;
    z-index: -1;
    opacity: 0.95;
}

.scroll-highlight-blue::after {
    background: linear-gradient(90deg, rgba(39, 125, 255, 0.92), rgba(84, 196, 255, 0.88));
    box-shadow: 0 10px 28px rgba(39, 125, 255, 0.28);
}

.scroll-highlight-dreamrelax::after {
    background: linear-gradient(90deg, rgba(41, 214, 118, 0.92), rgba(189, 255, 84, 0.88));
    box-shadow: 0 10px 28px rgba(41, 214, 118, 0.28);
}

.card-moment {
    position: relative;
    overflow: hidden;
    cursor: default;
    border-radius: var(--border-radius-20);
}


.card-moment:hover {
    z-index: 2;
}

.card-moment-image-wrapper {
    position: relative;
    width: 100%;
    padding-top: 133.33%; /* Ratio 3:4 (Format Twitch) */
}

.card-moment img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}


.card-moment .game-info {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 1.5rem 1rem 1rem;
    background: linear-gradient(transparent,rgba(0,0,0,.8));
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.3s ease;
    text-align: center;
}

.card-moment:hover .game-info {
    opacity: 1;
    transform: translateY(0);
}


/* --- DreamRelax Index --- */
.dr-section-container {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100dvh;
    overflow: visible;
}

.dr-images-layer {
    left: 50%;
    width: min(140vw, calc(100% + 22rem));
    max-width: none;
    transform: translateX(-50%);
    pointer-events: none;
}

/* Logos (Stickers) */
.dr-logo-link {
    position: relative;
    z-index: 10;
    display: flex;
    width: 100%;
    justify-content: center;
    align-items: center;
    padding-inline: clamp(4px, 1vw, 12px);
    transition: transform 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}
.dr-logo-img {
    width: min(100%, 460px);
    max-height: 180px;
    height: auto;
    object-fit: contain;
    object-position: center;
}
.dr-logo-link:hover {
    transform: scale(1.02) !important;
}

/* Images éparpillées (Scatter) */
.dr-scatter-item {
    position: absolute;
    top: calc(var(--scatter-top, 50) * 1%);
    left: calc(var(--scatter-left, 50) * 1%);
    z-index: 1;
    transform: translate(-50%, -50%);
    transform-origin: center;
    will-change: transform;
}

.dr-scatter-item.is-visible {
    animation: dr-scatter-float var(--dr-float-duration, 14s) ease-in-out infinite;
    animation-delay: calc(var(--dr-float-delay, 0s) * -1);
}

.dr-scatter-img {
    display: block;
    width: var(--scatter-size, 180px);
    height: auto;
    box-shadow: var(--xds-shadow);
    border-radius: var(--border-radius-10);
    object-fit: cover;
    transition: opacity 0.6s ease, filter 0.6s ease;
    opacity: 0;
    filter: grayscale(0.4);
    transform: rotate(calc(var(--scatter-rot, 0) * 1deg)) scale(0.68);
    transform-origin: center;
    will-change: transform, opacity;
}

.dr-scatter-item.is-visible .dr-scatter-img {
    animation: dr-scatter-pop var(--dr-pop-duration, 480ms) cubic-bezier(0.2, 0.9, 0.25, 1.35) forwards;
    animation-delay: var(--dr-pop-delay, 0ms);
}

@keyframes dr-scatter-pop {
    0% {
        opacity: 0;
        transform: rotate(calc(var(--scatter-rot, 0) * 1deg)) scale(0.68);
    }
    72% {
        opacity: 0.78;
        transform: rotate(calc((var(--scatter-rot, 0) * 1deg) + 1.4deg)) scale(1.08);
    }
    100% {
        opacity: 0.7;
        transform: rotate(calc(var(--scatter-rot, 0) * 1deg)) scale(1);
    }
}

@keyframes dr-scatter-float {
    0%, 100% {
        transform: translate(-50%, -50%);
    }
    50% {
        transform: translate(calc(-50% + var(--dr-drift-x, 10px)), calc(-50% + var(--dr-drift-y, -8px)));
    }
}

/* Info bulle */
.dr-info {
    position: absolute;
    bottom: -50px;
    left: 50%;
    transform: translateX(-50%) translateY(10px);
    opacity: 0;
    transition: all 0.5s ease;
    white-space: nowrap;
    pointer-events: none;
    z-index: 30;
}
.dr-logo-link:hover .dr-info {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

@media (max-width: 991.98px) {
    .dr-section-container { min-height: auto; padding: 50px 0; }
    .dr-images-layer { width: min(155vw, calc(100% + 8rem)); }
    .dr-col:nth-child(n) .dr-logo-link { transform: none; margin-bottom: 2rem; }
    .dr-logo-img { width: min(92vw, 480px); max-width: 280px; }
    .dr-scatter-img { width: min(var(--scatter-size, 180px), 130px); opacity: 0.5; }
    .dr-images-layer .dr-scatter-item[data-mobile-visible="false"] { display: none; }
    .scroll-highlight::after {top: -0.1em;}
}

@media (prefers-reduced-motion: reduce) {
    .dr-scatter-item,
    .dr-scatter-img {
        animation: none;
    }

    .dr-scatter-img {
        opacity: 0.7;
        transform: rotate(calc(var(--scatter-rot, 0) * 1deg)) scale(1);
    }
}

/* Liens vers les profils dans la modale SDR */
.participant-link {
    color: inherit;
    text-decoration: none;
    border-bottom: 1px dotted rgba(255,255,255,0.5);
    transition: all 0.2s ease;
}
.participant-link:hover {
    color: var(--bs-primary) !important;
    border-bottom-color: var(--bs-primary);
}

#index-page .index-twitch-block {
    position: relative;
}

#index-page .index-marquee-bridge {
    position: absolute;
    left: 50%;
    width: 100vw;
    transform: translateX(-50%);
    bottom: -13rem;
    z-index: -1;
    pointer-events: none;
}

#index-page .index-planning-block {
    position: relative;
    z-index: 2;
    margin-top: 0.75rem;
}

#index-page .box_alert_text {
    position: relative;
    z-index: 1;
}
