:root {
    --primary-color: #f05f3e;
    --primary-hover: #e04d2c;
    --primary-light: rgba(240, 95, 62, 0.1);
    --gray-100: #f3f4f6;
    --gray-200: #e5e7eb;
}

.output-group-btn {
    gap: 0.5rem;
}

.floating-magic-btn {
    position: absolute;
    bottom: 10px;
    right: 10px;

    cursor: pointer;
}

.magic-btn {
    border: none;
    background: none;
    padding: 0;
    font: inherit;
    color: inherit;
    cursor: pointer;
}

.floating-magic-btn .text-primary {
    font-size: 12px;
    font-weight: bold;
}

.story-card {
    /* background: linear-gradient(145deg, #ffffff 0%, var(--gray-100) 100%); */
    border: none;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.03);
    border-radius: 10px;
    padding: 2rem;
}

.story-input {
    border: 2px solid var(--gray-200);
    border-radius: 10px;
    transition: all 0.3s ease;
    font-size: 1.1rem;
    line-height: 1.7;
    padding: 1.5rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.02);
    resize: none;
}

.story-input:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 4px var(--primary-light);
}

.model-select {
    background-color: var(--gray-100);
    border-radius: 12px;
    padding: 1rem;
    font-weight: 500;
    border: 2px solid var(--gray-200);
    transition: all 0.3s ease;
}

.model-select:hover {
    border-color: var(--primary-color);
}

.advanced-btn {
    background: #ffffff;
    border: 2px solid var(--gray-200);
    border-radius: 4px;
    transition: all 0.3s ease;
    padding: 1rem 1.5rem;
}

.write-btn {
    background: linear-gradient(145deg, var(--primary-color) 0%, var(--primary-hover) 100%);
    border: none;
    padding: 1.2rem 3.5rem;
    font-weight: 600;
    letter-spacing: 0.5px;
    border-radius: 16px;
    transition: all 0.3s ease;
    color: white;
}

.write-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px var(--primary-light);
}

.output-card {
    border-radius: 16px;
    border: none;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.05);
}

.output-content {
    min-height: 200px;
    /* padding: 1.5rem; */
    font-size: 1.1rem;
    line-height: 1.8;
}

.action-btn {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    background: white;
    border: 2px solid var(--gray-200);
}

.action-btn:hover {
    background: var(--primary-color);
    color: white !important;
    /* transform: translateY(-1px); */
}

.text-primary {
    color: var(--primary-color) !important;
}

.btn-primary {
    background-color: var(--primary-color) !important;
    border-color: var(--primary-color) !important;
}

.btn-primary:hover {
    background-color: var(--primary-hover) !important;
    border-color: var(--primary-hover) !important;
}

.badge.bg-primary {
    background-color: var(--primary-color) !important;
}

.story-output {
    background: linear-gradient(145deg, #ffffff 0%, #fafafa 100%);
    border: 1px solid #e9ecef;
    border-radius: 15px;
    transition: all 0.3s ease;
}

.story-output:hover {
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
}

.output-content {
    /* padding: 2rem; */
    font-size: 1.1rem;
    line-height: 1.8;
    color: #2d3436;
    min-height: 200px;
}

.output-footer {
    padding: 1rem 2rem;
    border-top: 1px solid #e9ecef;
    background: #fafafa;
    border-bottom-left-radius: 15px;
    border-bottom-right-radius: 15px;
}

/* Mobile friendly output-footer */
@media (max-width: 576px) {
    .output-footer {
        padding: 0.75rem 0.5rem;
        font-size: 0.97rem;
        border-radius: 0 0 12px 12px;
        text-align: center;
    }

    .output-footer .word-count {
        padding: 0.5rem 1rem;
        font-size: 0.97rem;
        justify-content: center;
        width: 100%;
    }
}

.action-btn {
    width: 38px;
    height: 38px;
    border-radius: 10px;
    background: #fff;
    border: 1px solid #e9ecef;
    color: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
}


.word-count {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    background: var(--primary-light);
    color: var(--primary-color);
    border-radius: 12px;
    font-weight: 500;
}

.output-footer {
    padding: 1rem 2rem;
    border-top: 1px solid #e9ecef;
    background: #fafafa;
    border-bottom-left-radius: 15px;
    border-bottom-right-radius: 15px;
}

@media (max-width: 768px) {
    .container {
        padding: 0 0.5rem !important;
    }

    .story-card {
        padding: 1rem;
        margin: 0 -0.5rem;
        border-radius: 0;
    }

    .card-body {
        padding: 0.5rem !important;
    }

    .form-outline.mb-4 {
        margin-bottom: 1rem !important;
    }

    .story-input {
        padding: 0.75rem;
        font-size: 1rem;
    }

    .mb-4 {
        margin-bottom: 1rem !important;
    }

    .mt-5 {
        margin-top: 1.5rem !important;
    }

    .mt-4 {
        margin-top: 1rem !important;
    }

    .py-4 {
        padding-top: 1rem !important;
        padding-bottom: 1rem !important;
    }
}

/* Mobile Landscape */
@media (max-width: 576px) {
    .story-card {
        margin: -1rem;
        border-radius: 0;
    }

    .d-flex.align-items-center.mb-4 {
        flex-direction: column;
        text-align: center;
        gap: 1rem;
    }

    .avatar.me-3 {
        margin: 0 !important;
    }
}

/* Small height screens */
@media (max-height: 700px) {
    .story-input {
        max-height: 150px;
        overflow-y: auto;
    }
}



.theme-dark,
.theme-dark>div[class*='bg-'] {
    background-color: #051139 !important;
}

.theme-dark #input,
.theme-dark input,
.theme-dark textarea,
.theme-dark select,
.theme-dark #grid li,
.theme-dark #model,
.theme-dark .font-weight-medium,
.theme-dark #content-box,
.theme-dark .accordion-button,
.theme-dark .a2a_floating_style,
.theme-dark #parallax {
    background-color: #1b2434 !important;
    color: #f8fafc !important;
    border-color: #2c3c56 !important;
}

