/* Export Academy — Курсы: стили */

.courses-hero {
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
    padding: 4rem 0;
    text-align: center;
}
.courses-hero h1 {
    font-size: clamp(2rem, 5vw, 3rem);
    font-weight: 800;
    color: #1f2937;
    margin-bottom: 1rem;
}
.courses-hero p {
    font-size: 1.15rem;
    color: #4b5563;
    max-width: 720px;
    margin: 0 auto;
}

.courses-section { padding: 4rem 0; background: #fff; }

.courses-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 1.5rem;
}
.loading { text-align: center; color: #6b7280; padding: 3rem; }

.course-card {
    background: #fff;
    border: 2px solid #e5e7eb;
    border-radius: 1rem;
    padding: 1.75rem;
    display: flex;
    flex-direction: column;
    transition: all .25s;
    text-decoration: none;
    color: inherit;
}
.course-card:hover {
    border-color: #f59e0b;
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0,0,0,.1);
}
.course-card .course-icon { font-size: 2.5rem; margin-bottom: .75rem; }
.course-card h3 { font-size: 1.2rem; font-weight: 700; color: #1f2937; margin-bottom: .5rem; }
.course-card p { color: #6b7280; font-size: .95rem; flex: 1; margin-bottom: 1rem; }
.course-card .course-price {
    font-size: 1.3rem; font-weight: 800; color: #f59e0b;
}
.course-card .course-cta {
    display: inline-block; margin-top: .5rem;
    color: #92400e; font-weight: 600;
}

/* ---- Плеер ---- */
.player-layout { padding: 2.5rem 0 4rem; background: #f9fafb; min-height: 70vh; }

.player-top {
    display: grid;
    grid-template-columns: 1.6fr 1fr;
    gap: 2rem;
    align-items: start;
}
@media (max-width: 900px) { .player-top { grid-template-columns: 1fr; } }

.video-frame {
    position: relative;
    background: #000;
    border-radius: 1rem;
    overflow: hidden;
    aspect-ratio: 16/9;
}
.video-frame video { width: 100%; height: 100%; display: block; }

/* Персональный водяной знак поверх видео */
.watermark {
    position: absolute;
    pointer-events: none;
    color: rgba(255,255,255,.65);
    font-size: 13px;
    font-weight: 600;
    letter-spacing: .5px;
    text-shadow: 0 1px 3px rgba(0,0,0,.8);
    padding: 2px 6px;
    border-radius: 4px;
    background: rgba(0,0,0,.25);
    white-space: nowrap;
    z-index: 5;
}
.watermark.corner { top: 12px; right: 12px; }
.watermark.moving { bottom: 12px; left: 12px; animation: wmMove 20s linear infinite; }

@keyframes wmMove {
    0%   { transform: translate(0,0); }
    25%  { transform: translate(calc(min(60vw,300px) - 0px), 0); }
    50%  { transform: translate(calc(min(60vw,300px) - 0px), -40px); }
    75%  { transform: translate(0, -40px); }
    100% { transform: translate(0,0); }
}

/* Правый сайдбар: уроки */
.lesson-panel {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 1rem;
    padding: 1.25rem;
}
.lesson-panel h3 { font-size: 1.1rem; font-weight: 700; margin-bottom: .75rem; }
.lesson-list { list-style: none; padding: 0; margin: 0; }
.lesson-item {
    display: flex; align-items: center; gap: .75rem;
    padding: .7rem .6rem;
    border-radius: .5rem;
    cursor: pointer;
    border: 1px solid transparent;
    transition: all .15s;
}
.lesson-item:hover { background: #f9fafb; }
.lesson-item.active { background: #fef3c7; border-color: #fde68a; }
.lesson-item.locked { opacity: .6; }
.lesson-index {
    width: 28px; height: 28px; flex-shrink: 0;
    border-radius: 50%; background: #e5e7eb;
    display: flex; align-items: center; justify-content: center;
    font-size: .8rem; font-weight: 700; color: #374151;
}
.lesson-item.active .lesson-index { background: #f59e0b; color: #fff; }
.lesson-title { flex: 1; font-size: .95rem; color: #1f2937; }
.lesson-lock { font-size: 1rem; }

/* Курс описание + кнопка доступа */
.course-meta {
    margin-top: 1.25rem; padding-top: 1rem; border-top: 1px solid #e5e7eb;
}
.course-desc { color: #4b5563; font-size: .95rem; margin-bottom: 1rem; }
.unlock-box {
    background: #fef3c7; border: 1px solid #fde68a; border-radius: .75rem;
    padding: 1rem; text-align: center;
}
.unlock-box .price { font-size: 1.4rem; font-weight: 800; color: #d97706; }
.unlock-box button { margin-top: .75rem; width: 100%; }

/* ---- Модалка ---- */
.modal {
    position: fixed; inset: 0;
    background: rgba(0,0,0,.55);
    display: flex; align-items: center; justify-content: center;
    z-index: 1000; padding: 1rem;
}
.modal-box {
    background: #fff; border-radius: 1rem; padding: 2rem;
    max-width: 440px; width: 100%; position: relative;
}
.modal-close {
    position: absolute; top: .5rem; right: 1rem;
    background: none; border: none; font-size: 2rem; cursor: pointer; color: #6b7280;
}
.modal-box h2 { margin-bottom: .5rem; }
.pay-price { color: #374151; margin: .5rem 0 1rem; }
.modal-box label { display: block; font-size: .9rem; color: #374151; margin-bottom: .4rem; }
.modal-box input {
    width: 100%; padding: .8rem 1rem; border: 2px solid #e5e7eb;
    border-radius: .6rem; font-size: 1rem; margin-bottom: 1rem;
}
.modal-box input:focus { outline: none; border-color: #f59e0b; }
.pay-result { margin-top: 1rem; padding: 1rem; border-radius: .6rem; }
.pay-result a { color: #fff; text-decoration: underline; font-weight: 700; }
.pay-result.success { background: #dcfce7; color: #166534; }
.pay-result.error { background: #fee2e2; color: #991b1b; }
.pay-result.pending { background: #fef9c3; color: #854d0e; }
