/*--------------------------------------------------------------
# E-learning components – extends assets/css/style.css
# Theme colours (RDBMS): #86eafe (sidebar) · #149ddd (accent) · #173b6c (titles)
--------------------------------------------------------------*/
.inner-page { padding-top: 25px; }
.inner-page .card { margin-bottom: 15px; border: 1px solid #e3e9f2; box-shadow: 0 0 24px 0 rgba(0, 0, 0, 0.05); }
.inner-page .card-title { font-family: "Raleway", sans-serif; font-weight: 700; color: #173b6c; margin-bottom: 14px; padding-bottom: 10px; position: relative; }
.inner-page .card-title::after { content: ""; position: absolute; left: 0; bottom: 0; width: 40px; height: 3px; background: #149ddd; }
.inner-page .card-body { line-height: 1.75; }
.inner-page .card-body ul li, .inner-page .card-body ol li { margin-bottom: 6px; }
.inner-page h6.sub { font-family: "Poppins", sans-serif; font-weight: 600; color: #173b6c; margin: 18px 0 8px; }
.breadcrumbs h2 { font-weight: 400; }
@media (max-width: 1199px) { .breadcrumbs h2 { padding-right: 52px; font-size: 22px; } }
.web3-strip .card-title::after { display: none; }

/* Learning objectives / key takeaways */
.objectives { background: #f5f8fd; border-left: 4px solid #149ddd; padding: 14px 18px; }
.objectives ul { margin-bottom: 0; }
.takeaways { background: #eef9ff; border-left: 4px solid #86eafe; padding: 14px 18px; }
.takeaways ul { margin-bottom: 0; }

/* Definition / note boxes */
.def-box { background: #e4edf9; padding: 12px 16px; margin: 10px 0 14px; border-left: 4px solid #173b6c; }
.note-box { background: #eef9ff; padding: 10px 14px; margin: 12px 0; border-left: 4px solid #86eafe; font-size: 15px; }
.note-box i { color: #0b6fa0; }

/* Tables */
.inner-page .table thead th { background: #173b6c; color: #fff; font-family: "Poppins", sans-serif; font-weight: 600; vertical-align: top; }
.inner-page .table td, .inner-page .table th { font-size: 15px; }

/* Code */
pre.code { background: #050d18; color: #e6edf3; padding: 16px 18px; font-size: 13.5px; line-height: 1.6; overflow: auto; border-left: 4px solid #86eafe; border-radius: 2px; }
code.inl { background: #e4edf9; color: #173b6c; padding: 1px 6px; font-size: 90%; border-radius: 2px; }

/* Diagrams (block chain, flows) */
.flow { display: flex; flex-wrap: wrap; align-items: stretch; gap: 0; margin: 10px 0; }
.flow .node { flex: 1 1 150px; background: #fff; border: 2px solid #173b6c; padding: 10px 12px; font-size: 14px; }
.flow .node b { display: block; color: #173b6c; font-family: "Poppins", sans-serif; margin-bottom: 4px; }
.flow .arrow { display: flex; align-items: center; justify-content: center; padding: 0 6px; color: #149ddd; font-size: 26px; }
.flow .mono { font-family: Consolas, Menlo, monospace; font-size: 12.5px; word-break: break-all; }
@media (max-width: 767px) { .flow .arrow { width: 100%; transform: rotate(90deg); padding: 0; } }

/* Q/A */
.qa-list .accordion-button { font-weight: 600; color: #173b6c; font-size: 15.5px; }
.qa-list .accordion-button:not(.collapsed) { background: #e4edf9; color: #173b6c; box-shadow: none; }
.qa-list .accordion-button:focus { box-shadow: 0 0 0 .15rem rgba(20, 157, 221, .25); }
.qa-list .accordion-body { line-height: 1.75; }
.qa-no { color: #149ddd; font-family: "Poppins", sans-serif; min-width: 38px; }

/* MCQ */
.mcq { border: 1px solid #e3e9f2; padding: 14px 16px; margin-bottom: 14px; background: #fff; }
.mcq-q { font-weight: 600; color: #050d18; margin-bottom: 10px; }
.mcq-no { color: #149ddd; font-family: "Poppins", sans-serif; }
.mcq-options { display: grid; grid-template-columns: 1fr 1fr; gap: 6px 14px; margin-bottom: 10px; }
@media (max-width: 767px) { .mcq-options { grid-template-columns: 1fr; } }
.mcq-opt { display: block; padding: 6px 10px; border: 1px solid #e3e9f2; cursor: pointer; transition: .2s; }
.mcq-opt:hover { border-color: #149ddd; background: #f5f8fd; }
.mcq-opt input { margin-right: 6px; }
.mcq-opt.correct { border-color: #18a558; background: #e9f8ef; }
.mcq-opt.wrong { border-color: #d9534f; background: #fdeeee; }
.mcq-result { margin-left: 10px; font-weight: 600; }
.mcq-result.ok { color: #18a558; }
.mcq-result.no { color: #d9534f; }
.mcq-answer { margin-top: 10px; }
.mcq-answer summary { cursor: pointer; color: #149ddd; font-weight: 600; }
.mcq-answer p { margin: 8px 0 0; background: #f5f8fd; padding: 10px 12px; }
.mcq-actions { margin-top: 6px; }
.mcq-score { margin-left: 10px; font-family: "Poppins", sans-serif; font-weight: 600; color: #173b6c; }

/* References */
.ref-note { font-size: 14px; color: #555; background: #f5f8fd; padding: 10px 12px; }
.ref-list li { font-size: 14.5px; margin-bottom: 8px; word-break: break-word; }

/* Chapter navigation */
.chapter-nav { display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin-top: 10px; }

/* Home page */
.web3-strip { border-left: 5px solid #149ddd !important; }
.feature-box { display: flex; gap: 14px; margin-bottom: 22px; }
.feature-box .ic { flex: 0 0 50px; height: 50px; border-radius: 50%; background: #149ddd; display: flex; align-items: center; justify-content: center; }
.feature-box .ic i { color: #fff; font-size: 22px; }
.feature-box h6 { font-weight: 700; color: #343a40; margin-bottom: 4px; font-size: 16.5px; }
.feature-box p { font-size: 14.5px; margin: 0; line-height: 1.65; }
.module-title { font-family: "Poppins", sans-serif; font-weight: 600; color: #173b6c; font-size: 16px; margin: 14px 0 12px; }
.module-title span { background: #86eafe; padding: 3px 10px; margin-right: 8px; font-size: 12.5px; }
.chapter-card { display: block; background: #fff; padding: 14px 16px; height: 100%; border: 1px solid #e3e9f2; transition: .3s; color: #272829; }
.chapter-card:hover { border-color: #149ddd; box-shadow: 0 4px 20px rgba(20, 157, 221, .15); transform: translateY(-2px); color: #272829; }
.chapter-card .chn { font-family: "Poppins", sans-serif; font-weight: 700; color: #149ddd; font-size: 12.5px; }
.chapter-card h6 { font-weight: 700; color: #173b6c; margin: 4px 0 6px; font-size: 15.5px; }
.chapter-card p { font-size: 13.5px; margin: 0; line-height: 1.55; }
.hashtags span { display: inline-block; background: #e4edf9; color: #173b6c; font-size: 13px; font-weight: 600; padding: 4px 12px; margin: 0 6px 8px 0; }

/* Q/A panel */
.qp-chapter { margin-bottom: 8px; }
.qp-toc a { display: inline-block; margin: 0 6px 8px 0; padding: 4px 10px; border: 1px solid #e3e9f2; font-size: 13.5px; }
.qp-toc a:hover { border-color: #149ddd; }

@media print {
  #header, #footer, .mobile-nav-toggle, .back-to-top, .chapter-nav, .mcq-check, .mcq-actions { display: none !important; }
  #main { margin-left: 0 !important; }
  .accordion-collapse { display: block !important; }
}

/* Code examples (code + verified output) */
.code-ex { margin: 10px 0 16px; }
.code-ex .code-title { font-family: "Poppins", sans-serif; font-weight: 600; font-size: 14px; color: #173b6c; margin-bottom: 4px; }
.code-ex pre.code { margin-bottom: 0; }
.code-out-label { display: inline-block; background: #86eafe; color: #050d18; font-family: "Poppins", sans-serif; font-size: 12px; font-weight: 600; padding: 2px 10px; margin-top: 6px; }
pre.code-out { background: #f5f8fd; color: #050d18; border-left: 4px solid #86eafe; padding: 10px 16px; font-size: 13.5px; line-height: 1.55; overflow: auto; margin: 0; }
.syntax { font-family: Consolas, Menlo, monospace; background: #e4edf9; color: #173b6c; padding: 8px 14px; display: block; margin: 6px 0 12px; white-space: pre-wrap; }

/* Responsive 16:9 video (replaces fixed-height iframes) */
.video-wrap { position: relative; width: 100%; padding-top: 56.25%; }
.video-wrap iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

/* Chapters & Video Lessons page (videos.php) */
.video-card { height: 100%; display: flex; flex-direction: column; background: #fff; border: 1px solid #e3e9f2; transition: .3s; }
.video-card:hover { border-color: #149ddd; box-shadow: 0 4px 20px rgba(20, 157, 221, .18); }
.video-thumb { position: relative; display: block; aspect-ratio: 16 / 9; overflow: hidden; background: #050d18; }
.video-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s; }
.video-card:hover .video-thumb img { transform: scale(1.04); }
.video-thumb .play { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; }
.video-thumb .play i { width: 58px; height: 58px; border-radius: 50%; background: rgba(20, 157, 221, .92); color: #fff; font-size: 34px; display: flex; align-items: center; justify-content: center; padding-left: 4px; box-shadow: 0 2px 12px rgba(0,0,0,.35); }
.video-thumb.no-video { display: flex; align-items: center; justify-content: center; background: #86eafe; color: #050d18; font-weight: 600; }
.video-info { padding: 12px 14px 14px; display: flex; flex-direction: column; flex: 1; }
.video-info .chn { font-family: "Poppins", sans-serif; font-weight: 700; color: #149ddd; font-size: 12.5px; }
.video-info h6 { font-weight: 700; margin: 4px 0 6px; font-size: 16px; }
.video-info h6 a { color: #173b6c; }
.video-info p { font-size: 13.5px; line-height: 1.55; margin-bottom: 10px; flex: 1; }
.video-links { display: flex; gap: 14px; flex-wrap: wrap; font-size: 14px; font-weight: 600; }
.video-links i { vertical-align: -2px; }

/*--------------------------------------------------------------
# PDF Viewer (free tool, PDF.js) – RDBMS theme
--------------------------------------------------------------*/
.pdfv { --pdfv-h: 78vh; position: relative; display: flex; flex-direction: column; border: 1px solid #c9d6e8; background: #fff; outline: none; }
.pdfv-toolbar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px 10px; padding: 6px 8px; background: #86eafe; border-bottom: 1px solid #5fd3ec; }
.pdfv-group { display: flex; align-items: center; gap: 4px; }
.pdfv-btn { display: inline-flex; align-items: center; justify-content: center; width: 34px; height: 32px; border: 1px solid rgba(5, 13, 24, .18); background: rgba(255, 255, 255, .65); color: #050d18; font-size: 19px; border-radius: 3px; cursor: pointer; transition: .2s; padding: 0; margin: 0; }
.pdfv-btn:hover, .pdfv-btn:focus-visible { background: #fff; color: #149ddd; border-color: #149ddd; }
.pdfv-btn.on { background: #173b6c; color: #fff; }
.pdfv-pageinfo { font-family: "Poppins", sans-serif; font-size: 14px; color: #050d18; white-space: nowrap; }
.pdfv-page { width: 54px; height: 32px; text-align: center; border: 1px solid rgba(5, 13, 24, .25); border-radius: 3px; font-size: 14px; }
.pdfv-zoom { height: 32px; border: 1px solid rgba(5, 13, 24, .25); border-radius: 3px; font-size: 14px; padding: 0 4px; background: #fff; }
.pdfv-find { width: 150px; height: 32px; border: 1px solid rgba(5, 13, 24, .25); border-radius: 3px; padding: 0 8px; font-size: 14px; }
.pdfv-findinfo { font-size: 12.5px; color: #173b6c; font-weight: 600; min-width: 0; white-space: nowrap; }
.pdfv-progress { height: 3px; background: transparent; transition: opacity .4s; }
.pdfv-progress span { display: block; height: 100%; width: 0; background: #149ddd; transition: width .2s; }
.pdfv-stage { position: relative; height: var(--pdfv-h); min-height: 360px; overflow: auto; background: #525659; padding: 12px; text-align: center; scroll-behavior: auto; }
.pdfv-pagewrap { position: relative; margin: 0 auto 12px; background: #fff; box-shadow: 0 2px 10px rgba(0, 0, 0, .45); }
.pdfv-pagewrap canvas { display: block; }
.pdfv-pageno { position: absolute; right: 6px; bottom: 4px; font-size: 11px; color: #777; background: rgba(255,255,255,.8); padding: 0 5px; pointer-events: none; }
.pdfv-pagewrap.pdfv-hit { box-shadow: 0 0 0 3px #86eafe, 0 2px 10px rgba(0, 0, 0, .45); }
.pdfv-status { display: flex; justify-content: space-between; gap: 10px; padding: 4px 10px; background: #f5f8fd; font-size: 12.5px; color: #173b6c; border-top: 1px solid #e3e9f2; }
.pdfv-name { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pdfv-fallback { display: block; width: 100%; height: 100%; background: #fff; }
.pdfv-error { background: #fff; color: #b02a37; padding: 18px; margin: 30px auto; max-width: 520px; text-align: left; }
.pdfv-loading .pdfv-stage::after { content: "Loading PDF…"; position: absolute; top: 40%; left: 0; right: 0; color: #fff; font-family: "Poppins", sans-serif; }
.pdfv-night .pdfv-pagewrap canvas { filter: invert(.92) hue-rotate(180deg); }
.pdfv-night .pdfv-pagewrap { background: #111; }
.pdfv:fullscreen { --pdfv-h: calc(100vh - 80px); border: 0; }
.pdfv:fullscreen .pdfv-stage { height: calc(100vh - 80px); }
.pdfv.pdfv-max { position: fixed; inset: 0; z-index: 10000; --pdfv-h: calc(100vh - 80px); }
.pdfv-drop { color: #fff; padding: 60px 20px; border: 2px dashed rgba(255, 255, 255, .6); margin: 20px auto; max-width: 560px; }
.pdfv-drop > i { font-size: 54px; color: #86eafe; }
.pdfv-dragging .pdfv-stage { outline: 3px dashed #86eafe; outline-offset: -8px; }
.pdfv-open { margin: 0; }
@media (max-width: 767px) {
  .pdfv { --pdfv-h: 70vh; }
  .pdfv-toolbar { justify-content: center; }
  .pdfv-search { order: 5; width: 100%; justify-content: center; }
  .pdfv-find { flex: 1; width: auto; }
  .pdfv-stage { padding: 8px; }
}
@media print { .pdfv { display: none !important; } }

/* Chapter notes (refined explanation) */
.key-points { columns: 2; column-gap: 28px; }
@media (max-width: 991px) { .key-points { columns: 1; } }
.key-points li { break-inside: avoid; }
.pdf-meta { display: flex; flex-wrap: wrap; gap: 8px 16px; font-size: 14px; color: #173b6c; margin-bottom: 10px; }
.pdf-meta span { background: #e4edf9; padding: 3px 10px; }
.legacy-note { background: #fff8e5; border-left: 4px solid #f0ad4e; padding: 10px 14px; margin: 12px 0; font-size: 14.5px; }
.tool-list a { display: flex; gap: 10px; align-items: center; padding: 8px 10px; border: 1px solid #e3e9f2; margin-bottom: 8px; color: #173b6c; }
.tool-list a:hover { border-color: #149ddd; background: #f5f8fd; }
.tool-list a.active { border-color: #149ddd; background: #e4edf9; font-weight: 600; }
.tool-list i { font-size: 22px; color: #d9534f; }
.pdfv-nofile .pdfv-newtab, .pdfv-nofile .pdfv-download { display: none; }
@media (min-width: 992px) {
  .tool-card { position: sticky; top: 20px; }
  .tool-list { max-height: calc(100vh - 60px); overflow-y: auto; }
}
.tool-list a span { line-height: 1.35; }
