@import url("https://fonts.googleapis.com/css2?family=Manrope:wght@400;500;700;800&family=Sora:wght@500;600;700&display=swap");

:root {
  --bg: #f5f8fc;
  --panel: #ffffff;
  --ink: #1c2633;
  --muted: #536072;
  --line: #d9e4f2;
  --primary: #2f66c9;
  --primary-deep: #214b95;
  --secondary: #2d8f78;
  --accent: #f6b144;
  --shadow: 0 18px 42px rgba(37, 69, 121, 0.12);
  --radius: 20px;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

body {
  font-family: "Manrope", "Segoe UI", sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at 12% 18%, rgba(47, 102, 201, 0.2), transparent 35%),
    radial-gradient(circle at 88% 8%, rgba(45, 143, 120, 0.18), transparent 32%),
    var(--bg);
  line-height: 1.6;
}

a {
  color: var(--primary);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

.container {
  width: min(1120px, 92vw);
  margin: 0 auto;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(245, 248, 252, 0.88);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(217, 228, 242, 0.9);
}

.topbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.9rem 0;
  gap: 1rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  font-family: "Sora", "Manrope", sans-serif;
  font-weight: 700;
  font-size: 1.02rem;
  color: var(--ink);
}

.brand img {
  width: 34px;
  height: 34px;
  border-radius: 10px;
}

.nav {
  display: flex;
  gap: 1.1rem;
  align-items: center;
  flex-wrap: wrap;
}

.nav a {
  font-size: 0.95rem;
  color: #30425c;
  font-weight: 600;
}

.hero {
  padding: 5rem 0 2.9rem;
}

.hero-panel {
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.97), rgba(245, 251, 255, 0.96));
  border: 1px solid rgba(217, 228, 242, 0.95);
  border-radius: 32px;
  box-shadow: var(--shadow);
  padding: clamp(1.5rem, 3vw, 3rem);
  display: grid;
  gap: 1.8rem;
  grid-template-columns: 1.3fr 1fr;
  align-items: center;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  background: rgba(47, 102, 201, 0.12);
  color: var(--primary-deep);
  border-radius: 999px;
  font-size: 0.78rem;
  letter-spacing: 0.02em;
  font-weight: 700;
  padding: 0.42rem 0.7rem;
}

h1,
h2,
h3 {
  margin: 0;
  font-family: "Sora", "Manrope", sans-serif;
  line-height: 1.15;
}

h1 {
  font-size: clamp(1.8rem, 5vw, 3rem);
  margin-top: 0.9rem;
  margin-bottom: 1rem;
}

.hero p {
  margin: 0 0 1.1rem;
  color: var(--muted);
  max-width: 56ch;
}

