body.graphic-page {
  background-color: var(--background-color);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  height: 100%;
  padding-left: var(--body-padding-sides);
  padding-right: var(--body-padding-sides)}

.graphic-page-wrap {
  flex: 1 1 auto;
  min-height: 0;
  height: 100%;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  justify-content: center}

.graphic-detail {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: auto minmax(0, 1fr);
  gap: clamp(0.8rem, 1.6vw, 1.2rem);
  min-height: 0;
  height: 100%;
  align-items: start;
  /* graphic-stage가 아닌 여기에 패딩 → overflow:hidden 체인 밖이라 이미지 안짤림 */
  padding-bottom: var(--space-16)}

.graphic-sidebar {
  position: relative;
  display: grid;
  align-items: center;
  gap: clamp(0.6rem, 1.2vw, 1rem);
  min-width: 0;
  overflow: hidden;
  padding-bottom: var(--space-8)}

.graphic-sidebar__back,
.graphic-sidebar__copy {
  min-width: 0}

.graphic-sidebar__back {
  grid-column: 1;
  display: flex;
  align-items: center;
  justify-self: start}

.graphic-sidebar__copy {
  grid-column: 2;
  display: flex;
  justify-content: center;
  width: 100%}

.graphic-sidebar::after {
  content: "";
  position: absolute;
  left: calc(var(--body-padding-sides) * -1);
  right: calc(var(--body-padding-sides) * -1);
  bottom: 0;
  border-bottom: var(--border)}

.graphic-copy {
  display: flex;
  flex-direction: row;
  align-items: baseline;
  justify-content: center;
  gap: clamp(0.5rem, 1vw, 0.9rem);
  min-width: 0;
  flex: 0 1 auto;
  overflow: hidden;
  text-align: center;
  max-width: min(100%, 60rem)}

.graphic-copy__structured {
  display: contents}

.graphic-copy__mobile {
  display: none}

.graphic-copy__ticker-track,
.graphic-copy__ticker-item {
  display: contents}

.graphic-copy__ticker-item--clone {
  display: none}

.graphic-hero__title {
  margin: 0;
  display: flex;
  flex-direction: row;
  align-items: baseline;
  justify-content: center;
  font-weight: 400;
  max-width: none;
  flex: 0 0 auto;
  white-space: nowrap}

.graphic-hero__title-main,
.graphic-hero__title-sub {
  display: block}

.graphic-hero__title-sub {
  color: rgba(17, 17, 17, 0.72)}

.graphic-copy__body {
  min-width: 0;
  flex: 0 1 30rem}

.graphic-copy__body-text {
  margin: 0;
  color: rgba(17, 17, 17, 0.72);
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis}

.graphic-copy__body-text + .graphic-copy__body-text {
  margin-top: 0.2rem}

.graphic-hero__title-main .eng,
.graphic-hero__title-sub .eng,
.graphic-copy__body-text.eng {
  display: none}

body.eng .graphic-hero__title-main .kr,
body.eng .graphic-hero__title-sub .kr,
body.eng .graphic-copy__body-text.kr {
  display: none}

body.eng .graphic-hero__title-main .eng,
body.eng .graphic-hero__title-sub .eng,
body.eng .graphic-copy__body-text.eng {
  display: block}

.graphic-meta-list {
  display: flex;
  flex: 0 0 auto;
  flex-wrap: nowrap;
  justify-content: center;
  gap: 0.18rem 0.72rem;
  min-width: 0;
  align-items: baseline;
  margin: 0;
  max-width: none;
  white-space: nowrap}

.graphic-meta-value {
  min-width: 0;
  color: var(--text-color)}

.graphic-meta-value--demo {
  font-style: italic}

.graphic-page-nav {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  width: fit-content;
  max-width: none;
  margin: 0;
  order: -1}

.graphic-page-nav__back {
  display: inline-flex;
  align-items: center;
  gap: 0.26rem;
  width: fit-content;
  color: var(--color-gray-dark);
  font-size: var(--font-size-small);
  font-family: var(--font-family-ui);
  font-weight: 600;
  text-decoration: none}

.graphic-page-nav__back:hover {
  opacity: 0.7}

.graphic-page-nav__arrow {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1rem;
  height: 1rem;
  color: var(--color-gray-dark);
  flex-shrink: 0}

.graphic-page-nav__arrow svg {
  width: 100%;
  height: 100%}

.graphic-stage-shell {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  min-width: 0;
  min-height: 0;
  height: 100%;
  overflow: hidden;
  container-type: size}

.graphic-stage {
  position: relative;
  display: flex;
  align-items: center;
  gap: clamp(0.85rem, 1.4vw, 1.35rem);
  width: 100%;
  height: 100%;
  min-width: 0;
  min-height: 0;
  padding-left: var(--graphic-stage-pad-start, 0px);
  padding-right: var(--graphic-stage-pad-end, 0px);
  padding-bottom: 0;
  box-sizing: border-box;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x proximity;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none}

.graphic-stage::-webkit-scrollbar {
  display: none}

.graphic-stage::before,
.graphic-stage::after {
  content: none}

.graphic-image-item {
  margin: 0;
  flex: 0 0 auto;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  scroll-snap-align: center}

