:root {
  color-scheme: light;
  --mint: #73dcc1;
  --mint-dark: #28b996;
  --ink: #12312b;
  --muted: #6b817b;
  --line: rgba(18, 49, 43, 0.12);
  --bg: #eefbf7;
  --panel: rgba(255, 255, 255, 0.92);
  --orange: #ff9658;
  --blue: #4a90e2;
  --danger: #ff6b6b;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: linear-gradient(180deg, #dbfff5 0%, #f6fffc 48%, #ffffff 100%);
  color: var(--ink);
}

button {
  border: 0;
  font: inherit;
  cursor: pointer;
}

.app-shell {
  width: min(100%, 480px);
  min-height: 100vh;
  margin: 0 auto;
  background: var(--bg);
  overflow: hidden;
}

.view {
  min-height: 100vh;
  padding: 18px;
}

.hidden {
  display: none !important;
}

.muted {
  color: var(--muted);
}

.kicker {
  display: inline-block;
  font-size: 13px;
  font-weight: 700;
  color: var(--mint-dark);
}

.primary-btn,
.secondary-btn,
.danger-btn {
  width: 100%;
  min-height: 48px;
  border-radius: 8px;
  font-weight: 800;
}

.primary-btn {
  color: #fff;
  background: var(--mint-dark);
  box-shadow: 0 12px 30px rgba(40, 185, 150, 0.24);
}

.primary-btn:disabled {
  color: rgba(255, 255, 255, 0.88);
  background: #607b73;
  box-shadow: none;
  cursor: wait;
}

.secondary-btn {
  color: var(--ink);
  background: #fff;
  border: 1px solid var(--line);
}

.danger-btn {
  color: #fff;
  background: var(--danger);
}

.text-btn,
.icon-btn,
.round-btn {
  color: var(--ink);
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid var(--line);
}

.text-btn {
  padding: 9px 13px;
  border-radius: 8px;
  font-weight: 700;
}

.text-btn.light {
  color: #fff;
  background: rgba(255, 255, 255, 0.18);
  border-color: rgba(255, 255, 255, 0.25);
}

.icon-btn,
.round-btn {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  font-size: 25px;
  line-height: 1;
}

.profile-avatar {
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding: 2px;
  background: #fff;
}

.profile-avatar img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  pointer-events: none;
}

.plan-switch {
  display: flex;
  gap: 8px;
  margin-top: 14px;
}

.plan-switch button {
  min-height: 30px;
  padding: 0 11px;
  border-radius: 999px;
  border: 1px solid #dceee9;
  color: #668078;
  background: #f7fcfa;
  font-size: 12px;
  font-weight: 800;
}

.plan-switch button.active {
  border-color: var(--mint-dark);
  color: #fff;
  background: var(--mint-dark);
}

.login-view {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding-top: 56px;
  text-align: center;
}

.login-coach {
  width: min(76vw, 310px);
  height: 360px;
  object-fit: contain;
}

.login-hero h1 {
  margin: -12px 0 8px;
  font-size: 32px;
}

.login-hero p {
  margin: 0;
  color: var(--muted);
}

.login-panel {
  padding: 22px 0 12px;
}

.prep-view {
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.prep-panel {
  width: min(100%, 440px);
  padding: 32px 24px;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.78);
  box-shadow: 0 18px 48px rgba(36, 145, 121, 0.14);
}

.prep-coach {
  width: min(50vw, 180px);
  height: 180px;
  object-fit: contain;
}

.prep-percent {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 78px;
  height: 40px;
  margin-top: 12px;
  border-radius: 999px;
  color: #fff;
  background: var(--mint-dark);
  font-weight: 900;
}

.prep-panel h2 {
  margin: 16px 0 8px;
  font-size: 27px;
}

.prep-panel p {
  min-height: 24px;
  margin: 0 0 22px;
  color: var(--muted);
  font-weight: 700;
}

.prep-track {
  width: 100%;
  height: 16px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(18, 49, 43, 0.1);
}

.prep-track span {
  display: block;
  width: 0%;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--mint-dark), var(--orange));
  box-shadow: 0 2px 12px rgba(45, 193, 159, 0.48);
  transition: width 240ms ease;
}

.prep-steps {
  display: flex;
  justify-content: space-between;
  margin-top: 10px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

#prepRetryBtn {
  margin-top: 22px;
}

.simple-topbar,
.home-nav,
.training-header,
.report-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.setup-view {
  position: relative;
  background: #f7fffc;
}

.setup-copy {
  padding: 42px 4px 14px;
}

.setup-copy h2 {
  margin: 8px 0 10px;
  font-size: 30px;
  line-height: 1.16;
}

.setup-copy p {
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
}

