/*
    +------------------------------------+
    |        Elements in all page        |
    +------------------------------------+
*/
@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@600&display=swap');
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    text-decoration: none;
    font-family: var(--primary-font);
}
:root {
    --primary-color: #161e2e;
    --secondary-color: #fff;
    --third-color: #3a6f8e;
    --nav-color: #c5cbd8;
    --nav-color-hover: #c8d0dc;
    --main-bg-color: #313338;
    --primary-font: "Montserrat", sans-serif;
}
.d-flex {
    display: flex;
}
.list-style-none {
    list-style: none;
}
.warning {
    background: #f8d7da;
    color: #b02a37;
    padding: 1rem;
    border-radius: 5px;
    text-align: center;
    border: 1px solid #b02a37;
    display: none;
}
.success {
    background: #d1e7dd;
    color: #146c43;
    padding: 1rem;
    border-radius: 5px;
    text-align: center;
    border: 1px solid #146c43;
    display: none;
}
.show {
    display: block;
}
.loader-container {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 90vh;
}
.loader {
    width: 48px;
    height: 48px;
    border: 3px solid #FFF;
    border-radius: 50%;
    display: inline-block;
    position: relative;
    box-sizing: border-box;
    animation: rotation 1s linear infinite;
}
.loader::after {
    content: '';  
    box-sizing: border-box;
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 56px;
    height: 56px;
    border-radius: 50%;
    border: 3px solid;
    border-color: var(--third-color) transparent;
}
@keyframes rotation {
    0% {
      transform: rotate(0deg);
    }
    100% {
      transform: rotate(360deg);
    }
  } 
/*
    +------------------------------------+
    |     Elements in header section     |
    +------------------------------------+
*/
.header-section {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-around;
    background-color: #20242a;
    background-image:
        linear-gradient(
        #1f2532, #1e242a, #1f2630, #1e2835, #202123
        );
}
.logo-container {
    display: flex;
    align-items: center;
}
.header-logo {
    max-width: 2rem;
    height: 100%;
    object-fit: cover;
    object-position: center;
    border-radius: 50%;
}
.header-title{
    text-align: center;
    color: var(--nav-color);
    font-size: 2.5rem;
    margin: 1rem 0;
    font-weight: 800;
}
.nav-section {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 5%;
}
.nav-elements-ul {
    list-style: none;
    display: flex;
    flex-direction: row;
    justify-content: space-between;
}
.nav-elements-li {
    color: var(--nav-color);
    display: flex;
    cursor: pointer;
    padding: 0.5rem 1rem;
    text-decoration: none;
}
.nav-elements-li:hover {
    filter: brightness(3);
    color: var(--nav-color-hover);
    border-radius: 0.5rem;
}
.input-group {
    position: relative;
}
.form-input {
    width: 100%;
    background: none;
    color: var(--nav-color);
    font-size: 1rem;
    padding: 0.4rem 0;
    border: none;
    outline: none;
    border-bottom: 1px solid var(--nav-color);
}
  
.form-input:focus + .form-label,
.form-input:not(:placeholder-shown) + .form-label {
    transform: translateY(-9px) scale(0.7);
    transform-origin: left top;
    filter: brightness(3);
}
.form-label {
    color: var(--nav-color);
    cursor: pointer;
    position: absolute;
    top: 0;
    left: 2px;
    transform: translateY(10px);
    transition: transform 0.5s, color 0.3s;
}
/*
    +------------------------------------+
    |      Elements in modal section     |
    +------------------------------------+
*/
.modal {
    display: none;
    position: fixed; 
    z-index: 1; 
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto; 
    background-color: rgba(0,0,0,0.4); 
}

.modal-content {
    background-color: var(--main-bg-color);
    margin: 15% auto;
    max-width: 45rem;
    padding: 20px;
    border: 1px solid #888;
    border-radius: 8px;
}
.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    padding: 0 1rem 1rem 1rem;
}
.modal-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--nav-color);
}
.close {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
}
.close:hover,
.close:focus {
    color: var(--nav-color-hover);
    text-decoration: none;
    cursor: pointer;
}
.modal-input-group {
    position: relative;
    margin: 1rem;
}
.modal-form-input {
    width: 100%;
    color: var(--nav-color);
    background: none;
    font-size: 1rem;
    padding: 0.4rem 0;
    border: none;
    outline: none;
    border-bottom: 1px solid var(--nav-color);
}
.modal-form-input:focus + .modal-form-label,
.modal-form-input:not(:placeholder-shown) + .modal-form-label {
    transform: translateY(-9px) scale(0.7);
    transform-origin: left top;
    filter: brightness(3);
}
.modal-form-label {
    color: var(--nav-color);
    cursor: pointer;
    position: absolute;
    top: 0;
    left: 2px;
    transform: translateY(10px);
    transition: transform 0.5s, color 0.3s;
}
.modal-form-input[type="date"]::-webkit-calendar-picker-indicator {
    filter: invert(1);
}
.modal-author {
    color : var(--nav-color);
}
.modal-tags {
    color : var(--nav-color);
}
.tags-container {
    display: flex;
    flex-wrap: wrap;
}
.tag {
    background-color: #0077c2;
    color: white;
    padding: 5px 10px;
    border-radius: 20px;
    margin: 5px;
}
.modal-button {
    cursor: pointer;
    display: inherit;
    text-align: center;
    margin: 0 auto;
    margin-top: 0.8rem;
    color: var(--secondary-color);
    font-size: .8rem;
    border-radius: 5px;
    border: 0;
    padding: 0.5rem;
    background-color: #4A4983;
}
.modal-button:hover {
    background-color: #35335b;
}
.modal-body {
    padding: 1rem;
    color: var(--nav-color);
}
.modal-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    padding: 1rem;
}