/*
  The wiki (Pages/Front/WikiView.razor, Components/WikiMenu.razor, the game's docs/wiki-design.md), laid out the way
  its readers know it from Fandom but in the website's own look: the wiki's header with Explore and the menus, the
  page's title with its categories and Edit / History, the contents box at the top right of the text, thumbnails
  beside it, and the page tools and recent activity in a rail on the right.

  Only the design system's tokens are used. The text is long reading: body size, a comfortable line length, tables
  that scroll sideways on a phone instead of widening the page. No <footer> or <header> elements: site.css dresses
  every one of those as the site's own.
*/

.rf-wiki,
.rf-wiki * {
    box-sizing: border-box;
}

/* the wiki uses the width of the screen: the site's sections stop at 1248px with 100px each side, which left the
   pages a narrow column on a wide screen (the owner, 2026-12-02) */
/* (as specific as ravenfall-front.css's ".rf-front .page-content .section:not(.patreon)", 78rem, and loaded after it) */
.rf-front .page-content > .section.rf-wiki {
    max-width: 2000px;
    padding-left: clamp(0.75rem, 2.5vw, 3rem);
    padding-right: clamp(0.75rem, 2.5vw, 3rem);
}

.rf-wiki {
    color: var(--rf-ink);
    font-family: var(--rf-font);
    font-size: var(--rf-size-body);
    line-height: 1.6;
}

.rf-wiki .fa-solid {
    color: inherit;
}

.rf-wiki a {
    color: var(--rf-gold);
}

/* ---- The wiki's header ---------------------------------------------------- */
.rf-wikihead {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--rf-space-2) var(--rf-space-4);
    padding: var(--rf-space-3) var(--rf-space-4);
    margin-bottom: var(--rf-space-4);
    background: var(--rf-surface-1);
    border: 1px solid var(--rf-line);
    border-radius: var(--rf-radius);
    position: relative;
    z-index: 5;
}

.rf-wikihead__name {
    font-size: 1.2rem;
    font-weight: 700;
    text-decoration: none;
    color: var(--rf-ink) !important;
    white-space: nowrap;
}

.rf-wikihead__name i {
    color: var(--rf-gold);
}

.rf-wikihead__end {
    display: flex;
    align-items: center;
    gap: var(--rf-space-3);
    margin-left: auto;
}

.rf-wikihead__count {
    font-size: var(--rf-size-small);
    color: var(--rf-ink-muted) !important;
    text-decoration: none;
    white-space: nowrap;
}

.rf-wikihead__count b {
    color: var(--rf-ink);
    font-size: 1rem;
}

.rf-wikihead__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
    border: 1px solid var(--rf-line-strong);
    border-radius: var(--rf-radius-sm);
    color: var(--rf-ink) !important;
    text-decoration: none;
}

/* site.css makes every form in .content a centered column (.content form): this one is a row */
.rf-wiki .rf-wiki__search {
    display: flex;
    flex-flow: row nowrap;
    justify-content: flex-start;
    align-items: stretch;
    margin: 0;
}

.rf-wiki__search input {
    width: 14rem;
    min-width: 0;
    padding: 0.4rem 0.7rem;
    border-radius: var(--rf-radius-sm) 0 0 var(--rf-radius-sm);
    border: 1px solid var(--rf-line-strong);
    border-right: none;
    background: var(--rf-surface-2);
    color: var(--rf-ink);
    font: inherit;
}

.rf-wiki__search button {
    padding: 0.4rem 0.8rem;
    border-radius: 0 var(--rf-radius-sm) var(--rf-radius-sm) 0;
    border: 1px solid var(--rf-line-gold);
    background: var(--rf-gold-wash);
    color: var(--rf-ink);
    cursor: pointer;
}

/* ---- The menus -------------------------------------------------------------
   A top entry opens downwards, the entries in it open to the side; on hover and on focus (a tap, the keyboard). */
.rf-wikinav ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.rf-wikinav__top {
    display: flex;
    flex-wrap: wrap;
    gap: 0.15rem;
}

.rf-wikinav__item {
    position: relative;
}

