/* learnmingo.com - /glossary/: the public Glossary's own styles (hand-written; the pages are generated by build-glossary.py).
   The site's type and tokens (site.css --w-*, read from palette.css): no color is written here. One column: the search field,
   the level links (pills: a filter, never a button), the head line (the page's h1 `HSK n Chinese words`, the count, Sign in to
   mark words where the app has its marker) and the rows: word (a link to its word page, /word/), pinyin, meaning, HSK level.
   At 640px and under a row is two lines: word, pinyin and level, then the meaning. */

.wrap-gl { max-width: 860px; flex: 1; }
.gl { padding: 32px 0 96px; }

/* the search field: the contact form's field, with the browser's own clear button; it opens the page (the h1 is the level's, in
   the head line over the rows) */
.gl-search { margin: 24px 0 16px; }
.gl-search input {
  width: 100%; height: 44px; padding: 0 16px; margin: 0;
  font: 17px/1.47 var(--w-font); color: var(--w-ink);
  background: var(--w-card); border: 1px solid var(--page-rule); border-radius: 980px; box-shadow: none;   /* a field typed in: white inside its hairline on the off-white ground */
  -webkit-appearance: none; appearance: none;
}
.gl-search input::placeholder { color: var(--w-ink-2); opacity: 1; }
.gl-search input:focus-visible { outline: none; border-color: var(--w-current); box-shadow: none; }   /* (2026-11-21: the field's focus is its Current hairline alone, no halo - the kit field's look, ui/ridge.css .rg-edit) */

/* the level links */
.gl-levels { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 28px; }
.gl-levels a, .gl-pages a {
  display: inline-flex; align-items: center; justify-content: center; height: 34px; padding: 0 14px; border-radius: 980px;
  background: var(--w-in); color: var(--w-ink); font-size: 14px; line-height: 1; white-space: nowrap; text-decoration: none;
}
.gl-levels a:hover, .gl-pages a:hover { background: var(--w-in-hov); text-decoration: none; }
.gl-levels a[aria-current], .gl-pages a[aria-current] { background: var(--w-ink); color: var(--w-ground); }
:where(:root:not([data-focus="pointer"])) .gl-levels a:focus-visible, :where(:root:not([data-focus="pointer"])) .gl-pages a:focus-visible { border-radius: 980px; }

/* the head line: the level (or Search results), how many words, and the way to the marker */
.gl-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 14px; padding: 0 0 12px; border-bottom: 1px solid var(--w-rule); }
.gl-head h1 { margin: 0; font-family: var(--w-display); font-weight: 600; font-size: clamp(26px, 20px + 1vw, 34px); letter-spacing: -.024em; line-height: 1.1; }
.gl-count { font-size: 15px; color: var(--w-ink-2); font-variant-numeric: tabular-nums; }
.gl-mark { margin-left: auto; font-size: 15px; }
.gl-mark:not([data-painted]) { visibility: hidden; }   /* glossary.js paints the right words at once (the reader remembered on this browser) */
:where(:root:not([data-focus="pointer"])) .gl-mark:focus-visible { border-radius: 4px; }

/* the rows */
.gl-rows { list-style: none; margin: 0; padding: 0; }
.gl-rows li {
  display: grid; grid-template-columns: 132px 190px minmax(0, 1fr) auto; align-items: baseline; column-gap: 20px;
  padding: 11px 0; border-bottom: 1px solid var(--w-rule);
}
.gl-w { font: 400 24px/1.25 var(--w-zh); color: var(--w-ink); }
a.gl-w { color: var(--w-current); justify-self: start; }   /* the word is a link to its page: the site's link color, its underline on hover (site.css a:hover); only the word itself takes the click */
.gl-p { font-size: 16px; color: var(--w-ink); overflow-wrap: anywhere; }
.gl-e { font-size: 16px; color: var(--w-ink); overflow-wrap: anywhere; }
.gl-l { font-size: 13px; color: var(--w-ink-2); white-space: nowrap; font-variant-numeric: tabular-nums; }

.gl-more {
  display: block; margin: 24px auto 0; height: 40px; padding: 0 18px; border: 0; border-radius: var(--w-radius-btn);
  background: var(--w-in); color: var(--w-ink); font: 400 15px/1 var(--w-font); cursor: pointer;
}
.gl-more:hover { background: var(--w-in-hov); }

/* the pages of a long level */
.gl-pages { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin: 28px 0 0; }
.gl-pages a { min-width: 34px; padding: 0 10px; font-variant-numeric: tabular-nums; }

@media (max-width: 640px) {
  .wrap-gl { padding: 0 20px; }
  .gl-search { margin-top: 16px; }
  .gl-mark { margin-left: 0; flex-basis: 100%; }
  .gl-rows li { grid-template-columns: auto minmax(0, 1fr) auto; column-gap: 12px; row-gap: 2px; }
  .gl-w { font-size: 22px; }
  .gl-e { grid-column: 1 / -1; grid-row: 2; }
}
@media (pointer: coarse) {
  .gl-search input { font-size: 16px; }
  .gl-levels a, .gl-pages a { height: 44px; padding: 0 16px; }
  .gl-pages a { min-width: 44px; }
  .gl-mark { display: inline-block; padding: 12px 0; margin-top: -12px; margin-bottom: -12px; }
  .gl-more { height: 44px; }
}
