/* ===================================
   ASTRO LMS — Interface élève
   Palette : Sauge | Beige | Rose poudré
   =================================== */

:root {
    --alms-sage:       #7a9e8e;
    --alms-sage-dark:  #5a7d6e;
    --alms-sage-light: #d4e5dc;
    --alms-beige:      #f5f0e8;
    --alms-beige-mid:  #ede6d8;
    --alms-rose:       #d4a5a5;
    --alms-rose-light: #f0dede;
    --alms-text:       #3d3d3d;
    --alms-text-light: #6b6b6b;
    --alms-white:      #ffffff;
    --alms-radius:     12px;
    --alms-shadow:     0 4px 20px rgba(90, 125, 110, 0.12);
    --alms-shadow-hover: 0 8px 30px rgba(90, 125, 110, 0.2);
    --alms-transition: all 0.25s ease;
    --alms-font:       'Georgia', serif;
    --alms-font-sans:  -apple-system, 'Segoe UI', sans-serif;
}

/* =================== BASE =================== */
.alms-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 12px 24px;
    border-radius: 50px;
    font-size: 0.95rem;
    font-family: var(--alms-font-sans);
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: var(--alms-transition);
    text-decoration: none;
    white-space: nowrap;
}
.alms-btn-primary {
    background: var(--alms-sage);
    color: var(--alms-white);
}
.alms-btn-primary:hover {
    background: var(--alms-sage-dark);
    color: var(--alms-white);
    transform: translateY(-2px);
    box-shadow: var(--alms-shadow-hover);
}
.alms-btn-secondary {
    background: var(--alms-rose-light);
    color: var(--alms-sage-dark);
    border: 1.5px solid var(--alms-rose);
}
.alms-btn-secondary:hover {
    background: var(--alms-rose);
    color: var(--alms-white);
}
.alms-btn-ghost {
    background: transparent;
    color: var(--alms-sage);
    border: 1.5px solid var(--alms-sage);
}
.alms-btn-ghost:hover {
    background: var(--alms-sage-light);
}
.alms-btn-stripe {
    background: linear-gradient(135deg, #635bff, #4f46e5);
    color: white;
    width: 100%;
    justify-content: center;
    padding: 14px 24px;
    font-size: 1rem;
}
.alms-btn-stripe:hover { opacity: 0.9; transform: translateY(-1px); }
.alms-btn-paypal {
    background: linear-gradient(135deg, #ffd140, #f6a400);
    color: #1b2b4b;
    width: 100%;
    justify-content: center;
    padding: 14px 24px;
    font-size: 1rem;
}
.alms-btn-paypal:hover { opacity: 0.9; transform: translateY(-1px); }
.alms-section-title {
    font-family: var(--alms-font);
    font-size: 1.3rem;
    color: var(--alms-sage-dark);
    margin-bottom: 20px;
}

/* =================== GRILLE FORMATIONS =================== */
.alms-courses-grid {
    display: grid;
    gap: 24px;
    margin: 30px 0;
}
.alms-cols-3 { grid-template-columns: repeat(3, 1fr); }
.alms-cols-2 { grid-template-columns: repeat(2, 1fr); }
.alms-cols-1 { grid-template-columns: 1fr; }

@media (max-width: 900px) {
    .alms-cols-3, .alms-cols-2 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 600px) {
    .alms-cols-3, .alms-cols-2, .alms-cols-1 { grid-template-columns: 1fr; }
}

.alms-course-card {
    background: var(--alms-white);
    border-radius: var(--alms-radius);
    box-shadow: var(--alms-shadow);
    overflow: hidden;
    transition: var(--alms-transition);
    border: 1px solid var(--alms-sage-light);
}
.alms-course-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--alms-shadow-hover);
}
.alms-course-card.alms-owned { border-color: var(--alms-sage); }
.alms-card-thumb img { width: 100%; height: 200px; object-fit: cover; display: block; }
.alms-card-body { padding: 20px; }
.alms-card-badge {
    display: inline-block;
    background: var(--alms-sage-light);
    color: var(--alms-sage-dark);
    padding: 3px 12px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    margin-bottom: 10px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.alms-card-title {
    font-family: var(--alms-font);
    font-size: 1.15rem;
    color: var(--alms-text);
    margin: 8px 0;
    line-height: 1.4;
}
.alms-card-excerpt {
    font-size: 0.88rem;
    color: var(--alms-text-light);
    line-height: 1.6;
    margin-bottom: 12px;
}
.alms-card-meta { font-size: 0.82rem; color: var(--alms-text-light); margin-bottom: 14px; }
.alms-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding-top: 16px;
    border-top: 1px solid var(--alms-beige-mid);
}
.alms-price-main { font-size: 1.3rem; font-weight: 700; color: var(--alms-sage-dark); }
.alms-price-3x { font-size: 0.78rem; color: var(--alms-text-light); display: block; }
.alms-owned-badge { color: var(--alms-sage); font-weight: 600; font-size: 0.88rem; }