.rf-wikinav__link {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    width: 100%;
    padding: 0.4rem 0.7rem;
    border: none;
    border-radius: var(--rf-radius-sm);
    background: none;
    color: var(--rf-ink) !important;
    font: inherit;
    font-size: var(--rf-size-small);
    font-weight: 700;
    text-align: left;
    text-decoration: none;
    white-space: nowrap;
    cursor: pointer;
}

.rf-wikinav__item.is-top > .rf-wikinav__link {
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.rf-wikinav__link:hover,
.rf-wikinav__link:focus-visible,
.rf-wikinav__item:focus-within > .rf-wikinav__link {
    background: var(--rf-surface-3);
    color: var(--rf-gold) !important;
}

.rf-wikinav__caret {
    margin-left: auto;
    font-size: 0.75em;
    opacity: 0.8;
}

.rf-wikinav__menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 12rem;
    padding: 0.3rem !important;
    background: var(--rf-surface-2);
    border: 1px solid var(--rf-line-strong);
    border-radius: var(--rf-radius-sm);
    box-shadow: var(--rf-shadow-lg);
    z-index: 10;
}

.rf-wikinav__menu .rf-wikinav__menu {
    top: -0.3rem;
    left: 100%;
}

.rf-wikinav__item:hover > .rf-wikinav__menu,
.rf-wikinav__item:focus-within > .rf-wikinav__menu {
    display: block;
}

/* closed after a click until the mouse leaves the menus (WikiView.MenuClicked) */
.rf-wikinav.is-closed .rf-wikinav__menu {
    display: none !important;
}

.rf-wiki__title:focus {
    outline: none;
}

.rf-wikinav__menu .rf-wikinav__link {
    font-weight: 400;
    font-size: var(--rf-size-body);
}

/* ---- Messages -------------------------------------------------------------- */
.rf-wiki__role {
    display: flex;
    flex-wrap: wrap;
    gap: var(--rf-space-3);
    align-items: center;
    font-size: var(--rf-size-small);
    color: var(--rf-ink-muted);
}

.rf-wiki__chip {
    display: inline-block;
    padding: 0.05rem 0.55rem;
    border-radius: 999px;
    border: 1px solid var(--rf-line-gold);
    background: var(--rf-gold-wash);
    color: var(--rf-ink);
    font-weight: 700;
    font-size: var(--rf-size-small);
}

.rf-wiki__chip.is-bad {
    border-color: var(--rf-warn);
    background: transparent;
}

.rf-wiki__msg {
    padding: var(--rf-space-3) var(--rf-space-4);
    border-radius: var(--rf-radius-sm);
    border: 1px solid var(--rf-line-strong);
    background: var(--rf-surface-2);
}

.rf-wiki__msg.is-good {
    border-color: var(--rf-good);
    background: var(--rf-good-wash);
}

.rf-wiki__msg.is-bad {
    border-color: var(--rf-warn);
    background: var(--rf-warn-wash);
}

.rf-wiki__note,
.rf-wiki__license {
    color: var(--rf-ink-muted);
    font-size: var(--rf-size-small);
}

.rf-wiki__old {
    padding: var(--rf-space-3) var(--rf-space-4);
    border-radius: var(--rf-radius-sm);
    background: var(--rf-warn-wash);
    border: 1px solid var(--rf-warn);
}

/* ---- The page and the rail --------------------------------------------------
   The rail sits right of the page on a wide screen and below it on a narrow one. */
.rf-wiki__grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: var(--rf-space-5);
}

@media (min-width: 1100px) {
    .rf-wiki__grid {
        grid-template-columns: minmax(0, 1fr) 18rem;
    }

    .rf-wiki__grid.is-wide {
        grid-template-columns: minmax(0, 1fr);
    }
}

.rf-wiki__main {
    min-width: 0;
    background: var(--rf-surface-1);
    border: 1px solid var(--rf-line);
    border-radius: var(--rf-radius);
    padding: var(--rf-space-4) var(--rf-space-5);
}

@media (max-width: 600px) {
    .rf-wiki__main {
        padding: var(--rf-space-3);
    }
}

