/* Стили для страницы деталей курса */

/* Сетка наследуется из index.css через .main */
/* Дополнительные стили для фона */
.course-detail-page {
    max-width: 900px;
    margin: 30px auto;
    padding: 30px;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 6px 24px rgba(0, 0, 0, 0.06);
    border: 1px solid #e0e0e0;
    position: relative;
    width: 100%;
    box-sizing: border-box;
}

/* Hero изображение */
.course-hero {
    width: 100%;
    margin-bottom: 30px;
}

.hero-image {
    width: 100%;
    height: 320px;
    object-fit: cover;
    border-radius: 10px;
}

/* Заголовок секции */
.section-title {
    font-size: var(--fs-h2); /* 28px */
    font-weight: bold;
    font-family: var(--font-family-bold);
    margin-bottom: 25px;
    color: #000;
    line-height: var(--lh-tight);
    letter-spacing: -0.01em;
}

/* Заголовок курса */
.course-header {
    margin-bottom: 35px;
    padding: 15px 0 25px 0;
    border-bottom: 1px dashed #d0d0d0;
    display: flex;
    justify-content: center;
    align-items: center;
}

.course-title {
    font-size: var(--fs-h1); /* 36px */
    font-weight: bold;
    font-family: var(--font-family-bold);
    margin-top: 0;
    margin-bottom: 0;
    color: #000;
    line-height: var(--lh-tight);
    letter-spacing: -0.01em;
    text-align: center;
}

/* Блок выбора тарифа */
.tariff-selection {
    margin-bottom: 35px;
}

