/* ----- BASICS ----- */
:root {
    --background: #374c62;
    --text: #dbe2ee;
    --primary: #35527f;
    --secondary: #242C39;
    --accent: #26c8e5;
    --block-bg: #232B38;
    --title: #DFE5E7;
}

html,
body {
    min-height: 100dvh;
}

body {
    display: flex;
    margin: 0;
    color: var(--text);
    background-color: var(--background);

    font-family: "Inter Tight", sans-serif;
    font-optical-sizing: auto;
    font-weight: normal;
    font-style: normal;
}

/* ----- ASIDE ----- */

aside {
    background-color: var(--block-bg);
    width: 30%;
    max-width: 400px;
    min-height: calc(100vh - 40px);
    margin: 10px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
    border-radius: 10px;
    box-sizing: border-box;
}

aside .flexbox {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    color: var(--text);
    margin-left: auto;
}

.logo_wrap {
    margin: 50px auto 0px;
    /*border: 2px solid #a5abbd;*/
    border-radius: 50%;
    overflow: hidden;
}

.logo_wrap img {
    width: 300px;
    height: 300px;
}

#site_title {
    text-align: center;
}

.title {
    font-size: 1.75rem;
    font-weight: bold;
    color: var(--title);
    margin-bottom: .2rem;
}

.title:hover {
    color: #f1f1e6;
    cursor: pointer;
}

.subtitle,
.files_title {
    color: #a5abbd;
}

.files_title {
    padding-left: 30px;
    background-image: url(../assets/folder.png);
    background-repeat: no-repeat;
    background-size: 24px;
}

.socials {
    display: flex;
    gap: 20px;
    margin: 20px auto 50px;
    width: fit-content;
}

.socials img {
    width: 32px;
    height: 32px;
}

/* ----- MENU' ----- */

#menu ul{
    list-style-type: none;
    padding: 0;
    text-transform: uppercase;
    text-align: center;
}

#menu ul a{
    color: var(--accent);
    text-decoration-thickness: 3px;
}

#menu ul a:hover {
    color: #f1f1e6;
}

/* ----- MAIN ----- */

.main_wrap {
    width: 100%;
    box-sizing: border-box;
    padding: 20px 50px 0;
    display: flex;
    flex-wrap: wrap;
}

.files_list {
    margin-left: 30px;
}

a {
    color: #00b1b9;
    text-decoration: none;
    font-size: 15px;
}

a:hover {
    text-decoration: underline;
}

a:visited {
    color: #66c2c8;
}

.block {
    box-sizing: border-box;
    padding: 20px;
    margin: 10px;
    background-color: var(--secondary);
    border-radius: 10px;
    max-width: 800px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    height: fit-content;
}

#intro{
    width: 45%;
    background-color: var(--primary);
}

#about{
    width: 50%;
}

#about > div{
    display: flex;
    flex-wrap: wrap;
    justify-content: space-around;
    gap: 10px;
}

#about .member_contact > p{
    padding-bottom: 0;
    margin-bottom: 0;
}

#latest_files{
    width: 50%;
}

#candidatura{
    width: 45%;
    background-color: var(--text);
    color: var(--background);
}

.special_link{
    background-color: var(--primary);
    color: var(--text);
    padding: 0px 10px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    gap: 20px;
}

.special_link a{
    color: var(--text);
    padding-right: 20px;
    background-image: url(../assets/arrow_forward.svg);
    background-repeat: no-repeat;
    background-size: 18px;
    background-position: right center;
    transition: all 0.3s ease;
}

.special_link a:hover{
    padding-right: 25px;
    text-decoration: underline;
    text-decoration-thickness: 3px;
    text-decoration-color: var(--text);
}

.special_link h3{
    color: var(--text);
}

#intro .special_link{
    background-color: var(--text);
}

#intro .special_link a{
    background-image: url(../assets/arrow_forward_inv.svg);
}

#intro .special_link a:hover{
    text-decoration-color: var(--primary);
}

#intro .special_link h3{
    color: var(--primary);
}


#candidatura a,
#rtb a{
    color: var(--background);
}

#all_files{
    width: 100%;
    max-width: unset;
}

#all_files .files_blocks{
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: max-content;
    gap: 20px;
    grid-template-rows: repeat(4, auto);
}

#all_files .files_blocks .files_list {
    grid-row: span 4;
}

#all_files .inside_block{
    margin-left: 30px;
    height: fit-content;
}

.file_item{
    margin: 6px 0;
    padding: 6px;
    display: flex;
    align-items: center;
    cursor: pointer;
    width: fit-content;
    padding-left: 15px;
    background-image: url(../assets/file.svg);
    background-repeat: no-repeat;
    background-size: 14px;
    background-position: left center;
}

#rtb{
    width: 55%;
    background-color: var(--text);
    color: var(--background);
}

footer {
    margin-top: auto;
    width: 100%;
    text-align: center;
}

/* ----- MOBILE ----- */

@media only screen and (max-width: 1080px) {
    body {
        flex-direction: column;
    }

    aside {
        width: calc(100% - 20px);
        height: auto;
        min-height: unset;
        max-width: unset;
    }

    aside .flexbox {
        width: 100%;
        height: 100%;
        max-width: none;
        display: flex;
        flex-direction: row;
        align-items: center;
        color: #f1f1e6;
        padding: 20px;
        box-sizing: border-box;
    }

    .socials{
        align-items: center;
        margin: auto auto auto 0;
    }

    .logo_wrap{
        margin: 0 auto;
    }

    .logo_wrap img{
        width: 200px;
        height: 200px;
    }

    .main_wrap {
        width: 100%;
        flex: 1;
    }

    footer {
        width: 100%;
    }

    /* Menù mobile */

    #menu{
        margin-left: auto;
        margin-right: 20px;
        width: 40px;
        height: 40px;
        background-image: url(../assets/menu.svg);
        background-size: contain;
        background-repeat: no-repeat;
        background-position: center;
        position: relative;
    }

    #menu.open{
        background-image: url(../assets/close_menu.svg);
    }

    #menu ul {
        display: none;
    }

    #menu ul.show {
        display: block;
        position: absolute;
        top: 20px;
        right: 10px;
        background-color: var(--block-bg);
        border-radius: 10px;
        box-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
        padding: 10px;
        z-index: 9;
        width: 150px;
        height: 150px;
    }
}

@media only screen and (max-width: 980px) {
    #intro, #about, #latest_files, #candidatura, #rtb {
        width: 100%;
        max-width: unset;
    }

    .logo_wrap img{
        width: 150px;
        height: 150px;
    }

    #all_files .files_blocks{
        grid-auto-flow: unset;
    }

}

@media only screen and (max-width: 540px) {
    .logo_wrap {
        display: none;
    }

    #all_files .files_blocks .file_item small{
        display: none;
    }

    #all_files .inside_block,
    #all_files .files_blocks,
    #all_files .files_list{
        margin-left: 0;
    }

    .main_wrap {
        padding: 20px 20px 0;
    }
}