.rf-wiki__pagehead {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: flex-start;
    gap: var(--rf-space-3);
    margin-bottom: var(--rf-space-4);
}

.rf-wiki .rf-wiki__title {
    margin: 0;
    font-size: 2rem;
    font-weight: 700;
    line-height: 1.2;
    color: var(--rf-ink);
}

.rf-wiki__subline {
    margin: 0.2rem 0 0;
    color: var(--rf-ink-muted);
    font-size: var(--rf-size-small);
}

.rf-wiki__catmenu {
    position: relative;
    margin-top: 0.2rem;
    font-size: var(--rf-size-small);
}

.rf-wiki__catmenu summary {
    cursor: pointer;
    color: var(--rf-gold);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    list-style: none;
}

.rf-wiki__catmenu summary::-webkit-details-marker,
.rf-wiki__more summary::-webkit-details-marker,
.rf-wiki__toc summary::-webkit-details-marker {
    display: none;
}

.rf-wiki__catmenu ul {
    position: absolute;
    z-index: 4;
    margin: 0.3rem 0 0;
    padding: 0.4rem 0.8rem;
    list-style: none;
    background: var(--rf-surface-2);
    border: 1px solid var(--rf-line-strong);
    border-radius: var(--rf-radius-sm);
    box-shadow: var(--rf-shadow-lg);
}

.rf-wiki__bar,
.rf-wiki__actions {
    display: flex;
    flex-wrap: wrap;
    gap: var(--rf-space-2);
    align-items: center;
}

.rf-wiki .rf-wiki__btn {
    display: inline-flex;
    gap: 0.4rem;
    align-items: center;
    padding: 0.4rem 0.9rem;
    border-radius: var(--rf-radius-sm);
    border: 1px solid var(--rf-line-strong);
    background: var(--rf-surface-2);
    color: var(--rf-ink);
    font: inherit;
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
    list-style: none;
}

.rf-wiki .rf-wiki__btn.is-primary {
    border-color: var(--rf-line-gold);
    background: var(--rf-gold-wash);
}

.rf-wiki .rf-wiki__btn.is-danger {
    border-color: var(--rf-warn);
}

.rf-wiki .rf-wiki__btn:disabled {
    opacity: 0.6;
    cursor: default;
}

.rf-wiki__more {
    position: relative;
}

.rf-wiki__moremenu {
    position: absolute;
    right: 0;
    top: calc(100% + 0.3rem);
    z-index: 6;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    min-width: 14rem;
    padding: 0.6rem 0.8rem;
    background: var(--rf-surface-2);
    border: 1px solid var(--rf-line-strong);
    border-radius: var(--rf-radius-sm);
    box-shadow: var(--rf-shadow-lg);
    font-size: var(--rf-size-small);
}

.rf-wiki__linkbtn {
    border: none;
    background: none;
    padding: 0;
    color: var(--rf-gold);
    font: inherit;
    text-align: left;
    text-decoration: underline;
    cursor: pointer;
}

.rf-wiki__linkbtn.is-danger {
    color: var(--rf-ink);
}

.rf-wiki__protect {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    color: var(--rf-ink-muted);
}

.rf-wiki select,
.rf-wiki__field input,
.rf-wiki__text {
    padding: 0.45rem 0.7rem;
    border-radius: var(--rf-radius-sm);
    border: 1px solid var(--rf-line-strong);
    background: var(--rf-surface-2);
    color: var(--rf-ink);
    font: inherit;
}

/* the rail: page tools and the wiki's recent activity */
.rf-wiki__rail {
    display: flex;
    flex-direction: column;
    gap: var(--rf-space-4);
    min-width: 0;
}

.rf-wiki__railbox {
    background: var(--rf-surface-1);
    border: 1px solid var(--rf-line);
    border-radius: var(--rf-radius);
    padding: var(--rf-space-3) var(--rf-space-4);
    font-size: var(--rf-size-small);
}

.rf-wiki__railbox h2 {
    margin: 0 0 var(--rf-space-2);
    font-size: 1rem;
    font-weight: 700;
}

