/* Components added with the CMS rewrite; they only use the tokens and patterns of site.css. */

.app__title h1 {
  font-size: clamp(1.8rem, 3vw + 1rem, 2.75rem);
}

.nav a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

/* header dropdown */
.nav__dd {
  position: relative;
}

.nav__sub {
  position: absolute;
  top: 100%;
  left: 0;
  z-index: 60;
  display: none;
  min-width: 230px;
  margin: 0;
  padding: 8px;
  list-style: none;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(14, 15, 22, 0.97);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.45);
}

.nav__dd:hover .nav__sub,
.nav__dd:focus-within .nav__sub {
  display: block;
}

.nav__sub a {
  display: flex;
  width: 100%;
  border-radius: 12px;
}

.nav__sub img {
  border-radius: 7px;
}

/* mobile menu */
.mnav {
  display: none;
}

.mnav summary {
  display: inline-flex;
  width: 44px;
  height: 44px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--glass);
  cursor: pointer;
  list-style: none;
}

.mnav summary::-webkit-details-marker {
  display: none;
}

.mnav__bars,
.mnav__bars::before,
.mnav__bars::after {
  display: block;
  width: 18px;
  height: 2px;
  border-radius: 2px;
  background: var(--text);
  content: "";
}

.mnav__bars {
  position: relative;
}

.mnav__bars::before {
  position: absolute;
  top: -6px;
}

.mnav__bars::after {
  position: absolute;
  top: 6px;
}

.mnav__panel {
  position: absolute;
  top: 64px;
  right: 0;
  left: 0;
  display: grid;
  gap: 2px;
  padding: 12px 24px 20px;
  border-bottom: 1px solid var(--line);
  background: var(--bg);
  box-shadow: 0 18px 30px rgba(0, 0, 0, 0.5);
}

.mnav__panel a {
  padding: 12px 8px;
  border-radius: 12px;
  color: var(--text);
  font-weight: 700;
  text-decoration: none;
}

.mnav__panel a:hover {
  background: rgba(255, 255, 255, 0.06);
}

.mnav__panel .mnav__sub {
  padding-left: 28px;
  color: var(--text-2);
  font-weight: 600;
}

.mnav__sep {
  margin: 8px 0 4px;
  border-top: 1px solid var(--line);
}

.mnav__panel a.mnav__soc {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text-2);
  font-weight: 600;
}

@media (max-width: 639px) {
  .nav {
    display: none;
  }

  .mnav {
    display: block;
  }
}

/* news */
.newsgrid {
  margin-top: 8px;
}

.newscard {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  text-decoration: none;
  transition: transform 0.25s, border-color 0.25s;
}

.newscard:hover {
  transform: translateY(-4px);
  border-color: rgba(255, 255, 255, 0.22);
}

.newscard__cover {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

.newscard__body {
  display: grid;
  gap: 8px;
  padding: 22px 24px 26px;
}

.newscard__meta {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--muted);
  font-size: 0.875rem;
  font-weight: 600;
}

.views {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}

.views .icon {
  width: 1.15em;
  height: 1.15em;
}

.newscard__meta .views {
  margin-left: auto;
}

.eyebrow .views {
  vertical-align: bottom;
}

.newscard h3 {
  font-size: 1.25rem;
}

.newscard p {
  color: var(--text-2);
  line-height: 1.55;
}

.newsmore {
  margin-top: 28px;
}

.newsfilter {
  margin: 0 0 20px;
  padding: 0;
  list-style: none;
}

.newsfilter a {
  text-decoration: none;
}

.chip--on {
  border-color: rgba(255, 255, 255, 0.4);
  background: rgba(255, 255, 255, 0.12);
  color: var(--text);
}

.pager {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-top: 32px;
  color: var(--text-2);
}

.postcover {
  width: 100%;
  margin: 24px 0 8px;
  border-radius: 20px;
}

/* cookie banner */
.cookie {
  position: fixed;
  right: 16px;
  bottom: 16px;
  left: 16px;
  z-index: 90;
  display: grid;
  gap: 14px;
  max-width: 560px;
  margin: 0 auto;
  padding: 18px 20px;
  background: rgba(14, 15, 22, 0.96);
  font-size: 0.9375rem;
}

.cookie[hidden] {
  display: none;
}

.cookie p {
  color: var(--text-2);
  line-height: 1.5;
}

.cookie a {
  color: var(--text);
}

