/* General Styles */
body {
    margin: 0;
    font-family: Arial, sans-serif;
    background-color: #f4f4f4;
    background-image: url(bgattempt1.png);
    background-size: cover;
    background-repeat: no-repeat;
    background-attachment: fixed;
}

/* Navbar */
.navbar {
    display: flex;
    justify-content: center; /* Center the logo horizontally */
    align-items: center;
    padding: 10px 0; /* Remove side padding for true centering */
    background-color: #333;
    /* background-color: rgb(0, 191, 197); */
    color: white;
    position: sticky; /* Changed from default static */
    top: 0;
    z-index: 1000; /* Ensures navbar stays on top */
    box-sizing: border-box; /* Add this */
    height: 60px; /* Explicit height */

}

.logo {
    font-size: 2em;
    font-weight: 100;
    font-family: "Cherry Bomb One", serif;
    height: 100%; /* Fill navbar height */
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0;
    padding: 0;
}

.logo-link {
    color: white;
    text-decoration: none;
    display: flex;
    align-items: center;
    height: 100%;
    margin: 0;
    padding: 0;
}

.nav-icons {
    display: flex;
    align-items: center;
    cursor: hand;
    height: 100%;
    display: flex;
    align-items: center;
}

.nav-icons a {
    margin-left: 15px;
    text-decoration: none;
    color: white;
    font-size: 1.5em;
    transition: color 0.3s;
}

.nav-icons a:hover {
    color: #ffcc00;
}

/* Modal styles */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.5);
}

.modal-content {
    background-color: white;
    margin: 10% auto;
    padding: 20px;
    border: 1px solid #888;
    width: 80%;
    max-width: 500px;
    border-radius: 10px;
    position: relative;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.close-button {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    position: absolute;
    top: 10px;
    right: 15px;
    cursor: pointer;
}

.close-button:hover,
.close-button:focus {
    color: black;
    text-decoration: none;
}

/* Play Button Styles */
.play-overlay {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 70vh;
    text-align: center;
    margin-top: 2rem;
}

.play-button {
    padding: 25px 50px;
    font-size: 2.5em;
    background: linear-gradient(135deg, #2ae80d, #0bd50e);
    border: none;
    border-radius: 50px;
    color: white;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 15px;
    box-shadow: 0 10px 30px rgba(43, 232, 13, 0.3);
    animation: pulse 2s infinite;
}

.play-button:hover {
    transform: scale(1.05);
    box-shadow: 0 15px 40px rgba(43, 232, 13, 0.4);
}

.play-button:active {
    transform: scale(0.95);
}

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

.play-instruction {
    font-family: 'Chewy', cursive;
    color: #333;
    font-size: 1.4em;
    margin-bottom: 30px;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.1);
}

/* Add these to hide puzzle initially */
.image-container, .answer-container {
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.5s ease;
    display: none;
}

.revealed {
    opacity: 1 !important;
    transform: translateY(0) !important;
    display: block !important;
}

/* Main Content */
.content {
    display: block; /* Change from flex */
    padding: 20px 0;
    margin-top: 1rem;
    box-sizing: border-box;
    height: auto; /* Remove min-height */
}

.play-button {
    font-family: 'Chewy', 'Playfair Display', serif;
     text-shadow: 1px 1px 2px rgba(0,0,0,0.1);
}

/* Replace existing .image-container styles */
.image-container {
    width: 90%;
    max-width: 800px;
    margin: 20px auto; /* Vertical margin only */
    position: relative;
}

.image-container img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 10px;
}

/* Answer Section Styles */
.answer-container {
    width: 90%;
    max-width: 600px;
    margin: -30px auto 40px; /* Top negative margin pulls up */
    padding-top: 50px; /* Space between image and input */
    
}


#answer-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

#answer-input {
    padding: 15px 20px;
    font-size: 1.2em;
    border: 3px solid #333;
    border-radius: 30px;
    font-family: "Itim", serif;
    font-weight: 900;
    color: #333;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.9);
    width: 100%;
    box-sizing: border-box;
}

#answer-input:focus {
    outline: none;
    border-color: #0bd50e;
    box-shadow: 0 0 15px rgba(255, 204, 0, 0.3);
}

.submit-btn {
    padding: 12px 25px;
    /* background: linear-gradient(135deg, #ffcc00, #ff9500); */
    background: linear-gradient(135deg, #2ae80d, #0bd50e);
    border: none;
    border-radius: 25px;
    color: white;
    font-size: 1.1em;
    cursor: pointer;
    transition: transform 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    /* font-family: "Itim", serif; */
    font-family: "DynaPuff", serif;

    width: 100%;
    box-sizing: border-box;
}

.submit-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 15px rgba(255, 149, 0, 0.4);
}

/* Date Picker Styles */
.date-picker {
    display: flex;
    gap: 10px;
    margin-bottom: 15px;
}

