@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@400;700&display=swap');

body {
    position: absolute;
    width: 100%;
    height: 100%;
    left: 0px;
    top: 0px;

    -webkit-box-pack: center;
    justify-content: center;
    -webkit-box-align: center;
    align-items: center;

   /* background-image: url("/images/54634563453.jpg"); */
    background-color: #9f9f9f; /* Белый фон пока грузится изображение */
    background-repeat: no-repeat; /* Лучше использовать no-repeat для фонового изображения */
    background-attachment: fixed; /* или scroll */
    background-origin: border-box;

    margin: 0px;
    padding: 0px;
    background-size: cover !important;
    background-position: center center !important;
    box-sizing: border-box !important;


    font-family: 'Roboto', sans-serif;
    font-size: 16px;
    line-height: 1.5;

    color: var(--dark-color);
}

.fa, .fas {
}

.red_block {
    width: auto;
    display: flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
}


.file-actions {width: 120px;}
.file-name {    font-size: 14px;}

.new-etap {    cursor: pointer;
    font-size: 15px;
    font-weight: 300;
      }
        .alert {
            padding: 10px;


        }
        .error {
            color: #721c24;
            background-color: #f8d7da;
            border: 1px solid #f5c6cb;
        }
        .success {
            color: #155724;
            background-color: #d4edda;
            border: 1px solid #c3e6cb;
        }

        .form-group {
            margin-bottom: 15px;
        }
        label {
            display: block;
            margin-bottom: 5px;
            font-weight: bold;
        }
        input[type="text"], input[type="file"] {
            width: 40%;
            padding: 8px;
            border: 1px solid #ddd;
            border-radius: 4px;
        }
        button, .btn {
            padding: 0;
            color: white;
            border: none;
            border-radius: 4px;
            cursor: pointer;
            font-size: 14px;
        }
        .btn-success {
            background: #467095;
        }
        .btn-primary {
            background: #007bff;
        }
        .btn-danger {
            background: #dc3545;
        }
        .btn-info {
            background: #17a2b8;
        }
        .btn-secondary {
            background: #6c757d;
        }
        .section {
            margin-bottom: 20px;
            padding: 15px;
            border-left: 5px solid #6c757d;
            background: #f9f9f9;
            position: relative;
        }
        .section-header {
            display: flex;
            justify-content: space-between;
            align-items: center;
            margin-bottom: 10px;
        }
.status-badge {
    color: white;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: normal;
    margin-left: 8px;
    display: inline-block;
}
        .stage-list {
            list-style: none;
            padding-left: 20px;
            margin-top: 10px;
        }
        .stage-item {
            margin-bottom: 0px;
        }
        .inline-form {
            display: inline;
            margin-right: 10px;
        }
        .media-preview {
            max-width: 100px;
            max-height: 100px;
            border-radius: 5px;
            border: 1px solid #ccc;
            cursor: pointer;
        }
        .modal {
            display: none;
            position: fixed;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background: rgba(0,0,0,0.8);
            align-items: center;
            justify-content: center;
            z-index: 9999;
        }
        .modal-content {
            max-width: 90%;
            max-height: 90%;
        }
        .add-stage-form {
    margin-bottom: 30px;
    padding: 10px 20px 10px 10px;
    background: #f3f3f3;
    border-radius: 5px;
}

.stages-header {    padding: 30px 0px 18px 5px;}

.no-stages {
    color: gray;
}
.edit-form-container {
    margin-top: 10px;
}
.comments-container {
margin: 15px 0;
    padding:0px 0px 20px 0px;
    background: #f8f9fa;

    height: 100%;
    max-height: 270px;
    overflow: auto;
}
.comment-item {
    font-size: 13px;
    color: #555;
    padding: 5px;
    background: #fff;
    border-radius: 3px;
    margin-bottom: 5px;
}
.comment-form {
    margin-top: 5px;
    margin-left: 10px;
        margin-right: 10px;
    display: flex;
    gap: 5px;
}
.comment-form input {
    flex-grow: 1;
    padding: 5px;
    font-size: 12px;
}
.media-container {
    margin-top: 10px;
    margin-left: 25px;
}
.media-container h4 {
    margin-bottom: 5px;
    font-size: 14px;
}
.media-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}
.media-item {
    position: relative;
}
.media-delete-form {
    position: absolute;
    top: -8px;
    right: -8px;
}
.media-delete-form button {
    background: #dc3545;
    color: white;
    border: none;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    font-size: 10px;
    line-height: 1;
    cursor: pointer;
}
.media-upload-form {
    margin-top: 10px;
    margin-left: 25px;
}
.btn-sm {
    padding: 2px 5px;
    font-size: 12px;
}




