/*********************************************
** TABLE OF CONTENTS *************************
*********************************************/
/** Basics */
/** Buttons */
/** Product Selection */
/** Step 4 */
/** Reader */
/** Animations */


/*********************************************
** Fonts *************************************
*********************************************/

@font-face {
    font-family: 'Bookerly';
    src: url('/static/fonts/bookerly.woff2') format('woff2');
}

/*********************************************
** Basics ************************************
*********************************************/
body {
    font-family: 'Poppins', sans-serif;
    font-weight: 300;
    background: #f3f0e5;
}

a:hover {
    color: #222222;
}

p {
    font-size: 30px;
}

hr {
    margin-top: 30px;
    margin-bottom: 1rem;
    border: 0;
    border-top: 2px solid #222222;
}

#mainContent {
    min-height: 100dvh;
    max-width: 1000px;
    margin: auto;
}

.inner-container {
    margin: 0 40px;
    padding: 40px 0;
    padding-bottom: 200px;
}

.container {
    background: #f3f0e5;
}

.shadow {
    box-shadow: 0px 4px 8px 0px #00000026 !important;
}

.nav-link {
    background-color: transparent !important;
    color: #b7b7b7;
    padding: 0;
    margin-right: 30px;
    font-family: 'Roboto Mono', monospace;
    font-size: 18px;
    cursor: default;
}

.nav-link:hover {
    color: #b7b7b7;
}

.nav-link.active {
    background-color: transparent !important;
    color: black !important;
    border: none !important;
}

.btn {
    border-radius: 50px;
    padding: 10px 30px;
    border: none;
    font-size: 26px;
    font-weight: 300;
    font-family: 'Roboto Mono', sans-serif;
}

.fs-18 {
    font-size: 18px;
}

.roboto-mono {
    font-family: 'Roboto Mono', sans-serif;
}

.poppins {
    font-family: 'Poppins', sans-serif;
}

.reader-display {
    font-family: 'Bookerly', 'DM Serif Display', serif;
    text-align: justify;
    line-height: 2em;
    hyphens: auto;
    -webkit-hyphens: auto;
}
.reader-display p {
    text-indent: 1em;
    margin-top: 0em;
    margin-bottom: 0em;
}

.mb-6 {
    margin-bottom: 80px;
}

.logo-container {
    display: flex;
    justify-content: flex-end;
    margin-right: 30px;
}

.logo {
    width: 220px;
}

.logo-grey {
    align-self: flex-end;
    margin-right: 50px;
    margin-top: 40px;
}

footer {
    position: fixed;
    bottom: 0;
    width: 100%;
    height: 140px;
    z-index: 100;
    background: #f3f0e5;
    border-top: 2px solid #222222;
    padding-top: 30px;
}


/*********************************************
** Buttons ***********************************
*********************************************/
.btn:hover {
    cursor: pointer;
}

.btn-primary {
    background-color: #FFE55C !important;
    border-color: #FFE55C !important;
    color: #333 !important;
}

.btn-primary:hover {
    background-color: #FFD43B !important;
    border-color: #FFD43B !important;
}

.btn-primary:focus, .btn-primary.focus {
    box-shadow: 0 0 0 0.2rem rgba(255, 229, 92, 0.5) !important;
}

.btn-primary:active, .btn-primary.active {
    background-color: #FFCB26 !important;
    border-color: #FFCB26 !important;
}

.btn-primary:disabled, .btn-primary.disabled {
    background-color:#bdbab1 !important;
}

.btn-tertiary {
    background-color: #00D856;
    border-color: #00D856;
    color: #222222;
}

.btn-tertiary:hover {
    background-color: #00C748;
    border-color: #00C748;
}

.btn-tertiary:focus, .btn-tertiary.focus {
    box-shadow: 0 0 0 0.2rem rgba(0, 216, 86, 0.5);
}

.btn-tertiary:active, .btn-tertiary.active {
    background-color: #00B63A;
    border-color: #00B63A;
}

