/* =========================================================
   Blog and guides (5.10)
   The blog is a contact sheet: every article is a print with the day it came out burnt into its corner, the way a
   film camera dates a photo, and the viewfinder of the menu closes in on the one under the pointer.
   The guides are a manual: sections, steps in gold, contents beside the text.
   ========================================================= */

:root { --stamp: 255 150 48; --stamp-glow: 255 92 0; }

/* a note admins see on a closed section or a draft */
.cx-closed { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; padding: 10px 16px; margin-bottom: 20px; border-radius: 14px; font-size: var(--fs-sm); color: var(--mist);
  background: repeating-linear-gradient(-45deg, rgb(var(--c-ac) / .08) 0 10px, transparent 10px 20px); border: 1px dashed rgb(var(--c-ac) / .5); }
.cx-closed .ic { width: 18px; height: 18px; flex: none; color: var(--gold-2); }
.cx-closed span { flex: 1 1 260px; }
.cx-closed a { font-size: var(--fs-xs); }
.cx-closed.is-draft { background: repeating-linear-gradient(-45deg, rgb(var(--c-al) / .08) 0 10px, transparent 10px 20px); border-color: rgb(var(--c-al) / .5); }
.cx-closed.is-draft .ic { color: var(--turq-2); }

/* the arrow that points onward: left in Persian, right in English */
.ic-next { transform: scaleX(-1); }
[dir="ltr"] .ic-next { transform: none; }
[dir="ltr"] [dir="rtl"] .ic-dir { transform: none; }
[dir="ltr"] [dir="rtl"] .ic-next { transform: scaleX(-1); }

/* ---------- blog: head and categories ---------- */
.bx-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 14px 24px; margin-bottom: 18px; }
.bx-title { max-width: 64ch; }
:is(.bx-title, .gx-title) h1 { font-size: clamp(1.9rem, 3.6vw, 2.75rem); line-height: 1.3; color: rgb(var(--c-title)); text-wrap: balance; }
:is(.bx-title, .gx-title) > p { margin-top: 8px; color: var(--mist); max-width: 60ch; }
.bx-tools { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }

.bx-cats { display: flex; gap: 8px; margin: 0 -2px 22px; padding: 2px 2px 8px; overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.bx-cats::-webkit-scrollbar { display: none; }
.bx-cats a { flex: none; display: inline-flex; align-items: center; gap: 8px; height: 44px; padding: 0 12px 0 14px; border-radius: 14px; border: 1px solid var(--line-2);
  background: rgb(var(--c-sf1) / .55); color: var(--mist); text-decoration: none; font-size: var(--fs-sm); transition: color .2s, border-color .2s, background-color .2s; }
.bx-cats a .ic { width: 17px; height: 17px; }
.bx-cats a b { min-width: 24px; height: 24px; padding: 0 7px; display: inline-grid; place-items: center; border-radius: 99px; font-weight: 400; font-size: .75rem; background: rgb(var(--c-hl) / .07); font-variant-numeric: tabular-nums; }
.bx-cats a:hover { color: var(--parch); border-color: var(--line); }
.bx-cats a.is-on { color: var(--gold-2); border-color: rgb(var(--c-ac) / .55); background: rgb(var(--c-ac) / .1); }
.bx-cats a.is-on b { background: rgb(var(--c-ac) / .22); }

/* ---------- article cards ---------- */
.bx-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px 18px; }
@media (max-width: 1000px) { .bx-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .bx-grid { grid-template-columns: 1fr; gap: 16px; } }

.pc { position: relative; display: flex; flex-direction: column; min-width: 0; border-radius: 22px; overflow: hidden;
  background: linear-gradient(180deg, rgb(var(--c-sf2) / .78), rgb(var(--c-sf1) / .92)); border: 1px solid var(--line-2);
  transition: border-color .25s, box-shadow .3s, transform .4s var(--spring); }
.pc:hover, .pc:focus-within { border-color: rgb(var(--c-ac) / .45); box-shadow: 0 26px 50px -32px rgb(var(--c-sh) / calc(.95 * var(--sha))); }
.pc-media { position: relative; }
.pc-pic { position: relative; aspect-ratio: 16 / 9; overflow: hidden; background: rgb(var(--c-bg0)); }
.pc-pic img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform .7s var(--smooth); }
.pc:hover .pc-pic img { transform: scale(1.035); }
.pc-nopic { position: absolute; inset: 0; display: grid; place-items: center; color: var(--gold-2);
  background: radial-gradient(circle at 50% 45%, rgb(var(--c-ac) / .16), transparent 60%), linear-gradient(160deg, rgb(var(--c-sf3)), rgb(var(--c-sf1))); }
.pc-nopic .ic { width: 46px; height: 46px; opacity: .8; }

/* the viewfinder: four corners close in on the picture under the pointer */
.pc-aim { position: absolute; inset: 12px; pointer-events: none; opacity: 0; transform: scale(1.07); transition: opacity .2s, transform .5s var(--spring);
  --a: rgb(255 255 255 / .95); --l: 24px; --t: 2px;
  background:
    linear-gradient(var(--a), var(--a)) 0 0 / var(--l) var(--t) no-repeat, linear-gradient(var(--a), var(--a)) 0 0 / var(--t) var(--l) no-repeat,
    linear-gradient(var(--a), var(--a)) 100% 0 / var(--l) var(--t) no-repeat, linear-gradient(var(--a), var(--a)) 100% 0 / var(--t) var(--l) no-repeat,
    linear-gradient(var(--a), var(--a)) 0 100% / var(--l) var(--t) no-repeat, linear-gradient(var(--a), var(--a)) 0 100% / var(--t) var(--l) no-repeat,
    linear-gradient(var(--a), var(--a)) 100% 100% / var(--l) var(--t) no-repeat, linear-gradient(var(--a), var(--a)) 100% 100% / var(--t) var(--l) no-repeat;
  filter: drop-shadow(0 1px 2px rgb(0 0 0 / .55)); }
.pc-aim::after { content: ""; position: absolute; top: 50%; left: 50%; width: 14px; height: 14px; margin: -7px 0 0 -7px; border-radius: 50%; border: 2px solid var(--a); opacity: .85; }
.pc:hover .pc-aim, .pc:focus-within .pc-aim { opacity: 1; transform: scale(1); }

/* the date burnt into the print */
.pc-stamp { position: absolute; z-index: 2; right: 14px; bottom: 10px; pointer-events: none; font-size: .95rem; font-weight: 600; line-height: 1; letter-spacing: .12em; white-space: nowrap;
  color: rgb(var(--stamp)); font-variant-numeric: tabular-nums;
  text-shadow: 0 0 1px rgb(110 30 0 / .9), 0 0 6px rgb(var(--stamp-glow) / .85), 0 0 16px rgb(var(--stamp-glow) / .45); filter: blur(.25px); }
