html,
body {
    height: 100%;
    margin: 0;
    font-family: 'Inter', sans-serif;
    box-sizing: border-box;
    scrollbar-color: transparent transparent;
    overflow-x: hidden;
    word-wrap: break-word;
    overflow-wrap: break-word;
    background-color: var(--secondary-color);
    overflow: hidden;
}

.fontmedium {
    font-weight: lighter;
}

.container {
    display: flex;
    height: 93%;
    overflow: hidden;
}

.profilehr {
    border: 0.5px solid var(--secondary-color); 
}

.scrollhr {
    border: 1px solid var(--primary-color); 
    margin-top: 15px; 
    margin-bottom: 15px;
    width: 90%;
}

.scrolldiv {
    background-color: var(--secondary-color);
    scrollbar-color: rgb(109, 109, 109) var(--secondary-color);
    color: var(--third-color);
    height: 100%;
    width: 20%;
    min-width: 300px;
    overflow-y: scroll;
    font-weight: 300;
    scrollbar-gutter: stable;
}

.profile-circle {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    object-fit: cover;
    display: inline-block;
    justify-content: center;
    align-items: center;
}

.profile-container {
    width: 30px;
    display: inline-block;
    position: absolute;
    right: 20px;
    top: 20px;
    justify-content: center;
    cursor: pointer;
}

.user_container {
    position: relative;
}

.floating-div {
    position: absolute;
    box-sizing: border-box;
    top: 100%;
    right: 0;
    width: 150px;
    height: 100px;
    background-color: var(--primary-color);
    border: 1px solid var(--secondary-color);;
    border-radius: 5px;
    z-index: 1000;
    /* Ensures it stays on top if needed */
}



.topbar {
    background-color: var(--secondary-color);
    color: var(--third-color);
    height: 40px;
    width: 100%;
    overflow-y: unset;
    overflow-x: unset;
    display: inline-block;
}

.login-container {
    display: inline-block;
    justify-content: center;
    align-items: center;
    height: 100vh;
    background-color: transparent;
    position: absolute;
    right: 20px;
    height: 60px;
    top: 25px;
}

.login {
    height: 35px;
    width: 90px;
    background-color: var(--primary-color);
    border-radius: 6px;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    color: var(--third-color);
    font-size: 14px;
}

.assistantdiv {
    height: 100%;
    width: 60%;
    position: relative;
}

.aidiv {
    background-color: var(--secondary-color);
    scrollbar-color: rgb(109, 109, 109) var(--secondary-color);
    border-color: var(--sixth-color);
    height: 80%;
    width: 100%;
    min-width: 300px;
    overflow-y: scroll;
    overflow-x: hidden;
    font-weight: 300;
    scrollbar-gutter: stable;
    position: relative;
    display: flex;
    flex-direction: column;
    padding-top: 20px;
}

.message {
    display: flex;
    flex-direction: column;
    margin: 10px;
    font-size: 12px;
    max-width: 100%;
    white-space: normal;
    overflow-wrap: break-word;
}

.role {
    color: var(--third-color);
    font-size: 12px;
    font-weight: 500;
    margin-bottom: 4px;
    opacity: 0.8;
}

.bubble {
    background-color: var(--primary-color);
    border-radius: 8px;
    color: var(--primary-color);
    padding: 0px;
    white-space: pre-wrap;
    line-height: 1.4;
    word-wrap: break-word;
}

.message.ai {
    align-self: flex-start;
    text-align: left;
}

.message.user {
    align-self: flex-end;
    text-align: right;
}

.message.ai .bubble {
    background-color: transparent;
    color: var(--third-color);
}

.message.user .bubble {
    background-color: var(--primary-color);
    color: var(--third-color);
}

.messageInput {
    background-color: var(--secondary-color);
    border: none;
    border-top: 2px solid var(--sixth-color);
    position: relative;
    box-sizing: border-box;
    bottom: 0;
    resize: none;
    color: var(--third-color);
    font-size: 14px;
    padding: 10px;
    height: 20%;
    width: 100%;
    outline: none;
    box-shadow: none;
}

.icon-container {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 5px;
    border-radius: 5px;
    background-color: var(--fifth-color);
    margin-top: 10px;
    margin-left: 10px;
    width: 70px;
    height: 30px;
}

