/* Expertise interiors v4: backlog + Audience Pulse.
 * These styles own only the moving artwork inside the two fixed .visual frames.
 * The surrounding cards and paired scroll stack remain untouched. */

.hvo-x4b,
.hvo-x4p,
.hvo-x4b *,
.hvo-x4p * {
  box-sizing: border-box;
}

.hvo-x4b,
.hvo-x4p {
  --x4-lime: #d6fd70;
  --x4-on-lime: #171917;
  --x4-ink: #171917;
  --x4-muted: #71746f;
  --x4-line: rgba(23, 25, 23, 0.09);
  --x4-surface: #ffffff;
  --x4-row: #f2f3ef;
  position: relative;
  display: grid;
  width: 25rem;
  height: 24rem;
  flex: none;
  place-items: center;
  overflow: hidden;
  border-radius: 0.75rem;
  background: #fff;
  color: var(--x4-ink);
  font-family: "Plus Jakarta Sans", Arial, sans-serif;
  isolation: isolate;
}

.hvo-x4b-frame,
.hvo-x4p-frame {
  position: relative;
  width: 22.5rem;
  height: 21.25rem;
  overflow: hidden;
  padding: 1.125rem;
  border: 0;
  border-radius: 1.05rem;
  background: transparent;
  transform: translateZ(0);
}

/* -------------------------------------------------------------------------- */
/* Backlog: the selected thumbnails themselves become the three queue items.   */
/* -------------------------------------------------------------------------- */

.hvo-x4b-header {
  display: flex;
  height: 2.25rem;
  align-items: center;
}

.hvo-x4b-avatar {
  display: block;
  width: 2.25rem;
  height: 2.25rem;
  flex: none;
  border-radius: 50%;
  object-fit: cover;
}

.hvo-x4b-identity {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
  justify-content: center;
  padding-left: 0.62rem;
}

.hvo-x4b-identity strong,
.hvo-x4b-identity span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.hvo-x4b-identity strong {
  font-size: 0.76rem;
  font-weight: 650;
  letter-spacing: -0.018em;
  line-height: 1.1;
}

.hvo-x4b-identity span {
  margin-top: 0.25rem;
  color: var(--x4-muted);
  font-size: 0.61rem;
  line-height: 1;
}

.hvo-x4b-count {
  display: inline-grid;
  min-width: 4.75rem;
  height: 1.8rem;
  flex: none;
  place-items: center;
  border-radius: 999px;
  background: var(--x4-lime);
  color: var(--x4-on-lime);
  font-family: "Geist Mono", ui-monospace, monospace;
  font-size: 0.62rem;
  font-variant-numeric: tabular-nums;
  font-weight: 650;
  letter-spacing: -0.015em;
  line-height: 1;
}

.hvo-x4b.is-building .hvo-x4b-count {
  background: #171917;
  color: #fff;
}

.hvo-x4b-stage {
  position: relative;
  width: 100%;
  height: 15rem;
  margin-top: 1rem;
}

.hvo-x4b-row {
  position: absolute;
  z-index: 1;
  left: 0;
  display: grid;
  width: 100%;
  height: 4.45rem;
  margin: 0;
  grid-template-columns: 7rem minmax(0, 1fr) 1.35rem;
  align-items: center;
  gap: 0.7rem;
  padding: 0.34rem 0.55rem 0.34rem 0.34rem;
  border: 1px solid transparent;
  border-radius: 0.72rem;
  background: var(--x4-row);
}

.hvo-x4b-row:nth-of-type(1) {
  top: 0;
}
.hvo-x4b-row:nth-of-type(2) {
  top: 5.05rem;
}
.hvo-x4b-row:nth-of-type(3) {
  top: 10.1rem;
}

.hvo-x4b-copy {
  display: flex;
  min-width: 0;
  grid-column: 2;
  flex-direction: column;
  justify-content: center;
}