.hero-actions {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  border-radius: 12px;
  border: 1px solid transparent;
  padding: 0.7rem 1rem;
  font-size: 0.95rem;
  font-weight: 700;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.button:hover {
  transform: translateY(-1px);
  text-decoration: none;
}

.button.primary {
  color: #fff;
  background: linear-gradient(135deg, var(--primary), #4d86ea);
  box-shadow: 0 9px 24px rgba(47, 102, 201, 0.27);
}

.button.secondary {
  color: var(--primary);
  background: #eef4ff;
  border-color: #d7e4fa;
}

.hero-shot {
  background: linear-gradient(145deg, #f6fbff, #ffffff);
  border: 1px solid #dbe8f7;
  border-radius: 22px;
  padding: 0.9rem;
}

.hero-shot img {
  width: 100%;
  display: block;
  border-radius: 15px;
  border: 1px solid #d9e6f5;
}

.hero-shot figcaption {
  margin-top: 0.65rem;
  font-size: 0.82rem;
  color: #637086;
}

.principles-strip {
  padding-top: 0;
}

.principles-wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
}

.principle-pill {
  border: 1px solid #d6e5f6;
  border-radius: 999px;
  padding: 0.5rem 0.8rem;
  background: linear-gradient(130deg, #ffffff, #f4f9ff);
  color: #315178;
  font-size: 0.83rem;
  font-weight: 700;
  box-shadow: 0 5px 16px rgba(35, 69, 113, 0.08);
}

section {
  padding: 2.7rem 0;
}

.section-head {
  max-width: 65ch;
  margin-bottom: 1.4rem;
}

.section-head p {
  margin: 0.65rem 0 0;
  color: var(--muted);
}

.section-cta {
  margin-top: 1rem;
}

.foundation-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
}

.foundation-card {
  border: 1px solid #d9e6f5;
  border-radius: 19px;
  padding: 1rem;
  background:
    linear-gradient(155deg, rgba(255, 255, 255, 0.99), rgba(244, 250, 255, 0.98));
  box-shadow: 0 10px 26px rgba(29, 63, 106, 0.09);
}

.foundation-card h3 {
  font-size: 1.05rem;
  margin-bottom: 0.45rem;
}

.foundation-card p {
  margin: 0;
  color: #4d627a;
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.1rem;
}

.card h3 {
  font-size: 1.08rem;
  margin-bottom: 0.45rem;
}

.card p,
.card li {
  color: #4e5d70;
}

.process {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.9rem;
}

.step {
  border: 1px solid var(--line);
  border-radius: 16px;
  background: linear-gradient(180deg, #ffffff, #f8fbff);
  padding: 1rem;
}

.step strong {
  display: inline-flex;
  width: 1.8rem;
  height: 1.8rem;
  border-radius: 999px;
  align-items: center;
  justify-content: center;
  background: rgba(47, 102, 201, 0.14);
  color: var(--primary-deep);
  font-size: 0.9rem;
  margin-bottom: 0.6rem;
}

.ai-panel {
  border: 1px solid #d8e7f7;
  border-radius: 30px;
  padding: clamp(1.2rem, 3vw, 2.2rem);
  background:
    radial-gradient(circle at 5% 8%, rgba(47, 102, 201, 0.11), transparent 34%),
    radial-gradient(circle at 94% 16%, rgba(246, 177, 68, 0.14), transparent 32%),
    linear-gradient(140deg, rgba(255, 255, 255, 0.98), rgba(245, 251, 255, 0.98));
  box-shadow: 0 16px 42px rgba(27, 58, 101, 0.12);
}

.ai-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.85rem;
}

.ai-card {
  border: 1px solid #d5e6fb;
  border-radius: 18px;
  padding: 1rem;
  background: rgba(255, 255, 255, 0.92);
}

.ai-card h3 {
  font-size: 1rem;
  margin-bottom: 0.4rem;
}

.ai-card p {
  margin: 0;
  color: #4d6177;
}

.showcase {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.85rem;
}

.showcase img {
  width: 100%;
  display: block;
  border-radius: 16px;
  border: 1px solid #d7e3f4;
  box-shadow: 0 6px 20px rgba(26, 60, 109, 0.12);
}

.legal-wrap {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 1rem;
}

.legal-box {
  background: linear-gradient(150deg, #ffffff, #f4f9ff);
  border: 1px solid #d8e5f4;
  border-radius: 18px;
  padding: 1rem;
}

.legal-box h3 {
  margin-bottom: 0.45rem;
}

.legal-box ul {
  margin: 0.5rem 0 0;
  padding-left: 1.1rem;
}

.notice {
  border-left: 4px solid var(--accent);
  background: #fffaf0;
  padding: 0.95rem 1rem;
  border-radius: 12px;
  color: #5f4a29;
  margin-top: 1rem;
}

.footer {
  border-top: 1px solid var(--line);
  margin-top: 2rem;
  padding: 1.2rem 0 2.8rem;
  color: #57657a;
  font-size: 0.92rem;
}

.footer-links {
  display: flex;
  gap: 0.85rem;
  flex-wrap: wrap;
  margin-top: 0.5rem;
}

.legal-page {
  padding: 3rem 0;
}

.legal-page .card {
  margin-bottom: 1rem;
}

.legal-page h1 {
  font-size: clamp(1.8rem, 4.5vw, 2.6rem);
  margin-bottom: 0.8rem;
}

.legal-page h2 {
  font-size: 1.25rem;
  margin-bottom: 0.6rem;
}

.legal-page p,
.legal-page li {
  color: #4a596b;
}

.legal-page ul {
  margin: 0.4rem 0 0;
  padding-left: 1.15rem;
}

@media (max-width: 1000px) {
  .hero-panel,
  .legal-wrap,
  .grid-3,
  .process,
  .showcase,
  .foundation-grid,
  .ai-grid {
    grid-template-columns: 1fr;
  }

  .hero {
    padding-top: 3.2rem;
  }

  .topbar-inner {
    align-items: flex-start;
    flex-direction: column;
  }
}

/* Mallar & Verktyg */
.academy-page {
  background:
    radial-gradient(circle at 8% 12%, rgba(248, 201, 113, 0.28), transparent 28%),
    radial-gradient(circle at 90% 2%, rgba(53, 135, 207, 0.2), transparent 30%),
    linear-gradient(180deg, #f8fbff 0%, #f2f7fc 100%);
}

.academy-section {
  position: relative;
}

.academy-hero {
  padding: 4.8rem 0 2.2rem;
}

.academy-hero-panel {
  display: grid;
  grid-template-columns: 1.25fr 0.75fr;
  gap: 1rem;
  border-radius: 34px;
  border: 1px solid rgba(207, 221, 238, 0.95);
  padding: clamp(1.4rem, 3.2vw, 2.8rem);
  background:
    linear-gradient(128deg, rgba(255, 255, 255, 0.98), rgba(248, 252, 255, 0.92)),
    radial-gradient(circle at 87% 19%, rgba(44, 126, 198, 0.12), transparent 37%);
  box-shadow: 0 20px 55px rgba(29, 57, 97, 0.14);
  overflow: hidden;
}

.academy-hero-copy p {
  color: #546375;
  max-width: 58ch;
}

.academy-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
}

.academy-metrics {
  display: grid;
  gap: 0.75rem;
}

.academy-metrics article {
  padding: 1rem;
  border-radius: 18px;
  border: 1px solid rgba(214, 227, 242, 0.94);
  background: rgba(255, 255, 255, 0.88);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7);
}

.academy-metrics span {
  display: block;
  font-family: "Sora", "Manrope", sans-serif;
  font-size: clamp(1.45rem, 2vw, 2rem);
  line-height: 1;
  color: #17458e;
  letter-spacing: -0.02em;
}

.academy-metrics p {
  margin: 0.4rem 0 0;
  color: #5d6d81;
  font-size: 0.88rem;
}

.tools-section {
  padding-top: 2.8rem;
}

.tool-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.tool-card {
  border-radius: 14px;
  padding: 1.2rem;
  border: 1px solid rgba(200, 215, 235, 0.52);
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.98), rgba(249, 252, 255, 0.97));
  box-shadow:
    0 4px 6px -1px rgba(15, 23, 42, 0.05),
    0 2px 4px -2px rgba(15, 23, 42, 0.05);
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.tool-card:hover {
  transform: translateY(-2px);
  border-color: rgba(145, 173, 212, 0.72);
  box-shadow:
    0 8px 14px -3px rgba(15, 23, 42, 0.08),
    0 3px 6px -4px rgba(15, 23, 42, 0.06);
}

.tool-card-head {
  display: flex;
  align-items: center;
  gap: 0.78rem;
  margin-bottom: 0.72rem;
}

.tool-icon {
  width: 2.15rem;
  height: 2.15rem;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(47, 102, 201, 0.08);
  border: 1px solid rgba(161, 187, 224, 0.38);
  color: #2f66c9;
  flex-shrink: 0;
}

.tool-icon svg {
  width: 1.08rem;
  height: 1.08rem;
}

.tool-icon svg * {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.tool-card h3 {
  font-size: 1rem;
  font-weight: 700;
  color: #19263a;
  margin: 0;
}

.tool-description {
  margin: 0;
  color: #465b74;
  font-size: 0.92rem;
  line-height: 1.62;
}

.tool-divider {
  margin: 0.9rem 0 0.78rem;
  border: 0;
  border-top: 1px solid rgba(205, 220, 238, 0.62);
}

.tool-practice {
  margin: 0;
  color: #5b6f88;
  font-size: 0.86rem;
  line-height: 1.58;
  display: flex;
  gap: 0.42rem;
}

.tool-practice-icon {
  color: #5b84c7;
  font-weight: 700;
  line-height: 1.4;
  margin-top: 0.05rem;
  flex-shrink: 0;
}

.library-section {
  padding-top: 2.9rem;
  padding-bottom: 4rem;
}

.library-layout {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 1.4rem;
  align-items: start;
}

.library-sidebar {
  position: sticky;
  top: 5.7rem;
  border-radius: 14px;
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.99), rgba(248, 252, 255, 0.97));
  border: 1px solid rgba(200, 215, 235, 0.52);
  box-shadow:
    0 4px 6px -1px rgba(15, 23, 42, 0.05),
    0 2px 4px -2px rgba(15, 23, 42, 0.05);
  padding: 1.15rem;
}

