/* Scope all styles to the .container (training box) */
.container {
    max-width: 540px;
    margin: 40px auto;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 24px rgba(44, 110, 73, 0.10);
    padding: 32px 24px 24px 24px;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    color: #23432c;
    position: relative;
    z-index: 1;
}

.container h1 {
    text-align: center;
    color: #2c6e49;
    margin-bottom: 24px;
    font-size: 2em;
    font-weight: 700;
}

.container h2, 
.container h3 {
    color: #4c956c;
    margin-bottom: 12px;
    font-weight: 600;
}

.container label {
    font-weight: 500;
    margin-bottom: 8px;
    display: block;
}

.container input[type="text"] {
    width: 100%;
    padding: 10px;
    margin: 12px 0 20px 0;
    border: 1px solid #b7e4c7;
    border-radius: 6px;
    font-size: 1rem;
    box-sizing: border-box;
    background: #f8fafc;
    color: #23432c;
}

.container button {
    background: #2c6e49;
    color: #fff;
    border: none;
    border-radius: 6px;
    padding: 10px 22px;
    font-size: 1rem;
    margin-top: 16px;
    cursor: pointer;
    transition: background 0.2s;
    font-weight: 500;
    outline: none;
}

.container button:hover, 
.container button:focus {
    background: #4c956c;
}

.container button:disabled {
    background: #b7e4c7;
    color: #fff;
    cursor: not-allowed;
}

.container #quiz-options, 
.container #final-options {
    margin: 18px 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.container #quiz-options button,
.container #final-options button {
    background: #fefee3;
    color: #2c6e49;
    border: 1px solid #b7e4c7;
    border-radius: 6px;
    padding: 10px;
    font-size: 1rem;
    text-align: left;
    transition: background 0.2s, color 0.2s;
}

.container #quiz-options button:hover,
.container #final-options button:hover {
    background: #b7e4c7;
    color: #fff;
}

.container #quiz-options button.selected,
.container #final-options button.selected {
    background: #2c6e49;
    color: #fff;
}

.container #quiz-options button.wrong,
.container #final-options button.wrong {
    background: #e07a5f;
    color: #fff;
}

.container .hidden {
    display: none !important;
}

/* Dashboard styling */
.container #dashboard {
    margin-top: 24px;
}

.container .dashboard-module {
    border: 1px solid #b7e4c7;
    border-radius: 8px;
    background: #f8fafc;
    margin-bottom: 18px;
    padding: 16px 12px;
}

.container .dashboard-module h3 {
    margin: 0 0 6px 0;
    color: #2c6e49;
}

.container .dashboard-module p {
    margin: 4px 0;
}

.container .dashboard-module button {
    margin-right: 10px;
    margin-top: 10px;
    padding: 7px 16px;
    font-size: 0.97em;
}

/* Certificate styling */
.container #certificate-container {
    text-align: center;
    padding: 32px 0;
    border: 2px solid #4c956c;
    border-radius: 12px;
    background: #fefee3;
    margin-top: 16px;
}

.container #certificate-name {
    font-weight: bold;
    color: #2c6e49;
    font-size: 1.2em;
}

/* Responsive design */
@media (max-width: 700px) {
    .container {
        max-width: 98vw;
        padding: 12vw 2vw 8vw 2vw;
    }
    .container h1 {
        font-size: 1.3em;
    }
    .container h2 {
        font-size: 1.1em;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 8vw 1vw 6vw 1vw;
    }
    .container h1 {
        font-size: 1.1em;
    }
}

/* Prevent container from overlapping header/footer */
.container {
    margin-bottom: 40px;
    margin-top: 40px;
}

/* Responsive and visually appealing image at the top of the training container */
.container .training-title-img {
    display: block;
    margin: 0 auto 24px auto;
    max-width: 260px;
    width: 90%;
    height: auto;
    border-radius: 10px;
    box-shadow: 0 2px 12px rgba(44, 110, 73, 0.08);
    object-fit: contain;
    background: #f8fafc;
    /* Prevents cropping and keeps aspect ratio */
}

/* On very small screens, reduce max-width for better fit */
@media (max-width: 500px) {
    .container .training-title-img {
        max-width: 98vw;
        margin-bottom: 16px;
    }
}