:root {
  --bg: #0c1018;
  --surface: #141a26;
  --surface-soft: #1a2130;
  --border: #2a3347;
  --text: #f5f7ff;
  --text-muted: #9aa6c4;
  --purple: #9f66ff;
  --purple-soft: rgba(159, 102, 255, 0.16);
  --scrollbar-size: 12px;
  --scrollbar-track: rgba(14, 20, 33, 0.94);
  --scrollbar-thumb: linear-gradient(180deg, rgba(132, 93, 244, 0.92), rgba(89, 179, 255, 0.82));
  --scrollbar-thumb-hover: linear-gradient(180deg, rgba(163, 126, 255, 0.95), rgba(121, 204, 255, 0.88));
  --scrollbar-border: rgba(200, 214, 255, 0.24);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: Inter, system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  background:
    radial-gradient(circle at 20% 0%, rgba(159, 102, 255, 0.12), transparent 30%),
    linear-gradient(180deg, #090c14 0%, var(--bg) 48%, #0a0f19 100%);
  color: var(--text);
  min-height: 100vh;
  scrollbar-color: rgba(132, 93, 244, 0.92) rgba(14, 20, 33, 0.94);
  scrollbar-width: thin;
}

html {
  scrollbar-color: rgba(132, 93, 244, 0.92) rgba(14, 20, 33, 0.94);
  scrollbar-width: thin;
}

*::-webkit-scrollbar {
  width: var(--scrollbar-size);
  height: var(--scrollbar-size);
}

*::-webkit-scrollbar-track {
  background: var(--scrollbar-track);
  border-radius: 999px;
}

*::-webkit-scrollbar-thumb {
  background-image: var(--scrollbar-thumb);
  border: 2px solid var(--scrollbar-track);
  border-radius: 999px;
  box-shadow: inset 0 0 0 1px var(--scrollbar-border), 0 8px 18px rgba(45, 20, 95, 0.45);
}

*::-webkit-scrollbar-thumb:hover {
  background-image: var(--scrollbar-thumb-hover);
}

*::-webkit-scrollbar-corner {
  background: transparent;
}

body.modal-open {
  overflow: hidden;
}

.app-shell {
  display: grid;
  grid-template-columns: 280px 1fr;
  min-height: 100vh;
}

.sidebar {
  border-right: 1px solid rgba(154, 166, 196, 0.18);
  padding: 24px 18px;
  background: linear-gradient(190deg, #0f1320 0%, #0b1019 100%);
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.brand-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  border-radius: 14px;
  border: 1px solid rgba(159, 102, 255, 0.35);
  background: rgba(255, 255, 255, 0.03);
}

.avatar {
  height: 44px;
  width: 44px;
  border-radius: 10px;
  background: linear-gradient(145deg, #7f4be5, #be89ff);
  display: grid;
  place-items: center;
  font-weight: 700;
}

.brand-name {
  margin: 0;
  font-weight: 700;
}

.menu {
  display: grid;
  gap: 8px;
}

.menu-item {
  color: #d0d8ef;
  text-decoration: none;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid transparent;
}

.menu-item:hover,
.menu-item.is-active {
  border-color: rgba(159, 102, 255, 0.4);
  background: rgba(159, 102, 255, 0.09);
}

.content {
  padding: 34px;
}

.topbar {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
}

h1 {
  margin: 0;
  font-size: clamp(1.6rem, 2.5vw, 2.3rem);
  font-weight: 700;
}

.topbar p {
  margin: 8px 0 0;
  color: var(--text-muted);
}

.filters-panel {
  margin-top: 26px;
  display: grid;
  gap: 14px;
}

.filters-group {
  display: grid;
  gap: 8px;
}

.filters-title {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.85rem;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.filters {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}

.chip {
  appearance: none;
  border: 1px solid rgba(87, 213, 157, 0.45);
  background: linear-gradient(145deg, rgba(87, 213, 157, 0.14), rgba(87, 213, 157, 0.08));
  color: #b7f8dc;
  border-radius: 999px;
  padding: 9px 16px;
  font-weight: 600;
  line-height: 1;
  cursor: pointer;
  box-shadow: inset 0 0 0 1px rgba(87, 213, 157, 0.08);
  transition: transform 120ms ease, border-color 120ms ease, box-shadow 120ms ease;
}

.chip:hover {
  transform: translateY(-1px);
  border-color: rgba(87, 213, 157, 0.75);
  box-shadow: 0 6px 16px rgba(6, 34, 24, 0.4);
}

.chip-active {
  border-color: rgba(255, 208, 92, 0.85);
  background: linear-gradient(145deg, rgba(255, 208, 92, 0.3), rgba(245, 187, 58, 0.18));
  color: #fff3cf;
  box-shadow: 0 0 0 1px rgba(255, 208, 92, 0.28), 0 10px 24px rgba(74, 45, 6, 0.45);
}

#categoryFilters .chip {
  border-color: rgba(159, 102, 255, 0.45);
  background: linear-gradient(145deg, rgba(159, 102, 255, 0.16), rgba(159, 102, 255, 0.08));
  color: #e7d6ff;
  box-shadow: inset 0 0 0 1px rgba(159, 102, 255, 0.12);
}

#categoryFilters .chip:hover {
  border-color: rgba(159, 102, 255, 0.78);
  box-shadow: 0 6px 16px rgba(31, 15, 57, 0.45);
}

#categoryFilters .chip.chip-active {
  border-color: rgba(255, 208, 92, 0.9);
  background: linear-gradient(145deg, rgba(255, 208, 92, 0.32), rgba(245, 187, 58, 0.2));
  color: #fff5d8;
  box-shadow: 0 0 0 1px rgba(255, 208, 92, 0.32), 0 10px 24px rgba(74, 45, 6, 0.5);
}


#solutionsMainCategoryFilters .chip {
  border-color: rgba(87, 213, 157, 0.45);
  background: linear-gradient(145deg, rgba(87, 213, 157, 0.14), rgba(87, 213, 157, 0.08));
  color: #b7f8dc;
  box-shadow: inset 0 0 0 1px rgba(87, 213, 157, 0.08);
}