.setup-options {
  display: grid;
  gap: 12px;
  margin-top: 22px;
}

.setup-option {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.setup-option.active {
  border-color: var(--mint-dark);
  background: #e9fff8;
}

.setup-option strong {
  display: block;
  margin-bottom: 5px;
}

.setup-option small {
  color: var(--muted);
}

.radio-dot {
  width: 19px;
  height: 19px;
  flex: 0 0 19px;
  border: 2px solid #a7bdb7;
  border-radius: 50%;
}

.setup-option.active .radio-dot {
  border-color: var(--mint-dark);
  box-shadow: inset 0 0 0 4px #fff;
  background: var(--mint-dark);
}

.setup-progress {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin: 30px 0 84px;
}

.setup-progress span {
  height: 4px;
  border-radius: 999px;
  background: #d9eae5;
}

.setup-progress span.active {
  background: var(--mint-dark);
}

.bottom-action {
  position: fixed;
  right: max(18px, calc((100vw - 480px) / 2 + 18px));
  bottom: 18px;
  left: max(18px, calc((100vw - 480px) / 2 + 18px));
  width: auto;
  max-width: 444px;
}

.home-view {
  padding-bottom: 24px;
}

.home-nav strong {
  flex: 1;
  text-align: center;
  margin-right: 42px;
}

.coach-stage {
  position: relative;
  min-height: 390px;
  padding-top: 16px;
  text-align: center;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 11px;
  border-radius: 999px;
  background: #fff;
  color: var(--mint-dark);
  font-size: 13px;
  font-weight: 800;
}

.status-pill span {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--mint-dark);
}

.home-coach {
  display: block;
  width: min(72vw, 300px);
  height: 270px;
  object-fit: contain;
}

.home-coach-button {
  display: block;
  margin: 18px auto 0;
  padding: 0;
  border: 0;
  border-radius: 24px;
  background: transparent;
  cursor: pointer;
}

.home-coach-button:focus-visible {
  outline: 3px solid rgba(41, 190, 159, 0.55);
  outline-offset: 4px;
}

.coach-bubble {
  width: fit-content;
  max-width: 92%;
  margin: -16px auto 0;
  padding: 12px 14px;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 10px 28px rgba(18, 49, 43, 0.08);
  font-weight: 700;
  line-height: 1.45;
}

.coach-stage h2 {
  margin: 18px 0 5px;
  font-size: 26px;
}

.mode-list {
  display: grid;
  gap: 13px;
}

.mode-card {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  padding: 17px;
  border: 1px solid rgba(40, 185, 150, 0.24);
  border-radius: 8px;
  background: #fff;
}

.mode-card.secondary {
  border-color: rgba(255, 150, 88, 0.28);
}

.mode-card h3 {
  margin: 0 0 6px;
}

.mode-card p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.small-primary {
  align-self: start;
  min-width: 88px;
  height: 38px;
  border-radius: 8px;
  color: #fff;
  background: var(--mint-dark);
  font-weight: 800;
}

.small-primary.secondary {
  background: var(--orange);
}

.plan-lines {
  grid-column: 1 / -1;
  padding-top: 12px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 13px;
}

.demo-video-entry {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 14px 16px;
  border: 1px dashed rgba(37, 114, 102, 0.42);
  border-radius: 12px;
  color: #285d55;
  background: rgba(255, 255, 255, 0.56);
  text-align: left;
  cursor: pointer;
  transition: transform 160ms ease, background 160ms ease, border-color 160ms ease;
}

.demo-video-entry:hover {
  border-color: rgba(37, 114, 102, 0.72);
  background: #f8fffd;
  transform: translateY(-1px);
}

.demo-video-entry:focus-visible {
  outline: 3px solid rgba(41, 190, 159, 0.42);
  outline-offset: 3px;
}

.demo-video-play {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 50%;
  color: #fff;
  background: #356f65;
  font-size: 13px;
  padding-left: 2px;
}

.demo-video-copy {
  display: grid;
  gap: 3px;
}

.demo-video-copy strong {
  font-size: 14px;
  line-height: 1.35;
}

.demo-video-copy small {
  color: var(--muted);
  font-size: 12px;
}

.demo-video-arrow {
  color: #60867e;
  font-size: 25px;
  line-height: 1;
}

.training-view {
  padding: 0;
  background: #10201e;
  color: #fff;
}

.training-header {
  height: 66px;
  padding: 10px 14px;
  background: rgba(16, 32, 30, 0.96);
}

.training-header div {
  display: grid;
  gap: 4px;
  text-align: center;
}

.training-header span {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.72);
}

.training-header .timer {
  width: 58px;
  color: #fff;
  font-weight: 800;
  text-align: right;
}