.search-wrap {
  position: relative;
  display: grid;
  gap: 0.44rem;
  margin-bottom: 1.05rem;
}

.search-wrap::after {
  content: "";
  position: absolute;
  left: 0.78rem;
  bottom: 0.73rem;
  width: 0.95rem;
  height: 0.95rem;
  background-repeat: no-repeat;
  background-size: contain;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23667c99' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='M20 20l-3.4-3.4'/%3E%3C/svg%3E");
  pointer-events: none;
}

.search-wrap span {
  font-weight: 700;
  font-size: 0.8rem;
  color: #2e435f;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.search-wrap input {
  border-radius: 12px;
  border: 1px solid rgba(195, 211, 232, 0.45);
  padding: 0.72rem 0.84rem 0.72rem 2.25rem;
  font: inherit;
  color: #243448;
  background: #f5f9fd;
}

.search-wrap input:focus {
  outline: none;
  border-color: rgba(121, 156, 206, 0.7);
  box-shadow: 0 0 0 3px rgba(47, 102, 201, 0.12);
}

.filter-block {
  margin-bottom: 1.02rem;
}

.filter-block h3 {
  font-size: 0.76rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 0.48rem;
  color: #536b88;
}

.chip-group {
  display: flex;
  flex-wrap: wrap;
  gap: 0.42rem;
}