#solutionsMainCategoryFilters .chip:hover {
  border-color: rgba(87, 213, 157, 0.75);
  box-shadow: 0 6px 16px rgba(6, 34, 24, 0.4);
}

#solutionsMainCategoryFilters .chip.chip-active {
  border-color: rgba(255, 208, 92, 0.9);
  background: linear-gradient(145deg, rgba(255, 208, 92, 0.32), rgba(245, 187, 58, 0.2));
  color: #fff5d8;
  box-shadow: 0 0 0 1px rgba(255, 208, 92, 0.32), 0 10px 24px rgba(74, 45, 6, 0.5);
}

#solutionsSubcategoryFilters .chip {
  border-color: rgba(159, 102, 255, 0.45);
  background: linear-gradient(145deg, rgba(159, 102, 255, 0.16), rgba(159, 102, 255, 0.08));
  color: #e7d6ff;
  box-shadow: inset 0 0 0 1px rgba(159, 102, 255, 0.12);
}

#solutionsSubcategoryFilters .chip:hover {
  border-color: rgba(159, 102, 255, 0.78);
  box-shadow: 0 6px 16px rgba(31, 15, 57, 0.45);
}

#solutionsSubcategoryFilters .chip.chip-active {
  border-color: rgba(255, 208, 92, 0.9);
  background: linear-gradient(145deg, rgba(255, 208, 92, 0.32), rgba(245, 187, 58, 0.2));
  color: #fff5d8;
  box-shadow: 0 0 0 1px rgba(255, 208, 92, 0.32), 0 10px 24px rgba(74, 45, 6, 0.5);
}

#workflowClientFilters .chip {
  border-color: rgba(87, 213, 157, 0.45);
  background: linear-gradient(145deg, rgba(87, 213, 157, 0.14), rgba(87, 213, 157, 0.08));
  color: #b7f8dc;
  box-shadow: inset 0 0 0 1px rgba(87, 213, 157, 0.08);
}

#workflowClientFilters .chip:hover {
  border-color: rgba(87, 213, 157, 0.75);
  box-shadow: 0 6px 16px rgba(6, 34, 24, 0.4);
}

#workflowClientFilters .chip.chip-active {
  border-color: rgba(255, 208, 92, 0.9);
  background: linear-gradient(145deg, rgba(255, 208, 92, 0.32), rgba(245, 187, 58, 0.2));
  color: #fff5d8;
  box-shadow: 0 0 0 1px rgba(255, 208, 92, 0.32), 0 10px 24px rgba(74, 45, 6, 0.5);
}

#workflowExpertiseFilters .chip {
  border-color: rgba(159, 102, 255, 0.45);
  background: linear-gradient(145deg, rgba(159, 102, 255, 0.16), rgba(159, 102, 255, 0.08));
  color: #e7d6ff;
  box-shadow: inset 0 0 0 1px rgba(159, 102, 255, 0.12);
}

