@import url('https://fonts.googleapis.com/css?family=Poppins&display=swap');

img{
    object-fit: cover;
    width: 100%;
    height: 100%
}

/* ===== LAYOUT ===== */
#main-container{
    perspective: 2px;
}

/* ===== HERO BANNER ===== */
#hero-banner{
    width: 100%;
    min-height: 80vh;
    position: relative;
    background-image: url("/images/homepage/automatedsystem.jpeg");
    background-size: cover;
}

#hero-text{
    position: absolute;
    top: 0;
    left: 0;
    width: fit-content;
    margin: calc(2 * var(--primary-spacing));
    text-align: center;
    padding: calc(1.5 * var(--primary-spacing));
    border-radius: 10px;
    background-color: rgba(255, 255, 255, 0.9);
    font-size: xx-large;
    font-weight: bold;    
    color: var(--accent-color);
}


/* ===== ROWS ===== */
.home-tile{
    background-color: rgba(0, 0, 0, 0.1);
    padding: 5% 10%;
    position: relative;
    display: flex;
    flex-direction: column;
}
.home-tile > .pane-title{
    font-family: 'Poppins', sans-serif;
    font-size: xx-large;
    margin-left: -8%;
}
.home-tile > p{
    padding: var(--secondary-spacing);
    text-shadow: #EFEFEF 0px 0px 2px
}
.home-tile > *:not(.pane-title){
    font-size: 15pt;
}
.home-tile li{
    font-size: 14pt;
}
.home-tile > ul {
    margin-left: 8%;
}
.home-tile::after {
    content: "";
    opacity: 0.2;
    position: absolute;
    top: 0;
    left: 0;
    bottom: 0;
    right: 0;
    z-index: -1;  
    background-repeat: no-repeat; 
    background-attachment: fixed;
    background-position: center;
    background-size: cover;
    filter: blur(4px);
}

#first-tile::after{
    background-image: url(/images/homepage/first.jpg);
}

#second-tile::after{
    background-image: url(/images/homepage/second.jpg);
}

#third-tile::after{
    background-image: url(/images/homepage/third.png);
}

/* ===== NEWS ===== */

#news-container{
    position: absolute;
    top: 0;
    right: 0;
    display: flex;
    flex-direction: column;
    background-color:  rgba(255, 255, 255, 0.9);
    border-radius: 5px;
    margin: calc(2 * var(--primary-spacing));
    padding: calc(1.5 * var(--primary-spacing));
    overflow-y: auto;
    max-width: 400px;
    width: 30%;
    max-height: calc(80vh - calc(2 * var(--primary-spacing)) - calc(1.5 * var(--primary-spacing)))
}

.news-content p{
    word-break: break-word;
}

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

@media(max-width: 1024px){
    #main-container{
        grid-template-rows: 50vh auto auto auto auto;
        grid-row-gap: var(--primary-spacing);
    }
    .home-row{
        grid-template-rows: auto auto auto;
        grid-row-gap: var(--primary-spacing);
        min-height: 200px;
        margin: var(--primary-spacing);
    }
    .home-row > .text-tile{
        grid-row: 2/3;
    }
    .home-row > img{
        grid-row: 3/4;
        width: 100%;
        height: auto;
        max-height: 300px;
    }
}

@media(max-width: 768px){
    #news-container{
        display: none;
    }
    .home-tile > *:not(.pane-title){
        font-size: large;
    }
    .home-tile > .pane-title{
        font-size: x-large;
    }
}
