/* General Styles */
body {
    background-color: #1a1a2e;
    color: #ececec;
    font-family: "Arial", sans-serif;
}

a {
    color: #d9b3ff;
}

/* Fonts */
@font-face {
    font-family: "Jersey10";
    src: url("/static/fonts/Jersey10-Regular.ttf") format("truetype");
    font-display: block;
}

/* Full-screen preloader */
#preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    font-size: 2.5em;
    font-family: "Jersey10", sans-serif;
    color: #d9b3ff;
    background-color: #322d44;
}

#preloader div {
    font-size: 1.5em;
    letter-spacing: 0;
    display: flex;
    align-items: center;
}

@keyframes dotBlink1 {
    0%,
    25% {
        visibility: hidden;
    }
    26%,
    100% {
        visibility: visible;
    }
}

@keyframes dotBlink2 {
    0%,
    50% {
        visibility: hidden;
    }
    51%,
    100% {
        visibility: visible;
    }
}

@keyframes dotBlink3 {
    0%,
    75% {
        visibility: hidden;
    }
    76%,
    100% {
        visibility: visible;
    }
}

#dot1 {
    visibility: hidden;
    animation: dotBlink1 1.5s infinite;
}

#dot2 {
    visibility: hidden;
    animation: dotBlink2 1.5s infinite;
}

#dot3 {
    visibility: hidden;
    animation: dotBlink3 1.5s infinite;
}

#content {
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.5s ease-in-out;
}

/* Parallax Scrolling */
.parallax {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 280vh;
    background-image: url("/static/images/purple_background.png");
    background-size: calc(100% / 3) auto; /* x-repeat 3 times */
    background-repeat: repeat;
    z-index: -1;
}

/* Navigation Bar Styles */
.navbar {
    background-color: #322d44;
    border-bottom-left-radius: 15px;
    border-bottom-right-radius: 15px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.5);
    color: lightblue;
    max-width: 900px;
    margin: auto;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.navbar-brand {
    color: #d9b3ff !important;
    font-size: 1.8em;
    margin-left: 0.2em;
    display: flex;
    align-items: center;
    height: 1.8em;
}

.navbar-brand span {
    font-family: "Jersey10", sans-serif;
    margin-left: 0.15em;
    font-size: 1.8em;
}

.nav-link {
    color: #ececec;
    background-color: #252329;
    border-radius: 0.4em;
    margin-left: 0.7em;
    padding: 0.3em 0.6em !important;
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.5);
}

.navbar-brand:hover,
.nav-link:hover {
    color: #d9b3ff !important;
}

.navbar-nav .nav-link:focus {
    color: inherit;
}

/* Container Styles */
.container {
    max-width: 900px;
    margin: 20px auto;
    padding: 20px;
    background-color: #322d44;
    border-radius: 15px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.6);
}

/* Header Styles */
#header-image {
    width: 100%;
    border-radius: 0.7em;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.6);
}

.header-title {
    text-align: center;
    font-size: 2.5rem;
    margin: 0.8rem 0;
    color: #d9b3ff;
}

.header-title span {
    font-family: "Jersey10", sans-serif;
    font-size: 3.4rem;
}

.intro-note {
    color: #af8fcf;
}

/* Card Styles */
.body-card {
    background-color: #423b5e;
    margin-bottom: 20px;
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.4);
}

.card {
    background-color: #181a1b !important;
}

/* Button Styles */
.btn-custom {
    background-color: #6b52a7 !important;
    border: none;
    color: #fff;
    border-radius: 0.5em;
    padding: 10px 20px;
    display: block;
    margin: 0 auto;
}

.btn-custom:hover {
    background-color: #8a6dd1 !important;
}

@keyframes pulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(0.95);
    }
    100% {
        transform: scale(1);
    }
}

.btn-pulse {
    transition: all 0.3s ease-in-out;
    animation: pulse 1s infinite ease-in-out;
}

.btn-group {
    height: 2.75em;
}

@keyframes flash-green {
    0% {
        background-color: #28a745;
    }
    50% {
        background-color: #1b621b;
    }
    100% {
        background-color: #28a745;
    }
}

@keyframes flash-yellow {
    0% {
        background-color: #e3ac05;
    }
    50% {
        background-color: #9b8f29;
    }
    100% {
        background-color: #e3ac05;
    }
}

@keyframes flash-red {
    0% {
        background-color: #dc3545;
    }
    50% {
        background-color: #842929;
    }
    100% {
        background-color: #dc3545;
    }
}