.chip,
.chip-toggle {
  border: 1px solid rgba(193, 210, 232, 0.66);
  background: transparent;
  color: #3f5a7d;
  border-radius: 999px;
  padding: 0.34rem 0.62rem;
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  cursor: pointer;
  transition: border-color 0.18s ease, color 0.18s ease, background-color 0.18s ease;
}

.chip:hover,
.chip-toggle:hover {
  border-color: rgba(139, 166, 204, 0.8);
  color: #294d77;
}

.chip.is-active,
.chip-toggle.is-active {
  color: #ffffff;
  border-color: #234f97;
  background: #234f97;
  box-shadow: none;
}

.chip-toggle {
  width: 100%;
  text-align: center;
  margin-top: 0.24rem;
}

.library-count {
  margin: 1rem 0 0;
  font-size: 0.77rem;
  color: #617893;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.template-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.05rem;
}

.template-card {
  border-radius: 14px;
  border: 1px solid rgba(200, 215, 235, 0.52);
  border-left: 4px solid var(--template-accent, #5e7798);
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.99), rgba(249, 252, 255, 0.98));
  box-shadow:
    0 4px 6px -1px rgba(15, 23, 42, 0.05),
    0 2px 4px -2px rgba(15, 23, 42, 0.05);
  padding: 1.15rem;
  display: grid;
  gap: 0.74rem;
  cursor: pointer;
  transition: border-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.template-card:hover,
.template-card:focus-visible {
  transform: translateY(-2px);
  border-color: rgba(145, 173, 212, 0.74);
  box-shadow:
    0 8px 14px -3px rgba(15, 23, 42, 0.08),
    0 3px 6px -4px rgba(15, 23, 42, 0.06);
  outline: none;
}

.template-card.is-expanded {
  border-color: rgba(134, 166, 210, 0.78);
}