.theme-dark .mask {
    background: #1b2434 !important;
}

.theme-dark .css-typing,
.theme-dark .form-outline.mb-2.form-control.zero-clipboard.shadow-sm,
.theme-dark .accordion-body button,
.theme-dark em.lable_txt,
.theme-dark .swal2-html-container {
    background-color: #1b2434 !important;
    color: #f8fafc !important;
    border-color: #2c3c56 !important;
}

.theme-dark .dropdown-item,
.theme-dark .navbar .nav-link,
.theme-dark .navbar .navbar-brand,
.theme-dark .footer {
    color: hsla(0, 0%, 100%, 0.8) !important;
}

.theme-dark .highlight {
    background-color: #e65252 !important;
}

.theme-dark .btn-remove,
.theme-dark .lable_txt {
    color: wheat !important;
    padding-left: 11px;
}

.theme-dark .card p,
.theme-dark .dropdown .dropdown-menu p,
.theme-dark .kanban-board p,
.theme-dark .fw-light,
.theme-dark .swal2-popup p {
    color: #fff !important;
    opacity: 0.6;
}

.theme-dark div#input_custom p:hover {
    cursor: pointer;
    background-color: #5e5e5e;
}








.my-ads.form-check.d-flex {
    padding-left: 0 !important;
}

.donations {
    background-color: #f05f3e !important;
    cursor: pointer;
    color: white !important;
}

#example {
    user-select: none;
    /* For modern browsers */
    -webkit-user-select: none;
    /* For Safari */
    -moz-user-select: none;
    /* For Firefox */
    -ms-user-select: none;
    /* For Internet Explorer/Edge */
}

#content-box .card-body {
    padding: 2.5vw;
}

.css-typing table {
    border-collapse: collapse;
    width: 100%;
    margin: 20px 0px;
    background-color: #f9f9f9;
}

.css-typing td,
th {
    border: 1px solid #aaaaaa;
    text-align: left;
    padding: 8px;
}


.css-typing thead {
    background-color: #dddddd;
}



.css-typing .h1,
.css-typing h1 {
    font-size: 1.7rem !important;
}

div.form-outline.form-control.zero-clipboard.shadow-sm {
    background-color: rgb(232 243 254 / 70%) !important;
}

p.p-2.text-muted {
    padding: 10px 0px 0px 0px !important;
    margin: 0;
}

label.form-label.range-lable.text-muted.pt-2 {
    margin: 0 !important;
}

.form-outline.mb-2.form-control.zero-clipboard.shadow-sm {
    border: 2px dashed #97c7c0;
}


.badge {
    margin: 0 2px !important;
}

.form-check.d-flex.justify-content-center.mb-4.w-100 {
    /*background: antiquewhite;*/
    min-height: 65px;
}

body {
    font-family: 'Arial', sans-serif !important;
}

button#main_btn {
    padding: 7px 50px;
    font-size: 17px;
    font-weight: bold;
}

#main_btn::before {
    content: "";
    display: none;
    /* Hide the custom image, use FontAwesome icon instead */
}

.voice_btn {
    position: absolute;
    right: 28px;
    top: 114px;
    opacity: .7;
    cursor: pointer;
    width: 25px;
    height: 25px;
}

.range-lable {
    float: none !important;
}