.btn-back {    background-color: #353535;}





/* Стили для заголовка объекта и кнопки редактирования */
.object-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.btn-edit {
    padding: 0;
    border-radius: 4px;
    cursor: pointer;
    float: right;
        font-size: 16px;
        background: transparent;
}

.btn-edit:hover {
    background: #45a049;

}


.btn-edit2 {

    cursor: pointer;
    float: right;
        font-size: 16px;
        background: transparent;
}



/* Стили для модального окна редактирования */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.5);
}

.modal-content {
    background-color: #fefefe;
    margin: 10% auto;
    padding: 20px;
    border: 1px solid #888;
    width: 80%;
    max-width: 500px;
    border-radius: 5px;
}

.close {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
}

.close:hover {
    color: black;
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
}

.form-group textarea {
    min-height: 100px;
    resize: vertical;
}
    /* Обновленные стили для кнопки сохранения */
.modal-content .btn {
    background-color: #4CAF50; /* Зеленый цвет */
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
    width: 100%;
    margin-top: 10px;
    transition: background-color 0.3s;
}

.modal-content .btn:hover {
    background-color: #45a049; /* Темно-зеленый при наведении */
}






















img {
    max-width: 100%;
    height: auto;
}

/* Стили для страницы объекта */
.object-container {

}

.object-container h2 {
    color: #333;
    margin-top: 0;
    font-size: 17px;
}

.object-container h3 {
    color: #444;
    margin: 55px 0 25px;
    font-size: 17px;
}

/* Стили этапов */


.stage-item.completed {
    border-left-color: #28a745;
}

.stage-item.in_progress {
    border-left-color: #05d5e8;
}

.stage-item.not_started {
    border-left-color: #dc3545;
}

/* Прогресс-бар */

.progress-bar {
    height: 100%;
    background: linear-gradient(90deg, #4aa1ff, #ff15b2);
    border-radius: 10px;
    width: 0;
    transition: width 0.6s ease;
}


/* Медиа-файлы */
.media-container {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 10px;
}

.media-item {
    position: relative;
}

.media-item img,
.media-item video {
    max-width: 100px;
    max-height: 100px;
    border-radius: 5px;
    border: 1px solid #ccc;
}

/* Формы */
.form-group {
    margin-bottom: 15px;
}

.form-input {
    width: 100%;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
}

.form-button {
    padding: 8px 15px;
    background: #28a745;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

/* Модальное окно */
.media-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.8);
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

.media-content {
    max-width: 90%;
    max-height: 90%;
}

/* Мобильные стили */
@media (max-width: 768px) {
    .object-container {

    }

    .stage-item {
        padding: 10px;
        margin-bottom: 15px;
    }

    .media-item img,
    .media-item video {
        max-width: 80px;
        max-height: 80px;
    }



    /* Формы на мобильных */
    .form-grid {
        grid-template-columns: 1fr !important;
        gap: 8px !important;
    }

    /* Кнопки */
    .form-button {
        padding: 8px 12px;
        font-size: 14px;
    }

    /* Комментарии */
    .comment-item {
        font-size: 13px;
        padding: 5px;
    }

    /* Модальное окно */
    .media-content {
        max-width: 95%;
        max-height: 80%;
    }


    .comment-form {
    margin-top: 5px;
    margin-left: 0px;
    display: flex;
    gap: 5px;
}
.comments-container {
    margin-top: 10px;
    margin-left: 0px;
}
        .stage-list {
            list-style: none;
            padding-left: 0px;
            margin-top: 10px;
        }

        .inline-form {
            display: inline;
            margin-left: 0px;
        }
.media-upload-form {
    margin-top: 10px;
    margin-left: 0px;
}

            button, .btn {
            padding: 0;
            color: white;
            border: none;
            border-radius: 4px;
            cursor: pointer;
            font-size: 14px;
                margin-left: 10px;
                clear: both;
        }

            input[type="text"], input[type="file"] {
            width: 100%;
            padding: 8px;
            border: 1px solid #ddd;
            border-radius: 4px;
        }

}

/* Существующие стили из вашего файла */
.container {
  width: 100%;
    max-width: 1200px;
    margin: 0px auto;
    padding: 20px!important;
    border-radius: 7px;
    background-color: #fff;
}

.section {
    border-left: 5px solid #ccc;
    padding: 10px 15px;
    margin: 15px 0;
    background: #fff;
    -webkit-box-shadow: 0px 0px 12px -2px rgb(0 0 0 / 19%);
-moz-box-shadow: 0px 0px 12px -2px rgb(0 0 0 / 19%);
box-shadow: 0px 0px 12px -2px rgb(0 0 0 / 19%);
}

.section.done {
    border-color: #4caf50;
}

.section.in_progress {
    border-color: #ff9800;
}

.section.pending {
    border-color: #ccc;
}

.progress-bar-wrapper {
    background: #eee;
    border-radius: 5px;
    overflow: hidden;
    height: 20px;
    margin: 10px 0;
}

.stage-list {
    list-style: none;
    padding-left: 0;
}

.comment, .photo, .status-box {
    margin: 10px 0;
    padding: 10px;
    background: #f0f0f0;
    border-left: 3px solid #ddd;
}

/* Тёмная тема */
body.dark-mode .object-container {
    background: #2a2a2a;
    color: #eee;
}

body.dark-mode .stage-item {
    background: #333;
}

body.dark-mode .comment-item {
    background: #3a3a3a;
}








/* styles.css */
:root {
    --primary-color: #4361ee;
    --secondary-color: #3f37c9;
    --accent-color: #4895ef;
    --light-color: #f8f9fa;
    --dark-color: #212529;
    --success-color: #4cc9f0;
    --warning-color: #f8961e;
    --danger-color: #f94144;
    --border-radius: 5px;
    --box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}



header {
    background-color: white;
    box-shadow: var(--box-shadow);
    padding: 0;
    margin-bottom: 10px;
}


.welcome-message {
    font-size: 1.5rem;
    color: var(--primary-color);
    font-weight: 600;
}



.section-title {
    font-size: 1.5rem;
    margin: 10px 0 0px;
    color: var(--dark-color);
    position: relative;
    padding-bottom: 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.section-title2 {
    font-size: 1rem;
    margin: 30px 0 20px;
    color: var(--dark-color);
    position: relative;
    padding-bottom: 10px;
    display: flex;
    align-items: center;
}

.section-title2 i {
 padding-right: 5px;
}



    /* Стили карточек объектов */
    .object-card {
        box-sizing: border-box;
        background: #fff;
        border-radius: 18px;
        box-shadow: 2px 0px 13px 7px rgb(12 12 12 / 10%);
        overflow: hidden;
        margin-bottom: 20px;
        width: 100%;
        border: 1px solid #e0e0e0;
    }

    .completed-object-card {
        border-left: 0px solid #62ff00;
    }

    .object-photo {
    width: 100%;
    height: 250px;    overflow: hidden;
    }

    .object-photo img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        display: block;
    }

    .object-content {
        padding: 20px;
    }



    .object-title {
        margin: 0;
        font-size: 1.1rem;
        color: #333;
    }

    .object-title a {
        color: #333;
        text-decoration: none;
    }

    .object-description {
        color: #666;
        margin: 10px 0 0;
        font-size: 0.9rem;
    }




.objects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    margin-bottom: 40px;
}