.camera-section {
  position: relative;
  height: min(68vh, 660px);
  min-height: 430px;
  overflow: hidden;
  background: #000;
}

#cameraVideo,
#overlayCanvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

#cameraVideo {
  transform: scaleX(-1);
}

#overlayCanvas {
  pointer-events: none;
}

.body-guide {
  position: absolute;
  inset: 11% 13% 16%;
  border: 1px solid rgba(115, 220, 193, 0.44);
  border-radius: 120px 120px 26px 26px;
  pointer-events: none;
}

.corner {
  position: absolute;
  width: 28px;
  height: 28px;
  border-color: var(--mint);
  border-style: solid;
}

.tl { top: -1px; left: -1px; border-width: 3px 0 0 3px; }
.tr { top: -1px; right: -1px; border-width: 3px 3px 0 0; }
.bl { bottom: -1px; left: -1px; border-width: 0 0 3px 3px; }
.br { right: -1px; bottom: -1px; border-width: 0 3px 3px 0; }

.plan-intro,
.phase-overlay,
.count-overlay,
.rest-overlay,
.model-mask {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  width: min(88%, 360px);
  border-radius: 8px;
  background: rgba(6, 22, 20, 0.72);
  backdrop-filter: blur(10px);
  text-align: center;
}

.plan-intro {
  top: 18px;
  display: grid;
  gap: 6px;
  padding: 13px;
}

.plan-intro small {
  color: rgba(255, 255, 255, 0.75);
}

.phase-overlay,
.rest-overlay {
  top: 35%;
  display: grid;
  gap: 10px;
  padding: 18px;
}

.phase-overlay b,
.rest-overlay strong {
  font-size: 58px;
  line-height: 1;
}

.phase-overlay small,
.rest-overlay small {
  color: rgba(255, 255, 255, 0.74);
}

.count-overlay {
  top: 18px;
  right: 14px;
  left: auto;
  width: 138px;
  transform: none;
  padding: 12px;
}

.count-overlay strong {
  display: block;
  font-size: 56px;
  line-height: 1;
}

.count-overlay.is-preview {
  opacity: 0.7;
}

.training-side-coach {
  position: absolute;
  right: 18px;
  bottom: 78px;
  z-index: 5;
  width: clamp(96px, 23vw, 142px);
  max-height: 38%;
  object-fit: contain;
  object-position: bottom right;
  pointer-events: none;
  filter: drop-shadow(0 8px 10px rgba(5, 18, 16, 0.28));
}

.training-coach {
  position: absolute;
  right: 12px;
  bottom: 13px;
  left: 12px;
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 10px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.92);
  color: var(--ink);
}

.training-coach img {
  width: 42px;
  height: 42px;
  object-fit: contain;
}

.training-coach span {
  font-weight: 800;
}

.model-mask {
  top: 43%;
  display: grid;
  gap: 12px;
  padding: 18px 16px;
  color: #fff;
  font-weight: 800;
  text-align: left;
  background: rgba(4, 18, 16, 0.92);
  border: 1px solid rgba(115, 220, 193, 0.45);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.34);
}

.model-mask.is-preparing {
  width: min(94%, 430px);
  padding: 24px 20px;
  border-width: 2px;
}

.model-mask.is-ready {
  background: rgba(10, 72, 61, 0.94);
  border-color: rgba(115, 220, 193, 0.8);
}

.model-mask.is-error {
  background: rgba(92, 28, 34, 0.94);
  border-color: rgba(255, 107, 107, 0.7);
  text-align: center;
}

.model-mask.is-error strong {
  display: block;
  font-size: 20px;
}

.model-error-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.model-error-actions button {
  min-height: 42px;
  border-radius: 10px;
  color: #fff;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.28);
  font-weight: 900;
}

.model-error-actions #compatibilityModelBtn {
  color: #173a32;
  background: #73dcc1;
  border-color: #73dcc1;
}

.prep-status-head {
  display: grid;
  grid-template-columns: 34px 1fr;
  gap: 10px;
  align-items: center;
}

.prep-status-head strong {
  display: block;
  font-size: 22px;
  line-height: 1.25;
}

.prep-status-head small {
  display: block;
  margin-top: 4px;
  color: rgba(255, 255, 255, 0.72);
  font-size: 13px;
}

.prep-spinner {
  width: 28px;
  height: 28px;
  border: 3px solid rgba(255, 255, 255, 0.22);
  border-top-color: var(--mint);
  border-radius: 50%;
  animation: prepSpin 0.9s linear infinite;
}

.model-mask.is-ready .prep-spinner {
  animation: none;
  position: relative;
  border-color: var(--mint);
  background: rgba(115, 220, 193, 0.18);
}

