.input-container {
    display: flex;
    flex-direction: column;
    gap: .25rem;
    width: 100%;
    flex-grow: 1;

    input {
        width: 100%;
        height: 2.75rem;
        border-radius: 6.25rem;
        border: .0625rem solid var(--gray-25);
        background-color: var(--gray-0);
        padding: .75rem 1rem;
        font-family: "Onest", sans-serif;
        font-optical-sizing: auto;
        font-style: normal;
        font-weight: 400;
        font-size: 1rem;
        color: var(--gray-800);

        &::placeholder {
            color: var(--gray-300);
            font-family: "Onest", sans-serif;
            font-optical-sizing: auto;
            font-style: normal;
            font-weight: 400;
            font-size: 1rem;
        }

        &:focus {
            outline: none;
            border: .0625rem solid var(--orange);
        }
    }

    .hint {
        display: none;
        font-family: "Onest", sans-serif;
        font-optical-sizing: auto;
        font-style: normal;
        font-weight: 400;
        font-size: .875rem;
        color: var(--action-red);
    }

    &.error {
        input {
            border-color: var(--action-red);
            color: var(--action-red);
        }

        .hint {
            display: block;
        }
    }

    &.success {
        input {
            border-color: var(--action-green);
            color: var(--action-green);
        }
    }
}


.button-fill {
    background-color: #F85628;
    border-radius: 6.25rem;
    color: var(--gray-0);
    font-family: "Onest", sans-serif;
    font-optical-sizing: auto;
    font-style: normal;
    font-weight: 500;
    font-size: 1rem;
    padding: .75rem 1rem;
    display: flex;
    gap: .5rem;
    justify-content: center;
    align-items: center;
    border: none;
    cursor: pointer;
    width: 100%;
    flex-grow: 1;
    transition: 0.4s ease;

    &:disabled {
        opacity: 0.3;
        pointer-events: none;
    }

    &:hover {
        background-color: #C7360D;
    }

    &.icon {
        max-width: fit-content;
        height: 100%;
        aspect-ratio: 1/1;
        padding: .625rem;
    }
}

.button-outline {
    background-color: var(--gray-0);
    border-radius: 6.25rem;
    color: #F85628;
    font-family: "Onest", sans-serif;
    font-optical-sizing: auto;
    font-style: normal;
    font-weight: 500;
    font-size: 1rem;
    padding: calc(.75rem - .0625rem) 1rem;
    display: flex;
    gap: .5rem;
    justify-content: center;
    align-items: center;
    border: .0625rem solid var(--gray-25);
    cursor: pointer;
    width: 100%;
    min-height: 2.75rem;
    flex-grow: 1;
    transition-property: border, color;
    transition-duration: .2s;
    transition-timing-function: ease-in-out;

    &:hover {
        border: .0625rem solid #C7360D;
        color: #C7360D;
    }

    &:disabled {
        opacity: 0.5;
        pointer-events: none;
    }

    &.icon {
        width: 2.75rem;
        height: 2.75rem;
        aspect-ratio: 1/1;
        padding: .625rem;
        flex-grow: 0;
    }
}



