@import url('https://fonts.googleapis.com/css2?family=Montserrat:ital,wght@0,100..900;1,100..900&family=Orbitron:wght@400..900&display=swap');

/* Reset and base styles */
* {
    box-sizing: border-box;
}

body {
    margin: 0;
    color: #fff;
    font-family: 'Orbitron', sans-serif;
    line-height: 1.6;
}

main {
    margin: -60px auto 0 auto;
    background: linear-gradient(to right, #170c0c 35%, #390a0a 100%);
    padding: 48px 48px 48px 48px;
    display: flex;
    flex-direction: column;
    gap: 48px;
}

.main {
    padding: 4rem 2rem;
}
.h1 {
    color: #FF3B30;
    font-size: 48px;
    font-weight: 700;
    margin-bottom: 40px;
    display: flex;
    align-items: center;
    gap: 15px;
    text-shadow: 0 0 10px rgba(255, 59, 48, 0.3);
}
a.no-style {
  text-decoration: none;
  color: inherit;
}

/******************************* Header *******************************/
.header {
    height: 150px;
    padding: 0 50px;
    background-color: transparent;
    display: flex;
    align-items: center;
    position: absolute;     /* ⬅️ header flottant au-dessus */
    top: 0;
    left: 0;
    width: 100%;
    z-index: 2;
}
.header-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
}
/* Header - Burger menu */
.burger-menu {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 21px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 2001;
    position: relative;
}
.burger-menu span {
    width: 100%;
    height: 3px;
    background-color: #fff;
    border-radius: 3px;
    transition: all 0.3s ease;
    display: block;
}
/* Animation du burger menu */
.burger-menu.active span:nth-child(1) {
    transform: translateY(9px) rotate(45deg);
}
.burger-menu.active span:nth-child(2) {
    opacity: 0;
}
.burger-menu.active span:nth-child(3) {
    transform: translateY(-9px) rotate(-45deg);
}
/* Header - Navigation */
.nav {
    margin: 0 auto;
    right: -100%;
    z-index: 2000;
    filter:
      drop-shadow(1px 0 0 rgba(0,0,0,0.5))
      drop-shadow(-1px 0 0 rgba(0,0,0,0.5))
      drop-shadow(0 1px 0 rgba(0,0,0,0.5))
      drop-shadow(0 -1px 0 rgba(0,0,0,0.5));
}
.nav ul {
    display: flex;
    gap: 3rem;
    list-style: none;
    margin: 0;
    padding: 0;
}
.nav a {
    text-decoration: none;
    color: #ffffff;
    font-weight: 700;
    font-size: 0.95rem;
    text-transform: uppercase;
    position: relative;
    transition: color 0.3s;
}
.nav a::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -5px;
    width: 100%;
    height: 2px;
    background-color: #ffffff;
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.3s ease;
}
.nav a:hover, .nav a.active {
    color: #ff3333;
}
.nav a:hover::after, .nav a.active::after {
    transform: scaleX(1);
}
.nav.active {
    right: 0;
}
/* Header - Dropdown */
.dropdown {
    position: relative;
}
ul.dropdown-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background-color: #0c0c0c;
    border: 1px solid #222;
    list-style: none;
    margin: 0;
    padding: 0.5rem 0;
    min-width: 140px;
    z-index: 10;
}
.dropdown-menu li {
    padding: 0;
}
.dropdown-menu a {
    display: block;
    padding: 0.5rem 1rem;
    color: #ffffff;
    font-size: 0.9rem;
    text-transform: none;
    text-decoration: none;
    transition: background-color 0.2s;
}
.dropdown-menu a:hover {
    background-color: #222;
    color: #ff3333;
}
/* Affiche le sous-menu au survol */
.dropdown:hover .dropdown-menu {
    display: block;
}
.logo-img {
    height: 850px;
    width: auto;
}


/******************************* Footer *******************************/
.footer {
    background-color: #000;
    height: 150px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 2rem;
}
.footer-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    max-width: 1200px;
}
.footer-left {
    display: flex;
    align-items: center;
    gap: 1rem;
    font-size: 1.2rem;
    font-weight: 700;
}
.footer-text {
    font-family: 'Orbitron', sans-serif;
    font-size: 1.6rem;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
}
.footer-right {
    display: flex;
    align-items: center;
    gap: 1rem;
    font-size: 0.95rem;
}
.footer-right a {
    color: #fff;
    text-decoration: none;
}
.footer-right a:hover {
    color: #ff3333;
}
.social-icon {
    width: 50px;
    filter: brightness(0) invert(1); /* icônes blanches */
    transition: opacity 0.2s ease;
}
.social-icon:hover {
    opacity: 0.7;
}


