/* ==========================================================================
   Rocco Help Center theme — Copenhagen restyled to match rocco-website
   - Palette: deep navy #051626, purple #635BFF, cyan accent #00D4FF
   - Type:    Plus Jakarta Sans (headings), Inter (body)
   - Driven by Zendesk theme settings (#051626, #635BFF, etc.)
   ========================================================================== */

/* ---------- Reset / base ------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  font-size: 16px;
}

body {
  margin: 0;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  color: #051626;
  background-color: #FFFFFF;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img, svg { max-width: 100%; vertical-align: middle; }
button { font: inherit; }
ul, ol { padding: 0; margin: 0; list-style: none; }
hr { border: 0; border-top: 1px solid #E8ECEF; margin: 32px 0; }

h1, h2, h3, h4, h5, h6 {
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
  color: #051626;
  margin: 0;
  letter-spacing: -0.01em;
  line-height: 1.2;
  font-weight: 700;
}

h1 { font-size: 40px; letter-spacing: -0.02em; }
h2 { font-size: 28px; }
h3 { font-size: 22px; }
h4 { font-size: 18px; }

@media (max-width: 768px) {
  h1 { font-size: 30px; }
  h2 { font-size: 24px; }
}

a {
  color: #635BFF;
  text-decoration: none;
  transition: color 150ms ease;
}
a:hover { color: #4A43E8; }
a:visited { color: #635BFF; }
a:focus-visible {
  outline: 2px solid #635BFF;
  outline-offset: 2px;
  border-radius: 4px;
}

p { margin: 0 0 16px; }

/* ---------- Layout helpers ---------------------------------------------- */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}
@media (max-width: 640px) { .container { padding: 0 16px; } }

.section { padding: 48px 0; }
@media (max-width: 768px) { .section { padding: 32px 0; } }

.skip-navigation {
  position: absolute;
  left: -9999px;
  top: auto;
  width: 1px; height: 1px;
  overflow: hidden;
  background: #635BFF;
  color: #fff;
  padding: 10px 18px;
  border-radius: 12px;
  font-weight: 600;
  z-index: 9999;
}
.skip-navigation:focus {
  position: fixed;
  left: 16px; top: 16px;
  width: auto; height: auto;
  outline: 2px solid #fff;
  outline-offset: 2px;
}

.visibility-hidden {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ---------- Header ------------------------------------------------------- */
.header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  height: 80px;
  padding: 0 24px;
  background: rgba(255, 255, 255, 0.85);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid #E8ECEF;
  position: sticky;
  top: 0;
  z-index: 100;
}
@media (max-width: 640px) {
  .header { padding: 0 16px; height: 72px; }
}

