.os-infographics-page {
  min-height: 80vh;
  background:
    linear-gradient(180deg, rgba(248, 246, 241, 0.95), rgba(255, 255, 255, 0.98)),
    var(--ifm-background-color);
  padding: 2rem 1.5rem 5rem;
}

.os-infographics-header {
  align-items: center;
  display: grid;
  gap: clamp(2rem, 6vw, 5rem);
  grid-template-columns: minmax(0, 1.25fr) minmax(280px, 0.75fr);
  margin: 0 auto 1.5rem;
  max-width: 1320px;
  padding: clamp(1.5rem, 4vw, 3.25rem);
  border: 1px solid rgba(212, 175, 55, 0.24);
  border-radius: 28px;
  background:
    radial-gradient(circle at 88% 10%, rgba(212, 175, 55, 0.17), transparent 28%),
    linear-gradient(135deg, #26172f 0%, #17131d 58%, #101017 100%);
  box-shadow: 0 24px 60px rgba(18, 12, 22, 0.18);
}

.os-infographics-kicker {
  color: #e8c85e;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  margin: 0 0 0.5rem;
  text-transform: uppercase;
}

.os-infographics-title {
  color: #fffaf0;
  font-size: clamp(2.2rem, 5vw, 4.1rem);
  line-height: 1.05;
  margin: 0 0 0.75rem;
}

.os-infographics-description {
  color: rgba(255, 250, 240, 0.72);
  font-size: 1.08rem;
  line-height: 1.8;
  margin: 0;
  max-width: 720px;
}

.os-infographics-headerPanel {
  display: grid;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.055);
  backdrop-filter: blur(12px);
}

.os-infographics-headerPanel > div {
  align-items: baseline;
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  min-height: 66px;
  padding: 0.85rem 1rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.09);
}

.os-infographics-headerPanel > div:last-child {
  border-bottom: 0;
}

.os-infographics-headerPanel strong {
  color: #e8c85e;
  font-family: var(--ifm-heading-font-family);
  font-size: 1.45rem;
}

.os-infographics-headerPanel span {
  color: rgba(255, 250, 240, 0.72);
  font-size: 0.9rem;
}

.os-infographics-reuseNotice {
  align-items: center;
  display: inline-flex;
  font-weight: 700;
  gap: 0.65rem;
  justify-content: flex-start !important;
}

.os-infographics-reuseNotice svg {
  color: #e8c85e;
  flex: 0 0 auto;
}

.os-infographics-toolbar {
  align-items: start;
  display: grid;
  gap: 1rem;
  grid-template-columns: minmax(260px, 350px) minmax(0, 1fr);
  margin: 0 auto 1.5rem;
  max-width: 1320px;
  padding: 1rem;
  border: 1px solid rgba(31, 42, 46, 0.12);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: 0 14px 34px rgba(31, 42, 46, 0.07);
}

.os-infographics-searchColumn {
  min-width: 0;
}

.os-infographics-searchBox {
  align-items: center;
  background: #fff;
  border: 1px solid rgba(31, 42, 46, 0.16);
  border-radius: 12px;
  color: #536064;
  display: flex;
  gap: 0.65rem;
  min-height: 44px;
  padding: 0 0.85rem;
}

.os-infographics-searchBox input {
  background: transparent;
  border: 0;
  color: #1f2a2e;
  flex: 1;
  font-size: 0.98rem;
  min-width: 0;
  outline: 0;
}

.os-infographics-searchBox:focus-within {
  border-color: #62506d;
  box-shadow: 0 0 0 3px rgba(98, 80, 109, 0.12);
}

.os-infographics-resultCount {
  margin: 0.55rem 0 0;
  color: #718083;
  font-size: 0.85rem;
}

.os-infographics-mobileTagFilter {
  display: none;
}