/******************************* Commun *******************************/
.header-edition {
    position: relative;
    height: 500px;
    overflow: hidden;
}
.header-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 120%;
    object-fit: cover;
    transform: translateZ(0);
    will-change: transform;
    background-attachment: fixed;
}
.logo-edition {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    height: 280px;
    width: auto;
    filter:
      drop-shadow(2px 0 0 rgba(255,255,255,0.5))
      drop-shadow(-2px 0 0 rgba(255,255,255,0.5))
      drop-shadow(0 2px 0 rgba(255,255,255,0.5))
      drop-shadow(0 -2px 0 rgba(255,255,255,0.5));
}
.item {
    break-inside: avoid;
    margin-bottom: 10px;
    border-radius: 10px;
    overflow: hidden;
    backdrop-filter: blur(5px);
}
.item img {
    width: 100%;
    display: block;
    border-radius: 10px;
    transition: transform 0.3s ease;
}
.item img:hover {
    transform: scale(1.05);
}
.texte {
    padding: 5rem;
}
.texte h1 {
    font-family: 'Orbitron', sans-serif;
    font-size: 2rem;
}
.masonry {
    column-count: 3;
    column-gap: 10px;
    padding: 50px;
}
.item.texte {
    padding-top: 50px;
    padding-bottom: 10px;
    color: white;
    font-family: 'Montserrat', sans-serif;
    text-align: center;
}
.part {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 10px;
    padding: 20px;
}
.item-part {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 85px;
    height: 60px;
    text-align: center;
}
.item-part img {
    max-height: 50px;
    height: auto;
    width: auto;
}


/******************************* Index *******************************/
.index-bg {
    background: linear-gradient(to bottom, #3C0A0A, #120C0C);
}
.hero {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden;
}
.hero-img {
    width: 100%;
    height: 740px;
    object-fit: cover;
    filter: brightness(0.7);
}
.logo-container {
    position: absolute;
    top: 250px;
    left: 60px;
}
.logo {
    width: 400px;
}
.welcome-section {
    text-align: center;
    margin: 100px 0;
}
.welcome-section h1 {
    color: #bc181d;
    font-size: 2.5rem;
    margin-bottom: 24px;
    font-family: 'Orbitron', sans-serif;
}
.description {
    font-size: 1rem;
    color: #fff;
    margin-bottom: 0;
    line-height: 1.6;
    max-width: 1000px;
    font-weight: 700;
    margin-left: auto;
    margin-right: auto;
    font-family: 'Montserrat', sans-serif;
}
.index-section {
    margin-bottom: 100px;
}

.index-section h2 {
    color: #bc181d;
    font-size: 1.5rem;
    margin-bottom: 24px;
    font-family: 'Orbitron', sans-serif;
}
.index-content {
    display: flex;
    align-items: center;
    gap: 80px;
    justify-content: center;
}
.index-img {
    width: 300px;
    height: 300px;
    object-fit: cover;
    border-radius: 12px;
    text-align: center;
}
.index-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    max-width: 350px;
    font-family: 'Montserrat', sans-serif;
}
.index-info p {
    margin: 110px 0 16px 0;
    font-size: 1.2rem;
}
.index-btn {
    display: inline-block;
    padding: 12px 32px;
    background: transparent;
    border: 2px solid #bc181d;
    color: #fff;
    text-decoration: none;
    font-size: 1.1rem;
    transition: background 0.2s, color 0.2s;
    cursor: pointer;
}
.index-btn:hover {
    background: #bc181d;
    color: #fff;
}
.editions-section {
    margin-bottom: 4rem;
}
.editions-section div {
    text-align: center;
}
.editions-section h2 {
    color: #bc181d;
    font-size: 1.5rem;
    margin-bottom: 24px;
    font-family: 'Orbitron', sans-serif;
    text-align: center;
}
.edition-2025 {
    position: relative;
    display: inline-block;
    break-inside: avoid;
    margin-bottom: 10px;
    border-radius: 10px;
    overflow: hidden;
    backdrop-filter: blur(5px);
}
.edition-2025 img {
    width: 100%;
    display: block;
    border-radius: 10px;
    transition: transform 0.3s ease;
}
.edition-2025 img:hover {
    transform: scale(1.05);
}
.contact-section {
    background-color: #121212;
    text-align: center;
    padding: 150px 0;
}
.contact-section h2 {
    color: #bc181d;
    font-size: 1.5rem;
    font-family: 'Orbitron', sans-serif;
    margin: 0;
}
.separator {
    border: solid #bc181d 1px;
    width: 50px;
    margin-top: 20px;
    margin-bottom: 20px;
}
.contact-lien a {
    text-decoration: none;
    color: #fff;
    font-size: 1.1rem;
    letter-spacing: 2px;
}
.contact-lien a:hover {
    color: #bc181d;
    transition: .2s ease-in;
}


