button[disabled]:hover {
    cursor: not-allowed;
}


/**
 * Main container
 */


.ai-grammar-fixer-container {
    border: 1px solid #e6e7eb;
    padding: 1.5rem;
    width: 100%;
}

/**
 * Textareas
 */

textarea {
    flex-grow: 1;
    width: 100%;
    resize: none;
}

.textareas {
    display: flex;
    gap: 1rem;
    width: 100%;
}

.input-textarea {
    position: relative;
    border: 1px solid #CED4DA;
    border-radius: 0.25rem;
    transition: height 0.2s ease-in-out, border-color 0.2s ease, box-shadow 0.2s ease;
    padding: 0.5rem 0.75rem;
}

.input-textarea:focus-within {
    border-color: #80bdff;
    outline: 0;
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, .25);
}

.content-container {
    position: relative;
    display: flex;
    justify-content: space-between;
    height: 100%;
    flex-direction: column;
}

.content-textarea {
    display: flex;
    flex-grow: 1;
    flex-direction: column;
    height: 25em;
}

.result-textarea-container {
    background-color: #F5F7F9;
    display: flex;
    width: 100%;
    flex-grow: 1;
    flex-direction: column;
    border: 1px solid #CED4DA;
    border-radius: 0.25rem;
    padding: 0.5rem 0.75rem;
}

.result-textarea {
    background-color: #F5F7F9;
    outline: none;
    border: none
}

.result-textarea[focus] {
    outline: none;
}

.result-container {
    display: flex;
    flex-direction: column;
    width: 100%;
    height: 25em;
}

.action-btn-container {
    position: absolute;
    background-color: white;
    bottom: 1rem;
    right: 1rem;
}

.action-btn {
    position: relative;
    width: fit-content;
    display: inline-block;
    margin: 0;
}


@media screen and (max-width: 991px) {
    .textareas {
        display: flex;
        flex-direction: column;
    }

    .content-container,
    .result-container {
        width: 100%;
        margin-bottom: 1rem;
    }

}

.textareas > div {
    width: 100%;
}

.top-right-btn {
    position: absolute;
    top: 0;
    right: 0;
    margin: 0;
    width: 1.5rem;
    height: 1.5rem;
    padding: 0;
    display: flex;
    justify-content: center;
    align-items: center;
}

.top-right-btn svg {
    opacity: 0.8;
    transition: transform 0.1s ease-out, opacity 0.1s ease-out;
}

.top-right-btn:hover svg {
    opacity: 1;
}

.top-right-btn.hide {
    opacity: 0;
    pointer-events: none;
}

/**
 * Skeleton loaders
 */

@keyframes skeleton-loader-fade {
    0% {
        opacity: 0;
        transform: translateX(-100%);
    }

    50% {
        opacity: 1;
        transform: translateX(0);
    }

    100% {
        opacity: 0;
        transform: translateX(100%);
    }
}

.result-skeleton {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    padding-top: 0.25rem;
}

.result-skeleton-line {
    background: #CED4DA;
    max-width: 15rem;
    height: 1rem;
    border-radius: 0.25rem;
    margin-bottom: 0.5rem;
    position: relative;
    overflow: hidden;
}

.result-skeleton-line::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: linear-gradient(to right, transparent 0%, #e6e7eb 50%, transparent 100%);
    animation: skeleton-loader-fade 1.5s linear infinite;
}

.result-skeleton-line:nth-child(1) {
    width: 6rem;
    margin-bottom: 1.5rem;
}

.result-skeleton-line:nth-last-child(3) {
    margin-bottom: 1.5rem;
}

.result-skeleton-line:nth-last-child(2) {
    width: 5rem;
}

.result-skeleton-line:nth-last-child(1) {
    width: 3rem;
}

/**
 * Result sub-container
 */

.result-sub-container {
    display: flex;
    flex-grow: 1;
    position: relative;
}

/**
 * Error
 */

.result-error {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 0 2rem;
    width: 100%;
    height: 100%;
}

.result-error span {
    text-align: center;
    color: #6C757D;
}

.result-error .retry-btn {
    background: white;
    color: #000000A1;
    border: 1px solid #D4D9DF;
    padding: 0.4rem 0.75rem;
}

.result-error .retry-btn:hover {
    color: #000000;
}

