body[data-page="character-studio"] {
  background: #08090c;
}

.character-studio-page {
  --studio-page: #08090c;
  --studio-surface: #131419;
  --studio-line: rgba(255, 255, 255, 0.09);
  --studio-line-strong: rgba(255, 255, 255, 0.14);
  --studio-text: #f3f2f1;
  --studio-muted: #96969f;
  --studio-faint: #62636c;
  --studio-accent: #df416c;
  --studio-success: #63d2a5;
  min-height: 100svh;
  padding: 92px 12px 12px;
  overflow: hidden;
  background: var(--studio-page);
  color: var(--studio-text);
  font-family: Inter, "Segoe UI", Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}

.character-studio-page button {
  color: inherit;
  font: inherit;
  -webkit-tap-highlight-color: transparent;
}

.character-studio-page button:focus-visible {
  outline: 2px solid #ff7b9f;
  outline-offset: 3px;
}

.studio-shell {
  position: relative;
  display: flex;
  min-height: calc(100svh - 104px);
  flex-direction: column;
  overflow: hidden;
  border: 1px solid var(--studio-line);
  border-radius: 28px;
  background:
    radial-gradient(circle at 83% 18%, rgba(75, 28, 52, 0.09), transparent 34rem),
    linear-gradient(90deg, #14151a 0%, #121318 57%, #110f15 100%);
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.42);
}

.studio-header {
  position: relative;
  z-index: 20;
  display: flex;
  min-height: 86px;
  align-items: center;
  justify-content: space-between;
  padding: 0 33px;
}

.studio-brand {
  display: inline-flex;
  width: fit-content;
  align-items: center;
  gap: 13px;
}

.studio-logo {
  display: flex;
  width: 38px;
  height: 38px;
  align-items: center;
  justify-content: center;
  gap: 3px;
  border: 1px solid var(--studio-line);
  border-radius: 11px;
  background: rgba(255, 255, 255, 0.05);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.studio-logo span {
  width: 3px;
  border-radius: 999px;
  background: var(--studio-accent);
}

.studio-logo span:nth-child(1) { height: 10px; opacity: 0.65; }
.studio-logo span:nth-child(2) { height: 21px; }
.studio-logo span:nth-child(3) { height: 15px; opacity: 0.8; }

.studio-brand-copy strong,
.studio-brand-copy small,
.studio-motion-kicker,
.studio-motion-title {
  display: block;
}

.studio-brand-copy strong {
  font-size: 14px;
  font-weight: 650;
  letter-spacing: -0.025em;
}

.studio-brand-copy small {
  margin-top: 3px;
  color: #74747d;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.16em;
}

.studio-service-status {
  display: inline-flex;
  min-height: 38px;
  align-items: center;
  gap: 9px;
  padding: 0 14px;
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 999px;
  background: rgba(7, 8, 12, 0.54);
  color: #aaaab2;
  font-size: 11px;
}

.studio-service-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--studio-success);
  box-shadow: 0 0 0 4px rgba(99, 210, 165, 0.09);
}

.studio-workspace {
  position: relative;
  z-index: 1;
  min-height: 0;
  flex: 1;
}

.studio-character-stage {
  position: absolute;
  z-index: 1;
  inset: 0;
  overflow: hidden;
}

.studio-character-viewport {
  position: absolute;
  inset: 0;
  cursor: grab;
  touch-action: none;
}

.studio-character-viewport.is-dragging { cursor: grabbing; }

.studio-character-viewport canvas {
  position: absolute;
  z-index: 1;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
}

.studio-viewport-loader {
  position: absolute;
  z-index: 3;
  top: 50%;
  left: 50%;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--studio-muted);
  font-size: 11px;
  letter-spacing: 0.08em;
  transform: translate(-50%, -50%);
}

.studio-viewport-loader::before {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--studio-accent);
  content: "";
  animation: studio-loader-pulse 1.2s ease-in-out infinite;
}

.studio-viewport-loader.is-error {
  max-width: 280px;
  color: #d8a5b4;
  line-height: 1.5;
  text-align: center;
}

