/*
 * Bona vortaro's website, in the design of the app (BonaTheme.kt): a page
 * of a printed dictionary by day ("papero"), the night sky by night
 * ("stelnokto"), in Noto Serif, the app's font.
 */

/* Noto Serif (SIL Open Font License, tiparoj/OFL.txt), served by the site
 * itself: no visitor is sent to a font service. Cut down to what the site
 * uses (web/README.md): the weights 400 to 700; the Latin letters, then
 * the twelve of Esperanto apart (3 KB), so that an Esperanto page needs
 * neither the rest of Latin-ext (Čapek, Němcová…) nor its 110 KB */
@font-face {
  font-family: "Noto Serif";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("tiparoj/noto-serif-latin-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Noto Serif";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("tiparoj/noto-serif-eo-normal.woff2") format("woff2");
  unicode-range: U+0108-0109, U+011C-011D, U+0124-0125, U+0134-0135, U+015C-015D, U+016C-016D;
}
@font-face {
  font-family: "Noto Serif";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("tiparoj/noto-serif-latin-ext-normal.woff2") format("woff2");
  unicode-range: U+0100-0107, U+010A-011B, U+011E-0123, U+0126-0133, U+0136-015B, U+015E-016B, U+016E-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Noto Serif";
  font-style: italic;
  font-weight: 400 700;
  font-display: swap;
  src: url("tiparoj/noto-serif-latin-italic.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Noto Serif";
  font-style: italic;
  font-weight: 400 700;
  font-display: swap;
  src: url("tiparoj/noto-serif-eo-italic.woff2") format("woff2");
  unicode-range: U+0108-0109, U+011C-011D, U+0124-0125, U+0134-0135, U+015C-015D, U+016C-016D;
}
@font-face {
  font-family: "Noto Serif";
  font-style: italic;
  font-weight: 400 700;
  font-display: swap;
  src: url("tiparoj/noto-serif-latin-ext-italic.woff2") format("woff2");
  unicode-range: U+0100-0107, U+010A-011B, U+011E-0123, U+0126-0133, U+0136-015B, U+015E-016B, U+016E-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

/* "papero" */
:root {
  --fono: #f4edde;
  --fono-supre: #f4edde;
  --fono-sube: #f4edde;
  --karto: #fffaef;
  --kampo: #fffaef;
  --teksto: #2b2418;
  --kapvorto: #1f5132;
  --pala: #6e5f49;
  --ligilo: #1f5132;
  --sur-ligilo: #fffaef;
  --akcento: #8a4b2a;
  --linio: #d9cdb4;
  --strio: #a8997e;
  --peceto: #e6dcc5;
  --stelo: #0f7a35;
  /* The tinted backgrounds of the chips (primaryContainer, tertiaryContainer) */
  --ligilo-fono: #d9e6d3;
  --akcento-fono: #f2dccd;
  color-scheme: light dark;
}
/* "stelnokto": from the deep navy of the sky to a deep teal; by the
 * system's setting, unless the reader chose one in the settings (Etoso:
 * data-etoso on the page) */
@media (prefers-color-scheme: dark) {
  :root:not([data-etoso="hela"]) {
    --fono: #0c1834;
    --fono-supre: #0a1330;
    --fono-sube: #0d2b33;
    --karto: #101e3e;
    --kampo: rgba(255, 255, 255, 0.10);
    --teksto: #ede6d6;
    --kapvorto: #f1e8d2;
    --pala: #afbbc8;
    --ligilo: #8fd19e;
    --sur-ligilo: #0a1330;
    --akcento: #e2b07a;
    --linio: #2c3a5c;
    --strio: #6f7d95;
    --peceto: #1d2a4a;
    --stelo: #47c26b;
    --ligilo-fono: #1e4a35;
    --akcento-fono: #4a3524;
    color-scheme: dark;
  }
}
:root[data-etoso="malhela"] {
  --fono: #0c1834;
  --fono-supre: #0a1330;
  --fono-sube: #0d2b33;
  --karto: #101e3e;
  --kampo: rgba(255, 255, 255, 0.10);
  --teksto: #ede6d6;
  --kapvorto: #f1e8d2;
  --pala: #afbbc8;
  --ligilo: #8fd19e;
  --sur-ligilo: #0a1330;
  --akcento: #e2b07a;
  --linio: #2c3a5c;
  --strio: #6f7d95;
  --peceto: #1d2a4a;
  --stelo: #47c26b;
  --ligilo-fono: #1e4a35;
  --akcento-fono: #4a3524;
  color-scheme: dark;
}
:root[data-etoso="hela"] { color-scheme: light; }

* { box-sizing: border-box; }
html { background: var(--fono-supre); }
body {
  margin: 0;
  min-height: 100vh;
  background: linear-gradient(180deg, var(--fono-supre) 0%, var(--fono) 45%, var(--fono-sube) 100%) fixed;
  color: var(--teksto);
  /* The text size of the settings scales the page's (its root's) */
  font: 1.125rem/1.6 "Noto Serif", Georgia, "Times New Roman", serif;
}
a { color: var(--ligilo); text-underline-offset: 0.15em; }
main { max-width: 720px; margin: 0 auto; padding: 8px 16px 48px; }

/* The top: the name, then the search field, which stays at the top of
 * the window, as the app's bar, with the tabs under it */
.marko { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; max-width: 720px; margin: 0 auto; padding: 20px 16px 4px; }
.supro { position: sticky; top: 0; z-index: 10; padding: 10px 16px; background: var(--fono-supre); }
.supro .serco-linio { max-width: 688px; margin: 0 auto; }
.nomo { color: var(--kapvorto); font-size: 1.75rem; font-weight: 700; text-decoration: none; letter-spacing: -0.01em; }
.stelo { color: var(--stelo); font-size: 0.7em; margin-left: 0.3em; }
.lau { padding: 8px 0; color: var(--pala); font-style: italic; font-size: 0.9rem; text-decoration: none; }
.lau:hover { text-decoration: underline; }
.serco {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 8px 0 18px;
  border-radius: 999px;
  background: var(--kampo);
  border: 1px solid var(--linio);
}
.serco:focus-within { border-color: var(--ligilo); }
.lupeo { width: 24px; height: 24px; flex: none; fill: var(--pala); }
.serco input {
  flex: 1;
  min-width: 0;
  padding: 14px 4px;
  border: 0;
  background: none;
  color: var(--teksto);
  font: inherit;
  font-size: 1.1rem;
  outline: none;
}
.serco input::-webkit-search-cancel-button { -webkit-appearance: none; }
.serco input::placeholder { color: var(--pala); opacity: 1; }
.vakigi {
  flex: none;
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 50%;
  background: none;
  color: var(--pala);
  font-size: 1.6rem;
  line-height: 1;
  cursor: pointer;
}
.vakigi:hover { background: var(--peceto); }

/* The tabs of the languages: EO, FR… */
.langetoj {
  position: sticky;
  top: var(--supro-alteco, 70px);
  z-index: 9;
  display: flex;
  align-items: center;
  gap: 4px 20px;
  flex-wrap: wrap;
  margin: 0 0 4px;
  padding: 4px 2px 0;
  background: var(--fono-supre);
  /* The bar's colour across the whole window */
  box-shadow: 0 0 0 100vmax var(--fono-supre);
  clip-path: inset(0 -100vmax);
}
.langetoj a, .langetoj strong {
  padding: 4px 2px 6px;
  border-bottom: 3px solid transparent;
  color: var(--pala);
  font-size: 0.95rem;
  letter-spacing: 0.12em;
  text-decoration: none;
}
.langetoj strong { color: var(--kapvorto); border-bottom-color: var(--kapvorto); }
.langetoj select {
  margin-left: auto;
  padding: 4px 8px;
  border: 1px solid var(--linio);
  border-radius: 8px;
  background: var(--karto);
  color: var(--pala);
  font: inherit;
  font-size: 0.9rem;
}

/* The results, as the app's list: the word, then its definition */
.rezultoj { list-style: none; margin: 0; padding: 0; }
.rezultoj li + li { border-top: 1px solid var(--linio); }
.rezultoj a { display: block; padding: 14px 0; color: inherit; text-decoration: none; }
.rezultoj a:hover .linio, .rezultoj a:focus .linio { text-decoration: underline; text-decoration-color: var(--linio); }
.linio { display: block; font-size: 1.25rem; line-height: 1.4; }
.linio b { color: var(--kapvorto); }
.sago { color: var(--pala); font-size: 0.85em; margin: 0 0.2em; }
.rezultoj .difino {
  display: block;
  overflow: hidden;
  color: var(--pala);
  font-style: italic;
  font-size: 1.05rem;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.averto { color: var(--pala); font-style: italic; }
.enkonduko { color: var(--pala); font-style: italic; margin-top: 24px; }

/* The articles: a card for each word, as in the app */
.artikolo-titolo { display: flex; align-items: center; flex-wrap: wrap; gap: 6px 12px; margin: 8px 2px 16px; }
.artikolo-titolo h1 { margin: 0; color: var(--teksto); font-size: 1.6rem; font-weight: 400; }
.vorto {
  position: relative;
  margin: 0 0 16px;
  padding: 14px 16px 16px 22px;
  border: 1px solid var(--linio);
  border-radius: 14px;
  background: var(--karto);
  overflow: hidden;
}
/* The coloured edge on the left of the card */
.vorto::before { content: ""; position: absolute; inset: 0 auto 0 0; width: 4px; background: var(--ligilo); }
/* Opened at a word: below the bar, and lit up for a moment, as in the app */
.vorto, .subartikolo { scroll-margin-top: calc(var(--supro-alteco, 70px) + 12px); }
.vorto:target { animation: emfazo 2.5s ease-out; }
@keyframes emfazo {
  from { background: color-mix(in srgb, var(--ligilo) 16%, var(--karto)); }
  to { background: var(--karto); }
}
/* The word, its badge and its labels on one line, as in the app */
.vorto-kapo { display: flex; align-items: center; flex-wrap: wrap; gap: 6px 10px; margin: 0 0 8px; }
.vorto-kapo h2 { margin: 0; color: var(--kapvorto); font-size: 1.6rem; line-height: 1.25; }
.vorto-kapo .alineo, .vorto-kapo br { display: none; }
.oficiala {
  text-decoration: none;
  padding: 1px 9px;
  border-radius: 8px;
  background: var(--ligilo);
  color: var(--sur-ligilo);
  font-size: 0.95rem;
  font-weight: 700;
  white-space: nowrap;
}
.enhavo { overflow-wrap: break-word; }
/* A new paragraph, "\n\n" in the articles: a gap of its own size */
.alineo { display: block; height: 0.7em; }
.enhavo a:not(.fonto) { text-decoration-thickness: 1px; }

/* The labels: field and kind of word, as chips */
.fako, .gram {
  display: inline-block;
  padding: 0 10px;
  border-radius: 8px;
  font-size: 0.95rem;
  line-height: 1.8;
  white-space: nowrap;
}
.fako { background: var(--peceto); color: var(--teksto); }
.gram { border: 1px solid var(--linio); color: var(--teksto); }
/* The type of a link, "partoj", in its family's colour */
.ligtipo {
  display: inline-block;
  padding: 0 8px;
  border: 1px solid currentColor;
  border-radius: 999px;
  background: var(--ligilo-fono);
  color: var(--ligilo);
  margin-right: 0.3em;
  font-size: 0.85em;
  font-weight: 600;
  line-height: 1.5;
}
.ligtipo.egala { color: var(--akcento); background: var(--akcento-fono); }
.ligtipo.alia { color: var(--pala); background: var(--peceto); }
abbr { text-decoration: none; color: var(--pala); }

/* The examples: in italics, paler, with a line on their left */
.ekz {
  display: block;
  margin: 4px 0 4px 2px;
  padding-left: 14px;
  border-left: 2px solid var(--linio);
  color: var(--pala);
  white-space: normal;
}
.fonto { font-style: normal; font-size: 0.88em; color: var(--pala); }
a.fonto { text-decoration: none; }
a.fonto::after, a.ekstera::after { content: "\00a0↗"; font-size: 0.85em; }
a.fonto:hover { text-decoration: underline; }
.mis { font-style: italic; }
i .mis, .ekz .mis { font-style: normal; }
.rim { display: block; margin: 8px 0; padding: 8px 12px; border-radius: 8px; background: var(--peceto); white-space: normal; }

/* The box of a word's translations */
.tradukoj {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 4px 16px;
  margin-top: 14px;
  padding: 10px 14px;
  border: 1px solid var(--linio);
  border-radius: 12px;
}
.tradukoj > .tradukoj-titolo, .tradukoj > .pliaj-lingvoj { grid-column: 1 / -1; }
.traduko { display: contents; }
.tradukoj-titolo { margin: 0 0 2px; color: var(--ligilo); font-size: 0.85rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; }
.traduko .lingvo { color: var(--pala); font-style: italic; }
.traduko .senco { color: var(--pala); font-size: 0.8em; vertical-align: 0.1em; }
.traduko .ekz { display: inline; margin: 0; padding: 0; border: 0; font-style: italic; }
.js .traduko.kasxita { display: none; }
.pliaj-lingvoj { justify-self: start; min-height: 44px; margin: 0; padding: 0 2px; border: 0; background: none; color: var(--ligilo); font: inherit; font-size: 0.95rem; cursor: pointer; }

/* All the translations by language, at the end, folded */
.aliaj-tradukoj { margin: 8px 0 16px; padding: 10px 16px; border: 1px solid var(--linio); border-radius: 14px; }
.aliaj-tradukoj summary { color: var(--ligilo); cursor: pointer; }
.aliaj-tradukoj h3 { margin: 12px 0 2px; color: var(--pala); font-size: 1rem; font-style: italic; font-weight: 400; }
.aliaj-tradukoj .ekz { display: inline; margin: 0; padding: 0; border: 0; font-style: italic; }
.fonto-artikolo { color: var(--pala); font-size: 0.85rem; font-style: italic; }

@media (max-width: 480px) {
  body { font-size: 1.0625rem; }
  .nomo { font-size: 1.5rem; }
  .lau { font-size: 0.8rem; }
  .vorto { padding: 12px 12px 14px 18px; }
}

/* A part of an article, "I.", over its words */
.subartikolo { margin: 20px 4px 8px; color: var(--pala); font-size: 1.2rem; font-weight: 700; letter-spacing: 0.05em; }

/* The search field and the gear of the settings, as in the app */
.serco-linio { display: flex; align-items: center; gap: 8px; }
/* The way home, the star of the name: it comes into the bar once the name
 * has scrolled away (serco.js), so that it is never shown twice; the
 * search field makes room for it smoothly */
.hejmo-butono {
  flex: none; display: flex; align-items: center; justify-content: center;
  width: 0; height: 44px; margin-right: -8px; overflow: hidden; opacity: 0;
  border-radius: 50%; color: var(--stelo); font-size: 1.6rem; line-height: 1; text-decoration: none;
  transition: width 200ms ease, margin 200ms ease, opacity 200ms ease;
}
.hejmo-butono.videbla { width: 44px; margin-right: 0; opacity: 1; }
.hejmo-butono:hover { background: var(--peceto); }
@media (prefers-reduced-motion: reduce) { .hejmo-butono { transition: none; } }
.serco-linio .serco { flex: 1; min-width: 0; }
.agordoj-butono { flex: none; width: 44px; height: 44px; padding: 8px; border: 0; border-radius: 50%; background: none; cursor: pointer; }
.agordoj-butono svg { width: 28px; height: 28px; fill: var(--pala); }
.agordoj-butono:hover { background: var(--peceto); }
.agordoj-butono[hidden] { display: none; }

/* The icon of a field, the app's, in the colour of the text */
.fako-ikono {
  display: inline-block;
  width: 1.15em;
  height: 1.15em;
  margin-right: 0.35em;
  vertical-align: -0.2em;
  background: currentColor;
  -webkit-mask: no-repeat center / contain;
  mask: no-repeat center / contain;
}

/* Where the word comes from: "deveno" and its line, paler */
.vorto .deveno { margin: 0 0 8px; color: var(--pala); font-size: 0.95rem; line-height: 1.5; }
.fonto-artikolo .deveno { display: inline; }
/* An outlined pill in the grey of its line, as "homonimo" (the app's OriginView) */
.deveno-etikedo { display: inline-block; margin-right: 0.4em; padding: 0 7px; border: 1px solid currentColor; background: var(--peceto); border-radius: 999px; font-size: 0.82em; font-weight: 600; line-height: 1.45; }
.sen-deveno .deveno { display: none; }
.sen-fontoj .ekz .fonto { display: none; }

/* The settings */
.agordoj {
  width: min(560px, calc(100vw - 32px));
  max-height: calc(100vh - 32px);
  padding: 20px 24px;
  border: 1px solid var(--linio);
  border-radius: 16px;
  background: var(--karto);
  color: var(--teksto);
}
.agordoj::backdrop { background: rgba(0, 0, 0, 0.45); }
.agordoj h2 { margin: 0 0 8px; color: var(--kapvorto); font-size: 1.5rem; }
.agordoj h3 { margin: 18px 0 2px; color: var(--ligilo); font-size: 0.85rem; letter-spacing: 0.08em; text-transform: uppercase; }
.agordoj .klarigo { margin: 0 0 8px; color: var(--pala); font-size: 0.9rem; font-style: italic; }
.lingvo-listo { margin: 0 0 8px; padding: 0; list-style: none; border: 1px solid var(--linio); border-radius: 12px; }
.lingvo-listo li { display: flex; align-items: center; gap: 4px; padding: 4px 6px 4px 14px; }
.lingvo-listo li + li { border-top: 1px solid var(--linio); }
.lingvo-listo .malplena { color: var(--pala); font-style: italic; padding: 8px 14px; }
.nomo-de-lingvo { flex: 1; }
.agordoj .ikono { width: 36px; height: 36px; border: 0; border-radius: 50%; background: none; color: var(--pala); font: inherit; cursor: pointer; }
.agordoj .ikono:hover { background: var(--peceto); color: var(--teksto); }
.agordoj select { width: 100%; padding: 8px 10px; border: 1px solid var(--linio); border-radius: 10px; background: var(--karto); color: var(--teksto); font: inherit; }
.elekto { display: flex; align-items: center; gap: 8px; margin: 10px 0; cursor: pointer; }
.elekto input { width: 20px; height: 20px; accent-color: var(--ligilo); }
.agordoj .fermi { display: block; margin: 16px 0 0 auto; padding: 8px 20px; border: 0; border-radius: 999px; background: var(--ligilo); color: var(--sur-ligilo); font: inherit; font-weight: 700; cursor: pointer; }
.ekz-traduko { display: block; margin-top: 2px; font-size: 0.92em; }
.ekz-traduko .ekz { margin-right: 0.4em; color: var(--pala); }
.ekz-traduko .ekz::after { content: " →"; font-style: normal; }

/* While the results come: the old ones fade, after a moment */
main { transition: opacity 0.15s 0.2s; }
main.sxargas { opacity: 0.5; }

/* For screen readers only */
.nevidebla { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

/* The tab "+", which opens the settings */
.langeto-plus { padding: 0 6px 4px; border: 0; background: none; color: var(--pala); font: inherit; font-size: 1.4rem; line-height: 1; cursor: pointer; }
.langeto-plus[hidden] { display: none; }

/* The home page */
.provu { margin: 16px 0; font-size: 1.1rem; }
.provu a { font-weight: 600; }
.konsilo { color: var(--pala); font-size: 0.95rem; }

/* The words of a long article, to go to one */
.vortlisto { margin: 0 2px 16px; }
.vortlisto-ena { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.vortlisto a { padding: 2px 10px; border: 1px solid var(--linio); border-radius: 999px; background: var(--karto); color: var(--teksto); text-decoration: none; font-size: 0.95rem; white-space: nowrap; }
.vortlisto a:hover { border-color: var(--ligilo); }
.vortlisto.faldita .pli { display: none; }
/* A list of 2 or 3 words: only in the margin */
.vortlisto.mallonga { display: none; }
/* The root of the article in each word (rootMarked); the title and the
 * groups only in the margin */
.vortlisto .rad { color: var(--kapvorto); font-weight: 700; }
.vortlisto-titolo, .vortlisto-grupo { display: none; margin: 0; }
.vortlisto-titolo { padding: 0 12px 6px; color: var(--kapvorto); font-weight: 700; }
.vortlisto-titolo span { color: var(--pala); font-weight: 400; font-size: 0.8rem; }
.vortlisto-grupo { margin: 10px 12px 2px; font-size: 0.68rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--ligilo); font-weight: 600; }
.vortlisto-titolo + .vortlisto-grupo { margin-top: 0; }
.vortlisto button { padding: 2px 10px; border: 0; border-radius: 999px; background: none; color: var(--ligilo); font: inherit; font-size: 0.95rem; cursor: pointer; }

/* The foot of the pages */
.piedo { max-width: 720px; margin: 0 auto; padding: 16px 16px 32px; border-top: 1px solid var(--linio); color: var(--pala); font-size: 0.85rem; font-style: italic; }

@media (prefers-reduced-motion: reduce) {
  .vorto:target { animation: none; }
  main { transition: none; }
  .agordoj[open], .agordoj[open]::backdrop { animation: none !important; }
  body, html.kun-panelo body { transition: none !important; }
}
.alia-lingvo { font-style: italic; margin: 10px 0 4px; }

/* Vikivortaro: its translations dotted under, its words not bold, as in the app */
.viki { text-decoration: underline dotted var(--pala); text-underline-offset: 0.2em; }
.vikivorto { color: var(--kapvorto); }
.malrekomendata {
  display: inline-block;
  margin-left: 0.3em;
  padding: 0 8px;
  border: 1px solid var(--linio);
  border-radius: 8px;
  color: var(--pala);
  font-size: 0.8rem;
  font-weight: 400;
  vertical-align: 0.15em;
}
.rezultoj .konsilo { white-space: normal; }
.rezultoj .konsilo b { color: var(--kapvorto); font-style: normal; }
/* The page of a word only Vikivortaro has */
.kapvorto-viki { margin: 0; color: var(--kapvorto); font-size: 1.6rem; font-weight: 400; }
.fonto-linio { margin: 0 0 8px; color: var(--pala); font-size: 0.9rem; font-style: italic; }
.sencoj { margin: 8px 0; padding-left: 1.5em; }
/* How a word only Wiktionary has is built, under its words, as the app's
 * CompactAnalysis */
.analizo-kompakta { margin-top: 12px; padding-top: 10px; border-top: 1px solid var(--linio); color: var(--pala); font-size: 0.9rem; }
.analizo-kompakta p { margin: 0; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.analizo-kompakta .analizo-trancxo { font-style: italic; font-size: 1rem; margin-bottom: 2px; }
.analizo-kompakta a { color: var(--teksto); text-decoration: underline; text-underline-offset: 0.15em; }
.analizo-kompakta .analizo-noto { font-style: italic; opacity: 0.55; margin-top: 6px; }
.priskribo { display: block; color: var(--pala); font-style: italic; }
.propono { font-size: 1.1rem; }
.propono a { font-weight: 700; }

/* How a word may be built, as the app's: a guess, in grey, as a pencilled
 * note, with only what can be opened marked */
.analizo { color: var(--pala); font-style: italic; margin: 0.5rem 0 1rem; max-width: 40rem; }
.analizo p { margin: 0; }
.analizo-eble { padding-top: 0.5rem; }
.analizo-vorto { font-size: 1.5rem; padding: 0.25rem 0 0.5rem; }
.analizo .nerekonita { opacity: 0.55; }
.analizo-eroj { list-style: none; margin: 0; padding: 0; border-bottom: 1px solid var(--linio); }
.analizo-eroj li { border-top: 1px solid var(--linio); padding: 0.5rem 0; font-style: normal; }
.analizo-eroj a, .analizo-eroj .etikedo { display: block; color: var(--teksto); font-size: 1.1rem; }
.analizo-eroj a { text-decoration: underline; text-underline-offset: 0.15em; }
.analizo-eroj .gloso {
  display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-clamp: 2; overflow: hidden;
  font-style: italic;
}
.analizo button {
  display: block; font: inherit; color: inherit; background: none; border: 0; padding: 0.6rem 0; cursor: pointer; text-align: left;
}
.analizo-pli { color: var(--ligilo) !important; font-style: normal; }
.analizo-alia { width: 100%; font-size: 1.05rem; }
.analizo-noto { font-size: 0.85rem; opacity: 0.55; padding-top: 0.75rem; }
.ne-en-vortaro { color: var(--pala); font-size: 1.1rem; }

/* The history, on the search page while nothing is typed */
.historio h2 { margin: 16px 0 4px; color: var(--ligilo); font-size: 0.85rem; letter-spacing: 0.08em; text-transform: uppercase; }
.historio .rezultoj li { display: flex; align-items: center; }
.historio .rezultoj a { flex: 1; min-width: 0; }
.historio .forigi { flex: none; width: 44px; height: 44px; border: 0; border-radius: 50%; background: none; color: var(--pala); font-size: 1.4rem; cursor: pointer; }
.historio .forigi:hover { background: var(--peceto); }
.forvisxi { margin: 8px 0 16px; padding: 6px 0; border: 0; background: none; color: var(--ligilo); font: inherit; font-size: 0.95rem; cursor: pointer; }

/* The shortcut of the theme, a moon or a sun, beside the gear */
.etoso-butono { flex: none; width: 44px; height: 44px; padding: 10px; border: 0; border-radius: 50%; background: none; cursor: pointer; }
.etoso-butono svg { width: 24px; height: 24px; fill: var(--pala); }
.etoso-butono:hover { background: var(--peceto); }
.etoso-butono[hidden] { display: none; }
.agordoj .elektoj { display: flex; flex-wrap: wrap; gap: 4px 16px; }
.agordoj .grandeco { display: flex; align-items: center; gap: 12px; }
.agordoj .grandeco input { flex: 1; accent-color: var(--ligilo); }
.agordoj .ekzemplo { margin: 4px 0 0; color: var(--pala); }
.etoso-butono .suno { display: none; }
:root[data-etoso="malhela"] .etoso-butono .suno { display: inline; }
:root[data-etoso="malhela"] .etoso-butono .luno { display: none; }
@media (prefers-color-scheme: dark) {
  :root:not([data-etoso="hela"]) .etoso-butono .suno { display: inline; }
  :root:not([data-etoso="hela"]) .etoso-butono .luno { display: none; }
}

/* "Foliumi la vortaron": the roots before and after, and one at random,
 * as at the end of the app's articles */
.najbaroj { max-width: 720px; margin: 8px auto 24px; padding: 0 16px; }
.najbaroj-titolo { display: flex; align-items: center; gap: 10px; margin: 0 0 8px; color: var(--pala); font-size: 0.9rem; font-style: italic; }
.najbaroj-titolo::before, .najbaroj-titolo::after { content: ""; flex: 1; border-top: 1px solid var(--linio); }
.najbaroj-kartoj { display: flex; gap: 8px; align-items: stretch; }
.najbaro { flex: 1; min-width: 0; display: flex; flex-direction: column; padding: 10px 12px; border: 1px solid var(--linio); border-radius: 12px; background: var(--karto); color: inherit; text-decoration: none; }
.najbaro.sekva { text-align: right; }
.najbaro.malplena { visibility: hidden; }
.najbaro:hover, .hazarda:hover { border-color: var(--ligilo); }
.najbaro-etikedo { color: var(--pala); font-size: 0.8rem; }
.najbaro-radiko { overflow: hidden; color: var(--kapvorto); font-weight: 700; white-space: nowrap; text-overflow: ellipsis; }
.najbaro-difino { display: -webkit-box; overflow: hidden; color: var(--pala); font-size: 0.85rem; font-style: italic; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.hazarda { flex: none; width: 84px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; padding: 8px; border: 1px solid var(--linio); border-radius: 12px; background: var(--karto); color: var(--kapvorto); text-decoration: none; font-size: 0.75rem; text-align: center; }
.kubo { width: 30px; height: 30px; fill: currentColor; }
/* On the search page, before anything is typed: a root to discover */
.hazarda-radiko { display: flex; align-items: center; gap: 16px; margin: 12px 0; padding: 14px 16px; border: 1px solid var(--linio); border-radius: 12px; background: var(--karto); color: inherit; text-decoration: none; }
.hazarda-radiko:hover { border-color: var(--ligilo); }
.hazarda-radiko .kubo { flex: none; color: var(--kapvorto); }
.hazarda-radiko b { display: block; color: var(--kapvorto); }
.hazarda-radiko span { color: var(--pala); font-size: 0.9rem; font-style: italic; }

/* The pages "Pri" */
.pagxo { max-width: 680px; }
.pagxo h1 { color: var(--kapvorto); font-size: 1.8rem; margin: 8px 0 12px; }
.pagxo h2 { color: var(--kapvorto); font-size: 1.25rem; margin: 24px 0 6px; }
.pagxo h3 { color: var(--kapvorto); font-size: 1.1rem; margin: 18px 0 4px; }
.pagxo .jaro { color: var(--pala); font-weight: 400; }
.pagxo .ligiloj { display: flex; flex-wrap: wrap; gap: 4px 16px; }
.citajxo { margin: 16px 0; padding: 0 0 0 16px; border-left: 3px solid var(--ligilo); }
.citajxo p { margin: 0; color: var(--kapvorto); font-size: 1.2rem; font-style: italic; }
.citajxo footer { color: var(--pala); font-size: 0.95rem; }
.aldono details { margin: 4px 0 8px; }
.aldono summary { color: var(--ligilo); cursor: pointer; }
.oficiala-listo { columns: 2 14em; margin: 8px 0; padding-left: 1.2em; font-size: 0.95rem; }
.pri-ligiloj { font-style: normal; }
.pri-listo { margin: 0; padding-left: 1.2em; }
.pri-listo li { margin: 4px 0; }

/* Translations once the reader chose their languages */
.neniu-traduko { grid-column: 1 / -1; justify-self: start; padding: 4px 0; border: 0; background: none; color: var(--pala); font: inherit; font-size: 0.95rem; font-style: italic; cursor: pointer; }
.neniu-traduko:hover { color: var(--ligilo); }
.ciuj-lingvoj { margin: 4px 2px 12px; color: var(--pala); font-style: italic; }
.ciuj-lingvoj .ligilo { padding: 6px 0; border: 0; background: none; color: var(--ligilo); font: inherit; text-decoration: underline; text-underline-offset: 0.15em; cursor: pointer; }

/* The menu of the tab "+": the languages of the search, in place */
.lingvo-menuo { position: fixed; z-index: 20; padding: 12px; border: 1px solid var(--linio); border-radius: 12px; background: var(--karto); box-shadow: 0 10px 30px rgb(0 0 0 / 0.18); font-size: 0.95rem; }
.lingvo-menuo .menuo-titolo { margin: 0 0 6px; color: var(--ligilo); font-size: 0.8rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; }
.lingvo-menuo .elektitaj { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 8px; }
.lingvo-menuo .pilolo { padding: 2px 10px; border: 1px solid var(--ligilo); border-radius: 999px; background: var(--ligilo-fono); color: var(--ligilo); font: inherit; font-size: 0.9rem; cursor: pointer; }
.lingvo-menuo input { width: 100%; padding: 6px 10px; border: 1px solid var(--linio); border-radius: 8px; background: var(--fono); color: var(--teksto); font: inherit; }
.lingvo-menuo .trovitaj { margin: 6px 0; padding: 0; list-style: none; }
.lingvo-menuo .trovitaj button { width: 100%; padding: 6px 8px; border: 0; border-radius: 6px; background: none; color: var(--teksto); font: inherit; text-align: left; cursor: pointer; }
.lingvo-menuo .trovitaj button:hover, .lingvo-menuo .trovitaj button:focus-visible { background: var(--peceto); }
.lingvo-menuo .malplena { padding: 6px 8px; color: var(--pala); font-style: italic; }
.lingvo-menuo .klarigo { margin: 4px 0 0; color: var(--pala); font-size: 0.85rem; font-style: italic; }

/* The settings: a panel beside the page on a wide screen, a sheet from
 * the bottom on a phone */
.agordoj.panelo { position: fixed; inset: 0 0 0 auto; z-index: 30; width: 380px; max-width: none; height: 100vh; max-height: none; margin: 0; border: 0; border-left: 1px solid var(--linio); border-radius: 0; box-shadow: -8px 0 30px rgb(0 0 0 / 0.12); overflow-y: auto; }
@media (max-width: 999px) {
  .agordoj { width: 100%; max-width: 100%; max-height: 85vh; margin: auto 0 0; border-radius: 16px 16px 0 0; }
}
html.kun-panelo body { padding-right: 380px; }

/* Opening and closing (user, 2026-12-01), as Material's sheets: the panel
 * slides in from the side, the page making room at the same pace; the
 * sheet from the bottom, over a backdrop that darkens. A decelerating
 * curve to come in, an accelerating one, shorter, to go */
.agordoj[open] { animation: agordoj-el-sube 300ms cubic-bezier(0.05, 0.7, 0.1, 1); }
.agordoj[open]::backdrop { animation: agordoj-malheligxo 300ms ease-out; }
.agordoj.panelo[open] { animation-name: agordoj-el-flanko; }
.agordoj.eliras[open] { animation: agordoj-al-sube 200ms cubic-bezier(0.3, 0, 0.8, 0.15) forwards; }
.agordoj.eliras[open]::backdrop { animation: agordoj-heligxo 200ms ease-in forwards; }
.agordoj.panelo.eliras[open] { animation-name: agordoj-al-flanko; }
@keyframes agordoj-el-sube { from { transform: translateY(100%); } }
@keyframes agordoj-al-sube { to { transform: translateY(100%); } }
@keyframes agordoj-el-flanko { from { transform: translateX(100%); } }
@keyframes agordoj-al-flanko { to { transform: translateX(100%); } }
@keyframes agordoj-malheligxo { from { opacity: 0; } }
@keyframes agordoj-heligxo { to { opacity: 0; } }
@media (min-width: 1000px) {
  body { transition: padding-right 200ms cubic-bezier(0.3, 0, 0.8, 0.15); }
  html.kun-panelo body { transition: padding-right 300ms cubic-bezier(0.05, 0.7, 0.1, 1); }
}

/* From 1200 px: the words of the article in the left margin, in view while
 * it is read, the one being read marked; the article keeps its place. With
 * the settings open beside the page (380 px), only from 1580 px, where
 * there is still room for it: else at the top, as on a narrower screen */
@media (min-width: 1200px) {
  html:not(.kun-panelo) article { position: relative; }
  html:not(.kun-panelo) .vortlisto { position: absolute; top: 0; right: calc(100% + 32px); width: 200px; height: 100%; margin: 0; display: block; }
  html:not(.kun-panelo) .vortlisto-ena { position: sticky; top: calc(var(--supro-alteco, 70px) + 16px); display: flex; flex-direction: column; align-items: stretch; gap: 1px; max-height: calc(100vh - var(--supro-alteco, 70px) - 32px); overflow-y: auto; padding: 4px 0; }
  html:not(.kun-panelo) .vortlisto a { padding: 3px 12px; border: 0; border-radius: 8px; background: none; color: var(--pala); white-space: normal; }
  html:not(.kun-panelo) .vortlisto a:hover { background: var(--peceto); }
  html:not(.kun-panelo) .vortlisto a.nuna { color: var(--kapvorto); background: var(--ligilo-fono); }
  /* All of them: the list scrolls */
  html:not(.kun-panelo) .vortlisto.faldita .pli { display: block; }
  html:not(.kun-panelo) .vortlisto-titolo, html:not(.kun-panelo) .vortlisto-grupo { display: block; }
  html:not(.kun-panelo) .vortlisto button { display: none; }
}
@media (min-width: 1580px) {
  html.kun-panelo article { position: relative; }
  html.kun-panelo .vortlisto { position: absolute; top: 0; right: calc(100% + 32px); width: 200px; height: 100%; margin: 0; display: block; }
  html.kun-panelo .vortlisto-ena { position: sticky; top: calc(var(--supro-alteco, 70px) + 16px); display: flex; flex-direction: column; align-items: stretch; gap: 1px; max-height: calc(100vh - var(--supro-alteco, 70px) - 32px); overflow-y: auto; padding: 4px 0; }
  html.kun-panelo .vortlisto a { padding: 3px 12px; border: 0; border-radius: 8px; background: none; color: var(--pala); white-space: normal; }
  html.kun-panelo .vortlisto a:hover { background: var(--peceto); }
  html.kun-panelo .vortlisto a.nuna { color: var(--kapvorto); background: var(--ligilo-fono); }
  /* All of them: the list scrolls */
  html.kun-panelo .vortlisto.faldita .pli { display: block; }
  html.kun-panelo .vortlisto-titolo, html.kun-panelo .vortlisto-grupo { display: block; }
  html.kun-panelo .vortlisto button { display: none; }
}