.btn-tertiary:disabled, .btn-tertiary.disabled {
    background-color: #66E5A3;
    border-color: #66E5A3;
}

.btn-outline {
    border: 2px solid #222222 !important;
}

.btn-small {
    font-size: 16px;
    padding: 4px 14px;
    margin-right: 30px;
}

/*********************************************
** PRODUCT SELECTION *************************
*********************************************/
.product {
    width: 33%;
    position: relative;
}

.product.selected::after {
    content: '✔';
    color: white;
    font-size: 24px;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: #00da57;
    border-radius: 50%;
    padding: 10px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    width: 50px;
    height: 50px;
    text-align: center;
}

.product-image-container {
    margin: 25px;
    cursor: pointer;
}

.product img {
    width: 100%;
}

.product.selected img {
    filter: grayscale(100%);
    opacity: 0.8;
}

.checkmark {
    position: absolute;
    width: 10px;
    height: 10px;
    background-color: green;
    border-radius: 50%;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    display: none;
}

.product.selected .checkmark {
    display: block;
    filter: none;
}

#scrollBtn {
    display: none; /* Hidden by default */
    position: fixed;
    bottom: 140px;
    right: 30px;
    z-index: 99; /* Ensure it appears above other content */
    border: none;
    outline: none;
    background-color: #555; /* Background color */
    color: white; /* Arrow color */
    cursor: pointer;
    padding: 15px;
    border-radius: 4px;
    font-size: 18px;
}

#scrollBtn:hover {
    background-color: #333; /* Darken background on hover */
}


/*********************************************
** Step 4 ************************************
*********************************************/
.choices {
    display: flex;
    justify-content: space-between;
}

.choice-container {
    background: #fffdf8;
    padding: 30px;
    border-radius: 15px;
    width: calc(50% - 15px);
    min-height: 350px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: flex-start;
}

.amazing-book-preview {
    max-width: 300px;
    margin: auto;
    margin-bottom: 30px;
}

/*********************************************
** READER ************************************
*********************************************/
#fullscreenPopup {
    position: fixed;
    z-index: 1000;
}

.popup-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.95);
    display: flex;
    align-items: center;
    justify-content: flex-start;
    flex-direction: column;
    animation: fadeIn 0.5s;
    z-index: 1000;
}

.popup-content {
    position: relative;
    margin-top: 50px;
    z-index: 5;
}

.reader {
    background-color: rgb(255, 253, 248);
    width: 100%;
    padding: 100px;
    border-radius: 15px;
    overflow-y: auto;
    height: calc(100dvh - 220px);
    max-width: min(calc(100vw - 100px), 800px);
}

.scrollable-content {
    font-weight: 300;
    overflow-y: auto;
    white-space: pre-line;
}

.scrollable-content p {
    font-size: 20px;
}

.closeText {
    color: white;
    cursor: pointer;
    position: relative;
    top: -15px;
}

.closeText:hover {
    color: #ffffff;
    text-decoration: none;
}

.animationContainer {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 500px;
}

#loadingwrapper {
    flex-shrink: 0;
    width: 450px;
    height: 510px;
    overflow: hidden;
}

#loading {
    animation: loading_start 5.5s steps(66) forwards;
}

#loading.middle {
    animation: loading_middle 2s steps(24) forwards;
}

#loading.end {
    animation: loading_end 5s steps(111) forwards;
}


/*********************************************
** ANIMATIONS ********************************
*********************************************/
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes fadeOut {
    from {
        opacity: 1;
    }
    to {
        opacity: 0;
    }
}

@keyframes loading_start {
    from { transform: translateX(0); }
    to { transform: translateX(-29700px); }
}

@keyframes loading_middle {
    from { transform: translateX(-29700px); }
    to { transform: translateX(-40500px); }
}

@keyframes loading_end {
    from { transform: translateX(-40500px); }
    to { transform: translateX(-90450px); }
}