.hvo-x4b-copy strong {
  display: -webkit-box;
  overflow: hidden;
  font-size: 0.7rem;
  font-weight: 650;
  letter-spacing: -0.022em;
  line-height: 1.2;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.hvo-x4b-copy span {
  overflow: hidden;
  margin-top: 0.28rem;
  color: var(--x4-muted);
  font-family: "Geist Mono", ui-monospace, monospace;
  font-size: 0.55rem;
  font-variant-numeric: tabular-nums;
  line-height: 1;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.hvo-x4b-check {
  display: grid;
  width: 1.18rem;
  height: 1.18rem;
  grid-column: 3;
  place-items: center;
  border-radius: 50%;
  background: var(--x4-lime);
  color: var(--x4-on-lime);
  font-size: 0.62rem;
  font-style: normal;
  font-weight: 800;
  line-height: 1;
}

.hvo-x4b-thumb {
  position: absolute;
  z-index: 5;
  left: 0.34rem;
  width: 7rem;
  height: 3.94rem;
  overflow: hidden;
  margin: 0;
  border: 1px solid rgba(255, 255, 255, 0.68);
  border-radius: 0.52rem;
  background: #dedfd9;
  box-shadow: none;
  transform-origin: 50% 50%;
  will-change: transform, box-shadow;
}

.hvo-x4b-thumb:nth-of-type(1) {
  top: 0.255rem;
}
.hvo-x4b-thumb:nth-of-type(2) {
  top: 5.305rem;
}
.hvo-x4b-thumb:nth-of-type(3) {
  top: 10.355rem;
}

.hvo-x4b-thumb img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hvo-x4b-thumb > span {
  position: absolute;
  right: 0.24rem;
  bottom: 0.22rem;
  padding: 0.16rem 0.22rem;
  border-radius: 0.2rem;
  background: rgba(16, 17, 15, 0.78);
  color: #fff;
  font-family: "Geist Mono", ui-monospace, monospace;
  font-size: 0.48rem;
  font-variant-numeric: tabular-nums;
  line-height: 1;
}

.hvo-x4b-magnet {
  position: absolute;
  z-index: 0;
  top: 4.2rem;
  left: 8.3rem;
  width: 8rem;
  height: 8rem;
  border: 1px solid rgba(23, 25, 23, 0.12);
  border-radius: 50%;
  opacity: 0;
  pointer-events: none;
}

.hvo-x4b-magnet::before,
.hvo-x4b-magnet::after {
  content: "";
  position: absolute;
  border: 1px solid rgba(23, 25, 23, 0.08);
  border-radius: inherit;
  inset: 0.72rem;
}

.hvo-x4b-magnet::after {
  inset: 1.55rem;
}

/* -------------------------------------------------------------------------- */
/* Audience Pulse: a single source comment and a translation lens.             */
/* -------------------------------------------------------------------------- */

.hvo-x4p-frame {
  display: flex;
  flex-direction: column;
  background: transparent;
}

.hvo-x4p-header {
  display: grid;
  height: 2.35rem;
  grid-template-columns: 2.35rem minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.62rem;
}

.hvo-x4p-language {
  display: grid;
  width: 2.35rem;
  height: 2.35rem;
  place-items: center;
  border: 1px solid var(--x4-line);
  border-radius: 50%;
  background: var(--x4-surface);
  font-family: "Geist Mono", ui-monospace, monospace;
  font-size: 0.64rem;
  font-weight: 700;
  letter-spacing: 0.035em;
}

.hvo-x4p-author {
  display: flex;
  min-width: 0;
  flex-direction: column;
}

.hvo-x4p-author strong {
  overflow: hidden;
  font-family:
    -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Noto Sans KR",
    sans-serif;
  font-size: 0.72rem;
  font-weight: 650;
  line-height: 1.1;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.hvo-x4p-author span {
  margin-top: 0.24rem;
  color: var(--x4-muted);
  font-size: 0.59rem;
  line-height: 1;
}

.hvo-x4p-likes {
  display: inline-flex;
  align-items: center;
  gap: 0.28rem;
  color: var(--x4-ink);
  font-family: "Geist Mono", ui-monospace, monospace;
  font-size: 0.61rem;
  font-variant-numeric: tabular-nums;
  font-weight: 650;
  white-space: nowrap;
}

.hvo-x4p-likes svg {
  width: 0.82rem;
  height: 0.82rem;
  color: var(--x4-ink);
  fill: none;
  stroke: currentColor;
  stroke-linejoin: round;
  stroke-width: 1.35;
}

.hvo-x4p-likes svg path {
  fill: none;
}

.hvo-x4p-comment {
  position: relative;
  display: flex;
  flex: 1;
  flex-direction: column;
  justify-content: center;
  margin-top: 1.15rem;
}

.hvo-x4p-korean {
  margin: 0;
  color: var(--x4-ink);
  font-family:
    -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Noto Sans KR",
    sans-serif;
  font-size: 1rem;
  font-weight: 540;
  letter-spacing: -0.018em;
  line-height: 1.48;
  text-wrap: pretty;
}

.hvo-x4p-divider {
  position: relative;
  height: 1px;
  margin: 0.9rem 0 0.78rem;
  overflow: visible;
  background: var(--x4-line);
}

.hvo-x4p-divider span {
  position: absolute;
  top: -0.2rem;
  left: 0;
  width: 0.42rem;
  height: 0.42rem;
  border-radius: 50%;
  background: var(--x4-ink);
}

.hvo-x4p-translation-window {
  position: relative;
  min-height: 5.2rem;
  overflow: visible;
}

.hvo-x4p-translation {
  position: relative;
  z-index: 1;
}

.hvo-x4p-translation-label {
  display: block;
  color: var(--x4-muted);
  font-family: "Geist Mono", ui-monospace, monospace;
  font-size: 0.6rem;
  font-weight: 650;
  letter-spacing: 0.065em;
  line-height: 1;
  text-transform: uppercase;
}

.hvo-x4p-translation p {
  margin: 0.46rem 0 0;
  color: var(--x4-ink);
  font-size: 0.85rem;
  font-weight: 520;
  letter-spacing: -0.014em;
  line-height: 1.43;
  text-wrap: pretty;
}

.hvo-x4p-lens {
  position: absolute;
  z-index: 3;
  top: 0;
  bottom: 0;
  left: 0;
  width: 1px;
  background: var(--x4-ink);
  opacity: 0;
  pointer-events: none;
  will-change: transform;
}

.hvo-x4p-lens::before {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  width: 2.8rem;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.7));
}

.hvo-x4p-lens i {
  position: absolute;
  top: 0;
  left: 50%;
  display: grid;
  width: 1.4rem;
  height: 1.15rem;
  place-items: center;
  border-radius: 999px;
  background: var(--x4-ink);
  color: #fff;
  font-family: "Geist Mono", ui-monospace, monospace;
  font-size: 0.48rem;
  font-style: normal;
  font-weight: 700;
  line-height: 1;
  transform: translate(-50%, -0.2rem);
}

.hvo-x4p-lock {
  display: inline-flex;
  width: max-content;
  height: 1.72rem;
  flex: none;
  align-items: center;
  gap: 0.43rem;
  padding: 0 0.72rem;
  border-radius: 999px;
  background: var(--x4-lime);
  color: var(--x4-on-lime);
  font-family: "Geist Mono", ui-monospace, monospace;
  font-size: 0.57rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  line-height: 1;
}

.hvo-x4p-lock i {
  width: 0.42rem;
  height: 0.42rem;
  border-radius: 50%;
  background: currentColor;
}

html[data-theme="dark"] .hvo-x4b img {
  filter: none !important;
}

@media (max-width: 479px) {
  .hvo-x4b,
  .hvo-x4p {
    width: 15rem;
    height: 15rem;
  }

  .hvo-x4b-frame,
  .hvo-x4p-frame {
    width: 14.5rem;
    height: 14.5rem;
    padding: 0.72rem;
    border-radius: 0.9rem;
  }

  .hvo-x4b-header {
    height: 1.72rem;
  }

  .hvo-x4b-avatar {
    width: 1.72rem;
    height: 1.72rem;
  }

  .hvo-x4b-identity {
    padding-left: 0.45rem;
  }
  .hvo-x4b-identity strong {
    font-size: 0.66rem;
  }
  .hvo-x4b-identity span {
    display: none;
  }

  .hvo-x4b-count {
    min-width: 3.8rem;
    height: 1.42rem;
    font-size: 0.58rem;
  }

  .hvo-x4b-stage {
    height: 10.4rem;
    margin-top: 0.68rem;
  }

  .hvo-x4b-row {
    height: 3rem;
    grid-template-columns: 4.65rem minmax(0, 1fr) 0.92rem;
    gap: 0.42rem;
    padding: 0.22rem 0.34rem 0.22rem 0.22rem;
    border-radius: 0.5rem;
  }

  .hvo-x4b-row:nth-of-type(1) {
    top: 0;
  }
  .hvo-x4b-row:nth-of-type(2) {
    top: 3.45rem;
  }
  .hvo-x4b-row:nth-of-type(3) {
    top: 6.9rem;
  }

  .hvo-x4b-copy strong {
    font-size: 0.6rem;
    line-height: 1.16;
  }

  .hvo-x4b-copy span {
    display: none;
  }

  .hvo-x4b-check {
    width: 0.88rem;
    height: 0.88rem;
    font-size: 0.48rem;
  }

  .hvo-x4b-thumb {
    left: 0.22rem;
    width: 4.65rem;
    height: 2.62rem;
    border-radius: 0.38rem;
  }

  .hvo-x4b-thumb:nth-of-type(1) {
    top: 0.19rem;
  }
  .hvo-x4b-thumb:nth-of-type(2) {
    top: 3.64rem;
  }
  .hvo-x4b-thumb:nth-of-type(3) {
    top: 7.09rem;
  }

  .hvo-x4b-thumb > span {
    display: none;
  }

  .hvo-x4b-magnet {
    top: 2.5rem;
    left: 5rem;
    width: 5.4rem;
    height: 5.4rem;
  }

  .hvo-x4p-header {
    height: 1.78rem;
    grid-template-columns: 1.78rem minmax(0, 1fr) auto;
    gap: 0.42rem;
  }

  .hvo-x4p-language {
    width: 1.78rem;
    height: 1.78rem;
    font-size: 0.58rem;
  }

  .hvo-x4p-author strong {
    font-size: 0.62rem;
  }
  .hvo-x4p-author span {
    display: none;
  }

  .hvo-x4p-likes {
    gap: 0.19rem;
    font-size: 0.58rem;
  }

  .hvo-x4p-likes svg {
    width: 0.64rem;
    height: 0.64rem;
  }

  .hvo-x4p-comment {
    margin-top: 0.55rem;
  }

  .hvo-x4p-korean {
    font-size: 0.78rem;
    letter-spacing: -0.024em;
    line-height: 1.38;
  }

  .hvo-x4p-divider {
    margin: 0.48rem 0 0.45rem;
  }
  .hvo-x4p-divider span {
    top: -0.15rem;
    width: 0.32rem;
    height: 0.32rem;
  }

  .hvo-x4p-translation-window {
    min-height: 3.82rem;
  }
  .hvo-x4p-translation-label {
    font-size: 0.56rem;
  }

  .hvo-x4p-translation p {
    margin-top: 0.28rem;
    font-size: 0.72rem;
    line-height: 1.34;
  }

  .hvo-x4p-lens i {
    width: 1.1rem;
    height: 0.9rem;
    font-size: 0.38rem;
  }

  .hvo-x4p-lock {
    height: 1.28rem;
    gap: 0.32rem;
    padding: 0 0.52rem;
    font-size: 0.58rem;
  }

  .hvo-x4p-lock i {
    width: 0.32rem;
    height: 0.32rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hvo-x4b-thumb,
  .hvo-x4p-lens {
    will-change: auto;
  }
}