.template-card h3 {
  font-size: 1.02rem;
  font-weight: 700;
  color: #18253a;
  line-height: 1.35;
}

.template-badge {
  display: inline-flex;
  width: fit-content;
  padding: 0.18rem 0.48rem;
  border-radius: 999px;
  background: rgba(47, 102, 201, 0.1);
  color: #274f8f;
  font-size: 0.64rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.template-meta {
  margin: 0;
  color: #6b819b;
  font-size: 0.73rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
}

.template-description {
  margin: 0;
  color: #4b617c;
  font-size: 0.91rem;
  line-height: 1.6;
}

.template-snippet {
  margin: 0;
  padding-left: 0;
  list-style: none;
  color: #4c6076;
  font-size: 0.82rem;
  display: grid;
  gap: 0.4rem;
}

.template-snippet-row {
  display: flex;
  align-items: flex-start;
  gap: 0.45rem;
  line-height: 1.45;
}

.template-snippet-dot {
  width: 0.34rem;
  height: 0.34rem;
  border-radius: 999px;
  background: rgba(130, 149, 177, 0.8);
  margin-top: 0.42rem;
  flex-shrink: 0;
}

.template-snippet-text {
  color: #5a6e87;
}

.template-open {
  justify-self: start;
  margin: 0.1rem 0 0;
  font-size: 0.83rem;
  font-weight: 700;
  color: #234f97;
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  letter-spacing: 0.01em;
}

.template-open-arrow {
  transition: transform 0.2s ease;
}

.template-card:hover .template-open-arrow,
.template-card:focus-visible .template-open-arrow {
  transform: translateX(3px);
}

.template-card.is-expanded .template-open-arrow {
  transform: translateY(-1px);
}

.empty-state {
  margin: 0.8rem 0 0;
  color: #647a94;
}

.template-expanded-content {
  display: none;
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px dashed rgba(201, 216, 236, 0.92);
}

.template-card.is-expanded .template-expanded-content {
  display: block;
  animation: expandIn 240ms ease both;
}

.template-expanded-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.82rem;
  align-items: start;
}

.template-expanded-block {
  padding: 0.95rem;
  background: #f8fbff;
  border: 1px solid rgba(200, 215, 235, 0.58);
  border-radius: 8px;
}

.template-expanded-block h4 {
  margin: 0 0 0.48rem;
  font-size: 0.84rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: #395775;
}

.template-expanded-copy {
  margin: 0;
  color: #4f647f;
  font-size: 0.85rem;
  line-height: 1.58;
}

.template-expanded-meta {
  margin: 0 0 0.5rem;
  color: #5d7592;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.template-expanded-list {
  margin: 0;
  padding-left: 1rem;
  color: #4f637c;
  font-size: 0.84rem;
  display: grid;
  gap: 0.34rem;
}

.template-expanded-list--tight li {
  display: flex;
  justify-content: space-between;
  gap: 0.55rem;
}

.template-expanded-list--tight strong {
  color: #4f6782;
  font-size: 0.74rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  white-space: nowrap;
}