.studio-hero-column {
  position: absolute;
  z-index: 5;
  inset: 0 auto 0 0;
  width: 520px;
  padding: 56px 0 54px 74px;
  pointer-events: none;
}

.studio-hero-copy { max-width: 390px; }

.studio-eyebrow {
  margin: 0 0 29px;
  color: #ec547c;
  font-size: 10px;
  font-weight: 750;
  letter-spacing: 0.23em;
  line-height: 1.2;
}

.studio-hero-title {
  max-width: 390px;
  margin: 0;
  color: var(--studio-text);
  font-family: Inter, "Segoe UI", Arial, sans-serif;
  font-size: clamp(72px, 6.1vw, 88px);
  font-weight: 470;
  letter-spacing: -0.072em;
  line-height: 0.88;
  text-transform: none;
  transform: none;
  text-shadow: none;
}

.studio-hero-title span { display: block; }

.studio-hero-description {
  max-width: 365px;
  margin: 25px 0 0;
  color: var(--studio-muted);
  font-size: 13px;
  line-height: 1.65;
}

.studio-motion-column {
  position: absolute;
  z-index: 6;
  inset: 0;
  display: flex;
  align-items: flex-end;
  justify-content: flex-end;
  padding: 0 58px 55px 10px;
  pointer-events: none;
}

.studio-motion-card {
  width: 268px;
  overflow: hidden;
  border: 1px solid var(--studio-line-strong);
  border-radius: 20px;
  background: rgba(11, 12, 17, 0.88);
  box-shadow: 0 22px 70px rgba(0, 0, 0, 0.28);
  backdrop-filter: blur(20px);
  pointer-events: auto;
}

.studio-motion-head {
  display: flex;
  min-height: 86px;
  align-items: center;
  justify-content: space-between;
  padding: 18px 18px 16px 20px;
}

.studio-motion-kicker {
  color: var(--studio-faint);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.12em;
}

.studio-motion-title {
  margin-top: 6px;
  font-size: 21px;
  font-weight: 560;
  letter-spacing: -0.04em;
}

.studio-pause-button {
  position: relative;
  display: grid;
  width: 40px;
  height: 40px;
  place-items: center;
  border: 1px solid var(--studio-line-strong);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.025);
  cursor: pointer;
}

.studio-pause-icon,
.studio-play-icon {
  display: block;
  width: 12px;
  height: 12px;
}