.model-mask.is-ready .prep-spinner::after {
  position: absolute;
  top: 6px;
  left: 8px;
  width: 8px;
  height: 13px;
  border: solid #fff;
  border-width: 0 3px 3px 0;
  content: "";
  transform: rotate(45deg);
}

.prep-status-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.prep-status-item {
  min-height: 66px;
  padding: 12px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.prep-status-item b,
.prep-status-item span {
  display: block;
}

.prep-status-item b {
  margin-bottom: 4px;
  font-size: 18px;
}

.prep-status-item span {
  color: rgba(255, 255, 255, 0.68);
  font-size: 12px;
}

.prep-status-item.done {
  background: rgba(115, 220, 193, 0.18);
  border-color: rgba(115, 220, 193, 0.42);
}

.model-mask p {
  margin: 0;
  color: rgba(255, 255, 255, 0.72);
  font-size: 14px;
  line-height: 1.5;
}

.training-prep-progress {
  width: 100%;
  height: 14px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
}

.training-prep-progress span {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #73dcc1, #ff9a58);
  box-shadow: 0 2px 14px rgba(115, 220, 193, 0.7);
  transition: width 180ms ease;
}

.training-prep-progress-copy {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: rgba(255, 255, 255, 0.82);
  font-size: 13px;
}

.training-prep-progress-copy b {
  color: #fff;
  font-size: 20px;
}

.training-prep-progress-copy span {
  text-align: right;
}

@keyframes prepSpin {
  to {
    transform: rotate(360deg);
  }
}

.training-bottom {
  padding: 14px;
  background: #10201e;
}

.hint-box {
  display: grid;
  gap: 4px;
  min-height: 58px;
  padding: 12px 14px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.1);
}

.hint-box span {
  color: rgba(255, 255, 255, 0.72);
  font-size: 13px;
}

.control-row {
  display: grid;
  grid-template-columns: 1.35fr 0.85fr 0.85fr;
  gap: 10px;
  margin-top: 12px;
}

.voice-tip {
  min-height: 22px;
  margin-top: 10px;
  color: var(--mint);
  font-size: 13px;
  font-weight: 800;
  text-align: center;
}

.profile-view {
  padding: 0 0 34px;
  background: linear-gradient(180deg, #f3fffb 0%, #ffffff 100%);
}

.report-view {
  padding: 0 0 22px;
  background: #f4f4f4;
}

.report-header {
  height: 88px;
  padding: 28px 22px 14px;
  color: #fff;
  background: var(--mint);
}

.report-header strong {
  flex: 1;
  text-align: center;
  font-size: 16px;
}

.report-back {
  width: 42px;
  height: 42px;
  color: #fff;
  background: transparent;
  font-size: 38px;
  line-height: 1;
}

.report-menu {
  width: 78px;
  height: 36px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  background: rgba(18, 49, 43, 0.36);
  font-size: 20px;
  letter-spacing: 3px;
}

.report-title {
  padding: 28px 18px 12px;
}

.report-title h2 {
  margin: 0 0 10px;
  font-size: 28px;
}

.report-title p {
  margin: 0;
  color: #9a9a9a;
  font-weight: 800;
}

.overview-card,
.reward-card,
.history-card,
.trend-card,
.diagnostic-card {
  margin: 14px 18px 0;
  padding: 18px;
  border-radius: 14px;
  background: #fff;
}

.skin-showcase {
  margin-top: 14px;
  padding: 16px;
  border-radius: 8px;
  background: #fff;
}

.overview-card {
  color: #fff;
  background: var(--mint);
}

.overview-card h3,
.trend-card h3 {
  margin: 0 0 18px;
}

.overview-grid,
.stats-row {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px 18px;
  margin: 0;
}

.stats-row article {
  display: grid;
  gap: 5px;
  min-height: 78px;
  place-items: center;
  padding: 10px 6px;
  border-radius: 8px;
  background: #fff;
  text-align: center;
}

.stats-row span {
  color: var(--muted);
  font-size: 12px;
}

.stats-row strong {
  font-size: 24px;
}

.overview-grid article {
  display: grid;
  gap: 9px;
  place-items: center;
  min-height: 86px;
}

.overview-grid strong {
  color: #fff;
  font-size: 40px;
  line-height: 1;
}

.overview-grid span {
  color: rgba(255, 255, 255, 0.86);
  font-weight: 800;
}

.reward-card {
  display: flex;
  align-items: center;
  gap: 14px;
  background: #fff2d7;
}

.reward-card h3,
.history-card h3 {
  margin: 4px 0 7px;
}

.reward-card p {
  margin: 0 0 8px;
  color: var(--muted);
  line-height: 1.5;
}

.reward-card small {
  color: #d07612;
  font-weight: 900;
}

.reward-card img {
  width: 112px;
  height: 132px;
  object-fit: contain;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.5);
}