@media screen and (min-width: 1201px) {
    .range-lable {
        position: relative;
        top: -28px;
        right: -504px;
    }
}


.btn {
    background: #f05f3e !important;
    border-color: #f05f3e !important;
}

.btn:focus {
    outline: 0;
    box-shadow: 0 0 0 0.25rem rgb(255 87 34 / 22%) !important;
}

::-moz-selection {
    /* Code for Firefox */
    background: #f05f3e;
    color: white;
}

::selection {
    background: #f05f3e;
    color: white;
}


.bg {
    background: #ed3269;
    background: -moz-linear-gradient(to left, #ed3269, #f05f3e);
    background: -webkit-linear-gradient(to left, #ed3269, #f05f3e);
    background: linear-gradient(to left, #ed3269, #f05f3e);
    opacity: 0.9;
}

body,
.card .card-body {
    font-family: 'Arial', sans-serif !important;
}

.card {
    padding-bottom: 15px;
}

.bg-toolbaz {
    background-color: #f05f3e;
}

.output-txt {
    font-family: Arial, sans-serif;
}

@media (max-width: 991.98px) {
    .lable_txt {
        display: none;
    }

    button em {
        display: none;
    }
}

@media only screen and (min-width: 992px) {
    #sidebar {
        position: sticky;
        align-self: end;
        bottom: 2px;

    }
}

.css-typing {
    font-family: Arial, sans-serif;
}


.zero-clipboard {
    position: relative;
}

.btn-clipboard {
    position: absolute;
    top: -8px;
    right: -8px;
    border-radius: 3px;

}

#copy {
    background-image: url(https://toolbaz.com/assets/img/copy.png);
    text-align: center;
    background-repeat: no-repeat;
    width: 20px;
    height: 20px;
    background-size: contain;
    opacity: 50%;
}

.copyed {
    opacity: 70% !important;
    width: 22px !important;
    height: 22px !important;
}

.btn-remove {
    position: absolute;
    background-color: transparent !important;
    left: 0px;
    top: 15px;
    z-index: 99;
    opacity: 0.7;
}

em {
    font-size: unset !important;
    /* padding: unset !important;
    color: unset !important; */
}

em.lable_txt {
    background: aliceblue;
    padding: 3px;
    border-radius: 5px;
    margin-left: 5px;
}

#main_btn i {
    padding: 5px;
}

#output:focus {
    outline: none;
}

#output:focus-visible {
    outline: none;
}



.swal2-container {
    display: grid;
    position: fixed;
    z-index: 1060;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    box-sizing: border-box;
    grid-template-areas: "top-start     top            top-end" "center-start  center         center-end" "bottom-start  bottom-center  bottom-end" "gap gap gap";
    grid-template-rows: auto auto auto .625em;
    height: 100%;
    padding: .625em .625em 0;
    overflow-x: hidden;
    transition: background-color .1s;
    -webkit-overflow-scrolling: touch
}

.swal2-container::after {
    content: "";
    grid-column: 1/4;
    grid-row: 4;
    height: .625em
}

.swal2-container.swal2-backdrop-show,
.swal2-container.swal2-noanimation {
    background: rgba(0, 0, 0, .4)
}


.swal2-container.swal2-bottom,
.swal2-container.swal2-center,
.swal2-container.swal2-top {
    grid-template-columns: auto minmax(0, 1fr) auto
}

.swal2-container.swal2-center>.swal2-popup {
    grid-column: 2;
    grid-row: 2;
    align-self: center;
    justify-self: center
}

.swal2-popup {
    display: none;
    position: relative;
    box-sizing: border-box;
    width: 32em;
    max-width: 100%;
    padding: 0 0 1.25em;
    border: none;
    border-radius: 5px;
    background: #fff;
    font-family: inherit;
    font-size: 1rem
}


.swal2-title {
    position: relative;
    max-width: 100%;
    margin: 0;
    padding: .8em 1em 0;
    color: #595959;
    font-size: 1.875em;
    font-weight: 600;
    text-align: center;
    text-transform: none;
    word-wrap: break-word
}

.swal2-actions {
    display: flex;
    z-index: 1;
    box-sizing: border-box;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    width: 100%;
    margin: 1.25em auto 0;
    padding: 0
}

.swal2-loader {
    display: none;
    align-items: center;
    justify-content: center;
    width: 2.2em;
    height: 2.2em;
    margin: 0 1.875em;
    -webkit-animation: swal2-rotate-loading 1.5s linear 0s infinite normal;
    animation: swal2-rotate-loading 1.5s linear 0s infinite normal;
    border-width: .25em;
    border-style: solid;
    border-radius: 100%;
    border-color: #2778c4 transparent #2778c4 transparent
}