html[lang="en"] .pc-stamp { letter-spacing: .16em; font-weight: 700; }

.pc-body { display: flex; flex-direction: column; gap: 8px; flex: 1; padding: 16px 18px 14px; }
.pc-cat { position: relative; z-index: 2; align-self: flex-start; display: inline-flex; align-items: center; gap: 6px; font-size: var(--fs-xs); color: var(--gold-2); text-decoration: none; }
.pc-cat .ic { width: 15px; height: 15px; }
.pc-cat:hover { color: rgb(var(--c-glow)); text-decoration: underline; }
.pc-t { font-size: 1.125rem; font-weight: 600; line-height: 1.65; text-wrap: pretty; }
html[lang="en"] .pc-t { font-weight: 700; line-height: 1.35; }
.pc-t a { color: rgb(var(--c-title)); text-decoration: none; }
.pc-t a::after { content: ""; position: absolute; inset: 0; z-index: 1; border-radius: inherit; }
.pc-t a:focus-visible { outline: none; }
.pc:has(.pc-t a:focus-visible) { outline: 2px solid var(--gold); outline-offset: 3px; }
.pc-x { color: var(--mist); font-size: var(--fs-sm); line-height: 1.95; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
html[lang="en"] .pc-x { line-height: 1.6; }
.pc-meta { margin-top: auto; padding-top: 10px; display: flex; flex-wrap: wrap; align-items: center; gap: 6px 14px; font-size: var(--fs-xs); color: var(--mist-2); border-top: 1px dashed var(--line-2); }
.pc-meta > span { display: inline-flex; align-items: center; gap: 5px; }
.pc-meta .ic { width: 15px; height: 15px; }
.pc-meta .tag { margin-inline-start: auto; }

/* the leading article */
.pc-big { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); margin-bottom: 24px; border-radius: 28px; }
.pc-big .pc-media, .pc-big .pc-pic { height: 100%; }
.pc-big .pc-pic { aspect-ratio: auto; min-height: 330px; }
.pc-big .pc-aim { inset: 20px; --l: 34px; }
.pc-big .pc-stamp { font-size: 1.35rem; right: 22px; bottom: 18px; }
.pc-big .pc-body { justify-content: center; gap: 12px; padding: 32px 32px 26px; }
.pc-big .pc-t { font-size: clamp(1.45rem, 2.5vw, 2rem); line-height: 1.5; }
html[lang="en"] .pc-big .pc-t { line-height: 1.25; }
.pc-big .pc-x { -webkit-line-clamp: 5; font-size: var(--fs-md); }
.pc-big .pc-meta { margin-top: 8px; font-size: var(--fs-sm); }
@media (max-width: 880px) {
  .pc-big { grid-template-columns: 1fr; border-radius: 24px; margin-bottom: 18px; }
  .pc-big .pc-media, .pc-big .pc-pic { height: auto; }
  .pc-big .pc-pic { aspect-ratio: 16 / 9; min-height: 0; }
  .pc-big .pc-body { padding: 18px 20px 16px; }
  .pc-big .pc-stamp { font-size: 1.1rem; right: 16px; bottom: 12px; }
}

/* ---------- one article ---------- */
.px { max-width: 760px; margin-inline: auto; }
.px-head { display: grid; gap: 14px; margin-bottom: 26px; }
.px-crumbs { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-size: var(--fs-sm); }
.px-crumbs a { display: inline-flex; align-items: center; gap: 6px; color: var(--mist); text-decoration: none; }
.px-crumbs a:hover { color: var(--gold-2); }
.px-crumbs .ic { width: 16px; height: 16px; }
.px-crumbs .px-sep { width: 14px; height: 14px; opacity: .6; transform: rotate(90deg); }
[dir="ltr"] .px-crumbs .px-sep { transform: rotate(-90deg); }
.px h1, .gd-head h1 { font-size: clamp(1.8rem, 4.2vw, 2.7rem); line-height: 1.45; color: rgb(var(--c-title)); text-wrap: balance; }
html[lang="en"] :is(.px h1, .gd-head h1) { line-height: 1.2; font-weight: 700; }
.px-lead, .gd-lead { font-size: 1.15rem; line-height: 1.95; color: var(--mist); text-wrap: pretty; }
html[lang="en"] :is(.px-lead, .gd-lead) { line-height: 1.55; }
.px-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 20px; font-size: var(--fs-sm); color: var(--mist); }
.px-meta > * { display: inline-flex; align-items: center; gap: 6px; }
.px-meta .ic { width: 17px; height: 17px; opacity: .85; }
.px-meta a { color: var(--mist); text-decoration: none; }
.px-meta a:hover { color: var(--gold-2); }
.px-meta .px-edit { color: var(--gold-2); }
.px-cover { margin: 0 0 32px; border-radius: 24px; overflow: hidden; border: 1px solid var(--line-2); background: rgb(var(--c-bg0)); box-shadow: 0 34px 70px -46px rgb(var(--c-sh) / calc(.95 * var(--sha))); }
.px-cover img { display: block; width: 100%; height: auto; }
@media (min-width: 1000px) { .px > .px-cover { margin-inline: -90px; } }

.px-toc { margin-bottom: 28px; border-radius: 18px; border: 1px solid var(--line-2); background: rgb(var(--c-sf1) / .55); }
.px-toc summary { display: flex; align-items: center; gap: 8px; padding: 12px 16px; cursor: pointer; list-style: none; font-weight: 600; color: rgb(var(--c-title)); }
.px-toc summary::-webkit-details-marker { display: none; }
.px-toc summary::after { content: ""; margin-inline-start: auto; width: 8px; height: 8px; border: solid var(--mist); border-width: 0 0 2px 2px; transform: rotate(-45deg); transition: transform .2s; }
.px-toc[open] summary::after { transform: rotate(135deg); }
.px-toc summary .ic { width: 18px; height: 18px; color: var(--gold-2); }
.px-toc ol { margin: 0; padding: 0 16px 14px; padding-inline-start: 38px; display: grid; gap: 4px; font-size: var(--fs-sm); }
.px-toc ol li::marker { color: var(--gold-2); }
.px-toc a { color: var(--mist); text-decoration: none; }
.px-toc a:hover { color: var(--gold-2); }