.date-select {
    flex: 1;
    padding: 12px 15px;
    border: 3px solid #333;
    border-radius: 30px;
    font-family: 'Chewy', cursive;
    font-size: 1.1em;
    appearance: none;
    background: rgba(255, 255, 255, 0.9) url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23333' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e") no-repeat right 15px center;
    background-size: 20px;
}

.date-select:focus {
    outline: none;
    border-color: #ffcc00;
    box-shadow: 0 0 15px rgba(255, 204, 0, 0.3);
}

/*
*
*
*
*
/*Mult choice styles*/


.multichoice-container {
    display: flex;
    flex-direction: row; /* Change to row to place options side by side */
    justify-content: center; /* Center items horizontally */
    align-items: center;
    flex-wrap: wrap; /* Allow wrapping on small screens */
    gap: 20px;
    width: 100%;
    margin-top: -50px;
    /* margin: 0 auto; */
    padding-top: -120px;
  }
  
  .multichoice-container .choice {
    cursor: pointer;
    transition: background-color 0.3s ease;
    border-radius: 8px;
    padding: 5px;
  }
  
  .multichoice-container .choice.selected {
    background-color: rgba(11, 213, 14, 0.3); /* Example: light green overlay */
  }
  
  .multichoice-container img {
    width: 100px; /* adjust as needed */
    height: 100px; /* adjust as needed */
  }

  .choices-row {
    display: flex;
    flex-direction: row;
    justify-content: center;
    gap: 20px;
    width: 100%;
  }

  .submit-mc-btn {
    padding: 10px 20px;
    border: none;
    border-radius: 25px;
    background: linear-gradient(135deg, #2ae80d, #0bd50e);
    color: white;
    font-size: 1.1em;
    cursor: pointer;
    transition: transform 0.2s ease;
    margin-top: 15px; /* Add some space between options and button */
    width: fit-content; /* Button only as wide as needed */
    align-self: center; /* Center the button */
  }
/*   
  .submit-mc-btn {
    padding: 10px 20px;
    border: none;
    border-radius: 25px;
    background: linear-gradient(135deg, #2ae80d, #0bd50e);
    color: white;
    font-size: 1.1em;
    cursor: pointer;
    transition: transform 0.2s ease;
  }
   */

/* Confirmation Modal Styles */
#confirm-modal .modal-content {
    max-width: 400px;
    padding: 25px;
}

.warning-text {
    background: #fff9e6;
    padding: 15px;
    border-radius: 8px;
    margin: 15px 0;
    font-size: 0.9em;
    color: #666;
    border-left: 4px solid #ffcc00;
    display: flex;
    gap: 10px;
}

.warning-text i {
    color: #ffcc00;
    font-size: 1.2em;
    margin-top: 2px;
}

.modal-buttons {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    margin-top: 20px;
}

.confirm-btn, .cancel-btn {
    padding: 10px 25px;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.confirm-btn {
    /* background: linear-gradient(135deg, #ff4444, #ff0000); */
    background: linear-gradient(135deg, #2ae80d, #0bd50e);
    border: none;
    color: white;
}

.cancel-btn {
    background: #f0f0f0;
    border: 1px solid #ddd;
    color: #333;
}

.confirm-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 2px 8px rgba(255, 68, 68, 0.3);
}

.cancel-btn:hover {
    background: #e0e0e0;
}

/* Result Modal */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0,0,0,0.5);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
}
.result-modal {
    position: relative;
    /* overflow: hidden; */ /* Removed to allow corner borders to show */
}
.result-modal, .final-result {
    background: white;
    padding: 30px 40px;
    border-radius: 20px;
    text-align: center;
    box-shadow: 0 8px 30px rgba(0,0,0,0.15);
    min-width: 300px;
    max-width: 500px;
    margin: 0 auto 30px auto;
    font-family: 'Chewy', 'Playfair Display', serif;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
    border: 4px solid #eee;
}