.object-card {
    background-color: white;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    overflow: hidden;
    transition: var(--transition);
    position: relative;
}

.object-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}


.object-title {
    font-size: 16px;
    margin-bottom: 0px;
    color: #2386bd;
}

.object-description {
    color: #666;
    margin-bottom: 15px;
    font-size: 0.95rem;
}

.client {
    padding: 8px 12px;
    background:#f1f1f18a;
    margin: 8px 0;
    border-left: 3px solid var(--accent-color);


}

.no-client {
    color: gray;
    font-style: italic;
    font-size: 13px;
}

.object-actions {
    display: flex;
    gap: 10px;
    margin-top: 15px;
}


.btn-send {
background-color: #1c93d5;
    padding: 6px 9px;
    cursor: pointer;
    font-size: 0.8rem;
    margin-left: 10px;
}


.btn {
    padding: 8px 12px;
    border-radius: var(--border-radius);
    border: none;
    cursor: pointer;
    font-size: 0.9rem;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    transition: var(--transition);
    text-decoration: none;
}

.btn-primary {
    background-color: #2f91bd;
    color: white;
}

.btn-primary:hover {
    background-color: #125377;
}

.btn-edit2 {
    font-size: 12px;
    color: white;
}
.btn-edit {
    background-color: #515151;
    color: white;
    font-size: 12px;
}

.btn-edit:hover {
    background-color: #997d32;
}

.btn-delete {
    margin-left: 5px;
    cursor: pointer;
    background-color: #610000;
    color:#fff;
}

/* В контексте object-header (дашборд) — float не нужен, flex-родитель управляет позицией */
.object-header .btn-delete,
.red_block .btn-delete {
    float: none;
    margin-left: 0;
}

/* Единый стиль иконок-кнопок в red_block */
.red_block .btn-edit,
.red_block .btn-delete,
.red_block .btn-delete.disabled {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 6px;
    border: 1px solid #ddd;
    background: #f8f9fa;
    color: #555;
    font-size: 13px;
    cursor: pointer;
    text-decoration: none;
    transition: background 0.15s, color 0.15s, border-color 0.15s;
    padding: 0;
    float: none;
    margin: 0;
}

.red_block .btn-edit:hover {
    background: #e8f0fe;
    color: #1a73e8;
    border-color: #aac4f7;
}