.swal2-styled {
    margin: .3125em;
    padding: .625em 1.1em;
    transition: box-shadow .1s;
    box-shadow: 0 0 0 3px transparent;
    font-weight: 500
}

.swal2-styled:not([disabled]) {
    cursor: pointer
}

.swal2-styled.swal2-confirm {
    border: 0;
    border-radius: .25em;
    background: initial;
    background-color: #7367f0;
    color: #fff;
    font-size: 1em
}

.swal2-styled.swal2-deny {
    border: 0;
    border-radius: .25em;
    background: initial;
    background-color: #ea5455;
    color: #fff;
    font-size: 1em
}

.swal2-styled.swal2-cancel {
    border: 0;
    border-radius: .25em;
    background: initial;
    background-color: #6e7d88;
    color: #fff;
    font-size: 1em
}

.swal2-footer {
    justify-content: center;
    margin: 1em 0 0;
    padding: 1em 1em 0;
    border-top: 1px solid #eee;
    color: #545454;
    font-size: 1em
}

.swal2-timer-progress-bar-container {
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    grid-column: auto !important;
    height: .25em;
    overflow: hidden;
    border-bottom-right-radius: 5px;
    border-bottom-left-radius: 5px
}

.swal2-timer-progress-bar {
    width: 100%;
    height: .25em;
    background: rgba(0, 0, 0, .2)
}

.swal2-image {
    max-width: 100%;
    margin: 2em auto 1em
}

.swal2-close {
    z-index: 2;
    align-items: center;
    justify-content: center;
    width: 1.2em;
    height: 1.2em;
    margin-top: 0;
    margin-right: 0;
    margin-bottom: -1.2em;
    padding: 0;
    overflow: hidden;
    transition: color .1s, box-shadow .1s;
    border: none;
    border-radius: 5px;
    background: 0 0;
    color: #ccc;
    font-family: serif;
    font-family: monospace;
    font-size: 2.5em;
    cursor: pointer;
    justify-self: end
}

.swal2-html-container {
    z-index: 1;
    justify-content: center;
    margin: 0;
    padding: 1em 1.6em .3em;
    color: #545454;
    font-size: 1.125em;
    font-weight: 400;
    line-height: normal;
    text-align: center;
    word-wrap: break-word;
    word-break: break-word
}

.swal2-checkbox,
.swal2-file,
.swal2-input,
.swal2-radio,
.swal2-select,
.swal2-textarea {
    margin: 1em 2em 0
}

.swal2-file,
.swal2-input,
.swal2-textarea {
    box-sizing: border-box;
    width: auto;
    transition: border-color .1s, box-shadow .1s;
    border: 1px solid #d9d9d9;
    border-radius: .1875em;
    background: inherit;
    box-shadow: inset 0 1px 1px rgba(0, 0, 0, .06), 0 0 0 3px transparent;
    color: inherit;
    font-size: 1.125em
}

.swal2-input {
    height: 2.625em;
    padding: 0 .75em
}

.swal2-file {
    width: 75%;
    margin-right: auto;
    margin-left: auto;
    background: inherit;
    font-size: 1.125em
}

.swal2-textarea {
    height: 6.75em;
    padding: .75em
}

.swal2-select {
    min-width: 50%;
    max-width: 100%;
    padding: .375em .625em;
    background: inherit;
    color: inherit;
    font-size: 1.125em
}

.swal2-checkbox,
.swal2-radio {
    align-items: center;
    justify-content: center;
    background: #fff;
    color: inherit
}

.swal2-validation-message {
    align-items: center;
    justify-content: center;
    margin: 1em 0 0;
    padding: .625em;
    overflow: hidden;
    background: #f0f0f0;
    color: #666;
    font-size: 1em;
    font-weight: 300
}

.swal2-icon {
    position: relative;
    box-sizing: content-box;
    justify-content: center;
    width: 5em;
    height: 5em;
    margin: 2.5em auto .6em;
    border: .25em solid transparent;
    border-radius: 50%;
    border-color: #000;
    font-family: inherit;
    line-height: 5em;
    cursor: default;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none
}

.swal2-icon .swal2-icon-content {
    display: flex;
    align-items: center;
    font-size: 3.75em
}

.swal2-icon.swal2-warning {
    border-color: #facea8;
    color: #f8bb86
}

.swal2-progress-steps {
    flex-wrap: wrap;
    align-items: center;
    max-width: 100%;
    margin: 1.25em auto;
    padding: 0;
    background: inherit;
    font-weight: 600
}

[class^=swal2] {
    -webkit-tap-highlight-color: transparent
}