/* =================== PAGE DE VENTE =================== */
.alms-sales-page { max-width: 800px; }
.alms-course-badge {
    display: inline-block;
    background: var(--alms-rose);
    color: white;
    padding: 6px 18px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 700;
    margin-bottom: 20px;
    text-transform: uppercase;
    letter-spacing: 1px;
}
.alms-program-preview {
    background: var(--alms-beige);
    border-radius: var(--alms-radius);
    padding: 24px;
    margin-bottom: 30px;
}
.alms-lessons-preview {
    list-style: none;
    padding: 0;
    margin: 0;
}
.alms-lesson-preview-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid var(--alms-beige-mid);
    font-size: 0.95rem;
}
.alms-lesson-preview-item:last-child { border-bottom: none; }
.alms-free-preview {
    background: var(--alms-sage-light);
    color: var(--alms-sage-dark);
    padding: 3px 12px;
    border-radius: 20px;
    font-size: 0.78rem;
    font-weight: 600;
    text-decoration: none;
}
.alms-free-preview:hover { background: var(--alms-sage); color: white; }
.alms-locked-icon { color: #bbb; }

/* Bloc achat */
.alms-purchase-box {
    background: white;
    border-radius: var(--alms-radius);
    padding: 28px;
    box-shadow: var(--alms-shadow);
    border: 1px solid var(--alms-sage-light);
    max-width: 500px;
    margin: 0 auto;
}
.alms-purchase-header h3 {
    font-family: var(--alms-font);
    font-size: 1.2rem;
    color: var(--alms-sage-dark);
    text-align: center;
    margin-bottom: 20px;
}
.alms-price-options {
    display: flex;
    gap: 12px;
    margin-bottom: 20px;
}
.alms-price-option {
    flex: 1;
    border: 2px solid var(--alms-beige-mid);
    border-radius: 10px;
    padding: 16px;
    cursor: pointer;
    transition: var(--alms-transition);
    text-align: center;
}
.alms-price-option:hover, .alms-price-option.alms-active {
    border-color: var(--alms-sage);
    background: var(--alms-beige);
}
.alms-price-label { font-size: 0.8rem; color: var(--alms-text-light); margin-bottom: 6px; }
.alms-price-amount { font-size: 1.4rem; font-weight: 700; color: var(--alms-sage-dark); }
.alms-price-sub { font-size: 0.75rem; color: var(--alms-text-light); margin-top: 4px; }
.alms-payment-buttons { display: flex; flex-direction: column; gap: 10px; margin-bottom: 16px; }
.alms-purchase-note {
    display: flex;
    justify-content: center;
    gap: 16px;
    font-size: 0.78rem;
    color: var(--alms-text-light);
    flex-wrap: wrap;
}
.alms-payment-message {
    padding: 12px 16px;
    border-radius: 8px;
    text-align: center;
    margin-top: 12px;
    font-size: 0.9rem;
}
.alms-payment-message.success { background: #e8f5e9; color: #2e7d32; }
.alms-payment-message.error   { background: #fce4ec; color: #c62828; }
.alms-payment-message.loading { background: var(--alms-beige); color: var(--alms-text-light); }

/* =================== TABLEAU DE BORD =================== */
.alms-dashboard { max-width: 760px; }
.alms-progress-header {
    background: linear-gradient(135deg, var(--alms-sage-light), var(--alms-rose-light));
    border-radius: var(--alms-radius);
    padding: 20px 24px;
    margin-bottom: 24px;
}
.alms-progress-info {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
}
.alms-progress-label { font-weight: 600; color: var(--alms-sage-dark); }
.alms-progress-numbers { font-size: 0.9rem; color: var(--alms-text-light); }
.alms-progress-bar-wrap {
    background: rgba(255,255,255,0.6);
    height: 10px;
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 8px;
}
.alms-progress-bar {
    background: linear-gradient(90deg, var(--alms-sage), var(--alms-sage-dark));
    height: 100%;
    border-radius: 10px;
    transition: width 0.8s ease;
}
.alms-progress-percent {
    font-size: 0.85rem;
    color: var(--alms-sage-dark);
    font-weight: 600;
}
.alms-completion-badge {
    background: linear-gradient(135deg, var(--alms-sage), var(--alms-rose));
    color: white;
    border-radius: var(--alms-radius);
    padding: 14px 20px;
    text-align: center;
    margin-bottom: 20px;
    font-size: 1rem;
}
.alms-badge-icon { font-size: 1.4rem; margin-right: 8px; }

/* Liste des leçons */
.alms-lessons-list { display: flex; flex-direction: column; gap: 8px; }
.alms-lesson-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 18px;
    background: white;
    border-radius: 10px;
    border: 1px solid var(--alms-beige-mid);
    text-decoration: none;
    color: var(--alms-text);
    transition: var(--alms-transition);
}
.alms-lesson-item:hover {
    border-color: var(--alms-sage);
    background: var(--alms-beige);
    transform: translateX(4px);
}
.alms-lesson-item.alms-completed {
    background: var(--alms-beige);
    border-color: var(--alms-sage-light);
}
.alms-lesson-icon { font-size: 1.2rem; flex-shrink: 0; }
.alms-lesson-info { flex: 1; }
.alms-lesson-title { display: block; font-weight: 500; }
.alms-lesson-duration { font-size: 0.78rem; color: var(--alms-text-light); margin-top: 2px; display: block; }
.alms-lesson-status { flex-shrink: 0; }
.alms-check { color: var(--alms-sage); font-size: 1.1rem; font-weight: 700; }
.alms-arrow { color: var(--alms-sage); }

/* =================== PAGE LEÇON =================== */
.alms-lesson-page { max-width: 800px; }
.alms-breadcrumb {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 24px;
    flex-wrap: wrap;
    gap: 8px;
}
.alms-breadcrumb a {
    color: var(--alms-sage);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
}
.alms-breadcrumb a:hover { text-decoration: underline; }
.alms-lesson-meta { font-size: 0.85rem; color: var(--alms-text-light); }

/* Vidéo */
.alms-video-wrap {
    position: relative;
    padding-bottom: 56.25%;
    height: 0;
    overflow: hidden;
    border-radius: var(--alms-radius);
    background: #111;
    margin-bottom: 28px;
}
.alms-video-wrap iframe,
.alms-video-wrap video {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    border-radius: var(--alms-radius);
}
.alms-lesson-content { line-height: 1.8; color: var(--alms-text); }
.alms-pdf-block { margin: 24px 0; }

/* Footer leçon */
.alms-lesson-footer {
    margin-top: 36px;
    padding-top: 24px;
    border-top: 1px solid var(--alms-beige-mid);
}
.alms-lesson-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
}
.alms-btn-complete {
    background: var(--alms-beige-mid);
    color: var(--alms-sage-dark);
    border: 1.5px solid var(--alms-sage-light);
    border-radius: 50px;
    padding: 10px 20px;
    font-size: 0.9rem;
    cursor: pointer;
    transition: var(--alms-transition);
}
.alms-btn-complete:hover, .alms-btn-complete.alms-done {
    background: var(--alms-sage-light);
    border-color: var(--alms-sage);
    color: var(--alms-sage-dark);
}
.alms-btn-complete.alms-done { cursor: default; }

/* Leçon verrouillée */
.alms-locked-lesson {
    text-align: center;
    padding: 60px 20px;
    background: var(--alms-beige);
    border-radius: var(--alms-radius);
    border: 1px solid var(--alms-beige-mid);
}
.alms-lock-icon { font-size: 3rem; margin-bottom: 16px; }
.alms-locked-lesson h3 { font-family: var(--alms-font); color: var(--alms-sage-dark); margin-bottom: 12px; }
.alms-locked-lesson p { color: var(--alms-text-light); margin-bottom: 20px; }

/* =================== QUIZ =================== */
.alms-quiz-wrapper { margin: 32px 0; }
.alms-quiz-container {
    background: var(--alms-beige);
    border-radius: var(--alms-radius);
    overflow: hidden;
    border: 1px solid var(--alms-sage-light);
}
.alms-quiz-header {
    background: linear-gradient(135deg, var(--alms-sage), var(--alms-sage-dark));
    color: white;
    padding: 18px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.alms-quiz-title { font-family: var(--alms-font); font-size: 1.05rem; margin: 0; }
.alms-quiz-count {
    background: rgba(255,255,255,0.2);
    padding: 3px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
}
.alms-quiz-form { padding: 24px; }
.alms-quiz-question { margin-bottom: 28px; }
.alms-question-number {
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--alms-sage);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 8px;
}
.alms-question-text {
    font-size: 1rem;
    color: var(--alms-text);
    font-weight: 500;
    margin-bottom: 16px;
    line-height: 1.6;
}
.alms-choices-list { display: flex; flex-direction: column; gap: 8px; }
.alms-choice-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background: white;
    border-radius: 8px;
    border: 1.5px solid var(--alms-beige-mid);
    cursor: pointer;
    transition: var(--alms-transition);
    font-size: 0.95rem;
}
.alms-choice-item:hover { border-color: var(--alms-sage); background: var(--alms-sage-light); }
.alms-choice-item input[type="radio"] { accent-color: var(--alms-sage); flex-shrink: 0; }
.alms-choice-item.correct { background: #e8f5e9; border-color: #4caf50; }
.alms-choice-item.incorrect { background: #fce4ec; border-color: #e91e63; }
.alms-text-answer textarea {
    width: 100%;
    border: 1.5px solid var(--alms-beige-mid);
    border-radius: 8px;
    padding: 14px;
    font-size: 0.95rem;
    color: var(--alms-text);
    background: white;
    resize: vertical;
    transition: var(--alms-transition);
    box-sizing: border-box;
    font-family: var(--alms-font-sans);
}
.alms-text-answer textarea:focus { border-color: var(--alms-sage); outline: none; }
.alms-quiz-submit { text-align: center; padding-top: 8px; }

/* Résultats quiz */
.alms-quiz-results { padding: 24px; }
.alms-result-header {
    text-align: center;
    padding: 24px;
    border-radius: 10px;
    margin-bottom: 20px;
}
.alms-result-header.passed { background: linear-gradient(135deg, #e8f5e9, #c8e6c9); }
.alms-result-header.failed { background: linear-gradient(135deg, #fce4ec, #f8bbd0); }
.alms-result-score { font-size: 2.5rem; font-weight: 700; margin: 8px 0; }
.alms-result-score.passed { color: #2e7d32; }
.alms-result-score.failed { color: #c62828; }
.alms-result-label { font-size: 0.9rem; color: var(--alms-text-light); }

/* =================== MES FORMATIONS =================== */
.alms-my-courses { padding: 10px 0; }
.alms-my-courses-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 20px; }
.alms-my-course-card {
    background: white;
    border-radius: var(--alms-radius);
    overflow: hidden;
    box-shadow: var(--alms-shadow);
    border: 1px solid var(--alms-sage-light);
}
.alms-my-card-thumb img { width: 100%; height: 150px; object-fit: cover; }
.alms-my-card-body { padding: 16px; }
.alms-my-card-body h3 { font-family: var(--alms-font); font-size: 1rem; margin-bottom: 10px; color: var(--alms-text); }
.alms-mini-progress { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; }
.alms-mini-bar { flex: 1; height: 6px; background: var(--alms-beige-mid); border-radius: 6px; overflow: hidden; }
.alms-mini-fill { height: 100%; background: var(--alms-sage); border-radius: 6px; transition: width 0.6s ease; }
.alms-my-courses-empty { text-align: center; padding: 40px; color: var(--alms-text-light); }

/* =================== SPINNER / LOADING =================== */
.alms-spinner {
    display: inline-block;
    width: 18px; height: 18px;
    border: 2px solid rgba(255,255,255,0.4);
    border-top-color: white;
    border-radius: 50%;
    animation: alms-spin 0.7s linear infinite;
    vertical-align: middle;
}
@keyframes alms-spin { to { transform: rotate(360deg); } }

/* =================== RESPONSIVE =================== */
@media (max-width: 600px) {
    .alms-price-options { flex-direction: column; }
    .alms-lesson-nav { flex-direction: column; }
    .alms-lesson-nav .alms-btn { width: 100%; justify-content: center; }
    .alms-quiz-header { flex-direction: column; gap: 8px; text-align: center; }
    .alms-purchase-box { padding: 20px; }
}

/* =================== DOCUMENTS BONUS =================== */
.alms-bonuses-section {
    margin-top: 36px;
    padding-top: 28px;
    border-top: 1px solid var(--alms-beige-mid);
}
.alms-bonuses-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 14px;
}
.alms-bonus-card {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 16px 18px;
    background: white;
    border-radius: 12px;
    border: 1.5px solid var(--alms-rose-light);
    text-decoration: none;
    color: var(--alms-text);
    transition: var(--alms-transition);
    position: relative;
}
.alms-bonus-card:hover {
    border-color: var(--alms-rose);
    background: var(--alms-rose-light);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(212, 165, 165, 0.2);
    color: var(--alms-text);
}
.alms-bonus-icon {
    font-size: 1.8rem;
    flex-shrink: 0;
    line-height: 1;
}
.alms-bonus-info {
    flex: 1;
    min-width: 0;
}
.alms-bonus-title {
    display: block;
    font-weight: 600;
    font-size: 0.92rem;
    line-height: 1.3;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.alms-bonus-desc {
    display: block;
    font-size: 0.78rem;
    color: var(--alms-text-light);
    margin-top: 3px;
}
.alms-bonus-dl {
    font-size: 0.9rem;
    color: var(--alms-rose);
    flex-shrink: 0;
    opacity: 0.7;
}
.alms-bonus-card:hover .alms-bonus-dl { opacity: 1; }

@media (max-width: 600px) {
    .alms-bonuses-grid { grid-template-columns: 1fr; }
}

/* =================== MON COMPTE =================== */
.alms-account { max-width: 600px; margin: 0 auto; }
.alms-account-notice {
    padding: 13px 18px; border-radius: 10px;
    margin-bottom: 20px; font-size: 0.9rem;
}
.alms-notice-success { background: #edf7f0; border: 1px solid #a8d5b5; color: #1e7a40; }
.alms-notice-error   { background: #fdf0ee; border: 1px solid #f1b0a8; color: var(--alms-error, #c0392b); }
.alms-account-tabs {
    display: flex; gap: 8px; margin-bottom: 28px;
    border-bottom: 2px solid var(--alms-beige-mid, #ede6d8);
    padding-bottom: 0;
}
.alms-tab {
    padding: 10px 20px; background: none; border: none;
    border-bottom: 3px solid transparent; margin-bottom: -2px;
    font-size: 0.9rem; font-weight: 500; cursor: pointer;
    color: var(--alms-text-light, #8a8a8a);
    font-family: inherit; transition: all 0.2s;
}
.alms-tab:hover { color: var(--alms-sage, #7a9e8e); }
.alms-tab.active { color: var(--alms-sage-dark, #5a7d6e); border-bottom-color: var(--alms-sage, #7a9e8e); font-weight: 600; }
.alms-tab-content { display: none; }
.alms-tab-content.active { display: block; animation: alms-fadein 0.25s ease; }
.alms-field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 500px) { .alms-field-row { grid-template-columns: 1fr; } }
.alms-pw-strength { margin-top: 8px; }
.alms-pw-bar { height: 4px; background: var(--alms-beige-mid, #ede6d8); border-radius: 4px; overflow: hidden; margin-bottom: 5px; }
.alms-pw-fill { height: 100%; border-radius: 4px; transition: all 0.3s; width: 0; }
.alms-pw-weak   { width: 33%; background: #e74c3c; }
.alms-pw-med    { width: 66%; background: #f39c12; }
.alms-pw-strong { width: 100%; background: #27ae60; }
.alms-pw-label  { font-size: 0.75rem; color: var(--alms-text-light, #8a8a8a); }
.alms-pw-wrap { position: relative; }
.alms-pw-wrap input { padding-right: 44px; }
.alms-pw-eye { position: absolute; right: 12px; top: 50%; transform: translateY(-50%); background: none; border: none; cursor: pointer; font-size: 0.9rem; color: var(--alms-text-light, #8a8a8a); padding: 4px; }
.alms-pw-eye:hover { color: var(--alms-sage, #7a9e8e); }

/* =================== MOBILE LESSON SIDEBAR =================== */
.alms-sb-mobile-toggle { display: none; }

@media (max-width: 860px) {
  @media (min-width: 861px) { .alms-lesson-sidebar { position: sticky; top: 80px; } }

.alms-lesson-layout { grid-template-columns: 1fr !important; }

  .alms-lesson-sidebar { margin-bottom: 20px; }

  /* Cacher les éléments desktop de la sidebar */
  .alms-sb-course-title,
  .alms-sb-progress { display: none; }

  /* Bouton déroulant mobile */
  .alms-sb-mobile-toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 14px 18px;
    background: white;
    border: none;
    border-radius: var(--alms-radius, 14px);
    font-family: inherit;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--alms-sage-dark, #5a7d6e);
    cursor: pointer;
  }
  .alms-sb-mobile-toggle .alms-toggle-arrow {
    font-style: normal;
    transition: transform 0.25s;
    color: var(--alms-sage, #7a9e8e);
  }
  .alms-sb-mobile-toggle.open .alms-toggle-arrow {
    transform: rotate(180deg);
  }

  /* Liste des leçons repliée par défaut */
  .alms-sidebar-lessons {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    border-top: 0px solid var(--alms-sage-light, #d4e5dc);
  }
  .alms-sidebar-lessons.open {
    max-height: 600px;
    border-top: 1px solid var(--alms-sage-light, #d4e5dc);
  }
}

/* =================== PACKS =================== */
.alms-packs-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}
.alms-packs-grid.alms-cols-2 { grid-template-columns: repeat(2, 1fr); }
.alms-packs-grid.alms-cols-1 { grid-template-columns: 1fr; }
@media (max-width: 860px) { .alms-packs-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .alms-packs-grid { grid-template-columns: 1fr; } }

.alms-pack-card {
    background: white;
    border-radius: var(--alms-radius, 14px);
    border: 1.5px solid var(--alms-sage-light, #d4e5dc);
    box-shadow: 0 4px 24px rgba(90,125,110,.10);
    overflow: hidden;
    position: relative;
    transition: all .25s;
    display: flex;
    flex-direction: column;
}
.alms-pack-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 40px rgba(90,125,110,.18);
}

/* Pack mis en avant (Meilleure offre) */
.alms-pack-featured {
    border-color: var(--alms-sage, #7a9e8e);
    border-width: 2px;
    box-shadow: 0 8px 32px rgba(90,125,110,.20);
}
.alms-pack-featured::before {
    content: '⭐ Meilleure offre';
    display: block;
    background: linear-gradient(135deg, var(--alms-sage, #7a9e8e), #5a7d6e);
    color: white;
    text-align: center;
    font-size: .72rem;
    font-weight: 700;
    letter-spacing: .5px;
    padding: 6px;
    text-transform: uppercase;
}

/* Badge économie */
.alms-pack-saving-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    background: #d4a5a5;
    color: white;
    font-size: .7rem;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 20px;
    z-index: 1;
}
.alms-pack-featured .alms-pack-saving-badge { top: 44px; }

.alms-pack-thumb img { width: 100%; height: 140px; object-fit: cover; display: block; }

.alms-pack-body { padding: 20px; flex: 1; display: flex; flex-direction: column; }
.alms-pack-badge {
    font-size: .68rem; font-weight: 700;
    color: var(--alms-sage, #7a9e8e);
    text-transform: uppercase; letter-spacing: 1px;
    display: block; margin-bottom: 5px;
}
.alms-pack-title {
    font-family: Georgia, serif;
    font-size: 1.05rem;
    color: #2e2e2e;
    margin-bottom: 7px;
    line-height: 1.35;
}
.alms-pack-excerpt {
    font-size: .82rem;
    color: #8a8a8a;
    line-height: 1.55;
    margin-bottom: 14px;
}

/* Liste des formations incluses */
.alms-pack-courses {
    list-style: none;
    padding: 0; margin: 0 0 16px;
    display: flex; flex-direction: column; gap: 5px;
    flex: 1;
}
.alms-pack-course-item {
    font-size: .82rem;
    color: #5a5a5a;
    padding: 6px 10px;
    background: #f7f2ea;
    border-radius: 8px;
    display: flex; align-items: center; gap: 7px;
}
.alms-pack-course-item.owned { color: #5a7d6e; background: #edf5f0; }

/* Footer prix + bouton */
.alms-pack-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 14px;
    border-top: 1px solid #ede6d8;
    flex-wrap: wrap;
    gap: 10px;
}
.alms-pack-price {
    font-size: 1.5rem;
    font-weight: 700;
    color: #5a7d6e;
    display: block;
}
.alms-pack-price-3x {
    font-size: .72rem;
    color: #8a8a8a;
    display: block;
    margin-top: 2px;
}
.alms-pack-owned-badge {
    color: var(--alms-sage, #7a9e8e);
    font-weight: 600;
    font-size: .85rem;
}

/* =================== CATÉGORIES =================== */
.alms-category-section {
    margin-bottom: 52px;
}
.alms-category-header {
    margin-bottom: 22px;
    padding-bottom: 14px;
    border-bottom: 2px solid var(--alms-sage-light, #d4e5dc);
    display: flex;
    align-items: baseline;
    gap: 14px;
    flex-wrap: wrap;
}
.alms-category-title {
    font-family: Georgia, serif;
    font-size: 1.4rem;
    color: var(--alms-sage-dark, #5a7d6e);
    margin: 0;
}
.alms-category-desc {
    font-size: .875rem;
    color: var(--alms-text-light, #8a8a8a);
    margin: 0;
    font-style: italic;
}

/* =================== DISCORD PAR CATÉGORIE =================== */
.alms-discord-grid {
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.alms-discord-card {
    display: flex; align-items: center; gap: 18px;
    padding: 18px 22px;
    background: linear-gradient(135deg, #5865F2, #4752c4);
    border-radius: var(--alms-radius, 14px);
    text-decoration: none;
    box-shadow: 0 6px 24px rgba(88,101,242,.22);
    transition: all .25s;
}
.alms-discord-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 32px rgba(88,101,242,.32);
}
.alms-discord-icon {
    font-size: 1.8rem; flex-shrink: 0;
    width: 52px; height: 52px;
    background: rgba(255,255,255,.15);
    border-radius: 14px;
    display: flex; align-items: center; justify-content: center;
}
.alms-discord-info { flex: 1; }
.alms-discord-title {
    font-family: Georgia, serif;
    color: white; font-size: 1rem;
    margin-bottom: 3px;
}
.alms-discord-desc {
    color: rgba(255,255,255,.75);
    font-size: .8rem;
}
.alms-discord-arrow {
    color: rgba(255,255,255,.7);
    font-size: 1.3rem; flex-shrink: 0;
    transition: transform .2s;
}
.alms-discord-card:hover .alms-discord-arrow {
    transform: translateX(4px); color: white;
}