.weekly-trend {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  align-items: end;
  gap: 10px;
  min-height: 178px;
  padding-top: 10px;
}

.trend-day {
  display: grid;
  grid-template-rows: 1fr auto auto;
  gap: 7px;
  min-width: 0;
  height: 168px;
  text-align: center;
}

.trend-bar-wrap {
  display: flex;
  align-items: end;
  justify-content: center;
  min-height: 112px;
}

.trend-bar {
  width: 16px;
  min-height: 4px;
  border-radius: 999px 999px 0 0;
  background: var(--mint);
}

.trend-value,
.trend-label {
  color: #9a9a9a;
  font-size: 11px;
  font-weight: 800;
}

.trend-empty {
  grid-column: 1 / -1;
  align-self: center;
  color: var(--muted);
  text-align: center;
}

.history-list {
  display: grid;
  gap: 9px;
}

.history-item {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 0;
  border-top: 1px solid var(--line);
}

.history-item span {
  color: var(--muted);
  font-size: 13px;
}

.diagnostic-card h3 {
  margin: 0 0 5px;
}

.diagnostic-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.diagnostic-head p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

#diagSessionBadge {
  flex: 0 0 auto;
  padding: 5px 8px;
  border-radius: 999px;
  color: var(--mint-dark);
  background: #e8fff8;
  font-size: 12px;
  font-weight: 800;
}

.diag-actions {
  display: flex;
  margin-top: 12px;
}

.diag-actions .secondary-btn {
  width: auto;
  min-width: 132px;
  min-height: 40px;
  border-radius: 8px;
  font-size: 13px;
}

.diag-export-status {
  min-height: 20px;
  margin-top: 9px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.skin-showcase {
  display: grid;
  grid-template-columns: 1fr 136px;
  gap: 14px;
  align-items: center;
}

.skin-showcase h2 {
  margin: 5px 0 7px;
}

.skin-showcase p {
  margin: 0;
  color: var(--muted);
}

.skin-showcase img {
  width: 136px;
  height: 150px;
  object-fit: contain;
}

.skin-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.skin-card {
  position: relative;
  display: grid;
  gap: 6px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  text-align: center;
}

.skin-card.selected {
  border-color: var(--mint-dark);
  background: #edfff9;
}

.skin-card.locked img {
  filter: grayscale(1);
  opacity: 0.45;
}

.skin-card img {
  width: 100%;
  height: 120px;
  object-fit: contain;
}

.skin-card strong {
  font-size: 14px;
}

.skin-card small {
  color: var(--muted);
  min-height: 34px;
}

.skin-card button {
  min-height: 34px;
  border-radius: 8px;
  color: #fff;
  background: var(--mint-dark);
  font-weight: 800;
}

.skin-card.locked button {
  color: var(--muted);
  background: #eef4f2;
}

.full {
  margin-top: 18px;
}

.profile-nav {
  position: sticky;
  top: 0;
  z-index: 8;
  height: 88px;
  display: flex;
  align-items: end;
  justify-content: center;
  padding: 20px 18px 14px;
  color: #fff;
  background: var(--mint);
}

.profile-nav .icon-btn {
  position: absolute;
  left: 16px;
  bottom: 10px;
  color: #fff;
  background: rgba(255, 255, 255, 0.28);
  border: 0;
  font-size: 32px;
}

.profile-nav strong {
  font-size: 18px;
}

.profile-skin-showcase {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 158px;
  gap: 18px;
  align-items: stretch;
  margin: 18px;
  min-height: 210px;
  padding: 20px;
  border-radius: 14px;
  background: linear-gradient(135deg, #20322e 0%, #58d2b8 100%);
  box-shadow: 0 12px 30px rgba(64, 191, 164, 0.2);
}

.showcase-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
}

.showcase-copy span {
  color: rgba(255, 255, 255, 0.78);
  font-size: 14px;
  font-weight: 800;
}

.showcase-copy h2 {
  margin: 8px 0 10px;
  color: #fff;
  font-size: 28px;
  line-height: 1.12;
}

.showcase-copy p {
  margin: 0;
  color: rgba(255, 255, 255, 0.82);
  font-weight: 700;
  line-height: 1.5;
}

.showcase-actions {
  display: flex;
  gap: 10px;
  margin-top: 18px;
}

.showcase-primary,
.showcase-secondary {
  min-height: 42px;
  padding: 0 18px;
  border-radius: 999px;
  font-weight: 900;
}

.showcase-primary {
  color: #183b34;
  background: #fff;
}

.showcase-secondary {
  color: #fff;
  background: rgba(255, 255, 255, 0.2);
}

.showcase-primary:disabled {
  cursor: default;
}

.showcase-visual {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 180px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.18);
  overflow: hidden;
}

