body {
    font-size: .875rem;
    height: 100vh;
    height: calc(var(--vh, 1vh) * 100);

}

.feather {
    width: 16px;
    height: 16px;
    vertical-align: text-bottom;
}

/* === СТИЛИ ДЛЯ САЙДБАРА === */

.sidebar {
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    z-index: 100;
    padding: 48px 0 0;
    box-shadow: inset -1px 0 0 rgba(0, 0, 0, .1);
}

.sidebar-sticky {
    position: relative;
    top: 0;
    height: calc(100vh - 48px);
    padding-top: .5rem;
    overflow-x: hidden;
    overflow-y: auto;
}

.sidebar .nav-link {
    font-weight: 500;
    color: #333;
}

.sidebar .nav-link .feather {
    margin-right: 4px;
    color: #727272;
}

.sidebar .nav-link.router-link-active {
    color: #2470dc;
}

.sidebar .nav-link:hover .feather,
.sidebar .nav-link.router-link-active .feather {
    color: inherit;
}

.sidebar-heading {
    font-size: .75rem;
    text-transform: uppercase;
}

.sidebar-mobile-actions {
    padding: 10px;
    background: #f8f9fa;
    border-top: 1px solid #dee2e6;
}
.sidebar-mobile-actions input {
    font-size: 14px;
    padding: 6px;
}
.sidebar-mobile-actions .btn {
    font-size: 14px;
    padding: 8px;
}


/* === КОНЕЦ СТИЛЕЙ ДЛЯ САЙДБАРА === */



/* === НАВБАР === */

.navbar-brand {
    padding-top: .75rem;
    padding-bottom: .75rem;
    font-size: 1rem;
    background-color: rgba(0, 0, 0, .25);
    box-shadow: inset -1px 0 0 rgba(0, 0, 0, .25);
}

.navbar .navbar-toggler {
    top: .25rem;
    right: 1rem;
}

.navbar .form-control {
    padding: .75rem 1rem;
    border-width: 0;
    border-radius: 0;
}

.form-control-dark {
    color: #fff;
    background-color: rgba(255, 255, 255, .1);
    border-color: rgba(255, 255, 255, .1);
}

.form-control-dark:focus {
    border-color: transparent;
    box-shadow: 0 0 0 3px rgba(255, 255, 255, .25);
}

/* === КОНЕЦ НАВБАР === */



/* === СПИННЕР === */

.loader {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    background: rgba(255, 255, 255, 0.8);
    /*z-index: 9999; багает*/
    z-index: 3;
}

.loader--fullscreen {
    position: fixed;
}

.loader__spinner {
    border: 4px solid rgba(0, 0, 0, 0.1);
    border-left-color: #000;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.loader-container {
    position: relative;
}

.loader__text {
    position: absolute;
    top: calc(50% + 40px);
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 1.5rem;
    font-weight: bold;
    color: #000;
}

.loader__dot {
    animation: loader__blink 1.4s infinite both;
}

.loader__dot:nth-child(2) {
    animation-delay: 0.2s;
}

.loader__dot:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes loader__blink {
    0%, 80%, 100% {
        transform: translateY(0);
        opacity: 1;
    }
    40% {
        transform: translateY(-5px);
        opacity: 0.5;
    }
}

.page-loader__progress {
    height: 100%;
    width: 100%;
}

.page-loader__bar {
    height: 100%;
    width: 0%;
    background-color: #1DB954;
    transition: width 0.2s ease;
}

/* === КОНЕЦ СПИННЕР === */



/* === СПЕКТР АУДИО === */

.wave-container {
    display: flex;
    flex-direction: column;
    gap: 10px;
    align-items: center;
}

/* Основной блок (Waveform + Play + Volume) */
.wave-main {
    display: flex;
    align-items: center;
    width: 100%;
    gap: 16px;
}

.play-btn {
    width: 50px;
    min-width: 50px;
    height: 50px;
    border-radius: 50%;
    border: none;
    background-color: #1DB954;
    color: white;
    font-size: 22px;
    font-weight: bold;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.3s;
}

.play-btn:hover {
    background-color: #1ed760;
}

.play-btn > svg {
    min-width: 24px;
    min-height: 24px;
}

.waveform {
    cursor: pointer;
    flex-grow: 1;
    width: 100%;
}

.active-speed {
    background-color: #1DB954 !important;
    color: white !important;
}

.waveform-speed-controls {
    display: flex;
    margin-left: 10px;
    gap: 5px;
}