.flash-positive {
    animation: flash-green 1.4s infinite alternate ease-in-out;
}

.flash-neutral {
    animation: flash-yellow 1.5s infinite alternate ease-in-out;
}

.flash-negative {
    animation: flash-red 1.6s infinite alternate ease-in-out;
}

/* Top Games Section */
.top-games {
    border-radius: 10px;
    background-color: #423b5e;
    margin: 20px 0;
    padding: 10px 20px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.4);
}

.card-img {
    object-fit: cover;
    height: 5em;
    border-radius: 5px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.4);
}

.game-counts {
    border: 1px solid #6b52a7;
    border-radius: 0.2em;
    padding: 0.3em 0.6em;
    background-color: #3b3b5e;
}

/* Footer Styles */
footer {
    text-align: center;
    margin: 20px 0;
    color: #a2a2c1;
}

/* Summary Box Styles */
.summary-box {
    transition: all 0.5s ease;
}

.summary-head {
    overflow: hidden;
}

.summary-image video {
    border-radius: 0.5em;
    width: 100%;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.4);
}

.summary-content {
    margin-left: 1em;
}

.summary-btn {
    background-color: #6b52a7;
}

.summary-btn:hover {
    background-color: #8a6dd1;
}

.summary-box.expanded {
    height: 50em;
}

.pro-text {
    border: 1px solid green;
    border-radius: 0.3em;
    padding: 0.6em 0.8em;
    background-color: rgba(0, 128, 0, 0.125);
}

.contra-text {
    border: 1px solid red;
    border-radius: 0.3em;
    padding: 0.7em;
    background-color: rgba(255, 0, 0, 0.125);
}

.pro-text b {
    color: green;
}

.contra-text b {
    color: red;
}

/* Review Section */
.review-box {
    border-radius: 10px;
    background-color: #423b5e;
    margin-top: 0;
    padding: 10px 20px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.4);
}

#attention-result {
    background-color: #181a1b;
    border-color: #4c4f51;
    color: #ececec;
}

#attention-result p span {
    border-radius: 0.25em;
}

#review-input {
    background-image: url("/static/images/sentiment_background.png");
    background-size: cover;
    background-color: #181a1b;
    border-color: #4c4f51;
    color: #ececec;
}

#review-input::placeholder {
    text-align: center;
    font-size: 115%;
    font-weight: bold;
    color: #d9b7ff;
}

.review-results {
    height: 16.9em;
}

.review-results-form {
    margin: 0;
}

.review-results-text {
    height: 12.8em;
    overflow: hidden;
    background-image: url("/static/images/sentiment_background.png");
    background-size: cover;
}

/* Sentiment Metrics */
.sentiment-metrics.block {
    margin-right: 0.9em;
    width: 86%;
}

.sentiment-metrics.block img:first-of-type {
    margin-bottom: 0.9em;
}

.sentiment-metrics.matrix img {
    border-radius: 0.3em;
}

/* Cluster Section */
.cluster2,
.cluster3,
.cluster4 {
    margin-top: 1.1em;
}

.cluster-topic b,
.implementation,
.intro-headings {
    color: lightblue;
}

/* Topic Visualization */
.topic-visualization img {
    border-radius: 0.25em;
    margin-top: 0.5em;
}

#prediction-spinner {
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.spinner-grow {
    animation: grow-animation 1.5s infinite;
}

@keyframes grow-animation {
    0% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.5);
        opacity: 0.5;
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

/* Prompt Modal Styles */
body.modal-open {
    overflow-y: scroll !important;
    padding-right: 0px !important;
}

a[data-bs-toggle="modal"] {
    cursor: pointer;
}

.modal {
    padding-right: 0 !important;
}

.modal-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.modal-card:hover {
    transform: translateY(-2px) scale(1.01);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.5);
    cursor: pointer;
}

.modal-dialog {
    max-width: none;
    width: 54rem !important;
}

.modal-content {
    background-color: #211d2e !important;
    padding: 1.5em;
}

.modal-box img {
    border-radius: 0.25em;
    margin-top: 0.5em;
}

.btn-close-light {
    filter: brightness(0) saturate(100%) invert(39%) sepia(21%) saturate(527%)
        hue-rotate(220deg) brightness(95%) contrast(96%);
    opacity: 1;
    transform: rotate(90deg);
    transition: transform 0.2s ease-in-out;
}

.btn-close:focus {
    outline: none;
    box-shadow: none;
}

.btn-close:hover {
    transform: rotate(-90deg);
    transition: transform 0.2s ease-in-out;
}