.rf-wiki__railbox ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.rf-wiki__railbox li {
    padding: 0.15rem 0;
}

.rf-wiki__activity li {
    display: flex;
    flex-direction: column;
    padding: 0.3rem 0;
}

.rf-wiki__activity span {
    color: var(--rf-ink-muted);
}

.rf-wiki__railmore {
    display: inline-block;
    margin-top: var(--rf-space-2);
}

/* ---- The front page -------------------------------------------------------- */
.rf-wiki__lead {
    font-size: 1.05rem;
}

.rf-wiki__cats {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(13rem, 1fr));
    gap: var(--rf-space-4);
    margin: var(--rf-space-5) 0;
}

.rf-wiki__cat {
    background: var(--rf-surface-2);
    border: 1px solid var(--rf-line);
    border-radius: var(--rf-radius);
    padding: var(--rf-space-4);
}

.rf-wiki__cat h2,
.rf-wiki__subhead {
    font-size: 1.15rem;
    font-weight: 700;
    margin: 0 0 var(--rf-space-2);
}

.rf-wiki__cat h2 a {
    color: var(--rf-ink);
    text-decoration: none;
}

.rf-wiki__cat ul,
.rf-wiki__hits {
    list-style: none;
    margin: 0;
    padding: 0;
}

.rf-wiki__cat li {
    padding: 0.15rem 0;
}

.rf-wiki__hits li {
    padding: var(--rf-space-3) 0;
    border-bottom: 1px solid var(--rf-line);
}

.rf-wiki__hits a {
    font-weight: 700;
    font-size: 1.05rem;
}

.rf-wiki__hits p {
    margin: 0.2rem 0 0;
    color: var(--rf-ink-muted);
}

/* Special:AllPages: three columns, old names in italics */
.rf-wiki__allpages {
    columns: 3 14rem;
    column-gap: var(--rf-space-5);
    margin: 0 0 var(--rf-space-3);
}

.rf-wiki__allpages li {
    break-inside: avoid;
    padding: 0.1rem 0;
}

.rf-wiki__allpages li.is-old a {
    font-style: italic;
}

/* ---- A page's text --------------------------------------------------------- */
.rf-wiki__body {
    min-width: 0;
}

/* the contents box: at the top right of the text, beside its start, as on Fandom (above it on a narrow screen) */
.rf-wiki__toc {
    background: var(--rf-surface-2);
    border: 1px solid var(--rf-line-strong);
    border-radius: var(--rf-radius-sm);
    padding: var(--rf-space-2) var(--rf-space-4);
    margin: 0 0 var(--rf-space-4);
    font-size: var(--rf-size-small);
}

@media (min-width: 800px) {
    .rf-wiki__toc {
        float: right;
        width: 16rem;
        margin: 0 0 var(--rf-space-4) var(--rf-space-5);
        position: relative;
        z-index: 1;
    }
}

@media (max-width: 799px) {
    .rf-wiki__toc[open] ol {
        max-height: 14rem;
        overflow-y: auto;
    }
}

.rf-wiki__toc summary {
    cursor: pointer;
    font-weight: 700;
    list-style: none;
}

.rf-wiki__toc summary::after {
    content: " [hide]";
    font-weight: 400;
    color: var(--rf-gold);
}

.rf-wiki__toc:not([open]) summary::after {
    content: " [show]";
}

.rf-wiki__toc ol {
    list-style: none;
    margin: var(--rf-space-2) 0 0;
    padding: 0;
}

.rf-wiki__toc li {
    padding: 0.15rem 0;
}

.rf-wiki__toc li.is-sub {
    padding-left: var(--rf-space-4);
}

.rf-wiki__toc a {
    color: var(--rf-ink);
    text-decoration: none;
}

.rf-wiki__toc a:hover {
    color: var(--rf-gold);
}

.rf-wiki__body h2 {
    clear: both;
    font-size: 1.45rem;
    font-weight: 700;
    margin: var(--rf-space-6) 0 var(--rf-space-3);
    padding-bottom: var(--rf-space-2);
    border-bottom: 1px solid var(--rf-line-strong);
    scroll-margin-top: var(--rf-space-4);
}