.logo { display: flex; align-items: center; min-width: 0; }
.logo a {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #051626;
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
  font-weight: 700;
  font-size: 20px;
  letter-spacing: -0.01em;
}
.logo a:hover { color: #051626; }
.logo img {
  display: block;
  max-height: 36px;
  width: auto;
}
.logo span {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ---------- Navigation -------------------------------------------------- */
.nav-wrapper-desktop {
  display: flex;
  align-items: center;
  gap: 24px;
}
@media (max-width: 768px) { .nav-wrapper-desktop { display: none; } }

.user-nav-list {
  display: flex;
  align-items: center;
  gap: 8px;
}
.user-nav-list > li { display: inline-flex; }
.user-nav-list a {
  display: inline-flex;
  align-items: center;
  padding: 8px 14px;
  border-radius: 9999px;
  color: #051626;
  font-size: 14px;
  font-weight: 500;
}
.user-nav-list a:hover { color: #635BFF; background: rgba(99, 91, 255, 0.06); }

.user-nav-list .submit-a-request {
  background: #635BFF;
  color: #fff;
  padding: 10px 18px;
  font-weight: 600;
  box-shadow: 0 6px 18px rgba(99, 91, 255, 0.18);
}
.user-nav-list .submit-a-request:hover {
  background: #4A43E8;
  color: #fff;
}

.user-nav-list .sign-in {
  border: 1px solid #E8ECEF;
  padding: 8px 16px;
  font-weight: 500;
}
.user-nav-list .sign-in:hover {
  border-color: #635BFF;
  color: #635BFF;
  background: transparent;
}

/* User-info dropdown trigger (signed-in) */
.user-info { position: relative; }
.user-info .dropdown-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 4px 12px 4px 4px;
  border: 1px solid #E8ECEF;
  border-radius: 9999px;
  background: #fff;
  cursor: pointer;
  color: #051626;
  font-size: 14px;
  font-weight: 500;
  transition: border-color 150ms ease, background 150ms ease;
}
.user-info .dropdown-toggle:hover {
  border-color: #635BFF;
  background: rgba(99, 91, 255, 0.04);
}
.user-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  object-fit: cover;
}

/* ---------- Mobile menu ------------------------------------------------- */
.nav-wrapper-mobile { display: none; position: relative; }
@media (max-width: 768px) { .nav-wrapper-mobile { display: block; } }

.menu-button-mobile {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 6px 6px 14px;
  background: #fff;
  border: 1px solid #E8ECEF;
  border-radius: 9999px;
  cursor: pointer;
  color: #051626;
}
.menu-button-mobile:hover { border-color: #635BFF; }
.menu-button-mobile .icon-menu { width: 20px; height: 20px; }
.menu-button-mobile .user-avatar { width: 28px; height: 28px; }

.menu-list-mobile {
  display: none;
  position: absolute;
  top: calc(100% + 12px);
  right: 0;
  min-width: 280px;
  max-width: calc(100vw - 32px);
  background: #fff;
  border: 1px solid #E8ECEF;
  border-radius: 16px;
  box-shadow: 0 12px 32px rgba(5, 22, 38, 0.12);
  padding: 8px;
  z-index: 99;
}
.menu-list-mobile[aria-expanded="true"] { display: block; }

.menu-list-mobile-items { display: flex; flex-direction: column; gap: 2px; }
.menu-list-mobile-items .item { display: flex; }
.menu-list-mobile-items .item > a,
.menu-list-mobile-items .item .my-profile {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 12px 14px;
  border-radius: 10px;
  color: #051626;
  font-size: 15px;
  font-weight: 500;
}
.menu-list-mobile-items .item > a:hover,
.menu-list-mobile-items .item .my-profile:hover {
  background: rgba(99, 91, 255, 0.06);
  color: #635BFF;
}
.menu-list-mobile-items .submit-a-request {
  background: #635BFF;
  color: #fff !important;
}
.menu-list-mobile-items .submit-a-request:hover {
  background: #4A43E8;
  color: #fff !important;
}
.user-avatar-item .menu-profile-avatar {
  width: 40px; height: 40px; border-radius: 50%;
}
.menu-profile-name {
  display: flex;
  flex-direction: column;
  line-height: 1.3;
}
.my-profile-tooltip {
  font-size: 12px;
  color: #5B6470;
  font-weight: 400;
}
.nav-divider {
  height: 1px;
  background: #E8ECEF;
  margin: 6px 4px;
}

/* ---------- Generic dropdown (header user, footer language) ------------- */
.dropdown { position: relative; display: inline-block; }
.dropdown-toggle {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: none;
  border: none;
  cursor: pointer;
  font: inherit;
  color: inherit;
  padding: 8px 12px;
  border-radius: 8px;
}
.dropdown-toggle:hover { color: #635BFF; }
.dropdown-chevron-icon {
  width: 12px; height: 12px;
  transition: transform 150ms ease;
}
.dropdown[aria-expanded="true"] .dropdown-chevron-icon,
.dropdown-toggle[aria-expanded="true"] .dropdown-chevron-icon {
  transform: rotate(180deg);
}

.dropdown-menu {
  display: none;
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  min-width: 200px;
  padding: 8px;
  background: #fff;
  border: 1px solid #E8ECEF;
  border-radius: 12px;
  box-shadow: 0 12px 32px rgba(5, 22, 38, 0.10);
  z-index: 200;
}
.dropdown.open > .dropdown-menu,
.dropdown-menu[aria-expanded="true"],
.dropdown-toggle[aria-expanded="true"] + .dropdown-menu {
  display: block;
}
.dropdown-menu-end { left: auto; right: 0; }
.dropdown-menu a,
.dropdown-menu [role="menuitem"] {
  display: block;
  padding: 10px 12px;
  border-radius: 8px;
  color: #051626;
  font-size: 14px;
  white-space: nowrap;
}
.dropdown-menu a:hover,
.dropdown-menu [role="menuitem"]:hover {
  background: rgba(99, 91, 255, 0.06);
  color: #635BFF;
}
.separator {
  height: 1px;
  background: #E8ECEF;
  margin: 6px 0;
}

/* ---------- Hero + search (home page) ----------------------------------- */
.hero {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  min-height: 360px;
  padding: 96px 24px;
  background:
    radial-gradient(ellipse at 50% 0%, rgba(99, 91, 255, 0.10) 0%, rgba(99, 91, 255, 0) 60%),
    radial-gradient(ellipse at 80% 100%, rgba(0, 212, 255, 0.06) 0%, rgba(0, 212, 255, 0) 50%),
    #FFFFFF;
  border-bottom: 1px solid #E8ECEF;
}
@media (max-width: 768px) {
  .hero { min-height: 240px; padding: 56px 16px; }
}

.hero-inner {
  position: relative;
  width: 100%;
  max-width: 720px;
  display: flex;
  align-items: center;
}
/* Hide ALL inline SVG search-icons; we draw the magnifying glass directly on the input
   as a background-image so positioning is bulletproof and identical on every page. */
svg.search-icon { display: none !important; }
@media (max-width: 768px) {
  .hero-inner .search-icon { left: 18px; width: 16px; height: 16px; }
}

/* ---------- Search input (used in hero + sub-nav) ----------------------- */
/* Override the generic `form { display: flex }` rule so the absolute
   search-icon centers correctly against the input only. */
.search,
form[role="search"] {
  position: relative;
  width: 100%;
  display: block;
  flex-direction: row;
  gap: 0;
}
.search input[type="search"],
.search input[type="text"] {
  width: 100%;
  height: 64px;
  padding: 0 56px 0 56px;
  border: 1px solid #E8ECEF;
  border-radius: 9999px;
  background-color: #fff;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'><circle cx='4.5' cy='4.5' r='4' fill='none' stroke='%235B6470' stroke-width='1'/><path stroke='%235B6470' stroke-linecap='round' stroke-width='1' d='M11 11L7.5 7.5'/></svg>");
  background-repeat: no-repeat;
  background-position: 22px center;
  background-size: 18px 18px;
  color: #051626;
  font-family: inherit;
  font-size: 17px;
  box-shadow: 0 1px 2px rgba(5, 22, 38, 0.04);
  transition: border-color 150ms ease, box-shadow 150ms ease;
  -webkit-appearance: none;
  appearance: none;
}
.search input::placeholder { color: #5B6470; }
.search input:focus {
  outline: none;
  border-color: #635BFF;
  box-shadow: 0 0 0 4px rgba(99, 91, 255, 0.15);
}
@media (max-width: 768px) {
  .search input[type="search"],
  .search input[type="text"] {
    height: 56px;
    font-size: 16px;
    padding-left: 48px;
  }
}

/* Native search clear button */
.search input::-webkit-search-cancel-button { -webkit-appearance: none; }

/* JS-injected clear button (script.js — class "clear-button" added by buildClearSearchButton) */
.search .clear-button,
form[role="search"] .clear-button {
  display: none;
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  width: 28px;
  height: 28px;
  padding: 0;
  margin: 0;
  border: 0;
  background: transparent;
  border-radius: 50%;
  cursor: pointer;
  color: #5B6470;
  align-items: center;
  justify-content: center;
  -webkit-appearance: none;
  appearance: none;
}
.search.search-has-value .clear-button,
form[role="search"].search-has-value .clear-button { display: inline-flex; }
.search .clear-button:hover,
form[role="search"] .clear-button:hover {
  background: rgba(5, 22, 38, 0.08);
  color: #051626;
}
.search .clear-button svg,
form[role="search"] .clear-button svg {
  width: 12px;
  height: 12px;
}

/* Instant search results dropdown */
.search-results-dropdown,
.search .results {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  background: #fff;
  border: 1px solid #E8ECEF;
  border-radius: 16px;
  box-shadow: 0 16px 40px rgba(5, 22, 38, 0.12);
  padding: 8px;
  z-index: 50;
  text-align: left;
  max-height: 60vh;
  overflow-y: auto;
}
.search-results-dropdown a,
.search .results a {
  display: block;
  padding: 12px 14px;
  border-radius: 10px;
  color: #051626;
  font-size: 15px;
}
.search-results-dropdown a:hover,
.search .results a:hover {
  background: rgba(99, 91, 255, 0.06);
  color: #635BFF;
}

/* Sub-nav (article / category / section pages) — flex row with breadcrumbs + search */
.sub-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
  padding: 12px 0 0;
  margin: 0;
  border-bottom: 1px solid #E8ECEF;
  background: transparent;
}
.sub-nav .breadcrumbs {
  margin: 0;
  flex: 1 1 auto;
}
.search-container {
  position: relative;
  flex: 0 1 360px;
  max-width: 360px;
  width: 100%;
}
/* Sub-nav search input (uses same big pill style as home hero so it's visually consistent) */
.search-container .search input[type="search"],
.search-container .search input[type="text"],
.search-container form[role="search"] input[type="search"],
.search-container form[role="search"] input[type="text"] {
  height: 56px;
  font-size: 16px;
  padding: 0 48px 0 48px;
  border-radius: 9999px;
}
.search-container .clear-button,
.search-container form[role="search"] .clear-button {
  right: 10px;
  width: 24px;
  height: 24px;
}
@media (max-width: 640px) {
  .sub-nav { flex-direction: column; align-items: stretch; gap: 8px; padding: 12px 0 0; }
  .search-container { flex: 1 1 auto; max-width: none; }
}

/* ---------- Knowledge base / category blocks ---------------------------- */
.knowledge-base {
  padding: 64px 24px;
  max-width: 1200px;
  margin: 0 auto;
}
@media (max-width: 768px) { .knowledge-base { padding: 40px 16px; } }

.categories,
.blocks {
  margin: 0;
  padding: 0;
}

.blocks-list {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  list-style: none;
  margin: 0;
  padding: 0;
}
@media (max-width: 1024px) { .blocks-list { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px)  { .blocks-list { grid-template-columns: 1fr; } }

.blocks-item {
  background: #fff;
  border: 1px solid #E8ECEF;
  border-radius: 16px;
  transition: border-color 150ms ease, box-shadow 150ms ease, transform 150ms ease;
}
.blocks-item:hover {
  border-color: rgba(99, 91, 255, 0.30);
  box-shadow: 0 12px 32px rgba(5, 22, 38, 0.08);
  transform: translateY(-2px);
}
.blocks-item-link {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  min-height: 120px;
  padding: 28px 24px;
  color: #051626;
  gap: 6px;
}
.blocks-item-link:hover { color: #051626; }
.blocks-item-title {
  display: block;
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
  font-weight: 700;
  font-size: 18px;
  color: #051626;
  letter-spacing: -0.01em;
  line-height: 1.3;
}
.blocks-item-description {
  display: block;
  font-size: 14px;
  color: #5B6470;
  line-height: 1.5;
}
.blocks-item-description:empty { display: none; }
.blocks-item-internal { position: relative; }
.blocks-item-internal::after {
  content: "";
  position: absolute;
  top: 12px; right: 12px;
  width: 8px; height: 8px;
  background: #635BFF;
  border-radius: 50%;
}

/* Promoted articles list (home + category pages) */
.articles { margin-top: 56px; }
.articles > h2 {
  font-size: 22px;
  font-weight: 700;
  margin: 0 0 20px;
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
}
.article-list,
.promoted-articles {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 1px solid #E8ECEF;
}
.article-list-item,
.promoted-articles-item,
.article-list > li {
  border-bottom: 1px solid #E8ECEF;
}
.article-list-item a,
.promoted-articles-item a,
.article-list > li > a,
.article-list-link {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 16px 4px;
  color: #051626;
  font-size: 16px;
  font-weight: 500;
}
.article-list-item a:hover,
.promoted-articles-item a:hover,
.article-list > li > a:hover,
.article-list-link:hover {
  color: #635BFF;
}
.article-promoted::before {
  content: "★";
  color: #635BFF;
  margin-right: 6px;
  font-size: 14px;
}
.icon-lock,
.icon-star {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
  color: #5B6470;
}

/* ---------- Section / category pages ------------------------------------ */
.category-container,
.section-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 32px 24px 96px;
}
.article-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 12px 24px 96px;
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 56px;
  align-items: flex-start;
}
@media (max-width: 1024px) {
  .article-container { grid-template-columns: 1fr; gap: 8px; padding: 8px 16px 64px; }
}
.article-sidebar { margin: 0; padding: 0; }
@media (max-width: 640px) {
  .category-container,
  .section-container,
  .article-container { padding: 16px 16px 64px; }
}

.category-content,
.section-content { display: flex; flex-direction: column; gap: 32px; }

.section-list { display: flex; flex-direction: column; gap: 24px; }
.section-list-item {
  padding: 24px;
  background: #fff;
  border: 1px solid #E8ECEF;
  border-radius: 16px;
  transition: border-color 150ms ease, box-shadow 150ms ease;
}
.section-list-item:hover {
  border-color: rgba(99, 91, 255, 0.30);
  box-shadow: 0 8px 24px rgba(5, 22, 38, 0.06);
}
.section-list-item h2,
.section-list-item h3 {
  font-size: 20px;
  margin: 0 0 8px;
}
.section-list-item h2 a,
.section-list-item h3 a { color: #051626; }
.section-list-item h2 a:hover,
.section-list-item h3 a:hover { color: #635BFF; }

.see-all-articles,
.see-all-filters {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 12px;
  color: #635BFF;
  font-weight: 600;
  font-size: 14px;
}
.see-all-articles:hover,
.see-all-filters:hover { color: #4A43E8; }

.section-empty,
.category-empty,
.no-results,
.no-activities,
.no-activity,
.no-posts-with-filter {
  text-align: center;
  padding: 48px 24px;
  color: #5B6470;
  background: #F7F8FA;
  border-radius: 16px;
}

/* ---------- Breadcrumbs ------------------------------------------------- */
.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 8px;
  align-items: center;
  padding: 0;
  margin: 0 0 24px;
  font-size: 14px;
  color: #5B6470;
}
.breadcrumbs li { display: inline-flex; align-items: center; gap: 4px 8px; }
.breadcrumbs li:not(:last-child)::after {
  content: "";
  display: inline-block;
  width: 6px; height: 6px;
  border-right: 1.5px solid #5B6470;
  border-top: 1.5px solid #5B6470;
  transform: rotate(45deg);
  margin-left: 4px;
  margin-right: 4px;
  opacity: 0.7;
}
.breadcrumbs a { color: #5B6470; }
.breadcrumbs a:hover { color: #635BFF; }
.breadcrumbs li:last-child { color: #051626; font-weight: 500; }

/* ---------- Article page ------------------------------------------------ */
.article { min-width: 0; }

.article-sidebar {
  position: sticky;
  top: 96px;
  align-self: flex-start;
}
@media (max-width: 1024px) {
  .article-sidebar { position: static; }
}
.article-sidebar h3,
.section-tree-title {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #5B6470;
  font-weight: 700;
  margin: 0 0 12px;
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
}
.article-sidebar ul,
.article-sidebar ol,
.section-tree {
  display: flex;
  flex-direction: column;
  gap: 2px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.article-sidebar a,
.section-tree a {
  display: block;
  padding: 8px 12px;
  border-radius: 8px;
  color: #5B6470;
  font-size: 14px;
  line-height: 1.5;
}
.article-sidebar a:hover,
.section-tree a:hover {
  background: #F7F8FA;
  color: #051626;
}
.article-sidebar .current-article > a,
.article-sidebar a.current,
.section-tree .current > a {
  background: rgba(99, 91, 255, 0.08);
  color: #635BFF;
  font-weight: 600;
}

.article-content,
.article-main { max-width: 760px; min-width: 0; }
.article-header { margin-bottom: 24px; }
.article-title {
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
  font-size: 40px;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.15;
  margin: 0 0 16px;
  color: #051626;
}
@media (max-width: 768px) { .article-title { font-size: 28px; } }

.article-info {
  display: block;
  color: #5B6470;
  font-size: 14px;
}
.article-author {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0 0 8px;
  flex-wrap: wrap;
}
.article-avatar,
.article-author .avatar {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #F7F8FA;
  flex-shrink: 0;
  overflow: hidden;
}
.article-avatar img,
.article-author .avatar img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
}
.article-avatar .icon-agent,
.article-author .avatar .icon-agent {
  position: absolute;
  bottom: -2px;
  right: -2px;
  width: 14px;
  height: 14px;
  background: #635BFF;
  color: #fff;
  border-radius: 50%;
  padding: 2px;
  border: 2px solid #fff;
}
.article-meta {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 4px 12px;
  color: #5B6470;
  font-size: 14px;
  line-height: 1.5;
}
.article-meta a { color: #635BFF; font-weight: 500; }
.article-meta .meta-group {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 4px 8px;
  align-items: baseline;
  color: #5B6470;
  font-size: 13px;
  margin: 0;
}
.article-meta .meta-data { color: #5B6470; font-size: 13px; }

/* Follow / subscribe button — render the underlying button as a clean pill */
.article-subscribe { margin-top: 12px; display: inline-block; }
.article-subscribe button,
.article-subscribe input[type="submit"],
.article-subscribe a.button,
.section-subscribe button,
.organization-subscribe button,
.subscriptions-subscribe button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 18px;
  background: #fff;
  color: #051626;
  border: 1px solid #E8ECEF;
  border-radius: 9999px;
  font-family: inherit;
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  transition: border-color 150ms ease, color 150ms ease, background 150ms ease;
}
.article-subscribe button:hover,
.section-subscribe button:hover,
.organization-subscribe button:hover,
.subscriptions-subscribe button:hover {
  border-color: #635BFF;
  color: #635BFF;
  background: rgba(99, 91, 255, 0.04);
}

.article-body {
  font-size: 17px;
  line-height: 1.75;
  color: #051626;
  margin-top: 24px;
}
.article-body h2 { font-size: 26px; margin: 40px 0 16px; }
.article-body h3 { font-size: 21px; margin: 32px 0 12px; }
.article-body h4 { font-size: 18px; margin: 24px 0 10px; }
.article-body p { margin: 0 0 18px; }
.article-body a {
  color: #635BFF;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}
.article-body a:hover { color: #4A43E8; }
.article-body ul,
.article-body ol { padding-left: 24px; margin: 0 0 18px; list-style: revert; }
.article-body li { margin-bottom: 6px; }
.article-body img,
.article-body video,
.article-body iframe {
  max-width: 100%;
  height: auto;
  border-radius: 12px;
  margin: 16px 0;
}
.article-body code {
  background: #F7F8FA;
  padding: 2px 6px;
  border-radius: 6px;
  font-size: 0.9em;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  border: 1px solid #E8ECEF;
}
.article-body pre {
  background: #F7F8FA;
  padding: 16px;
  border-radius: 12px;
  overflow-x: auto;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 14px;
  border: 1px solid #E8ECEF;
}
.article-body pre code {
  background: none;
  border: none;
  padding: 0;
}
.article-body blockquote {
  border-left: 3px solid #635BFF;
  padding: 4px 0 4px 16px;
  margin: 16px 0;
  color: #5B6470;
  font-style: italic;
}
.article-body table {
  border-collapse: collapse;
  width: 100%;
  margin: 16px 0;
  font-size: 15px;
}
.article-body th,
.article-body td {
  border: 1px solid #E8ECEF;
  padding: 10px 14px;
  text-align: left;
}
.article-body th {
  background: #F7F8FA;
  font-weight: 600;
}

/* Article footer (votes, share, attachments, subscribe) */
.article-footer {
  margin-top: 40px;
  padding-top: 24px;
  border-top: 1px solid #E8ECEF;
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
  justify-content: space-between;
  align-items: center;
}

.article-attachments,
.attachments {
  margin-top: 24px;
  padding: 16px;
  background: #F7F8FA;
  border-radius: 12px;
}
.attachment-item,
.attachments li {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 0;
}
.attachment-item a,
.attachments a { color: #635BFF; }
.attachment-icon { width: 16px; height: 16px; color: #5B6470; }
.attachment-meta {
  margin-left: auto;
  font-size: 12px;
  color: #5B6470;
}

.article-share {
  display: flex;
  gap: 8px;
  align-items: center;
}
.article-share a,
.post-share a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px; height: 36px;
  border-radius: 50%;
  background: #F7F8FA;
  color: #051626;
  transition: background 150ms ease, color 150ms ease;
}
.article-share a:hover,
.post-share a:hover {
  background: #635BFF;
  color: #fff;
}

.article-votes,
.article-more-questions {
  width: 100%;
  margin-top: 24px;
  padding: 24px;
  background: #F7F8FA;
  border-radius: 16px;
  text-align: center;
}
.article-votes {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}
/* Collapse the more-questions box when its `request_callout` helper renders empty */
.article-more-questions:not(:has(*:not(:empty))) {
  display: none;
}
.article-votes-question { font-weight: 600; margin: 0; }
.article-votes-controls {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin: 0;
}
.article-votes-controls button {
  padding: 8px 18px;
  background: #fff;
  border: 1px solid #E8ECEF;
  border-radius: 9999px;
  cursor: pointer;
  font: inherit;
  font-weight: 500;
  color: #051626;
  transition: border-color 150ms ease, color 150ms ease, background 150ms ease;
}
.article-votes-controls button:hover {
  border-color: #635BFF;
  color: #635BFF;
}
.article-votes-count { display: block; margin: 0; color: #5B6470; font-size: 13px; }

.article-relatives {
  margin-top: 56px;
  display: grid;
  gap: 40px;
}
@media (min-width: 768px) {
  .article-relatives { grid-template-columns: 1fr 1fr; }
}
.article-relatives section,
.article-relatives > div {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.article-relatives h2,
.article-relatives h3 {
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
  font-size: 22px;
  font-weight: 700;
  margin: 0 0 8px;
  letter-spacing: -0.01em;
  color: #051626;
  text-transform: none;
}
.article-relatives ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.article-relatives li { margin: 0; }
.article-relatives li a { color: #051626; line-height: 1.5; }
.article-relatives li a:hover { color: #635BFF; }

.article-return-to-top {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 24px;
  color: #5B6470;
  font-size: 14px;
}
.article-return-to-top:hover { color: #635BFF; }
.article-return-to-top-icon {
  width: 14px;
  height: 14px;
  transform: rotate(180deg);  /* native chevron points down — flip to point up */
}

/* Subscribe / follow buttons */
.article-subscribe,
.section-subscribe,
.organization-subscribe,
.subscriptions-subscribe,
.community-follow {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

/* Collapsible sidebar (mobile articles-in-section) — title + toggle share a row, body wraps below */
.collapsible-sidebar,
.collapsible-nav {
  display: grid;
  grid-template-columns: 1fr auto;
  grid-template-areas:
    "title toggle"
    "body  body";
  align-items: center;
  border: 1px solid #E8ECEF;
  border-radius: 12px;
  background: #fff;
  margin-bottom: 16px;
  overflow: hidden;
}
.collapsible-sidebar-toggle,
.collapsible-nav-toggle {
  grid-area: toggle;
  align-self: center;
  justify-self: end;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  margin: 6px;
  padding: 0;
  background: transparent;
  border: 0;
  border-radius: 8px;
  outline: 0;
  cursor: pointer;
  color: #051626;
  -webkit-appearance: none;
  appearance: none;
  box-shadow: none;
}
.collapsible-sidebar-toggle:hover,
.collapsible-nav-toggle:hover {
  background: rgba(99, 91, 255, 0.08);
  color: #635BFF;
}
.collapsible-sidebar-toggle:focus,
.collapsible-nav-toggle:focus { outline: 0; }
.collapsible-sidebar-toggle:focus-visible,
.collapsible-nav-toggle:focus-visible {
  outline: 2px solid #635BFF;
  outline-offset: -2px;
}
.collapsible-sidebar-title,
.collapsible-nav .sidenav-title {
  grid-area: title;
  display: flex;
  align-items: center;
  min-height: 48px;
  padding: 8px 8px 8px 16px;
  font-weight: 700;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #5B6470;
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
  margin: 0;
}
.collapsible-sidebar-toggle-icon,
.collapsible-nav-toggle-icon {
  width: 16px;
  height: 16px;
}

/* DEFAULT STATE: body visible, X icon shown (since the list is "expanded") */
.collapsible-sidebar-body,
.collapsible-nav-list {
  grid-area: body;
  display: block;
  padding: 4px 8px 12px;
  border-top: 1px solid #E8ECEF;
}
.collapsible-sidebar-toggle .chevron-icon,
.collapsible-nav-toggle .chevron-icon { display: none; }
.collapsible-sidebar-toggle .x-icon,
.collapsible-nav-toggle .x-icon { display: inline-block; }

/* COLLAPSED STATE: when parent has aria-expanded="false" (set by script.js after click) */
.collapsible-sidebar[aria-expanded="false"] .collapsible-sidebar-body,
.collapsible-nav[aria-expanded="false"] .collapsible-nav-list { display: none; }
.collapsible-sidebar[aria-expanded="false"] .x-icon,
.collapsible-nav[aria-expanded="false"] .x-icon { display: none; }
.collapsible-sidebar[aria-expanded="false"] .chevron-icon,
.collapsible-nav[aria-expanded="false"] .chevron-icon { display: inline-block; }

/* Hide the toggle button on desktop — the sidebar is always visible there. */
@media (min-width: 1025px) {
  .collapsible-sidebar-toggle,
  .collapsible-nav-toggle { display: none; }
  .collapsible-sidebar[aria-expanded="false"] .collapsible-sidebar-body,
  .collapsible-nav[aria-expanded="false"] .collapsible-nav-list { display: block; }
}
.collapsible-sidebar-body[aria-hidden="true"],
.collapsible-nav-list[aria-hidden="true"] { display: none; }
.collapsible-sidebar-body ul,
.collapsible-nav-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.collapsible-sidebar-body .sidenav-item,
.collapsible-sidebar-body li > a {
  display: block;
  padding: 8px 12px;
  border-radius: 8px;
  color: #5B6470;
  font-size: 14px;
  line-height: 1.5;
}
.collapsible-sidebar-body .sidenav-item:hover,
.collapsible-sidebar-body li > a:hover {
  background: #F7F8FA;
  color: #051626;
}
.collapsible-sidebar-body .current-article,
.collapsible-sidebar-body .sidenav-item.current-article {
  background: rgba(99, 91, 255, 0.08);
  color: #635BFF;
  font-weight: 600;
}

/* ---------- Comments --------------------------------------------------- */
.comments { margin-top: 64px; }
.comment-heading {
  font-size: 22px;
  font-weight: 700;
  margin: 0 0 24px;
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
}
.comment-list,
.comment-list ul {
  display: flex;
  flex-direction: column;
  gap: 16px;
  list-style: none;
  padding: 0;
  margin: 0;
}
.comment {
  padding: 24px;
  background: #fff;
  border: 1px solid #E8ECEF;
  border-radius: 16px;
}
.comment-container,
.comment-wrapper {
  display: flex;
  gap: 16px;
  align-items: flex-start;
}
.comment-avatar {
  width: 40px; height: 40px;
  border-radius: 50%;
  flex-shrink: 0;
  object-fit: cover;
}
.comment-info { flex: 1; min-width: 0; }
.comment-overview { display: flex; flex-wrap: wrap; gap: 8px 16px; align-items: center; }
.comment-author { font-weight: 600; color: #051626; }
.comment-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 12px;
  font-size: 13px;
  color: #5B6470;
  margin-top: 2px;
}
.comment-body {
  margin-top: 12px;
  line-height: 1.65;
  color: #051626;
}
.comment-actions {
  display: flex;
  gap: 16px;
  margin-top: 12px;
  font-size: 14px;
  color: #5B6470;
}
.comment-actions a { color: #5B6470; }
.comment-actions a:hover { color: #635BFF; }
.comment-callout,
.comment-official {
  padding: 16px;
  background: rgba(99, 91, 255, 0.05);
  border: 1px solid rgba(99, 91, 255, 0.20);
  border-radius: 12px;
  font-size: 14px;
}
.comment-pending { opacity: 0.7; }
.comment-vote {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.comment-form-controls {
  display: flex;
  gap: 12px;
  margin-top: 16px;
  flex-wrap: wrap;
  align-items: center;
}

/* ---------- Buttons ----------------------------------------------------- */
.button,
button.button,
a.button,
input[type="submit"],
button[type="submit"],
.post-to-community {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 12px 22px;
  background: #051626;
  color: #FFFFFF;
  border: 1px solid #051626;
  border-radius: 9999px;
  font-family: inherit;
  font-weight: 600;
  font-size: 15px;
  cursor: pointer;
  text-decoration: none;
  white-space: nowrap;
  transition: background 150ms ease, border-color 150ms ease, transform 150ms ease, box-shadow 150ms ease;
}
.button:hover,
button.button:hover,
a.button:hover,
input[type="submit"]:hover,
button[type="submit"]:hover,
.post-to-community:hover {
  background: #0a2b4a;
  border-color: #0a2b4a;
  color: #FFFFFF;
}
.button:active { transform: scale(0.98); }
.button:focus-visible,
button.button:focus-visible,
input[type="submit"]:focus-visible,
button[type="submit"]:focus-visible {
  outline: 2px solid #635BFF;
  outline-offset: 2px;
}
.button:disabled,
button.button:disabled,
input[type="submit"]:disabled,
button[type="submit"]:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.button-large { padding: 16px 32px; font-size: 17px; }
.button-primary {
  background: #635BFF;
  border-color: #635BFF;
  color: #fff;
  box-shadow: 0 8px 24px rgba(99, 91, 255, 0.20);
}
.button-primary:hover {
  background: #4A43E8;
  border-color: #4A43E8;
  color: #fff;
}
.button-secondary {
  background: #fff;
  color: #051626;
  border-color: #E8ECEF;
  box-shadow: none;
}
.button-secondary:hover {
  background: #F7F8FA;
  color: #051626;
  border-color: #635BFF;
}

/* ---------- Forms ------------------------------------------------------ */
.form,
form { display: flex; flex-direction: column; gap: 18px; }
.form-header { margin-bottom: 8px; }
.form-header h1,
.form-header h2 {
  font-size: 28px;
  margin: 0 0 8px;
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
}
.form-field { display: flex; flex-direction: column; gap: 6px; }
.form-field > label,
form > label {
  font-weight: 500;
  font-size: 14px;
  color: #051626;
}
.form-field .description,
.form-field small {
  font-size: 13px;
  color: #5B6470;
}
.optional {
  color: #5B6470;
  font-weight: 400;
  font-size: 13px;
  margin-left: 6px;
}
input[type="text"],
input[type="email"],
input[type="url"],
input[type="search"],
input[type="password"],
input[type="number"],
input[type="tel"],
input[type="date"],
input[type="time"],
textarea,
select {
  width: 100%;
  padding: 12px 16px;
  border: 1px solid #E8ECEF;
  border-radius: 12px;
  background: #fff;
  font-family: inherit;
  font-size: 15px;
  color: #051626;
  transition: border-color 150ms ease, box-shadow 150ms ease;
}
textarea {
  resize: vertical;
  min-height: 140px;
  line-height: 1.6;
}
input:focus,
textarea:focus,
select:focus {
  outline: none;
  border-color: #635BFF;
  box-shadow: 0 0 0 4px rgba(99, 91, 255, 0.15);
}
input[type="checkbox"],
input[type="radio"] {
  width: auto;
  accent-color: #635BFF;
}
select {
  -webkit-appearance: none;
  appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, #5B6470 50%), linear-gradient(135deg, #5B6470 50%, transparent 50%);
  background-position: calc(100% - 18px) 50%, calc(100% - 13px) 50%;
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
  padding-right: 36px;
}

.notification,
.notification-inline {
  padding: 14px 16px;
  border-radius: 12px;
  background: rgba(99, 91, 255, 0.06);
  border: 1px solid rgba(99, 91, 255, 0.20);
  color: #051626;
  font-size: 14px;
  margin: 16px 0;
}
.notification-error {
  background: rgba(220, 38, 38, 0.06);
  border-color: rgba(220, 38, 38, 0.25);
  color: #B91C1C;
}

/* ---------- Footer ----------------------------------------------------- */
.footer {
  background: #051626;
  color: #FFFFFF;
  padding: 56px 24px 32px;
  margin-top: 80px;
}
.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.footer-inner > a:first-child {
  color: #FFFFFF;
  font-weight: 600;
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
  font-size: 16px;
  letter-spacing: -0.01em;
}
.footer-inner > a:first-child:hover { color: rgba(255, 255, 255, 0.80); }

.footer-language-selector .language-selector .dropdown-toggle {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #FFFFFF;
  border-radius: 9999px;
  padding: 8px 14px;
  font-size: 14px;
}
.footer-language-selector .language-selector .dropdown-toggle:hover {
  background: rgba(255, 255, 255, 0.14);
  color: #FFFFFF;
}
.footer-language-selector .dropdown-menu {
  background: #092641;
  border-color: rgba(255, 255, 255, 0.15);
  max-height: 320px;
  overflow-y: auto;
}
.footer-language-selector .dropdown-menu a {
  color: rgba(255, 255, 255, 0.85);
}
.footer-language-selector .dropdown-menu a:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #FFFFFF;
}

/* ---------- Search results page ---------------------------------------- */
.search-results,
.search-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 32px 24px 96px;
}
.search-results-column { max-width: 800px; }
.search-results-list { list-style: none; padding: 0; margin: 0; }
.search-results-subheading {
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #5B6470;
  margin: 32px 0 12px;
}
.search-result {
  padding: 20px 0;
  border-bottom: 1px solid #E8ECEF;
}
.search-result:first-child { border-top: 1px solid #E8ECEF; }
.search-result-title {
  font-size: 19px;
  font-weight: 700;
  margin: 0 0 6px;
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
}
.search-result-title-container {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.search-result-title a { color: #051626; }
.search-result-title a:hover { color: #635BFF; }
.search-result-description {
  color: #5B6470;
  margin: 6px 0 8px;
  line-height: 1.6;
  font-size: 15px;
}
.search-result-breadcrumbs {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  font-size: 13px;
  color: #5B6470;
}
.search-result-breadcrumbs li:not(:last-child)::after {
  content: "›";
  margin-left: 6px;
  color: #5B6470;
}
.search-result-meta-container {
  display: flex;
  gap: 16px;
  margin-top: 8px;
  font-size: 13px;
  color: #5B6470;
}
.search-result-votes,
.search-result-meta-count {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.search-result-votes-icon,
.search-result-meta-count-icon {
  width: 14px; height: 14px;
}
.search-result-icons { display: inline-flex; gap: 6px; }

.results-count { color: #5B6470; font-size: 14px; margin-bottom: 16px; }

/* ---------- Pagination ------------------------------------------------- */
.pagination {
  display: flex;
  gap: 4px;
  justify-content: center;
  align-items: center;
  margin: 40px 0;
  flex-wrap: wrap;
  list-style: none;
  padding: 0;
}
.pagination a,
.pagination span,
.pagination .current {
  min-width: 40px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 12px;
  border-radius: 10px;
  color: #051626;
  font-size: 14px;
  border: 1px solid transparent;
}
.pagination a:hover {
  background: #F7F8FA;
  color: #635BFF;
}
.pagination .current,
.pagination [aria-current="page"] {
  background: #635BFF;
  color: #fff;
  font-weight: 600;
}
.pagination .disabled,
.pagination .gap { color: #5B6470; cursor: default; }

/* ---------- Community --------------------------------------------------- */
.community,
.home-section.community {
  margin-top: 56px;
  padding: 40px;
  background: #F7F8FA;
  border-radius: 24px;
  text-align: center;
}
.home-section.community h2 {
  font-size: 24px;
  margin: 0 0 12px;
}
.community-link,
.community a.button,
.home-section.community > a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #635BFF;
  color: #fff;
  padding: 12px 22px;
  border-radius: 9999px;
  font-weight: 600;
  margin-top: 8px;
  box-shadow: 0 8px 24px rgba(99, 91, 255, 0.18);
}
.community-link:hover,
.home-section.community > a:hover {
  background: #4A43E8;
  color: #fff;
}
.community-image { display: none; }

.community-hero {
  background: #F7F8FA;
  padding: 48px 24px;
  text-align: center;
  border-bottom: 1px solid #E8ECEF;
}
.community-header {
  margin-bottom: 24px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.community-footer { margin-top: 24px; color: #5B6470; }

.topics,
.topics-list,
.posts-list {
  display: grid;
  gap: 16px;
}
.topics { grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
.topics-list,
.posts-list { grid-template-columns: 1fr; }

.topics-item,
.post,
.post-container {
  background: #fff;
  border: 1px solid #E8ECEF;
  border-radius: 16px;
  padding: 24px;
  transition: border-color 150ms ease, box-shadow 150ms ease;
}
.topics-item:hover,
.post-container:hover {
  border-color: rgba(99, 91, 255, 0.30);
  box-shadow: 0 8px 24px rgba(5, 22, 38, 0.06);
}
.topics-item h2,
.topics-item h3 { font-size: 18px; margin: 0 0 6px; }
.topics-item h2 a,
.topics-item h3 a { color: #051626; }
.topics-item h2 a:hover,
.topics-item h3 a:hover { color: #635BFF; }

.post-title,
.post-header h1,
.post-header h2 {
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
  font-size: 24px;
  font-weight: 700;
  margin: 0 0 8px;
  letter-spacing: -0.01em;
}
.post-title a { color: #051626; }
.post-title a:hover { color: #635BFF; }
.post-meta,
.post-info,
.post-info-container {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  align-items: center;
  font-size: 13px;
  color: #5B6470;
}
.post-author { display: inline-flex; align-items: center; gap: 8px; }
.post-avatar { width: 28px; height: 28px; border-radius: 50%; }
.post-body {
  line-height: 1.7;
  margin-top: 16px;
  color: #051626;
}
.post-actions,
.post-actions-wrapper {
  margin-top: 16px;
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  align-items: center;
}
.post-vote {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  background: #F7F8FA;
  border: 1px solid #E8ECEF;
  border-radius: 9999px;
  font-size: 13px;
}
.post-comment-count { display: inline-flex; align-items: center; gap: 4px; font-size: 13px; color: #5B6470; }
.post-comment-count .icon-comments { width: 14px; height: 14px; }
.post-featured { border-color: rgba(99, 91, 255, 0.40); background: rgba(99, 91, 255, 0.02); }

.community-featured-posts {
  margin-bottom: 24px;
  padding: 8px 12px;
  background: rgba(99, 91, 255, 0.04);
  border-radius: 12px;
  font-size: 13px;
  font-weight: 600;
  color: #635BFF;
  display: inline-block;
}

.topic-header,
.community-header {
  padding: 24px 0;
}
.topic-filters,
.filters-in-section {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 16px 0;
}

.community-activity {
  margin-top: 24px;
  padding: 16px;
  background: #F7F8FA;
  border-radius: 12px;
}

.community-name-and-title-badges {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
.community-badge,
.community-badge-achievement,
.community-badge-title,
.escalation-badge,
.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 10px;
  border-radius: 9999px;
  font-size: 12px;
  font-weight: 600;
  background: #F7F8FA;
  color: #051626;
  border: 1px solid #E8ECEF;
}
.community-badge-achievements,
.community-badge-titles {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

/* ---------- Status labels --------------------------------------------- */
.status-label {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 10px;
  border-radius: 9999px;
  font-size: 12px;
  font-weight: 600;
  background: #F7F8FA;
  color: #051626;
  text-transform: capitalize;
}
.status-label-featured,
.status-label-pinned,
.status-label-official {
  background: rgba(99, 91, 255, 0.10);
  color: #635BFF;
}
.status-label-pending-moderation { background: #FFF4E5; color: #B5651D; }
.status-label-open,
.status-label-new { background: rgba(0, 212, 255, 0.10); color: #006B8F; }
.status-label-solved,
.status-label-closed { background: rgba(34, 197, 94, 0.10); color: #166534; }

/* ---------- Tables / requests / activity lists ------------------------- */
.table,
.requests-table,
.my-activities-table,
.contributions-table,
.subscriptions-table {
  width: 100%;
  border-collapse: collapse;
  border: 1px solid #E8ECEF;
  border-radius: 12px;
  overflow: hidden;
  font-size: 14px;
  background: #fff;
}
.table th,
.table td,
.requests-table th,
.requests-table td,
.my-activities-table th,
.my-activities-table td,
.contributions-table th,
.contributions-table td,
.subscriptions-table th,
.subscriptions-table td {
  padding: 14px 16px;
  border-bottom: 1px solid #E8ECEF;
  text-align: left;
  vertical-align: top;
}
.table th,
.requests-table th,
.my-activities-table th,
.contributions-table th,
.subscriptions-table th {
  background: #F7F8FA;
  font-weight: 600;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #5B6470;
}
.table tr:last-child td,
.requests-table tr:last-child td { border-bottom: 0; }

.requests-search-info,
.requests-table-info,
.my-activities-header,
.my-activities-following-header {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
  margin: 24px 0 16px;
}
.request-table-filter,
.requests-table-meta { font-size: 13px; color: #5B6470; }

.striped-list {
  list-style: none;
  margin: 0;
  padding: 0;
  border: 1px solid #E8ECEF;
  border-radius: 12px;
  overflow: hidden;
  background: #fff;
}
.striped-list-item {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px;
  border-bottom: 1px solid #E8ECEF;
}
.striped-list-item:last-child { border-bottom: 0; }
.striped-list-item:hover { background: #F7F8FA; }
.striped-list-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px; height: 32px;
  border-radius: 50%;
  background: #F7F8FA;
  font-weight: 700;
  font-size: 13px;
  color: #051626;
  flex-shrink: 0;
}
.striped-list-info { flex: 1; min-width: 0; }
.striped-list-title { font-weight: 600; color: #051626; }
.striped-list-status { font-size: 13px; color: #5B6470; margin-top: 2px; }
.striped-list-count { font-weight: 700; color: #051626; font-size: 14px; }
.striped-list-count-item { display: inline-flex; align-items: center; gap: 4px; }

.request-container {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  gap: 32px;
  align-items: flex-start;
}
@media (max-width: 1024px) { .request-container { grid-template-columns: 1fr; } }
.request-sidebar {
  padding: 24px;
  background: #F7F8FA;
  border-radius: 16px;
  font-size: 14px;
}
.request-info,
.request-details {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.request-title { font-size: 24px; margin: 0 0 8px; font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif; }
.request-breadcrumbs { margin-bottom: 16px; }
.request-attachments,
.request-collaborators,
.request-follow-up {
  margin-top: 16px;
  font-size: 14px;
  color: #5B6470;
}
.request-submit-comment { margin-top: 16px; }
.follow-up-hint { color: #5B6470; font-size: 13px; }
.action-prompt { color: #5B6470; font-size: 13px; }

.meta-data,
.meta-group,
.meta-group-opposite {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
  align-items: center;
  font-size: 13px;
  color: #5B6470;
  margin: 8px 0;
}

/* ---------- Profile / contributions ------------------------------------ */
.profile-header {
  display: flex;
  gap: 24px;
  align-items: center;
  padding: 32px 0;
  flex-wrap: wrap;
}
.profile-avatar {
  width: 96px; height: 96px;
  border-radius: 50%;
  object-fit: cover;
}
.profile-info { flex: 1; min-width: 0; }
.profile-info h1,
.profile-header h1 { font-size: 28px; margin: 0 0 4px; font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif; }
.profile-stats {
  display: flex;
  gap: 32px;
  margin-top: 16px;
  flex-wrap: wrap;
}
.profile-stats-counters {
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
}
.profile-stats-activity {
  display: flex;
  gap: 16px;
  font-size: 14px;
  color: #5B6470;
}
.stat { display: flex; flex-direction: column; }
.stat-value { font-size: 22px; font-weight: 700; color: #051626; }
.stat-label { font-size: 13px; color: #5B6470; }

.profile-section,
.community-activity { margin: 32px 0; }
.profile-section-header {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}
.profile-section-title { font-size: 20px; font-weight: 700; margin: 0; font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif; }
.profile-section-description { color: #5B6470; font-size: 14px; }
.profile-section-sorter { font-size: 14px; color: #5B6470; }

.profile-nav,
.my-activities-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin: 16px 0;
  border-bottom: 1px solid #E8ECEF;
}
.profile-nav a,
.my-activities-nav a {
  padding: 10px 16px;
  color: #5B6470;
  font-weight: 500;
  font-size: 14px;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
}
.profile-nav a:hover,
.my-activities-nav a:hover { color: #051626; }
.profile-nav a[aria-current="page"],
.profile-nav .current,
.my-activities-nav a[aria-current="page"],
.my-activities-nav .current {
  color: #635BFF;
  border-bottom-color: #635BFF;
}

.my-activities-sub-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 16px 0;
}
.my-activities-sub-nav a {
  display: inline-flex;
  padding: 6px 12px;
  background: #F7F8FA;
  border: 1px solid #E8ECEF;
  border-radius: 9999px;
  font-size: 13px;
  color: #051626;
}
.my-activities-sub-nav a:hover,
.my-activities-sub-nav a.current {
  background: rgba(99, 91, 255, 0.08);
  border-color: #635BFF;
  color: #635BFF;
}

.profile-activity,
.profile-contribution,
.profile-activity-list,
.profile-contribution-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.profile-activity-contribution,
.profile-contribution {
  padding: 20px;
  background: #fff;
  border: 1px solid #E8ECEF;
  border-radius: 12px;
}
.profile-activity-header,
.profile-contribution-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
  font-size: 13px;
  color: #5B6470;
}
.profile-activity-icon,
.profile-contribution-icon { width: 16px; height: 16px; color: #5B6470; }
.profile-activity-description,
.profile-contribution-title { color: #051626; font-weight: 500; }
.profile-contribution-body { color: #5B6470; margin-top: 8px; line-height: 1.6; }
.profile-contribution-breadcrumbs {
  margin-top: 8px;
  font-size: 12px;
  color: #5B6470;
}
.profile-private-badge,
.profile-private-icon {
  color: #5B6470;
  font-size: 12px;
}
.private-activity,
.private-activity-icon { color: #5B6470; }

.profile-badges-items {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
}
.profile-badges-item {
  padding: 16px;
  background: #fff;
  border: 1px solid #E8ECEF;
  border-radius: 12px;
  text-align: center;
}
.profile-badges-item-image { width: 48px; height: 48px; margin: 0 auto 8px; }
.profile-badges-item-title { font-weight: 600; font-size: 14px; }
.profile-badges-item-description {
  font-size: 12px;
  color: #5B6470;
  margin-top: 4px;
}

/* ---------- Sidenav ---------------------------------------------------- */
.sidenav-title {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #5B6470;
  font-weight: 700;
  margin: 16px 0 8px;
}
.sidenav-item {
  display: block;
  padding: 8px 12px;
  border-radius: 8px;
  color: #051626;
  font-size: 14px;
}
.sidenav-item:hover { background: #F7F8FA; color: #635BFF; }
.sidenav-subitem { padding-left: 28px; font-size: 13px; }
.sidenav-tag {
  display: inline-block;
  margin-left: auto;
  padding: 2px 8px;
  background: #F7F8FA;
  border-radius: 9999px;
  font-size: 11px;
  color: #5B6470;
}

/* ---------- Multibrand filter ----------------------------------------- */
.multibrand-filter-list {
  list-style: none;
  padding: 0;
  margin: 16px 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.multibrand-filter-list a {
  display: inline-block;
  padding: 6px 12px;
  background: #F7F8FA;
  border: 1px solid #E8ECEF;
  border-radius: 9999px;
  font-size: 13px;
  color: #051626;
  font-weight: 500;
}
.multibrand-filter-list a:hover,
.multibrand-filter-list a.current {
  background: rgba(99, 91, 255, 0.08);
  border-color: #635BFF;
  color: #635BFF;
}
.multibrand-filter-list--collapsed > li:nth-child(n+7) { display: none; }

/* ---------- Content tags ---------------------------------------------- */
.content-tag-list,
.content-tags {
  list-style: none;
  padding: 0;
  margin: 12px 0;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.content-tag-item,
.content-tag {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  background: #F7F8FA;
  border: 1px solid #E8ECEF;
  border-radius: 9999px;
  font-size: 12px;
  color: #5B6470;
  font-weight: 500;
}
.content-tag:hover,
.content-tag-item:hover {
  background: rgba(99, 91, 255, 0.06);
  border-color: #635BFF;
  color: #635BFF;
}
.content-tags-add-hint { font-size: 12px; color: #5B6470; margin-top: 6px; }

/* ---------- Error page ------------------------------------------------- */
.error-page {
  text-align: center;
  padding: 96px 24px;
  max-width: 600px;
  margin: 0 auto;
}
.error-page h1 {
  font-size: 56px;
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
  font-weight: 800;
  margin: 0 0 16px;
  letter-spacing: -0.02em;
}
.error-page p { color: #5B6470; font-size: 17px; }

/* ---------- Page header (generic) ------------------------------------- */
.page-header { padding: 32px 0 16px; }
.page-header h1 { font-size: 32px; margin: 0 0 8px; font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif; }
.page-header-description { color: #5B6470; font-size: 16px; }
.headline {
  font-size: 24px;
  margin: 24px 0 12px;
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
}

/* ---------- Recent activity (home page) -------------------------------- */
/* Section is empty when settings.show_recent_activity is off — collapse it */
.home-section.activity:not(:has(*)) { display: none; padding: 0; margin: 0; }
.home-section.activity:has(*) {
  margin-top: 56px;
  padding: 32px;
  background: #F7F8FA;
  border-radius: 16px;
}
.activity h2 {
  font-size: 20px;
  margin: 0 0 16px;
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
}

/* ---------- Subscriptions / contributions tables ----------------------- */
.subscriptions-table .doc-count,
.contributions-table .doc-count {
  display: inline-block;
  padding: 2px 8px;
  background: #F7F8FA;
  border-radius: 9999px;
  font-size: 12px;
  color: #5B6470;
}

/* ---------- Container divider ----------------------------------------- */
.container-divider {
  height: 1px;
  background: #E8ECEF;
  margin: 32px 0;
  border: 0;
}

/* ---------- Misc icons ------------------------------------------------ */
.icon-menu,
.icon-comments,
.icon-agent,
.icon-star,
.icon-lock,
.chevron-icon,
.x-icon,
.close-icon { color: currentColor; flex-shrink: 0; }

/* ---------- Scrollbars (subtle) --------------------------------------- */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb {
  background: rgba(5, 22, 38, 0.12);
  border-radius: 9999px;
  border: 2px solid transparent;
  background-clip: padding-box;
}
::-webkit-scrollbar-thumb:hover { background: rgba(5, 22, 38, 0.25); background-clip: padding-box; }

/* ---------- Reduced motion (respect user preference) ------------------ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
}

/* ---------- Print ----------------------------------------------------- */
@media print {
  .header, .footer, .sub-nav, .article-sidebar,
  .article-share, .article-votes, .article-relatives,
  .menu-list-mobile, .nav-wrapper-desktop, .nav-wrapper-mobile,
  .skip-navigation, .breadcrumbs, .pagination { display: none !important; }
  body { color: #000; background: #fff; font-size: 12pt; }
  .article-content { max-width: 100%; }
  a { color: #000; text-decoration: underline; }
}