.swal2-show {
    -webkit-animation: swal2-show .3s;
    animation: swal2-show .3s
}

.swal2-scrollbar-measure {
    position: absolute;
    top: -9999px;
    width: 50px;
    height: 50px;
    overflow: scroll
}

body.swal2-shown:not(.swal2-no-backdrop):not(.swal2-toast-shown) {
    overflow: hidden
}

body.swal2-height-auto {
    height: auto !important
}

.swal2-styled.swal2-default-outline:focus-visible {
    outline: none;

}

.alert-warning {
    color: #856404;
    background-color: #fff3cd;
    border-color: #ffeeba;
}

.alert-dismissible .close {
    position: absolute;
    top: 0;
    right: 0;
    padding: 0.55rem 1.25rem;
    color: inherit;
    cursor: pointer;
    background: transparent;
    border: none;
    font-size: 23px;
}


#show_val {
    padding: 8px 3px;
}

.form-range1 {
    cursor: pointer;
}

.ms-auto {
    margin-left: auto !important;
}

/* Add focus style for input, select, textarea based on primary color */
input:focus,
select:focus,
textarea:focus {
    border-color: var(--primary-color) !important;
    box-shadow: 0 0 0 4px var(--primary-light) !important;
    outline: none !important;
}




img#output-img {
    border-radius: 7px;
}

.suggest {
    background-color: #ffe7d7;
}

#example {
    cursor: pointer;
    color: var(--primary-color) !important;
}

.swal2-container {
    z-index: 999999;
}

.play {
    background-image: none;
    position: absolute;
    bottom: 17px;
    right: 15px;
    border-radius: 3px;
    width: auto;
    height: auto;
    opacity: 0.7;
    cursor: pointer;
    padding: 5px;
}

.play i {
    font-size: 16px;
    color: #666;
}

.play:hover {
    opacity: 1;
}

.highlight {
    background: var(--primary-color);
    color: white;
    padding: 3px 4px;
    border-radius: 4px;

}



.advanced-options-button {
    color: var(--primary-color) !important;

    display: flex;
    padding: 0.4rem 0rem;
    font-size: .875rem;
    text-decoration: underline;
    color: #f76707 !important;
    text-align: left;
    background-color: transparent;
    border: 0;
    border-radius: 0;
    overflow-anchor: none;
    transition: color .15s ease-in-out, background-color .15s ease-in-out, border-color .15s ease-in-out, box-shadow .15s ease-in-out, border-radius .15s ease;
}




.advanced-options-body {
    padding: 15px 10px;
    border: 1px solid #d8d7d7 !important;
    border-radius: 7px;
    margin: 1px;
}

.advanced-options-body select {
    cursor: pointer;
}

.advanced-options-button:not(.collapsed)::after {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23f05f3e'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3e%3c/svg%3e");
    transform: rotate(-180deg);
}

.advanced-options-button::after {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23f05f3e'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-size: 1rem;
    transition: transform .2s ease-in-out;
}


#content-box table {
    margin: 24px 0;
    max-width: 100%;
    border-collapse: collapse;
    text-align: left;
    border-spacing: 0;
    overflow-x: auto;
}

#content-box table td,
#content-box table th {
    padding: 8px 16px;
    border: 1px solid #ccc;
}

.tablediv {
    overflow-x: auto;

}




blockquote {
    margin: 24px;
    padding: 8px 24px;
    border-left: 4px solid #ccc;
    background: #f9f9f9;
}

body {
    font-size: 16px;
}

#content-box p {
    margin: 18px 0;
}

#content-box h2 {
    font-weight: 700;
    font-size: 24px;
    line-height: 33.6px;
    min-height: 33.6px;
    margin: 22px 0;
}

#content-box li {
    margin: 0 0 18px 0;
}

#content-box h3 {
    font-weight: 700;
    font-size: 20px;
    line-height: 28px;
    min-height: 28px;
    margin: 20px 0;
}

#content-box h4 {
    font-weight: 700;
    font-size: 18px;
    line-height: 25px;
    min-height: 25px;
    margin: 20px 0;
}

#content-box h4 {
    font-weight: 700;
    font-size: 17px;
    line-height: 22px;
    min-height: 22px;
    margin: 20px 0;
}