.showcase-visual img {
  width: 142px;
  height: 178px;
  object-fit: contain;
}

.skin-rarity-tag,
.skin-rarity {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 24px;
  padding: 0 10px;
  border-radius: 999px;
  color: #fff;
  background: #40bfa4;
  font-size: 12px;
  font-weight: 900;
}

.skin-rarity-tag {
  position: absolute;
  top: 12px;
  left: 12px;
}

.skin-rarity-tag.regular,
.skin-rarity.regular {
  background: var(--orange);
}

.skin-rarity-tag.epic,
.skin-rarity.epic {
  background: #6c55d9;
}

.profile-mini {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 0 18px 16px;
  padding: 16px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 4px 16px rgba(18, 49, 43, 0.05);
}

.mini-avatar {
  width: 58px;
  height: 58px;
  flex: none;
  display: grid;
  place-items: center;
  border-radius: 50%;
  border: 2px solid #73dcc1;
  background: #f2fffb;
  overflow: hidden;
}

button.mini-avatar {
  padding: 0;
  cursor: pointer;
}

.mini-avatar img {
  width: 42px;
  height: 42px;
  object-fit: contain;
}

button.mini-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.mini-copy {
  min-width: 0;
  flex: 1;
}

.mini-copy > strong {
  display: block;
  font-size: 18px;
  line-height: 1.25;
}

.profile-nickname {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  max-width: 100%;
  padding: 0;
  color: var(--ink);
  background: transparent;
  text-align: left;
}

.profile-nickname span {
  color: var(--mint-dark);
  font-size: 12px;
  font-weight: 800;
}

.mini-copy > span {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
}

.challenge-mini {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 10px;
  padding: 9px 10px;
  border-radius: 10px;
  background: #f1fffa;
}

.challenge-mini span {
  min-width: 0;
  color: #2a7768;
  font-size: 13px;
  font-weight: 800;
}

.challenge-mini button {
  flex: none;
  min-width: 94px;
  min-height: 34px;
  padding: 0 14px;
  border-radius: 999px;
  color: #fff;
  background: #1f2428;
  font-size: 13px;
  font-weight: 900;
}

.challenge-mini button:disabled {
  color: #71807c;
  background: #dde7e4;
  cursor: default;
}

.profile-stats-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin: 0 18px 16px;
}

.profile-stats-row article {
  display: grid;
  gap: 6px;
  place-items: center;
  min-height: 86px;
  padding: 12px 8px;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 4px 16px rgba(18, 49, 43, 0.05);
}

.profile-stats-row strong {
  color: var(--mint-dark);
  font-size: 28px;
  line-height: 1;
}

.profile-stats-row span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.profile-report-entry {
  width: calc(100% - 36px);
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 74px;
  margin: 0 18px 16px;
  padding: 14px 16px;
  border-radius: 14px;
  color: var(--ink);
  background: #fff;
  box-shadow: 0 4px 16px rgba(18, 49, 43, 0.05);
  text-align: left;
}

.profile-report-entry .report-entry-icon {
  width: 46px;
  height: 46px;
  flex: none;
  display: grid;
  place-items: center;
  gap: 4px;
  border-radius: 50%;
  border: 2px solid #73dcc1;
  background: #f2fffb;
}

.profile-report-entry i {
  display: block;
  height: 3px;
  border-radius: 999px;
  background: var(--mint-dark);
}

.profile-report-entry i:nth-child(1) {
  width: 18px;
}

.profile-report-entry i:nth-child(2) {
  width: 24px;
}

.profile-report-entry i:nth-child(3) {
  width: 14px;
}

.profile-report-entry span:nth-child(2) {
  min-width: 0;
  flex: 1;
}

.profile-report-entry strong,
.profile-report-entry small {
  display: block;
}

.profile-report-entry strong {
  font-size: 18px;
}

.profile-report-entry small {
  margin-top: 4px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.profile-report-entry b {
  color: var(--mint-dark);
  font-size: 34px;
  line-height: 1;
}

.profile-info-card,
.wardrobe-card {
  margin: 0 18px 16px;
  padding: 0 18px;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 4px 16px rgba(18, 49, 43, 0.05);
}

.profile-info-row {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 58px;
  border-bottom: 1px solid #eef3f1;
  color: var(--ink);
  background: transparent;
  text-align: left;
}

.profile-info-row strong {
  font-size: 17px;
}

.profile-info-row span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #667973;
  font-size: 16px;
  font-weight: 800;
}

.profile-info-row em {
  font-style: normal;
}

.profile-info-row b,
.profile-question-grid b {
  color: #b8c3c0;
  font-size: 22px;
  line-height: 1;
  font-weight: 500;
}

