.cel-app {
    max-width: 1150px;
    margin: 30px auto;
    font-family: Arial, sans-serif;
    color: #172033;
    background: #f4f8fc;
    border-radius: 22px;
    overflow: hidden;
    box-shadow: 0 18px 55px rgba(20, 50, 90, .16);
}

.cel-header {
    padding: 28px 32px;
    color: white;
    background: linear-gradient(135deg, #102a62, #2878d5);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.cel-header h2 {
    color: white;
    margin: 0;
    font-size: 28px;
}

.cel-header p {
    margin: 7px 0 0;
    opacity: .85;
}

.cel-score-box {
    background: rgba(255,255,255,.15);
    border-radius: 15px;
    padding: 12px 20px;
    text-align: center;
}

.cel-score-box span,
.cel-score-box strong {
    display: block;
}

.cel-score-box strong {
    font-size: 28px;
}

.cel-game-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
    padding: 18px;
    background: white;
}

.cel-stat {
    padding: 12px;
    text-align: center;
    background: #f4f8fc;
    border-radius: 12px;
}

.cel-stat span {
    display: block;
    font-size: 12px;
    color: #66778a;
}

.cel-stat strong {
    display: block;
    margin-top: 3px;
    font-size: 22px;
}

.cel-layout {
    display: grid;
    grid-template-columns: 240px 1fr;
    gap: 0;
}

.cel-levels {
    padding: 22px;
    background: #e8f0fa;
}

.cel-levels h3 {
    margin-top: 0;
}

.cel-level-button {
    width: 100%;
    text-align: left;
    margin-bottom: 9px;
    padding: 13px;
    border: 1px solid #d1dceb;
    border-radius: 12px;
    background: white;
    cursor: pointer;
    color: #18365f;
    transition: .2s;
}

.cel-level-button:hover:not(:disabled) {
    transform: translateY(-2px);
    border-color: #347ed1;
}

.cel-level-button.active {
    color: white;
    background: #2878d5;
    border-color: #2878d5;
}

.cel-level-button.locked {
    opacity: .55;
    cursor: not-allowed;
}

.cel-level-button small {
    display: block;
    margin-top: 4px;
    opacity: .75;
}

.cel-game {
    padding: 30px;
}

.cel-game h3 {
    margin-top: 0;
    font-size: 23px;
}

.cel-instruction {
    color: #66778a;
    margin-bottom: 15px;
}

.cel-game-visual {
    min-height: 190px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    margin-bottom: 20px;
}

.cel-lab-icon {
    font-size: 90px;
}

.cel-ph-scale {
    width: 90%;
    height: 25px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 8px;
    border-radius: 20px;
    color: white;
    font-size: 11px;
    background: linear-gradient(
        90deg,
        #e31b3f,
        #ff7b00,
        #ffe047,
        #35c96f,
        #21a7db,
        #4c54d9,
        #7929a6
    );
}

.cel-beaker {
    position: relative;
    width: 160px;
    height: 165px;
    border: 5px solid #8ea0b3;
    border-top: 0;
    border-radius: 0 0 32px 32px;
    overflow: hidden;
    background: rgba(255,255,255,.5);
}

.cel-liquid {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 65%;
    background: #83d5ff;
}

.cel-liquid.neutral {
    background: #82d99b;
}

.cel-bubble {
    position: absolute;
    bottom: 15px;
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: rgba(255,255,255,.8);
    animation: celBubble 2s infinite;
}

.cel-bubble.b1 {
    left: 30%;
}

.cel-bubble.b2 {
    left: 55%;
    animation-delay: .5s;
}

.cel-bubble.b3 {
    left: 70%;
    animation-delay: 1s;
}

@keyframes celBubble {
    100% {
        transform: translateY(-120px);
        opacity: 0;
    }
}

.cel-equation-preview {
    margin-top: 15px;
    font-size: 20px;
    font-weight: bold;
}

.cel-periodic-symbol {
    width: 120px;
    height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 15px;
    background: #2878d5;
    color: white;
    font-size: 55px;
    font-weight: bold;
    box-shadow: 0 12px 30px rgba(40,120,213,.25);
}

.cel-periodic-name {
    margin-top: 10px;
    font-weight: bold;
}

.cel-molecule {
    display: flex;
    align-items: center;
    gap: 25px;
    font-size: 55px;
    font-weight: bold;
}

.cel-molecule span {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 70px;
    height: 70px;
    border-radius: 50%;
    background: #e1f2ff;
    border: 3px solid #58a8dc;
}

.cel-molecule-label {
    margin-top: 12px;
    color: #60758a;
}

.cel-reaction-animation {
    font-size: 60px;
}

.cel-reaction-label {
    color: #60758a;
    margin-top: 10px;
}

.cel-choices {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.cel-answer {
    padding: 16px;
    border: 1px solid #d3deeb;
    border-radius: 13px;
    background: white;
    cursor: pointer;
    text-align: left;
    font-size: 16px;
    transition: .2s;
}

.cel-answer:hover:not(:disabled) {
    border-color: #2878d5;
    transform: translateY(-2px);
}

.cel-answer span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    margin-right: 9px;
    border-radius: 50%;
    background: #e7eef8;
    font-weight: bold;
}

.cel-answer.correct {
    background: #dcfce7;
    border-color: #22c55e;
}

.cel-answer.wrong {
    background: #fee2e2;
    border-color: #ef4444;
}

.cel-message {
    margin-top: 16px;
    padding: 15px;
    min-height: 45px;
    border-radius: 12px;
    background: #edf4fb;
}

.cel-progress {
    height: 9px;
    margin-top: 16px;
    overflow: hidden;
    border-radius: 20px;
    background: #dbe5ef;
}

#cel-progress-bar {
    height: 100%;
    width: 0;
    background: #2878d5;
    transition: width .4s;
}

.cel-progress-text {
    display: block;
    margin-top: 6px;
    color: #718096;
    font-size: 12px;
}

.cel-result {
    display: none;
    padding: 45px 25px;
    text-align: center;
}

.cel-result.show {
    display: block;
}

.cel-result-icon {
    font-size: 65px;
}

.cel-result h2 {
    font-size: 30px;
}

.cel-next,
.cel-restart {
    margin-top: 20px;
    padding: 14px 25px;
    border: 0;
    border-radius: 12px;
    background: #2878d5;
    color: white;
    cursor: pointer;
    font-weight: bold;
    font-size: 16px;
}

.hidden {
    display: none !important;
}

@media (max-width: 750px) {

    .cel-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }

    .cel-game-stats {
        grid-template-columns: repeat(2, 1fr);
    }

    .cel-layout {
        grid-template-columns: 1fr;
    }

    .cel-choices {
        grid-template-columns: 1fr;
    }

    .cel-game {
        padding: 20px;
    }
}