.icon {
    width: 28px;
    height: 23px;
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s;
}

.typing-indicator {
    width: 12px;
    height: 12px;
    background-color: #e0e5ff;
    margin-top: 10px;
    border-radius: 50%;
    animation: pulse 1.5s infinite;
}

.bubbleresponse {
    background: #f0f0f0;
}


@keyframes pulse {

    0%,
    100% {
        transform: scale(1);
        opacity: 0.8;
    }

    50% {
        transform: scale(1.5);
        opacity: 1;
    }
}

.ai-close-button {
    position: absolute;
    top: 10px;
    /* Add spacing from the top */
    left: 10px;
    /* Add spacing from the left */
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    color: var(--third-color);
    background: none;
    border: none;
    padding: 5px 10px;
    /* Optional padding for click area */
    line-height: 1;
    z-index: 10;
    /* Ensure it's above other content */
}


.button-50 {
    appearance: button;
    background-color: var(--primary-color);
    background-image: none;
    border: 1px solid var(--primary-color);
    border-radius: 4px;
    box-shadow: var(--secondary-color) 1px 1px 0 0, var(--secondary-color)1px 1px 0 1px;
    box-sizing: border-box;
    color: var(--third-color);
    cursor: pointer;
    display: inline-block;
    font-family: ITCAvantGardeStd-Bk, Arial, sans-serif;
    font-size: 14px;
    font-weight: 400;
    text-align: center;
    margin: 0 5px 10px 0;
    overflow: visible;
    padding: 12px 40px;
    text-align: center;
    text-transform: none;
    touch-action: manipulation;
    user-select: none;
    -webkit-user-select: none;
    vertical-align: middle;
    white-space: nowrap;
    width: 150px;
    height: 40px;
}

.button-50:focus {
    text-decoration: none;
}

.button-50:hover {
    text-decoration: none;
}

.pdf-container {
    width: 100%;
    height: 100vh;
}

.button-50:active {
    box-shadow: var(--sixth-color) 0 3px 5px inset;
    outline: 0;
}

.button-50:not([disabled]):active {
    box-shadow: var(--sixth-color) 2px 2px 0 0, var(--sixth-color) 2px 2px 0 1px;
    transform: translate(2px, 2px);
}

.scrolldivtest {
    background-color: var(--secondary-color);
    scrollbar-color: transparent transparent;
    color: var(--third-color);
    height: 240px;
    width: 100%;
    overflow-y: hidden;
    overflow-x: hidden;
    text-align: center;
    font-weight: 300;
    scrollbar-gutter: stable;
}

.main {
    color: var(--third-color);
    background: var(--primary-color);
    scrollbar-color: rgb(109, 109, 109) rgb(32, 32, 34);
    border: 1px solid var(--sixth-color);
    padding: 20px;
    margin: 20px;
    margin-top: 0px;
    border-radius: 10px;
    overflow-y: scroll;
    overflow-x: hidden;
}

.title {
    display: flex; 
    align-items: center;
    font-weight: 700;
    font-size: 22px;
    margin-top: 20px;
    margin-bottom: 1px;
    margin-left: 25px;
    width: 300px;
}

.scrolltitle {
    font-weight: 700;
    font-size: 22px;
    margin-bottom: 15px;
}

.scroll_filliere {
    font-size: 16px;
    margin-bottom: 1px;
}

.ai_assistant_div {
    padding: 5px 10px;
    background-color: var(--third-color);
    color: var(--primary-color);
    font-family: Arial, sans-serif;
    font-size: 10px;
    font-weight: bold;
    border-radius: 8px;
    text-transform: lowercase;
}

.link,
.ai_assistant {
    text-decoration: none;
    font-size: 15px;
    display: inline-block;
    margin-bottom: 2px;
    margin-top: 2px;
    color: var(--third-color);
}

.alink {
    color: rgb(180, 114, 114);
}

.module_title {
    margin-left: 5px;
    font-size: 14px;
    text-decoration: none;
    color: var(--third-color);
    display: inline-flex;
    margin-bottom: 8px;
}

