/* ============================================================
   learning_materials.css
   Стили для страницы Обучающие материалы (p_learning_materials.php)
   Brand palette — matches index.php / style.css
   ============================================================ */

/* ── CSS variables ───────────────────────────────────────── */
:root {
    --lm-brand:   rgb(13, 82, 105);       /* dark teal */
    --lm-accent:  rgb(35, 134, 167);      /* mid teal  */
    --lm-dark:    rgb(4, 48, 63);         /* deep teal */
    --lm-border:  rgba(13, 82, 105, 0.18);
    --lm-shadow:  0 10px 24px rgba(0,0,0,0.06), 0 1px 0 rgba(255,255,255,0.6) inset;
    --lm-shadow-hover: 0 14px 30px rgba(0,0,0,0.08), 0 1px 0 rgba(255,255,255,0.7) inset;
    --lm-radius:  14px;
}

/* ── Section wrapper ─────────────────────────────────────── */
/* Override the 800px cap from style.css #s3_services_learning */
#s3_services_learning.lm-section,
.lm-section {
    max-width: 1100px;
    margin: 0 auto;
    padding: 32px 16px 60px;
}

/* ── Page hero title ─────────────────────────────────────── */
.lm-hero {
    text-align: center;
    margin-bottom: 28px;
}

.lm-hero__title {
    font-size: 30px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    color: var(--lm-dark);
    margin: 0 0 10px;
}

.lm-hero__subtitle {
    font-size: 15px;
    color: rgba(13, 82, 105, 0.75);
    margin: 0;
    font-style: italic;
}

/* ── Navigation pill bar ─────────────────────────────────── */
.lm-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    margin-bottom: 36px;
    padding: 16px 18px;

    background: transparent;
    border: 1px solid var(--lm-border);
    border-radius: var(--lm-radius);
    box-shadow: var(--lm-shadow);
}

.lm-nav__group {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}

.lm-nav__divider {
    width: 1px;
    height: 24px;
    background: var(--lm-border);
    align-self: center;
    margin: 0 4px;
}

.lm-nav a {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 6px 14px;
    border-radius: 22px;
    text-decoration: none;
    font-size: 13px;
    font-weight: 600;
    color: var(--lm-brand);
    background: white;
    border: 1px solid rgba(13, 82, 105, 0.22);
    box-shadow: 0 2px 6px rgba(0,0,0,0.05);
    transition: background 0.18s ease, color 0.18s ease, border-color 0.18s ease, transform 0.15s ease;
    white-space: nowrap;
}

.lm-nav a:hover {
    background: var(--lm-accent);
    color: #fff;
    border-color: var(--lm-accent);
    transform: translateY(-1px);
}

.lm-nav__lang-label {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.7px;
    color: rgba(13, 82, 105, 0.5);
    align-self: center;
    padding: 0 4px;
}

/* ── Card grid ───────────────────────────────────────────── */
.lm-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 24px;
}

/* ── Individual card ─────────────────────────────────────── */
.lm-card {
    background: transparent;
    border-radius: var(--lm-radius);
    border: 1px solid var(--lm-border);
    box-shadow: var(--lm-shadow);
    padding: 20px 18px 22px;
    display: flex;
    flex-direction: column;
    transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
}

.lm-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--lm-shadow-hover);
    border-color: rgba(13, 82, 105, 0.26);
}

/* ── Card header row ─────────────────────────────────────── */
.lm-card__header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 14px;
}

.lm-card__icon {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: white;
    border: 1px solid var(--lm-border);
    box-shadow: 0 4px 10px rgba(0,0,0,0.06);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    flex-shrink: 0;
}

.lm-card__title {
    font-size: 16px;
    font-weight: 700;
    color: var(--lm-dark);
    margin: 0;
    line-height: 1.3;
}

/* ── Video player ────────────────────────────────────────── */
.lm-card__video {
    width: 100%;
    border-radius: 10px;
    overflow: hidden;
    background: #000;
    box-shadow: 0 6px 18px rgba(0,0,0,0.12);
    flex: 1;
}

.lm-card__video video {
    width: 100%;
    height: auto;
    display: block;
}

/* ── PDF action buttons ──────────────────────────────────── */
.lm-card__pdf-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
    flex: 1;
    justify-content: center;
}

.lm-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    padding: 10px 18px;
    border-radius: 22px;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    transition: background 0.18s ease, transform 0.15s ease, box-shadow 0.15s ease;
    box-shadow: 0 3px 8px rgba(0,0,0,0.08);
}

.lm-btn--view {
    background: var(--lm-accent);
    color: #fff;
    border: 1px solid transparent;
}

.lm-btn--view:hover {
    background: var(--lm-brand);
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(13, 82, 105, 0.22);
}

.lm-btn--download {
    background: white;
    color: var(--lm-brand);
    border: 1px solid rgba(13, 82, 105, 0.28);
}

.lm-btn--download:hover {
    background: rgba(35, 134, 167, 0.07);
    border-color: var(--lm-accent);
    transform: translateY(-1px);
}

/* ── Language badge on card ──────────────────────────────── */
.lm-lang-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 2px 8px;
    border-radius: 10px;
    margin-bottom: 4px;
}

.lm-lang-badge--kg {
    background: rgba(35, 134, 167, 0.1);
    color: var(--lm-accent);
    border: 1px solid rgba(35, 134, 167, 0.25);
}

.lm-lang-badge--ru {
    background: rgba(13, 82, 105, 0.08);
    color: var(--lm-brand);
    border: 1px solid var(--lm-border);
}

/* ── Section divider headings ────────────────────────────── */
.lm-section-label {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: rgba(13, 82, 105, 0.55);
    margin: 36px 0 14px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.lm-section-label::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--lm-border);
}

/* ── Responsive ──────────────────────────────────────────── */
@media (max-width: 680px) {
    .lm-hero__title {
        font-size: 22px;
    }

    .lm-nav {
        padding: 12px 12px;
        gap: 6px;
    }

    .lm-nav a {
        font-size: 12px;
        padding: 5px 11px;
    }

    .lm-nav__divider {
        display: none;
    }

    .lm-grid {
        grid-template-columns: 1fr;
    }

    .lm-card__title {
        font-size: 15px;
    }
}

@media (max-width: 400px) {
    .lm-section {
        padding: 20px 10px 40px;
    }

    .lm-hero__title {
        font-size: 18px;
    }

    .lm-btn {
        font-size: 13px;
        padding: 9px 14px;
    }
}