/* ---------- the text (both kinds) ---------- */
.md { font-size: 1.0625rem; line-height: 2.05; color: var(--parch); overflow-wrap: break-word; }
html[lang="en"] .md { line-height: 1.75; }
html[lang="en"] .md:lang(fa) { line-height: 2.05; }
.md > * { margin: 0; }
.md > * + * { margin-top: 1.05em; }
.md h2 { font-size: 1.5rem; font-weight: 600; line-height: 1.55; margin-top: 2.1em; color: rgb(var(--c-title)); scroll-margin-top: 110px; }
.md h2::before { content: ""; display: inline-block; width: 11px; height: 11px; margin-inline-end: 12px; vertical-align: .12em; clip-path: var(--star); background: var(--gold); }
.md h3 { font-size: 1.2rem; font-weight: 600; line-height: 1.6; margin-top: 1.7em; color: rgb(var(--c-title)); }
.md h4 { font-size: 1.05rem; font-weight: 600; margin-top: 1.5em; color: var(--gold-2); }
html[lang="en"] .md :is(h2, h3) { font-weight: 700; line-height: 1.3; }
.md :is(h2, h3, h4) + * { margin-top: .6em; }
.md a { color: var(--turq-2); text-underline-offset: 4px; }
.md strong { font-weight: 700; color: rgb(var(--c-title)); }
.md del { opacity: .7; }
.md ul { padding-inline-start: 1.35em; }
.md ul > li::marker { color: var(--gold); }
.md li + li { margin-top: .4em; }
/* numbered lists are steps: a gold coin for each, joined by a thread */
.md ol { list-style: none; padding: 0; counter-reset: step; }
.md ol > li { counter-increment: step; position: relative; padding-inline-start: 48px; min-height: 34px; }
.md ol > li + li { margin-top: .75em; }
.md ol > li::before { content: counter(step); position: absolute; inset-inline-start: 0; top: .2em; width: 32px; height: 32px; display: grid; place-items: center; border-radius: 50%;
  font-size: .9rem; font-weight: 700; line-height: 1; color: rgb(var(--c-on));
  background: linear-gradient(180deg, rgb(var(--c-ac2)), rgb(var(--c-ac)) 60%, rgb(var(--c-ac3))); box-shadow: inset 0 1px 0 rgb(var(--c-hl) / .5), 0 8px 16px -8px rgb(var(--c-ac) / .9); }
.md:lang(fa) ol > li::before { content: counter(step, persian); }
.md ol > li:not(:last-child)::after { content: ""; position: absolute; inset-inline-start: 15.5px; top: calc(.2em + 36px); bottom: calc(-.75em + 4px); width: 1px; background: linear-gradient(rgb(var(--c-ac) / .55), rgb(var(--c-ac) / .08)); }
.md li > ul { margin-top: .45em; padding-inline-start: 1.25em; }
.md li > ul > li + li { margin-top: .3em; }
.md blockquote { padding: 2px 18px; border-inline-start: 3px solid var(--gold); color: var(--mist); }
.md blockquote > * + * { margin-top: .7em; }
.md hr { width: 12px; height: 12px; margin: 2.4em auto; border: 0; clip-path: var(--star); background: var(--gold); opacity: .75; }
.md code { font-family: var(--mono); font-size: .85em; padding: 2px 6px; border-radius: 7px; background: rgb(var(--c-hl) / .07); border: 1px solid var(--line-2); direction: ltr; unicode-bidi: isolate; overflow-wrap: anywhere; }
.md pre.md-code { padding: 14px 16px; border-radius: 14px; background: rgb(var(--c-bg0) / .75); border: 1px solid var(--line-2); overflow: auto; font-size: .875rem; line-height: 1.7; text-align: left; }
.md pre.md-code code { padding: 0; border: 0; background: none; font-size: inherit; overflow-wrap: normal; white-space: pre; }
.md-keys { display: inline-flex; align-items: center; gap: 3px; white-space: nowrap; direction: ltr; unicode-bidi: isolate; vertical-align: .05em; }
.md-keys i { font-style: normal; font-size: .8em; color: var(--mist-2); }
.md kbd { font-size: .78em; font-weight: 600; padding: 2px 8px; color: rgb(var(--c-title)); background: rgb(var(--c-sf1)); box-shadow: 0 2px 0 rgb(var(--c-hl) / .12); }
.md-fig { margin: 1.7em 0 0; }
.md-fig + * { margin-top: 1.7em; }
.md-fig img { display: block; width: 100%; height: auto; border-radius: 16px; border: 1px solid var(--line-2); background: rgb(var(--c-bg0)); box-shadow: 0 24px 50px -36px rgb(var(--c-sh) / calc(.9 * var(--sha))); }
.md-fig figcaption { margin-top: 10px; font-size: var(--fs-xs); line-height: 1.8; color: var(--mist); text-align: center; }
.md-box { padding: 14px 18px; border-radius: 16px; border: 1px solid; }
.md-box > * + * { margin-top: .6em; }
.md-box > .md-box-t + * { margin-top: 0; }
.md-box-t { display: flex; align-items: center; gap: 7px; font-size: var(--fs-sm); font-weight: 700; line-height: 1.6; margin-bottom: 2px; }
.md-box-t .ic { width: 17px; height: 17px; }
.md-box :is(p, li) { font-size: .97em; }
.md-tip { background: rgb(var(--c-al) / .08); border-color: rgb(var(--c-al) / .32); }
.md-tip .md-box-t { color: var(--turq-2); }
.md-note { background: rgb(var(--c-ac) / .08); border-color: rgb(var(--c-ac) / .32); }
.md-note .md-box-t { color: var(--gold-2); }
.md-warn { background: rgb(var(--c-bad) / .07); border-color: rgb(var(--c-bad) / .32); }
.md-warn .md-box-t { color: var(--pom-2); }
.md-table { overflow-x: auto; border-radius: 14px; border: 1px solid var(--line-2); background: rgb(var(--c-sf1) / .5); }
.md-table table { width: 100%; border-collapse: collapse; font-size: var(--fs-sm); line-height: 1.8; }
.md-table :is(th, td) { padding: 10px 14px; text-align: start; vertical-align: top; border-bottom: 1px solid var(--line-2); }
.md-table th { font-weight: 600; color: rgb(var(--c-title)); background: rgb(var(--c-hl) / .04); white-space: nowrap; }
.md-table tr:last-child td { border-bottom: 0; }

/* ---------- likes, dislikes, sharing ---------- */
.px-react { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 14px 18px; margin-top: 46px; padding: 20px 22px; border-radius: 22px;
  background: linear-gradient(160deg, rgb(var(--c-sf2) / .78), rgb(var(--c-sf1) / .92)); border: 1px solid var(--line-2); scroll-margin-top: 110px; }
.px-react > p { font-size: 1.1rem; font-weight: 600; color: rgb(var(--c-title)); }
.vote-row { display: flex; gap: 10px; }
.vote-row form { margin: 0; }
.vote { display: inline-flex; align-items: center; gap: 8px; height: 46px; padding: 0 16px; border-radius: 14px; border: 1px solid var(--line); background: rgb(var(--c-hl) / .03);
  color: var(--parch); font-size: var(--fs-sm); line-height: 1; text-decoration: none; cursor: pointer; transition: color .2s, background-color .2s, border-color .2s, transform .15s; }
