/* =========================================================================
   DentalEd - site theme, design "Faculty" (chosen by Maros 1.12.2026 from
   three variants; the comparison is in outputs/spravca_dentaled/dizajn/).
   Idea: a faculty's own teaching site. A deep aubergine header (lilac is the
   traditional academic colour of dentistry), a book serif for headings over a
   plain public-service sans for reading, and an index-like list of routes in
   place of cards (the way reference manuals list their chapters).
   Fonts (both SIL Open Font License 1.1, see fonts/LICENSE.md):
     - Literata    - headings, lead text (TypeTogether for Google Play Books)
     - Public Sans - reading text, navigation, tables (U.S. Web Design System)
   Self-hosted from assets/site/fonts/ - a reader's browser contacts no third
   party (GDPR). Variable weight files, subsets latin + latin-ext (Slovak,
   Czech, Polish, Hungarian); other scripts fall back to system fonts.
   ========================================================================= */
@font-face {
  font-family: "Literata"; font-style: normal; font-weight: 400 700; font-display: swap;
  src: url(fonts/literata-latin.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: "Literata"; font-style: normal; font-weight: 400 700; font-display: swap;
  src: url(fonts/literata-latin-ext.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Literata"; font-style: italic; font-weight: 400; font-display: swap;
  src: url(fonts/literata-italic-latin.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: "Literata"; font-style: italic; font-weight: 400; font-display: swap;
  src: url(fonts/literata-italic-latin-ext.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Public Sans"; font-style: normal; font-weight: 400 700; font-display: swap;
  src: url(fonts/public-sans-latin.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: "Public Sans"; font-style: normal; font-weight: 400 700; font-display: swap;
  src: url(fonts/public-sans-latin-ext.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Public Sans"; font-style: italic; font-weight: 400 700; font-display: swap;
  src: url(fonts/public-sans-italic-latin.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: "Public Sans"; font-style: italic; font-weight: 400 700; font-display: swap;
  src: url(fonts/public-sans-italic-latin-ext.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

/* ---------- Palette: light ---------- */
:root,
[data-md-color-scheme="default"] {
  --de-paper: #ffffff;
  --de-panel: #f5f3f8;            /* cool lilac-grey, not cream */
  --de-ink: #211d26;              /* 16.6:1 on paper */
  --de-muted: #575060;            /*  7.6:1 on paper, 7.0:1 on panel */
  --de-rule: #ddd8e3;
  --de-key: #3a2748;              /* aubergine - header, strong rules */
  --de-lilac: #8c6fb8;            /* decorative rules only, never text */
  --de-accent: #5a3a8a;           /* links                 8.6:1 on paper */
  --de-accent-hover: #3a2459;
  --de-warn: #9a3412;             /* 7.2:1 */
  --de-note: #5a3a8a;
  --de-tip: #2b6a4d;              /* 6.6:1 */
  --de-header-bg: #3a2748;
  --de-header-fg: #f6f2fa;        /* 13.0:1 on header */
  --de-figure-bg: #ffffff;
  --de-figure-mat: var(--de-panel);
  --de-figure-filter: none;

  --md-primary-fg-color: #3a2748;
  --md-primary-fg-color--light: #4d3660;
  --md-primary-fg-color--dark: #2a1c35;
  --md-primary-bg-color: #f6f2fa;
  --md-primary-bg-color--light: rgba(246, 242, 250, 0.74);
  --md-accent-fg-color: #3a2459;
  --md-accent-fg-color--transparent: rgba(90, 58, 138, 0.09);
  --md-default-bg-color: var(--de-paper);
  --md-default-fg-color: var(--de-ink);
  --md-default-fg-color--light: var(--de-muted);
  --md-default-fg-color--lighter: #8e8798;
  --md-default-fg-color--lightest: var(--de-rule);
  --md-typeset-color: var(--de-ink);
  --md-typeset-a-color: var(--de-accent);
  --md-typeset-table-color: var(--de-rule);
  --md-footer-bg-color: #3a2748;
  --md-footer-bg-color--dark: #2a1c35;
  --md-footer-fg-color: #f6f2fa;
  --md-footer-fg-color--light: rgba(246, 242, 250, 0.84);
  --md-footer-fg-color--lighter: rgba(246, 242, 250, 0.74);
}

/* ---------- Palette: dark ---------- */
[data-md-color-scheme="slate"] {
  --de-paper: #16131a;
  --de-panel: #201c26;
  --de-ink: #ebe7f0;              /* 15.4:1 on paper */
  --de-muted: #b4acbe;            /*  8.6:1 on paper */
  --de-rule: #342e3c;
  --de-key: #c9adf2;
  --de-lilac: #a98bd6;
  --de-accent: #c9adf2;           /* 10.0:1 on paper */
  --de-accent-hover: #e2d2fa;
  --de-warn: #f2a580;             /*  9.0:1 */
  --de-note: #c9adf2;
  --de-tip: #8fd1b0;              /* 10.3:1 */
  --de-header-bg: #241a2e;
  --de-header-fg: #ebe7f0;
  --de-figure-bg: #ebebeb;
  --de-figure-mat: #201c26;
  --de-figure-filter: brightness(0.92);

  --md-hue: 275;
  --md-primary-fg-color: #4d3660;
  --md-primary-bg-color: #f6f2fa;
  --md-accent-fg-color: #e2d2fa;
  --md-accent-fg-color--transparent: rgba(201, 173, 242, 0.12);
  --md-default-bg-color: var(--de-paper);
  --md-default-fg-color: var(--de-ink);
  --md-default-fg-color--light: var(--de-muted);
  --md-default-fg-color--lighter: #776f82;
  --md-default-fg-color--lightest: var(--de-rule);
  --md-typeset-color: var(--de-ink);
  --md-typeset-a-color: var(--de-accent);
  --md-typeset-table-color: var(--de-rule);
  --md-code-bg-color: #201c26;
  --md-footer-bg-color: #241a2e;
  --md-footer-bg-color--dark: #1a1321;
}

/* ---------- Fonts ---------- */
:root {
  --md-text-font: "Public Sans";
  --de-font: "Public Sans", -apple-system, "Segoe UI", Arial, sans-serif;
  --de-serif: "Literata", Georgia, "Times New Roman", serif;
}
body { background: var(--de-paper); }

/* ---------- Header: one deep aubergine band ---------- */
.md-header {
  background-color: var(--de-header-bg);
  color: var(--de-header-fg);
  box-shadow: none;
}
.md-header--shadow { box-shadow: 0 1px 0 rgba(0, 0, 0, 0.2); }
.md-header__button.md-logo { margin-right: 0; }
.md-header__button.md-logo img { height: 1.5rem; width: auto; }
.md-header__title { margin-left: 0.4rem; }
.md-header__topic:first-child {
  font-family: var(--de-serif);
  font-weight: 600;
  font-size: 1.02rem;
  letter-spacing: 0.005em;
}
.md-header__topic + .md-header__topic { font-family: var(--de-serif); }

/* ---------- Layout ---------- */
.md-grid { max-width: 66rem; }
.md-main__inner { margin-top: 1.6rem; }

/* ---------- Navigation ---------- */
.md-nav { font-size: 0.72rem; }
.md-nav__link { color: var(--de-ink); }
.md-nav__link:hover, .md-nav__link:focus { color: var(--de-accent); }
.md-nav--primary > .md-nav__list > .md-nav__item--section > .md-nav__link {
  font-family: var(--de-serif);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--de-ink);
  letter-spacing: 0;
}
.md-nav__item .md-nav__link--active { color: var(--de-accent); font-weight: 600; }
.md-sidebar--primary .md-nav__link--active:not(.md-nav__container) {
  background: var(--md-accent-fg-color--transparent);
  padding: 0.1rem 0.4rem;
  margin-left: -0.4rem;
}
.md-nav--secondary .md-nav__title {
  font-family: var(--de-serif);
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--de-ink);
  /* The title is sticky: it needs the page colour, else scrolled entries show through it. */
  background: var(--de-paper);
  box-shadow: none;
}
/* Desktop: the site name already sits in the header, and the sticky copy at the top of
   the left menu covered the first entries once the menu scrolled. The phone drawer keeps
   it (there it is the drawer's own header). */
@media screen and (min-width: 76.25em) {
  .md-nav--primary > .md-nav__title { display: none; }
}

/* ---------- Long-text typography ---------- */
.md-typeset {
  font-size: 0.84rem;             /* 16.8 px */
  line-height: 1.68;
  color: var(--de-ink);
}
.md-content__inner > :is(p, ul, ol, blockquote, .admonition, details, h2, h3, h4) {
  max-width: 70ch;
}
.md-typeset :is(h1, h2) {
  font-family: var(--de-serif);
  color: var(--de-ink);
}
.md-typeset h1 {
  font-size: 2.1em;
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -0.015em;
  margin: 0 0 0.7em;
  max-width: 28ch;
}
.md-typeset h2 {
  font-size: 1.45em;
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: -0.01em;
  margin: 2.4em 0 0.55em;
}
.md-typeset h3 {
  font-size: 1em;
  font-weight: 700;
  margin: 1.7em 0 0.35em;
  color: var(--de-ink);
}
.md-typeset h4 { font-size: 0.92em; font-weight: 700; color: var(--de-muted); }
.md-typeset p, .md-typeset ul, .md-typeset ol { margin: 0 0 0.9em; }
.md-typeset li { margin-bottom: 0.3em; }
.md-typeset ol li::marker { font-weight: 600; color: var(--de-accent); }
.md-typeset a { color: var(--de-accent); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 0.2em; text-decoration-color: color-mix(in srgb, var(--de-accent) 50%, transparent); }
.md-typeset a:hover, .md-typeset a:focus { color: var(--de-accent-hover); text-decoration-color: currentColor; }
.md-typeset .headerlink { text-decoration: none; color: var(--de-muted); }
.md-typeset hr {
  border: 0;
  height: 1px;
  background: var(--de-rule);
  margin: 2.2em 0;
}
.md-typeset hr:has(+ h2) { margin-bottom: 0; }
.md-typeset :focus-visible { outline: 2px solid var(--de-lilac); outline-offset: 2px; }

/* Page facts: a quiet panel, label + value per line */
.md-typeset blockquote:first-of-type {
  border: 0;
  background: var(--de-panel);
  color: var(--de-ink);
  padding: 0.6rem 0.9rem;
  margin: 0 0 1.6em;
  font-size: 0.78rem;
  line-height: 1.65;
}
.md-typeset blockquote:first-of-type p { margin: 0; }
.md-typeset blockquote:first-of-type br { display: none; }
.md-typeset blockquote:first-of-type strong {
  font-weight: 600;
  color: var(--de-muted);
  margin-right: 0.3em;
}
.md-typeset blockquote:first-of-type strong:not(:first-child)::before {
  content: "\A";
  white-space: pre;
}
/* Other quotes: serif aside with a lilac rule */
.md-typeset blockquote:not(:first-of-type) {
  border-left: 2px solid var(--de-lilac);
  color: var(--de-ink);
  padding: 0.05rem 0 0.05rem 1rem;
  font-family: var(--de-serif);
  font-size: 0.95em;
}

/* ---------- Tables: tinted head, hairline rows, no cage ---------- */
.md-typeset table:not([class]) {
  border: 0;
  border-radius: 0;
  box-shadow: none;
  font-size: 0.76rem;
  line-height: 1.5;
}
.md-typeset table:not([class]) th {
  background: var(--de-panel);
  color: var(--de-ink);
  font-weight: 700;
  border-bottom: 1px solid var(--de-key);
  padding: 0.65em 1em;
}
.md-typeset table:not([class]) td {
  border-top: 0;
  border-bottom: 1px solid var(--de-rule);
  padding: 0.6em 1em;
  vertical-align: top;
}
.md-typeset table:not([class]) td:first-child { font-weight: 600; }
.md-typeset table:not([class]) tbody tr:hover { background: var(--md-accent-fg-color--transparent); box-shadow: none; }

/* ---------- Admonitions: panel with a coloured top rule and the label ---------- */
.md-typeset :is(.admonition, details:not(.dentaled-report))[class] {
  --de-adm: var(--de-note);
  border: 0;
  border-top: 2px solid var(--de-adm);
  border-radius: 0;
  box-shadow: none;
  background: var(--de-panel);
  font-size: 0.8rem;
  padding: 0.1rem 1rem 0.35rem;
  margin: 1.6em 0;
}
.md-typeset :is(.admonition, details:not(.dentaled-report)):is(.warning, .caution, .attention, .danger, .error, .failure, .bug) { --de-adm: var(--de-warn); }
.md-typeset :is(.admonition, details:not(.dentaled-report)):is(.tip, .hint, .important, .success, .check, .done) { --de-adm: var(--de-tip); }
.md-typeset :is(.admonition, details:not(.dentaled-report)) > :is(.admonition-title, summary) {
  background: transparent;
  border: 0;
  margin: 0.55rem 0 0.3rem;
  padding: 0 0 0 1.5rem;
  color: var(--de-adm);
  font-family: var(--de-serif);
  font-weight: 600;
  font-size: 0.86rem;
}
.md-typeset :is(.admonition, details:not(.dentaled-report)) > :is(.admonition-title, summary)::before {
  background-color: var(--de-adm);
  left: 0;
  top: 0.18em;
  width: 1.05rem;
  height: 1.05rem;
}
.md-typeset :is(.admonition, details:not(.dentaled-report)):focus-within { box-shadow: none; }

/* ---------- Route cards: an index list - title left, description right ---------- */
.md-typeset .grid.cards {
  display: block;
  margin: 1.2em 0 2em;
  border-top: 1px solid var(--de-key);
}
.md-typeset .grid.cards > ul { display: block; margin: 0; padding: 0; }
.md-typeset .grid.cards > ul > li,
.md-typeset .grid.cards > ul > li:hover,
.md-typeset .grid.cards > ul > li:focus-within {
  border: 0;
  border-bottom: 1px solid var(--de-rule);
  border-radius: 0;
  box-shadow: none;
  background: transparent;
  margin: 0;
  padding: 0.75rem 0 0.8rem;
  display: grid;
  grid-template-columns: 13rem 1fr;
  column-gap: 1.4rem;
  align-items: baseline;
}
.md-typeset .grid.cards > ul > li:hover { background: var(--md-accent-fg-color--transparent); }
.md-typeset .grid.cards > ul > li > * { grid-column: 2; }
.md-typeset .grid.cards > ul > li > h3 {
  grid-column: 1;
  grid-row: 1 / span 3;
  margin: 0;
  font-family: var(--de-serif);
  font-size: 0.98rem;
  font-weight: 600;
  line-height: 1.35;
  padding-left: 0.2rem;
}
.md-typeset .grid.cards p { font-size: 0.8rem; line-height: 1.55; margin: 0 0 0.35rem; color: var(--de-muted); }
.md-typeset .grid.cards p:last-child { margin: 0; color: var(--de-ink); }
.md-typeset .grid.cards .headerlink { display: none; }

/* ---------- Figures: the diagram on a mat, caption under a short rule ---------- */
.md-typeset p:has(> img:only-child) {
  max-width: none;
  margin: 1.6em 0 0.5em;
  padding: 1rem;
  background: var(--de-figure-mat);
}
.md-typeset p:has(> img:only-child) img {
  display: block;
  margin: 0 auto;
  background: var(--de-figure-bg);
  filter: var(--de-figure-filter);
  box-shadow: 0 0 0 1px var(--de-rule);
}
.md-typeset p:has(> img:only-child) + p:has(> em:only-child) {
  font-size: 0.74rem;
  line-height: 1.5;
  color: var(--de-muted);
  max-width: 60ch;
}
.md-typeset p:has(> img:only-child) + p:has(> em:only-child) em { font-style: normal; }
.md-typeset p:has(> img:only-child) + p:has(> em:only-child)::before {
  content: "";
  display: block;
  width: 2rem;
  height: 2px;
  margin-bottom: 0.35rem;
  background: var(--de-lilac);
}

/* ---------- Home page (the only page without the report tail) ---------- */
.md-content:not(:has(.dentaled-tail)) .md-typeset h1 {
  font-size: 2.6em;
  font-weight: 500;
  max-width: 22ch;
  margin-bottom: 0.45em;
}
.md-content:not(:has(.dentaled-tail)) .md-typeset h1 + p {
  font-family: var(--de-serif);
  font-size: 1.15em;
  line-height: 1.6;
  max-width: 50ch;
  margin-bottom: 1.4em;
}

/* ---------- Page tail ---------- */
.dentaled-tail {
  margin-top: 3rem;
  padding-top: 1rem;
  border-top: 1px solid var(--de-key);
  font-size: 0.74rem;
  color: var(--de-muted);
  max-width: 70ch;
}
.dentaled-tail a { color: var(--de-accent); }
.md-typeset details.dentaled-report {
  border: 0;
  box-shadow: none;
  background: transparent;
  padding: 0;
  margin: 0.3rem 0 0;
  font-size: 0.78rem;
  overflow: visible;
}
.md-typeset details.dentaled-report > summary {
  display: inline-block;
  background: transparent;
  border: 1px solid var(--de-accent);
  margin: 0;
  padding: 0.3rem 0.8rem;
  color: var(--de-accent);
  font-weight: 600;
  font-size: 0.76rem;
}
.md-typeset details.dentaled-report > summary::before,
.md-typeset details.dentaled-report > summary::after { display: none; }
.md-typeset details.dentaled-report > summary:hover { background: var(--md-accent-fg-color--transparent); }
.md-typeset details.dentaled-report[open] > summary { margin-bottom: 0.5rem; }
.dentaled-report__form label { color: var(--de-ink); font-weight: 600; }
.dentaled-report__form textarea,
.dentaled-report__form input {
  border: 1px solid #8e8798;
  border-radius: 0;
  background: var(--de-paper);
  color: var(--de-ink);
}
.dentaled-report__form :is(textarea, input):focus { outline: 2px solid var(--de-lilac); outline-offset: 1px; }
.dentaled-report__form .md-button--primary { border-radius: 0; font-weight: 600; }
[data-md-color-scheme="slate"] .dentaled-report__form .md-button--primary {
  background-color: var(--de-accent);
  border-color: var(--de-accent);
  color: #16131a;
}

/* ---------- Footer ---------- */
.md-footer-meta { background-color: var(--md-footer-bg-color--dark); }
.md-footer__title { font-family: var(--de-serif); }
.md-copyright { font-size: 0.64rem; line-height: 1.5; max-width: 60rem; }
.md-copyright a { color: #ffffff; text-decoration: underline; }

/* ---------- Small screens ---------- */
@media screen and (max-width: 44.9375em) {
  .md-typeset { font-size: 0.82rem; }
  .md-typeset h1 { font-size: 1.75em; }
  .md-content:not(:has(.dentaled-tail)) .md-typeset h1 { font-size: 2.1em; }
  .md-typeset .grid.cards > ul > li,
  .md-typeset .grid.cards > ul > li:hover { grid-template-columns: 1fr; }
  .md-typeset .grid.cards > ul > li > *,
  .md-typeset .grid.cards > ul > li > h3 { grid-column: 1; grid-row: auto; }
  .md-typeset .grid.cards > ul > li > h3 { margin-bottom: 0.3rem; padding-left: 0; }
  .md-typeset p:has(> img:only-child) { padding: 0.4rem; margin-left: -0.4rem; margin-right: -0.4rem; }
}