/* the first heading stays beside the contents box instead of dropping below it */
.rf-wiki__body > .rf-wiki__toc + h2,
.rf-wiki__body > .rf-wiki__toc ~ h2:first-of-type {
    clear: none;
}

.rf-wiki__body h3 {
    font-size: 1.15rem;
    font-weight: 700;
    margin: var(--rf-space-5) 0 var(--rf-space-2);
    scroll-margin-top: var(--rf-space-4);
}

.rf-wiki__body h4 {
    font-size: 1rem;
    font-weight: 700;
    margin: var(--rf-space-4) 0 var(--rf-space-2);
}

.rf-wiki__body p,
.rf-wiki__body ul,
.rf-wiki__body ol {
    margin: 0 0 var(--rf-space-3);
}

.rf-wiki__body code {
    font-family: var(--rf-font-mono);
    font-size: 0.9em;
    padding: 0.05rem 0.35rem;
    border-radius: var(--rf-radius-sm);
    background: var(--rf-surface-3);
    color: var(--rf-ink);
}

.rf-wiki__body pre,
.rf-wiki__raw {
    display: block;
    font-family: var(--rf-font-mono);
    font-size: 0.85rem;
    background: var(--rf-surface-2);
    border: 1px solid var(--rf-line);
    border-radius: var(--rf-radius-sm);
    padding: var(--rf-space-3);
    overflow-x: auto;
    white-space: pre;
    color: var(--rf-ink);
}

.rf-wiki__body pre code {
    padding: 0;
    background: none;
}

.rf-wiki__body blockquote {
    margin: 0 0 var(--rf-space-3);
    padding: var(--rf-space-2) var(--rf-space-4);
    border-left: 3px solid var(--rf-line-gold);
    background: var(--rf-surface-2);
}

/* the command lists: the command, its explanation indented under it */
.rf-wiki__body dl {
    margin: 0 0 var(--rf-space-4);
}

.rf-wiki__body dt {
    font-weight: 700;
    margin-top: var(--rf-space-3);
}

.rf-wiki__body dd {
    margin: 0.2rem 0 0 var(--rf-space-4);
}

.rf-wiki__body img {
    max-width: 100%;
    height: auto;
    vertical-align: middle;
}

/* a thumbnail: beside the text on the right with its caption (as "The island of Home" on Fandom) */
.rf-wiki__thumb {
    float: right;
    clear: right;
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    width: 18rem;
    max-width: 45%;
    margin: 0.2rem 0 var(--rf-space-3) var(--rf-space-4);
    padding: 0.3rem;
    background: var(--rf-surface-2);
    border: 1px solid var(--rf-line);
    border-radius: var(--rf-radius-sm);
}

.rf-wiki__thumb img {
    width: 100%;
    border-radius: calc(var(--rf-radius-sm) - 2px);
}

.rf-wiki__caption {
    font-size: var(--rf-size-small);
    color: var(--rf-ink-muted);
    line-height: 1.3;
}

@media (max-width: 600px) {
    .rf-wiki__thumb {
        float: none;
        width: 100%;
        max-width: 100%;
        margin: 0 0 var(--rf-space-3);
    }
}

/* a row of screenshots (a picture titled "shot"): captioned cards side by side, a click opens the picture */
.rf-wiki__shot {
    display: inline-flex;
    flex-direction: column;
    gap: 0.3rem;
    width: 21rem;
    max-width: 100%;
    margin: 0 var(--rf-space-2) var(--rf-space-3) 0;
    padding: 0.3rem;
    vertical-align: top;
    background: var(--rf-surface-2);
    border: 1px solid var(--rf-line);
    border-radius: var(--rf-radius-sm);
    text-decoration: none;
}

.rf-wiki__shot:hover {
    border-color: var(--rf-line-strong);
}

.rf-wiki__shot img {
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    border-radius: calc(var(--rf-radius-sm) - 2px);
}

/* the old wiki's pictures in tables (pets, masks) and beside text (skill icons): their own size, never huge */
.rf-wiki__body td img {
    max-height: 4rem;
}

