.video_detection_wrapper {
    /*padding: 20px;*/
}
.video_detection_wrapper .progress_bar{
    height: 6px;
    border-radius: 3px;
}
.task_page .upload_progress{
    margin: -20px  0 10px 0;
}
.task_page .progress_text{
    visibility: hidden;
}
.task_page .progress_fill{
    visibility: hidden;
}
.task_page .upload_progress.upload .progress_text{
    visibility: visible;
}
.task_page .upload_progress.upload .progress_fill{
    visibility: visible;
}
.video_detection_wrapper .progress_fill{
    /*background: #555;*/
}
.video_detection_wrapper .progress_text{
    margin: 0 0 10px 0;
}
.view_content_wrapper{
    padding: 0 0 40px 0;
    width: 99%;
}
.upload_section {
    background: #fff;
    border: 1px solid #ddd;
    /*border-radius: 4px;*/
    padding: 20px;
    margin-bottom: 30px;
}
.upload_header h2 {
    margin: 0 0 10px 0;
    font-size: 1.2em;
    font-weight: 700;
    color: #222;
    letter-spacing: 1px;
}
.upload_area {
    height: 260px;
    padding: 40px 0 0;
    border: 2px dashed #CCC;
    border-radius: 8px;
    text-align: center;
    background: #F5F5F5;
    margin-bottom: 15px;
    transition: background 0.2s;
    position: relative;
}
.upload_area:hover{
    border: 2px dashed #1976d2;
    background: #f5f8fa;
}
.upload_area input[type=file]{
    display: none;
}
.upload_placeholder{
    padding: 40px 0;
}
.upload_area.dragover {
    background: #e3f2fd;
}
.detection_files_label{
    display: block;
    background: transparent;
    position: absolute;
    top: 0;
    bottom: 0;
    right: 0;
    left: 0;
    cursor: pointer;
    z-index: 100;
}
.upload_icon {
    font-size: 48px;
    margin-bottom: 10px;
}
.upload_info {
    color: #888;
    font-size: 13px;
}
.upload_progress {
    margin-top: 10px;
}
.progress_bar {
    width: 100%;
    height: 8px;
    background: #eee;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 5px;
}
.progress_fill {
    height: 100%;
    background: #1976d2;
    width: 0;
    transition: width 0.3s;
}
.progress_text {
    font-size: 13px;
    color: #1976d2;
}
.videos_section {
    background: #FFF;
    padding: 20px;
}
.videos_header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}
.videos_actions {
    display: flex;
    gap: 10px;
}
.videos_actions form{
    display: none;
}
.videos_list {
    display: flex;
    flex-direction: column;
    margin: 20px 0 0 0;
}
.video_item {
    display: flex;
    align-items: flex-start;
    border-bottom: 1px dashed #CCC;
    flex-wrap: wrap;
    position: relative;
}
.video_item > .cover{
    display: block;
    width: 100%;
}
.video_item:hover{
    background: #F9F9F9;
}
.video_main_info_wrapper{
    width: auto;
    display: flex;
    padding: 20px 0 10px 20px;
}
.video_item input.processing_select{
    display: none;
}
.video_item .video_select{

}
.video_status_wrapper{
    height: 24px;
    display: flex;
}
.video_item label.processing_label {
    position: absolute;
    right: 0;
    bottom: 0;
    top: 0;
    left: 0;
    background: transparent;
    cursor: pointer;
    border-bottom: none;
    z-index: 10;
}
label.processing_label + input[type="checkbox"]:checked ~ .video_main_info_wrapper{
    background: #F2F2F2;
}
label.processing_label + input[type="checkbox"]:checked ~ .processing_statuses_wrapper{
    background: #F2F2F2;
}
label.processing_label + input[type="checkbox"]:checked ~ .event_actions{
    background: #F2F2F2;
}
label.processing_label + input[type="checkbox"] + .video_main_info_wrapper > .video_actions{
    visibility: hidden;
}
label.processing_label + input[type="checkbox"]:checked + .video_main_info_wrapper > .video_actions{
    background: #F2F2F2;
    visibility: visible;
    z-index: 10;
}
label.processing_label + input[type="checkbox"]:checked ~ .processing_statuses_wrapper > .processing_list > li{
    border: #F2F2F2 solid 1px;
}
label.processing_label + input[type="checkbox"]:checked ~ .processing_statuses_wrapper > .processing_list > li.active{
    border: #777 solid 1px;
}
.processing_statuses_wrapper {
    height: 30px;
    flex-shrink: 1;
    flex-grow: 0;
    flex-basis: 100%;
    padding: 0 20px 20px;
}
.processing_list{
    display: flex;
    gap: 8px;
    padding: 6px 0;
}
.processing_list > li{
    padding: 4px 8px;
    /*background: #F2F2F2;*/
    border: transparent solid 1px;
    font-size: 12px;
    text-transform: lowercase;
}
.processing_list > li.active{
    border: #777 solid 1px;
}
.processing_list > li > span{
    color: #111;
}
.video_item:last-child {
    border-bottom: none;
}
.video_preview {
    width: 120px;
    height: 68px;
    background: #000;
    background-size: cover;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}