.os-infographics-mobileTagFilter select {
  appearance: none;
  background:
    linear-gradient(45deg, transparent 50%, #536064 50%) right 1rem center / 6px 6px no-repeat,
    linear-gradient(135deg, #536064 50%, transparent 50%) right 0.68rem center / 6px 6px no-repeat,
    #fff;
  border: 1px solid rgba(31, 42, 46, 0.16);
  border-radius: 8px;
  color: #1f2a2e;
  font: inherit;
  font-size: 0.98rem;
  min-height: 44px;
  padding: 0 2.2rem 0 0.85rem;
  width: 100%;
}

.os-infographics-mobileTagLabel {
  color: #536064;
  display: block;
  font-size: 0.82rem;
  font-weight: 700;
  margin: 0 0 0.35rem;
}

.os-infographics-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
}

.os-infographics-tagArea {
  min-width: 0;
}

.os-infographics-tagButton,
.os-infographics-tagsToggle,
.os-infographics-iconAction,
.os-infographics-secondaryAction,
.os-infographics-closeButton,
.os-infographics-imageButton {
  appearance: none;
  border: 0;
  cursor: pointer;
  font: inherit;
}

.os-infographics-tagButton {
  background: #fff;
  border: 1px solid rgba(31, 42, 46, 0.15);
  border-radius: 999px;
  color: #374347;
  font-size: 0.92rem;
  min-height: 38px;
  padding: 0.45rem 0.9rem;
}

.os-infographics-tagsToggle {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  min-height: 38px;
  padding: 0.45rem 0.8rem;
  border: 0;
  background: transparent;
  color: #665370;
  cursor: pointer;
  font: inherit;
  font-size: 0.88rem;
  font-weight: 800;
}

.os-infographics-tagButtonActive {
  background: #24383d;
  border-color: #24383d;
  color: #fff;
}

.os-infographics-grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  margin: 0 auto;
  max-width: 1320px;
}

