body {
    font-family: 'Montserrat', sans-serif;
    background-color: #f0f0f0;
    margin: 0;
    color: #333;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    min-height: 100vh;
    overflow-x: hidden;
}

.logged-in {
    color: white;
}

.header {
    width: 100%;
    position: fixed;
    top: 0;
    left: 0;
    background-color: #007bff;
    padding: 15px 20px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 1000;
    box-sizing: border-box;
    height: 70px;
}

.add-project-action button {
    padding: 5px;
    font-size: 1em;
}

.header h1 {
    margin: 0;
    color: #fff;
    font-size: 1.5em;
    font-weight: 700;
}


.container {
    border-radius: 3px;
    background-color: #ffffff;
    padding: 20px;
    width: 90%;
    max-width: 900px;
    margin-top: 5px;
    margin-bottom: 10px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    box-sizing: border-box;
    position: relative;
}

form {
    display: flex;
    flex-direction: column;
}

label {
    font-weight: 500;
    text-align: left;
    color: #333;
    margin-bottom: 10px;
}

input[type="text"], input[type="password"], input[type="email"] {
    padding: 8px;
    width: 100%;
    box-sizing: border-box;
    border: 1px solid #ccc;
    border-radius: 3px;
    background-color: #f9f9f9;
    color: #333;
    margin-bottom: 15px;
    font-size: 0.9em;
}

#answer-temperature, #answer-temperature_edit {
    padding: 8px;
    width: 100%;
    box-sizing: border-box;
    border: 1px solid #ccc;
    border-radius: 3px;
    background-color: #f9f9f9;
    color: #333;
    margin-bottom: 15px;
    font-size: 0.9em;
}

#model, #model_edit {
    padding: 8px;
    width: 100%;
    box-sizing: border-box;
    border: 1px solid #ccc;
    border-radius: 3px;
    background-color: #f9f9f9;
    color: #333;
    margin-bottom: 15px;
    font-size: 0.9em;
}

.edit_ysk_speed {
 padding: 8px;
    width: 100%;
    box-sizing: border-box;
    border: 1px solid #ccc;
    border-radius: 3px;
    background-color: #f9f9f9;
    color: #333;
    margin-bottom: 15px;
    font-size: 0.9em;

}

#instruction, #instruction_edit {
    width: 100%;
    min-height: 100px;
    resize: both;
    box-sizing: border-box;
    padding: 10px;
    font-size: 14px;
    border: 1px solid #ccc;
    border-radius: 4px;
}

textarea {
    margin-bottom: 5px;
}

button {
    padding: 8px;
    background-color: #007bff;
    color: #fff;
    border: none;
    cursor: pointer;
    border-radius: 3px;
    transition: background-color 0.3s ease;
    font-size: 0.9em;
    font-weight: 500;
}

button:hover {
    background-color: #0056b3;
}

#submit-button, .cancel-button {
    width: 100%;
    font-size: 0.9em;
    text-align:center
}

.cancel-button {
    background-color: #6c757d;
    margin-top: 10px;
}

.cancel-button:hover {
    background-color: #5a6268;
}

/* Loading spinner */
.loading-container {
    display: none;
    justify-content: center;
    align-items: center;
    height: 100px;
    position: relative;
}

.spinner {
    border: 4px solid #f3f3f3;
    border-top: 4px solid #007bff;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.popup {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    justify-content: center;
    align-items: center;
}

.popup-content {
    background: white;
    padding: 20px;
    border-radius: 5px;
    max-width: 600px;
    text-align: center;
    max-height: 80vh;
    overflow-y: auto;
}

.popup-content h2 {
    margin-bottom: 20px;
}

.popup-content button {
    margin: 5px;
    font-size: 0.9em;
}

.files-container-edit {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
}


.footer {
    text-align: center;
    padding: 20px 0;
    color: #777;
    background-color: #f1f1f1;
    width: 100%;
    position: absolute;
    bottom: 0;
    left: 0;
    box-sizing: border-box;
}

.footer p {
    margin: 0;
    font-size: 0.9em;
}

#projects-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
    list-style-type: none;
    padding: 0;
    margin: 0;
    margin-top:0.2em
}

#projects-list li {
    background-color: #f0f7ff;
    border: 1px solid #ddd;
    border-radius: 5px;
    padding: 15px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}


.assistant-container li {
    background-color: #f0f7ff;
    border: 1px solid #ddd;
    border-radius: 5px;
    margin-bottom: 10px;
    padding: 15px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    position: relative;
    display: flex;
    flex-direction: column;
}

.project-detail {
    margin-bottom: 10px;
}

.project-detail span {
    display: block;
    font-weight: 500;
}

.project-detail .label {
    font-weight: bold;
    color: #333;
}

.project-detail .value {
    color: #555;
}

.button-group {
    display: flex;
    justify-content: space-between;
    margin-top: 10px;
}

.button-group button {
    padding: 8px 12px;
    border: none;
    border-radius: 3px;
    font-size: 0.9em;
    color: #fff;
    cursor: pointer;
}

.green-action {
    background: #4fa31a;
    margin:0.3em
}

.green-action:hover {
    background: #489617;
}