@keyframes expandIn {
  from {
    opacity: 0;
    transform: translateY(-6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 1080px) {
  .academy-hero-panel,
  .library-layout {
    grid-template-columns: 1fr;
  }

  .library-sidebar {
    position: static;
  }

  .template-expanded-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .academy-hero {
    padding-top: 3.2rem;
  }
}

/* Mallbibliotek */
.catalog-page {
  background:
    radial-gradient(circle at 9% 12%, rgba(248, 201, 113, 0.2), transparent 30%),
    radial-gradient(circle at 92% 3%, rgba(53, 135, 207, 0.14), transparent 29%),
    linear-gradient(180deg, #f8fbff 0%, #f3f8fd 100%);
}

.catalog-hero {
  padding: 4.2rem 0 1.6rem;
}

.catalog-hero h1 {
  margin-top: 0.8rem;
  margin-bottom: 0.75rem;
}

.catalog-hero p {
  margin: 0;
  max-width: 72ch;
  color: #4f637c;
}

.catalog-section {
  padding-top: 1.3rem;
  padding-bottom: 3rem;
}

.catalog-layout {
  display: grid;
  grid-template-columns: 360px 1fr;
  gap: 1.2rem;
  align-items: start;
}

.catalog-sidebar {
  position: sticky;
  top: 5.7rem;
  border-radius: 14px;
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.99), rgba(248, 252, 255, 0.97));
  border: 1px solid rgba(200, 215, 235, 0.52);
  box-shadow:
    0 4px 6px -1px rgba(15, 23, 42, 0.05),
    0 2px 4px -2px rgba(15, 23, 42, 0.05);
  padding: 1rem;
}

.catalog-filter-block {
  margin-bottom: 0.8rem;
}

.catalog-filter-block h3 {
  margin: 0 0 0.5rem;
  font-size: 0.76rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #536b88;
}

.catalog-checkboxes {
  display: grid;
  gap: 0.35rem;
}

.catalog-checkbox {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.18rem 0.1rem;
  color: #445b79;
  font-size: 0.85rem;
}

.catalog-checkbox input {
  width: 1rem;
  height: 1rem;
  accent-color: #2f66c9;
}

.catalog-list {
  margin-top: 0.8rem;
  display: grid;
  gap: 0.42rem;
  max-height: 54vh;
  overflow: auto;
  padding-right: 0.2rem;
}

.catalog-list-item {
  width: 100%;
  border: 1px solid rgba(200, 215, 235, 0.52);
  border-radius: 10px;
  background: #ffffff;
  text-align: left;
  padding: 0.6rem 0.68rem;
  cursor: pointer;
  transition: border-color 0.18s ease, background-color 0.18s ease;
}

.catalog-list-item:hover {
  border-color: rgba(135, 169, 214, 0.78);
  background: #f7fbff;
}

.catalog-list-item.is-active {
  border-color: rgba(92, 136, 196, 0.8);
  background: #eff5ff;
}

.catalog-list-title {
  margin: 0;
  font-size: 0.9rem;
  font-weight: 700;
  color: #1f2d42;
}

.catalog-list-meta {
  margin: 0.2rem 0 0;
  font-size: 0.72rem;
  color: #67809c;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
}

.catalog-detail {
  min-height: 640px;
}

.catalog-placeholder {
  border: 1px dashed rgba(191, 210, 234, 0.9);
  border-radius: 12px;
  background: rgba(250, 253, 255, 0.92);
  color: #5c7492;
  padding: 1.2rem;
}

.catalog-detail-card {
  border-radius: 14px;
  border: 1px solid rgba(200, 215, 235, 0.52);
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.99), rgba(249, 252, 255, 0.98));
  box-shadow:
    0 4px 6px -1px rgba(15, 23, 42, 0.05),
    0 2px 4px -2px rgba(15, 23, 42, 0.05);
  padding: 1rem;
}

.catalog-detail-head {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 1rem;
}

.catalog-detail-head img {
  width: 100%;
  border-radius: 12px;
  border: 1px solid rgba(198, 214, 234, 0.62);
  box-shadow:
    0 6px 12px -4px rgba(15, 23, 42, 0.12),
    0 3px 6px -5px rgba(15, 23, 42, 0.1);
}

.catalog-detail-meta {
  margin: 0;
  color: #5f7794;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.catalog-detail-head h2 {
  margin: 0.45rem 0 0.5rem;
  font-size: 1.45rem;
  line-height: 1.2;
  color: #18253a;
}

.catalog-detail-head p {
  margin: 0;
  color: #4f637d;
}

.catalog-detail-usage {
  margin-top: 0.8rem !important;
  padding: 0.76rem 0.85rem;
  border-radius: 10px;
  border: 1px solid rgba(197, 214, 234, 0.62);
  background: #f6faff;
  color: #43617f;
  font-size: 0.88rem;
  line-height: 1.58;
}

.catalog-detail-grid {
  margin-top: 1rem;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: 0.8rem;
  align-items: start;
}

.catalog-detail-column {
  display: grid;
  gap: 0.8rem;
  align-content: start;
}

