/* Import font */
@import url('https://fonts.googleapis.com/css2?family=Bangers&family=Sansation:ital,wght@0,300;0,400;0,700;1,300;1,400;1,700&family=Zalando+Sans:ital,wght@0,200..900;1,200..900&display=swap');

/* Import others files */
@import url("theme.css");
@import url("dialog.css");


/* ------------------------------------
    Balises 
------------------------------------ */
/* * */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: "Zalando Sans", sans-serif;
    transition: var(--transition);
}

[disabled] {
    opacity: 0.5;
    cursor: not-allowed;
}

/* body */
body {
    height: 100vh;
    overflow: hidden;
    background: var(--primaryBg);
    color: var(--primaryFg);
}


/* header/footer */
header {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 10px;

    border-bottom: 2px solid var(--secondaryBg);
    padding: 10px;
}
footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem;
    text-align: center;
    font-size: 0.8rem;
    border-top: 2px solid var(--secondaryBg);
}


/* All h */
h1 {
    font-size: 1.4em;
}
h2 {
    font-size: 1.2em;
}
h3 {
    font-size: 1em;
}


/* All button */
button {
    display: flex; 
    justify-content: center;
    align-items: center;
    outline: none;

    cursor: pointer;
    color: var(--lightgray);
    background:var(--color);
    border: 1px solid var(--color);
    border-radius: var(--radiusBTN);

    gap: 6px;
    font-size: 1em;
    font-weight: 600;
    padding: 8px 12px;
    transition: 0.5s;
}
button:hover {
    background: var(--colorHover);
}

.ghost {
    background: transparent;
    color: var(--primaryFg);
    border: 1px solid var(--secondaryBg);
}
.ghost:hover {
    background: transparent;
    color: var(--color);
    border: 1px solid var(--color);
}

.icon {
    color: var(--primaryFg);
}

.red {
    background: var(--close);
    border-color: var(--close);
}
.red:hover {
    background: var(--closeHover);
    border-color: var(--closeHover  );
}

.green {
    background: var(--validate);
    border-color: var(--validate);
}
.green:hover {
    background: var(--validateHover);
    border-color: var(--validateHover);
}

.iconToggle {
    position: relative;
    background: transparent;
    border: 2px solid var(--secondaryBg);
    border-radius: var(--radius);
    padding: 0;
    min-width: 40px;
    min-height: 40px;
    overflow: hidden;
}
.iconToggle:hover {
    background: var(--secondaryBg);
}
.iconToggle svg {
    position: absolute;
}
.iconToggle svg:last-child {
    transform: translateX(40px);
}
.iconToggle.active svg:first-child {
    transform: translateX(-40px);
}
.iconToggle.active svg:last-child {
    transform: translateX(0px);
}


/* input */
input, textarea
{
    width: 100%;
    outline: none;
    font-size: 1em;
    font-weight: normal;
    margin: 5px 0;
    padding: 8px;
    border-radius: var(--radius);
    border: 2px solid var(--secondaryBg);
    background: var(--primaryBg);
    color: var(--primaryFg);
}

/* ------------------------------------
    Global styles for RagSystem 
------------------------------------ */
#app {
    display: flex;
    flex-direction: column;
    height: 100vh;
}


/* ------------------------------------
    Header 
------------------------------------ */
#leftHeader h1 {
    font-size: 1.5rem;
    font-weight: normal;
}
#centerHeader {
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: center;
    gap: 10px;
    width: 50%;
}
#centerHeader input {
    text-align: center;
}
#keySearchBTN {
    width: 40px;
    height: 40px;
    padding: 0 6px;
    border: 2px solid var(--secondaryBg);
    border-radius: var(--radius);
}
#keySearchBTN:hover {
    border-color: var(--color);
}
#rightHeader {
    display: flex;
    flex-direction: row;
}
#rightHeader button {
    background: transparent;
    border: none;
}


/* ------------------------------------
    Main 
------------------------------------ */
main {
    display: flex;
    flex: 1;
    overflow: hidden;
}
/*  SideBar   */
.sideBar {
    width: 50px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    border-right: 2px solid var(--secondaryBg);
}
.sideBar ul {
    list-style: none;
}
.sideBar button {
    position: relative;
    width: 100%;
    height: 50px;
    border-radius: 0;
    padding: 0;

    border: none;
    background: none;
    
    cursor: pointer;
    transition: var(--transition);
}
.sideBar button:hover {
    background: var(--secondaryBg);
}
.sideBar button.active::before {
    position: absolute;
    content: '';
    left: 0;
    top: 0;

    background: var(--color);
    transition: var(--transition);

    width: 4px;
    height: 100%;
}
.sideBar button.active:hover::before {
    background: var(--colorHover);
}
.sideBar .separator {
    width: calc(100% - 8px);
    border-bottom: 2px solid var(--secondaryBg);
    margin: 1px 4px;
}
/*  TreeView/ConvView   */
.view {
    display: none;
}
.view.active {
    display: block;

}

.userActions {
    display: flex;
    flex-direction: column;
}

.contentArea {
    flex: 1;
    overflow: hidden;
}








/* Splitter styles */
dcia-splitter {
    display: block;
    width: 100%;
    height: 100%;
}

/* File explorer styles */
dcia-tree-view {
    display: block;
    width: 100%;
    height: 100%;
}

/* Tab widget styles */
dcia-tab-widget {
    display: block;
    width: 100%;
    height: 100%;
}

/* Chat bot styles */
dcia-chat-bot {
    display: block;
    width: 100%;
    height: 100%;
}




/* ------------------------------------
    Responsive design for mobile (Revoir plus tard) 
------------------------------------ */
@media (max-width: 768px) {
    .sidebar {
        width: 100%;
        height: 40px;
        flex-direction: row;
        align-items: center;
        padding: 0;
    }
    
    .sidebar nav ul {
        display: flex;
        width: 100%;
    }
    
    .sidebar button {
        padding: 0.5rem;
        font-size: 0.7rem;
    }
    
    .user-actions {
        flex-direction: row;
        gap: 0;
    }
    
    main {
        flex-direction: column;
    }
}