.vote .ic { width: 20px; height: 20px; transition: fill-opacity .2s; fill: currentColor; fill-opacity: 0; }
.vote b { min-width: 1.4ch; font-weight: 700; font-variant-numeric: tabular-nums; }
.vote:hover { color: var(--gold-2); border-color: rgb(var(--c-ac) / .45); }
.vote:active { transform: translateY(1px); }
.vote-up.is-on { color: rgb(var(--c-oktx)); background: rgb(var(--c-ok) / .13); border-color: rgb(var(--c-ok) / .5); }
.vote-down.is-on { color: var(--pom-2); background: rgb(var(--c-bad) / .1); border-color: rgb(var(--c-bad) / .42); }
.vote.is-on .ic { fill-opacity: .22; }
.vote.is-busy { pointer-events: none; opacity: .7; }
.vote.pop .ic { animation: vote-pop .5s var(--spring); }
@keyframes vote-pop { 0% { transform: scale(1); } 40% { transform: scale(1.4) rotate(-10deg); } 100% { transform: scale(1); } }
.px-share { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 8px; padding-top: 14px; border-top: 1px dashed var(--line-2); }
.px-admin-n { grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; padding: 10px 12px; border-radius: 12px; font-size: var(--fs-xs); color: var(--mist);
  background: repeating-linear-gradient(-45deg, rgb(var(--c-ac) / .07) 0 8px, transparent 8px 16px); }
.px-admin-n .ic { width: 15px; height: 15px; color: var(--gold-2); }
.px-admin-n span { flex: 1 1 240px; }
@media (max-width: 560px) {
  .px-react { grid-template-columns: minmax(0, 1fr); padding: 18px; }
  .vote-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .vote { justify-content: center; }
}
@media (max-width: 360px) {
  .vote { padding: 0 8px; gap: 5px; font-size: var(--fs-xs); }      /* both votes side by side on the narrowest phones */
  .vote .ic { width: 18px; height: 18px; }
}

/* ---------- comments ---------- */
.cm-wrap { margin-top: 46px; scroll-margin-top: 100px; }
.cm-wrap > h2 { display: flex; align-items: center; gap: 10px; margin-bottom: 18px; font-size: 1.5rem; font-weight: 600; color: rgb(var(--c-title)); }
.cm-wrap > h2 small { min-width: 30px; height: 30px; padding: 0 9px; display: inline-grid; place-items: center; border-radius: 99px; font-size: .85rem; font-weight: 600; color: var(--gold-2); background: rgb(var(--c-ac) / .14); font-variant-numeric: tabular-nums; }
.cm-form { margin-bottom: 18px; padding: 18px; border-radius: 20px; border: 1px solid var(--line-2); background: rgb(var(--c-sf1) / .65); }
.cm-who { display: flex; align-items: flex-end; gap: 12px; }
.cm-who .field { flex: 1; }
.cm-who .cm-av { margin-bottom: 16px; }
.cm-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 16px; }
.cm-foot small { display: inline-flex; align-items: flex-start; gap: 6px; max-width: 54ch; font-size: var(--fs-xs); line-height: 1.8; color: var(--mist); }
.cm-foot small .ic { width: 15px; height: 15px; flex: none; margin-top: 3px; }
.cm-form .field textarea { min-height: 110px; }
.cm-err { color: var(--pom-2); font-size: var(--fs-xs); }
.cm-guest { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 14px 16px; margin-bottom: 18px; padding: 18px; border-radius: 20px; border: 1px dashed rgb(var(--c-ac) / .45); background: rgb(var(--c-ac) / .05); }
.cm-guest-ic { width: 46px; height: 46px; display: grid; place-items: center; border-radius: 15px; color: var(--gold-2); background: rgb(var(--c-ac) / .13); }
.cm-guest-ic .ic { width: 22px; height: 22px; }
.cm-guest p { color: var(--mist); font-size: var(--fs-sm); line-height: 1.9; }
.cm-guest-act { display: flex; flex-wrap: wrap; gap: 8px; }
@media (max-width: 700px) { .cm-guest { grid-template-columns: auto minmax(0, 1fr); } .cm-guest-act { grid-column: 1 / -1; } .cm-guest-act .btn { flex: 1; } }
.cm-closed { display: flex; align-items: center; gap: 8px; color: var(--mist); margin-bottom: 14px; }
.cm-closed .ic { width: 17px; height: 17px; }
.cm-as { margin-bottom: 18px; border-radius: 18px; border: 1px dashed rgb(var(--c-al) / .5); background: rgb(var(--c-al) / .05); }
.cm-as summary { display: flex; align-items: center; gap: 8px; padding: 12px 16px; cursor: pointer; list-style: none; color: var(--turq-2); font-size: var(--fs-sm); }
.cm-as summary::-webkit-details-marker { display: none; }
.cm-as summary .ic { width: 18px; height: 18px; }
.cm-as summary small { margin-inline-start: auto; font-size: var(--fs-xs); color: var(--mist-2); }
.cm-as form { padding: 2px 16px 16px; }
.cm-as-grid { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr) minmax(0, .7fr); gap: 0 12px; }
@media (max-width: 600px) { .cm-as-grid { grid-template-columns: 1fr 1fr; } .cm-as-grid .field:first-child { grid-column: 1 / -1; } }

.cm-list { list-style: none; margin: 0; padding: 0; }
.cm { display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 12px 14px; padding: 16px 2px; border-top: 1px solid var(--line-2); }
.cm:first-child { border-top: 0; }
.cm-av { width: 44px; height: 44px; flex: none; display: grid; place-items: center; border-radius: 15px; font-size: 1.15rem; font-weight: 700; line-height: 1; text-transform: uppercase; user-select: none; }
.cv-1 { color: var(--gold-2); background: rgb(var(--c-ac) / .2); }
.cv-2 { color: var(--turq-2); background: rgb(var(--c-al) / .18); }
.cv-3 { color: rgb(var(--c-x)); background: rgb(var(--c-x) / .17); }
.cv-4 { color: var(--pom-2); background: rgb(var(--c-bad) / .14); }
.cv-5 { color: var(--pist); background: rgb(var(--c-ok) / .17); }
.cv-6 { color: rgb(var(--c-title)); background: rgb(var(--c-deep) / .32); }
.cm-top { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 10px; }
.cm-name { font-weight: 600; color: rgb(var(--c-title)); }
.cm-top time { font-size: var(--fs-xs); color: var(--mist-2); }
.cm-body { margin-top: 4px; line-height: 1.95; overflow-wrap: anywhere; }
.cm-hp { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; opacity: 0; pointer-events: none; }
.cm-meter { display: flex; align-items: baseline; justify-content: space-between; gap: 4px 14px; flex-wrap: wrap; margin-top: 6px; font-size: var(--fs-xs); color: rgb(var(--c-tx3)); }
.cm-left { font-variant-numeric: tabular-nums; white-space: nowrap; margin-inline-start: auto; }
.cm-left.is-near { color: rgb(var(--c-badtx)); font-weight: 600; }
.cm-name { overflow-wrap: anywhere; }
html[lang="en"] .cm-body { line-height: 1.6; }
.cm-admin { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; margin-top: 10px; }
.cm-admin .tag { text-decoration: none; max-width: 100%; overflow: hidden; text-overflow: ellipsis; }
.cm-admin form { margin: 0; margin-inline-start: auto; }
.cm-admin .icon-btn { width: 34px; height: 34px; }
.cm.is-new { animation: cm-in .7s var(--spring); }
@keyframes cm-in { from { opacity: 0; transform: translateY(-10px); } }
.cm.is-gone { opacity: 0; transform: scale(.98); transition: opacity .25s, transform .25s; }
.cm-empty { padding: 18px; text-align: center; color: var(--mist); }