.red-action {
    background: #a3481a;
    margin:0.3em
}

.red-action:hover {
    background: #8f3e15;
}

.yellow-action {
    background: #FFC811;
    margin:0.3em;
    color: #1c1c1c

}

.yellow-action:hover {
    background: #edbb13;
}

.back-button {
    color: #fff;
    text-decoration: none;
    margin: 0 15px;
}

.back-button:hover {
    text-decoration: underline;
}

input[type="text"], input[type="password"], input[type="email"] {
    overflow: hidden;
    text-overflow: ellipsis;
}

.assistant-container {
    word-wrap: break-word;
    overflow-wrap: break-word;
    word-break: break-word;
    border-radius:5px;
    background: #f0f7ff;
    transition: background-color 0.3s ease;
}

.file-details {
    background: #dae9fb;
    justify-content: space-between;
    border-radius: 5px;
    padding: 0.3em;
    margin: 0.1em;
    width: 100%;
}

.container p {
    word-wrap: break-word;
    overflow-wrap: break-word;
    word-break: break-word;
    white-space: normal;
}

.switch {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 24px;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: .4s;
    border-radius: 34px;
}

.slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 4px;
    bottom: 3px;
    background-color: white;
    transition: .4s;
    border-radius: 50%;
}

input:checked + .slider {
    background-color: #2196F3;
}

input:checked + .slider:before {
    transform: translateX(26px);
}

.no-assistants-message {
    margin-bottom:0.7em;
    padding:0.3em;
    border-radius: 3px;
    background-color: #0056b3;
    color:#ffffff

}

#api_key_instance {
    display: inline-block;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    border: 1px solid #ddd;
    padding: 5px;
    background-color: #f9f9f9;
}

#sync-remote-status, #sync-remote-status_edit{
background-color: #f0f7ff;
padding: 5px;
border: 1px solid #ddd;
display: inline-block;
max-width: 100%;
}

#warning-message {
background-color: #f7f3bc;
padding: 5px;
border: 1px solid #ddd;
display: inline-block;
max-width: 100%;
}

.drop-zone {
    border: 2px dashed #ccc;
    border-radius: 4px;
    padding: 20px;
    text-align: center;
    margin-top: 10px;
    font-size: 16px;
    color: #333;
    background-color: #f9f9f9;
}

.drop-zone-active {
    border-color: #007bff;
    background-color: #e9f5ff;
}

.file-preview {
    border: 1px solid #ddd;
    padding: 10px;
    margin: 5px 0;
}

.file-preview img {
    max-width: 100px;
    height: auto;
}

.file-preview div {
    margin: 5px 0;
}

#engine-container {
background:#f4fff5;
padding:10px;
border-radius:4px

}

#statistics-container {
background: #d9e6db;
color: #333;
padding: 10px;
border-radius: 5px;
}

/*Голосовые настройки*/

.yandex-sk-container {
margin-top:3px;
background:#fffcf4;
padding:10px;
border-radius:4px;
transition: background-color 0.3s ease;
margin-bottom:0.1em;
}

.list-ysk {
cursor:pointer;
transition:0.3s;
background:#e5f0e6;
border-radius:5px;
padding:3px;
width:80px;
margin-bottom:0.1em;
}

.list-ysk:hover {
color:#657766
}

.button-group-projects {
    display: flex;
    justify-content: flex-start;
    gap: 10px;
    margin-top: 10px;
}

.button-group-projects button {
    padding: 8px 12px;
    border: none;
    border-radius: 3px;
    font-size: 0.9em;
    color: #fff;
    cursor: pointer;
}

.loading {
font-style: italic;
color: #aaa;
padding: 10px 0;
}

.generated-links {
background: #fffcf4;
color: #333;
padding: 10px;
border-radius: 5px;
}

#no-files {
padding:10px; border-radius:5px; background:white; margin-top:0.1em;
}

.underheader-tabs {
    width: 100%;
    background-color: #f1f1f1;
    padding: 10px 0;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    margin-top: 70px
}

.tab-list {
    list-style-type: none;
    padding: 0;
    margin: 0;
    display: flex;
    justify-content: center;
}

.tab-list li {
    margin: 0 15px;
    transition: background-color 0.3s ease, transform 0.3s ease;
}

.tab-list a {
    text-decoration: none;
    color: #007bff;
    font-weight: 500;
    transition: color 0.3s ease;
}

.tab-list a:hover {
    color: #0e68ca;
    transform: scale(1.05);
}

.header-title {
    flex: 1;
    text-align: center;
    margin: 0;
    color: #fff;
}

.add-project-action {
    display: flex;
    justify-content: center;
    margin-top: 10px;
    margin-bottom: 10px;
}

.changelog-container {
    background-color: #f0f7ff;
    border: 1px solid #ddd;
    border-radius: 5px;
    margin-bottom: 10px;
    padding: 15px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    position: relative;
    flex-direction: column;
}

#searchInput {
    width: 100%;
    padding: 10px;
    margin-bottom: 12px;
    font-size: 16px;
    border: 1px solid #ddd;
    border-radius: 4px;
}

#username {color:white}