/* Fonts & Typography */
@font-face {
    font-family: SZ-Bold;
    src: url(Fonts/StyreneA-Bold.otf);
}

@font-face {
    font-family: SZ-Light;
    src: url(Fonts/StyreneA-Light.otf);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    background-image: url('../images/quiz-bg.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
    padding: 20px;
}

/* Unified Game Container */
#game-container {
    width: 100%;
    max-width: 900px;
    background-color: transparent;
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

/* Top White Panel */
.game-content {
    background-color: #ffffff;
    padding: 30px 40px 25px 40px;
    display: flex;
    flex-direction: column;
}

/* Header Row (Left: Title, Right: Level) */
header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin-bottom: 15px;
    border-bottom: none;
    padding: 0;
}

#website_title {
    font-family: "SZ-Bold", "Inter", sans-serif;
    font-weight: 700;
    font-size: 32px;
    color: #0026ff;
    /* Vibrantly sharp blue as in the screenshot */
    letter-spacing: -0.5px;
}

#level-indicator {
    font-family: 'Inter', sans-serif;
    font-weight: 500;
    font-size: 16px;
    color: #555555;
    user-select: none;
}

/* Question Text styling */
#question-text {
    font-family: "SZ-Light", "Inter", sans-serif;
    font-size: 18px;
    font-weight: 600;
    color: #3b42f6;
    /* Elegant blue-indigo */
    text-align: left;
    margin-bottom: 20px;
}

/* Image Container & Station Image */
#image-container {
    width: 100%;
    overflow: hidden;
    margin-bottom: 5px;
    border: 1px solid #e0e0e0;
}

#station-image {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
}

/* Bottom Control Panel (Light Gray) */
.game-footer {
    background-color: #eeeeee;
    /* Distinct light gray bottom bar */
    padding: 25px 40px;
    border-top: 1px solid #dcdcdc;
}

.footer-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    width: 100%;
}

/* Styled Input Field */
#answer-input {
    flex: 2;
    padding: 11px 16px;
    font-size: 15px;
    font-family: 'Inter', sans-serif;
    background-color: #ffffff;
    border: 1px solid #c0c0c0;
    border-radius: 4px;
    color: #333;
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
}

#answer-input::placeholder {
    color: #aaaaaa;
}

#answer-input:focus {
    border-color: #3c7fb1;
    box-shadow: 0 0 4px rgba(63, 213, 251, 0.4);
}

/* Buttons container */
.buttons-container {
    flex: 1.2;
    display: flex;
    gap: 10px;
}

/* User Specified Retro Button Style */
.btn-retro {
    flex: 1;
    padding: 10px 20px;
    font-size: 15px;
    font-weight: 600;
    font-family: 'Segoe UI', Tahoma, sans-serif;
    color: #333;
    cursor: pointer;
    text-align: center;
    background: linear-gradient(180deg, #ffffff 0%, #f2f2f2 48%, #e6e6e6 52%, #eeeeee 100%);
    border: 1px solid #828282;
    border-radius: 4px;
    box-shadow:
        inset 0 1px 0 0 #fff,
        inset 0 -1px 1px 0 rgba(0, 0, 0, 0.05),
        0 1px 2px rgba(0, 0, 0, 0.1);
    transition: all 0.2s ease;
    user-select: none;
    outline: none;
}

.btn-retro:hover {
    background: linear-gradient(180deg, #ffffff 0%, #f7f7f7 48%, #ededed 52%, #f5f5f5 100%);
    border-color: #666;
    box-shadow:
        inset 0 1px 0 0 #fff,
        0 1px 3px rgba(0, 0, 0, 0.15);
}

.btn-retro:active,
.btn-retro:focus {
    outline: none;
    background: linear-gradient(180deg, #ffffff 0%, #f1f1f1 49%, #d5e6f2 50%, #c4daeb 100%) !important;
    border-color: #3c7fb1 !important;
    box-shadow: inset 0 0 12px #3fd5fb !important;
}

/* Next Button adjustments */
.btn-next {
    margin: 20px auto 0 auto;
    width: fit-content;
    padding: 12px 30px;
}

/* Feedback message box */
.feedback-box {
    margin-top: 15px;
    padding: 12px;
    border-radius: 4px;
    font-size: 16px;
    font-weight: 600;
    text-align: center;
    transition: all 0.3s ease;
}

.correct-feedback {
    background: linear-gradient(180deg, #eaffed 0%, #81ffa2ad 50%, #94ffa7 51%, #a4ffc4ad 100%);
    color: #1e7e34;
    border: 1px solid #c3e6cb;
}

.incorrect-feedback {
    background: linear-gradient(180deg, #ffffff 0%, #ffd5d5 50%, #ffc5c578 100%);
    color: #dc3545;
    border: 1px solid #f5c6cb;
}

.trivia-box {
    margin-top: 15px;
    padding: 16px;
    border-radius: 4px;
    line-height: 1.6;
}

.trivia-title {
    font-size: 16px;
    font-weight: 700;
    color: #0026ff;
    margin-bottom: 8px;
}

.trivia-content {
    font-size: 14px;
    color: #4a5568;
}

/* Victory Screen */
#victory-screen {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(8px);
    color: white;
    justify-content: center;
    align-items: center;
    z-index: 100;
    flex-direction: column;
}

#victory-screen h2 {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 15px;
    letter-spacing: -1px;
}

#victory-screen p {
    font-size: 1.3rem;
    margin-bottom: 30px;
    color: #cccccc;
}

#reset-button {
    padding: 12px 30px;
    font-size: 16px;
}

/* Responsiveness Media Queries */
@media (max-width: 768px) {
    body {
        padding: 10px;
        background-position: -10rem !important;
    }

    .game-content {
        padding: 20px 20px 15px 20px;
    }

    #website_title {
        font-size: 24px;
    }

    #level-indicator {
        font-size: 14px;
    }

    #question-text {
        font-size: 16px;
    }

    .game-footer {
        padding: 20px;
    }

    .footer-row {
        flex-direction: column;
        gap: 15px;
        align-items: stretch;
    }

    #answer-input {
        width: 100%;
    }

    .buttons-container {
        width: 100%;
    }
}