html,
body,
#q-app {

    margin: 0;

    width: 100%;
    min-height: 100%;

    background: #06101c;

    font-family:
        "Segoe UI",
        Arial,
        sans-serif;
}


body {

    overflow-x: hidden;

}


.q-page {

    min-height: 100vh !important;

}


/* ========================================
   PAGE
======================================== */

.fdra-page {

    position: relative;

    width: 100vw;
    min-height: 100vh;

    overflow: hidden;

    color: #f8fafc;

    /* Fond officiel de l'accueil */
    background-color: #06101c;
    background-image: url('/assets/ui/home_background.png');
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;

}


/* ========================================
   REFLET HAUT GAUCHE
======================================== */

.top-left-glow {

    position: absolute;

    left: -120px;
    top: -170px;

    width: 560px;
    height: 500px;

    border-radius: 50%;

    background:

        radial-gradient(
            circle,
            rgba(82, 139, 232, 0.17),
            transparent 66%
        );

    filter: blur(22px);

    pointer-events: none;

}


/* ========================================
   LOGO FDRA
======================================== */

.logo-glow {

    position: absolute;

    right: 1.2vw;
    top: -3vh;

    width: 460px;
    height: 350px;

    background:

        radial-gradient(
            ellipse at 52% 45%,
            rgba(70, 145, 255, 0.38) 0%,
            rgba(48, 105, 210, 0.20) 32%,
            rgba(25, 70, 150, 0.08) 52%,
            transparent 72%
        );

    filter: blur(22px);

    pointer-events: none;

    z-index: 1;
}


.fdra-logo {
    position: absolute;

    right: 2.5vw;
    top: 1.5vh;

    width: clamp(310px, 24vw, 390px);

    z-index: 2;

    filter:
        drop-shadow(0 0 7px rgba(100, 175, 255, 0.55))
        drop-shadow(0 0 18px rgba(65, 125, 255, 0.35))
        drop-shadow(0 0 32px rgba(40, 90, 190, 0.20));
}


/* ========================================
   HÉLICE GAUCHE
======================================== */

.ghost-propeller {

    position: absolute;

    left: -150px;
    bottom: -35px;

    width: 650px;

    /*
       Important :
       l'asset reste intact.
       On baisse seulement sa visibilité.
    */

    opacity: 0.15;

    pointer-events: none;

    z-index: 1;

}


/* ========================================
   TITRE FDRA CHAMPIONSHIP MANAGER
======================================== */

.brand-block {
    position: absolute;

    top: 10vh;
    left: 2.5vw;

    gap: 8px !important;

    z-index: 3;
}


.fdra-title {
    display: block;

    width: clamp(
        700px,
        67vw,
        1060px
    );

    height: auto;

    object-fit: contain;
    object-position: left center;
}


/* Sous-titre */

.brand-subtitle {
    margin-left: 10vw;
    margin-top: 0;

    font-size: clamp(
        18px,
        1.55vw,
        25px
    );

    color: #8197c1;

    font-weight: 500;
}


/* ========================================
   ZONE CHOIX RÔLE
======================================== */

.role-area {

    position: absolute;

    top: 35vh;

    left: 50%;

    transform:
        translateX(-50%);

    width: min(
        800px,
        65vw
    );

    gap: 14px !important;

    z-index: 4;

}


/* Choisissez votre rôle */

.choice-title {

    font-size: clamp(
        40px,
        3.25vw,
        54px
    );

    line-height: 1.05;

    font-weight: 750;

    color: #f8fafc;

}


/* Sélectionnez votre profil */

.choice-subtitle {

    margin-top: 2px;
    margin-bottom: 20px;

    font-size: clamp(
        16px,
        1.35vw,
        21px
    );

    color: #91aad5;

}


/* ========================================
   BOUTONS RÔLES
======================================== */

.role-card {

    position: relative;

    box-sizing: border-box;

    width: 100%;

    min-height: 130px;

    border:

        1px solid
        rgba(
            100,
            143,
            202,
            0.42
        );

    border-radius: 14px;

    background:

        linear-gradient(
            105deg,
            rgba(20, 38, 65, 0.76),
            rgba(9, 22, 39, 0.64)
        );

    box-shadow:

        inset
        0 1px 0
        rgba(255,255,255,0.025);

    backdrop-filter: blur(9px);

    overflow: hidden;

    cursor: pointer;

    transition:

        transform 0.20s ease,
        border-color 0.20s ease,
        box-shadow 0.20s ease;

}


/* Survol */

.role-card:hover {

    transform:
        translateY(-2px);

    border-color:

        rgba(
            93,
            157,
            255,
            0.82
        );

    box-shadow:

        0 0 22px
        rgba(
            43,
            112,
            220,
            0.20
        ),

        inset
        0 1px 0
        rgba(
            255,
            255,
            255,
            0.04
        );

}


/* ========================================
   LISERÉ BLEU AU SURVOL
======================================== */

.hover-line {

    position: absolute;

    left: 0;
    top: 18%;

    width: 4px;
    height: 64%;

    border-radius:
        0 5px 5px 0;

    background:

        linear-gradient(
            #7ec2ff,
            #317cff
        );

    opacity: 0;

    transform:
        scaleY(0.35);

    transition:

        opacity 0.20s ease,
        transform 0.20s ease;

}


