* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', sans-serif;
}

html {
    scroll-behavior: smooth;
}

.modal-background {
    display: none;
    justify-content: center;
    padding-top: 10%;
    position: fixed;
    z-index: 1;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.6);
}

.loader-spinner {
    display: none;
    border: 16px solid #94a3b8; 
    border-top: 16px solid #0ea5e9;
    border-radius: 50%;
    width: 120px;
    height: 120px;
    animation: spin 2s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.modal {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    border-radius: 10px;
    background-color: #FFFFFF;
    width: min(90vw, 600px);
    height: 600px;
    min-width: 300px;
    min-height: 460px;
    padding: 2em;
}

input {
    /* color: #546CFF; */
    color: #1D1141;
}

.close-modal-button {
    cursor: pointer;
    background-color: transparent;
    border: none;
    color: #1D1141;
    font-size: 2em;
    position: relative;
    top: 0;
    right: 0;
    top: -4%;
    right: -50%;
}

.modal-form {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 1.2em;
    width: min(90%, 400px);
    height: 100%;
    margin-top: -10%;
}

.modal-container {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 1.2em;
    width: 400px;
    min-width: 300px;
    height: 100%;
    margin-top: -10%;
}

.form-title {
    text-align: center;
    font-size: 3em;
    /* color: #546CFF; */
    color: #1D1141;
    margin-bottom: 0.2em;
}

.sign-up-modal,
.log-in-modal,
.log-out-modal,
.add-book-modal,
.edit-book-modal,
.edit-profile-modal,
.change-password-modal,
.message-modal {
    display: none;
}

.yes,
.no {
    font-weight: 600;
}

.modal-form > input {
    padding-left: 0.6em;
    /* border: solid 1px #546CFF; */
    border: solid 1px #1D1141;
}

.modal-form > input, button {
    font-size: 1em;
    height: 40px;
    border-radius: 5px;
}

.modal-form > button {
    cursor: pointer;
    font-weight: 600;
    /* background-color: #546CFF; */
    background-color: #1D1141;
    color: #FFFFFF;
    border: none;
}

.message-modal-button-container {
    display: flex;
    justify-content: center;
    gap: 1em;
    margin-top: 1em;
}

.log-in-button {
    background-color: transparent;
    border: none;
    cursor: pointer;
}

header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    min-width: 375px;
    min-height: 80px;
    height: 10vh;
    background: #1D1141;
    padding: 2% 4% 2% 4%;
}

.header-logo {
    cursor: pointer;
    display: flex;
    align-items: center;
}

.header-logo > img {
    height: 50px;
}

.header-logo > h1 {
    color: #FFFFFF;
    font-size: 2.4em;
    font-family: 'EB Garamond', serif;
    margin: 0.1em 0 0 0.2em;
}

.mobile-menu {
    display: none;
}

.mobile-menu-button {
    cursor: pointer;
    background-color: transparent;
    border: none;
}

.mobile-menu-button > span {
    color: #FFFFFF;
    font-size: 3em;
}

.mobile-nav-modal {
    background-color: #1D1141;
    position: absolute;
    top: 80px;
    width: 100%;
    min-width: 375px;
    padding-block: 2em;
    justify-content: center; 
}

.mobile-nav-modal.hide-mobile-nav {
    display: none;
}

.mobile-nav-modal.show-mobile-nav {
    display: flex;
}

nav > ul {
    font-family: sans-serif;
    display: flex;
    height: 100%;
    gap: 2em;
    list-style: none;
    align-items: center;
}

.sign-up-button {
    cursor: pointer;
    width: 110px;
    height: 40px;
    font-size: 1em;
    font-weight: bold;
    color: #FFFFFF;
    background-color: #FF692E;
    border: none;
    border-radius: 5px;
}

.error-message {
    color: red;
}

.success-message {
    text-align: center;
    border-radius: 5px;
    background-color: rgb(89, 179, 89);
    color: #FFFFFF;
    padding: 0.8em;
}

a {
    text-decoration: none;
    color: #FFFFFF;
}

.log-out-modal-form > div {
    display: flex;
    justify-content: center;
    gap: 1.4em;
}