.px-more { margin-top: 64px; }
.px-more > h2 { margin-bottom: 18px; font-size: 1.45rem; font-weight: 600; color: rgb(var(--c-title)); }

/* ---------- guides: the manual ---------- */
.gx-head { display: grid; grid-template-columns: minmax(0, 1fr) minmax(260px, 400px); align-items: end; gap: 18px 32px; margin-bottom: 20px; }
@media (max-width: 800px) { .gx-head { grid-template-columns: 1fr; } }
.gx-admin { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.gx-find { position: relative; display: block; }
.gx-find .ic { position: absolute; top: 50%; inset-inline-start: 15px; width: 19px; height: 19px; translate: 0 -50%; color: var(--mist); pointer-events: none; }
.gx-find input { width: 100%; height: 52px; padding: 0 14px; padding-inline-start: 46px; border-radius: 16px; border: 1px solid var(--line); background: var(--field); color: var(--parch); font-size: var(--fs-sm); }
.gx-find input::placeholder { color: var(--mist-2); }
.gx-find input:focus { outline: none; border-color: var(--gold); box-shadow: 0 0 0 4px rgb(var(--c-ac) / .16); }
.gx-jump { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 24px; }
.gx-jump a { display: inline-flex; align-items: center; gap: 7px; height: 38px; padding: 0 13px; border-radius: 12px; border: 1px solid var(--line-2); color: var(--mist); text-decoration: none; font-size: var(--fs-sm); background: rgb(var(--c-sf1) / .5); transition: color .2s, border-color .2s; }
.gx-jump a .ic { width: 16px; height: 16px; color: var(--gold-2); }
.gx-jump a:hover { color: var(--parch); border-color: var(--line); }
.gx-jump a.is-dim { opacity: .4; }
.gx-secs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; align-items: start; }
@media (max-width: 920px) { .gx-secs { grid-template-columns: 1fr; } }
.gx-sec { padding: 18px 18px 10px; border-radius: 24px; background: linear-gradient(170deg, rgb(var(--c-sf2) / .78), rgb(var(--c-sf1) / .92)); border: 1px solid var(--line-2); scroll-margin-top: 100px; }
.gx-sec:target { border-color: rgb(var(--c-ac) / .55); box-shadow: 0 0 0 4px rgb(var(--c-ac) / .12); }
.gx-sec-h { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 12px 14px; padding-bottom: 12px; margin-bottom: 4px; border-bottom: 1px solid var(--line-2); }
.gx-ic { width: 48px; height: 48px; display: grid; place-items: center; border-radius: 16px; color: var(--gold-2); background: rgb(var(--c-ac) / .12); box-shadow: inset 0 0 0 1px rgb(var(--c-ac) / .28); }
.gx-ic .ic { width: 23px; height: 23px; }
.gx-sec-h h2 { font-size: 1.2rem; font-weight: 600; line-height: 1.5; color: rgb(var(--c-title)); }
.gx-sec-h p { margin-top: 2px; font-size: var(--fs-xs); line-height: 1.8; color: var(--mist); }
.gx-sec-h small { align-self: start; font-size: var(--fs-xs); color: var(--mist-2); white-space: nowrap; }
.gx-list { list-style: none; margin: 0; padding: 0; }
.gx-list li + li { border-top: 1px dashed var(--line-2); }
.gx-list a { display: grid; grid-template-columns: 30px minmax(0, 1fr) auto; align-items: start; gap: 12px; padding: 12px 8px; margin-inline: -8px; border-radius: 14px; color: var(--parch); text-decoration: none; transition: background-color .2s; }
.gx-list a:hover { background: rgb(var(--c-ac) / .07); }
.gx-list a:hover .gx-n { color: rgb(var(--c-on)); background: var(--gold); border-color: var(--gold); }
.gx-n { width: 30px; height: 30px; margin-top: 1px; display: grid; place-items: center; border-radius: 50%; font-size: .85rem; font-weight: 600; color: var(--gold-2); border: 1px solid rgb(var(--c-ac) / .4); transition: color .2s, background-color .2s; }
.gx-t strong { display: block; font-weight: 600; line-height: 1.65; }
html[lang="en"] .gx-t strong { line-height: 1.35; }
.gx-t small { margin-top: 2px; font-size: var(--fs-xs); line-height: 1.8; color: var(--mist); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.gx-min { margin-top: 5px; display: inline-flex; align-items: center; gap: 4px; font-style: normal; font-size: var(--fs-xs); color: var(--mist-2); white-space: nowrap; }
.gx-min .ic { width: 14px; height: 14px; }
.gx-none { margin-top: 10px; }
.gx-help { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 12px 18px; margin-top: 32px; padding: 18px 20px; border-radius: 22px; border: 1px dashed rgb(var(--c-al) / .5); background: rgb(var(--c-al) / .05); }
.gx-help-ic { width: 48px; height: 48px; display: grid; place-items: center; border-radius: 16px; color: var(--turq-2); background: rgb(var(--c-al) / .13); }
.gx-help-ic .ic { width: 23px; height: 23px; }
.gx-help b { display: block; font-weight: 600; color: rgb(var(--c-title)); }
.gx-help p { font-size: var(--fs-sm); line-height: 1.85; color: var(--mist); }
@media (max-width: 640px) { .gx-help { grid-template-columns: auto minmax(0, 1fr); } .gx-help .btn { grid-column: 1 / -1; } }

/* one guide: the section on one side, the contents on the other */
.gd { display: grid; grid-template-columns: 250px minmax(0, 1fr) 220px; align-items: start; gap: 36px; }
.gd:not(.has-toc) { grid-template-columns: 250px minmax(0, 1fr); }
.gd-main { min-width: 0; max-width: 780px; }
.gd-side, .gd-toc { position: sticky; top: 104px; max-height: calc(100vh - 124px); overflow: auto; scrollbar-width: thin; }
.gd-all { display: inline-flex; align-items: center; gap: 6px; margin-bottom: 12px; font-size: var(--fs-sm); color: var(--mist); text-decoration: none; }
.gd-all:hover { color: var(--gold-2); }
.gd-all .ic { width: 16px; height: 16px; }
.gd-sib { padding: 6px; border-radius: 18px; border: 1px solid var(--line-2); background: rgb(var(--c-sf1) / .6); }
.gd-sib summary { display: flex; align-items: center; gap: 8px; padding: 8px 10px; cursor: pointer; list-style: none; font-weight: 600; font-size: var(--fs-sm); color: rgb(var(--c-title)); }
.gd-sib summary::-webkit-details-marker { display: none; }
.gd-sib summary .ic { width: 18px; height: 18px; color: var(--gold-2); }
.gd-sib ol { list-style: none; margin: 0; padding: 0 0 4px; }
.gd-sib a { display: grid; grid-template-columns: 22px minmax(0, 1fr); gap: 6px; padding: 7px 10px; border-radius: 11px; font-size: var(--fs-sm); line-height: 1.7; color: var(--mist); text-decoration: none; }
html[lang="en"] .gd-sib a { line-height: 1.4; }
.gd-sib a b { font-weight: 400; font-size: .75rem; color: var(--mist-2); padding-top: .2em; }
.gd-sib a:hover { color: var(--parch); background: rgb(var(--c-hl) / .04); }
.gd-sib .is-on a { color: var(--gold-2); background: rgb(var(--c-ac) / .11); }
.gd-sib .is-on a b { color: var(--gold-2); font-weight: 600; }
.gd-toc > b { display: block; margin-bottom: 8px; font-size: var(--fs-xs); font-weight: 600; color: var(--mist-2); }
.gd-toc ol { list-style: none; margin: 0; padding: 0; border-inline-start: 1px solid var(--line-2); }
.gd-toc a { display: block; margin-inline-start: -1px; padding: 5px 12px; border-inline-start: 2px solid transparent; font-size: var(--fs-xs); line-height: 1.75; color: var(--mist); text-decoration: none; transition: color .2s, border-color .2s; }
.gd-toc a:hover { color: var(--parch); }
.gd-toc a.is-on { color: var(--gold-2); border-color: var(--gold); }
.gd-head { display: grid; gap: 12px; margin-bottom: 26px; }
.gd-sec { justify-self: start; display: inline-flex; align-items: center; gap: 6px; font-size: var(--fs-sm); color: var(--gold-2); text-decoration: none; }
.gd-sec .ic { width: 17px; height: 17px; }
.gd-sec:hover { text-decoration: underline; }
.gd-cover { margin-inline: 0; }
.gd-toc-m { display: none; }
.gd-pn { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 44px; }
.gd-pn a { display: grid; align-content: start; gap: 4px; padding: 14px 16px; border-radius: 16px; border: 1px solid var(--line-2); background: rgb(var(--c-sf1) / .55); text-decoration: none; transition: border-color .2s, background-color .2s; }
.gd-pn a:hover { border-color: rgb(var(--c-ac) / .5); background: rgb(var(--c-ac) / .06); }
.gd-pn small { display: inline-flex; align-items: center; gap: 6px; font-size: var(--fs-xs); color: var(--mist); }
.gd-pn small .ic { width: 15px; height: 15px; }
.gd-pn b { font-weight: 600; line-height: 1.6; color: rgb(var(--c-title)); }
.gd-next { text-align: end; }
.gd-next small { justify-content: flex-end; }
.gd-help { margin-top: 18px; }
@media (max-width: 1220px) {
  .gd, .gd:not(.has-toc) { grid-template-columns: 230px minmax(0, 1fr); gap: 30px; }
  .gd-toc { display: none; }
  .gd-toc-m { display: block; }
}
@media (max-width: 880px) {
  .gd, .gd:not(.has-toc) { grid-template-columns: 1fr; gap: 14px; }
  .gd-side { position: static; max-height: none; overflow: visible; }
  .gd-pn { grid-template-columns: 1fr; }
}

/* =========================================================
   Admin → Content
   ========================================================= */
.ad-switch { display: flex; align-items: center; gap: 12px; margin-bottom: 18px; padding: 6px 18px; border-radius: 18px; border: 1px solid rgb(var(--c-bad) / .35); background: rgb(var(--c-bad) / .05); }
.ad-switch.is-open { border-color: rgb(var(--c-ok) / .4); background: rgb(var(--c-ok) / .06); }
.ad-switch .switch { flex: 1; }
.ad-filter { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
.ad-filter .input { height: 44px; min-width: 0; padding: 0 14px; border-radius: 13px; border: 1px solid var(--line); background: var(--field); color: var(--parch); }
.ad-filter input.input { flex: 1 1 220px; }
.ad-filter select.input { flex: 0 1 200px; }
.ad-filter .btn { height: 44px; }
.ad-count { margin-bottom: 10px; }
.ad-posts { display: grid; gap: 10px; }
.ad-post { display: grid; grid-template-columns: 112px minmax(0, 1fr) auto auto; align-items: center; gap: 12px 18px; padding: 10px 14px 10px 10px; border-radius: 18px; border: 1px solid var(--line-2); background: rgb(var(--c-sf1) / .7); }
[dir="rtl"] .ad-post { padding: 10px 10px 10px 14px; }
.ad-thumb { width: 112px; aspect-ratio: 16 / 9; display: grid; place-items: center; border-radius: 12px; overflow: hidden; color: var(--gold-2); background: rgb(var(--c-sf3)); }
.ad-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ad-thumb .ic { width: 26px; height: 26px; }
.ad-title { display: block; font-weight: 600; line-height: 1.6; color: rgb(var(--c-title)); text-decoration: none; }
.ad-title:hover { color: var(--gold-2); }
.ad-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 12px; margin-top: 4px; font-size: var(--fs-xs); color: var(--mist); }
.ad-meta > span:not(.tag) { display: inline-flex; align-items: center; gap: 5px; }
.ad-meta .ic { width: 14px; height: 14px; }
.ad-slug { color: var(--mist-2); }
.ad-nums { display: flex; gap: 14px; font-size: var(--fs-sm); color: var(--mist); }
.ad-nums > * { display: inline-flex; align-items: center; gap: 5px; color: inherit; text-decoration: none; font-variant-numeric: tabular-nums; }
.ad-nums a:hover { color: var(--gold-2); }
.ad-nums .ic { width: 16px; height: 16px; }
@media (max-width: 860px) {
  .ad-post, [dir="rtl"] .ad-post { grid-template-columns: 84px minmax(0, 1fr); padding: 10px; }
  .ad-thumb { width: 84px; }
  .ad-nums, .ad-post .apl-acts { grid-column: 1 / -1; }
  .ad-post .apl-acts { justify-content: flex-start; }
}

/* the editor */
.ce { display: grid; grid-template-columns: minmax(0, 1fr) 320px; align-items: start; gap: 22px; }
@media (max-width: 1060px) { .ce { grid-template-columns: 1fr; } }
.ce-main { min-width: 0; padding: 20px; border-radius: var(--r-lg); border: 1px solid var(--line-2); background: linear-gradient(180deg, rgb(var(--c-sf2) / .5), rgb(var(--c-sf1) / .62)); }
.ce-lang { display: inline-flex; gap: 4px; padding: 4px; margin-bottom: 16px; border-radius: 14px; background: rgb(var(--c-hl) / .05); border: 1px solid var(--line-2); }
.ce-lang button { height: 38px; padding: 0 16px; border: 0; border-radius: 11px; background: none; color: var(--mist); cursor: pointer; font-size: var(--fs-sm); }
.ce-lang button[aria-selected="true"] { color: var(--gold-2); background: rgb(var(--c-ac) / .15); box-shadow: inset 0 0 0 1px rgb(var(--c-ac) / .35); }
.ce-lang small { font-size: .7rem; opacity: .75; }
.ce-hint { display: flex; align-items: flex-start; gap: 8px; margin-bottom: 14px; font-size: var(--fs-xs); color: var(--mist); }
.ce-hint .ic { width: 15px; height: 15px; flex: none; margin-top: 3px; color: var(--turq-2); }
.field input.ce-title { height: 54px; font-size: 1.2rem; font-weight: 600; }
.field textarea.ce-x { min-height: 0; }
.ce-ed { gap: 0; }
.ce-ed > label { margin-bottom: 6px; }
.ce-bar { position: sticky; top: 84px; z-index: 3; display: flex; flex-wrap: wrap; align-items: center; gap: 2px; padding: 5px; border: 1px solid var(--line); border-bottom: 0; border-radius: 14px 14px 0 0; background: rgb(var(--c-sf2)); }
.ce-b { height: 34px; min-width: 34px; display: inline-flex; align-items: center; justify-content: center; gap: 6px; padding: 0 8px; border: 0; border-radius: 9px; background: none; color: var(--mist); cursor: pointer; font-size: var(--fs-xs); }
.ce-b .ic { width: 17px; height: 17px; }
.ce-b:hover { color: var(--gold-2); background: rgb(var(--c-ac) / .1); }
.ce-b[aria-pressed="true"] { color: var(--gold-2); background: rgb(var(--c-ac) / .16); }
.ce-b.is-busy { opacity: .6; pointer-events: none; }
.ce-bar-gap { flex: 1; }
.field textarea.ce-body { min-height: 460px; border-radius: 0 0 14px 14px; font-size: .98rem; line-height: 1.95; tab-size: 2; }
.field textarea.ce-body[dir="ltr"] { line-height: 1.7; font-family: var(--latin); }
.field textarea.ce-body.is-drop { border-color: var(--turq); box-shadow: 0 0 0 4px rgb(var(--c-al) / .18); }
.ce-preview { min-height: 460px; padding: 18px 20px; border: 1px solid var(--line); border-radius: 0 0 14px 14px; background: rgb(var(--c-bg0) / .55); }
.ce-foot { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px 14px; margin-top: 8px; font-size: var(--fs-xs); color: var(--mist-2); }
.ce-drop { display: inline-flex; align-items: center; gap: 6px; }
.ce-drop .ic { width: 14px; height: 14px; }
.ce-help { margin-top: 6px; border-radius: 14px; border: 1px solid var(--line-2); }
.ce-help summary { display: flex; align-items: center; gap: 8px; padding: 10px 14px; cursor: pointer; list-style: none; font-size: var(--fs-sm); color: var(--mist); }
.ce-help summary::-webkit-details-marker { display: none; }
.ce-help summary .ic { width: 16px; height: 16px; color: var(--turq-2); }
.ce-help-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px 18px; padding: 4px 14px 14px; font-size: var(--fs-xs); }
.ce-help-grid > div { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; }
.ce-help-grid code { font-family: var(--mono); font-size: .78rem; padding: 1px 6px; border-radius: 6px; background: rgb(var(--c-hl) / .06); border: 1px solid var(--line-2); direction: rtl; unicode-bidi: isolate; }
.ce-help-grid span { flex-basis: 100%; color: var(--mist); }
@media (max-width: 700px) { .ce-help-grid { grid-template-columns: 1fr; } }
.ce-side { display: grid; gap: 14px; }
@media (min-width: 1061px) { .ce-side { position: sticky; top: 92px; } }
.ce-box { padding: 16px; border-radius: 18px; border: 1px solid var(--line-2); background: rgb(var(--c-sf1) / .72); }
.ce-box > h2 { margin-bottom: 12px; font-size: var(--fs-md); font-weight: 600; color: rgb(var(--c-title)); }
.ce-box .field { margin-bottom: 12px; }
.ce-box .field > a.small { justify-self: start; }
.ce-box .switch { padding: 6px 0; }
.ce-status { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; margin-bottom: 12px; }
.ce-status label { position: relative; }
.ce-status input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.ce-status span { display: flex; align-items: center; justify-content: center; gap: 6px; height: 42px; border-radius: 12px; border: 1px solid var(--line-2); font-size: var(--fs-sm); color: var(--mist); transition: .2s; }
.ce-status span .ic { width: 16px; height: 16px; }
.ce-status input:checked + span { color: var(--gold-2); border-color: rgb(var(--c-ac) / .55); background: rgb(var(--c-ac) / .12); }
.ce-status input:focus-visible + span { outline: 2px solid var(--gold); outline-offset: 2px; }
.ce-when { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 0 10px; }
.ce-note { margin: -2px 0 12px; font-size: var(--fs-xs); line-height: 1.8; color: var(--mist-2); }
.ce-cover { position: relative; aspect-ratio: 16 / 9; margin-bottom: 10px; display: grid; place-items: center; border-radius: 14px; overflow: hidden; border: 1px dashed var(--line); background: rgb(var(--c-bg0) / .5); }
.ce-cover img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.ce-cover.has-img { border-style: solid; border-color: var(--line-2); }
.ce-cover-empty { display: grid; justify-items: center; gap: 4px; font-size: var(--fs-xs); color: var(--mist-2); }
.ce-cover-empty .ic { width: 28px; height: 28px; }
.ce-cover.is-busy::after { content: ""; position: absolute; inset: 0; background: rgb(var(--c-bg0) / .55); }
.ce-cover-act { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.ce-cover-act label { cursor: pointer; }
.ce-slug { display: flex; align-items: stretch; border-radius: 13px; border: 1px solid var(--line); background: var(--field); overflow: hidden; }
.ce-slug span { display: grid; place-items: center; padding: 0 2px 0 10px; font-family: var(--latin); font-size: var(--fs-xs); color: var(--mist-2); white-space: nowrap; }
.field .ce-slug input { flex: 1; min-width: 0; height: 44px; border: 0; border-radius: 0; background: none; box-shadow: none; padding-inline-start: 2px; }
.ce-slug:focus-within { border-color: var(--gold); box-shadow: 0 0 0 3px rgb(var(--c-ac) / .15); }
.ce-votes { display: grid; grid-template-columns: 1fr 1fr; gap: 0 10px; margin-top: 8px; }
.ce-votes label { display: inline-flex; align-items: center; gap: 6px; }
.ce-votes label .ic { width: 15px; height: 15px; }
.ce-del { justify-self: start; }

/* categories */
.cat-panel { scroll-margin-top: 100px; }
.cat-list { display: grid; gap: 8px; margin-bottom: 12px; }
.cat-row, .cat-new { border-radius: 16px; border: 1px solid var(--line-2); background: rgb(var(--c-sf1) / .6); }
.cat-row > summary, .cat-new > summary { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; padding: 10px 14px; cursor: pointer; list-style: none; }
.cat-row > summary::-webkit-details-marker, .cat-new > summary::-webkit-details-marker { display: none; }
.cat-ic { width: 38px; height: 38px; display: grid; place-items: center; border-radius: 12px; color: var(--gold-2); background: rgb(var(--c-ac) / .12); }
.cat-ic .ic { width: 19px; height: 19px; }
.cat-name { flex: 1 1 200px; display: grid; }
.cat-name b { font-weight: 600; }
.cat-name small { font-size: var(--fs-xs); color: var(--mist-2); justify-self: start; }
.cat-chev { width: 18px; height: 18px; color: var(--mist); transition: transform .2s; }
.cat-row[open] .cat-chev { transform: rotate(180deg); }
.cat-body { display: grid; gap: 10px; padding: 4px 14px 14px; }
.cat-body > form:last-child { justify-self: start; }
.cat-new { border-style: dashed; }
.cat-new > summary { color: var(--gold-2); }
.cat-new > summary .ic { width: 18px; height: 18px; }
.cat-new .cat-form { padding: 4px 14px 14px; }
.cat-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 12px; }
@media (max-width: 640px) { .cat-grid { grid-template-columns: 1fr; } }
.cat-icons { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 14px; padding: 0; border: 0; }
.cat-icons legend { width: 100%; margin-bottom: 6px; font-size: var(--fs-sm); color: var(--mist); }
.cat-icons label { position: relative; }
.cat-icons input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.cat-icons span { width: 38px; height: 38px; display: grid; place-items: center; border-radius: 11px; border: 1px solid var(--line-2); color: var(--mist); }
.cat-icons span .ic { width: 18px; height: 18px; }
.cat-icons input:checked + span { color: var(--gold-2); border-color: rgb(var(--c-ac) / .6); background: rgb(var(--c-ac) / .13); }
.cat-icons input:focus-visible + span { outline: 2px solid var(--gold); outline-offset: 2px; }

