/* gateway-v2/assets/learn-trend.css — WHAT LEARNERS ARE DOING NOW (4 Nov 2026), prefix lrt-. Engine includes/learn/lrn-trend.php.
   The landing block (#trending), the course page row (.lrt-crow), the lesson player's "Popular in …" line (.lp-end-tr) and the
   Dictionary's trending lists. Everything is server-rendered (no fill, no layout shift). Gold #ffcf5e on dark; #7a5600 in light,
   only through :root[data-theme="light"] (never the system colour-scheme query). Country plates are two letters, never emoji flags. */

/* ── the landing block ── */
.lrt { position: relative; margin: 0 0 clamp(56px, 7vw, 112px); }
.lrt-h { margin-bottom: clamp(16px, 2vw, 26px); }
.lrt-you { display: flex; align-items: center; gap: 10px; margin: 0 0 14px; padding: 10px 14px; border-radius: 14px; border: 1px solid rgba(255,207,94,.35); background: rgba(255,207,94,.06); font: 400 15px/1.45 var(--st-ui, Inter, sans-serif); color: var(--st-ink-2, rgba(243,245,251,.86)); }
.lrt-you b { color: var(--st-ink, #f3f5fb); font-weight: 650; }
.lrt-g { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; align-items: stretch; }
.lrt-g--nocourse { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.lrt-c { display: flex; flex-direction: column; min-width: 0; padding: 18px 18px 14px; border: 1px solid var(--st-rule, rgba(255,255,255,.1)); border-radius: 20px; background: var(--st-card, #0d1322); }
.lrt-k { margin: 0 0 10px; font: 700 11.5px/1.2 var(--st-ui, Inter, sans-serif); letter-spacing: .12em; text-transform: uppercase; color: var(--st-ink-3, rgba(243,245,251,.72)); }
.lrt-k span { letter-spacing: .06em; text-transform: none; font-weight: 500; color: var(--st-ink-3, rgba(243,245,251,.6)); }
.lrt-list, .lrt-cl, .lrt-nl, .lrt-mini, .lrt-dl { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.lrt-list a, .lrt-cl a, .lrt-nl a, .lrt-mini a, .lrt-dl a { display: grid; align-items: center; gap: 10px; min-height: 48px; padding: 6px 8px; margin: 0 -8px; border-radius: 12px; color: inherit; text-decoration: none; transition: background .2s; }
.lrt-list a:hover, .lrt-cl a:hover, .lrt-nl a:hover, .lrt-mini a:hover, .lrt-dl a:hover { background: rgba(255,207,94,.07); }
.lrt-list a:focus-visible, .lrt-cl a:focus-visible, .lrt-nl a:focus-visible, .lrt-mini a:focus-visible, .lrt-dl a:focus-visible { outline: 2px solid #ffcf5e; outline-offset: 1px; }
.lrt-list a { grid-template-columns: 24px minmax(0, 1fr) auto; }
/* 12 Nov 2026: the three cards are one height and every row is the same two-line shape (title over detail, figure over its
   word); a longer list scrolls inside its card, with a soft fade at the edge while there is more to see */
.lrt-sc { flex: 1 1 auto; max-height: 340px; margin: 0 -8px; padding: 0 8px; overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin; scrollbar-color: rgba(255,207,94,.35) transparent;
  -webkit-mask-image: linear-gradient(to bottom, #000 calc(100% - 28px), transparent); mask-image: linear-gradient(to bottom, #000 calc(100% - 28px), transparent); }
.lrt-sc:focus-visible { outline: 2px solid #ffcf5e; outline-offset: 2px; border-radius: 12px; }
.lrt-sc::-webkit-scrollbar { width: 6px; }
.lrt-sc::-webkit-scrollbar-thumb { border-radius: 6px; background: rgba(255,207,94,.35); }
.lrt-sc::-webkit-scrollbar-track { background: transparent; }
.lrt-sc > ol, .lrt-sc > ul { padding-bottom: 22px; }
.lrt-list a, .lrt-cl a, .lrt-nl a { box-sizing: border-box; min-height: 58px; align-content: center; }
.lrt-v, .lrt-cv { min-width: 72px; }
.lrt-t small .lrt-rise { margin-left: 4px; padding: 1px 6px; font-size: 9.5px; vertical-align: 1px; }
.lrt-i { display: inline-grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; border: 1px solid rgba(255,207,94,.45); font: 700 12px/1 var(--st-ui, Inter, sans-serif); color: #ffcf5e; font-variant-numeric: tabular-nums; }
.lrt-t { min-width: 0; display: grid; gap: 2px; }
.lrt-t b, .lrt-nl b, .lrt-mini b, .lrt-dl b { font: 650 15px/1.3 var(--st-ui, Inter, sans-serif); overflow-wrap: anywhere; }
.lrt-t small, .lrt-nl small, .lrt-mini small, .lrt-dl small, .lrt-cv small { font: 400 12.5px/1.3 var(--st-ui, Inter, sans-serif); color: var(--st-ink-3, rgba(243,245,251,.68)); }
.lrt-v { display: grid; justify-items: end; gap: 3px; font: 400 12.5px/1.2 var(--st-ui, Inter, sans-serif); color: var(--st-ink-3, rgba(243,245,251,.7)); white-space: nowrap; }
.lrt-v b, .lrt-cv b { font: 700 15px/1.1 var(--st-ui, Inter, sans-serif); color: #ffcf5e; font-variant-numeric: tabular-nums; }
.lrt-rise { display: inline-block; padding: 2px 7px; border-radius: 999px; border: 1px solid rgba(255,207,94,.5); font: 700 10.5px/1.3 var(--st-ui, Inter, sans-serif); letter-spacing: .06em; text-transform: uppercase; color: #ffcf5e; }
.lrt-cl a { grid-template-columns: 36px minmax(0, 1fr) auto; }
.lrt-cl li.is-here a { background: rgba(255,207,94,.06); }
.lrt-cc { display: inline-grid; place-items: center; min-width: 30px; height: 20px; padding: 0 4px; border-radius: 5px; border: 1px solid rgba(255,207,94,.55); background: rgba(255,207,94,.08); font: 700 11px/1 var(--st-ui, Inter, sans-serif); letter-spacing: .06em; color: #ffcf5e; }
.lrt-cn { display: block; min-width: 0; font: 650 15px/1.3 var(--st-ui, Inter, sans-serif); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lrt-cv { display: grid; justify-items: end; gap: 2px; white-space: nowrap; font: 400 12.5px/1.2 var(--st-ui, Inter, sans-serif); color: var(--st-ink-3, rgba(243,245,251,.7)); }
.lrt-nl a, .lrt-mini a { grid-template-columns: minmax(0, 1fr); gap: 2px; }
.lrt-note { margin: 12px 0 0; font: 400 12.5px/1.45 var(--st-ui, Inter, sans-serif); color: var(--st-ink-3, rgba(243,245,251,.62)); }
@media (max-width: 1100px) { .lrt-g { grid-template-columns: repeat(2, minmax(0, 1fr)); } .lrt-courses { grid-column: 1 / -1; } }
@media (max-width: 700px) {
  .lrt-g, .lrt-g--nocourse { grid-template-columns: minmax(0, 1fr); gap: 10px; }
  .lrt-c { padding: 14px 14px 10px; border-radius: 16px; }
  .lrt-sc { max-height: 300px; }
}

/* ── the course page row ── */
.lrt-crow { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); align-items: start; gap: 14px; margin: 28px 0 0; }
.lrt-box { min-width: 0; padding: 16px 16px 10px; border-radius: 16px; border: 1px solid var(--st-rule, rgba(255,255,255,.1)); background: var(--st-card, #0d1322); }
.lrt-bh { margin: 0 0 6px; font: 700 15px/1.3 var(--st-ui, Inter, sans-serif); }

/* ── "Lesson complete": one line; the end screen keeps fitting the stage (the 4 Nov short-screen rules in learn-blocks.css) ── */
.lp-end-tr { max-width: 100%; margin: 12px 0 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font: 400 14px/1.4 var(--st-ui, Inter, sans-serif); color: var(--lp-ink2, rgba(243,245,251,.8)); }
.lp-end-tr a { color: var(--lp-acc, #ffcf5e); font-weight: 650; text-underline-offset: 3px; }
@media (max-height: 820px) { .lp-end-tr { margin-top: 8px; } }
@media (max-height: 640px) { .lp-end-tr { display: none; } }

/* ── the Dictionary ── */
.lrt-dsub { margin: -4px 0 12px; font: 400 14px/1.5 var(--st-ui, Inter, sans-serif); color: var(--st-ink-3, rgba(243,245,251,.7)); }
.lrt-dl { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2px 18px; }
.lrt-dl a { grid-template-columns: 24px minmax(0, 1fr) auto; margin: 0; }
@media (max-width: 700px) { .lrt-dl { grid-template-columns: minmax(0, 1fr); } }

/* ── light theme (opt-in only) ── */
:root[data-theme="light"] .lrt-c, :root[data-theme="light"] .lrt-box { background: #fff; border-color: rgba(16,19,28,.12); }
:root[data-theme="light"] .lrt-you { background: #fff8e6; border-color: rgba(122,86,0,.35); color: #2c3140; }
:root[data-theme="light"] .lrt-you b { color: #10131c; }
:root[data-theme="light"] .lrt-k, :root[data-theme="light"] .lrt-k span, :root[data-theme="light"] .lrt-t small, :root[data-theme="light"] .lrt-nl small, :root[data-theme="light"] .lrt-mini small, :root[data-theme="light"] .lrt-dl small, :root[data-theme="light"] .lrt-cv, :root[data-theme="light"] .lrt-cv small, :root[data-theme="light"] .lrt-v, :root[data-theme="light"] .lrt-note, :root[data-theme="light"] .lrt-dsub { color: #4f5566; }
:root[data-theme="light"] .lrt-i, :root[data-theme="light"] .lrt-v b, :root[data-theme="light"] .lrt-cv b, :root[data-theme="light"] .lrt-rise, :root[data-theme="light"] .lrt-cc, :root[data-theme="light"] .lp-end-tr a { color: #7a5600; }
:root[data-theme="light"] .lrt-i, :root[data-theme="light"] .lrt-rise, :root[data-theme="light"] .lrt-cc { border-color: rgba(122,86,0,.55); }
:root[data-theme="light"] .lrt-cc { background: #fff8e6; }
:root[data-theme="light"] .lrt-list a:hover, :root[data-theme="light"] .lrt-cl a:hover, :root[data-theme="light"] .lrt-nl a:hover, :root[data-theme="light"] .lrt-mini a:hover, :root[data-theme="light"] .lrt-dl a:hover, :root[data-theme="light"] .lrt-cl li.is-here a { background: #fbf6e8; }
:root[data-theme="light"] .lrt-list a:focus-visible, :root[data-theme="light"] .lrt-cl a:focus-visible, :root[data-theme="light"] .lrt-nl a:focus-visible, :root[data-theme="light"] .lrt-mini a:focus-visible, :root[data-theme="light"] .lrt-dl a:focus-visible { outline-color: #7a5600; }
:root[data-theme="light"] .lp-end-tr { color: #2c3140; }
:root[data-theme="light"] .lrt-sc { scrollbar-color: rgba(122,86,0,.4) transparent; }
:root[data-theme="light"] .lrt-sc::-webkit-scrollbar-thumb { background: rgba(122,86,0,.4); }
:root[data-theme="light"] .lrt-sc:focus-visible { outline-color: #7a5600; }
@media (prefers-reduced-motion: reduce) { .lrt-list a, .lrt-cl a, .lrt-nl a, .lrt-mini a, .lrt-dl a { transition: none; } }