.profile-info-row:active,
.profile-question-grid button:active {
  opacity: 0.72;
}

.profile-question-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  padding: 16px 0 18px;
}

.profile-question-grid button {
  position: relative;
  min-height: 72px;
  padding: 12px;
  border-radius: 12px;
  border: 1px solid #e4f3ef;
  background: #f7fcfa;
  color: var(--ink);
  text-align: left;
}

.profile-question-grid span,
.profile-question-grid strong {
  display: block;
}

.profile-question-grid span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.profile-question-grid strong {
  margin-top: 8px;
  padding-right: 18px;
  font-size: 16px;
}

.profile-question-grid b {
  position: absolute;
  right: 10px;
  bottom: 10px;
}

.wardrobe-card {
  padding: 18px;
}

.section-title-row h3 {
  margin: 0;
  font-size: 20px;
}

.section-title-row p {
  margin: 5px 0 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.profile-view .skin-list {
  display: flex;
  gap: 12px;
  margin-top: 16px;
  padding: 0 0 6px;
  overflow-x: auto;
}

.profile-view .skin-card {
  width: 146px;
  min-width: 146px;
  min-height: 270px;
  display: flex;
  flex-direction: column;
  gap: 7px;
  align-items: center;
  justify-content: flex-start;
  padding: 12px;
  border-radius: 12px;
  border: 1px solid #eef3f1;
  background: #fafcfb;
}

.profile-view .skin-card.selected {
  border-color: var(--mint-dark);
  background: #f0fffa;
}

.profile-view .skin-card.locked {
  background: #f5f6f7;
}

.profile-view .skin-card img {
  width: 112px;
  height: 130px;
  object-fit: contain;
}

.profile-view .skin-card strong {
  width: 100%;
  min-height: 36px;
  font-size: 14px;
  line-height: 1.25;
}

.profile-view .skin-card small {
  min-height: 34px;
  font-size: 12px;
  line-height: 1.35;
}

.profile-view .skin-card button {
  width: 100%;
  margin-top: auto;
  min-height: 38px;
  border-radius: 8px;
}

.profile-view .skin-card.selected button {
  background: var(--mint-dark);
}

.profile-logout {
  width: calc(100% - 36px);
  margin: 8px 18px 0;
}

.profile-edit-modal {
  position: fixed;
  inset: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 22px;
  background: rgba(18, 22, 28, 0.48);
}

body.modal-open {
  overflow: hidden;
}

.demo-video-modal {
  position: fixed;
  inset: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 18px;
  background: rgba(12, 24, 21, 0.68);
}

.demo-video-dialog {
  width: min(100%, 620px);
  max-height: min(90vh, 760px);
  overflow: auto;
  padding: 18px;
  border-radius: 18px;
  color: var(--ink);
  background: #fff;
  box-shadow: 0 24px 70px rgba(12, 24, 21, 0.32);
}

.demo-video-modal-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 13px;
}

.demo-video-modal-head span {
  color: #438176;
  font-size: 12px;
  font-weight: 800;
}

.demo-video-modal-head h2 {
  margin: 3px 0 0;
  font-size: 21px;
}

.demo-video-close {
  display: grid;
  width: 34px;
  height: 34px;
  flex: none;
  place-items: center;
  border-radius: 50%;
  color: #48645e;
  background: #edf6f3;
  font-size: 27px;
  line-height: 1;
}

.promo-video {
  display: block;
  width: 100%;
  max-height: 62vh;
  border-radius: 12px;
  background: #0d1715;
}

.full-demo-link {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 3px 10px;
  align-items: center;
  margin-top: 14px;
  padding: 14px 15px;
  border: 1px solid #d8ebe5;
  border-radius: 12px;
  color: #285d55;
  background: #f5fbf9;
  text-decoration: none;
}

.full-demo-link span {
  grid-column: 1;
  color: var(--muted);
  font-size: 12px;
}

.full-demo-link strong {
  grid-column: 1;
  font-size: 14px;
}

.full-demo-link b {
  grid-row: 1 / span 2;
  grid-column: 2;
  font-size: 20px;
}

.profile-edit-panel {
  width: min(100%, 420px);
  padding: 20px;
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 18px 60px rgba(18, 22, 28, 0.2);
}

.profile-edit-panel h3 {
  margin: 0;
  font-size: 22px;
  text-align: center;
}

.profile-number-editor label {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 18px;
  padding: 0 14px;
  min-height: 58px;
  border-radius: 12px;
  border: 1px solid #e4f3ef;
  background: #f7fcfa;
}

.profile-number-editor input {
  width: 100%;
  min-width: 0;
  border: 0;
  outline: 0;
  color: var(--ink);
  background: transparent;
  font-size: 22px;
  font-weight: 900;
}