.studio-pause-icon {
  background: linear-gradient(90deg, #bbb 0 25%, transparent 25% 70%, #bbb 70% 95%, transparent 95%);
}

.studio-play-icon {
  width: 0;
  height: 0;
  margin-left: 2px;
  border-top: 6px solid transparent;
  border-bottom: 6px solid transparent;
  border-left: 9px solid #bbb;
}

.studio-motion-list { border-top: 1px solid var(--studio-line); }

.studio-motion-item {
  display: grid;
  width: 100%;
  min-height: 44px;
  grid-template-columns: 30px 1fr 24px;
  align-items: center;
  padding: 0 16px 0 20px;
  border: 0;
  border-bottom: 1px solid var(--studio-line);
  background: transparent;
  color: #70717b;
  cursor: pointer;
  text-align: left;
  transition: color 160ms ease, background 160ms ease;
}

.studio-motion-item:hover { color: #c8c6c8; }
.studio-motion-item.is-active { background: rgba(223, 65, 108, 0.13); color: var(--studio-text); }
.studio-motion-index { color: #565761; font-size: 8px; }
.studio-motion-name { font-size: 11px; font-weight: 600; }

.studio-equalizer {
  display: flex;
  height: 14px;
  align-items: flex-end;
  justify-content: flex-end;
  gap: 2px;
  opacity: 0;
}

.studio-motion-item.is-active .studio-equalizer { opacity: 1; }

.studio-equalizer i {
  display: block;
  width: 2px;
  border-radius: 2px;
  background: var(--studio-accent);
  animation: studio-equalize 0.7s ease-in-out infinite alternate;
}

.studio-equalizer i:nth-child(1) { height: 6px; }
.studio-equalizer i:nth-child(2) { height: 12px; animation-delay: -0.3s; }
.studio-equalizer i:nth-child(3) { height: 8px; animation-delay: -0.5s; }
.studio-motion-card.is-paused .studio-equalizer i { animation-play-state: paused; }

.studio-motion-footer {
  display: flex;
  min-height: 38px;
  align-items: center;
  justify-content: space-between;
  padding: 0 14px;
  color: #555660;
  font-size: 7px;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.studio-stage-caption {
  position: absolute;
  z-index: 5;
  bottom: 32px;
  left: 74px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #62636d;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.studio-mouse-symbol {
  position: relative;
  width: 14px;
  height: 20px;
  border: 1px solid #6a6b74;
  border-radius: 8px;
}

.studio-mouse-symbol::after {
  position: absolute;
  top: 4px;
  left: 50%;
  width: 2px;
  height: 4px;
  border-radius: 2px;
  background: var(--studio-accent);
  content: "";
  transform: translateX(-50%);
}

@keyframes studio-equalize { to { height: 4px; } }
@keyframes studio-loader-pulse { 50% { opacity: 0.4; transform: scale(0.72); } }

@media (max-width: 1120px) {
  .studio-hero-column { width: 440px; padding-left: 42px; }
  .studio-hero-title { font-size: clamp(62px, 7vw, 76px); }
  .studio-motion-column { padding-right: 28px; }
  .studio-stage-caption { left: 42px; }
}

@media (max-width: 880px) {
  .character-studio-page { overflow: visible; }
  .studio-shell { min-height: calc(100svh - 104px); overflow: visible; }
  .studio-header { min-height: 76px; padding: 0 20px; }
  .studio-service-status { padding: 0 11px; }
  .studio-workspace { display: flex; min-height: calc(100svh - 180px); flex-direction: column; }
  .studio-hero-column { position: relative; inset: auto; width: auto; padding: 46px 24px 6px; }
  .studio-hero-copy { max-width: none; }
  .studio-eyebrow { margin-bottom: 20px; }
  .studio-hero-title { max-width: 520px; font-size: clamp(52px, 15vw, 76px); }
  .studio-hero-description { max-width: 440px; margin-top: 20px; }
  .studio-desktop-break { display: none; }
  .studio-character-stage { position: relative; inset: auto; height: 58svh; min-height: 430px; }
  .studio-motion-column { position: relative; inset: auto; padding: 0 16px 24px; }
  .studio-motion-card { width: 100%; }
  .studio-motion-list { display: grid; grid-template-columns: repeat(4, 1fr); }
  .studio-motion-item {
    min-height: 56px;
    grid-template-columns: auto 1fr;
    gap: 8px;
    padding: 0 12px;
    border-right: 1px solid var(--studio-line);
  }
  .studio-motion-item:last-child { border-right: 0; }
  .studio-equalizer,
  .studio-motion-footer,
  .studio-stage-caption { display: none; }
}

@media (max-width: 760px) {
  .character-studio-page { min-height: auto; padding: 12px 0 0; }
  .studio-shell { min-height: 100svh; border-right: 0; border-left: 0; border-radius: 0; }
}

@media (max-width: 540px) {
  .studio-brand-copy small { display: none; }
  .studio-service-status [data-motion-status-text] { font-size: 0; }
  .studio-service-status [data-motion-status-text]::after {
    color: var(--studio-success);
    content: "Active";
    font-size: 10px;
  }
  .studio-hero-column { padding-top: 32px; }
  .studio-character-stage { height: 52svh; min-height: 390px; }
  .studio-motion-head { min-height: 72px; }
  .studio-motion-item {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 4px;
    text-align: center;
  }
}

@media (prefers-reduced-motion: reduce) {
  .character-studio-page *,
  .character-studio-page *::before,
  .character-studio-page *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