#workflowExpertiseFilters .chip:hover {
  border-color: rgba(159, 102, 255, 0.78);
  box-shadow: 0 6px 16px rgba(31, 15, 57, 0.45);
}

#workflowExpertiseFilters .chip.chip-active {
  border-color: rgba(255, 208, 92, 0.9);
  background: linear-gradient(145deg, rgba(255, 208, 92, 0.32), rgba(245, 187, 58, 0.2));
  color: #fff5d8;
  box-shadow: 0 0 0 1px rgba(255, 208, 92, 0.32), 0 10px 24px rgba(74, 45, 6, 0.5);
}

#workflowCategoryFilters .chip {
  border-color: rgba(89, 179, 255, 0.45);
  background: linear-gradient(145deg, rgba(89, 179, 255, 0.18), rgba(89, 179, 255, 0.1));
  color: #d0ecff;
  box-shadow: inset 0 0 0 1px rgba(89, 179, 255, 0.12);
}

#workflowCategoryFilters .chip:hover {
  border-color: rgba(89, 179, 255, 0.78);
  box-shadow: 0 6px 16px rgba(7, 33, 56, 0.45);
}

#workflowCategoryFilters .chip.chip-active {
  border-color: rgba(255, 208, 92, 0.9);
  background: linear-gradient(145deg, rgba(255, 208, 92, 0.32), rgba(245, 187, 58, 0.2));
  color: #fff5d8;
  box-shadow: 0 0 0 1px rgba(255, 208, 92, 0.32), 0 10px 24px rgba(74, 45, 6, 0.5);
}

.cards-grid {
  margin-top: 22px;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 16px;
}

.card {
  background: linear-gradient(170deg, rgba(26, 33, 48, 0.95), rgba(20, 26, 38, 0.94));
  border: 1px solid rgba(154, 166, 196, 0.18);
  border-radius: 16px;
  padding: 16px;
  display: grid;
  gap: 12px;
  box-shadow: 0 14px 34px rgba(2, 6, 13, 0.38);
  cursor: pointer;
  transition: transform 120ms ease, border-color 120ms ease;
}

.card:hover,
.card:focus-visible {
  border-color: rgba(159, 102, 255, 0.52);
  transform: translateY(-2px);
}

.card.card-highlighted {
  border-color: rgba(255, 208, 92, 0.9);
  box-shadow: 0 0 0 1px rgba(255, 208, 92, 0.32), 0 14px 34px rgba(2, 6, 13, 0.38);
}

.card.card-highlighted:hover,
.card.card-highlighted:focus-visible {
  border-color: rgba(255, 208, 92, 0.9);
}

.card:focus-visible {
  outline: 2px solid rgba(159, 102, 255, 0.7);
  outline-offset: 2px;
}

.card-title {
  margin: 0;
  font-size: 1.04rem;
}

.card-description {
  margin: 0;
  color: var(--text-muted);
  line-height: 1.45;
  font-size: 0.92rem;
}


.status {
  margin: 0;
  padding: 14px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text-muted);
}

.status-warning {
  border-color: rgba(255, 197, 94, 0.45);
  color: #ffe2a4;
}

.status-error {
  border-color: rgba(255, 114, 114, 0.45);
  color: #ffb4b4;
}

.badges,
.modal-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  justify-self: start;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 0.78rem;
  background: rgba(159, 102, 255, 0.16);
  color: #e7d6ff;
  border-color: 1px solid rgba(159, 102, 255, 0.45);
}

.badge-client {
  background: rgba(87, 213, 157, 0.14);
  color: #b3f3d6;
  border: 1px solid rgba(87, 213, 157, 0.4);
}

.badge-main {
  background: rgba(87, 213, 157, 0.14);
  color: #b3f3d6;
  border: 1px solid rgba(87, 213, 157, 0.4);
}

.badge-sub {
  background: linear-gradient(145deg, rgba(159, 102, 255, 0.16), rgba(159, 102, 255, 0.08));
  color: #e7d6ff;
  border-color: rgba(159, 102, 255, 0.45);
}

.badge-expertise {
  background: linear-gradient(145deg, rgba(159, 102, 255, 0.16), rgba(159, 102, 255, 0.08));
  color: #e7d6ff;
  border-color: rgba(159, 102, 255, 0.45);
}

.badge-cat1,
.badge-cat2 {
  background: linear-gradient(145deg, rgba(89, 179, 255, 0.18), rgba(89, 179, 255, 0.1));
  color: #d0ecff;
  border-color: rgba(89, 179, 255, 0.48);
}