/* every comment */
.ad-cms .cm { padding-inline: 14px; border-radius: 16px; border: 1px solid var(--line-2); background: rgb(var(--c-sf1) / .6); }
.ad-cms .cm + .cm { margin-top: 10px; }
.cm-on { display: inline-flex; align-items: center; gap: 5px; font-size: var(--fs-xs); color: var(--mist); text-decoration: none; }
.cm-on .ic { width: 14px; height: 14px; }
.cm-on:hover { color: var(--gold-2); }

/* rainbow and the haunted night get their own touches */
[data-theme="rainbow"] :is(.pc, .gx-sec, .px-react, .cm-form, .ce-main, .ce-box) { border-radius: 30px; border: 2px solid #fff; box-shadow: 0 14px 34px -22px rgb(230 90 160 / .45); }
[data-theme="rainbow"] .pc-big { border-radius: 34px; }
[data-theme="rainbow"] .md ol > li::before { background: linear-gradient(180deg, #FFD6EB, #FF9CCD); color: rgb(92 12 72); }
[data-theme="rainbow"] .md h2::before, [data-theme="rainbow"] .md hr { background: #FF9ECF; }
[data-theme="dark"] .pc:hover { box-shadow: 0 0 0 1px rgb(255 30 50 / .35), 0 30px 60px -30px rgb(200 0 30 / .5); }
[data-theme="dark"] .pc-aim { --a: rgb(255 120 120 / .95); filter: drop-shadow(0 0 4px rgb(255 30 50 / .8)); }

@media (prefers-reduced-motion: reduce) {
  .pc, .pc-pic img, .pc-aim, .vote, .cm { transition: none !important; animation: none !important; }
  .pc:hover .pc-pic img { transform: none; }
}
@media print {
  .px-react, .cm-wrap, .px-more, .gd-side, .gd-toc, .gd-pn, .gx-help, .cx-closed { display: none !important; }
}

/* Admin → Content → Comments: the rules panel (5.10.1) */
.panel.cm-rules { padding: 0; margin: 0 0 18px; }
.cm-rules > summary { display: flex; align-items: center; gap: 12px; padding: 14px 18px; cursor: pointer; list-style: none; }
.cm-rules > summary::-webkit-details-marker { display: none; }
.cm-rules > summary > .ic { flex: none; width: 22px; height: 22px; color: var(--gold-2); }
.cm-rules > summary > span:not(.tag) { display: flex; flex-direction: column; flex: 1; min-width: 0; line-height: 1.6; }
.cm-rules > summary small { color: var(--mist); font-size: var(--fs-xs); }
.cm-rules[open] > summary { border-bottom: 1px solid var(--line-2); }
.cm-rules-body { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 18px; align-items: start; padding: 16px 18px 18px; }
.cm-rules-list { display: grid; gap: 8px; margin: 0; padding: 12px 14px; list-style: none; border-radius: 14px; font-size: var(--fs-xs); line-height: 1.85; background: rgb(var(--c-hl) / .035); border: 1px solid var(--line-2); }
.cm-rules-list li { display: flex; align-items: flex-start; gap: 8px; }
.cm-rules-list .ic { flex: none; width: 15px; height: 15px; margin-top: 3px; color: var(--mist); }
.cm-rules-form .field { margin: 0 0 12px; }
.cm-rules-form textarea { min-height: 128px; }
@media (max-width: 900px) { .cm-rules-body { grid-template-columns: 1fr; } }
.empty-acts { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
.empty-acts form { display: contents; }
