/* FONTS AND VARIABLES */
@font-face{
    font-family: default-font;
    src: url('fonts/montserrat/Montserrat-Regular.ttf');
    font-weight: normal;
}
/* GENERAL STYLING */
body{
    margin: 0;
    overflow-y: hidden;
}
.background{
    background-size: cover;
    background-repeat: no-repeat;
    background-position: center;
    width: 100%;
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;
    z-index: 1;
    background-color: rgba(0, 0, 0, 0.7);
}
.background-overlay{
    position: absolute;
    z-index: 2;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.4);
}
.default-font{
    font-family: default-font;
    color: white;
}
a{
    text-decoration: none;
}
.styled-button{
    transition: 0.2s ease-out;
}
.styled-button:hover{
    background-color: white;
    color: black;
}
/* DEFINING GRID */
.grid-container{
    display: grid;
    grid-template-columns: 1fr 1fr 1fr 500px;
    grid-template-rows: 106px 1fr 1fr;
    gap: 0px 0px;
    grid-template-areas:
        "header header header sidebar"
        "content content content sidebar"
        "content content content sidebar";
    width: 100%;
    height: 100%;
}

/* HEADER STYLING */
.header{
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 40px;
    box-sizing: border-box;
    grid-area: header;
    position: relative;
    z-index: 100;
}
.header .logo-wrapper{
    margin-left: 60px;
}
.logo-name{
    font-size: 0.8rem;
    letter-spacing: 14px;
    margin-bottom: 0px;
}
.navigation-wrapper .navigation{
    position: relative;
}
.navigation-wrapper .navigation .nav-link:not(:first-child){
    margin-left: 82px;
}
.navigation-wrapper .navigation .nav-link{
    font-size: 1.3rem;
}
.navigation-wrapper .navigation .menu-dropdown{
    text-transform: lowercase;
    display: inline;
    cursor: pointer;
}
.navigation-wrapper .navigation .user-menu{
    position: absolute;
    top: 28px;
    right: 0;
}
.navigation-wrapper .navigation .user-menu p{
    text-align: right;
    font-size: 1.3rem;
    text-transform: lowercase;
    cursor: pointer;
}
/* WIDGET AND FORM STYLING */
.widget-background{
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color:rgba(0, 0, 0, 0.7);
    z-index: 100000;
    transition: 1s cubic-bezier(0.46, 1.03, 0.32, 1);
    overflow: hidden;
    backdrop-filter: blur(3px);
    opacity: 0;
    visibility: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
}
.widget-background.visible{
    opacity: 1;
    visibility: visible;
    transform: scale(1);
}
.widget-background form{
    box-sizing: border-box;
    background-color: #1E1E1E;
    position: relative;
    padding: 40px;
    max-width: 500px;
    width: 100%;
}
.widget-background img{
    margin: 0 auto 60px auto;
    display: block;
}
.login-widget form .input-wrapper{
    max-width: 100%;
}
.input-wrapper{
    position: relative;
    max-width: 300px;
    margin: 0 auto 40px auto;
}
.text-input{
    font-size: 1.3rem;
    color: white;
    outline: none;
    border: none;
    border-bottom: 1px solid white;
    background-color: transparent;
    box-sizing: border-box;
    padding: 15px;
    width: 100%;
    position: relative;
    z-index: 1;
}
textarea[name="comment-area"]{
    position: relative;
    z-index: 1;
}
.input-wrapper label{
    position: absolute;
    left: 15px;
    top: 20px;
    transition: 0.2s ease-out;
    color: #979797;
    z-index: 0;
}
.input-wrapper input:focus ~ label,
.input-wrapper input:valid ~ label,
.input-wrapper textarea:focus ~ label,
.input-wrapper textarea:valid ~ label{
    top: 0;
    font-size: 0.7rem;
}
.error-message{
    color: red;
    font-weight: bold;
}
.widget-background form .register-link,
.widget-background form .login-link{
    color: white;
    text-decoration: underline;
    cursor: pointer;
}
form .login-button{
    background-color: transparent;
    outline: none;
    border: 1px solid white;
    padding: 10px 20px;
    display: block;
    cursor: pointer;
    width: 100%;
}
.close-widget{
    position: absolute;
    width: 30px;
    height: 30px;
    right: 10px;
    top: 10px;
    cursor: pointer;
    background-image: url('images/close_icon.svg');
    background-repeat: no-repeat;
    background-position: center;
    background-size: contain;
}
/* SIDEBAR STYLING */
.sidebar{
    max-width: 500px;
    box-sizing: border-box;
    width: 100%;
    height: 100%;
    background-color: rgba(20, 20, 20, 0.7);
    grid-area: sidebar;
    position: relative;
    z-index: 100;
    overflow-y: auto;
    overflow-x: hidden;
}
.sidebar .sidebar-content{
    padding: 40px;
}
.sidebar .sidebar-top{
    display: flex;
    align-items: center;
    max-height: 100px;
    box-sizing: border-box;
    height: 100%;
    padding: 20px 40px !important;
}
.sidebar .temperature-content{
    padding-bottom: 20px !important;
}
.data-label{
    color: #979797;
}
.city-label{
    margin: 0 20px 0 0;
    font-size: 1.2rem;
}
.city-data{
    margin: 0;
    font-size: 1.3rem;
}
.change-location{
    color: white;
    border: 1px solid white;
    padding: 5px 20px;
    cursor: pointer;
    margin: 0 0 0 auto;
}
.sidebar-separator{
    width: 500px;
    height: 1px;
    background-color: white;
}
.sidebar .sidebar-content-title{
    font-size: 1.3rem;
    margin: 0 0 30px 0;
}
.sidebar .data-row{
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.sidebar .data-row p{
    margin: 10px 0;
}
.sidebar .input-wrapper{
    position: relative;
}
form.weather-search,
form.news-search{
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    margin-bottom: 0;
}
form .search-button{
    color: white;
    border: 1px solid white;
    padding: 5px 20px;
    cursor: pointer;
    margin: 0 0 0 auto;
    background-color: transparent;
    font-size: 1rem;
    height: min-content;
}
.search-button{
    margin-left: 20px;
}
.sidebar .input-wrapper{
    margin: 0;
}
.temperature-content .sidebar-content-title.default-font{
    margin-bottom: 0;
}
.temperature-chart{
    width: 100%;
    height: 160px;
}
/* CONTENT STYLING */
.content{
    max-width: 100%;
    width: 100%;
    height: 100%;
    grid-area: content;
    position: relative;
    z-index: 2;
}
.content .content-inner{
    max-height: calc(100% - 200px);
    height: 100%;
    display: flex;
    align-items: flex-start;
    position: relative;
}
.content .content-inner .temp-wrapper{
    display: flex;
    align-items: flex-start;
    padding: 0 0 50px 100px;
    position: absolute;
    bottom: 0;
    left: 0;
}
.content .content-inner .temp-wrapper .current-temp{
    font-size: 6rem;
    margin: 0;
}
.content .content-inner .temp-wrapper .weather-desc{
    font-size: 2.5rem;
    margin: 15px 0 0 20px;
    text-transform: capitalize;
}
.content .content-bottom{
    border-top: 1px solid white;
    max-height: 200px;
    height: 100%;
    width: 100%;
    box-sizing: border-box;
    display: flex;
    align-items: center;
    padding: 50px 100px;
}
.content-bottom .photo-intro{
    margin-left: 20px;
    padding-top: 2px;
}
.content-bottom .photographer-link{
    margin-left: 5px;
    padding-top: 2px;
}
.content .content-bottom .pexels-link{
    font-size: 1.3rem;
}
/* NEWS STYLING START */
.news-card-overlay{
    width: 0px;
    height: 0px;
    background-color: rgba(0, 0, 0, 0.7);
    position: absolute;
    left: 50%;
    top: 50%;
    right: 50%;
    bottom: 50%;
    z-index: 10000;
    transition: 1s cubic-bezier(0.46, 1.03, 0.32, 1);
    overflow: hidden;
    backdrop-filter: blur(3px);
    opacity: 0;
}
.news-section-wrapper{
    padding: 0px 0px 0px 100px;
    box-sizing: border-box;
    width: 100%;
}
.news-section-top h1{
    font-weight: normal;
}
.news-cards-wrapper{
    display: flex;
    flex-wrap: wrap;
    overflow-y: auto;
    max-height: 90%;
}
.news-card{
    background-color: #1E1E1E;
    padding: 20px;
    box-sizing: border-box;
    border-radius: 5px;
    margin: 0 20px 20px 0;
    max-width: 500px;
}
.news-card .news-card-top{
    display: flex;
    align-items: center;
    flex-wrap: wrap;
}
.news-title{
    margin: 0 20px 0 0;
    font-size: 1.4rem;
}
.default-font.news-author{
    color: #979797;
}
.news-card-content img{
    max-width: 100%;
}
.news-link{
    color: white;
    border: 1px solid white;
    padding: 5px 20px;
    display: block;
    cursor: pointer;
    text-decoration: none;
    margin: 0 auto;
    font-size: 1rem;
}
.news-topic{
    cursor: pointer;
}
/* COMMENTS STYLING */
.comment-section{
    max-width: 450px;
    width: 100%;
    margin: 0 20px 0 auto;
}
.comments-wrapper{
    width: 100%;
    padding: 20px;
    box-sizing: border-box;
    background-color: rgba(20, 20, 20, 0.7);
    margin-bottom: 20px;
    max-height: 400px;
    overflow-y: auto;
    height: 100%;
}
.message{
    border-bottom: 1px solid grey;
}
.message-top{
    display: flex;
    align-items: center;
}
.message-user{
    font-size: 0.9rem;
    margin-bottom: 0;
}
.message-timestamp{
    font-size: 0.9rem;
    margin-left: 20px;
    margin-bottom: 0;
}
.comment-form-wrapper{
    padding: 20px;
    background-color: rgba(20, 20, 20, 0.7);
    box-sizing: border-box;
    margin-bottom: 20px;
}
.comment-form-wrapper form{
    margin: 0;
}
.comment-form-wrapper .input-wrapper{
    max-width: 100%;
}
.comment-form-wrapper textarea[name="comment-area"]{
    padding: 15px;
    width: 100%;
    background-color: transparent;
    outline: none;
    resize: none;
    font-size: 1rem;
}
.submit-message{
    border: 1px solid white;
    padding: 5px 20px;
    box-sizing: border-box;
    cursor: pointer;
    background-color: transparent;
    font-size: 1rem;
}
/* SETTINGS FORM STYLING */
.settings-title{
    margin-top: 0;
    font-size: 2rem;
    padding-bottom: 20px;
    border-bottom: 2px solid white;
}
.settings-form .input-wrapper{
    margin-left: 0;
}
.submit-settings-button{
    background-color: transparent;
    outline: none;
    border: 1px solid white;
    padding: 10px 20px;
    display: block;
    cursor: pointer;
}