.cookie__btns {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

@media (min-width: 720px) {
  .cookie {
    right: auto;
    left: 24px;
    margin: 0;
  }
}

.linkbtn {
  padding: 0;
  border: 0;
  background: none;
  color: var(--text-2);
  font: inherit;
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
}

.linkbtn:hover {
  color: var(--text);
}

/* draft preview bar */
.previewbar {
  position: fixed;
  top: 0;
  right: 0;
  left: 0;
  z-index: 200;
  padding: 6px 16px;
  background: #f59e0b;
  color: #1a1204;
  font-size: 0.8125rem;
  font-weight: 800;
  text-align: center;
}

/* accounts */
.acclink { padding: 8px 12px; border-radius: 999px; color: var(--text-2); font-size: 0.9375rem; font-weight: 700; text-decoration: none; }
.acclink:hover { color: var(--text); background: rgba(255, 255, 255, 0.06); }
@media (max-width: 639px) { .acclink { display: none; } }

.acct { max-width: 760px; }
.acct h1 { margin-bottom: 24px; }
.acct__card { margin: 0 0 20px; padding: 24px; }
.acct__card h2 { margin: 0 0 14px; font-size: 1.4rem; }
.acct__card h3 { margin: 22px 0 10px; font-size: 1.1rem; }
.acct__form { display: grid; gap: 14px; }
.acct__field { display: grid; gap: 6px; font-weight: 700; font-size: 0.9375rem; }
.acct__field input[type="text"], .acct__field input[type="email"], .acct__field input[type="password"] {
  width: 100%; padding: 12px 16px; border: 1px solid var(--line); border-radius: 14px; background: rgba(255, 255, 255, 0.05);
  color: var(--text); font: 1rem var(--font);
}
.acct__field input:focus, .acct__field input:focus-visible { outline: 2px solid var(--violet); outline-offset: 1px; }
.acct__field input[type="file"] { color: var(--text-2); font: inherit; }
.acct__err { min-height: 0; color: #fda4af; font-weight: 700; }
.acct__err:empty { display: none; }
.acct__status { margin: 0; color: #fda4af; font-weight: 700; }
.acct__status:empty { display: none; }
.acct__check { display: flex; align-items: flex-start; gap: 10px; }
.acct__check input { margin-top: 5px; width: 18px; height: 18px; flex: none; }
.acct__check a { color: var(--text); }
.acct__profile { display: flex; align-items: center; gap: 18px; }
.acct__avatar { width: 72px; height: 72px; border-radius: 50%; object-fit: cover; }
.acct__avatar--none { display: grid; place-items: center; background: var(--brand); color: #fff; font-size: 1.8rem; font-weight: 800; }
.acct__app { display: grid; gap: 10px; padding: 14px 0; border-top: 1px solid var(--line); }
.acct__app:first-of-type { border-top: 0; }
.acct__apphead { display: flex; align-items: center; gap: 12px; }
.acct__apphead img { border-radius: 12px; }
.acct__row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }
.acct__danger { border-color: rgba(244, 63, 94, 0.6); color: #fda4af; }
.acct a { color: var(--text); text-underline-offset: 3px; }

/* forum */
.forum__list { display: grid; gap: 14px; margin-top: 24px; }
.forum__row { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 20px 24px; text-decoration: none; transition: border-color 0.25s, transform 0.25s; }
.forum__row:hover { border-color: rgba(255, 255, 255, 0.25); transform: translateY(-2px); }
.forum__row h2 { margin: 0 0 4px; font-size: 1.2rem; }
.forum__row p { margin: 0; color: var(--text-2); }
.forum__meta { flex: none; color: var(--muted); font-size: 0.875rem; text-align: right; }
.forum__posts { display: grid; gap: 14px; margin: 24px 0; }
.forum__post { padding: 18px 22px; }
.forum__post header { margin-bottom: 8px; }
.forum__body p { margin: 0 0 10px; overflow-wrap: anywhere; }
.forum__body a { color: var(--text); }
.forum__actions { display: flex; gap: 14px; margin-top: 8px; font-size: 0.875rem; }
.forum__reply { margin-top: 28px; }
.forum textarea, .forum select, .acct__field textarea, .acct__field select { width: 100%; padding: 12px 16px; border: 1px solid var(--line); border-radius: 14px; background: rgba(255, 255, 255, 0.05); color: var(--text); font: 1rem var(--font); }
.forum select option { background: #12141d; color: #f2f3f7; }
@media (max-width: 639px) { .forum__row { flex-direction: column; align-items: flex-start; } .forum__meta { text-align: left; } }
.forum .lead { margin-bottom: 20px; }
.forum > p { margin-top: 16px; }

/* achievements */
.ach__grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; margin: 12px 0 0; padding: 0; list-style: none; }
.ach { display: grid; gap: 4px; align-content: start; padding: 14px; border: 1px solid var(--line); border-radius: 16px; background: rgba(255, 255, 255, 0.03); }
.ach strong { font-size: 0.95rem; }
.ach small { color: var(--text-2); font-size: 0.8rem; }
.ach__circle { display: grid; place-items: center; width: 44px; height: 44px; margin-bottom: 6px; border-radius: 50%; background: var(--brand); }
.ach__icon { width: 24px; height: 24px; fill: none; stroke: #fff; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.ach--off { opacity: 0.6; }
.ach--off .ach__circle { background: rgba(255, 255, 255, 0.12); }
.ach__bar { position: relative; height: 6px; margin-top: 8px; border-radius: 3px; background: rgba(255, 255, 255, 0.12); }
.ach__bar span { display: block; height: 100%; border-radius: 3px; background: var(--brand); }
.ach__bar em { position: absolute; top: 10px; left: 0; color: var(--text-2); font-size: 0.75rem; font-style: normal; }
.ach--off:has(.ach__bar) { padding-bottom: 30px; }