.red_block .btn-delete:not(.disabled):hover {
    background: #fdecea;
    color: #c62828;
    border-color: #f5c6c6;
}

.red_block .btn-delete.disabled {
    opacity: 0.45;
    cursor: not-allowed;
    pointer-events: none;
}



.empty-state {
    text-align: center;
    padding: 40px 20px;
    background-color: white;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
}

.empty-icon {
    font-size: 3rem;
    color: #ddd;
    margin-bottom: 20px;
}

.empty-text {
    color: #777;
    margin-bottom: 20px;
}

/* Мобильные стили */
@media (max-width: 768px) {
    .container {

    margin: 0 auto;
    padding: 10px;
    margin-bottom: 5px;
    background-color: #fff;
    border-radius: 0px;

    }



    .welcome-message {
        font-size: 1.3rem;
    }



    .client-code {
        font-size: 1.5rem;
        padding: 8px 12px;
    }

    .objects-grid {
        grid-template-columns: 1fr;
    }

    .section-title {
        font-size: 1rem;
        margin: 20px 0 15px;
    }
}

@media (max-width: 480px) {
    .notice-title {
        font-size: 14px;
    }

    .client-code {
        font-size: 1.3rem;
    }

    .object-content {
        padding: 20px;
    }

    .object-title {
        font-size: 1.1rem;
    }
}


.user-status {
    top: -15px;
    left: 0;

    font-size: 13px;
}

.user-status.company {

    color: #212529;
    border: 3px solid #4a5363;
    max-width: 300px;
    width: 100%;
    overflow: hidden;
    white-space: nowrap;
}

.user-status.client {

    color: #212529;
    border: 3px solid #1e7e34;
}

.user-status.partner {

    color: #212529;
    border: 3px solid #d39e00;
}

.profile-link {
    color: #535353;
    font-size: 24px;
    transition: all 0.3s;
}


.profile-icon {
    vertical-align: middle;
}





.client {
    display: flex;
    flex-wrap: wrap;
    margin-bottom: 5px;

}


.client2 {
    font-size: 12px;
}


.client strong {
    margin-right: 5px;
}

.client .email {
    word-break: break-all;
}

.object-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 15px;
}


.object-card {
    background: #fff;
border-radius: 18px;
        box-shadow: 2px 0px 13px 7px rgb(12 12 12 / 10%);
    padding: 0px;
    margin-bottom: 20px;
}

@media (max-width: 480px) {
    .object-card {
        padding: 0px;
    }

    .object-title {
        font-size: 1.2em;
    }

    .object-description {
        font-size: 0.9em;
    }
}


.btn-dashboard {
    display: inline-block;
    padding: 8px 15px;
    background-color: #4CAF50;
    color: white;
    text-decoration: none;
    border-radius: 4px;
    margin-left: 15px;
    font-size: 14px;
    transition: background-color 0.3s;
}

.btn-dashboard:hover {
    background-color: #45a049;
}



/* Добавьте это в конец файла style.css */

/* Стили для всплывающих уведомлений */
.flash-message {
    position: fixed;
    bottom: 66px;
    left: 50%;
    transform: translateX(-50%);
    padding: 12px 24px;
    border-radius: 4px;
    color: white;
    font-weight: bold;
    z-index: 1050;
    opacity: 0;
    transition: opacity 0.2s ease-in-out;
    max-width: 80%;
    text-align: center;
}

.flash-message.show {
    opacity: 1;
}

.flash-message.success {
    background-color: #4CAF50;
    color: #fff;
    border: 1px solid #636724;
    font-size: 12px;
}

.flash-message.error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.flash-message.warning {
    background-color: #fff3cd;
    color: #856404;
    border: 1px solid #ffeeba;
}

.flash-message.info {
    background-color: #d1ecf1;
    color: #0c5460;
    border: 1px solid #bee5eb;
}

@keyframes fadeInOut {
    0% {
        opacity: 0;
        transform: translate(-50%, -50%) scale(0.9);
    }
    10% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
    }
    90% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
    }
    100% {
        opacity: 0;
        transform: translate(-50%, -50%) scale(0.9);
    }
}

/* Затемнение фона */
.flash-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 9998;
    opacity: 0;
    transition: opacity 0.3s ease-in-out;
    pointer-events: none;
}

.flash-backdrop.show {
    opacity: 1;
}

.toggle-comments-btn {
    background: none;
    border: none;
    color: #007bff;
    cursor: pointer;
    padding: 5px;
    margin: 5px 0;
    font-size: 14px;
}

.toggle-comments-btn:hover {
    text-decoration: underline;
}



.comment-item {
    margin-bottom: 5px;
    padding: 10px;
    background: white;
    border-radius: 3px;
}