.edit_icon {
    background-image: url(https://toolbaz.com/assets/img/edit.png);
    text-align: center;
    background-repeat: no-repeat;
    width: 20px;
    height: 15px;
    background-size: contain;
    opacity: 100%;
    background-color: transparent;
    display: inline-block;
}


.edit {
    /* position: absolute; */
    text-align: center;
    width: 59px;
    height: 26px;
    bottom: 17px;
    left: 20px;
    border-radius: 3px;
    background-color: #0900008f;
    color: white;
    margin: 5px;
}


.css-typing:focus-visible {
    outline: none;
}




.error-alert {
    background-color: #f8d7da;
    color: #721c24;
    padding: 10px 15px;
    border: 1px solid #f5c6cb;
    border-radius: 5px;
    display: none;
    align-items: center;
    justify-content: space-between;
    width: 300px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
}

.error-alert.show {
    display: flex;
}

.error-alert-close {
    cursor: pointer;
    font-weight: bold;
}

.cookies-wrapper {
    z-index: 9999;
    max-width: 300px;
    width: 100%;
    margin: 0;
    padding: 0;
    border: 0;
    bottom: 0;
    left: auto;
    right: 0;
    top: auto;
    margin: 0 15px 15px 0;
    display: none
}

.position-fixed {
    position: fixed !important;
}

.text-center {
    text-align: center !important;
}

.bg-white {
    --tblr-bg-opacity: 1;
    background-color: rgba(var(--tblr-white-rgb), var(--tblr-bg-opacity)) !important;
}

.py-3 {
    padding-top: 1rem !important;
    padding-bottom: 1rem !important;
}

.px-2 {
    padding-right: .5rem !important;
    padding-left: .5rem !important;
}

.custom-alert {
    position: fixed;
    top: 20px;
    right: 20px;

    background-color: #0000008c;
    color: white;
    padding: 15px;
    border-radius: 5px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    opacity: 0;
    transition: opacity 0.5s ease-in-out;
    z-index: 9999999;
}

.custom-alert.show {
    opacity: 1;
}

#message {
    position: fixed;
    display: none;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 99;
}

#inner-message {
    margin: 0 auto;
}




div#input_custom p:hover {
    /* text-decoration: underline; */
    cursor: pointer;
    background-color: cornsilk;

}

div#input_custom p {
    padding: 1px 10px;
    border-radius: 7px;
}

.swal2-input {
    font-size: smaller;

}

.swal2-input:focus {
    color: inherit;
    background-color: #fff;
    border-color: #90b5e2;
    outline: 0;
    box-shadow: 0 0 0 .25rem rgba(32, 107, 196, .25);
}

div.custom_text_div {
    text-align: left !important;
}

div#main_result_display {
    background-color: #e1f1ff !important;
}

input#prompt_input:focus {
    outline: none !important;
}

div#input_custom {
    border: 2px dotted;
    padding-top: 16px;
    position: relative;
}

button.generate_btn {
    position: relative;
    padding-left: 35px;
    /* Adjust to create space for the icon */
}

button.generate_btn::before {
    content: '';
    display: inline-block;
    height: 20px;
    width: 20px;
    background-image: url("https://toolbaz.com/assets/img/edit.png");
    background-size: contain;
    background-repeat: no-repeat;
    position: absolute;
    left: 8px;
    /* Adjust based on your needs */
    top: 50%;
    transform: translateY(-50%);
}

.swal2-popup button:focus {
    outline: none !important;
    box-shadow: none !important;
}

input#prompt_input:focus {
    outline: none !important;
    box-shadow: none !important;
}

div:where(.swal2-container) .swal2-html-container {

    overflow: unset !important;

}

#input_custom.css-typing {
    font-family: unset !important;
}

#input_custom:empty:before {
    content: attr(placeholder);
    color: #999;
}

div#input_custom {
    min-height: 150px;
}

html.swal2-shown,
body.swal2-shown {
    overflow-y: hidden !important;
    height: auto !important;
}

.navbar {
    padding: 1rem 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.navbar-brand {
    padding: 0.5rem 0;
}

.nav-link {
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.nav-link:hover {
    background: var(--primary-light);
    color: var(--primary-color) !important;
}

.navbar-toggler {
    border: none;
    padding: 0.5rem;
}

.navbar-toggler:focus {
    box-shadow: none;
}

.error-alert {
    background: white;
    color: #dc2626;
    padding: 1rem 1.5rem;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
}

.cookies-wrapper {
    background: white;
    border-radius: 16px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
    padding: 1.5rem;
}

@media (max-width: 768px) {
    .navbar {
        padding: 0.5rem 0;
    }

    .navbar-collapse {
        background: white;
        padding: 1rem;
        border-radius: 12px;
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
        margin-top: 1rem;
    }

    .nav-link {
        padding: 0.75rem 1rem;
        border-radius: 8px;
    }

    .navbar-nav {
        gap: 0.5rem;
    }

    .error-alert {
        width: calc(100% - 2rem);
        left: 1rem;
        right: 1rem;
    }

    .cookies-wrapper {
        max-width: calc(100% - 2rem);
        margin: 0 1rem 1rem 1rem;
    }
}


.history-header {
    padding: 1rem;
    border-bottom: 1px solid #eaeaea;
}

.history-title {
    font-size: 1.25rem;
    color: #333;
    margin: 0;
    display: flex;
    align-items: center;
}

.history-count {
    color: #6c757d;
    font-size: 1rem;
    margin-left: 0.5rem;
}

.history-list {
    padding: 0.5rem;
}

.history-item {
    background: #fff;
    border: 1px solid #eaeaea;
    border-radius: 8px;
    margin-bottom: 1rem;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.04);
    overflow: hidden;
}

.history-item-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.5rem;
    background-color: #f8f9fa;
    cursor: pointer;
    transition: background-color 0.2s;
    position: relative;
}