.module_name {
    margin-left: 6px;
    color: rgb(106, 106, 106);
}

.semestre,
.tronc_commun {
    font-size: 14px;
    text-decoration: none;
    color: var(--third-color);
    display: block;
    margin-bottom: 8px;
}

a,
u {
    text-underline-offset: 3px;
}

li {
    margin-top: 8px;
    font-size: 14px;
}

.line_divider {
    width: 100%;
    border: 0.1px solid var(--forth-color);
    margin-top: 15px;
    margin-bottom: 15px;
}

.code {
    background-color: var(--code-color);
    border: 1px solid var(--sixth-color);
    padding: 5px 7px 5px 8px;
    display: inline-block;
    word-wrap: break-word;
    overflow-wrap: break-word;
    min-width: 100%;
    box-sizing: border-box;

}

.codecomment {
    background-color: var(--code-coment-color);
    border-style: solid;
    display: inline-block;
    border-color: var(--sixth-color);
    color: var(--third-color);
    border-width: 1px;
    padding: 2px;
}

.color_preprocessor {
    color: #F07B72;
}

.color_type {
    color: #F07B72;
}

.color_function {
    color: #D2A8FF;
}

.color_punctuation {
    color: #A5D6FF;
}

.color_literal {
    color: #A5D6FF;
}

.color_operator {
    color: #F07B72;
}

.color_keyword {
    color: #F07B72;
}

.color_string {
    color: #A5D6FF;
}

.color_tag {
    color: #569CD6;
}

.color_attribut {
    color: #7CDCDA
}

.color_attributstring {
    color: #CE9178;
}

.color_arrow {
    color: #80807A;
}

.color_comment {
    color: #6a9956;
}

/* Initialize main counter */
.enumerate-list {
    counter-reset: section;
}

.enumerate-list>li {
    counter-increment: section;
    list-style-type: none;
}

.enumerate-list>li::before {
    content: counter(section) ". ";
}

/* Second level counter */
.enumerate-list ol {
    counter-reset: subsection;
}

.enumerate-list ol>li {
    counter-increment: subsection;
    list-style-type: none;
}

.enumerate-list ol>li::before {
    content: counter(section) "." counter(subsection) ". ";
}

/* Third level counter */
.enumerate-list ol ol {
    counter-reset: subsubsection;
}

.enumerate-list ol ol>li {
    counter-increment: subsubsection;
    list-style-type: none;
}

.enumerate-list ol ol>li::before {
    content: counter(section) "." counter(subsection) "." counter(subsubsection) ". ";
}

:root {
    --primary-color: #1e1f1f;
    --secondary-color: #121212;
    --third-color: #fff;
    --forth-color: rgba(215, 215, 215, 0.674);
    --fifth-color: #151515;
    --sixth-color: rgb(44, 44, 44);
    --code-color: #0D1117;
    --code-coment-color: #171717;
}

.white-theme {
    --primary-color: #e7e7e7;
    --secondary-color: #d6d6d6;
    --third-color: #464646;
    --forth-color: rgba(0, 0, 0, 0.674);
    --fifth-color: rgba(215, 215, 215, 0.674);
    --sixth-color: rgb(198, 198, 198);
    --code-color: rgb(255, 255, 255);
    --code-coment-color: rgb(196, 196, 196);
}

:root{
    --shadowColor : #B47272; 
}
h2{
    color: gray;
}
.login{
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 0 10px;
    transition: 0.2s;
    border: 2px solid white;
    color: white;
}
.login:hover{
box-shadow: 0 0 12px rgba(255, 255, 255, 0.549);
}
.login i{
    font-size: 20px;
}

.mainListe li a{
    text-decoration: none;
    padding: 2px 0;
    position: relative;
}
.mainListe li{
    list-style: none;
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--shadowColor);
}
.mainListe li a::after{
    content: " ";
    position: absolute;
    left: 0;
    bottom: 0;
    height: 2px;
    background-color: var(--shadowColor);
    width: 0;
    transition: 0.4s;
}
.mainListe li a:hover::after{
    width: 100%;
}

.mainListe li i{
    animation: mouve 0.5s linear infinite alternate-reverse;
}