.role-card:hover
.hover-line {

    opacity: 1;

    transform:
        scaleY(1);

}


/* ========================================
   CONTENU CARTE
======================================== */

.role-content {

    box-sizing: border-box;

    width: 100%;

    min-height: 130px;

    padding:
        17px 34px;

    gap: 24px !important;

}


/* ========================================
   PICTOGRAMMES
======================================== */

.role-icon {
    display: block;

    width: 96px;
    height: 96px;

    min-width: 96px;

    object-fit: contain;

    filter:
        drop-shadow(
            0 0 8px
            rgba(255, 70, 70, 0.20)
        );
}


/* séparateur vertical */

.role-separator {

    width: 1px;
    height: 82px;

    background:

        rgba(
            135,
            160,
            198,
            0.46
        );

}


/* ========================================
   TEXTE RÔLE
======================================== */

.role-text {

    gap: 1px !important;

}


.role-title {

    font-size: clamp(
        28px,
        2.15vw,
        36px
    );

    line-height: 1.1;

    font-weight: 700;

    color: #ff9696;

}


.role-description {

    font-size: clamp(
        16px,
        1.30vw,
        20px
    );

    color: #8faee8;

}


/* ========================================
   FLÈCHE
======================================== */

.chevron {

    padding-right: 4px;

    font-size: 58px;

    line-height: 1;

    font-weight: 200;

    color: #ff535b;

}


/* ========================================
   VERSION
======================================== */

.version {

    position: absolute;

    bottom: 4vh;
    left: 50%;

    transform:
        translateX(-50%);

    font-size: 17px;

    color: #8da2c8;

    z-index: 5;

    white-space: nowrap;

}


.version-fd {

    color: #2789ff;

}


.version-ra {

    color: #ef3544;

}


.version-number {

    color: #5598ff;

}


/* ========================================
   RESPONSIVE
======================================== */

@media (
    max-width: 900px
) {

    .fdra-logo {

        width: 175px;

        right: 15px;

        top: 10px;

    }


    .brand-block {

        top: 115px;

        left: 22px;

        right: 22px;

    }


    .fdra-title {

        width: 95vw;

    }


    .brand-subtitle {

        margin-left: 0;

    }


    .role-area {

        top: 330px;

        width:
            calc(
                100vw - 36px
            );

    }


    .ghost-propeller {

        width: 340px;

        left: -90px;

    }


    .role-content {

        padding:
            14px 18px;

        gap:
            14px !important;

    }


    .role-icon {

        width: 68px;
        height: 68px;

        flex-basis:
            68px;

    }


    .role-separator {

        height: 65px;

    }


    .version {

        position: fixed;

        bottom: 10px;

        font-size: 14px;

    }

}

/* ========================================
   ACCUEIL 3 PROFILS — V1.8.1b
   Organisateur + Pilote / Club centré
   ======================================== */

.role-area {
    top: 36vh;
    width: min(920px, 72vw);
    gap: 10px !important;
}

.role-top-row {
    width: 100%;
    gap: 16px !important;
}

.role-top-row > .role-card {
    width: calc(50% - 8px);
}

.role-club-row {
    width: 100%;
    margin-top: 18px;
}

.role-club-row > .role-card {
    width: calc(50% - 8px);
}

.role-card {
    min-height: 104px;
}

.role-content {
    min-height: 104px;
    padding: 12px 22px;
    gap: 16px !important;
}

.role-icon {
    width: 76px;
    height: 76px;
    min-width: 76px;
}

.role-separator {
    height: 64px;
}

.role-title {
    font-size: clamp(23px, 1.7vw, 30px);
}

.role-description {
    font-size: clamp(14px, 1.05vw, 17px);
}

.chevron {
    font-size: 46px;
}

/* Damier désormais intégré à home_background.png */


/* La version reste dégagée sous les cartes */
.version {
    bottom: 2.5vh;
}

@media (max-width: 900px) {
    .role-area {
        top: 330px;
        width: calc(100vw - 36px);
        padding-bottom: 80px;
    }

    .role-top-row {
        flex-direction: column !important;
        gap: 10px !important;
    }

    .role-top-row > .role-card,
    .role-club-row > .role-card {
        width: 100%;
    }

    .role-card,
    .role-content {
        min-height: 92px;
    }

    .role-content {
        padding: 10px 16px;
        gap: 12px !important;
    }

    .role-icon {
        width: 62px;
        height: 62px;
        min-width: 62px;
    }

    .role-separator {
        height: 56px;
    }
}

