/* static/pages/css/video_catalog.css */

.container {
    position: relative;
    top: -140px;
    margin-bottom: -140px;
    max-width: 100% !important;
    padding: 140px 10px 10px 10px;
    background: 
            linear-gradient(to bottom, rgba(22, 1, 26, 0) 0%, rgba(53, 2, 96) 100%),
            url(../images/catalog/catalog_up.jpg);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    min-height: 90vh;
    z-index: 0;
}

/* .container::after {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 260px;
    background: url(../images/catalog/catalog_down.jpg) no-repeat center;
    background-size: cover;
    z-index: 0;
} */

.main-footer {
    margin-bottom: 0px;
    background-color: rgba(53, 2, 96);
    /* background: url(../images/catalog/catalog_down.jpg) no-repeat center; */
}

.cta-button {
    background: transparent;
    color: white;
    font-weight: 600;
    font-size: 20px;
    padding: 10px 50px;
    border: none;
    border-radius: 30px;
    text-decoration: none;
    display: block;
    cursor: pointer;
    transition: box-shadow 0.3s ease;
    position: relative;
    overflow: hidden;
}

.cta-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to right, #00f, #f0f);
    z-index: -1;
}

.cta-button::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(to left, #00f, #f0f);
    transition: left 0.3s ease;
    z-index: -1;
}

.cta-button:hover::after {
    left: 0;
}

.cta-button:hover {
    box-shadow: 0 0 10px rgba(255, 255, 255, 0.5);
}

.catalog_header h1 {
    color: #ffffff;
    padding-bottom: 0px;
    margin-bottom: 15px;
    font-weight: 500;
    text-align: center;
}

.catalog_header h3 {
    color: #ffffff;
    font-size: 16px;
    padding-bottom: 30px;
    font-weight: 300;
    text-align: center;
}

.collection-empty-card {
    max-width: 1100px;
    margin: 0 auto 40px auto;
    padding: 24px 24px 28px;
    border-radius: 22px;
    position: relative;
    background: linear-gradient(216deg, rgb(255 170 131 / 2%), rgb(161 44 244 / 33%), rgba(0, 0, 0, 0.85));
    box-shadow: 10px 10px 10px rgb(34 3 42 / 25%);
}

.collection-empty-card::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background-image: url(../images/sound-check/curves-back.svg);
    background-size: 100%;
    background-position: 0 150px;
    background-repeat: no-repeat;
    opacity: 0.38;
    pointer-events: none;
    z-index: 0;
}

.collection-empty-card > * {
    position: relative;
    z-index: 1;
}

.collection-empty-header {
    text-align: center;
    margin-bottom: 18px;
}

.collection-empty-header h1 {
    margin: 0 0 8px 0;
    font-size: 28px;
    font-weight: 600;
    color: #ffffff;
}

.collection-empty-header p {
    margin: 0;
    font-size: 18px;
    opacity: 0.9;
    color: #ffffff;
}

.collection-empty-header-actions {
    margin-top: 16px;
    display: flex;
    justify-content: center;
    gap: 14px;
    flex-wrap: wrap;
    height: 50px;
    align-items: center;
    margin-bottom: 50px;
}

.collection-empty-header-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 10px 28px;
    border-radius: 999px;
    text-decoration: none;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    box-shadow: 0 10px 22px rgba(0, 0, 0, 0.22);
    line-height: 1;
}

.collection-empty-header-btn-text {
    line-height: 1;
    display: inline-block;
}

.collection-empty-header-btn i {
    font-size: 18px;
}

.collection-empty-header-icon {
    width: 28px;
    height: 28px;
    object-fit: contain;
    display: block; /* чтобы в flex не было базовой линии */
}