.comment-form {
    margin-top: 10px;
}


.toggle-media-btn,
.toggle-upload-btn {
    background: none;
    border: none;
    color: #007bff;
    cursor: pointer;
    padding: 5px;
    margin: 5px 0;
    font-size: 14px;
    display: inline-block;
}

.toggle-media-btn:hover,
.toggle-upload-btn:hover {
    text-decoration: underline;
}

.media-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 10px;
    margin: 10px 0;
}

.media-item {
    position: relative;
}

.media-preview {
    width: 100%;
    height: 100px;
    object-fit: cover;
    border-radius: 4px;
}

.media-delete-form {
    position: absolute;
    top: 5px;
    right: 5px;
}

.media-upload-form {
    margin: 15px 0;
    padding: 10px;
    background: #f8f9fa;
    border-radius: 5px;
}


/* Стили для элементов управления */
.stage-controls {
    display: inline-flex;
    gap: 20px;
    margin-left: 0px;
    padding: 20px 20px 20px 40px;
}

.control-btn {
    background-color: #efefefc2;
    border: none;
    color: #656565;
    cursor: pointer;
    padding: 5px 15px 5px 15px;
    font-size: 13px;
    white-space: nowrap;
}


.control-btn:hover {
    text-decoration: underline;
    background-color: #d3f598c2;
    border-radius: 3px;
}

/* Стили для медиа-галереи */
.media-container {
    margin-top: 5px;
}

.media-grid {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    padding: 0px 0px 15px 0px;
    margin: 15px 0;
}

.media-item {
    position: relative;
    flex: 0 0 auto;
    float: left;
    margin-left: 10px;
}

.media-preview {
    width: 100px;
    height: 80px;
    object-fit: cover;
    border-radius: 4px;
    border: 1px solid #ddd;
}

.media-delete-form {
    position: absolute;
    top: 2px;
    right: 2px;
}

/* Стили для формы загрузки */
.media-upload-form {
    display: flex;
    gap: 10px;
    align-items: center;
    margin: 15px 0;
    padding: 0px;
    background: #f8f9fa;
    border-radius: 5px;
}

.media-upload-form input[type="file"] {
    flex-grow: 1;
    padding: 5px;
    border: 1px solid #ced4da;
    border-radius: 4px;
}

.btn-cancel {    background-color: #b90e0e;
    color: #fff;
    padding: 8px 12px;
    border-radius: var(--border-radius);
    cursor: pointer;
    font-size: 0.9rem;}


.btn-upload {   background-color: #6a871f;
    padding: 10px 15px;
    cursor: pointer;
    font-size: 0.8rem;
    margin-left: 10px;}


.stage-name{    font-size: 14px;    padding-left: 10px;}

.profile-actions {
    display: flex;
    gap: 15px;
    align-items: center;
        padding-right: 10px;
}

.profile-link, .logout-link {
    color: #395665;
    font-size: 20px;
    transition: color 0.3s;
}

.profile-link:hover, .logout-link:hover {
    color: #007bff;
}

.stats-container {
    display: flex;
    gap: 30px;
    margin: 15px 0;
}
.stat-item {
    text-align: center;
        background-color: #ffffffe8;
    padding: 10px;
    border-radius: 15px;
}

.stat-item2 {
    text-align: left;
    background-color: #d1d1d121;
    padding: 10px;
    border-radius: 15px;
    border: 1px solid #d9d9d975;
}


.stat-value {
    font-size: 28px;
    font-weight: bold;
    color: #fff;
}
.stat-label {
    font-size: 14px;
    color: #fff;
}

.sections-progress {
    margin: 20px 0;
}

.section-progress-item {
    margin-bottom: 10px;
}

.section-name {
    font-size: 14px;

    margin-bottom: 5px;
}

.section-progress-container {
    width: 100%;
    background-color: #b9b9b9;
    border-radius: 5px;
    height: 20px;
    position: relative;
    overflow: hidden;
}

.section-progress-bar {
    height: 100%;
    background-color: #84b92bb0;
    transition: width 0.3s ease;
}

.section-progress-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #fff;
    font-weight: bold;
    font-size: 10px;
    text-shadow: 0 0 1px rgba(0,0,0,0.5);
}



.object-title a {
    color: inherit;
    text-decoration: none;
    transition: color 0.2s;
}

.object-title a:hover {
    color: #007bff;
}

.object-header .btn-edit {
    background: transparent;
    border: none;
    color: #6c757d;
    padding: 0px;
    font-size: 16px;
    cursor: pointer;
    transition: color 0.2s;
}

.object-header .btn-edit:hover {
    color: #007bff;
}

.object-actions {
    display: flex;
    justify-content: flex-end;
    margin-top: 15px;
}

.btn-delete-icon {
    background: #f8f9fa;
    border: 1px solid #dc3545;
    color: #dc3545;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    transition: all 0.2s;
}