.graphic-image-item img {
  display: block;
  width: auto;
  height: auto;
  max-height: 100cqh;
  max-width: none;
  object-fit: contain;
  user-select: none;
  -webkit-user-drag: none}

.graphic-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 1.75rem;
  height: 1.75rem;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.58);
  color: rgba(17, 17, 17, 0.84);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(5px);
  cursor: pointer;
  z-index: 3;
  transition: opacity 0.15s ease, transform 0.15s ease, background 0.15s ease}

.graphic-nav:hover {
  background: rgba(255, 255, 255, 0.76)}

.graphic-nav:active {
  transform: translateY(-50%) scale(0.97)}

.graphic-nav--prev {
  left: var(--space-16)}

.graphic-nav--next {
  right: var(--space-16)}

.graphic-nav svg {
  width: 0.82rem;
  height: 0.82rem}

.graphic-stage__counter-wrap {
  position: absolute;
  right: 0.15rem;
  bottom: max(0.45rem, 1.4vh);
  z-index: 3;
  pointer-events: none}

.graphic-nav-counter {
  display: inline-flex;
  align-items: center;
  min-height: var(--button-outline-min-height);
  padding: var(--button-outline-padding);
  border: var(--button-outline-border);
  background: var(--color-gray-light);
  color: var(--color-gray-dark);
  font-size: var(--font-size-ui);
  font-family: var(--font-family-ui)}

html[data-theme-mode="dark"] .graphic-copy__body-text {
  color: rgba(240, 240, 240, 0.72)}

@media only screen and (max-width: 1024px) {
  .graphic-copy {
    gap: 0.6rem}

  .graphic-meta-list {
    gap: 0.18rem 0.56rem;
  }
}

@keyframes graphic-copy-marquee {
  from {
    transform: translateX(0)}

  to {
    transform: translateX(-50%)}
}

@media only screen and (max-width: 768px) {
  body.graphic-page {
    display: flex;
    flex-direction: column;
    height: 100vh;
    height: 100dvh;
    overflow-y: auto;
    padding-left: var(--body-padding-sides);
    padding-right: var(--body-padding-sides);
    padding-bottom: max(0px, env(safe-area-inset-bottom, 0px));
    box-sizing: border-box}

  .graphic-page-wrap {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    flex-direction: column;
    justify-content: center}

  .graphic-detail {
    flex: 1 1 auto;
    min-height: 0;
    grid-template-rows: auto minmax(0, 1fr);
    gap: var(--space-8);
    padding-bottom: var(--space-16);
    align-items: stretch}

  .graphic-sidebar {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-items: center;
    gap: 0.7rem;
    width: 100%;
    min-width: 0;
    overflow: hidden}

  .graphic-sidebar__back {
    grid-column: 1}

  .graphic-sidebar__copy {
    grid-column: 2;
    justify-content: stretch}

  .graphic-sidebar::after {
    left: calc(var(--body-padding-sides) * -1);
    right: calc(var(--body-padding-sides) * -1)}

  .graphic-copy {
    display: block;
    grid-column: 2;
    justify-self: stretch;
    width: 100%;
    min-width: 0;
    overflow: hidden;
    text-align: left;
    max-width: none;
    min-width: 0}

  .graphic-copy__structured {
    display: none}

  .graphic-copy__mobile {
    display: block;
    width: 100%;
    overflow: hidden;
    white-space: nowrap}

  .graphic-copy__mobile-track {
    display: inline-flex;
    align-items: center;
    width: max-content;
    min-width: max-content;
    white-space: nowrap;
    animation: graphic-copy-marquee 22s linear infinite;
    will-change: transform}

  .graphic-copy__mobile-item {
    display: inline-flex;
    align-items: center;
    padding-right: 1.2rem;
    flex: 0 0 auto}

  .graphic-copy__mobile-text {
    display: inline;
    white-space: nowrap}

  .graphic-copy__mobile-text.eng {
    display: none}

  body.eng .graphic-copy__mobile-text.kr {
    display: none}

  body.eng .graphic-copy__mobile-text.eng {
    display: inline}

  .graphic-page-nav {
    grid-column: 1;
    justify-self: start;
    align-self: center;
    max-width: none;
    order: 0}

  .graphic-stage-shell {
    container-type: normal;
    width: 100%;
    min-width: 0;
    min-height: 0;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center}

  .graphic-stage {
    align-items: center;
    gap: 0.7rem;
    width: 100%;
    height: 100%;
    min-height: 0;
    padding-left: 0;
    padding-right: 0;
    scroll-snap-type: x mandatory}

  .graphic-stage::before,
  .graphic-stage::after {
    flex-basis: 0}

  .graphic-image-item {
    min-width: 100%;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center}

  /* 헤더 + 사이드바 한 줄·간격 제외 — 뷰포트 밖으로 넘치지 않게 */
  .graphic-image-item img {
    width: 100%;
    height: auto;
    max-width: 100%;
    max-height: calc(100vh - var(--header-height) - 9rem);
    max-height: calc(100dvh - var(--header-height) - 9rem);
    object-fit: contain}

  .graphic-nav {
    width: 1.65rem;
    height: 1.65rem}

  .graphic-nav--prev {
    left: var(--space-16)}

  .graphic-nav--next {
    right: var(--space-16)}

  .graphic-stage__counter-wrap {
    right: 0.35rem;
    bottom: 0.35rem}
}