.rf-wiki__body p > img,
.rf-wiki__body li > img {
    max-height: 12rem;
}

.rf-wiki__nofile {
    display: inline-block;
    padding: 0.1rem 0.5rem;
    border: 1px dashed var(--rf-line-strong);
    border-radius: var(--rf-radius-sm);
    color: var(--rf-ink-muted);
    font-size: var(--rf-size-small);
}

.rf-wiki__table {
    overflow-x: auto;
    margin: 0 0 var(--rf-space-4);
}

.rf-wiki__body table,
.rf-wiki__history {
    border-collapse: collapse;
    font-size: var(--rf-size-small);
}

.rf-wiki__history {
    min-width: 100%;
}

.rf-wiki__body th,
.rf-wiki__body td,
.rf-wiki__history th,
.rf-wiki__history td {
    padding: 0.4rem 0.7rem;
    border: 1px solid var(--rf-line);
    text-align: left;
    vertical-align: top;
}

.rf-wiki__history td:first-child {
    white-space: nowrap;
}

.rf-wiki__body th,
.rf-wiki__history th {
    background: var(--rf-surface-2);
    font-weight: 700;
    white-space: nowrap;
}

.rf-wiki__info th {
    width: 14rem;
}

.rf-wiki__body tr:nth-child(even) td {
    background: var(--rf-surface-2);
}

.rf-wiki__current {
    color: var(--rf-good);
    font-weight: 700;
}

.rf-wiki__links {
    white-space: nowrap;
}

.rf-wiki__links > * + * {
    margin-left: var(--rf-space-2);
}

/* ---- Under a page: categories, writers, the license -------------------------- */
.rf-wiki__foot {
    clear: both;
    margin-top: var(--rf-space-6);
    padding-top: var(--rf-space-4);
    border-top: 1px solid var(--rf-line);
    color: var(--rf-ink-muted);
    font-size: var(--rf-size-small);
}

.rf-wiki__chips {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--rf-space-2);
}

.rf-wiki__chips a {
    padding: 0.15rem 0.6rem;
    border-radius: 999px;
    border: 1px solid var(--rf-line-gold);
    background: var(--rf-gold-wash);
    color: var(--rf-ink);
    text-decoration: none;
    font-weight: 700;
}

/* ---- Editing ----------------------------------------------------------------- */
.rf-wiki__edit {
    min-width: 0;
}

.rf-wiki__field {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    margin: 0 0 var(--rf-space-3);
    font-weight: 700;
}

.rf-wiki__field small {
    font-weight: 400;
    color: var(--rf-ink-muted);
}

.rf-wiki__text {
    width: 100%;
    min-height: 24rem;
    font-family: var(--rf-font-mono);
    font-size: 0.9rem;
    line-height: 1.5;
    resize: vertical;
}

.rf-wiki__help {
    margin: 0 0 var(--rf-space-3);
    font-size: var(--rf-size-small);
}

.rf-wiki__help summary {
    cursor: pointer;
    color: var(--rf-gold);
    font-weight: 700;
}

.rf-wiki__help dt {
    margin-top: var(--rf-space-2);
    font-weight: 400;
}

.rf-wiki__help dd {
    margin: 0 0 0 var(--rf-space-4);
    color: var(--rf-ink-muted);
}

.rf-wiki__preview {
    padding: var(--rf-space-4);
    border: 1px dashed var(--rf-line-strong);
    border-radius: var(--rf-radius);
}

.rf-wiki__review {
    margin: var(--rf-space-5) 0;
    padding: var(--rf-space-4);
    border: 1px solid var(--rf-line);
    border-radius: var(--rf-radius);
    background: var(--rf-surface-2);
}

.rf-wiki__review h2 {
    font-size: 1.2rem;
    margin: 0 0 var(--rf-space-2);
}

.rf-wiki__diff {
    font-family: var(--rf-font-mono);
    font-size: 0.85rem;
    line-height: 1.5;
    border: 1px solid var(--rf-line);
    border-radius: var(--rf-radius-sm);
    overflow-x: auto;
    margin: 0 0 var(--rf-space-3);
}