.answer-main-text {
    font-size: 2.3em;
    font-weight: 400;
    font-family: 'Chewy', 'Playfair Display', serif;
    margin-bottom: 0.2em;
    letter-spacing: 0.01em;
    text-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

/* Incorrect Result Modal Extensions */
.incorrect-options {
    display: flex;
    gap: 15px;
    margin-top: 20px;
    justify-content: center;
}

.try-again-btn, .show-answer-btn {
    padding: 10px 25px;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: 'Chewy', cursive;
}

.try-again-btn {
    background: #f0f0f0;
    border: 2px solid #ddd;
    color: #333;
}

.show-answer-btn {
    background: linear-gradient(135deg, #ff9500, #ff4444);
    border: none;
    color: white;
}

.answer-explanation {
    margin-top: 20px;
    background: rgba(255, 255, 255, 0.9);
    padding: 15px;
    border-radius: 10px;
    border-left: 4px solid;
}

.answer-explanation h3 {
    font-family: 'Cherry Bomb One', cursive;
    margin: 0 0 10px 0;
    font-size: 1.3em;
    color: inherit;
}

.answer-explanation p {
    font-family: 'Chewy', cursive;
    margin: 0;
    font-size: 1em;
    color: #666;
}

.incorrect .answer-explanation {
    border-color: #ffcc00;
    background: #fff9e6;
}

.correct .answer-explanation {
    border-color: #4CAF50;
    background: #e8f5e9;
}

.correct-answer {
    color: #4CAF50;
    font-weight: bold;
}



/* Learn More Page Styles */
.learn-more {
    max-width: 800px;
    margin: 2rem auto;
    padding: 20px;
    background: rgba(255, 255, 255, 0.4); /* Last digit is opacity*/
    border-radius: 15px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

/* The individual info cards*/
.info-card {
    background: white;
    margin: 1.5rem 0;
    padding: 1.5rem;
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.info-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

.info-card::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: #ffcc00;
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.info-card:hover::after {
    transform: scaleX(1);
}

.card-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out;
}

.info-card:hover .card-content {
    max-height: 500px;
}

.learn-more button {
    background: linear-gradient(135deg, #ffcc00, #ff9500);
    border: none;
    padding: 1rem 2rem;
    font-size: 1.1rem;
    color: white;
    border-radius: 25px;
    cursor: pointer;
    transition: transform 0.2s ease;
    display: block;
    margin: 2rem auto;
    width: fit-content;
}

.learn-more button:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 15px rgba(255, 149, 0, 0.4);
}

/* Learn More Page Tooltip */
.learn-more-page .logo-link {
    position: relative;
    padding-right: 40px;
}

/* Learn More Page Tooltip - Enhanced */
.learn-more-page .logo-link::after {
    content: "← Click to return!";
    display: inline-block;
    margin-left: 15px;
    font-family: 'Caveat', cursive;
    color: #ffcc00;
    font-size: 1.4rem;
    font-weight: 700;
    vertical-align: middle;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.1);
    animation: wiggle 5s ease-in-out infinite;
}

@keyframes wiggle {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-3px); }
    75% { transform: translateX(3px); }
}

/* Media Queries */
@media (max-width: 768px) {
    .navbar {
        flex-direction: row;
        flex-wrap: wrap;
        padding: 0 0;
        align-items: center;
        height: 60px;
    }
.logo {
    font-size: 2em;
    font-weight: 100;
    font-family: "Cherry Bomb One", serif;
    height: 100%; /* Fill navbar height */
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0;
    padding: 0;
}

.logo-link {
    color: white;
    text-decoration: none;
    display: flex;
    align-items: center;
    height: 100%;
    margin: 0;
    padding: 0;
}

    
    .navbar {
        flex-direction: row;
        flex-wrap: wrap;
        padding: 10px 15px;
        align-items: center; /* Ensure vertical centering on mobile */
    }



    .nav-icons {
        margin-top: 0;
        justify-content: flex-end;
        width: auto;
        flex-grow: 1;
    }

    .nav-icons a {
        margin-left: 15px;
        margin-right: 0;
    }

    .modal-content {
        width: 90%;
    }

    .learn-more {
        margin: 1rem;
        padding: 15px;
    }
    
    .info-card {
        margin: 1rem 0;
        padding: 1rem;
    }

    .learn-more-page .logo-link::after {
        content: "← Home";
        font-size: 1.2rem;
        margin-left: 8px;
    }
    
    .logo {
        padding-right: 0;
    }

    .content {
        gap: 25px; /* Reduce spacing on mobile */
    }
    
    .image-container {
        margin-top: 10px;
    }
    
    .answer-container {
        margin-bottom: 25px;
    }
    
    #answer-input {
        font-size: 1em;
        padding: 12px 15px;
    }
    
    .submit-btn {
        font-size: 1em;
        padding: 10px 20px;
    }

    .puzzle-card {
        /* Mobile Glass Panel Styles - matching desktop */
        background: rgba(255, 255, 255, 0.15) !important;
        backdrop-filter: blur(10px) !important;
        -webkit-backdrop-filter: blur(10px) !important;
        border: 1px solid rgba(255, 255, 255, 0.2) !important;
        border-radius: 15px !important; /* Slightly smaller radius for mobile */
        box-shadow: 
            0 8px 32px rgba(0, 0, 0, 0.1),
            0 0 0 1px rgba(255, 255, 255, 0.1) inset,
            0 0 20px rgba(43, 232, 13, 0.1) !important;
        width: 92%; /* Reduced from 99% to prevent edge cutting */
        max-width: calc(100vw - 20px); /* Account for margins */
        margin: 15px auto; /* Reduced margins */
        padding: 25px 20px; /* Fixed padding instead of viewport units */
        font-size: 1em; /* Slightly smaller font */
        /* overflow: hidden; */ /* Remove this to prevent clipping of corner borders */
        box-sizing: border-box; /* Ensure padding is included in width */
    }
    .puzzle-question {
        font-size: 1.18em;
        color: #2d1c08;
        padding: 0;
        word-break: break-word;
        overflow-wrap: break-word;
        line-height: 1.4;
        text-align: center;
        position: relative; 
        margin-top: 45px; /* Add this line */
    }
    .puzzle-diagram {
        max-width: 98vw;
    }
}

