/* ==========================================================
   Basic LMS — Frontend
   ========================================================== */

.blms-form { max-width: 560px; padding: 24px; background: #fff; border: 1px solid #e5e7eb; border-radius: 10px; box-shadow: 0 1px 2px rgba(0,0,0,.04); margin: 24px auto; }
.blms-form h3 { margin: 0 0 18px; font-size: 22px; }
.blms-field { margin-bottom: 14px; }
.blms-field label { display: block; font-size: 13px; font-weight: 600; margin-bottom: 4px; color: #374151; }
.blms-field .req { color: #dc2626; }
.blms-field input[type="text"],
.blms-field input[type="email"],
.blms-field input[type="password"],
.blms-field input[type="tel"],
.blms-field input[type="url"],
.blms-field input[type="number"],
.blms-field input[type="search"],
.blms-field input[type="datetime-local"],
.blms-field input[type="file"],
.blms-field select,
.blms-field textarea {
    width: 100%; padding: 9px 11px; font-size: 14px; border: 1px solid #d1d5db; border-radius: 6px; box-sizing: border-box; background: #fff;
}
.blms-field input:focus, .blms-field textarea:focus, .blms-field select:focus { outline: 0; border-color: #2563eb; box-shadow: 0 0 0 3px rgba(37,99,235,.15); }
.blms-row { display: flex; gap: 12px; }
.blms-row .blms-field { flex: 1; }
.blms-note { font-size: 12px; color: #6b7280; margin-top: 10px; }
.blms-msg { margin-top: 12px; font-size: 13px; min-height: 18px; }
.blms-msg.success { color: #15803d; }
.blms-msg.error { color: #dc2626; }

.blms-btn { display: inline-block; padding: 9px 16px; font-size: 14px; font-weight: 600; border: 1px solid #d1d5db; background: #fff; color: #111; border-radius: 6px; cursor: pointer; text-decoration: none; }
.blms-btn:hover { background: #f9fafb; }
.blms-btn-primary { background: #2563eb; color: #fff; border-color: #2563eb; }
.blms-btn-primary:hover { background: #1d4ed8; color: #fff; }
.blms-btn-sm { padding: 5px 10px; font-size: 12px; }
.blms-forgot { display: inline-block; margin-left: 12px; font-size: 13px; }

.blms-notice { padding: 12px 16px; background: #eff6ff; border: 1px solid #bfdbfe; color: #1e3a8a; border-radius: 6px; margin: 18px auto; max-width: 560px; }

/* Dashboard */
.blms-dashboard { max-width: 1100px; margin: 24px auto; }
.blms-dashboard h2 { margin: 0 0 16px; }
.blms-tabs { display: flex; gap: 8px; border-bottom: 1px solid #e5e7eb; margin-bottom: 24px; flex-wrap: wrap; }
.blms-tabs a { padding: 10px 14px; font-size: 14px; font-weight: 600; color: #6b7280; text-decoration: none; border-bottom: 2px solid transparent; }
.blms-tabs a.active, .blms-tabs a:hover { color: #2563eb; border-color: #2563eb; }
.blms-tab-panel { display: none; }
.blms-tab-panel.active { display: block; }

.blms-table { width: 100%; border-collapse: collapse; margin: 12px 0 24px; background: #fff; border: 1px solid #e5e7eb; border-radius: 8px; overflow: hidden; }
.blms-table th, .blms-table td { padding: 10px 12px; text-align: left; font-size: 14px; border-bottom: 1px solid #f3f4f6; }
.blms-table th { background: #f9fafb; font-weight: 600; color: #374151; }
.blms-table tr:last-child td { border-bottom: 0; }

/* Notifications list */
.blms-notif-list { list-style: none; padding: 0; margin: 0; }
.blms-notif-list li { padding: 12px 14px; border: 1px solid #e5e7eb; border-radius: 8px; margin-bottom: 10px; background: #fff; }
.blms-notif-list li strong { display: block; font-size: 14px; color: #111; }
.blms-notif-date { float: right; font-size: 12px; color: #6b7280; }
.blms-notif-list li p { font-size: 13px; color: #4b5563; margin: 6px 0 0; }

/* Catalog & cards */
.blms-catalog { max-width: 1200px; margin: 24px auto; }
.blms-filters { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 20px; position: relative; }
.blms-filters input[type="search"] { padding: 9px 11px; border: 1px solid #d1d5db; border-radius: 6px; min-width: 260px; flex: 1; }
.blms-filters select { padding: 9px 11px; border: 1px solid #d1d5db; border-radius: 6px; }
.blms-suggest { position: absolute; top: 100%; left: 0; right: 0; background: #fff; border: 1px solid #e5e7eb; border-top: 0; max-height: 260px; overflow: auto; z-index: 50; border-radius: 0 0 6px 6px; display: none; }
.blms-suggest.show { display: block; }
.blms-suggest a { display: block; padding: 8px 12px; color: #111; text-decoration: none; border-bottom: 1px solid #f3f4f6; }
.blms-suggest a:hover { background: #f9fafb; }

.blms-course-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 16px; }
.blms-card { display: block; background: #fff; border: 1px solid #e5e7eb; border-radius: 10px; overflow: hidden; text-decoration: none; color: inherit; transition: box-shadow .15s, transform .15s; }
.blms-card:hover { box-shadow: 0 4px 16px rgba(0,0,0,.08); transform: translateY(-2px); }
.blms-card img { width: 100%; height: 160px; object-fit: cover; display: block; }
.blms-card-body { padding: 14px; }
.blms-card-body h4 { margin: 0 0 6px; font-size: 16px; }
.blms-card-meta { font-size: 12px; color: #6b7280; margin: 0 0 10px; }
.blms-card-price { font-weight: 700; color: #2563eb; }

/* Progress */
.blms-progress { width: 100%; height: 8px; background: #e5e7eb; border-radius: 4px; overflow: hidden; margin: 10px 0 4px; }
.blms-progress-bar { height: 100%; background: #2563eb; transition: width .3s; }
.blms-progress-text { font-size: 12px; color: #6b7280; margin-bottom: 10px; }

/* Course detail */
.blms-course-detail { max-width: 1000px; margin: 24px auto; }
.blms-course-head { display: flex; gap: 24px; align-items: flex-start; margin-bottom: 24px; }
.blms-course-head img { width: 320px; max-width: 40%; height: auto; border-radius: 10px; }
.blms-course-head h1 { margin: 0 0 8px; }
.blms-course-meta { color: #6b7280; }
.blms-course-price { font-size: 22px; font-weight: 700; color: #2563eb; margin: 14px 0; }
.blms-enroll { padding: 14px; background: #f9fafb; border: 1px solid #e5e7eb; border-radius: 8px; margin-top: 8px; }
.blms-enroll h4 { margin: 0 0 10px; }
.blms-pay-btn { margin-right: 6px; margin-bottom: 6px; }
.blms-course-desc { margin: 20px 0; line-height: 1.6; }

/* Modules / lessons */
.blms-modules { display: flex; flex-direction: column; gap: 10px; }
.blms-module { background: #fff; border: 1px solid #e5e7eb; border-radius: 8px; padding: 14px; }
.blms-module-head { display: flex; align-items: center; margin-bottom: 8px; }
.blms-module-desc { font-size: 13px; color: #6b7280; margin: 0 0 10px; }
.blms-lessons { list-style: none; padding: 0; margin: 0; }
.blms-lessons li { padding: 8px 0; border-bottom: 1px solid #f3f4f6; font-size: 14px; }
.blms-lessons li:last-child { border-bottom: 0; }
.blms-lesson-type { display: inline-block; padding: 2px 7px; background: #eff6ff; color: #1e40af; border-radius: 4px; font-size: 11px; text-transform: uppercase; font-weight: 600; margin-right: 8px; }
.blms-lock { margin-left: 6px; opacity: .6; }
.blms-duration { float: right; font-size: 12px; color: #6b7280; }

/* Lesson player */
.blms-lesson { max-width: 900px; margin: 24px auto; }
.blms-back { display: inline-block; margin-bottom: 12px; color: #6b7280; text-decoration: none; font-size: 14px; }
.blms-back:hover { color: #2563eb; }
.blms-video-wrapper { position: relative; width: 100%; background: #000; border-radius: 8px; overflow: hidden; }
.blms-video-wrapper video { width: 100%; display: block; }
.blms-watermark { position: absolute; right: 14px; top: 14px; padding: 4px 10px; background: rgba(0,0,0,.4); color: #fff; font-size: 12px; border-radius: 4px; pointer-events: none; user-select: none; font-family: monospace; transition: top 1s, right 1s, bottom 1s, left 1s; }
.blms-resume-info { font-size: 13px; color: #2563eb; margin-top: 8px; }
.blms-pdf { width: 100%; height: 70vh; border: 1px solid #e5e7eb; border-radius: 8px; }
.blms-live { padding: 20px; background: #eff6ff; border: 1px solid #bfdbfe; border-radius: 8px; text-align: center; }
.blms-lesson-body { margin: 20px 0; line-height: 1.6; }
.blms-lesson-actions { margin: 20px 0; }
.blms-done { display: inline-block; padding: 9px 16px; background: #d1f4dd; color: #007017; border-radius: 6px; font-weight: 600; }
.blms-lesson-nav { display: flex; align-items: center; margin-top: 24px; padding-top: 16px; border-top: 1px solid #e5e7eb; }
.blms-lesson-nav .blms-spacer { flex: 1; }

@media (max-width: 700px) {
    .blms-row { flex-direction: column; }
    .blms-course-head { flex-direction: column; }
    .blms-course-head img { max-width: 100%; width: 100%; }
}