.catalog-detail-block {
  padding: 0.95rem;
  background: #f8fbff;
  border: 1px solid rgba(200, 215, 235, 0.58);
  border-radius: 8px;
}

.catalog-detail-block--research-quick {
  background: linear-gradient(155deg, #eef6ff, #f8fbff);
  border-color: rgba(132, 172, 224, 0.62);
}

.catalog-detail-block h3 {
  margin: 0 0 0.48rem;
  font-size: 0.84rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: #395775;
}

.catalog-detail-submeta {
  margin: 0 0 0.5rem;
  color: #5d7592;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.catalog-detail-block ul {
  margin: 0;
  padding-left: 1rem;
  color: #4f637c;
  font-size: 0.84rem;
  display: grid;
  gap: 0.34rem;
}

.catalog-detail-copy {
  margin: 0;
  color: #4f637c;
  font-size: 0.86rem;
  line-height: 1.58;
}

.catalog-flow-list li {
  display: grid;
  gap: 0.16rem;
}

.catalog-flow-list strong {
  font-size: 0.74rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #496689;
}

.catalog-disclosure {
  border: 1px solid rgba(153, 183, 221, 0.85);
  border-radius: 999px;
  background: #edf4ff;
  color: #1f4f93;
  font: inherit;
  font-size: 0.79rem;
  font-weight: 700;
  padding: 0.34rem 0.66rem;
  cursor: pointer;
}

.catalog-disclosure:hover,
.catalog-disclosure:focus-visible {
  background: #e3efff;
  outline: none;
}

#catalog-research-panel {
  margin-top: 0.62rem;
}

.catalog-item-list {
  list-style: none;
  padding-left: 0 !important;
  gap: 0.52rem !important;
}

.catalog-item-entry {
  padding: 0;
  border: 1px solid rgba(198, 214, 234, 0.62);
  border-radius: 8px;
  background: #ffffff;
  overflow: hidden;
}

.catalog-item-toggle {
  width: 100%;
  border: 0;
  background: #ffffff;
  text-align: left;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.55rem;
  align-items: start;
  padding: 0.65rem 0.68rem;
  cursor: pointer;
}

.catalog-item-toggle::after {
  content: "▾";
  grid-column: 2;
  grid-row: 1;
  color: #4f6782;
  font-size: 0.78rem;
  transform: rotate(-90deg);
  transition: transform 0.16s ease;
  margin-top: 0.2rem;
}

.catalog-item-entry.is-expanded .catalog-item-toggle::after {
  transform: rotate(0deg);
}

.catalog-item-toggle:hover,
.catalog-item-toggle:focus-visible {
  background: #f7fbff;
  outline: none;
}

.catalog-item-title {
  color: #1f2d42;
  font-size: 0.86rem;
  font-weight: 700;
}

.catalog-item-type {
  color: #4f6782;
  font-size: 0.74rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  white-space: nowrap;
}

.catalog-item-panel {
  border-top: 1px solid rgba(198, 214, 234, 0.52);
  padding: 0.56rem 0.68rem 0.65rem;
  background: #fbfdff;
}

.catalog-item-main {
  display: flex;
  justify-content: space-between;
  gap: 0.55rem;
  align-items: flex-start;
}

.catalog-item-list strong {
  color: #4f6782;
  font-size: 0.74rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  white-space: nowrap;
}

.catalog-item-support {
  margin: 0.4rem 0 0;
  font-size: 0.78rem;
  line-height: 1.45;
  color: #4f637c;
}

.catalog-item-support--muted {
  margin-top: 0.25rem;
  color: #607a99;
}

.catalog-item-support--research {
  margin-top: 0.25rem;
  color: #2f557d;
  font-weight: 600;
}

.catalog-item-support--logic {
  margin-top: 0.2rem;
  color: #597694;
  font-style: italic;
}

@media (max-width: 1080px) {
  .catalog-layout,
  .catalog-detail-head {
    grid-template-columns: 1fr;
  }

  .catalog-detail-grid {
    grid-template-columns: 1fr;
  }

  .catalog-sidebar {
    position: static;
  }

  .catalog-list {
    max-height: 36vh;
  }
}