/* v2.1.9a4 : accueil en flux, sans décalage du conteneur NiceGUI. */
.fdra-home-container {padding:0 !important;gap:0 !important;width:100%;min-width:0}
.fdra-page {width:100%;box-sizing:border-box;display:flex;flex-direction:column;align-items:center;padding-bottom:24px}
.brand-block {position:relative;top:auto;left:auto;align-self:flex-start;margin:10vh 2.5vw 0;max-width:95%}
.fdra-title {max-width:100%}
.role-area {position:relative;top:auto;left:auto;transform:none;width:min(1040px,92vw);margin:64px auto 32px;flex-shrink:0}
.role-club-row {margin-top:6px}
.role-text {min-width:0;flex:1}
.role-separator {flex-shrink:0}
.version {position:relative;bottom:auto;left:auto;transform:none;margin: auto 16px 0;padding-top:16px;white-space:normal;text-align:center}
@media(max-width:900px) {
  .fdra-page {min-height:100svh;padding:0 18px 24px}
  .fdra-logo {width:175px;right:18px;top:10px}
  .brand-block {align-self:stretch;margin:115px 0 0;max-width:100%;gap:8px !important}
  .fdra-title {width:100%;max-width:100%}
  .brand-subtitle {margin:0;text-align:center;font-size:clamp(16px,3.5vw,22px)}
  .role-area {width:100%;max-width:620px;margin:32px auto 24px;padding:0;gap:10px !important}
  .choice-title {font-size:clamp(28px,7vw,40px);text-align:center}
  .choice-subtitle {margin:0 0 14px;text-align:center;font-size:16px}
  .role-top-row {gap:10px !important}
  .role-club-row {margin:0}
  .role-content {gap:10px !important;padding:10px 12px}
  .role-icon {width:54px;height:54px;min-width:54px;flex-basis:54px;flex-shrink:0}
  .role-title {font-size:clamp(20px,5.5vw,28px)}
  .role-description {font-size:14px;overflow-wrap:anywhere}
  .chevron {font-size:36px;padding:0}
  .role-content > .q-space {display:none}
  .version {position:relative;bottom:auto;font-size:13px;padding-top:12px}
}

/* Sous-titre centré sur toute la largeur, avec retour à la ligne sur petit écran. */
.brand-subtitle {box-sizing:border-box;width:100%;max-width:100%;min-width:0;margin:0;padding:0 8px;text-align:center;white-space:normal;overflow-wrap:anywhere;align-self:stretch}

/* Accueil adaptable : un seul défilement, signature comprise dans la hauteur. */
.fdra-home-container{min-height:100vh;min-height:100svh;display:flex;flex-direction:column;overflow:visible !important}
.fdra-home-container .fdra-page{flex:1 0 auto;width:100%;min-height:0;overflow:visible;overflow:clip;overflow-clip-margin:0;padding:0 24px 18px}
.fdra-home-container .brand-block{align-self:flex-start;width:min(68%,900px);max-width:100%;margin:clamp(24px,7vh,64px) 0 0;gap:8px !important}
.fdra-home-container .fdra-title{width:100%;min-width:0;max-width:100%}
.fdra-home-container .brand-subtitle{font-size:clamp(15px,1.3vw,21px);line-height:1.4}
.fdra-home-container .fdra-logo{top:12px;right:24px;width:clamp(150px,19vw,280px)}
.fdra-home-container .role-area{width:min(980px,100%);margin:clamp(24px,5vh,48px) auto 20px;padding:0;gap:10px !important}
.fdra-home-container .choice-title{font-size:clamp(28px,3.1vw,44px);text-align:center}
.fdra-home-container .choice-subtitle{margin:0 0 10px;text-align:center;line-height:1.4}
.fdra-home-container .role-club-row{margin:0}
.fdra-home-container .version{margin:0 0 0;padding-top:8px;font-size:14px;line-height:1.5}
.fdra-home-container .team-signature{margin-top:0}
/* Les décorations restent recadrées, sans créer de conteneur déroulant. */
@media(max-width:900px){
 .fdra-home-container .fdra-page{padding:0 16px 16px}
 .fdra-home-container .fdra-logo{position:relative;align-self:flex-end;top:auto;right:auto;width:clamp(100px,24vw,160px);margin:10px 0 8px}
 .fdra-home-container .brand-block{align-self:stretch;width:100%;margin:0;gap:6px !important}
 .fdra-home-container .role-area{width:100%;max-width:620px;margin:20px auto 16px}
 .fdra-home-container .choice-title{font-size:clamp(26px,6vw,36px)}
 .fdra-home-container .choice-subtitle{font-size:15px;margin-bottom:8px}
 .fdra-home-container .role-card,.fdra-home-container .role-content{min-height:80px}
 .fdra-home-container .role-icon{width:48px;height:48px;min-width:48px;flex-basis:48px}
 .fdra-home-container .role-separator{height:48px}
 .fdra-home-container .role-title{font-size:clamp(20px,4.8vw,26px)}
 .fdra-home-container .role-description{font-size:13px;line-height:1.4}
 .fdra-home-container .version{font-size:12px}
}
@media(min-width:901px) and (max-height:700px){
 .fdra-home-container .brand-block{margin-top:20px}
 .fdra-home-container .fdra-logo{width:170px}
 .fdra-home-container .role-area{margin:24px auto 14px;gap:8px !important}
 .fdra-home-container .choice-title{font-size:32px}
 .fdra-home-container .role-card,.fdra-home-container .role-content{min-height:88px}
 .fdra-home-container .role-icon{width:58px;height:58px;min-width:58px}
}