.badge-sub.badge-action,
.badge-sub.badge-clickable,
.badge-expertise.badge-action,
.badge-expertise.badge-clickable {
  background: linear-gradient(145deg, rgba(159, 102, 255, 0.16), rgba(159, 102, 255, 0.08));
  color: #e7d6ff;
  border-color: rgba(159, 102, 255, 0.45);
}

.badge-cat1.badge-action,
.badge-cat1.badge-clickable,
.badge-cat2.badge-action,
.badge-cat2.badge-clickable {
  background: linear-gradient(145deg, rgba(89, 179, 255, 0.18), rgba(89, 179, 255, 0.1));
  color: #d0ecff;
  border-color: rgba(89, 179, 255, 0.48);
}

.badge-sub.badge-action:hover,
.badge-sub.badge-clickable:hover,
.badge-expertise.badge-action:hover,
.badge-expertise.badge-clickable:hover {
  border-color: rgba(159, 102, 255, 0.78);
  box-shadow: 0 6px 16px rgba(31, 15, 57, 0.45);
}

.badge-cat1.badge-action:hover,
.badge-cat1.badge-clickable:hover,
.badge-cat2.badge-action:hover,
.badge-cat2.badge-clickable:hover {
  border-color: rgba(89, 179, 255, 0.78);
  box-shadow: 0 6px 16px rgba(7, 33, 56, 0.45);
}

.badge-accent {
  background: linear-gradient(145deg, rgba(89, 179, 255, 0.18), rgba(89, 179, 255, 0.1));
  color: #d0ecff;
  border-color: rgba(89, 179, 255, 0.48);
}



.badge-clickable,
.badge-action {
  appearance: none;
  cursor: pointer;
  transition: transform 120ms ease, border-color 120ms ease, box-shadow 120ms ease;
}

.badge-clickable:hover,
.badge-action:hover {
  transform: translateY(-1px);
}

.badge-clickable:focus-visible,
.badge-action:focus-visible {
  outline: 2px solid rgba(255, 208, 92, 0.8);
  outline-offset: 2px;
}


.modal-backdrop[hidden] {
  display: none;
}
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(8, 12, 20, 0.8);
  backdrop-filter: blur(4px);
  display: grid;
  place-items: center;
  padding: 24px;
  z-index: 100;
}

.modal {
  position: relative;
  width: min(760px, 100%);
  max-height: 88vh;
  overflow-y: auto;
  background: linear-gradient(170deg, rgba(26, 33, 48, 0.98), rgba(20, 26, 38, 0.97));
  border: 1px solid rgba(159, 102, 255, 0.4);
  border-radius: 18px;
  padding: 22px;
  box-shadow: 0 24px 60px rgba(1, 5, 14, 0.75);
  display: grid;
  gap: 14px;
  scrollbar-gutter: stable;
}

.modal-title {
  margin: 0;
}

.modal-description {
  margin: 0;
  color: var(--text-muted);
  line-height: 1.5;
}

.modal-subtitle {
  margin: 6px 0 0;
  font-size: 1rem;
}

.modal-details {
  margin: 0;
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 10px 16px;
}

.modal-details dt {
  margin: 0;
  color: #d8dfff;
  font-weight: 600;
  text-transform: capitalize;
}

.modal-details dd {
  margin: 0;
  color: var(--text-muted);
  word-break: break-word;
}

.modal-empty {
  margin: 0;
  color: var(--text-muted);
}

.modal-close {
  position: absolute;
  top: 12px;
  right: 12px;
  border: 1px solid rgba(154, 166, 196, 0.35);
  background: rgba(154, 166, 196, 0.12);
  color: #f0f4ff;
  border-radius: 10px;
  width: 34px;
  height: 34px;
  font-size: 1.3rem;
  line-height: 1;
  cursor: pointer;
}

.modal-close:hover {
  border-color: rgba(159, 102, 255, 0.65);
  background: rgba(159, 102, 255, 0.22);
}

@media (max-width: 900px) {
  .app-shell {
    grid-template-columns: 1fr;
  }

  .sidebar {
    border-right: 0;
    border-bottom: 1px solid rgba(154, 166, 196, 0.18);
  }
}

@media (max-width: 640px) {
  .content {
    padding: 22px;
  }

  .modal-details {
    grid-template-columns: 1fr;
    gap: 4px;
  }

  .modal {
    padding: 18px;
  }
}