.waveform-speed-controls > button {
    border: 1px solid #1DB954;
    color: #1DB954;
    margin-bottom: 5px;
    cursor: pointer;
    border-radius: 4px;
    width: 60px;
    font-weight: bold;
    background-color: white;
}

.waveform-speed-controls > button.active-speed {
    background-color: #1DB954;
    color: white;
}

.waveform-volume-control {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 10px;
}

.waveform-volume-control .volume-button {
    background-color: transparent;
    border: none;
    cursor: pointer;
    color: #1DB954;
    font-size: 24px;
    width: 10px;
}

.volume-slider {
    transform: rotate(-90deg);
    width: 100px;
    height: 8px;
    -webkit-appearance: none;
    background-color: #e0e0e0;
    border-radius: 5px;
    cursor: pointer;
    outline: none;
    border: none;
}

/* Chrome, Safari */
.volume-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    background-color: #1DB954;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    cursor: pointer;
}

/* Firefox */
.volume-slider::-moz-range-thumb {
    background-color: #1DB954;
    border: none;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    cursor: pointer;
}

/* Нижний блок с контролами */
.wave-controls {
    display: flex;
    justify-content: space-between;
    width: 100%;
    padding: 10px 0;
}

/* Кнопка скачивания аудио */
.download-audio-btn {
    background: #1DB954;
    border: none;
    cursor: pointer;
    color: white;
    padding: 6px 12px;
    font-size: 14px;
    border-radius: 5px;
    display: flex;
    align-items: center;
    gap: 5px;
}

.download-audio-btn:hover {
    background-color: #1ed760;
}



/* === КОНЕЦ СПЕКТР АУДИО === */



/* БЛЮР МОДАЛКИ */
.modal-blurred {
    pointer-events: none; /* Чтобы нельзя было кликнуть в модалку под верхней */
    filter: blur(2px); /* Само размытие */
    opacity: 0.9; /* Чтобы был визуально мягче */
    transition: filter 0.3s ease, opacity 0.3s ease;
}




/* === СТИЛИ ДЛЯ ТАБЛИЦЫ СПИСКА ЗАПИСЕЙ === */

.page-wrapper {
    display: flex;
    flex-direction: column;
    height: calc(var(--vh, 1vh) * 100 - 131px);
}

.records-table {
    flex-grow: 1;
    overflow: auto; /* Скролл, если данных много */
    min-height: 0; /* Важный момент для flex-grow */
}

.table-footer {
    background-color: #f8f9fa;
    border-top: 1px solid #dee2e6;
}

.table-restyle > tbody > tr > td {
    padding: 10px;
}

.table-restyle > tbody > tr {
    cursor: pointer;
}

.noselect {
    -webkit-touch-callout: none;
    -webkit-user-select: none;
     -khtml-user-select: none;
       -moz-user-select: none;
        -ms-user-select: none;
            user-select: none;
}

.records-filters {
    display: flex;
    align-items: center;
    gap: 10px;
}

@media (max-width: 768px) {
    .records-filters {
        flex-direction: column;
        align-items: flex-start;
    }

    .dropdown-menu {
        width: 100vw !important;
        left: 0 !important;
        right: 0 !important;
    }

    .records-table {
        font-size: 0.7rem;
    }

    .navbar-brand {
        background-color: unset;
        box-shadow: unset;
    }

    .table-footer {
        font-size: 0.65rem;
    }
}

.dropdown-menu-filter-manager {
    min-width: 250px;
}

.btn-menu-filter-manager {
    width: 125px;
}


