
  /* Base Container */
  .crs-detail, .les-page, .les-locked { font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif; color: inherit; max-width: 1100px; margin: 0 auto; padding: 20px; }

  /* Course Grid & Cards */
  .crs-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 1.25rem; margin: 1.5rem 0; }
  .crs-card { border: 1px solid rgba(128,128,128,.2); border-radius: 12px; overflow: hidden; background: var(--bg-card, transparent); display: flex; flex-direction: column; text-decoration: none; color: inherit; transition: transform .12s, border-color .12s, box-shadow .12s; }
  .crs-card:hover { transform: translateY(-3px); border-color: var(--accent-color, #0073aa); box-shadow: 0 10px 15px -3px rgba(0,0,0,0.08); }
  .crs-card-img { height: 140px; background: rgba(128,128,128,.12) center/cover no-repeat; }
  .crs-card-body { padding: .9rem 1rem 1rem; display: flex; flex-direction: column; gap: .3rem; flex: 1; }
  .crs-card-title { font-weight: 700; font-size: 1rem; margin-bottom: .2rem; }
  .crs-card-meta { font-size: .78rem; opacity: .65; margin-bottom: .4rem; }
  .crs-card-price { margin-top: auto; font-weight: 700; color: var(--accent-color, #0073aa); }
  .crs-card-discount { display: inline-block; font-size: .7rem; padding:0.1rem 0.5rem; background:#dc3545; color:#fff; border-radius:4px; margin-left:0.3rem; }
  .crs-level { display: inline-block; font-size: .72rem; font-weight: 600; padding: .1rem .55rem; border-radius: 999px; border: 1px solid currentColor; }

  /* Page Layout & Course Detail */
  .crs-layout { display: flex; gap: 2rem; align-items: flex-start; flex-wrap: wrap; }
  .crs-main { flex: 1; min-width: 300px; }
  .crs-side { width: 310px; flex-shrink: 0; }
  .crs-school { display: flex; align-items: center; gap: 0.5rem; font-size: .85rem; opacity: .7; }
  .crs-school a { color: inherit; }
  .crs-title { margin: .2rem 0 .35rem; }
  .crs-rating { color: #d29922; letter-spacing: 1px; }
  .crs-rating small { opacity: .6; margin-left: .4rem; color: inherit; }
  .crs-hero { width: 100%; aspect-ratio: 16/9; object-fit: cover; border-radius: 12px; background: rgba(128,128,128,.12); margin: .75rem 0 1rem; }

  /* Pricing with Tax & Discount */
  .crs-pricing { display:flex; flex-wrap:wrap; align-items:center; gap:0.5rem; margin:0.5rem 0; }
  .crs-price-original { font-size:1rem; text-decoration:line-through; opacity:0.5; }
  .crs-price-current { font-size:1.5rem; font-weight:700; color:var(--accent-color,#0073aa); }
  .crs-price-discount-badge { background:#dc3545; color:#fff; padding:0.15rem 0.6rem; border-radius:4px; font-size:0.75rem; font-weight:600; }
  .crs-tax-info { font-size:0.75rem; opacity:0.6; margin-top:0.2rem; }

  /* Tabs & Course Outline */
  .crs-tabs { display: flex; gap: .25rem; border-bottom: 1px solid rgba(128,128,128,.2); margin: 1rem 0; flex-wrap: wrap; }
  .crs-tab { padding: .55rem .9rem; border: none; background: none; color: inherit; cursor: pointer; font: inherit; font-weight: 600; opacity: .6; border-bottom: 2px solid transparent; margin-bottom: -1px; }
  .crs-tab.active { opacity: 1; color: var(--accent-color, #0073aa); border-bottom-color: var(--accent-color, #0073aa); }
  .crs-panel { display: none; }
  .crs-panel.active { display: block; }
  .crs-outline { list-style: none; margin: .5rem 0; padding: 0; counter-reset: les; }
  .crs-outline li { display: flex; gap: .7rem; padding: .55rem 0; border-bottom: 1px solid rgba(128,128,128,.12); }
  .crs-outline li::before { counter-increment: les; content: counter(les); width: 24px; height: 24px; flex-shrink: 0; border-radius: 50%; background: rgba(128,128,128,.15); display: flex; align-items: center; justify-content: center; font-size: .78rem; font-weight: 700; }
  .crs-outline .les-note, .crs-outline .les-availfrom { font-size: .85rem; opacity: .7; }
  .crs-item-badge { display: inline-block; font-size: .66rem; font-weight: 700; letter-spacing: .02em; padding: .05rem .45rem; margin-left: .4rem; border-radius: 999px; border: 1px solid currentColor; opacity: .7; vertical-align: middle; text-transform: uppercase; }
  .crs-obj { list-style: none; margin: .5rem 0; padding: 0; }
  .crs-obj li { display: flex; gap: .6rem; padding: .35rem 0; }
  .crs-obj li::before { content: "✓"; color: #2ea043; font-weight: 700; }

  /* Scrollbar */
  .custom-scroll { scrollbar-width: thin; scrollbar-color: #ced1d4da transparent; }
  .custom-scroll::-webkit-scrollbar { width: 6px; }
  .custom-scroll::-webkit-scrollbar-track { background: transparent; }
  .custom-scroll::-webkit-scrollbar-thumb { background: #ced1d4da; border-radius: 10px; }
  .custom-scroll::-webkit-scrollbar-thumb:hover { background: #ced1d4da; }

  /* Side Panel & Enrollment */
  .crs-panelbox { border: 1px solid rgba(128,128,128,.2); border-radius: 14px; padding: 1.25rem; background: var(--bg-card, transparent); position: sticky; top: 1rem; }
  .crs-price { font-size: 1.6rem; font-weight: 800; }
  .crs-price-original-sm { font-size:1rem; text-decoration:line-through; opacity:0.4; margin-left:0.5rem; }
  .crs-tax-sm { font-size:0.7rem; opacity:0.6; margin-top:0.1rem; }
  .crs-facts { list-style: none; margin: 1rem 0; padding: 0; font-size: .9rem; }
  .crs-facts li { display: flex; justify-content: space-between; gap: 1rem; padding: .4rem 0; border-bottom: 1px solid rgba(128,128,128,.12); }
  .crs-facts .k { opacity: .6; }
  .crs-enroll { display: flex; align-items: center; justify-content: center; gap: 0.5rem; width: 100%; margin-top: .5rem; padding: .75rem; border: none; border-radius: 9px; background: #1d475a; color: #fff; font-weight: 700; cursor: pointer; }
  .crs-enroll:disabled { opacity: .5; cursor: default; }
  .crs-enrolled { text-align: center; padding: .6rem; border-radius: 99px; background: rgba(46,160,67,.14); color: #2ea043; font-weight: 600; margin-top: .5rem; }
  .crs-note { margin-top: .6rem; font-size: .85rem; opacity: .75; text-align: center; }

  /* Teacher & Reviews */
  .crs-teacher { display: flex; gap: 1rem; align-items: center; }
  .crs-teacher-av { width: 64px; height: 64px; border-radius: 50%; object-fit: cover; background: rgba(128,128,128,.15); }
  .crs-reviews { list-style: none; margin: 1rem 0 0; padding: 0; }
  .crs-review { padding: .85rem 0; border-top: 1px solid rgba(128,128,128,.15); }
  .crs-review-head { display: flex; justify-content: space-between; gap: .6rem; }
  .crs-review-stars { color: #d29922; }
  .crs-rform { margin-top: 1.25rem; border: 1px solid rgba(128,128,128,.2); border-radius: 12px; padding: 1rem; }
  .crs-rform textarea { width: 100%; margin-top: .5rem; padding: .6rem; border-radius: 8px; border: 1px solid rgba(128,128,128,.3); background: transparent; color: inherit; font: inherit; resize: vertical; }
  .crs-rate { display: inline-flex; flex-direction: row-reverse; gap: .15rem; font-size: 1.5rem; }
  .crs-rate input { display: none; }
  .crs-rate label { cursor: pointer; color: rgba(128,128,128,.4); }
  .crs-rate input:checked ~ label, .crs-rate label:hover, .crs-rate label:hover ~ label { color: #d29922; }

  /* Modals */
  .crs-modal { position: fixed; inset: 0; background: rgba(0,0,0,.5); display: flex; align-items: center; justify-content: center; z-index: 99999; backdrop-filter: blur(2px); padding: 1rem; }
  .crs-modal-card { background: var(--general-background, #fff); border: 1px solid rgba(128,128,128,.2); border-radius: 12px; padding: 1.4rem; width: 100%; max-width: 460px; max-height: 90vh; overflow: auto; box-shadow: 0 12px 30px rgba(0,0,0,.25); box-sizing: border-box; }
  .crs-modal-card h3 { margin: 0 0 1rem; }
  .crs-f { display: block; margin-bottom: .75rem; font-size: .85rem; }
  .crs-f input, .crs-f select { width: 100%; margin-top: .3rem; padding: .55rem; border: 1px solid rgba(128,128,128,.3); border-radius: 8px; background: transparent; color: inherit; font: inherit; box-sizing: border-box; }
  .crs-modal-actions { display: flex; justify-content: flex-end; gap: .6rem; margin-top: 1rem; }
  .crs-btn { padding: .55rem 1rem; border: 1px solid rgba(128,128,128,.3); border-radius: 8px; background: transparent; color: inherit; cursor: pointer; font: inherit; }
  .crs-btn--primary { background: #1d475a; color: #fff; border-color: transparent; font-weight: 700; }
  .crs-btn--danger { background: #dc3545; color: #fff; border-color: transparent; font-weight: 700; }
  .crs-btn--danger:hover { background: #c82333; }
  .crs-modal-err { color: #f85149; font-size: .85rem; margin-top: .5rem; min-height: 1em; }

  /* Lessons & Progress */
  .crs-related { margin-top: 2.5rem; }
  .crs-lesson-link { color: var(--accent-color, #0073aa); text-decoration: none; }
  .crs-lesson-link:hover { text-decoration: underline; }
  .crs-lesson-locked { opacity: .55; }
  .crs-lesson-locked .lk { margin-left: .3rem; }
  .les-crumb a { font-size: 16px; color: inherit; opacity: .7; text-decoration: none; display: inline-flex; align-items: center; gap: .3rem; }
  .les-nav { display: flex; justify-content: space-between; gap: 1rem; margin-top: 2.5rem; }
  .les-nav-btn { padding: .6rem .9rem; border: 1px solid rgba(128,128,128,.3); border-radius: 8px; text-decoration: none; color: inherit; max-width: 46%; }
  .les-locked { text-align: center; padding: 3rem 1.5rem; border: 1px dashed rgba(128,128,128,.35); border-radius: 14px; margin-top: 1rem; }
  .les-lock-icon { font-size: 2.6rem; line-height: 1; margin-bottom: .5rem; }
  .crs-ol-main { flex: 1; min-width: 0; }
  .crs-ol-row { display: flex; align-items: center; gap: .55rem; }
  .crs-ck { width: 16px; height: 16px; cursor: pointer; flex-shrink: 0; }
  .crs-ck:disabled { cursor: not-allowed; opacity: .5; }
  .crs-outline li.done .crs-ol-row strong { text-decoration: line-through; opacity: .6; }
  .crs-progress { margin-top: 1rem; }
  .crs-progress-head { display: flex; justify-content: space-between; font-size: .82rem; opacity: .75; margin-bottom: .35rem; }
  .crs-progress-bar { height: 8px; border-radius: 999px; background: rgba(128,128,128,.2); overflow: hidden; }
  .crs-progress-bar span { display: block; height: 100%; background: #2ea043; transition: width .2s; }
  .crs-enroll--done { background: #2ea043; }
  .les-complete { margin-top: 2rem; }

  /* Empty Search Results Container */
  .crs-no-results { text-align: center; padding: 40px 20px; opacity: .7; font-size: 15px; background: rgba(128,128,128,.05); border-radius: 10px; border: 1px dashed rgba(128,128,128,.3); margin-top: 10px; }

  /* List View Overrides */
  .crs-grid.crs-view-list { display: flex; flex-direction: column; gap: 12px; }
  .crs-grid.crs-view-list .crs-card { flex-direction: row; align-items: center; padding: 12px; }
  .crs-grid.crs-view-list .crs-card-img { width: 160px; height: 100px; flex-shrink: 0; border-radius: 6px; }
  .crs-grid.crs-view-list .crs-card-body { padding: 0 0 0 16px; flex-direction: column; justify-content: center; }
  .crs-grid.crs-view-list .crs-card-title { font-size: 1rem; margin-bottom: 4px; }
  .crs-grid.crs-view-list .crs-card-meta { margin-bottom: 6px; }

  @media (max-width: 900px) { .crs-layout { flex-direction: column; } .crs-side { width: 100%; } }
  
  .crs-review-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: .6rem;
  }
  .crs-review-delete {
    background: none;
    border: none;
    color: #f85149;
    cursor: pointer;
    padding: .2rem .4rem;
    border-radius: 4px;
    opacity: .5;
    transition: opacity .2s, background .2s;
    display: inline-flex;
    align-items: center;
  }
  .crs-review-delete:hover {
    opacity: 1;
    background: rgba(248, 81, 73, .1);
  }
  .crs-review-delete svg {
    width: 16px;
    height: 16px;
  }

  /* Delete Modal Styles */
  .crs-modal-delete .crs-modal-card {
    max-width: 420px;
    text-align: center;
  }

  .crs-modal-delete .crs-modal-card h3 {
    color: #dc3545;
    margin-bottom: 0.5rem;
  }
  .crs-modal-delete .crs-modal-card p {
    opacity: 0.8;
    margin-bottom: 1.5rem;
    font-size: 0.95rem;
    line-height: 1.5;
  }
  .crs-modal-delete .crs-modal-actions {
    display: flex;
    justify-content: center;
    gap: 0.75rem;
    margin-top: 1rem;
  }
  .crs-modal-delete .crs-btn--secondary {
    background: transparent;
    color: inherit;
    border: 1px solid rgba(128,128,128,.3);
  }
  .crs-modal-delete .crs-btn--secondary:hover {
    background: rgba(128,128,128,.08);
  }
  .crs-modal-delete .crs-btn--danger {
    background: #dc3545;
    color: #fff;
    border-color: transparent;
  }
  .crs-modal-delete .crs-btn--danger:hover {
    background: #c82333;
  }

  /* Answered-quiz lock + results review */
  .crs-quiz-result-trigger { display: inline-flex; align-items: center; gap: .45rem; background: none; border: none; padding: 0; margin: 0; font: inherit; color: inherit; cursor: pointer; text-align: left; }
  .crs-quiz-score { font-size: .72rem; font-weight: 700; padding: .05rem .5rem; border-radius: 999px; }
  .crs-quiz-score.pass { background: rgba(46,160,67,.15); color: #2ea043; }
  .crs-quiz-score.fail { background: rgba(248,81,73,.15); color: #f85149; }
  .crs-quiz-locktag { font-size: .72rem; opacity: .6; display: inline-flex; align-items: center; gap: .2rem; }
  .crs-modal-quizreview .crs-modal-card { max-width: 640px; }
  .crs-qr-head { display: flex; align-items: center; justify-content: space-between; gap: .75rem; margin-bottom: .5rem; }
  .crs-qr-head h3 { margin: 0; }
  .crs-qr-stats { display: flex; flex-wrap: wrap; gap: .4rem 1rem; font-size: .82rem; opacity: .85; margin-bottom: 1rem; padding-bottom: .75rem; border-bottom: 1px solid rgba(128,128,128,.15); }
  .quiz-score-badge { display: inline-block; padding: .25rem .75rem; border-radius: 999px; font-weight: 600; font-size: .85rem; }
  .quiz-score-badge.passed { background: rgba(46,160,67,.15); color: #2ea043; }
  .quiz-score-badge.failed { background: rgba(248,81,73,.15); color: #f85149; }
  .quiz-answer-review .question-block { padding: .75rem; margin-bottom: .75rem; border-radius: 8px; border: 1px solid rgba(128,128,128,.1); background: rgba(128,128,128,.03); }
  .quiz-answer-review .question-block.correct { border-color: #2ea043; background: rgba(46,160,67,.05); }
  .quiz-answer-review .question-block.incorrect { border-color: #f85149; background: rgba(248,81,73,.05); }
  .quiz-answer-review .question-text { font-weight: 600; margin-bottom: .5rem; }
  .quiz-answer-review .answer-text { font-size: .9rem; opacity: .9; }
  .quiz-answer-review .answer-text .user-answer { font-weight: 600; color: var(--accent-color, #0073aa); }
  .quiz-answer-review .answer-text .correct-answer { font-weight: 600; color: #2ea043; }
  .quiz-answer-review .answer-text .wrong-answer { font-weight: 600; color: #f85149; }