.btn-delete-icon:hover {
    background: #dc3545;
    color: white;
}

.btn_mini {display: inline-block;
    padding: 3px 8px;
    background-color: #2b507b;
    color: white;
    text-decoration: none;
    border-radius: 4px;
    margin-left: 15px;
    font-weight: 100;
    font-size: 13px;
    transition: background-color 0.3s;
cursor: pointer;}

/* Для мобильных устройств */
@media (max-width: 768px) {
    .btn-delete-icon {
        width: 36px;
        height: 36px;
    }



}





 button, .btn {
            padding: 8px 10px;
            color: white;
            border: none;
            border-radius: 4px;
            cursor: pointer;
            font-size: 13px;
                clear: both;

        }

.btn-save {background-color:#167ccf}



/* Основные стили для мобильной версии */
@media (max-width: 768px) {
    .stage-item {
        padding: 0px;
        margin-bottom: 0px;
    }

    .stage-header {

    }

    .stage-controls {
        flex-direction: column;
        gap: 8px;
    }

    .control-btn {
        width: 100%;
        padding: 8px;
        font-size: 14px;
        justify-content: flex-start;
        text-align: left;
    }

    .comments-container {
        max-height: 200px;
        overflow-y: auto;
    }

    .comment-item {
        padding: 6px 0;
        font-size: 14px;
    }

    .media-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
    }

    .media-preview {
        max-width: 100%;
        height: auto;
    }

    .comment-form,
    .media-upload-form,
    .edit-form-container form {
        flex-direction: column;
        gap: 8px;
    }

    .comment-form input[type="text"],
    .media-upload-form input[type="file"],
    .edit-form-container input[type="text"] {
        width: 100%;
        padding: 8px;
    }

    .btn-send,
    .btn-upload,
    .btn-save,
    .btn-cancel,
 {
        width: 100%;
        padding: 8px;
        margin: 4px 0;
    }

    /* Скрытие иконок на маленьких экранах */
    .control-btn i {
        margin-right: 6px;
    }

    /* Адаптация текста */
    .stage-name {
        font-size: 15px;
        margin-top: 0px;
    }
}