.os-infographics-card {
  background: #fff;
  border: 1px solid rgba(31, 42, 46, 0.12);
  border-radius: 16px;
  box-shadow: 0 14px 34px rgba(31, 42, 46, 0.09);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

@media (hover: hover) {
  .os-infographics-card:hover {
    border-color: rgba(98, 80, 109, 0.32);
    box-shadow: 0 18px 40px rgba(31, 42, 46, 0.13);
    transform: translateY(-2px);
  }
}

.os-infographics-imageButton {
  background: #eef1ef;
  display: block;
  padding: 0;
  width: 100%;
  overflow: hidden;
}

.os-infographics-preview {
  aspect-ratio: 4 / 4.65;
  display: block;
  height: auto;
  object-fit: cover;
  width: 100%;
  transition: transform 0.25s ease;
}

.os-infographics-imageButton:hover .os-infographics-preview {
  transform: scale(1.018);
}

.os-infographics-cardBody {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 0.75rem;
  padding: 1.1rem;
}

.os-infographics-cardMeta {
  color: #718083;
  display: flex;
  flex-wrap: wrap;
  font-size: 0.78rem;
  gap: 0.5rem;
}

.os-infographics-cardMeta span {
  background: #f2f0eb;
  border-radius: 999px;
  padding: 0.22rem 0.55rem;
}

.os-infographics-cardTitle {
  color: #1f2a2e;
  font-size: 1.18rem;
  line-height: 1.35;
  margin: 0;
}

.os-infographics-cardDescription {
  color: #536064;
  font-size: 0.95rem;
  line-height: 1.65;
  margin: 0;
}

.os-infographics-cardActions,
.os-infographics-modalActions {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  margin-top: auto;
}

.os-infographics-primaryAction,
.os-infographics-secondaryAction,
.os-infographics-iconAction {
  align-items: center;
  border-radius: 10px;
  display: inline-flex;
  font-weight: 700;
  gap: 0.45rem;
  justify-content: center;
  min-height: 40px;
  text-decoration: none;
}

.os-infographics-primaryAction {
  background: #1f4f46;
  color: #fff;
  padding: 0.55rem 0.85rem;
}

.os-infographics-primaryAction:hover {
  color: #fff;
  text-decoration: none;
}

.os-infographics-secondaryAction {
  background: #eef1ef;
  color: #1f2a2e;
  padding: 0.55rem 0.85rem;
}

.os-infographics-iconAction {
  background: #eef1ef;
  color: #1f2a2e;
  width: 40px;
}

.os-infographics-copiedText {
  color: #1f4f46;
  font-size: 0.88rem;
  font-weight: 700;
  margin: 0;
}

.os-infographics-emptyState {
  align-items: center;
  background: #fff;
  border: 1px dashed rgba(31, 42, 46, 0.25);
  border-radius: 8px;
  color: #536064;
  display: flex;
  flex-direction: column;
  margin: 2rem auto 0;
  max-width: 760px;
  padding: 4rem 1.5rem;
  text-align: center;
}

.os-infographics-emptyState h2 {
  color: #1f2a2e;
  font-size: 1.45rem;
  margin: 1rem 0 0.5rem;
}

.os-infographics-emptyState p {
  line-height: 1.75;
  margin: 0;
  max-width: 560px;
}

.os-infographics-modal {
  inset: 0;
  position: fixed;
  z-index: 1000;
}

.os-infographics-modalBackdrop {
  background: rgba(18, 24, 27, 0.76);
  inset: 0;
  position: absolute;
}

.os-infographics-modalPanel {
  background: #fff;
  border-radius: 8px;
  display: grid;
  gap: 0;
  grid-template-columns: minmax(0, 1fr) minmax(300px, 420px);
  height: min(88dvh, 920px);
  left: 50%;
  max-height: min(88vh, 920px);
  max-width: min(1120px, calc(100vw - 2rem));
  overflow: hidden;
  position: absolute;
  top: 50%;
  transform: translate(-50%, -50%);
  width: 100%;
}

.os-infographics-closeButton {
  align-items: center;
  background: rgba(255, 255, 255, 0.92);
  border-radius: 999px;
  color: #1f2a2e;
  display: inline-flex;
  height: 42px;
  justify-content: center;
  position: absolute;
  right: 0.8rem;
  top: 0.8rem;
  width: 42px;
  z-index: 2;
}

.os-infographics-modalImageWrap {
  align-items: center;
  background: #eef1ef;
  display: flex;
  justify-content: center;
  min-height: 0;
  max-height: 100%;
  overflow: auto;
  padding: 1rem;
}

.os-infographics-modalImage {
  display: block;
  height: auto;
  max-height: calc(88vh - 2rem);
  max-width: 100%;
  object-fit: contain;
}

.os-infographics-modalInfo {
  color: #536064;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  min-height: 0;
  overscroll-behavior: contain;
  overflow-y: auto;
  padding: 2rem 2rem 2.25rem;
}

.os-infographics-modalTopic {
  color: #87622e;
  font-size: 0.85rem;
  font-weight: 700;
  margin: 0;
}

.os-infographics-modalTitle {
  color: #1f2a2e;
  font-size: 1.65rem;
  line-height: 1.3;
  margin: 0;
}

.os-infographics-modalDescription {
  line-height: 1.75;
  margin: 0;
}

.os-infographics-modalReuse {
  background: #eef7f2;
  border-left: 4px solid #1f4f46;
  color: #1f4f46;
  font-weight: 700;
  margin: 0;
  padding: 0.75rem 0.9rem;
}

.os-infographics-modalTags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.os-infographics-modalTags span {
  background: #f2f0eb;
  border-radius: 999px;
  color: #374347;
  font-size: 0.85rem;
  padding: 0.25rem 0.6rem;
}

.os-infographics-relatedLinks {
  border-top: 1px solid rgba(31, 42, 46, 0.12);
  display: grid;
  gap: 0.5rem;
  margin-top: 0.35rem;
  padding-top: 1rem;
}

.os-infographics-relatedLinks h3 {
  color: #1f2a2e;
  font-size: 1rem;
  margin: 0;
}

.os-infographics-relatedLinks a {
  align-items: center;
  display: inline-flex;
  gap: 0.4rem;
  overflow-wrap: anywhere;
}

@media (max-width: 860px) {
  .os-infographics-header,
  .os-infographics-toolbar,
  .os-infographics-modalPanel {
    grid-template-columns: 1fr;
  }

  .os-infographics-reuseNotice {
    white-space: normal;
  }

  .os-infographics-header {
    gap: 1.5rem;
  }

  .os-infographics-headerPanel {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .os-infographics-headerPanel > div {
    align-items: center;
    flex-direction: column;
    justify-content: center;
    border-right: 1px solid rgba(255, 255, 255, 0.09);
    border-bottom: 0;
    text-align: center;
  }

  .os-infographics-headerPanel > div:last-child {
    border-right: 0;
  }

  .os-infographics-modalPanel {
    display: flex;
    flex-direction: column;
    height: calc(100dvh - 1rem);
    max-height: calc(100vh - 1rem);
  }

  .os-infographics-modalImageWrap {
    flex: 0 0 auto;
    max-height: 44dvh;
  }

  .os-infographics-modalImage {
    max-height: 42dvh;
  }

  .os-infographics-modalInfo {
    flex: 1 1 auto;
    min-height: 0;
    padding: 1.25rem 1.25rem 1.75rem;
  }
}

@media (max-width: 520px) {
  .os-infographics-page {
    padding: 1.25rem 0.85rem 3rem;
  }

  .os-infographics-header {
    gap: 1rem;
    padding: 1.25rem;
    border-radius: 20px;
  }

  .os-infographics-title {
    font-size: 2.25rem;
  }

  .os-infographics-headerPanel {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .os-infographics-headerPanel > div {
    min-height: 58px;
  }

  .os-infographics-reuseNotice {
    grid-column: 1 / -1;
    flex-direction: row !important;
  }

  .os-infographics-toolbar {
    gap: 0.8rem;
  }

  .os-infographics-grid {
    grid-template-columns: 1fr;
  }

  .os-infographics-primaryAction,
  .os-infographics-secondaryAction {
    width: 100%;
  }
}

@media (max-width: 700px) {
  .os-infographics-toolbar {
    grid-template-columns: 1fr;
  }

  .os-infographics-mobileTagFilter {
    display: block;
  }

  .os-infographics-tags,
  .os-infographics-modalTags {
    display: none;
  }

  .os-infographics-cardMeta span:last-child {
    display: none;
  }
}

[data-theme='dark'] .os-infographics-page {
  background:
    linear-gradient(180deg, rgba(16, 14, 18, 0.98), rgba(22, 18, 25, 0.98)),
    var(--ifm-background-color);
}

[data-theme='dark'] .os-infographics-toolbar,
[data-theme='dark'] .os-infographics-card,
[data-theme='dark'] .os-infographics-emptyState,
[data-theme='dark'] .os-infographics-modalPanel {
  border-color: rgba(255, 255, 255, 0.1);
  background: #211c25;
}

[data-theme='dark'] .os-infographics-searchBox,
[data-theme='dark'] .os-infographics-tagButton,
[data-theme='dark'] .os-infographics-mobileTagFilter select {
  border-color: rgba(255, 255, 255, 0.12);
  background-color: #18151b;
  color: rgba(255, 255, 255, 0.82);
}

[data-theme='dark'] .os-infographics-tagButtonActive {
  border-color: #e8c85e;
  background: #e8c85e;
  color: #17131d;
}

[data-theme='dark'] .os-infographics-searchBox input,
[data-theme='dark'] .os-infographics-cardTitle,
[data-theme='dark'] .os-infographics-modalTitle,
[data-theme='dark'] .os-infographics-relatedLinks h3 {
  color: #fffaf0;
}

[data-theme='dark'] .os-infographics-cardDescription,
[data-theme='dark'] .os-infographics-modalInfo,
[data-theme='dark'] .os-infographics-resultCount {
  color: rgba(255, 255, 255, 0.65);
}

[data-theme='dark'] .os-infographics-cardMeta span,
[data-theme='dark'] .os-infographics-modalTags span,
[data-theme='dark'] .os-infographics-secondaryAction,
[data-theme='dark'] .os-infographics-iconAction {
  background: rgba(255, 255, 255, 0.07);
  color: rgba(255, 255, 255, 0.8);
}

@media (prefers-reduced-motion: reduce) {
  .os-infographics-card,
  .os-infographics-preview {
    transition: none;
  }

  .os-infographics-card:hover,
  .os-infographics-imageButton:hover .os-infographics-preview {
    transform: none;
  }
}
