/* Nội dung › Khóa học: a drill's page (frontend/panel/content/drills/). Values
   from output/reference/behaviours/content-courses.md, cited per block. */

.dr {
  display: flex;
  flex-direction: column;
  height: 100%;
}

/* The bar's book and tape choices (courses#129, #130; md:L1938–1978). */
/* Book and tape in the toolbar as the reference's small outlined selects, the label on the top border
   (md:L1935–1985: FormControl size small, outlined, with its InputLabel), so they fit the app bar (N142). */
.dr-choice {
  position: relative;
  display: flex;
  flex-shrink: 0;
  margin-left: 12px;
}

.dr-choice-label {
  position: absolute;
  top: -7px;
  left: 8px;
  z-index: 1;
  padding: 0 4px;
  background: var(--surface);
  color: color-mix(in srgb, var(--ink) 60%, transparent);
  font-size: 11px;
  line-height: 14px;
  pointer-events: none;
}

.dr-select {
  width: 240px;
  height: 28px;
  padding: 0 6px;
  font-size: 14px;
}

@media (max-width: 900px) {
  .dr-select {
    width: 140px;
  }
}

/* The PDF beside a 400 px tape column; the column alone without a PDF (courses#132; md:L2260–2372). */
.dr-body {
  display: flex;
  flex: 1 1 0%;
  min-height: 0;
}

.dr-pdf {
  flex: 1 1 0%;
  min-width: 0;
}

.dr.no-pdf .dr-pdf {
  display: none;
}

.dr.no-pdf .dr-body {
  justify-content: flex-end;
}

.dr-pdf-frame {
  width: 100%;
  height: 100%;
  border: 0;
  /* Seen only until Chrome's PDF viewer paints its own ground: the look's surface, not a white flash in dark. */
  background: var(--surface);
}

/* A course's lesson text in the book's place (drills/page.js sideTextView; chinese-japanese.md Z-E2). */
.dr-text {
  display: flex;
  flex-direction: column;
  height: 100%;
  min-height: 0;
  font-size: 17px;
}

.dr-text-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 20px;
  border-bottom: 1px solid var(--line-soft);
  font-size: 15px;
}

.dr-text-title {
  color: var(--text-strong);
  font-weight: 600;
}

/* Its size comes from .dr-text, so a Chinese or Japanese text's .is-bigger-script (1.2em, panel.css) applies. */
.dr-text-body {
  flex: 1 1 0%;
  overflow-y: auto;
  padding: 16px 24px 32px;
  color: var(--text);
  line-height: 1.7;
}

.dr-text-body p {
  margin: 0 0 6px;
}

.dr-text-body .dr-text-gap {
  height: 10px;
}

.dr-column {
  flex: 0 0 400px;
  width: 400px;
  border-left: 1px solid var(--bg);
}

@media (max-width: 900px) {
  .dr-column {
    flex: 1 1 auto;
    width: 100%;
    border-left: 0;
  }
}

/* While the PDF holds the keys (courses#140; md:L2199–2259). */
.dr-keys-cover {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  border: 0;
  background: rgba(13, 13, 15, 0.85);
  color: var(--on-media);
  font: 500 16px/1.4 var(--font);
  cursor: pointer;
}

.dr-keys-cover[hidden] {
  display: none;
}

.dr-pdf-links {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding-left: 18px;
}

/* The lines in the 400 px column fill it, as every recording's do (ix:L116768), with a narrower play column. */
.dr-column .rd-play {
  flex-basis: 33px;
}

.dr-column .rd-trans-side {
  padding-left: 12px;
}