.client-code-container{font-size: 13px;padding: 10px 10px 10px 5px;}


     .object-photo3-placeholder { width: 120px;
    max-height: 230px;
    background-color: #ededed;}


.gallery-loading-container {
    position: relative;
    min-height: 100px;
}

.gallery-loader {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    background: transparent;
    z-index: 10;
}

.gallery-spinner {
    width: 40px;
    height: 40px;
    border: 4px solid rgba(0, 0, 0, 0.1);
    border-radius: 50%;
    border-top-color: #4361ee;
    animation: spin 1s ease-in-out infinite;
}

.gallery-items {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.gallery-items.loaded {
    opacity: 1;
}










.notice {

    color: #1a1a1a;
    padding: 20px 20px 4px 20px;
    border-radius: var(--border-radius);
    margin-bottom: 30px;

    position: relative;
    overflow: hidden;
}


.notice-title {
    font-size: 13px;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.notice-title i {
    font-size: 1.5rem;
}

.notice-text {
    font-size: 13px;
    opacity: 0.9;
    padding: 12px 15px 12px 15px;
    margin: 15px 0px 20px 0px;
    background-color: #c1d1dd70;
    border-radius: 6px;
        line-height: 30px;
}

.notice-text2{
    font-size: 13px;
    opacity: 0.9;
    padding: 12px 15px 12px 15px;
    border-radius: 6px;
        line-height: 30px;
}


.notice-text2 a{
 color: #0058ff;
}

.stat-label a{ color: #0058ff;}

.client-code {
    font-size: 1.8rem;
    font-weight: bold;
    letter-spacing: 2px;
    margin: 10px 0;
    padding: 10px 15px;
    border-radius: var(--border-radius);
    display: inline-block;
        background: linear-gradient(45deg, #47bc06, #d6f700);
    color: #fff;
}



/* ——— overlay-контейнер ——— */
.photo-stats-overlay{
    position:absolute;
    top:15px;
    left:15px;
    display:flex;
    gap:10px;
    z-index:4;                /* выше изображения, но ниже кнопки замены фото */
}

/* ——— отдельная карточка-«бейдж» ——— */
.photo-stat{
    background: #fff;
    color: #0d0d0d;
    font-size: 12px;
    line-height: 1;
    padding: 8px 10px;
    border-radius: 3px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, .15);
    white-space: nowrap;
}
@media(max-width:768px){
    .photo-stat{
    background: #fff;
    color: #0d0d0d;
    font-size: 12px;
    line-height: 1;
    padding: 8px 10px;
    border-radius: 3px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, .15);
    white-space: nowrap;
}
.single-view .object-photo-placeholder {width:100px!important;}
    .single-view .photo-stat {display: none}
}

.single-view .object-photo-placeholder {width:500px}




/* Для разных видов отображения */
.single-view .object-photo-placeholder {
   max-height: 220px;
}

.double-view .object-photo-placeholder {
    height: 230px;
}

.triple-view .object-photo-placeholder {
    height: 230px;
}

/* Иконка внутри placeholder'а */
.object-photo-placeholder::before {
    content: "\f1ad"; /* Иконка здания из Font Awesome */
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    font-size: 50px;
    color: #ccc;
}


/* 1. Универсальная заглушка «Нет фото»  ------------------------------ */
.object-photo-placeholder {
    position: relative;
    width: 100%;

    background-color: #f0f0f0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #999;
}

/* текст «Нет фото» внизу заглушки */
.object-photo-placeholder::after{
    content:'Нет фото';
    position:absolute;
    left:0;
    right:0;
    bottom:10px;
    font:14px/1.3 "Inter", Arial, sans-serif;
    color:#6c757d;
    text-align:center;
    pointer-events:none;
}

/* 2. Заглушка внутри завершённых объектов (опционально сделать чуть «тусклее») */
.object-card.completed .object-photo-placeholder{
    filter:grayscale(100%) opacity(.7);
}

/* 3. Добавили единообразные правила и для реальных фото --------------- */
.object-card .object-photo{
    width:100%;

    position:relative;
    overflow:hidden;
    border-radius:6px 6px 0 0;
}

.object-card .object-photo img{
    position:absolute;
    top:0;left:0;right:0;bottom:0;
    width:100%;height:100%;
    object-fit:cover;
}













.user-profile-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 30px;
    max-width: 1000px;
    margin: 0 auto;
    padding: 5px;
    margin-top: 20px;
}

.profile-column {
    display: flex;
    flex-direction: column;
}

.profile-card {
    background: #fff;
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0px 0px 16px 3px rgb(62 62 62 / 10%);
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    flex: 1;
    height: 100%;
}

.profile-section-title {
    color: #3c6289;
    font-size: 15px;
    margin-top: 0;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid #eee;
}

.profile-section-title i {
    margin-right: 8px;
    color: #17488f;
}

.profile-item {
    display: flex;
    align-items: center;
    margin-bottom: 12px;
}

.profile-item i {
    width: 24px;
    color: #000;
    margin-right: 10px;
    text-align: center;
}

.label {
    font-weight: 600;
    color: #555;
    min-width: 20px;
    margin-right: 10px;
    font-size: 0.9rem;
}

.value {
    color: #333;
    flex: 1;
    font-size: 0.8rem;
}

.tariff-link {
    color: #4a6fa5;
    text-decoration: none;
    font-weight: 600;
}

.tariff-link:hover {
    text-decoration: underline;
}

.deleted-link {
    color: #d9534f;
    text-decoration: none;
}

.deleted-link:hover {
    text-decoration: underline;
}

.deleted-info {
    font-size: 0.8em;
    color: #777;
    margin-left: 5px;
}

strong {
    color: #2c3e50;
}

/* Мобильная адаптация */
@media (max-width: 768px) {
    .user-profile-container {
        grid-template-columns: 1fr;
    }

    .profile-item {
        flex-wrap: wrap;
    }

    .label {
        min-width: 20px;
        font-size: 0.8rem;
    }

    .value {
        margin-left: 0px;
        width: 100%;
    }

    .deleted-info {
        display: block;
        margin-left: 34px;
        margin-top: 5px;
    }
}


.transfer-notice {
    font-size: 0.8rem;
    color: #666;
    margin-top: 5px;
}






.update-content {    line-height: 16px;
    white-space: pre-line;
    font-size: 14px;
    font-weight: 100;}






    .current-version {
        font-size: 1.2em;
        margin-bottom: 30px;
        color: #4361ee;
    }
    .updates-list {
        margin-top: 30px;
    }
    .update-card {
        background: white;
        border-radius: 8px;
        padding: 25px;
        margin-bottom: 25px;
        box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    }
    .update-header {
        display: flex;
        align-items: center;
        margin-bottom: 15px;
        padding-bottom: 10px;
        border-bottom: 1px solid #eee;
    }
    .update-header h2 {
        margin: 0;
        font-size: 1.5em;
        color: #333;
    }
    .update-date {
        margin-left: 15px;
        color: #666;
        font-size: 0.9em;
    }
    .current-badge {
        background: #28a745;
        color: white;
        padding: 3px 10px;
        border-radius: 4px;
        font-size: 0.8em;
        margin-left: 15px;
    }





.object-address {
    margin: 15px 0;
    font-size: 1.1rem;
    color: #333;
}

.object-address i {
    margin-right: 8px;
    color: #e74c3c;
}

.object-map-container {
    margin: 20px 0;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.building-type-info {
    padding: 10px;
    border-radius: 5px;
}

.building-type-row {
    display: flex;
    margin-bottom: 5px;
}

.building-type-label {
    font-weight: 500;
    min-width: 100px;
    color: #555;
}

.building-type-value {
    color: #000;
}





.article-content h1 {font-size: 21px}








.legal-container {
  max-width: 900px;
  margin: 0 auto;
  line-height: 1.6;
  color: #333;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.legal-container h1 {
  font-size: 2.2em;
  margin-bottom: 10px;
  color: #1a1a1a;
  border-bottom: 3px solid #2563eb;
  padding-bottom: 15px;
}

.legal-container h2 {
  font-size: 1.5em;
  margin-top: 40px;
  margin-bottom: 20px;
  color: #1a1a1a;
  border-left: 4px solid #2563eb;
  padding-left: 15px;
}

.legal-container h3 {
  font-size: 1.2em;
  margin-top: 25px;
  margin-bottom: 15px;
  color: #374151;
}

.legal-container .last-update {
  background: #f3f4f6;
  padding: 12px 16px;
  border-radius: 6px;
  margin: 20px 0;
  font-size: 0.95em;
  color: #6b7280;
  display: inline-block;
}

.legal-container .definitions {
  background: #f9fafb;
  padding: 20px;
  border-radius: 8px;
  margin: 25px 0;
  border: 1px solid #e5e7eb;
}

.legal-container .definitions h3 {
  margin-top: 0;
  color: #1a1a1a;
}

.legal-container dl {
  margin: 0;
}

.legal-container dt {
  font-weight: 600;
  color: #1a1a1a;
  margin-top: 15px;
  margin-bottom: 5px;
}

.legal-container dd {
  margin-left: 0;
  color: #4b5563;
  line-height: 1.5;
}

.legal-container .data-table {
  width: 100%;
  border-collapse: collapse;
  margin: 20px 0;
  font-size: 0.95em;
}

.legal-container .data-table th,
.legal-container .data-table td {
  padding: 12px;
  text-align: left;
  border: 1px solid #e5e7eb;
}

.legal-container .data-table th {
  background: #f9fafb;
  font-weight: 600;
  color: #374151;
}

.legal-container .data-table tr:nth-child(even) {
  background: #f9fafb;
}

.legal-container .warning-box {
  background: #fef3c7;
  border-left: 4px solid #f59e0b;
  padding: 16px 20px;
  margin: 20px 0;
  border-radius: 0 6px 6px 0;
}

.legal-container .warning-box strong {
  color: #92400e;
}

.legal-container ul,
.legal-container ol {
  padding-left: 25px;
  margin: 15px 0;
}

.legal-container li {
  margin-bottom: 8px;
}

.legal-container p {
  margin: 15px 0;
}

@media (max-width: 768px) {
  .legal-container {
    padding: 20px 15px;
  }

  .legal-container h1 {
    font-size: 1.8em;
  }

  .legal-container .data-table {
    font-size: 0.85em;
  }

  .legal-container .data-table th,
  .legal-container .data-table td {
    padding: 8px;
  }
}















.article-content {
    padding: 0px!important;
    flex: 1;
    display: flex;
    flex-direction: column;

    /* Критически важно для flex-контейнеров */
    min-width: 0;
    overflow: hidden;
}

/* Все прямые дочерние элементы не должны превышать ширину */
.article-content > * {
    max-width: 100%;
}

/* Таблицы — горизонтальная прокрутка */
.article-content table,
.article-content .data-table {
    display: block;
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border-collapse: collapse;
}

/* Внутренности таблицы возвращаем в нормальный режим */
.article-content table thead,
.article-content table tbody,
.article-content table tfoot {
    display: table;
    width: 100%;
    min-width: 600px; /* Минимальная ширина для читаемости */
}

.article-content table th,
.article-content table td {
    word-wrap: break-word;
    overflow-wrap: break-word;
    hyphens: auto;
}

/* Списки определений */
.article-content dl {
    margin: 0;
}

.article-content dt {
    font-weight: bold;
    margin-top: 15px;
}

.article-content dd {
    margin-left: 0;
    margin-top: 5px;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

/* Длинные слова и ссылки */
.article-content a,
.article-content p,
.article-content li {
    word-wrap: break-word;
    overflow-wrap: break-word;
    hyphens: auto;
}

/* Изображения */
.article-content img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Предупреждающие блоки */
.article-content .warning-box,
.article-content .last-update,
.article-content .definitions {
    max-width: 100%;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

/* Заголовки */
.article-content h2,
.article-content h3 {
    word-wrap: break-word;
    overflow-wrap: break-word;
}