.exercises-option {
    max-width: 77.875rem;
    margin: 0 auto;
    box-sizing: content-box;

    .header:not(.exercise-header) {
        display: flex;
        align-items: end;
        justify-content: space-between;
        margin-bottom: 1.5rem;
        gap: 1rem;

        .title {
            font-size: 2rem;
            font-weight: 700;
            color: #2A1C14;
            font-family: "Source Serif 4", serif;
        }

        .top-bar {
            max-width: 31.875rem;
            width: fit-content;
            height: 5.75rem;
            flex-grow: 1;
            display: flex;
            align-items: center;
            justify-content: space-between;
            flex-direction: row;

            .button-prev {
                color: #919292;
                padding: .875rem;

                &:hover {
                    color: #C7360D;
                }
            }

            .box {
                display: flex;
                align-items: center;
                gap: 1.625rem;

                .counter {
                    color: #000000;
                    font-size: 1.125rem;
                    font-weight: 600;
                    white-space: nowrap;

                    .current {
                        color: #F85628;
                    }
                }

                .button-check {
                    width: 10.6875rem;
                }

                .button-repeat {
                    display: none;
                    width: 9.125rem;
                }

                .button-next {
                    display: none;
                    width: 15rem;
                }
            }
        }
    }

    .task-wrapper {
        display: flex;
        gap: 1rem;

        .task {
            max-width: 45rem;
            height: 36.25rem;
            flex-grow: 1;

            .additional-play-btn {
                display: flex;
                align-items: center;
                justify-content: center;
                width: 100%;
                height: 13.0625rem;
                background-color: var(--gray-15);
                border-radius: 1rem;
                margin-bottom: 1rem;
                position: relative;
                overflow: hidden;

                [alt="play"] {
                    display: block;
                }

                [alt="stop"] {
                    display: none;
                }

                button {
                    width: 6.25rem;
                    height: 6.25rem;
                    border-radius: 6.25rem;
                    display: flex;
                    align-items: center;
                    justify-content: center;
                    border: none;
                    background-color: #F85628;
                    cursor: pointer;
                    position: relative;
                    z-index: 1;

                    &.is-playing {
                        [alt="play"] {
                            display: none;
                        }

                        [alt="stop"] {
                            display: block;
                        }
                    }
                }

                .flowers {
                    pointer-events: none;
                    user-select: none;

                    svg {
                        position: absolute;
                    }

                    svg:nth-child(1) {
                        top: 0;
                        left: 0;
                    }

                    svg:nth-child(2) {
                        bottom: 0;
                        right: 2.75rem;
                    }
                }
            }

            .transcription {
                display: block;
                height: auto;
                overflow: auto;
                padding: 1rem 0;
                scrollbar-width: none;
                -ms-overflow-style: none;
                scroll-margin-top: 6.25rem;

                &::-webkit-scrollbar {
                    display: none;
                }

                pre {
                    white-space: pre-wrap;
                    word-break: break-all;
                    font-family: var(--font-onest);
                    font-size: 1rem;
                    font-weight: 400;
                    color: #000000;
                }
            }
        }

        .button-to-transcription {
            display: none;
        }

        .answer {
            max-width: 31.875rem;
            flex-grow: 1;
            height: 36.25rem;
            padding: 0;
            overflow: hidden;

            .correct-answers {
                display: none;
                position: absolute;
                left: 0;
                top: 0;
                padding: 1.5rem;
                padding-bottom: 0;
                background-image: linear-gradient(#FFFFFFF2, #FFFFFF00);
                width: 100%;            }

            .scroll-container {
                padding: 1.5rem;

                .question {
                    padding-top: 12.5rem;
                    background-image: url('../../../../img/exercises/common/answer_frame.svg');
                    background-repeat: no-repeat;
                    background-size: 26.5625rem;
                    background-position: center 1.5rem;
                    display: flex;
                    align-items: center;
                    flex-direction: column;
                    height: 32.125rem;
                    flex-shrink: 0;

                    .title {
                        color: #2A1C14;
                        font-size: 1.5rem;
                        font-weight: 600;
                        margin-bottom: .5rem;
                    }

                    .subtitle {
                        color: var(--gray-500);
                        font-size: 1rem;
                        font-weight: 400;
                        margin-bottom: 1.5rem;
                    }

                    .label {
                        color: #2A1C14;
                        font-size: 1rem;
                        font-weight: 400;
                        margin-bottom: .75rem;
                    }

                    .input-container {
                        width: 16.1875rem;
                        flex-grow: 0;
                    }
                }

                .explanation {
                    display: none;

                    .collapsible-content {
                        transition: all .3s ease-in-out;

                        p {
                            color: #F85628;
                            font-size: .875rem;
                            font-weight: 400;
                            margin-top: 1rem;
                            margin-bottom: 1.5rem;
                        }

                        pre {
                            font-family: var(--font-onest);
                            font-weight: 400;
                            font-size: .875rem;
                            white-space: pre-wrap;
                            word-break: break-all;
                            color: #000000;
                        }
                    }
                }
            }
        }    }}

.result {
    .header:not(.exercise-header) {
        .top-bar {
            .box {
                gap: .5rem;

                .counter {
                    display: none;
                }

                .button-check {
                    display: none;
                }

                .button-repeat {
                    display: flex;
                }

                .button-next {
                    display: flex;
                }
            }
        }
    }

    .task-wrapper {
        .task {
            height: auto;

            .transcription {
                display: block;
                height: auto;
                min-height: 0;
                padding-top: 1rem;
            }
        }

        .answer {
            position: relative;

            .correct-answers {
                display: block;


}

            .scroll-container {
                overflow: auto;
                padding-bottom: .625rem;
                scrollbar-width: none;
                -ms-overflow-style: none;

                &::-webkit-scrollbar {
                    display: none;
                }

                .explanation {
                    display: block;
                }
            }

        }
    }}

@media (max-width: 64rem) {
    .exercises-option {
        .task-wrapper {
            flex-direction: column;
            align-items: center;
            gap: 1.5rem;

            .paper {
                border: none;
                padding: 0;
            }

            .task {
                max-width: 100%;
                height: fit-content;
                padding-bottom: 1.5rem;
                border-bottom: .0625rem solid var(--gray-25);
                border-radius: 0;
                padding: 0;

                .additional-play-btn {
                    display: none;
                }
            }

            .answer {
                max-width: 20.5rem;
                min-height: 22.8125rem;
                height: fit-content;
                width: 100%;
                border-radius: 0;

                .correct-answers {
                    position: relative;
                    background-image: none;
                    padding: 0;
                    margin-bottom: 1rem;
                }

                .scroll-container {
                    overflow: visible;
                    padding: 0;

                    .question {
                        padding-top: 7.375rem;
                        background-size: contain;
                        background-position: center;
                        height: 22.8125rem;

                        .input-container {
                            width: 11.8125rem;
                        }
                    }
                }
            }        }
    }
}

@media (max-width: 48rem) {
    .exercises-option {
    .header:not(.exercise-header) {
            flex-direction: column-reverse;
            align-items: start;
            margin-bottom: 2rem;

            .title {
                font-family: "Onest", sans-serif;
                font-size: 1.5rem;
                font-weight: 600;
            }

            .top-bar {
                border: none;
                padding: 0;
                gap: 1rem;
                height: fit-content;

                .box {
                    .counter {
                        font-size: 1rem;
                    }

                    .button-check {
                        display: none;
                    }
                }
            }
        }
    }

    .result {
    .header:not(.exercise-header) {
            .top-bar {
                .box {
                    .counter {
                        display: block;
                    }

                    .button-repeat {
                        display: none;
                    }

                    .button-next {
                        display: none;
                    }
                }
            }
        }

    }
}

@media (max-width: 64rem) {
    .exercise-section .exercises-option[data-template="option_1"]:not(.result) .task .additional-play-btn {
        display: flex;
    }
}