.definition-page {
  color: var(--text);
}

.definition-page .content {
  padding-top: 40px;
}

.definition-topbar {
  align-items: center;
}

.definition-eyebrow {
  margin: 0 0 8px;
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 700;
  color: #c9abff;
}

.definition-page h1 {
  color: var(--text);
}

.definition-page .topbar p {
  color: var(--text-muted);
  max-width: 62ch;
}

.definition-tag {
  display: inline-flex;
  align-items: center;
  padding: 10px 16px;
  border-radius: 999px;
  border: 1px solid rgba(89, 179, 255, 0.42);
  background: rgba(20, 26, 38, 0.86);
  color: #b8deff;
  font-weight: 700;
  box-shadow: 0 10px 25px rgba(8, 17, 31, 0.35);
  white-space: nowrap;
}

.definition-intro {
  margin-top: 24px;
  padding: 22px;
  border-radius: 20px;
  border: 1px solid rgba(159, 102, 255, 0.26);
  background: linear-gradient(140deg, rgba(20, 26, 38, 0.9), rgba(16, 22, 33, 0.95));
  box-shadow: 0 16px 35px rgba(2, 7, 18, 0.42);
}

.definition-intro p {
  margin: 0;
  color: #c8d2ea;
  line-height: 1.6;
}

.definition-grid {
  margin-top: 24px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 18px;
}

.definition-card {
  padding: 22px;
  border-radius: 22px;
  border: 1px solid rgba(154, 166, 196, 0.2);
  background: linear-gradient(170deg, rgba(20, 26, 38, 0.96), rgba(16, 22, 33, 0.96));
  box-shadow: 0 20px 42px rgba(2, 6, 13, 0.42);
  display: grid;
  gap: 10px;
}

.definition-step {
  margin: 0;
  font-size: 0.74rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-weight: 700;
  color: #c9abff;
}

.definition-card h2 {
  margin: 0;
  font-size: 1.35rem;
  color: var(--text);
}

.definition-hook {
  margin: 0;
  font-weight: 700;
  color: #e7d6ff;
}

.definition-card > p {
  margin: 0;
  color: var(--text-muted);
  line-height: 1.6;
}

.definition-card ul {
  margin: 6px 0 0;
  padding-left: 18px;
  display: grid;
  gap: 9px;
  color: #d8dfff;
}

.card-custom {
  border-color: rgba(89, 179, 255, 0.3);
  background: linear-gradient(165deg, rgba(20, 26, 38, 0.96), rgba(14, 28, 46, 0.96));
}

.card-agent {
  border-color: rgba(159, 102, 255, 0.36);
  background: linear-gradient(165deg, rgba(20, 26, 38, 0.96), rgba(28, 20, 46, 0.96));
}

.card-workflow {
  border-color: rgba(87, 213, 157, 0.32);
  background: linear-gradient(165deg, rgba(20, 26, 38, 0.96), rgba(13, 35, 33, 0.96));
}

@media (max-width: 900px) {
  .definition-page .sidebar {
    border-right: 0;
    border-bottom: 1px solid rgba(154, 166, 196, 0.18);
  }
}

@media (max-width: 640px) {
  .definition-tag {
    display: none;
  }

  .definition-card {
    padding: 18px;
    border-radius: 18px;
  }
}

.hub-page .topbar p {
  max-width: 60ch;
}

.hub-grid {
  margin-top: 28px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 18px;
}

.hub-card {
  display: grid;
  gap: 10px;
  padding: 22px;
  border-radius: 18px;
  text-decoration: none;
  border: 1px solid rgba(159, 102, 255, 0.3);
  background: linear-gradient(160deg, rgba(26, 33, 48, 0.94), rgba(20, 26, 38, 0.95));
  box-shadow: 0 16px 36px rgba(2, 6, 13, 0.42);
  transition: transform 120ms ease, border-color 120ms ease;
}

.hub-card:hover,
.hub-card:focus-visible {
  transform: translateY(-3px);
  border-color: rgba(89, 179, 255, 0.6);
}

.hub-card:focus-visible {
  outline: 2px solid rgba(89, 179, 255, 0.7);
  outline-offset: 2px;
}

.hub-card-label {
  margin: 0;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  font-weight: 700;
  color: #9bc8ff;
}

.hub-card h2 {
  margin: 0;
  color: #f5f7ff;
  font-size: 1.3rem;
}

.hub-card p {
  margin: 0;
  color: #c6d1eb;
  line-height: 1.5;
}