/* === МОДАЛКА XXL ДЛЯ ПРОСМОТРА ЗАПИСИ === */
.modal-xxl {
    width: 100%;
    height: calc(100vh - 20px) !important; /* Робимо висоту трохи меншою за 100vh */
    max-width: calc(100% - 20px); /* Відступи з боків */
    margin: 10px; /* Відступи зверху і знизу */
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-xxl .modal-dialog {
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
    max-width: 100%;
}

.modal-xxl .modal-content {
    width: 100%;
    height: 100%;
    border-radius: 10px; /* Закруглені кути для кращого вигляду */
    display: flex;
    flex-direction: column;
}

.modal-xxl .modal-body {
    flex-grow: 1;
    overflow-y: auto;
    padding: 20px; /* Додаємо внутрішній відступ */
}

.modal-xxl .modal-header,
.modal-xxl .modal-footer {
    flex-shrink: 0;
    padding: 15px;
}

/* === КОНЕЦ СТИЛЕЙ ДЛЯ ТАБЛИЦЫ СПИСКА ЗАПИСЕЙ === */



.record-info-footer {
    flex-shrink: 0;
    padding: 10px;
    background: #f8f9fa;
    border-top: 1px solid #ddd;
    text-align: right;
}


.record-info-container {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.waveplayer-container {
    flex-shrink: 0;
    padding: 10px;
    background: #f8f9fa;
    border-bottom: 1px solid #ddd;
}

.record-info-content {
    display: flex;
    flex: 1;
    overflow: hidden;
}

.record-info-sidebar {
    width: 20%;
    background: #f1f1f1;
    padding: 15px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.record-info-sidebar ul {
    list-style: none;
    padding: 0;
    width: 100%;
}

.record-info-sidebar ul li {
    width: 100%;
    margin-bottom: 10px;
}

.record-info-sidebar ul li button {
    width: 100%;
    padding: 10px;
    border: none;
    background: #e0e0e0;
    cursor: pointer;
    text-align: center;
    border-radius: 5px;
}

.record-info-sidebar ul li button:hover {
    background: #d6d6d6;
}

.record-info-main,
.record-info-comments {
    width: 50%;
    padding: 20px;
    overflow-y: auto;
}

/* Коментарі (ховаються на мобільних) */
.record-info-comments {
    background: #f9f9f9;
    border-left: 1px solid #ddd;
}

/* Адаптивність */
@media (max-width: 768px) {
    .modal-xxl {
        height: calc(var(--vh, 1vh) * 100 - 10px) !important;
        max-width: calc(100% - 10px);
        margin: 5px;
    }

    .record-info-content {
        display: flex;
        flex-direction: column;
        width: 100%;
    }

    .record-info-sidebar {
        width: 100%;
        display: flex;
        justify-content: space-around;
        padding: 10px 0;
        background: #f8f9fa;
        box-shadow: 0px 2px 5px rgba(0, 0, 0, 0.1);
        position: sticky;
        top: 0;
        z-index: 100;
    }

    .record-info-sidebar ul {
        display: flex;
        justify-content: space-around;
        width: 100%;
        padding: 0;
        margin: 0;
    }

    .record-info-sidebar ul li {
        list-style: none;
    }

    .record-info-sidebar ul li button {
        background: transparent;
        border: none;
        cursor: pointer;
        display: flex;
        flex-direction: column;
        align-items: center;
        padding: 5px;
        transition: all 0.2s ease-in-out;
    }

    .record-info-sidebar ul li button:hover {
        opacity: 0.7;
    }

    .record-info-sidebar ul li button ficons {
        width: 28px;
        height: 28px;
        color: #333;
        transition: color 0.2s;
    }


    .record-info-main,
    .record-info-comments {
        width: 100%;
        padding: 20px;
        overflow-y: auto;
    }

    /* Ховаємо блок коментарів, якщо він не активний */
    .record-info-comments {
        display: none;
    }

    /* Відображаємо коментарі, якщо вони активні */
    .record-info-comments.active {
        display: block;
    }

    /* Ховаємо основний блок, якщо активні коментарі */
    .record-info-main.hidden {
        display: none;
    }

    .waveform-speed-controls > button {
        width: 40px;
        font-size: 0.67rem;
    }

    .table-restyle {
        font-size: 0.8rem;
    }
}


/* Подсветка активной кнопки */
.record-info-sidebar ul li button.active {
    color: #007bff; /* Синий цвет */
    background-color: #c0d6c0;
}

/* === ТАЙМЛАЙН === */

.wrapper-timeline ul, li {
    list-style: none;
    padding: 0;
}

.wrapper-timeline {
    padding: 1rem;
    border-radius: 15px;
}
.wrapper-timeline h1 {
    font-size: 1.1rem;
    font-family: sans-serif;
}
.sessions-timeline {
    margin-top: 2rem;
    border-radius: 12px;
    position: relative;
}
.wrapper-timeline li {
    padding-bottom: 1.5rem;
    position: relative;
    padding-left: 20px;
    margin-left: 10px;
}
.wrapper-timeline li:last-child {
    border: 0px;
    padding-bottom: 0;
}
.wrapper-timeline li:before {
    content: '';
    width: 15px;
    height: 15px;
    border-radius: 50%;
    position: absolute;
    left: -10px;
    top: 0px;
    background: white;
}
.time-timeline {
    color: #2a2839;
    font-family: 'Poppins', sans-serif;
    font-weight: 500;
}
@media screen and (min-width: 601px) {
    .time-timeline {
        font-size: 0.9rem;
    }
}
@media screen and (max-width: 600px) {
    .time-timeline {
        margin-bottom: 0.3rem;
        font-size: 0.85rem;
    }
}
.wrapper-timeline p {
    color: #4f4f4f;
    font-family: sans-serif;
    line-height: 1.5;
    margin-top: 0.4rem;
}
@media screen and (max-width: 600px) {
    .wrapper-timeline p {
        font-size: 0.9rem;
    }
}


/* === КОНЕЦ СТИЛЕЙ ТАЙМЛАЙНА === */

.sess-timeline-violet {
    border-left: 1px solid #abaaed;
}

.sess-timeline-violet:before {
    border: 1px solid #4e5ed3;
    box-shadow: 3px 3px 0px #bab5f8;
    box-shadow: 3px 3px 0px #bab5f8;
}

.sess-timeline-red {
    border-left: 1px solid #e57373;
    background-color: #ef9a991c;
}

.sess-timeline-red:before {
    border: 1px solid #d32f2f;
    box-shadow: 3px 3px 0px #ef9a9a;
}

.sess-timeline-blue {
    border-left: 1px solid #64b5f6;
    background-color: #90caf91c;
}

.sess-timeline-blue:before {
    border: 1px solid #1976d2;
    box-shadow: 3px 3px 0px #90caf9;
}

.sess-timeline-green {
    border-left: 1px solid #81c784;
    background-color: #a5d6a91c;
}

.sess-timeline-green:before {
    border: 1px solid #388e3c;
    box-shadow: 3px 3px 0px #a5d6a7;
}

.sess-timeline-orange {
    border-left: 1px solid #ffb74d;
    box-shadow: 3px 3px 0px #ffcc891c;
}

.sess-timeline-orange:before {
    border: 1px solid #f57c00;
    box-shadow: 3px 3px 0px #ffcc80;
}

.sess-timeline-yellow {
    border-left: 1px solid #f5de10;
    background-color: #fff5991c;
}

.sess-timeline-yellow:before {
    border: 1px solid #fbc02d;
    box-shadow: 3px 3px 0px #fff59d;
}

.addtime-timeline {
    color: gray;
    font-weight: bold;
    font-size: 11px;
}

/* === КОНЕЦ СТИЛЕЙ ТАЙМЛАЙНА === */


/* === СТИЛИ ДЛЯ ИСТОРИИ ЗВОНКОВ === */

.recordinfo-history {
    display: flex;
    align-items: center;
    padding: 10px;
    border-radius: 8px;
    background: #f8f9fa;
    transition: background 0.3s, transform 0.2s;
    cursor: pointer;
    gap: 15px;
    margin-bottom: 10px;
}

.recordinfo-history-active {
    border: 1px solid #ffae00;
    background: #e1f2e1;
    box-shadow: 0 0 5px rgba(0, 0, 0, 0.1);
}

.recordinfo-history-active:hover {
    background: #ceffce !important;
}

.recordinfo-history:hover {
    background: #e2e6ea;
    transform: translateY(-2px);
}

.recordinfo-history-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 32px;
}

.recordinfo-history-icon .ficons {
    font-size: 24px;
}

.vertical-line {
    width: 2px;
    /*height: 100%;*/
    align-self: stretch;
}

.recordinfo-history-text {
    display: flex;
    flex-direction: column;
    padding-left: 10px;
}

.recordinfo-history-icon .ficons .feather {
    height: 30px;
    width: 30px;
}

.recordinfo-history-icon .ficons .feather-phone-incoming {
    color: #28a745;
}

.recordinfo-history-icon .ficons .feather-phone-outgoing {
    color: #007bff;
}

.vertical-line-incoming {
    background: #28a745;
}

.vertical-line-outgoing {
    background: #007bff;
}

.history-date-line {
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    width: 100%;
    height: 1px;
    background-color: #ddd;
    margin: 20px 0;
}

.history-date-text {
    position: absolute;
    background-color: #dddddd;
    padding: 0 10px;
    font-size: 14px;
    color: #000;
}

/* === КОНЕЦ СТИЛЕЙ ДЛЯ ИСТОРИИ ЗВОНКОВ === */


canvas {
    max-height: 350px;
    min-height: 350px;
}


@media (max-width: 1190px) {
    canvas {
        max-height: 250px;
        min-height: 250px;
    }
}

.d-contents {
    display: contents !important;
}

.sidebar-logout {
    padding: 10px;
    background: #f8f9fa; /* Фон как у сайдбара */
    border-top: 1px solid #dee2e6;
}
.sidebar-logout .btn {
    font-size: 16px;
    padding: 10px;
}