.profile-number-editor span {
  flex: none;
  color: var(--muted);
  font-weight: 900;
}

.profile-choice-list {
  display: grid;
  gap: 10px;
  margin-top: 18px;
}

.profile-choice-list button {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 54px;
  padding: 0 14px;
  border-radius: 12px;
  border: 1px solid #e4f3ef;
  color: var(--ink);
  background: #f7fcfa;
  font-weight: 900;
  text-align: left;
}

.profile-choice-list button.active {
  border-color: var(--mint-dark);
  background: #edfff9;
}

.profile-choice-list button.active::after {
  content: "";
  width: 10px;
  height: 10px;
  flex: none;
  border-radius: 50%;
  background: var(--mint-dark);
}

.profile-edit-error {
  min-height: 20px;
  margin: 10px 0 0;
  color: var(--danger);
  font-size: 13px;
  font-weight: 800;
  text-align: center;
}

.profile-edit-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 12px;
}

.profile-edit-actions button {
  min-height: 46px;
  border-radius: 999px;
  font-weight: 900;
}

#profileEditCancelBtn {
  color: #60646c;
  background: #f2f3f5;
}

#profileEditSaveBtn {
  color: #fff;
  background: #1f2428;
}

.profile-edit-actions.choice-mode {
  grid-template-columns: 1fr;
}

.profile-edit-actions.choice-mode #profileEditSaveBtn {
  display: none;
}

.skin-detail-panel {
  position: relative;
  text-align: center;
}

.skin-detail-panel > img {
  display: block;
  width: 176px;
  height: 190px;
  margin: 14px auto 8px;
  object-fit: contain;
}

.skin-detail-panel .skin-rarity-tag {
  top: 18px;
  left: 18px;
}

.skin-detail-panel h3 {
  margin-top: 4px;
}

.skin-detail-panel p {
  color: var(--muted);
  font-weight: 700;
  line-height: 1.5;
}

.skin-detail-condition {
  color: var(--mint-dark) !important;
}

#skinDetailCloseBtn {
  color: #60646c;
  background: #f2f3f5;
}

#skinDetailUseBtn {
  color: #fff;
  background: #1f2428;
}

@media (max-width: 380px) {
  .profile-skin-showcase {
    grid-template-columns: 1fr 126px;
    padding: 16px;
  }

  .showcase-actions {
    flex-wrap: wrap;
  }

  .showcase-visual img {
    width: 116px;
  }
}

.challenge-modal {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 22px;
  background: rgba(12, 20, 18, 0.58);
}

.challenge-dialog {
  width: min(100%, 420px);
  padding: 22px;
  border-radius: 16px;
  background: #fff;
  color: var(--ink);
  text-align: center;
  box-shadow: 0 24px 70px rgba(18, 49, 43, 0.22);
}

.challenge-dialog > span {
  color: var(--orange);
  font-weight: 900;
}

.challenge-dialog h2 {
  margin: 8px 0;
  font-size: 26px;
}

.challenge-dialog p {
  margin: 0;
  color: var(--muted);
  line-height: 1.5;
  font-weight: 700;
}

.challenge-rewards {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 18px;
}

.challenge-rewards article {
  padding: 12px 8px;
  border-radius: 8px;
  background: #fff7ed;
}

.challenge-rewards article.epic {
  background: #f1edff;
}

.challenge-rewards img {
  width: 100%;
  height: 112px;
  object-fit: contain;
}

.challenge-rewards strong,
.challenge-rewards small {
  display: block;
}

.challenge-rewards small {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
}

.deposit-note {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 16px 0;
  padding: 12px;
  border-radius: 8px;
  background: #fff7ed;
  text-align: left;
}

.deposit-note b {
  display: grid;
  place-items: center;
  width: 58px;
  height: 58px;
  flex: 0 0 58px;
  border-radius: 8px;
  background: var(--orange);
  color: #fff;
  font-size: 22px;
}

.deposit-note span {
  color: #8c5830;
  font-weight: 800;
  line-height: 1.45;
}

.challenge-accept,
.challenge-decline {
  display: block;
  width: fit-content;
  max-width: 100%;
  min-height: 48px;
  margin: 12px auto 0;
  padding: 0 26px;
  border-radius: 999px;
  font-weight: 900;
}

.challenge-accept {
  color: #fff;
  background: #172321;
}

.challenge-decline {
  color: var(--muted);
  background: #f1f4f3;
}

@media (min-width: 481px) {
  body {
    background: #dceee9;
  }

  .app-shell {
    min-height: 100vh;
    box-shadow: 0 0 0 1px rgba(18, 49, 43, 0.08);
  }
}