.rf-wiki__diffline {
    display: flex;
    gap: var(--rf-space-2);
    padding: 0 var(--rf-space-2);
    white-space: pre-wrap;
    word-break: break-word;
    color: var(--rf-ink-muted);
}

.rf-wiki__diffline.is-added {
    background: var(--rf-good-wash);
    color: var(--rf-ink);
}

.rf-wiki__diffline.is-removed {
    background: var(--rf-warn-wash);
    color: var(--rf-ink);
    text-decoration: line-through;
    text-decoration-color: rgba(236, 228, 214, 0.35);
}

.rf-wiki__diffmark {
    flex: none;
    width: 1ch;
    font-weight: 700;
}

.rf-wiki__diffsr {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
}

/* ---- The admin page (Pages/Admin/WikiAccess.razor) ----------------------------- */
.rf-wikiadmin__add {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    align-items: center;
}

.rf-wikiadmin__roles {
    margin-top: 0.75rem;
}

/* ---- Live data blocks (WikiBlocks: {{item:}}, [[Item:]], {{recipe:}}, {{items:}}, {{recipes:}}) ---------------- */
.rf-wikiitem {
    display: inline-flex;
    flex-direction: column;
    gap: var(--rf-space-2);
    width: min(100%, 24rem);
    margin: 0 0 var(--rf-space-3);
    padding: var(--rf-space-3);
    background: var(--rf-surface-2);
    border: 1px solid var(--rf-line-strong);
    border-radius: var(--rf-radius);
    vertical-align: top;
}

.rf-wikiitem + .rf-wikiitem {
    margin-left: var(--rf-space-3);
}

.rf-wikiitem__head {
    display: flex;
    align-items: center;
    gap: var(--rf-space-3);
}

.rf-wikiitem__head > div {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.rf-wikiitem__pic {
    flex: none;
    width: 3.5rem;
    height: 3.5rem;
    object-fit: contain;
    border-radius: var(--rf-radius-sm);
    background: var(--rf-surface-3);
}

.rf-wikiitem__pic.is-empty {
    display: inline-block;
}

.rf-wikiitem__name {
    font-weight: 700;
    font-size: 1.05rem;
    text-decoration: none;
}

.rf-wikiitem__kind {
    color: var(--rf-ink-muted);
    font-size: var(--rf-size-small);
}

.rf-wikiitem__desc {
    margin: 0 !important;
    color: var(--rf-ink-muted);
    font-size: var(--rf-size-small);
    font-style: normal;
}

.rf-wikiitem__facts {
    margin: 0;
    font-size: var(--rf-size-small);
}

.rf-wikiitem__facts > div {
    display: flex;
    justify-content: space-between;
    gap: var(--rf-space-3);
    padding: 0.15rem 0;
    border-bottom: 1px solid var(--rf-line);
}

.rf-wikiitem__facts dt {
    margin: 0 !important;
    font-weight: 400;
    color: var(--rf-ink-muted);
    white-space: nowrap;
}

.rf-wikiitem__facts dd {
    margin: 0 !important;
    text-align: right;
    font-weight: 700;
}

.rf-wikiitem__more {
    font-size: var(--rf-size-small);
}

/* an item named in a sentence, with its small card on hover or focus */
.rf-wikiitemlink {
    position: relative;
    display: inline-block;
}

.rf-wikiitemlink > a {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    font-weight: 700;
}

.rf-wikiitemlink__pic,
.rf-wikiblock__minipic {
    width: 1.3em;
    height: 1.3em;
    object-fit: contain;
    vertical-align: middle;
}

.rf-wikiitemlink__pic.is-empty,
.rf-wikiblock__minipic.is-empty {
    display: none;
}

.rf-wikiitemlink__tip {
    display: none;
    position: absolute;
    left: 0;
    top: calc(100% + 0.3rem);
    z-index: 8;
    min-width: 14rem;
    padding: 0.5rem 0.7rem;
    flex-direction: column;
    gap: 0.1rem;
    background: var(--rf-surface-2);
    border: 1px solid var(--rf-line-strong);
    border-radius: var(--rf-radius-sm);
    box-shadow: var(--rf-shadow-lg);
    font-size: var(--rf-size-small);
    font-weight: 400;
    white-space: nowrap;
    color: var(--rf-ink);
}

.rf-wikiitemlink__tip span {
    color: var(--rf-ink-muted);
}

.rf-wikiitemlink:hover .rf-wikiitemlink__tip,
.rf-wikiitemlink:focus-within .rf-wikiitemlink__tip {
    display: flex;
}

.rf-wikiblock__mini {
    display: inline-flex;
    align-items: center;
    gap: 0.2rem;
    white-space: nowrap;
}

.rf-wikiblock__rowpic {
    width: 2rem;
    height: 2rem;
    object-fit: contain;
}

.rf-wikiblock__rowpic.is-empty {
    display: inline-block;
}

.rf-wikiblock__quiet {
    color: var(--rf-ink-muted);
}

.rf-wikiblock__value {
    font-weight: 700;
}

/* a block that could not be filled: plain for the reader, a clear message for the writer */
.rf-wikiblock__problem {
    display: inline-block;
    padding: 0.05rem 0.5rem;
    border: 1px dashed var(--rf-warn);
    border-radius: var(--rf-radius-sm);
    color: var(--rf-ink-muted);
    font-size: var(--rf-size-small);
}

.rf-wikiblock__table td {
    vertical-align: middle !important;
}

/* ---- The editor's toolbar, item search and checks (WikiView.RenderEdit, rf-wiki-editor.js) ------------------- */
.rf-wiki__toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.3rem;
    margin: 0 0 0.4rem;
}