/*assistant ai*/
.aidiv{
    padding: 0;
    border: 2px gray solid;
    border-bottom: none;
    margin-top: 10px;
    margin-left: 10px;
    border-radius: 8px 8px 0 0;
    overflow: auto;
    width: 96%;
    background-color: transparent;

}
.aiTitle{
    display: flex;
    align-items: center;
    justify-content: space-around;
}

.aiTitle .ai-close-button{
    font-size: 15px;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    cursor: pointer;
    color: white;
    font-size: 22px;
    border-radius: 100%;
    transition: 0.2s;
}
.aiTitle .ai-close-button:hover{
    box-shadow: 0 0 6px var(--shadowColor);
}
.titleBox{
    width: 65%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
}
.aiTitle h4{
    color: white;
    margin-top: 10px;
}
.aiTitle span{
    color: gray;
    font-size: 14px;
}
/*message input*/
.inputContainer{
    margin-left: 10px;
    font-size: 20px;
    border: 2px solid gray;
    border-top: none;
    width: 96%;
   height: 81px;
   display: flex;
   flex-direction: column;
   justify-content: flex-end;
   position: relative;
   background-color: transparent;
}
.download{
    padding-right: 8px;
    padding-bottom: 15px;
    display: flex;
    align-items: center;
    height: 30%;
    margin-right: 15px;
    width: 15%;
    align-self: flex-end;
}
.imageInformations{
    position: absolute;
    bottom: 100%;
    color: white;
    z-index: 100;
}

.imageChat{
   width: 60%;
   height: 30%;
   border-radius: 15px;
   margin-left: 15px;
}
.inputContainer textarea{
    width: 100%;
    height: 60%;
    background-color: transparent;
}
/*images*/
.bx-image-add,.bx-send{
    font-size: 25px;
    color: white;
    margin-left: 10px;
    cursor: pointer;

}
.bx-image-add{
    font-size: 27px;
}
.bx-send{
    rotate: -90deg;
    background-color: var(--shadowColor);
    padding: 4px;
    border-radius: 100%;
}

.p-info{
    font-size: 12px;
    margin-left: 15px;
}
.info-download h3{
    font-size: 13px;
    margin-bottom: 4px;
    margin-top: 21px;
}
.info-download h6{
    font-size: 10px;
    margin-top: 4px;
}
.info-download{
    display: flex;
    flex-direction: column;
    justify-content: center;
    text-align: left;
    height: 50px;
    padding-block: auto;
}
/*reload*/
.reload{
    width: 20px;
    height: 20px;
    border-radius: 100%;
    border: 3px solid;
    border-bottom: none;
    border-right: rgba(255, 255, 255, 0.562);
    animation: reload 1s infinite ease-out;
}
@keyframes reload{
to{
    transform: rotate(360deg);
}
} 
.download-image{
    display: flex;
    align-items: center;
    gap: 15px;
    margin-left: 15px;
    margin-bottom: 15px;
    border-radius: 8px;
    padding: 0 10px;
    background-color: rgba(128, 128, 128, 0.54);
}
    

.titleBox h6{
    color: gray;
    font-weight: 400;
    margin-bottom: 0;
    margin-top: 10px;
    text-align: center;
}
.title{
    cursor: pointer;
}
.mainLink{
    text-decoration: none;
    color: white;
}
.button-50{
    border: 2px solid var(--shadowColor);
    color: var(--shadowColor);
    border-radius: 4px;
}
.button-50:hover{
    box-shadow: 0px 0px 7px var(--shadowColor);
}

/*div main media query*/
@media (max-width:700px) {
    .main{
        margin-inline: auto;
    }
}
@media (max-width:420px) {
    .title,.login-container{
        margin-inline: 0;
        
    }
}
@media (max-width:900px) {
    .assistantdiv{
        width: 98%;
        margin-inline: auto;
    }
    .main{
        margin-top: 17px;
    }
    .download{
        padding-right: 50px;
    }
}

.aidiv .message .bubble ul {
    margin-left: 20px;    
    padding-left: 0;
    margin-top: 5px;       
    margin-bottom: 5px;   
}

.aidiv .message .bubble li {
    font-size: 12px;
    line-height: 1.4;
    margin-bottom: 3px;  
}