.log-out-modal-form > div > a {
    font-size: 1.4em;
    /* color: #546CFF; */
    color: #1D1141;
    font-weight: 400;
}

.log-out-modal-form > div > a:hover {
    font-size: 1.4em;
    font-weight: 600;
}

.hero-container {
    display: flex;
    align-items: center;
    justify-content: center;
    padding-block: 2em;
}

.hero-text-container {
    position: relative;
    left: 5vw;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: calc(24px + 1vw);
}

.hero-text {
    color: #546CFF;
    font-size: calc(2rem + 4vw);
    line-height: 90%;
    padding-left: 15%;
    text-shadow: #111111;
}

.hero-text > span {
    color: #FF692E;
}

.hero-text-container > h3 {
    text-align: center;
    font-size: calc(14px + 1vw);
    color: #546CFF;
    font-weight: 400;
    line-height: 1.4em;
}

.hero-button-container {
    display: flex;
    gap: 1em;
}

.hero-button-container > button {
    width: 130px;
}

.try-demo-button {
    background-color: transparent;
    color: #546CFF;
    cursor: pointer;
    width: 110px;
    height: 40px;
    font-size: 1em;
    font-weight: bold;
    border-radius: 5px;
    border: solid 2px #546CFF;
}

.try-demo-button:hover {
    background-color: #546CFF;
    color: #FFFFFF;
}

.hero-image {
    position: relative;
    right: 10vw;
    width: calc(60% + 1vw);
    height: auto;
    -webkit-transform: scaleX(-1);
    transform: scaleX(-1);
    z-index: -1;
}

.demo-banner {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    background-color: #EFDEFF;
    width: 100%;
    height: 300px;
    gap: 2em;
}

.demo-banner > h3 {
    text-align: center;
    font-size: calc(16px + 1vw);
    color: #1D1141;
    font-weight: 400;
    margin-top: 3em;
}

.library-function-container {
    display: flex;
    justify-content: center;
    padding-block: 2em;
    gap: 1em;
}

.library-filter-selector {
    width: 180px;
    min-width: 150px;
    border-radius: 5px;
    border: none;
    padding-left: 1em;
    font-size: 1em;
}

.add-book-button {
    cursor: pointer;
    width: 180px;
    min-width: 150px;
    height: 40px;
    font-size: 1em;
    font-weight: bold;
    color: #FFFFFF;
    background-color: #1D1141;
    border: none;
    border-radius: 5px;
}

.demo-card-container,
.card-container {
    width: 100%;
    min-height: 700px;
    display: none;
    grid-template-columns: repeat(auto-fit, 350px);
    justify-content: center;
    align-items: center;
    padding: 2em 5em 5em 5em;
    gap: 24px;
}

.card-container {
    display: grid; 
}

.main-container {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    min-height: 700px;
    padding: 2em 5em 5em 5em;
}

.demo-card-container > h1 {
    font-weight: 400;
    text-align: center;
    font-size: 98px;
    color: #1D1141;
}