.history-item-header:hover {
    background-color: #f1f3f5;
}

.history-item-title-container {
    display: flex;
    align-items: center;
    flex: 1;
    min-width: 0;
}

.history-item-number {
    font-weight: bold;
    margin-right: 0.75rem;
    color: #6c757d;
    flex-shrink: 0;
}

.history-item-title {
    font-weight: 500;
    margin: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 1rem;
}

.history-item-meta {
    display: flex;
    align-items: center;
    flex-shrink: 0;
    margin-right: 35px;
    /* Make space for the delete button */
}

.history-item-category {
    background-color: #e9ecef;
    color: #495057;
    padding: 0.2rem 0.5rem;
    border-radius: 20px;
    font-size: 0.75rem;
    margin-right: 0.75rem;
}

.history-item-wordcount {
    color: #6c757d;
    font-size: 0.85rem;
    margin-right: 1rem;
}

.history-item-toggle {
    color: #6c757d;
    transition: transform 0.2s;
}

.history-item-header .delete-btn {
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    z-index: 10;
    opacity: 0.6;
    transition: all 0.2s;
}

.history-item-header .delete-btn:hover {
    opacity: 1;
    background-color: rgba(255, 235, 238, 0.9);
}

.history-item-header[aria-expanded="true"] .history-item-toggle {
    transform: rotate(180deg);
}

.history-item-content {
    border-top: 1px solid #eaeaea;
}

.history-item-body {
    padding: 1.5rem;
}

.history-item-text {
    background-color: #f8f9fa;
    border-radius: 6px;
    position: relative;
    margin-bottom: 1rem;
    border: 1px solid #eaeaea;
}

.history-item-text .css-typing {
    max-height: 450px;
    overflow-y: auto;
    line-height: 1.5;
}

.history-item-actions {

    top: 0.5rem;
    right: 0.5rem;
    display: flex;
    gap: 0.5rem;
    flex-wrap: nowrap;
    justify-content: flex-end;
}

.history-action-btn {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    color: #495057;
    transition: all 0.2s;
    padding: 0;
}


.history-action-btn.delete-btn:hover {
    color: #dc3545;
    background-color: rgba(255, 235, 238, 0.9);
}

.history-action-btn.copy-btn:hover {
    color: #0d6efd;
    background-color: rgba(232, 240, 254, 0.9);
}

.history-action-btn.play-btn:hover {
    color: #198754;
    background-color: rgba(235, 250, 242, 0.9);
}

.history-action-btn.edit-btn:hover {
    color: #fd7e14;
    background-color: rgba(255, 243, 224, 0.9);
}

.history-item-footer {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
}

.history-badge {
    display: inline-flex;
    align-items: center;
    padding: 0.35rem 0.65rem;
    font-size: 0.75rem;
    font-weight: 500;
    line-height: 1;
    color: #495057;
    background-color: #e9ecef;
    border-radius: 20px;
}



/* Responsive adjustments */
@media (max-width: 768px) {
    .history-item-meta {
        display: none;
    }

    .history-item-title-container {
        margin-right: 1rem;
    }

    .history-item-header {
        position: relative;
    }

    .history-item-toggle {
        position: absolute;
        right: 45px;
        /* Move the toggle arrow to make space for delete button */
        top: 50%;
        transform: translateY(-50%);
    }

    .history-item-header[aria-expanded="true"] .history-item-toggle {
        transform: translateY(-50%) rotate(180deg);
    }
}

/* Output Container Styling */
.result-container {
    transition: all 0.3s ease;
}

.output-content {
    position: relative;
    background-color: #ffffff;
    border-radius: 0;
}

.css-typing {
    min-height: 150px;
    max-height: 500px;
    overflow-y: auto;
    font-size: 16px;
    line-height: 1.6;
    color: #5a5a5a;
    border: none;
    outline: none;
    padding: 1.25rem;
}