/******************************* CTF *******************************/
.ctf-bg {
    background: linear-gradient(to bottom, #3C0A0A, #120C0C);
}
.header-ctf {
    position: relative;
    padding: 7rem;
    text-align: center;
}
.ctf-section {
    margin-bottom: 4rem;
}
.ctf-section-title {
    font-family: 'Orbitron', sans-serif;
    color: #BC181D;
    font-size: 2rem;
    margin-bottom: 2rem;
    text-align: center;
}
.ctf-content-block {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    gap: 3rem;
    flex-wrap: wrap;
    max-width: 1100px;
    margin: 0 auto;
}
.ctf-column {
    flex-direction: column;
    border-radius: 20px;
}
.challenges {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    margin-top: 1rem;
}
.challenge-item {
    display: flex;
    align-items: center;
    gap: 1rem;
}
.image {
    width: 300px;
    height: 300px;
    object-fit: cover;
    border-radius: 20px;
}
.image-small {
    width: 200px;
    height: 100px;
    border-radius: 12px;
    object-fit: cover;
}
.image-large {
    width: 100%;
    max-width: 1000px;
    height: auto;
    border-radius: 20px;
    object-fit: cover;
    margin-bottom: 2rem;
    display: block;
    margin-left: auto;
    margin-right: auto;
}
.text {
    max-width: 650px;
}
.paragraph {
    font-family: 'Montserrat', sans-serif;
    font-size: 1.05rem;
    line-height: 1.8;
    margin-bottom: 1.5rem;
}
.list {
    font-family: 'Montserrat', sans-serif;
    list-style: none;
    padding-left: 0;
    margin-bottom: 1.5rem;
}
.list li {
    margin-bottom: 1rem;
    padding-left: 1.5rem;
    position: relative;
}
.list li::before {
    content: '•';
    color: #BC181D;
    position: absolute;
    left: 0;
    font-size: 1.2rem;
}
.image:hover, .image-small:hover, .image-large:hover {
  transform: translateY(-1px) scale(1.005);
/*  box-shadow: 0 2px 6px rgba(250, 150, 150, 0.25);*/
}


/******************************* Edition 2022 *******************************/
.ed2022-bg {
    background: rgb(75, 82, 94);
    background: linear-gradient(rgb(75, 82, 94), #000000);
}


/******************************* Edition 2023 *******************************/
.ed2023-bg {
    background: rgb(51, 110, 181);
    background: linear-gradient(rgb(51, 110, 181), #134670);
}


/******************************* Edition 2024 *******************************/
.ed2024-bg {
    background: rgb(75, 201, 212);
    background: linear-gradient(rgb(75, 201, 212), #1770b9);
}


/******************************* Edition 2025 *******************************/
.ed2025-bg {
    background: rgb(28, 17, 4);
    background: linear-gradient(rgb(28, 17, 4), #305919);
}
.ed2025-btn {
    display: inline-block;
    padding: 12px 32px;
    background: transparent;
    border: 2px solid #131313;
    color: #fff;
    text-decoration: none;
    font-size: 1.1rem;
    transition: background 0.2s, color 0.2s;
    cursor: pointer;
    border-radius: 5px;
}
.ed2025-btn:hover {
    background: #131313;
    color: #fff;
}
.masonry2025 {
    column-count: 2;
    column-gap: 10px;
    padding: 50px;
}
.masonry2025-2 {
    column-count: 1;
    column-gap: 10px;
    padding: 50px;
    text-align: center;
}
.item2025 {
    break-inside: avoid;
    margin-bottom: 10px;
    overflow: hidden;
    background: #3e4f0e;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.40);
    text-align: left;
    font-family: 'Montserrat', sans-serif;
}
.item2025-2 {
    break-inside: avoid;
    margin-bottom: 10px;
    overflow: hidden;
    background: #3e4f0e;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.40);
    text-align: center;
    font-family: 'Montserrat', sans-serif;
}
.item2025:hover, .item2025-2:hover {
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 4px 12px rgba(150, 150, 150, 0.25);
}


/******************************* Contact *******************************/
.contact-bg {
    background: #0a0a0a;
    background: linear-gradient(135deg, #0a0a0a 0%, #1a1a1a 100%);
}
.contact-container {
    width: 100%;
    max-width: 1280px;
    margin: 0 auto;
    padding: 40px 20px;
}
.contact-wrapper {
    display: flex;
    justify-content: space-between;
    gap: 60px;
    margin-top: 120px;
    position: relative;
}
.contact-wrapper::before {
    content: '';
    position: absolute;
    top: -20px;
    left: -20px;
    right: -20px;
    bottom: -20px;
    border: 1px solid rgba(255, 59, 48, 0.1);
    border-radius: 10px;
    z-index: -1;
}
.contact-info {
    flex: 1;
    max-width: 600px;
}
.contact-text {
    font-family: 'Montserrat', sans-serif;
    color: white;
    font-size: 20px;
    line-height: 1.6;
}
.highlight-box {
    background: rgba(255, 59, 48, 0.05);
    border-left: 4px solid #FF3B30;
    padding: 20px;
    margin: 20px 0;
    border-radius: 0 5px 5px 0;
}
.emphasis {
    font-size: 24px;
    color: #FF3B30;
    font-weight: 700;
}
.contact-methods {
    margin: 30px 0;
}
.contact-method {
    display: flex;
    align-items: center;
    gap: 15px;
    margin: 15px 0;
    padding: 10px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 5px;
}
.contact-method i {
    color: #FF3B30;
    font-size: 20px;
}
.glow {
    color: #FF3B30;
    text-shadow: 0 0 10px rgba(255, 59, 48, 0.3);
}
.contact-form {
    width: 373px;
    display: flex;
    flex-direction: column;
    gap: 23px;
    background: transparent;
    padding: 50px 0;
    backdrop-filter: none;
}
.input-group {
    position: relative;
}
.input-group i {
    display: none;
}
.contact-form input,
.contact-form textarea {
    width: 373px;
    padding: 15px;
    background: white;
    border: 3.04px solid #FF3B30;
    font-family: 'Orbitron', sans-serif;
    font-size: 24px;
    //color: #DFDFDF;
    color: #333333;
    border-radius: 0;
}
.contact-form textarea {
    height: 251px;
    resize: none;
}
.contact-form input:focus,
.contact-form textarea:focus {
    border-color: #FF3B30;
    background: white;
    outline: none;
    box-shadow: none;
}
.contact-form button {
    background: transparent;
    border: 3.04px solid #FF3B30;
    color: white;
    font-family: 'Orbitron', sans-serif;
    font-size: 31.89px;
    font-weight: 700;
    padding: 30.37px 48.59px;
    cursor: pointer;
    border-radius: 0;
    display: inline-flex;
    justify-content: center;
    align-items: center;
}
.contact-form button:hover {
    background: transparent;
    transform: none;
    box-shadow: none;
}
.contact-form button i {
    display: none;
}


/******************************* Mentions légales - Politique de confidentialité *******************************/
.legal-bg {
    background: linear-gradient(to bottom, #3C0A0A, #120C0C);
}
.legal-container h1 {
    font-family: 'Orbitron', sans-serif;
    font-size: 2.5rem;
    color: #BC181D;
    text-align: center;
    margin-bottom: 30px;
    letter-spacing: 1px;
}
.legal-container h2 {
    font-family: 'Orbitron', sans-serif;
    font-size: 1.6rem;
    color: white;
}
.legal-text p {
    font-family: 'Montserrat', sans-serif;
    font-size: 1rem;
    line-height: 1.7;
    color: #FFFFFF;
}
.legal-text ul {
    font-family: 'Montserrat', sans-serif;
    font-size: 1rem;
    line-height: 1.7;
    color: #FFFFFF;
}
.legal-container {
    max-width: 800px;
    margin: 160px auto 80px;
    padding: 40px;
    background-color: rgba(18, 12, 12, 0.95); /* fond unifié mais opaque */
    border-left: 4px solid #BC181D;
    border-radius: 8px;
    box-shadow: 0 0 15px rgba(188, 24, 29, 0.3);
}




/******************************* Responsive *******************************/
@media (max-width: 768px) {
    .masonry, .masonry2025 {
        column-count: 1;
    }
}

@media (max-width: 768px) {
    .footer {
        padding: 7rem 2rem;
    }
}

/* Media queries pour le header */
@media (max-width: 768px) {
    .header {
        padding: 0 20px;
        height: 100px;
    }

    .header-container {
        position: relative;
    }

    .logo-img {
        height: 60px;
    }

    .burger-menu {
        display: flex;
    }

    .nav {
        position: fixed;
        top: 0;
        right: -100%;
        width: 100vw;
        height: 100vh;
        background-color: rgba(0, 0, 0, 0.95);
        transition: right 0.3s ease;
        display: flex;
        align-items: center;
        justify-content: center;
        z-index: 2000;
    }

    .nav.active {
        right: 0;
    }

    .nav ul {
        flex-direction: column;
        align-items: center;
        gap: 2rem;
    }

    .nav a {
        font-size: 1.2rem;
    }

    .dropdown-menu {
        position: static;
        background: transparent;
        border: none;
        padding: 1rem 0;
        display: none;
    }

    .dropdown.active .dropdown-menu {
        display: block;
    }

    .dropdown-menu li {
        text-align: center;
    }

    .dropdown-menu a {
        padding: 0.5rem 0;
    }

    .footer-container {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }

    .footer-right {
        margin-top: 1rem;
    }
}

@media (min-width: 769px) and (max-width: 1024px) {
    .header {
        padding: 12px 20px;
    }

    .logo-img {
        height: 45px;
    }

    .nav ul {
        gap: 2rem;
    }

    .nav a {
        font-size: 0.85rem;
    }
}

@media (min-width: 1025px) {
    .header {
        padding: 15px 30px;
    }

    .logo-img {
        height: 75px;
    }

    .nav ul {
        gap: 3rem;
    }

    .nav a {
        font-size: 0.95rem;
    }
}

@media (max-width: 768px) {
    .contact-wrapper {
        display: block;
    }
}

@media (max-width: 1024px) {
    .contact-form {
        width: 373px;
        max-width: 373px;
    }

    .contact-form input,
    .contact-form textarea {
        width: 100%;
    }
}


/* --- Responsive design --- */
@media (max-width: 768px) {
    .header-ctf {
        height: 18vh;
        padding: 1rem;
    }

    .title {
        font-size: 2rem;
    }

    .logo-ctf {
        width: 60px;
        height: 60px;
    }

    .image {
        width: 100%;
        height: auto;
    }

    .content-block {
        flex-direction: column;
        align-items: center;
    }

    .text {
        max-width: 100%;
        padding: 0 1rem;
    }
}


/* Ajustement pour les petits écrans (version mobile) */
@media (max-width: 768px) {
    .legal-container {
        padding: 20px; /* Réduit le padding */
        margin: 20px; /* Espace entre la boîte et le bord de l'écran */
    }

    /* Aligne les éléments (image et texte) verticalement dans la section CTF */
    .index-content, .ctf-content {
        flex-direction: column;
        align-items: center; /* Centre horizontalement les éléments */
        gap: 24px; /* Espace entre l’image et le bloc texte/bouton */
    }

    /* Rend l’image responsive en largeur tout en limitant sa taille */
    .index-img, .ctf-img {
        width: 100%;         /* Prend toute la largeur disponible */
        max-width: 300px;    /* Mais ne dépasse pas 300px */
    }

    /* Permet au texte et au bouton d’avoir de l’espace sur les côtés */
    .ctf-info, .index-info {
        max-width: 100%;     /* Prend toute la largeur disponible */
        padding: 0 1rem;     /* Ajoute du padding latéral pour l’aération */
    }

    .editions-gallery {
        flex-direction: column;
        align-items: center;
        gap: 2rem;
    }

    /* Centre les blocs lien (image + texte) */
    .editions-lien {
        display: flex;
        flex-direction: column;
        align-items: center;
        text-align: center;
        width: 90%;              /* Même largeur que l’image */
        max-width: 22rem;        /* Évite qu’elle soit trop large sur écran large */
    }

    .editions-gallery img {
        width: 100%;             /* Prend toute la largeur du bloc parent */
        height: 21.875rem;       /* ~350px */
        object-fit: cover;
        border-radius: 0.75rem;
    }

    .edition-year {
        text-align: center;
    }
}


@media (max-width: 768px) {
    .title {
        font-size: 2rem;
    }

    .logo-edition {
        max-height: 120px;
    }

    .logo {
        width: 240px;
    }

    .content-block {
        flex-direction: column !important;
        align-items: center;
    }

    .image {
        width: 100%;
        height: auto;
        max-width: 400px;
        margin-bottom: 1rem;
    }

    .text {
        max-width: 100%;
        padding: 0 1rem;
    }

    /* Responsive pour les éléments de défis */
    .challenge-item {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .image-small {
        width: 100%;
        height: auto;
        max-width: 300px;
    }
}