.rf-wiki__toolbar > button,
.rf-wiki__itemhits button {
    min-width: 2.2rem;
    padding: 0.3rem 0.55rem;
    border: 1px solid var(--rf-line-strong);
    border-radius: var(--rf-radius-sm);
    background: var(--rf-surface-2);
    color: var(--rf-ink);
    font: inherit;
    font-size: var(--rf-size-small);
    cursor: pointer;
}

.rf-wiki__toolbar > button:hover,
.rf-wiki__itemhits button:hover {
    border-color: var(--rf-line-gold);
    color: var(--rf-gold);
}

.rf-wiki__itemsearch {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    margin-left: auto;
    color: var(--rf-ink-muted);
}

.rf-wiki__itemsearch input {
    width: 14rem;
    padding: 0.3rem 0.6rem;
    border-radius: var(--rf-radius-sm);
    border: 1px solid var(--rf-line-strong);
    background: var(--rf-surface-2);
    color: var(--rf-ink);
    font: inherit;
    font-size: var(--rf-size-small);
}

.rf-wiki__itemhits {
    list-style: none;
    margin: 0 0 0.5rem;
    padding: 0.4rem;
    border: 1px solid var(--rf-line);
    border-radius: var(--rf-radius-sm);
    background: var(--rf-surface-2);
    font-size: var(--rf-size-small);
}

.rf-wiki__itemhits li {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.15rem 0;
}

.rf-wiki__itemhits li > span {
    flex: 1;
    font-weight: 700;
}

.rf-wiki__checks {
    list-style: none;
    margin: 0 0 var(--rf-space-3);
    padding: var(--rf-space-2) var(--rf-space-3);
    border: 1px solid var(--rf-warn);
    border-radius: var(--rf-radius-sm);
    background: var(--rf-warn-wash);
    font-size: var(--rf-size-small);
}

/* the game-data blocks (WikiBlocks.Game.cs) */
.rf-wikiblock__tag {
    display: inline-block;
    margin-left: 0.3rem;
    padding: 0 0.4rem;
    border: 1px solid var(--rf-line-gold);
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--rf-gold);
    white-space: nowrap;
}

.rf-wikiitemlink__wrap {
    max-width: 22rem;
    white-space: normal;
}

.rf-wikiblock__highscore {
    margin: 0 0 0.3rem;
    padding-left: 1.6rem;
}