.output-actions {
    position: absolute;
    top: 0.75rem;
    right: 0.75rem;
    display: flex;
    gap: 6px;
}

.action-btn {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    background: #ffe6d6;
    color: #495057;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.08);
    transition: all 0.2s ease;
    padding: 0;
    font-size: 0.85rem;
}

.action-btn:hover {
    /* transform: translateY(-1px); */
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.action-btn#copy:hover {
    background-color: #e7f5ff;
    color: #0d6efd;
}

.action-btn.play:hover {
    background-color: #e7f9ed;
    color: #198754;
}

.action-btn.edit:hover {
    background-color: #fff4e6;
    color: #fd7e14;
}

.card-header {
    /* background-color: #f8f9fa;
                                border-bottom: 1px solid rgba(0, 0, 0, 0.06); */
}

.card-footer {
    background-color: #f8f9fa;
    border-top: 1px solid rgba(0, 0, 0, 0.06);
}

.badge {
    font-weight: 500;
    padding: 0.5rem 0.75rem;
    border-radius: 20px;
    font-size: 0.75rem;
    background-color: #e9ecef;
    color: #495057;
}

.badge.donations {
    color: #ffffff;
    cursor: pointer;
    transition: all 0.2s;
}

.badge.donations:hover {
    /* background-color: #0d6efd; */
    color: #ffffff;
}

/* Highlight styling for read-aloud feature */
.highlight {
    background-color: #f76707e6;
    padding: 0 2px;
    border-radius: 3px;
}

@media (max-width: 767.98px) {
    .output-meta .badge {
        font-size: 0.7rem;
        padding: 0.4rem 0.6rem;
    }

    .action-btn {
        width: 28px;
        height: 28px;
        font-size: 0.8rem;
    }

    .css-typing {
        font-size: 15px;
        padding: 1rem;
    }
}


select {
    cursor: pointer;
}

.custom-model-dropdown {
    position: relative;
    width: 100%;
    font-family: inherit;
}

.model-select-wrapper {
    position: relative;
}

.selected-model {
    display: flex;
    align-items: center;
    padding: 10px 15px;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    background-color: #fff;
    cursor: pointer;
    transition: border-color 0.15s ease-in-out;
    min-height: 48px;
    /* Reduced height since we don't show description */
}

.selected-model:hover {
    border-color: #adb5bd;
}

.model-icon {
    width: 24px;
    height: 24px;
    object-fit: contain;
    margin-right: 12px;
    border-radius: 4px;
}

.model-info {
    flex: 1;
}

.model-name {
    font-weight: 500;
    margin-bottom: 2px;
}

.model-description {
    font-size: 0.8rem;
    color: #6c757d;
}

.dropdown-arrow {
    margin-left: 10px;
    transition: transform 0.2s ease;
}

.model-dropdown-menu {
    position: absolute;
    width: 100%;
    max-height: 350px;
    overflow-y: auto;
    background-color: #fff;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    display: none;
    padding: 5px;
}

.model-dropdown-menu.active {
    display: block;
}

.model-group-title {
    padding: 8px 15px;
    font-weight: 600;
    color: #495057;
    background-color: #f8f9fa;
    border-radius: 4px;
    margin-top: 5px;
}

.model-option {
    display: flex;
    align-items: center;
    padding: 10px 15px;
    cursor: pointer;
    border-radius: 4px;
    transition: background-color 0.15s ease;
    justify-content: space-between;
}

.model-option:hover {
    background-color: #f8f9fa;
}

.model-option.selected {
    background-color: #e9f0ff;
}

.model-badge {
    font-size: 10px;
    padding: 2px 6px;
    border-radius: 10px;
    margin-left: 5px;
    background-color: #e0f7fa;
    color: #0277bd;
}

.model-badge-info {
    background-color: #e0f7fa;
    color: #0277bd;
}

.model-badge-success {
    background-color: #e8f5e9;
    color: #2e7d32;
}

.model-badge-warning {
    background-color: #fff8e1;
    color: #ff8f00;
}

.model-badge-danger {
    background-color: #ffebee;
    color: #c62828;
}

.model-metrics {
    font-size: 0.75rem;
    color: #6c757d;
}

.model-metrics-right {
    margin-left: auto;
    font-size: 0.75rem;
    color: #6c757d;
    padding-left: 10px;
    border-left: 1px solid #efefef;
}

.speed-indicator,
.quality-indicator {
    display: flex;
    align-items: center;
}

.speed-indicator i {
    font-size: 0.8rem;
}

.quality-indicator i {
    font-size: 0.8rem;
}

@media (max-width: 767px) {
    .model-metrics {
        display: none !important;
    }
}