.preview_placeholder {
    color: #fff;
    font-size: 32px;
    text-align: center;
}
.video_status {
    position: absolute;
    bottom: 5px;
    right: 8px;
    font-size: 18px;
}
.status_icon {
    font-size: 18px;
}
.video_info {
    flex: 1;
}
.video_main_info_wrapper .video_info{
    padding: 0 20px;
}
.file_info_wrapper{
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.file_status_wrapper > .recording_type{
    padding: 4px 8px;
    font-size: 12px;
    display: inline-block;
    background: #e5e5e5;
    border-radius: 0;
    margin: 1px 0 0 0;
}
.file_status_wrapper > .recording_type.entry{
    background: #e3f2fd;
    color: #7b1fa2;
}
.file_status_wrapper > .recording_type.completed{
    background: #e3f2fd;
    color: #1976d2;
}
.file_download_wrapper{
    width: 220px;
    font-size: 14px;
    color: #888;
    text-align: right;
}
.video_header {
    display: flex;
    align-items: center;
    gap: 15px;
    position: relative;
    z-index: 10;
}
.video_header > a{
    margin: 0;
    font-size: 16px;
    color: #555;
    font-weight: 600;
    text-transform: uppercase;
}
.video_header > a:hover{
    color: #111;
}
.video_header > a.processed{
    color: #1976d2;
}
.video_header > a.processed:hover{
    color: #094cb8;
}
.video_status_text {
    font-size: 13px;
    padding: 2px 8px;
    border-radius: 4px;
    background: #e5e5e5;
}
.video_status_text.processed {
    background: #e3f2fd;
    color: #1976d2;
}
.video_status_text.processing {
    background: #fffde7;
    color: #fbc02d;
}
.video_status_text.pending {
    background: #f5f5f5;
    color: #888;
}
.video_details {
    display: flex;
    gap: 15px;
    color: #888;
    font-size: 13px;
    margin-top: 5px;
    flex-wrap: wrap;
}
.detail_item {
    display: flex;
    gap: 4px;
}
.detection_results {
    display: flex;
    gap: 10px;
    margin-top: 5px;
}
.result_item {
    font-size: 13px;
    color: #388e3c;
}
.video_actions {
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-width: 120px;
}
.action_btn {
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 8px 12px;
    border: none;
    background: #f5f5f5;
    color: #333;
    font-size: 14px;
    cursor: pointer;
    border-radius: 4px;
    transition: background 0.3s;
    position: relative;
}
.action_btn:hover {
    background: #e5e5e5;
}
.action_btn.process {
    color: #1976d2;
}
.action_btn.view_results {
    color: #388e3c;
}
.action_btn.download {
    text-align: center;
    color: #1976d2;
}
.download_action,
.delete_action{
    text-align: center;
    background: #F5F5F5;
    display: inline-block;
    font-size: 14px;
    border-radius: 4px;
    padding: 8px 12px;
    width: auto;
}
.download_action{
    color: #1976d2;
}
.delete_action{
    color: #d32f2f;
}
.download_action:hover,
.delete_action:hover{
    background: #E5E5E5;
}
.action_btn.delete {
    color: #d32f2f;
}
.videos_actions > .action_btn{
    height: 45px;
}
label.upload_detection_files_label{
    background: #F5F5F5;
    cursor: pointer;
    border-radius: 4px;
    padding: 8px 12px;
}
label.upload_detection_files_label:hover{
    background: #E5E5E5;
}
@media (max-width: 900px) {
    .video_item {
        flex-direction: column;
        gap: 10px;
    }
    .video_preview {
        width: 100%;
        height: 180px;
    }
    .video_actions {
        flex-direction: row;
        gap: 10px;
        min-width: 0;
    }
}
.payment_wrapper {
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 30px 20px;
    max-width: 700px;
    margin: 0 auto;
}
.payment_wrapper h2 {
    font-size: 24px;
    font-weight: 600;
    margin-bottom: 25px;
    text-align: center;
}
.tariffs_section {
    background: #F5F5F5;
    padding: 60px 0;
    margin-top: 40px;
}
.tariffs_section .description_container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}
.tariffs_section h3 {
    font-size: 28px;
    font-weight: 600;
    color: #333;
    text-align: center;
    margin-bottom: 30px;
}
.tariffs_grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    max-width: 800px;
    margin: 0 auto;
}
.tariff_plan {
    background: #fff;
    border-radius: 12px;
    padding: 30px 25px;
    position: relative;
    transition: transform 0.2s, box-shadow 0.2s;
}
.tariff_plan:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
}
.tariff_plan.featured {
    border-color: #1976d2;
}
.tariff_badge {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: #1976d2;
    color: #fff;
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
}
.tariff_header {
    margin-bottom: 25px;
}
.tariff_header h4 {
    font-size: 22px;
    font-weight: 600;
    color: #333;
    margin-bottom: 15px;
}
.tariff_price {
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: 4px;
}
.price_amount {
    font-size: 36px;
    font-weight: 700;
    color: #1976d2;
}
.price_currency {
    font-size: 18px;
    color: #666;
}
.tariff_features {
    margin-bottom: 25px;
}
.tariff_features ul {
    list-style: none;
    padding: 0;
    margin: 0;
}
.tariff_features li {
    padding: 8px 0;
    color: #555;
    font-size: 14px;
    position: relative;
    padding-left: 20px;
}
.tariff_features li:before {
    content: "✓";
    position: absolute;
    left: 0;
    color: #4caf50;
    font-weight: bold;
}
.tariff_btn {
    width: 100%;
    padding: 12px 0;
    border: 2px solid #1976d2;
    background: #1976d2;
    color: #fff;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}
.tariff_btn:hover {
    background: #125ea7;
    border-color: #125ea7;
}
.tariff_btn.featured {
    background: #1976d2;
    border-color: #1976d2;
}
.detection_description {
    font-size: 18px;
    color: #666;
    text-align: center;
    margin-bottom: 30px;
}
@media (max-width: 768px) {
    .tariffs_grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    .tariff_plan {
        padding: 25px 20px;
    }
    .price_amount {
        font-size: 32px;
    }
}
.payment_success_wrapper,
.payment_failure_wrapper {
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 40px 20px;
    max-width: 500px;
    margin: 0 auto;
    text-align: center;
}
.success_icon,
.failure_icon {
    font-size: 48px;
    margin-bottom: 20px;
}
.success_icon {
    color: #4caf50;
}
.failure_icon {
    color: #f44336;
}
.payment_success_wrapper h2,
.payment_failure_wrapper h2 {
    font-size: 24px;
    font-weight: 600;
    margin-bottom: 15px;
}
.payment_success_wrapper p,
.payment_failure_wrapper p {
    font-size: 16px;
    color: #555;
    margin-bottom: 20px;
}
.payment_details {
    background: #f5f8fa;
    border-radius: 4px;
    padding: 15px;
    margin-bottom: 25px;
    text-align: left;
}
.payment_details p {
    margin: 5px 0;
    font-size: 14px;
}
.success_actions,
.failure_actions {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
}
.success_actions .btn,
.failure_actions .btn {
    padding: 10px 20px;
    border-radius: 4px;
    text-decoration: none;
    font-weight: 500;
    transition: background 0.2s;
}
.btn_primary {
    background: #1976d2;
    color: #fff;
}
.btn_primary:hover {
    background: #125ea7;
}
.btn_secondary {
    background: #f5f5f5;
    color: #333;
    border: 1px solid #ddd;
}
.btn_secondary:hover {
    background: #e5e5e5;
}
@media (max-width: 600px) {
    .success_actions,
    .failure_actions {
        flex-direction: column;
    }
    .success_actions .btn,
    .failure_actions .btn {
        width: 100%;
        text-align: center;
    }
}
.video_view_grid {
    display: flex;
    align-items: flex-start;
    min-height: 480px;
    /*max-height: 620px;*/
    align-content: space-between
}
.video_view_grid.full{
    position: fixed;
    bottom: 0;
    top: 0;
    right: 0;
    left: 0;
    background: #FFF;
    z-index: 100;
    padding: 30px;
}
.video_content_narrow {
    width: 80%;
    margin: 0 30px 0 0;
    /* height: 100%; убрано */
}
.video_content_narrow .video_container {
    width: 100%;
}
.detection_results_panel {
    background: #fff;
    border: 1px solid #ddd;
    width: 30%;
    display: flex;
    align-items: stretch;
    flex-direction: column;
    align-self: stretch;
    /* height: 100%; убрано */
    max-height: 100%;
    overflow: auto;
}
.detection_results_panel .events_timeline {
    overflow-y: auto;
    padding-right: 8px;
}
.detection_results_panel .events_timeline::-webkit-scrollbar {
    width: 6px;
}
.detection_results_panel .events_timeline::-webkit-scrollbar-thumb {
    background: #ddd;
    border-radius: 3px;
}
.detection_results_panel .events_timeline::-webkit-scrollbar-thumb:hover {
    background: #bbb;
}
.detection_results_panel > .results_header{
    margin: 15px;
}
.results_header > hr{
    margin: 12px 0;
    border: none;
    border-bottom: 1px dashed #CCC;
}
.detection_summary{
    font-size: 13px;
    margin: 15px 0;
}
.summary_item{
    margin: 4px 0;
}
.summary_item > span.label{
    font-weight: 400;
    color: #888;
}
.summary_item > span.value{
    color: #000;
}
.detection_results_panel > .events_timeline{
    margin: 10px 8px 20px 15px;
    gap: 0;
}
.detection_results_panel > .events_timeline .event_item{
    position: relative;
    border-bottom: 1px dashed #CCC;
    padding: 0;
    gap: 0;
}
.detection_results_panel > .events_timeline .event_item:hover{
    background: #F9F9F9;
}
.video_alarm_segments_wrapper > .event_item.active:hover > .event_actions{
    background: #a66969;
}
.audio_alarm_segments_wrapper > .event_item.active:hover > .event_actions{
    background: #276baf;
}
.detection_results_panel > .events_timeline .event_item:last-child{
    border-bottom: none;
}
.events_timeline .event_item > input[type="checkbox"]{
    display: none;
}
.events_timeline .event_item > input[type="checkbox"]:checked ~ .event_time{
    background: #F2F2F2;
}
.events_timeline .event_item > input[type="checkbox"]:checked ~ .event_content{
    background: #F2F2F2;
}
.events_timeline .event_item > input[type="checkbox"]:checked ~ .event_actions{
    background: #F2F2F2;
}
.events_timeline .event_item > label.event_checkbox_label{
    position: absolute;
    right: 0;
    bottom: 0;
    top: 0;
    left: 0;
    background: transparent;
    cursor: pointer;
    border-bottom: none;
    z-index: 10;
}
.events_timeline .event_item > .event_time{
    width: 70px;
    height: 60px;
    padding: 15px 0;
    margin: 0;
}
.events_timeline .event_item > .event_content{
    height: 60px;
    padding: 15px 0;
}
.events_timeline > .event_item > .event_content{
    height: 60px;
    padding: 15px 0;
}
.events_timeline .event_item > .event_time,
.events_timeline .event_item > .event_content,
.events_timeline .event_item > .event_actions {
    position: relative;
    /*z-index: 50;*/
}
.events_timeline .event_item > .event_actions > .action_btn{
    background: transparent !important;
}
.content_inner{
    border-left: none;
}
@media (max-width: 1100px) {
    .video_view_grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    .detection_results_panel {
        max-width: 100%;
        margin-top: 20px;
    }
    .video_content_narrow .video_container {
        max-width: 100%;
    }
}
.page_description {
    background: #FFF;
    padding: 60px 0;
}
.description_container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}
.page_description h3 {
    font-size: 28px;
    font-weight: 600;
    color: #333;
    text-align: center;
    margin-bottom: 20px;
}
.description_container > p.detection_description {
    font-size: 16px;
    font-weight: 400;
    color: #888;
    text-align: center;
    margin-bottom: 40px;
}
.features_grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
    margin-bottom: 40px;
}
.feature_item {
    background: #fff;
    border: 1px dashed #DDD;
    border-radius: 8px;
    padding: 25px;
    text-align: center;
    transition: transform 0.2s, box-shadow 0.2s;
}
.feature_item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}
.feature_icon {
    font-size: 32px;
    margin-bottom: 15px;
}
.feature_item h4 {
    font-size: 18px;
    font-weight: 600;
    color: #333;
    margin-bottom: 10px;
}
.feature_item p {
    font-size: 14px;
    color: #666;
    line-height: 1.5;
}
.workflow_description {
    background: #fff;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 30px;
    margin: 0 auto;
}
.workflow_description h4 {
    font-size: 20px;
    font-weight: 600;
    color: #333;
    margin-bottom: 20px;
}
.workflow_description ol {
    padding-left: 20px;
}
.workflow_description li {
    font-size: 16px;
    color: #555;
    margin-bottom: 12px;
    line-height: 1.6;
}
.workflow_description strong {
    color: #1976d2;
    font-weight: 600;
}
@media (max-width: 768px) {
    .features_grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    .feature_item {
        padding: 20px;
    }
    .workflow_description {
        padding: 20px;
    }
    .page_description h3 {
        font-size: 24px;
    }
}
.dragdrop-modal {
    position: fixed;
    z-index: 9000;
    top: 0; left: 0; right: 0; bottom: 0;
    align-items: center;
    justify-content: center;
    pointer-events: none;
    background: rgba(0, 0, 0, 0.45);
    display: none;
}
.dragdrop-modal.active {
    pointer-events: all;
    display: block;
}
.dragdrop-modal__overlay {

}
.dragdrop-modal .upload_placeholder{
    text-align: center;
}
.dragdrop-modal .upload_placeholder h3{
    color: #FFF;
}
.dragdrop-modal .upload_placeholder p{
    color: #FFF;
}
.dragdrop-modal .upload_placeholder p.upload_info{
    color: #CCC;
}
.dragdrop-modal__content {
    position: absolute;
    top: 6%;
    right: 3%;
    bottom: 6%;
    left: 3%;
    background: transparent;
    border: #FFF dashed 7px;
    padding: 48px 64px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-width: 320px;
    z-index: 100;
}
.dragdrop-modal__icon {
    font-size: 3.5rem;
    margin-bottom: 18px;
}
.dragdrop-modal__text {
    font-size: 1.3rem;
    color: #1976d2;
    font-weight: 500;
    text-align: center;
}
@media (max-width: 600px) {
    .dragdrop-modal__content {
        padding: 32px 10px;
        min-width: 0;
        width: 90vw;
    }
    .dragdrop-modal__icon {
        font-size: 2.2rem;
    }
    .dragdrop-modal__text {
        font-size: 1rem;
    }
}
label.check_item_bool{
    display: flex;
    background: #F5F5F5;
    cursor: pointer;
    border-radius: 4px;
    padding: 12px 14px;
}
label.check_item_bool > input[type='checkbox']{display: none}