.tariff-cards {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.tariff-card {
    background: #f9f9f9;
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    padding: 24px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.tariff-card:hover {
    border-color: #000;
}

.tariff-card.active {
    border-color: #000;
    background: #fff;
}

.tariff-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 18px;
}

.tariff-name {
    font-size: var(--fs-h3); /* 22px */
    font-weight: bold;
    font-family: var(--font-family-bold);
    color: #000;
    line-height: var(--lh-tight);
    letter-spacing: -0.01em;
}

.tariff-badge {
    background: #000;
    color: #fff;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: var(--fs-meta); /* 14px */
    font-family: var(--font-family);
    position: relative;
}

.tariff-card[data-tariff="premium"] .tariff-badge {
    background: linear-gradient(135deg, rgb(255 120 120) 0%, rgb(244 128 54) 100%);
    color: #fff;
}

.tariff-features {
    list-style: none;
    padding: 0;
    margin: 0;
}

.tariff-features li {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: var(--fs-desc); /* 15px */
    line-height: var(--lh-base);
    color: #333;
    font-family: var(--font-family);
    margin-bottom: 6px;
}

.tariff-features .feature-icon {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
}

/* Блок выбора периода оплаты */
.billing-period-selection {
    margin-bottom: 30px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.period-toggle {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    width: 100%;
}

.period-option-wrapper {
    position: relative;
}

.period-option-wrapper .yearly-badge {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
}

.period-option {
    background: #f5f5f5;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    padding: 16px 32px;
    font-size: var(--fs-body); /* 16px */
    font-family: var(--font-family);
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    width: 100%;
    box-sizing: border-box;
    height: 100%;
    color: #000;
}

.period-option:hover {
    border-color: #000;
    background: #fff;
}

.period-option.active {
    background: #000;
    color: #fff;
    border: 2px solid #000;
    padding: 16px 32px;
}

.period-option-title {
    font-size: var(--fs-body); /* 16px */
    font-weight: var(--fw-normal);
}

.period-option-subtitle {
    font-size: 0.75rem; /* 12px */
    color: #666;
    font-weight: normal;
}

.period-option.active .period-option-subtitle {
    color: #ccc;
}

/* Селектор месяца */
.month-selector {
    margin-bottom: 30px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.month-selector-title {
    font-size: var(--fs-h2); /* 28px */
    font-weight: bold;
    font-family: var(--font-family-bold);
    margin-bottom: 25px;
    color: #000;
    line-height: var(--lh-tight);
    letter-spacing: -0.01em;
}

/* Сетка кнопок месяцев */
.month-buttons-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(calc((100% - 36px) / 4), 1fr));
    gap: 12px;
    width: 100%;
    max-width: 100%;
}


.month-btn {
    background: #f5f5f5;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    padding: 12px 24px;
    font-size: var(--fs-desc); /* 15px */
    font-family: var(--font-family);
    cursor: pointer;
    transition: all 0.3s ease;
    color: #000;
    width: 100%;
    text-align: center;
    box-sizing: border-box;
}

.month-btn:hover {
    border-color: #000;
    background: #fff;
}

.month-btn.active {
    background: #000;
    color: #fff;
    border-color: #000;
}

/* Годовой селектор */
.yearly-selector {
    margin-bottom: 30px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.yearly-badge {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: rgb(255, 92, 92);
    color: #fff;
    padding: 4px 12px;
    font-size: 0.75rem; /* 12px */
    font-weight: bold;
    font-family: var(--font-family-medium);
    white-space: nowrap;
    z-index: 10;
    border-radius: 6px;
}

.yearly-btn {
    background: #000;
    color: #fff;
    border: 2px solid #000;
    border-radius: 10px;
    padding: 12px 32px;
    font-size: var(--fs-body); /* 16px */
    font-family: var(--font-family);
    cursor: pointer;
    transition: all 0.3s ease;
    margin: 0 auto;
    position: relative;
}

.yearly-btn:hover {
    background: #333;
}

.yearly-btn.active {
    background: #000;
    color: #fff;
    width: 100%;
}

/* Блок информации о курсе (использует структуру block__bottom из раздела курсов) */
.course-info-section {
    margin-bottom: 30px;
}

/* Стили block__bottom уже определены в goods_courses.css */
/* .block__bottom использует те же стили, что и в разделе курсов */

/* Отображение цены */
.price-display {
    margin-top: 30px;
    padding-top: 30px;
    border-top: 1px dashed #d0d0d0;
    display: flex;
    justify-content: center;
}

.price-container {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 8px;
    position: relative;
    width: 100%;
}

.price-main-wrapper {
    display: flex;
    align-items: baseline;
    gap: 10px;
    justify-content: center;
}

.price-label {
    font-size: 0.75rem; /* 12px */
    font-family: var(--font-family-medium);
    color: #666;
    font-weight: 400;
}

.price-value {
    font-size: 2rem; /* 32px */
    font-weight: bold;
    font-family: var(--font-family-bold);
    color: #000;
}

.old-price {
    text-decoration: line-through;
    font-size: var(--fs-body); /* 16px */
    font-weight: normal;
    color: #666;
    font-family: var(--font-family-bold);
}

.price-period {
    font-size: var(--fs-body); /* 16px */
    font-weight: normal;
    color: #666;
}

/* Секция покупки */
.purchase-section {
    text-align: center;
}

.purchase-btn {
    background: rgb(255, 176, 92);
    color: #fff;
    border: none;
    border-radius: 10px;
    padding: 14px 48px;
    font-size: var(--fs-category); /* 18px */
    font-weight: bold;
    font-family: var(--font-family-medium);
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.purchase-btn:hover {
    background: rgb(255, 195, 130);
}

.purchase-btn:active {
    background: rgb(255, 176, 92);
}

.purchase-btn:disabled {
    background: #ccc;
    color: #999;
    cursor: not-allowed;
    opacity: 0.5;
    box-shadow: none;
}

.purchase-btn:disabled:hover {
    background: #ccc;
}

/* Стили для кнопки "Убрать из корзины" */
.purchase-btn.remove-from-cart-btn {
    background: #e0e0e0;
    color: #666;
    border: none;
    border-radius: 10px;
    padding: 14px 48px;
    font-size: var(--fs-category); /* 18px */
    font-weight: bold;
    font-family: var(--font-family-medium);
    cursor: pointer;
    transition: background-color 0.3s ease, color 0.3s ease;
}

.purchase-btn.remove-from-cart-btn:hover {
    background: #d0d0d0;
    color: #555;
}

/* Стили для кнопки "Подробнее" */
.course-btn.details-btn {
    display: inline-block;
    background: #000;
    color: #fff;
    border: none;
    border-radius: 10px;
    font-size: var(--fs-body); /* 16px */
    font-family: var(--font-family);
    padding: 13px 38px;
    text-decoration: none;
    margin-top: 10px;
    transition: background-color 0.2s ease;
    white-space: nowrap;
    text-align: center;
}

.course-btn.details-btn:hover {
    background: #333;
    opacity: 0.8;
}

/* Медиа-запросы для адаптивности */

/* Планшеты */
@media screen and (max-width: 768px) {
    .course-detail-page {
        margin: 20px auto;
        padding: 20px;
        border-radius: 14px;
    }
    
    .hero-image {
        height: 200px;
        border-radius: 8px;
    }
    
    .course-header {
        margin-bottom: 25px;
        padding: 12px 0 20px 0;
        border-bottom: 1px dashed #d0d0d0;
        flex-direction: row;
        gap: 20px;
    }
    
    .course-image {
        width: 150px;
        height: 150px;
    }
    
    .course-title {
        font-size: 1.75rem; /* 28px */
        margin-top: 0;
        margin-bottom: 12px;
    }
    
    .course-description {
        font-size: 0.9375rem; /* 15px */
    }
    
    .section-title {
        font-size: 1.375rem; /* 22px */
        margin-bottom: 20px;
    }
    
    .tariff-selection {
        margin-bottom: 25px;
    }
    
    .tariff-cards {
        gap: 10px;
    }
    
    .tariff-card {
        padding: 18px;
    }
    
    .tariff-header {
        margin-bottom: 15px;
    }
    
    .tariff-name {
        font-size: 1.125rem; /* 18px */
    }
    
    .tariff-features li {
        font-size: 0.875rem; /* 14px */
        gap: 6px;
        margin-bottom: 5px;
    }
    
    .tariff-features .feature-icon {
        width: 16px;
        height: 16px;
    }
    
    .billing-period-selection {
        margin-bottom: 25px;
        display: flex;
        flex-direction: column;
        align-items: center;
    }
    
    .period-toggle {
        gap: 10px;
        justify-content: center;
    }
    
    .period-option {
        padding: 10px 20px;
        font-size: 0.9375rem; /* 15px */
        border-radius: 8px;
    }
    
    .month-selector,
    .yearly-selector {
        margin-bottom: 25px;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
    }
    
    .month-selector-title {
        font-size: 1rem; /* 16px */
        margin-bottom: 12px;
    }
    
    .month-buttons-grid {
        gap: 8px;
    }
    
    .month-btn {
        padding: 10px 18px;
        font-size: 0.875rem; /* 14px */
        width: 100%;
    }
    
    .yearly-btn {
        padding: 10px 20px;
        font-size: 0.9375rem; /* 15px */
    }
    
    .yearly-badge,
    .period-option-wrapper .yearly-badge {
        font-size: 0.6875rem; /* 11px */
        padding: 3px 10px;
        top: -10px;
    }
    
    .course-info-section {
        margin-bottom: 20px;
    }
    
    .course-info-section .block__bottom {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }
    
    .price-display {
        margin-top: 25px;
        padding-top: 25px;
        border-top: 1px dashed #d0d0d0;
        display: flex;
        justify-content: center;
    }
    
    .price-main-wrapper {
        gap: 8px;
    }
    
    .price-container {
        flex-direction: column;
        align-items: center;
        gap: 8px;
    }
    
    .price-label {
        font-size: 0.7rem; /* ~11px */
    }
    
    .price-value {
        font-size: 1.75rem; /* 28px */
    }
    
    .old-price {
        font-size: 0.9375rem; /* 15px */
        font-weight: normal;
        color: #666;
    }
    
    .price-period {
        font-size: 0.9375rem; /* 15px */
    }
    
    .purchase-btn {
        padding: 12px 32px;
        font-size: 1rem; /* 16px */
        border-radius: 8px;
    }
    
    .purchase-btn.remove-from-cart-btn {
        padding: 12px 32px;
        font-size: 1rem; /* 16px */
        border-radius: 8px;
        font-weight: bold;
        font-family: var(--font-family-medium);
    }
    
    .course-btn.details-btn {
        font-size: 0.875rem; /* 14px */
        padding: 10px 24px;
        border-radius: 8px;
    }
}

/* Мобильные устройства */
@media screen and (max-width: 576px) {
    .course-detail-page {
        margin: 15px auto;
        padding: 15px;
        border-radius: 12px;
    }
    
    .hero-image {
        height: 180px;
        border-radius: 8px;
    }
    
    .course-header {
        margin-bottom: 20px;
        padding: 10px 0 15px 0;
        border-bottom: 1px dashed #d0d0d0;
    }
    
    .course-title {
        font-size: 1.5rem; /* 24px */
        margin-top: 0;
        margin-bottom: 0;
    }
    
    .section-title {
        font-size: 1.125rem; /* 18px */
        margin-bottom: 15px;
    }
    
    .tariff-cards {
        gap: 10px;
    }
    
    .tariff-card {
        padding: 15px;
        border-radius: 10px;
    }
    
    .tariff-header {
        margin-bottom: 12px;
    }
    
    .tariff-name {
        font-size: 1rem; /* 16px */
    }
    
    .tariff-badge {
        padding: 3px 8px;
        font-size: 0.875rem; /* 14px */
    }
    
    .tariff-features li {
        font-size: 0.875rem; /* 14px */
    }
    
    .tariff-features .feature-icon {
        width: 14px;
        height: 14px;
    }
    
    .period-toggle {
        gap: 10px;
        justify-content: center;
    }
    
    .period-option {
        padding: 8px 16px;
        font-size: 0.875rem; /* 14px */
    }
    
    .month-selector-title {
        font-size: 1.125rem; /* 18px */
        margin-bottom: 15px;
    }
    
    .month-buttons-grid {
        gap: 6px;
    }
    
    .month-btn {
        padding: 8px 16px;
        font-size: 0.875rem; /* 14px */
        border-radius: 8px;
        width: 100%;
    }
    
    .yearly-btn {
        padding: 8px 18px;
        font-size: 0.875rem; /* 14px */
    }
    
    .yearly-badge,
    .period-option-wrapper .yearly-badge {
        font-size: 0.625rem; /* 10px */
        padding: 2px 8px;
        top: -8px;
    }
    
    .price-display {
        margin-top: 20px;
        padding-top: 20px;
        border-top: 1px dashed #d0d0d0;
    }
    
    .price-main-wrapper {
        gap: 6px;
    }
    
    .price-container {
        gap: 6px;
    }
    
    .price-label {
        font-size: 0.6875rem; /* 11px */
    }
    
    .price-value {
        font-size: 1.5rem; /* 24px */
    }
    
    .old-price {
        font-size: 0.875rem; /* 14px */
        font-weight: normal;
        color: #666;
    }
    
    .price-period {
        font-size: 0.875rem; /* 14px */
    }
    
    .purchase-btn {
        padding: 10px 28px;
        font-size: 0.9375rem; /* 15px */
        border-radius: 8px;
    }
    
    .purchase-btn.remove-from-cart-btn {
        padding: 10px 28px;
        font-size: 0.9375rem; /* 15px */
        border-radius: 8px;
        font-weight: bold;
        font-family: var(--font-family-medium);
    }
    
    .course-btn.details-btn {
        font-size: 0.875rem; /* 14px */
        padding: 9px 20px;
    }
}

/* Маленькие мобильные устройства */
@media (max-width: 480px) {
    .course-detail-page {
        max-width: calc(100% - 10px);
        margin: 15px auto;
        padding: 8px;
        border-radius: 8px;
        box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);
    }
    
    .hero-image {
        height: 100px;
        border-radius: 6px;
    }
    
    .course-header {
        margin-bottom: 10px;
        padding: 4px 0 8px 0;
        border-bottom: 1px dashed #d0d0d0;
    }
    
    .course-title {
        font-size: 0.8125rem; /* 13px */
        margin-top: 0;
        margin-bottom: 0;
        letter-spacing: -0.01em;
    }
    
    .section-title {
        font-size: 0.6875rem; /* 11px */
        margin-bottom: 8px;
        letter-spacing: -0.01em;
    }
    
    .tariff-selection {
        margin-bottom: 12px;
    }
    
    .tariff-cards {
        gap: 4px;
    }
    
    .tariff-card {
        padding: 8px;
        border-radius: 6px;
        border-width: 1px;
        position: relative;
    }
    
    .tariff-header {
        flex-direction: row;
        justify-content: space-between;
        align-items: flex-start;
        margin-bottom: 6px;
    }
    
    .tariff-name {
        font-size: 0.625rem; /* 10px */
        letter-spacing: -0.01em;
    }
    
    .tariff-badge {
        padding: 2px 5px;
        border-radius: 3px;
        font-size: 0.4rem; /* 8px */
        position: absolute;
        top: 4px;
        right: 4px;
    }
    
    .tariff-features li {
        font-size: 0.4rem; /* 9px */
        gap: 3px;
        margin-bottom: 2px;
    }
    
    .tariff-features .feature-icon {
        width: 8px;
        height: 8px;
    }
    
    .billing-period-selection {
        margin-bottom: 12px;
    }
    
    .period-toggle {
        gap: 4px;
    }
    
    .period-option {
        padding: 6px 10px;
        font-size: 0.5625rem; /* 9px */
        border-radius: 6px;
        border-width: 1px;
        gap: 2px;
        color: #000;
    }
    
    .period-option.active {
        padding: 6px 10px;
        color: #fff;
    }
    
    .period-option-title {
        font-size: 0.5625rem; /* 9px */
        color: inherit;
    }
    
    .period-option-subtitle {
        font-size: 0.4rem; /* 7px */
    }
    
    .period-option-wrapper .yearly-badge {
        top: -5px;
    }
    
    .month-selector {
        margin-bottom: 12px;
    }
    
    .month-selector-title {
        font-size: 0.6875rem; /* 11px */
        margin-bottom: 8px;
    }
    
    .month-buttons-grid {
        gap: 4px;
    }
    
    .month-btn {
        padding: 5px 10px;
        font-size: 0.5rem; /* 8px */
        border-radius: 6px;
        border-width: 1px;
        width: 100%;
    }
    
    .yearly-selector {
        margin-bottom: 12px;
    }
    
    .yearly-btn {
        padding: 6px 12px;
        font-size: 0.5625rem; /* 9px */
        border-radius: 6px;
        border-width: 1px;
    }
    
    .yearly-badge,
    .period-option-wrapper .yearly-badge {
        font-size: 0.3rem; /* 7px */
        padding: 2px 5px;
        border-radius: 3px;
        top: -5px;
    }
    
    .price-display {
        margin-top: 12px;
        padding-top: 12px;
    }
    
    .price-container {
        gap: 3px;
    }
    
    .price-main-wrapper {
        gap: 3px;
    }
    
    .price-value {
        font-size: 0.875rem; /* 14px */
    }
    
    .price-label {
        font-size: 0.4375rem; /* 7px */
    }
    
    .old-price {
        font-size: 0.5rem; /* 8px */
    }
    
    .price-period {
        font-size: 0.5625rem; /* 9px */
    }
    
    .purchase-btn {
        padding: 8px 16px;
        font-size: 0.5625rem; /* 9px */
        border-radius: 6px;
        width: 100%;
        max-width: 100%;
    }
    
    .purchase-btn.remove-from-cart-btn {
        padding: 8px 16px;
        font-size: 0.5625rem; /* 9px */
        border-radius: 6px;
        width: 100%;
        max-width: 100%;
        font-weight: bold;
        font-family: var(--font-family-medium);
    }
    
    .course-btn.details-btn {
        font-size: 0.5rem; /* 8px */
        padding: 6px 14px;
        border-radius: 6px;
        margin-top: 4px;
    }
    
    .course-info-section {
        margin-bottom: 20px;
    }
    
    .course-info-section .block__bottom {
        grid-template-columns: repeat(4, 1fr);
        gap: 8px;
    }
}

/* Модальное окно для просмотра изображений */
.image-modal {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(8px);
    animation: fadeIn 0.3s ease;
    overflow: hidden;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.image-modal-content {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100vw;
    height: 100vh;
    padding: 10vh 10vw;
    box-sizing: border-box;
}

.modal-image {
    max-width: 90vw;
    max-height: 90vh;
    width: auto;
    height: auto;
    object-fit: contain;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    animation: zoomIn 0.3s ease;
    will-change: transform, opacity;
    transition: opacity 0.1s ease-out;
}

@keyframes zoomIn {
    from {
        transform: scale(0.8);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

/* Контейнер для кнопок модального окна */
.image-modal-buttons {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 15px;
}

.image-modal-close {
    position: relative;
    color: #fff;
    font-size: 0;
    font-family: var(--font-family-medium);
    font-weight: 500;
    cursor: pointer;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(0,0,0,0.7), rgba(0,0,0,0.6));
    border: none;
    border-radius: 22px;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 6px 20px rgba(0,0,0,0.3);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255,255,255,0.2);
    user-select: none;
    text-shadow: none;
    line-height: 1;
    padding: 0;
    margin: 0;
    overflow: hidden;
    text-indent: -9999px;
}

.image-modal-close::before {
    content: '×';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    display: block;
    width: 20px;
    height: 20px;
    line-height: 20px;
    text-align: center;
    font-size: 20px;
    text-indent: 0;
}

.image-modal-close:hover {
    background: linear-gradient(135deg, rgba(0,0,0,0.8), rgba(0,0,0,0.7));
    transform: scale(1.05);
    border-color: rgba(255,255,255,0.3);
    box-shadow: 0 8px 25px rgba(0,0,0,0.4);
    color: #fff;
}

.image-modal-close:active {
    transform: scale(0.98);
}

/* Кнопка скачивания расписания */
.image-modal-download {
    position: relative;
    color: #fff;
    font-size: 22px;
    font-family: var(--font-family-medium);
    font-weight: 500;
    cursor: pointer;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(0,0,0,0.7), rgba(0,0,0,0.6));
    border: none;
    border-radius: 22px;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 6px 20px rgba(0,0,0,0.3);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255,255,255,0.2);
    user-select: none;
    text-shadow: none;
    padding: 0;
    margin: 0;
    line-height: 1;
}

.image-modal-download svg {
    width: 20px;
    height: 20px;
    stroke: currentColor;
}

.image-modal-download:hover {
    background: linear-gradient(135deg, rgba(0,0,0,0.8), rgba(0,0,0,0.7));
    transform: scale(1.05);
    border-color: rgba(255,255,255,0.3);
    box-shadow: 0 8px 25px rgba(0,0,0,0.4);
    color: #fff;
}

.image-modal-download:active {
    transform: scale(0.98);
}

/* Медиа-запросы для модального окна */
@media (max-width: 768px) {
    .image-modal-buttons {
        top: 15px;
        right: 15px;
        gap: 5px;
    }
    
    .image-modal-close {
        width: 40px;
        height: 40px;
        font-size: 30px;
        border-radius: 20px;
        line-height: 1;
        padding: 0;
        margin: 0;
    }
    
    .image-modal-close::before {
        width: 18px;
        height: 18px;
        line-height: 18px;
        font-size: 18px;
        position: absolute;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        text-indent: 0;
    }
    
    .image-modal-download {
        width: 40px;
        height: 40px;
        border-radius: 20px;
        line-height: 1;
        padding: 0;
        margin: 0;
    }
    
    .image-modal-download svg {
        width: 18px;
        height: 18px;
    }
    
    .course-info-section .block__bottom {
        grid-template-columns: repeat(4, 1fr);
        gap: 8px;
    }
}

@media (max-width: 480px) {
    .image-modal-buttons {
        top: 10px;
        right: 10px;
        gap: 5px;
    }
    
    .image-modal-close {
        width: 35px;
        height: 35px;
        font-size: 25px;
        border-radius: 17.5px;
        line-height: 1;
        padding: 0;
        margin: 0;
    }
    
    .image-modal-close::before {
        width: 18px;
        height: 18px;
        line-height: 18px;
        font-size: 18px;
        position: absolute;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        text-indent: 0;
    }
    
    .image-modal-download {
        width: 35px;
        height: 35px;
        border-radius: 17.5px;
        line-height: 1;
        padding: 0;
        margin: 0;
    }
    
    .image-modal-download svg {
        width: 18px;
        height: 18px;
    }
}