.collection-empty-header-btn--gradient {
    background: linear-gradient(to right, #00f, #f0f);
    color: #ffffff;
    position: absolute;
    left: -40px;
    padding: 6px 40px;
    min-width: 260px;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 0;
    text-align: center;
    line-height: 1;
}

/* Кнопка "Мои треки" должна быть неактивной на пустой коллекции */
.collection-empty-header-btn[aria-disabled="true"] {
    pointer-events: none;
    opacity: 0.9;
}

.collection-empty-header-warning {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 4px 20px;
    border-radius: 999px;
    background: gray;
    color: white;
    font-weight: 800;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    margin-right: auto;
    margin-left: 200px;
    z-index: 1;
}

.collection-empty-gallery {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.collection-empty-item {
    position: relative;
    border-radius: 18px;
    min-height: 280px;
    padding: 3px;
    background: linear-gradient(to right, #3f00ff, #ff00ff);
    overflow: hidden;
    display: flex;
    align-items: stretch;
}

.collection-empty-item-left::before,
.collection-empty-item-right::before {
    content: '';
    position: absolute;
    inset: 3px;
    border-radius: 14px;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    z-index: 0;
    pointer-events: none; /* чтобы ховер/клик шли по ссылке */
}

.collection-empty-item-left::before {
    background-image: url(../images/catalog/каталог_6.jpg);
}

.collection-empty-item-right::before {
    background-image: url(../images/catalog/каталог_7.jpg);
}

.collection-empty-item-inner {
    position: relative;
    z-index: 1;
    height: 100%;
    border-radius: 14px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 14px 10px;
    text-align: center;
    background: radial-gradient(circle at 10% 0, rgba(0,0,0,0.75) 0%, rgba(0,0,0,0.3) 45%, transparent 100%);
    width: 100%;
}

.collection-empty-item-inner-link {
    text-decoration: none;
    cursor: pointer;
    transition: transform 0.18s ease, box-shadow 0.18s ease, filter 0.18s ease, opacity 0.18s ease;
    box-shadow: 0 8px 22px rgba(0, 0, 0, 0.18);
    opacity: 1;
    height: 100%;
    width: 100%;
    flex: 1;
}

.collection-empty-item-inner-link:hover {
    box-shadow: 0 18px 48px rgba(0, 0, 0, 0.45);
    filter: brightness(1.22) saturate(1.25);
    opacity: 0.78;
}

.collection-empty-item:hover .collection-empty-item-inner-link {
    box-shadow: 0 18px 48px rgba(0, 0, 0, 0.45);
    filter: brightness(1.22) saturate(1.25);
    opacity: 0.78;
}

.collection-empty-item-inner-link .collection-empty-btn {
    pointer-events: none; /* чтобы клики шли на весь контейнер */
}

.collection-empty-item-title {
    margin: 0;
    font-size: 18px;
    font-weight: 700;
    color: #ffffff;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.collection-empty-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 150px;
    padding: 10px 24px;
    border-radius: 999px;
    font-size: 14px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    text-decoration: none;
    border: none;
    cursor: pointer;
    transition: transform 0.12s ease, box-shadow 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.collection-empty-btn--light {
    background: #ffffff;
    color: #ff0091;
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.28);
}

.collection-empty-btn--gradient {
    background: linear-gradient(135deg, #ff0091, #5b5bff);
    color: #ffffff;
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.28);
}

.collection-empty-btn:hover {
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.52);
}

.collection-empty-btn:active {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.54);
}

.container-catalog {
    position: relative;
    background: linear-gradient(180deg, rgba(255, 216, 198, 0.4), rgba(188, 94, 255, 0.4), rgba(30, 6, 56, 0.4));
    border-radius: 50px;
    padding: 50px;
    max-width: 1200px;
    margin: auto;
    box-shadow: 10px 10px 10px rgb(34 3 42 / 80%);
    margin-bottom: 50px;
}

.container-catalog::before {
    background-image: url(../images/programs/prog-back.svg);
    width: 100%;
    height: 100%;
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    border-radius: inherit;
    background-size: 100%;
    background-position: 0px 150px;
    background-repeat: no-repeat;
    opacity: 0.4;
    z-index: -4;
}

.search-container {
    position: relative;
    z-index: 1;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    width: 100%;
    gap: 30px;
    justify-content: center;
    margin: 0 auto;
}

.search-container .vote .cta-button {
    font-weight: 300;
    padding: 5px 30px;
    background-color: #412574;
}

.search-container .my-lessons .cta-button {
    font-weight: 300;
    padding: 5px 30px;
}

.form-control2 {
    display: block;
    padding: 5px 40px 5px 14px;
    border-radius: 25px;
    border: none;
    background-color: rgb(255 255 255 / 16%);
    color: #432c4d;
    font-size: 15px;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    transition: border-color .15s ease-in-out, box-shadow .15s ease-in-out;
    position: relative;
    flex: 1 1 auto;
    width: 100%; /* Изменено с 31% на 100% */
    min-width: 250px;
    font-size: 20px;
    text-align: center;
}

.form-control2::placeholder {
    color: #725d7b;
    opacity: 1; /* для Firefox */
}

.form-control2:focus {
    box-shadow: 0 0 7px rgba(239, 39, 124, 0.6);
    outline: none;
}

.input-group3 {
    position: relative;
    display: flex;
    gap: 30px;
}

.input-group3 select {
    cursor: pointer;
    width: auto;
    border-radius: 25px;
    border: none;
    background-color: #412574;
    color: #ffffff;
    font-size: 18px;
    font-weight: 300;
    padding: 7px 20px;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    transition: border-color .15s ease-in-out, box-shadow .15s ease-in-out;
}

.input-group3 select:focus {
    box-shadow: 0px 0px 7px rgba(20, 130, 250, 0.5);
    outline: none;
}

.input-group2 {
    position: relative;
    display: flex;
    flex-grow: 1; 
    min-width: 250px;
}

.input-group2 .search-clear {
    margin-left: -42px;
    padding-right: 26px;
    z-index: 2;
    background: transparent;
    border: none;
    cursor: pointer;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.input-group2:has(input:focus) .search-clear {
    opacity: 1;
    color: #ef277c;
}

.category-filter .flex-wrap {
    margin: 40px 0px;
    width: auto;
    border-radius: 25px;
    border: none;
    background-color: #412574;
    color: #ffffff;
    font-size: 18px;
    font-weight: 300;
    padding: 7px 20px;
    position: relative;
}

.category-filter .arrows {
    margin: -10px 0px;
}

.category-filter-btn {
    position: relative;
    transition: all 0.2s;
    font-size: 20px;
    padding: 3px 10px 3px 20px;
    text-decoration: none;
    color: #ffffff;
}

.category-filter-btn::before {
    content: "";
    position: absolute;
    left: 5px;
    top: 50%;
    transform: translateY(-50%);
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background-color: white;
}

.btn-selected::before {
    background-color: #ff0493;
}

.category-filter-btn:first-child::before {
    display: none;
}

.category-filter-btn:hover {
    border-bottom: 2px solid #ff0493;
    margin-bottom: -2px;
}

.catalog-row {
    --bs-gutter-x: 1.5rem;
    --bs-gutter-y: 0;
    display: flex;
    flex-wrap: wrap;
    margin-top: calc(-1 * var(--bs-gutter-y));
    margin-right: calc(-.5 * var(--bs-gutter-x));
    margin-left: calc(-.5 * var(--bs-gutter-x));
}

.catalog-item {
    flex: 0 0 auto;
    width: 33.33333333%;
    padding: 10px;
}

.cat-card {
    position: relative;
    z-index: 1;
    padding: 20px;
    background: none;
    border: 0;
    height: 100%;
}

.cat-card::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 80%;
    background: linear-gradient(130deg, rgb(175 30 150 / 92%), rgb(44 0 199 / 86%));
    z-index: -1;
    border-radius: 25px;
    box-shadow: 5px 5px 10px rgb(35 5 43 / 30%);
}

.cat-card .card-buttons {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-evenly;
    margin-top: -14px;
    z-index: 1;
    flex-wrap: wrap;
    gap: 10px;
}

.cat-card .card-buttons .cta-button {
    font-weight: 300;
    font-size: 14px;
    padding: 2px 5px;
}

.card-body {
    position: relative;
    display: flex;
	padding: 20px 0px 0px 0px;
	margin: 0;
}

.card-body .marker { 
    width: 20%;
    text-align: center;
}

.card-body .marker i { 
    text-align: center;
    font-size: 4vmin;
    color: #A99D9D;
    cursor: pointer;
    transition: all 0.4s ease;
    position: relative;
    display: inline-block;
}

.card-body .marker i:hover {
    transform: scale(1.05);
    transition: all 0.2s ease;
    color: #ff0493;
    text-shadow: 0 0 10px rgba(255, 4, 147, 0.6);
}

/* Анимация наполнения при лайке */
@keyframes heartFill {
    0% {
        transform: scale(1);
        color: #A99D9D;
    }
    50% {
        transform: scale(1.2);
        color: #ff6b6b;
    }
    100% {
        transform: scale(1.1);
        color: #e74c3c;
    }
}

/* Анимация снятия лайка */
@keyframes heartEmpty {
    0% {
        transform: scale(1.1);
        color: #e74c3c;
    }
    50% {
        transform: scale(0.8);
        color: #ff6b6b;
    }
    100% {
        transform: scale(1);
        color: #A99D9D;
    }
}

.card-body .marker i.liked {
    color: #e74c3c;
    transform: scale(1.1);
    text-shadow: 0 0 10px rgba(231, 76, 60, 0.5);
    animation: heartFill 0.6s ease-out;
}

.card-body .marker i.unliked {
    animation: heartEmpty 0.4s ease-out;
}

.card-body .card-title { 
    position: relative;
    width: 80%;
}

.card-body .card-title p {
    color: #fff;
    font-size: 20px;
    font-weight: 300;
    line-height: normal;
    text-align: right;
    margin: 0;
    padding: 0;
}

.cat-card .thumb {
    position: relative;
    display: block;
    overflow: hidden;
}

.cat-card .thumb img {
    display: block;
    border-radius: 5px;
    transition: padding 0.3s ease;
}

.cat-card .thumb.completed img {
    filter: grayscale(100%);
    opacity: 0.97;
}

.cat-card .thumb .completed-badge {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #FF0493;
    font-size: 64px;
    font-weight: 600;
    text-shadow: 0 0 10px rgba(180, 0, 168, 0.01), 0 0 20px rgba(180, 0, 168, 0.95);
    z-index: 10;
    pointer-events: none;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.cat-card .thumb .completed-badge i {
    background: linear-gradient(130deg, rgb(175 30 150 / 10%), rgb(44 0 199 / 96%));
    border-radius: 50%;
    background-size: 90%;
}

.cat-card .thumb::before {
    content: 'Смотреть превью трека';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    padding: 10px;
    margin: 5px 10%;
    border-radius: 0px 0px 20px 20px;
    background: rgb(46 0 73 / 70%);
    color: white;
    text-align: center;
    font-size: 16px;
    opacity: 0;
    transform: translateY(-100%);
    transition: all 0.3s ease;
    z-index: 1;
}

.cat-card .thumb::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(130deg, rgb(255 0 211), rgb(0 51 255));
    background-clip: border-box;
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: -1;
    border-radius: 5px;
}

.cat-card .thumb:hover::before {
    opacity: 1;
    transform: translateY(0);
}

.cat-card .thumb:hover::after {
    opacity: 1;
}

.cat-card .thumb:hover img {
    padding: 5px;
}




/* Адаптивные стили для каталога */
@media (max-width: 992px) {
    .container-catalog { max-width: 790px; padding: 20px; }
    .catalog-item { flex: 0 0 50%; max-width: 50%; }

}

@media (max-width: 768px) {
    .catalog-item { padding: 5px; }
    .cat-card { padding: 10px; }
    .category-filter-btn { font-size: 16px; }
    .search-container .vote .cta-button, .form-control2, .input-group3 select, .card-body .card-title p { font-size: 16px; }
    .cat-card .card-buttons .cta-button { font-size: 12px; }
    .input-group2 { order: 1; width: 100%; }
    .input-group3 { order: 2; }
    .vote { order: 3; }
}

@media (max-width: 532px) {
    .container-catalog { max-width: 410px; min-width: 290px;}
    .catalog-item { flex: 0 0 100%; max-width: 100%; }
    .search-container, .input-group3 { gap: 10px; }
    .category-filter .flex-wrap { margin: 35px 0px 20px 0px; height: 44px; overflow: hidden; transition: max-height 0.9s ease; will-change: height;}
    .category-filter .flex-wrap::before { 
        content: 'Категории треков';
        position: absolute;
        top: 0;
        left: 0;
        height: 100%;
        width: 100%;
        border-radius: inherit;
        background: #412574;
        color: white;
        text-align: center;
        font-size: 16px;
        line-height: 2.7;
        opacity: 1;
        z-index: 1;
        transition: all 0.3s ease;
    }
    .category-filter .flex-wrap:hover::before {
        opacity: 0;
        pointer-events: none;
    }
    .category-filter .flex-wrap:hover {
        overflow: visible;
        height: auto;
        max-height: 500px;
    }
}

/* Стили для круглой кнопки утверждения */
.approve-btn-round {
    position: absolute;
    bottom: 5px;
    left: 50%;
    transform: translateX(-50%);
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: linear-gradient(135deg, #11802b, #1d4f02);
    border: none;
    color: white;
    font-size: 14px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(40, 167, 69, 0.3);
    z-index: 10;
}

.approve-btn-round:hover {
    transform: translateX(-50%) scale(1.1);
    box-shadow: 0 4px 12px rgba(40, 167, 69, 0.5);
    background: linear-gradient(135deg, #218838, #1ea085);
}

.approve-btn-round:active {
    transform: translateX(-50%) scale(0.95);
}

.approve-btn-round:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: translateX(-50%) scale(1);
}

.approve-btn-round i {
    font-size: 12px;
    line-height: 1;
}

/* Позиционирование кнопки относительно лайка */
.card-body .marker {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.card-body .marker i.like-btn {
    margin-bottom: 0;
}