.book-card {
    width: 350px;
    height: 480px;
    /* background-color: #546CFF; */
    background-image: linear-gradient(to bottom, #1D1141,  #546CFF);
    border-radius: 10px;
}

.blur-filter {
    display: flex;
    justify-content: center;
    height: 100%;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(5px);
    border-radius: 10px 10px 0 0;
}

.book-cover-image {
    width: 100%;
    height: 45%;
    border-radius: 10px 10px 0 0;
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
}

.book-card-info-container {
    height: 55%;
    font-size: 1.2em;
    display: flex;
    flex-direction: column;
    padding: 1em;
    color: #FFFFFF;
}

.book-card-info-container > p {
    font-family: serif;
}

.book-card-interaction-container {
    position: relative;
    height: 100%;
    margin: 0.4em;
}

.favorite-button, .search-button {
    cursor: pointer;
    background-color: transparent;
    border: none;
}

span.filled {
    font-size: 36px;
    color: red;

    font-variation-settings:
    'FILL' 1,
    'wght' 400,
    'GRAD' 0,
    'opsz' 24
}

span.unfilled {
    font-size: 36px;
    color: #FFFFFF;

    font-variation-settings:
    'FILL' 0,
    'wght' 400,
    'GRAD' 0,
    'opsz' 24
}

span.search-icon {
    font-size: 36px;
    color: #FFFFFF;

    font-variation-settings:
    'FILL' 0,
    'wght' 400,
    'GRAD' 0,
    'opsz' 24
}

.book-card-button-container {
    display: flex;
    justify-content: center;
    gap: 8px;
    width: 100%;
    position: absolute;
    bottom: 0;
}

.book-card-button-container > button {
    cursor: pointer;
    font-weight: bold;
    color: #FFFFFF;
    /* background-color: #546CFF; */
    background-color: transparent;
    border: solid 2px #FFFFFF;
    border-radius: 5px;
    padding: 0 0.8em 0 0.8em;
}

.book-card-button-container > button:hover {
    color: #FFFFFF;
    background-color: #1D1141;
    border: solid 2px #1D1141;
}

.unread {
    background-color: transparent;
    /* width: 120px; */
}

.read {
    width: 100px;
    background-color: rgb(0, 194, 0) !important;
    border: solid 2px rgb(0, 194, 0) !important;
}

.read:hover {
    border: solid 2px rgb(0, 194, 0) !important;
}

footer {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    height: 300px;
    background-color: #1D1141;
    color: #FFFFFF;
}

.profile-container {
    display: flex;
    flex-direction: column;
    gap: 2em;
}

.profile-image-container {
    position: relative;
    text-align: center;
    align-self: center;
    border-radius: 50%;
}

.profile-image-container > p {
    cursor: pointer;
    color: #1D1141;
    font-size: 1.2em;
    font-weight: 500;
    position: absolute;
    top: 135px;
    left: 65px;
}

.profile-image {
    cursor: pointer;
    align-self: center;
    background-color: #94a3b8;
    height: 300px;
    width: 300px;
    border-radius: 50%;
    object-fit: cover;
}

.profile-image-form {
    display: none;
}

.profile-data {
    display: flex;
    flex-direction: column;
    /* gap: 1em; */
    text-align: center;
}

.profile-text {
    font-size: 32px;
    /* color: #546CFF; */
    color: #1D1141;
}

.profile-text > span {
    font-size: 0.9em;
    font-weight: 400;
    margin-left: 0.4em;
}

.edit-profile-button {
    cursor: pointer;
    align-self: center;
    border: none;
    border-radius: 5px;
    /* background-color: #546CFF; */
    background-color: #1D1141;
    color: #FFFFFF;
    font-weight: 600;
    width: 150px;
}

.modal-form > .upload-profile-image-button {
    font-weight: 400;
    background-color: transparent;
    /* color: #546CFF; */
    color: #1D1141;
    /* border: solid 1px #546CFF; */
    border: solid 1px #1D1141;
}

.modal-form > .upload-profile-image-button:hover {
    font-weight: 600;
    /* background-color: #546CFF; */
    background-color: #1D1141;
    color: #FFFFFF;
    /* border: solid 1px #546CFF; */
    border: solid 1px #1D1141;
}

.change-password-link {
    align-self: center;
    /* color: #546CFF; */
    color: #1D1141;
}

.friends-list {
    width: 300px;
    height: 300px;
}

.friends-list-header > h2 {
    background-color: #1D1141;
    color: #FFFFFF;
}

footer > h2 {
    margin-top: 1em;
    font-size: 1.2em;
    font-weight: 400;
    min-width: 330px;
}

.footer-links {
    display: flex;
    gap: 1em;
}

.footer-links > a > img {
    margin-top: 2em;
    width: 50px;
    height: 50px;
}

@media (max-width: 800px) {
    .desktop-nav {
        display: none;
    }
    .mobile-menu {
        display: flex;
    }

    .hero-container {
        flex-direction: column;
        padding-top: 2em;
    }

    .hero-text-container,
    .hero-container > img {
        width: 100%;
        position: static;
    }

    .hero-text {
        padding-left: 0;
        line-height: 100%;
        width: 80%;
    }

    .demo-card-container {
        padding: 2em 0 2em 0;
    }
}