label.check_item_bool span.box_wrapper{
    width: 15px;
    height: 15px;
    display: block;
    float: left;
    cursor: pointer;
    background: transparent;
    border: 2px solid #939393;
}
input.error_input_field + span.box_wrapper{
    border: 2px solid #D3544E;
}
input.error_input_field ~ span.key > a{
    color: #D3544E !important;
}
label.check_item_bool span.cover{
    width: 0;
    height: 13px;
    margin: 1px 0 0 2px;
    display: inline-block;
    line-height: 12px;
    overflow: hidden;

    -ms-user-select: none;
    -moz-user-select: none;
    -khtml-user-select: none;
    -webkit-user-select: none;

    -webkit-transition: width 0.1s ease-in-out;
    -moz-transition: width 0.1s ease-in-out;
    -ms-transition: width 0.1s ease-in-out;
    -o-transition: width 0.1s ease-in-out;
    transition: width 0.1s ease-in-out;
}
label.check_item_bool span.cover > img{
    vertical-align: middle;
}
label.check_item_bool span.key{
    width: 80%;
    margin: 2px 0 0 10px;
    cursor: pointer;
    color: #555;
    display: block;
    float: left;
    font-size: 14px;
    font-weight: 400;
    vertical-align: middle;
}
label.check_item_bool span.key > span:first-child > span{
    display: inline-block;
    padding: 1px 0;
    background: #FFE7A3
}
label.check_item_bool span.key span.count{
    font-size: 12px;
    color: #C0C0C0;
}
label.check_item_bool span.key > span > span.count_list{
    background: #FFF;
    color: #C0C0C0;
    font-size: 13px;
}
label.check_item_bool > input[type='checkbox']:checked + span.box_wrapper > span.cover{width: 11px}
label.check_item_bool:hover span.box_wrapper{border: #000 solid 2px}
label.check_item_bool:hover span.key{color: #000}
label.check_item_bool > input[type='checkbox']:checked + span.box_wrapper{border: #000 solid 2px}
label.check_item_bool > input[type='checkbox']:checked ~ span.key{
    color: #111;
    font-weight: 500
}
label.check_item_bool > input[type='checkbox']:checked ~ span.key > a{
    color: #111;
    font-weight: 600
}
.search_description > label.check_item_bool {
    width: 50%;
    margin: 10px 0 10px 0;
}
.detection_flow_wrapper{
    background: #F5F5F5;
}
.view_navigate_tab_wrapper{
    width: 100%;
    background: #DDD;
    margin: 15px 0;
}
ul.view_navigate_tabs{
    margin: 0 1%;
    padding: 10px 0 0 0;
}
ul.view_navigate_tabs > li{
    width: 33%;
    height: 38px;
    float: left;
    background: #DDD;
    line-height: 38px;
}
ul.view_navigate_tabs > li.active{
    background: #FFF;
}
ul.view_navigate_tabs > li.active > a{
    color: #000;
}
ul.view_navigate_tabs > li > a{
    display: block;
    width: 100%;
    height: 38px;
    text-align: center;
    color: #444;
    vertical-align: middle;
    font-size: 12px;
    text-transform: uppercase;
}
ul.view_navigate_tabs > li:hover > a{
    color: #000;
}
input.volume_slider::-webkit-slider-thumb {
    background: #FFF;
}
.video_container{
    border-radius: 0;
}
.video_controls{
    background: #e8e8e7;
    /*border-top: #FFF solid 3px;*/
}
.volume_slider {
    background: #888;
}
.control_btn{
    color: #FFF;
    background-color: #4242427F;
}
.control_btn.active{
    background: #444;
}

/* Стили для кнопок управления timeline */
.timeline-controls {
    display: flex;
    gap: 5px;
    margin: 0 10px;
}

.timeline-controls .timeline-btn {
    padding: 8px;
    min-width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #4242427F;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.timeline-controls .timeline-btn:hover {
    background-color: #555;
}

.timeline-controls .timeline-btn:active {
    background-color: #666;
}

.timeline-controls .timeline-btn svg {
    width: 1.2em;
    height: 1.2em;
    fill: none;
    stroke: #fff;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

/* Стили для счетчика выделений */
.selections-counter {
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 0, 0.8);
    color: #333;
    font-size: 12px;
    font-weight: bold;
    padding: 4px 8px;
    border-radius: 3px;
    min-width: 20px;
    height: 20px;
    margin-right: 5px;
}
.selections-counter .counter-text {
    font-size: 11px;
    font-weight: 600;
}
.timeline{
    height: 10px;
    background: #999;
    border-radius: 0;
    margin-bottom: 25px;
    cursor: pointer;
    position: relative;
}

/* Стили для выделений на timeline */
.timeline-selections {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 5;
}

.timeline-selection {
    position: absolute;
    top: 0;
    height: 100%;
    background: #f8db75;
    pointer-events: auto;
    z-index: 6;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.timeline-selection:hover {
    background: rgba(255, 255, 0, 0.7);
    border-color: rgba(255, 255, 0, 1);
}

.detection_marker{
    position: absolute;
    width: 8px;
    height: 10px;
    background: #a65f5f;
    border-radius: 0;
    cursor: pointer;
    z-index: 7; /* Выше выделений */
}
.detection_marker.audio{
    background: #276baf;
}
.progress {
    background: #555;
    border-radius: 0;
    position: relative;
}
.progress:after{
    content: '';
    position: absolute;
    display: block;
    border: 5px solid transparent;
    border-top: 8px solid #555;
    top: -12px;
    right: -5px;
}
.event_marker {
    position: absolute;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 80px;
    height: 6px;
    background: #d32f2f;
    border-radius: 0;
    cursor: pointer;
}
.video_view_help{
    margin: 24px 0 0 0;
    padding: 20px 28px;
    background: #F5F5F5;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
    display: flex;
    align-items: flex-start;
    gap: 18px;
}

/* Стили для формы настроек детекции */
.detection_settings_wrapper {
    padding: 20px;
}
.detection_settings_wrapper h3 {
    margin-bottom: 20px;
    color: #333;
    font-size: 18px;
    font-weight: 500;
}
.form_group {
    margin-bottom: 25px;
}
.form_group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #555;
    font-size: 14px;
}
.range_container {
    display: flex;
    align-items: center;
    gap: 15px;
}
.range_container input[type="range"] {
    flex: 1;
    height: 6px;
    border-radius: 3px;
    background: #ddd;
    outline: none;
    -webkit-appearance: none;
    appearance: none;
}
.range_container input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #1976d2;
    cursor: pointer;
    border: 2px solid #fff;
    box-shadow: 0 2px 6px rgba(0,0,0,0.2);
    transition: all 0.2s ease;
}
.range_container input[type="range"]::-webkit-slider-thumb:hover {
    background: #1565c0;
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
}
.range_container input[type="range"]::-moz-range-thumb {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #1976d2;
    cursor: pointer;
    border: 2px solid #fff;
    box-shadow: 0 2px 6px rgba(0,0,0,0.2);
    transition: all 0.2s ease;
}
.range_container input[type="range"]::-moz-range-thumb:hover {
    background: #1565c0;
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
}
.range_container input[type="range"]::-webkit-slider-track {
    background: linear-gradient(to right, #1976d2 0%, #1976d2 50%, #ddd 50%, #ddd 100%);
    border-radius: 3px;
    height: 6px;
}
.range_value {
    min-width: 60px;
    padding: 8px 12px;
    /*background: #DDD;*/
    color: #222;
    border-radius: 3px;
    font-weight: 600;
    font-size: 14px;
    text-align: center;
    border: #DDD solid 1px;
}
.detection_settings_wrapper .action_btn {
    width: 100%;
    padding: 12px;
    background: #1976d2;
    color: #fff;
    border: none;
    border-radius: 6px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 10px;
}
.detection_settings_wrapper .action_btn:hover {
    background: #1565c0;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(25,118,210,0.3);
}
.action_btn.active {
    background: #E0E0E0;
}
.action_btn.active:hover {
    background: #CCC;
}
.detection_settings_wrapper .action_btn:active {
    transform: translateY(0);
}
/* Адаптивность для настроек */
@media (max-width: 768px) {
    .detection_settings_wrapper {
        padding: 15px;
    }
    
    .range_container {
        flex-direction: column;
        gap: 10px;
        align-items: stretch;
    }
    
    .range_value {
        align-self: center;
        min-width: 80px;
    }
}

.video_processing_status {
    padding: 4px 8px;
    background: #F0F0F0;
    font-size: 12px;
    text-transform: lowercase;
    margin: 0 10px;
}
.video_processing_status.pending { color: #888; }
.video_processing_status.converting { color: #1976d2; }
.video_processing_status.segmenting { color: #ff9800; }
.video_processing_status.decoding { color: #7b1fa2; }
.video_processing_status.saving { color: #388e3c; }
.video_processing_status.processed {
    color: #388e3c;
    background: #F0F0F0;
}
.video_processing_status .processing_icon {
    font-size: 12px;
}
.videos_pagination{
    margin: 20px 0 0 0;
}
.events_pagination {
    display: flex;
    justify-content: left;
    align-items: flex-start;
    gap: 6px;
    margin: 18px 0 0 0;
}
.pagination_btn {
    background: #f5f5f5;
    border: none;
    color: #1976d2;
    font-size: 15px;
    font-weight: 500;
    padding: 6px 13px;
    border-radius: 5px;
    cursor: pointer;
    transition: background 0.2s, color 0.2s;
}
.pagination_btn.active,
.pagination_btn:hover:not(:disabled) {
    background: #1976d2;
    color: #fff;
}
.pagination_btn:disabled {
    color: #bbb;
    background: #eee;
    cursor: default;
}
.pagination_dots {
    color: #888;
    font-size: 18px;
    padding: 0 4px;
}

/* Стили для селектора типа сегментов */
.alarm_segment_type_wrapper{
    position: relative;
    height: 34px;
    display: flex;
    line-height: 36px;
    vertical-align: middle;
}
.alarm_segment_type_wrapper > h4{
    margin: 0 0 0 10px;
}
.segment_type_selector {
    width: auto;
    position: absolute;
    right: 15px;
    display: flex;
}
.segment_type_selector .radio_group input[type=radio]{
    display: none;
}
.radio_group {
    display: flex;
    gap: 5px;
    flex-wrap: wrap;
}

.radio_label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}

.radio_label:hover > .radio_icon{
    border: #444 dashed 1px;
}

.radio_label input[type="radio"] {
    display: none;
}
.radio_label input[type="radio"]:checked + .radio_custom::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 6px;
    height: 6px;
    background-color: white;
    border-radius: 50%;
}
.radio_label input[type="radio"]:checked ~ span {
    color: #1976d2;
    font-weight: 600;
}
.radio_icon {
    display: flex;
    width: 30px;
    height: 30px;
    align-items: center;
    justify-content: center;
    border: #FFF dashed 1px;
    color: #777;
}
.radio_icon svg {
    width: 16px;
    height: 16px;
}
.radio_label input[type="radio"]:checked ~ .radio_icon {
    border: #888 dashed 1px;
    color: #444;
}

/* Адаптивность для мобильных устройств */
@media (max-width: 768px) {
    .radio_group {
        flex-direction: column;
        gap: 12px;
    }
    
    .radio_label {
        padding: 10px 12px;
        font-size: 15px;
    }
}

/* Скрытие элементов */
.none {
    display: none !important;
}

/* Активное состояние для событий */
.event_item.active {
    background: #a66969;
}
.event_item.active .event_time {
    background: #a66969 !important;
    color: #222;
}
.event_item.active > .event_content {
    background: #a66969 !important;
    color: #222;
}
.events_timeline .event_item.active > input ~ .event_content{
    background: #a66969;
    color: #222;
}
.video_alarm_segments_wrapper > .event_item.active > input[type="checkbox"]:checked ~ .event_actions{
    background: #a66969;
    color: #222;
}
.video_alarm_segments_wrapper > .event_item.active > input ~ .event_actions{
    background: #a66969;
    color: #222;
}
.audio_alarm_segments_wrapper > .event_item.active {
    background: #276baf !important;
}
.audio_alarm_segments_wrapper > .event_item.active .event_time {
    background: #276baf !important;
    color: #222;
}
.audio_alarm_segments_wrapper > .event_item.active > .event_content {
    background: #276baf !important;
    color: #222;
}
.audio_alarm_segments_wrapper > .event_item.active > input ~ .event_content{
    background: #276baf !important;
    color: #222;
}
.audio_alarm_segments_wrapper > .event_item.active > input ~ .event_actions{
    background: #276baf !important;
    color: #222;
}
.audio_alarm_segments_wrapper > .event_item.active > input[type="checkbox"]:checked ~ .event_actions{
    background: #276baf !important;
    color: #222;
}
.audio_alarm_segments_wrapper > .event_item.active > input[type="checkbox"] ~ .event_actions{
    background: #276baf !important;
    color: #222;
}
.events_timeline .event_item.active > input ~ .event_actions > .action_btn{
    color: #FFF;
}
/* Стили для блока #alarms с внутренним скроллом */
#alarms {
    max-height: 500px;
    overflow-y: auto;
    overflow-x: hidden;
}
#alarms::-webkit-scrollbar {
    width: 6px;
}
#alarms::-webkit-scrollbar-thumb {
    background: #ddd;
    border-radius: 3px;
}
#alarms::-webkit-scrollbar-thumb:hover {
    background: #bbb;
}






































