@charset "UTF-8";

:root {
  color-scheme: light;
  --yellow: #f4c753;
  --yellow-soft: #ffe9b1;
  --bg: #fcfaf7;
  --thumb: #f2f0e8;
  --ink: #1e1e1e;
  --text: #625845;
  --muted: #a39e9e;
  --line: #ded8cc;
  --line-soft: #ebe6dd;
  --paper: #fffdf8;
  --dim: rgba(0, 0, 0, 0.25);
  --danger: #ff3b21;
  --sage: #728c75;
  --warm-shadow: 0 18px 50px rgba(83, 62, 35, 0.12);
  --soft-shadow: 0 8px 22px rgba(83, 62, 35, 0.08);
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "PingFang SC",
    "Microsoft YaHei", Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  background:
    radial-gradient(circle at top left, rgba(244, 199, 83, 0.16), transparent 32rem),
    linear-gradient(180deg, #fffefb 0%, var(--bg) 55%, #f5f1e9 100%);
  color: var(--ink);
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  cursor: pointer;
}

button:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

img {
  display: block;
  max-width: 100%;
}

.app {
  width: min(1320px, 100%);
  margin: 0 auto;
  padding: 18px;
}

.app-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.brand,
.header-actions,
.screen-header,
.canvas-toolbar,
.canvas-actions,
.sheet-header,
.source-tabs {
  display: flex;
  align-items: center;
}

.brand {
  gap: 12px;
}

.brand-icon {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border-radius: 16px;
  background: linear-gradient(135deg, var(--yellow), #f8d978);
  color: var(--ink);
  font-weight: 900;
  box-shadow: var(--soft-shadow);
}

.brand h1,
.brand p,
.screen-header h2,
.screen-header p,
.sheet-header h3,
.sheet-header p,
.panel h3,
.panel p {
  margin: 0;
}

.brand h1 {
  font-size: 1.25rem;
  line-height: 1.15;
}

.brand p,
.screen-header p,
.sheet-header p,
.panel p {
  color: var(--text);
  font-size: 0.86rem;
}

.header-actions {
  gap: 8px;
}

.cloud-pill {
  padding: 9px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 253, 248, 0.82);
  color: var(--text);
  font-size: 0.84rem;
}

.phone-frame {
  position: relative;
  min-height: calc(100vh - 100px);
  padding: 18px 18px 92px;
  border: 1px solid var(--line);
  border-radius: 30px;
  background: var(--bg);
  box-shadow: var(--warm-shadow);
  overflow: hidden;
}

.view {
  display: none;
}

.view.is-active {
  display: block;
}

.screen-header {
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 14px;
}

.screen-header h2 {
  font-size: clamp(1.55rem, 3vw, 2.35rem);
  line-height: 1.05;
}

.icon-button,
.fab {
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 999px;
  background: var(--yellow);
  color: var(--ink);
  font-size: 1.4rem;
  font-weight: 800;
  box-shadow: var(--soft-shadow);
}

.icon-button {
  width: 44px;
  height: 44px;
}

.fab {
  position: absolute;
  right: 24px;
  bottom: 96px;
  z-index: 5;
  width: 62px;
  height: 62px;
  transition: transform 150ms ease;
}

.fab:hover {
  transform: translateY(-2px);
}

.category-tabs,
.tag-strip,
.item-tray,
.deploy-list {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 8px;
  scrollbar-width: none;
}

.category-tabs::-webkit-scrollbar,
.tag-strip::-webkit-scrollbar,
.item-tray::-webkit-scrollbar {
  display: none;
}

.tab-chip,
.tag-chip {
  border: 0;
  border-radius: 999px;
  white-space: nowrap;
}

.tab-chip {
  display: flex;
  align-items: center;
  gap: 7px;
  min-height: 38px;
  padding: 8px 14px;
  background: var(--thumb);
  color: var(--text);
  font-weight: 700;
}

.tab-chip span {
  color: var(--muted);
  font-size: 0.8rem;
}

.tab-chip.is-active {
  background: var(--yellow);
  color: var(--ink);
}

.tag-chip {
  min-height: 32px;
  padding: 7px 11px;
  background: #2c2c2c;
  color: #f5f5f5;
  font-size: 0.82rem;
}

.tag-chip.is-light {
  background: #f5f5f5;
  color: #757575;
  border: 1px solid var(--line-soft);
}

.closet-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  padding-top: 8px;
}

.clothing-card {
  position: relative;
  overflow: hidden;
  aspect-ratio: 1 / 1;
  border: 1px solid var(--line-soft);
  border-radius: 16px;
  background: var(--thumb);
  box-shadow: 0 5px 12px rgba(83, 62, 35, 0.05);
}

.clothing-card img,
.outfit-card img,
.source-card img,
.tray-item img,
.try-thumb img,
.detail-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.clothing-card button {
  width: 100%;
  height: 100%;
  border: 0;
  background: transparent;
  padding: 0;
}

.clothing-card .mini-add {
  position: absolute;
  right: 8px;
  bottom: 8px;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 0;
  background: var(--yellow);
  font-weight: 900;
  box-shadow: var(--soft-shadow);
}

.empty-state {
  grid-column: 1 / -1;
  display: grid;
  place-items: center;
  min-height: 280px;
  border: 1px dashed var(--line);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.48);
  color: var(--text);
  text-align: center;
  padding: 20px;
}

.outfit-grid,
.recent-grid,
.source-grid,
.insight-grid {
  display: grid;
  gap: 12px;
}

.outfit-grid,
.recent-grid,
.source-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.outfit-card,
.try-thumb {
  overflow: hidden;
  border: 1px solid var(--line-soft);
  border-radius: 18px;
  background: var(--thumb);
  box-shadow: var(--soft-shadow);
}

.outfit-card {
  position: relative;
  aspect-ratio: 3 / 4;
}

.outfit-card button {
  width: 100%;
  height: 100%;
  border: 0;
  background: transparent;
  padding: 0;
}

.outfit-name {
  position: absolute;
  left: 10px;
  right: 10px;
  bottom: 10px;
  padding: 7px 9px;
  border-radius: 10px;
  background: rgba(30, 30, 30, 0.76);
  color: #fff;
  font-size: 0.82rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.canvas-screen {
  display: none;
}

.canvas-screen.is-open {
  display: block;
}

.outfit-list.is-hidden {
  display: none;
}

.canvas-toolbar {
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.outfit-canvas {
  position: relative;
  min-height: 520px;
  border-radius: 22px;
  background:
    linear-gradient(135deg, rgba(244, 199, 83, 0.16), transparent 45%),
    var(--thumb);
  overflow: hidden;
}

.canvas-placeholder {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: var(--text);
  text-align: center;
  padding: 24px;
}

.canvas-piece {
  position: absolute;
  width: 32%;
  min-width: 94px;
  aspect-ratio: 1 / 1;
  border: 2px solid transparent;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.44);
  pointer-events: none;
  touch-action: none;
  user-select: none;
}

.canvas-piece.is-active {
  border-color: var(--yellow);
}

.canvas-piece img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  pointer-events: auto;
}

.piece-remove {
  position: absolute;
  z-index: 1000;
  width: 28px;
  height: 28px;
  transform: translate(-50%, -50%);
  border: 0;
  border-radius: 50%;
  background: var(--danger);
  color: #fff;
  font-weight: 800;
  pointer-events: auto;
  touch-action: manipulation;
}

.canvas-bottom {
  display: grid;
  gap: 10px;
  margin: 12px 0 16px;
}

.canvas-bottom input,
.add-form input,
.add-form select {
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--paper);
  color: var(--ink);
  padding: 0 12px;
  outline: 0;
}

.canvas-bottom input:focus,
.add-form input:focus,
.add-form select:focus {
  border-color: var(--yellow);
  box-shadow: 0 0 0 3px rgba(244, 199, 83, 0.18);
}

.canvas-actions {
  gap: 8px;
}

.canvas-actions button {
  flex: 1;
}

.tray-title,
.section-label {
  margin: 16px 0 8px;
  color: var(--text);
  font-weight: 800;
}

.tray-item {
  flex: 0 0 72px;
  height: 72px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--thumb);
}

.tryon-selectors {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin: 14px 0;
}

.selection-box {
  position: relative;
  display: grid;
  align-content: start;
  gap: 8px;
  min-height: 210px;
  overflow: hidden;
  border: 1px dashed var(--line);
  border-radius: 20px;
  background: var(--thumb);
  color: var(--ink);
  padding: 16px;
  text-align: left;
}

.selection-box input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.selection-box span {
  color: var(--text);
  font-size: 0.84rem;
}

.selection-box img {
  display: none;
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.selection-box.has-image img {
  display: block;
}

.selection-box.has-image strong,
.selection-box.has-image span {
  position: relative;
  z-index: 1;
  width: fit-content;
  max-width: 100%;
  padding: 5px 7px;
  border-radius: 8px;
  background: rgba(255, 253, 248, 0.86);
}

.tips-toggle {
  min-height: 40px;
  border: 0;
  border-radius: 14px;
  background: var(--thumb);
  color: var(--text);
  padding: 0 12px;
  font-weight: 700;
}

.photo-tips {
  display: none;
  gap: 6px;
  margin-top: 10px;
  padding: 12px;
  border-radius: 16px;
  background: var(--paper);
  color: var(--text);
}

.photo-tips.is-open {
  display: grid;
}

.try-progress {
  display: none;
  gap: 8px;
  margin: 12px 0;
  padding: 14px;
  border-radius: 18px;
  background: var(--paper);
}

.try-progress.is-open {
  display: grid;
}

.try-progress > div:first-child {
  display: flex;
  justify-content: space-between;
}

.progress-track {
  height: 10px;
  overflow: hidden;
  border-radius: 999px;
  background: var(--thumb);
}

.progress-track span {
  display: block;
  width: 0%;
  height: 100%;
  border-radius: inherit;
  background: var(--yellow);
}

.try-result {
  display: none;
  margin: 14px 0;
}

.try-result.is-open {
  display: block;
}

.try-result img {
  width: min(420px, 100%);
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 22px;
  background: var(--thumb);
  box-shadow: var(--soft-shadow);
}

.try-thumb {
  aspect-ratio: 3 / 4;
}

.insight-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-bottom: 14px;
}

.insight-card,
.panel {
  border: 1px solid var(--line);
  border-radius: 20px;
  background: var(--paper);
  padding: 16px;
  box-shadow: var(--soft-shadow);
}

.insight-card strong {
  display: block;
  margin-top: 10px;
  font-size: 2rem;
}

.deploy-list {
  flex-wrap: wrap;
  margin-top: 12px;
}

.deploy-list span {
  padding: 7px 9px;
  border-radius: 999px;
  background: var(--thumb);
  color: var(--text);
  font-size: 0.82rem;
}

.backup-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-top: 14px;
}

.gold-button,
.secondary-button,
.ghost-button,
.danger-button,
.file-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  border-radius: 14px;
  padding: 0 14px;
  font-weight: 800;
  text-decoration: none;
}

.gold-button {
  border: 0;
  background: var(--yellow);
  color: var(--ink);
}

.secondary-button,
.ghost-button {
  border: 1px solid var(--line);
  background: var(--paper);
  color: var(--ink);
}

.ghost-button {
  min-height: 38px;
}

.danger-button {
  border: 0;
  background: var(--danger);
  color: #fff;
}

.wide {
  width: 100%;
}

.file-button {
  position: relative;
  overflow: hidden;
}

.file-button input {
  position: absolute;
  inset: 0;
  opacity: 0;
}

.hidden-input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.bottom-nav {
  position: absolute;
  left: 18px;
  right: 18px;
  bottom: 18px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 4px;
  padding: 7px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(255, 253, 248, 0.94);
  box-shadow: var(--soft-shadow);
}

.nav-button {
  display: grid;
  gap: 2px;
  place-items: center;
  min-height: 54px;
  border: 0;
  border-radius: 18px;
  background: transparent;
  color: var(--text);
  font-size: 0.78rem;
  font-weight: 800;
}

.nav-button span {
  font-size: 1.18rem;
}

.nav-icon {
  position: relative;
  display: block;
  width: 22px;
  height: 22px;
  color: currentColor;
}

.nav-icon::before,
.nav-icon::after {
  position: absolute;
  content: "";
}

.nav-icon-closet {
  border-radius: 4px;
  background: currentColor;
}

.nav-icon-closet::before {
  left: 50%;
  top: 3px;
  bottom: 3px;
  width: 2px;
  transform: translateX(-50%);
  background: var(--bg);
}

.nav-icon-closet::after {
  left: 6px;
  top: 10px;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: var(--bg);
  box-shadow: 8px 0 0 var(--bg);
}

.nav-icon-outfits::before {
  left: 5px;
  top: 3px;
  width: 14px;
  height: 18px;
  border-radius: 4px;
  background: currentColor;
  transform: rotate(-18deg);
}

.nav-icon-outfits::after {
  left: 9px;
  top: 7px;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--bg);
}

.nav-icon-tryon::before {
  left: 9px;
  top: 1px;
  width: 4px;
  height: 22px;
  border-radius: 999px;
  background: currentColor;
  transform: rotate(38deg);
}

.nav-icon-tryon::after {
  left: 2px;
  top: 2px;
  width: 4px;
  height: 4px;
  background: currentColor;
  box-shadow:
    14px 1px 0 -1px currentColor,
    3px 15px 0 -1px currentColor,
    17px 16px 0 -2px currentColor;
  transform: rotate(45deg);
}

.nav-icon-profile::before {
  left: 7px;
  top: 3px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: currentColor;
}

.nav-icon-profile::after {
  left: 3px;
  bottom: 3px;
  width: 16px;
  height: 9px;
  border-radius: 12px 12px 4px 4px;
  background: currentColor;
}

.nav-button.is-active {
  background: var(--yellow);
  color: var(--ink);
}

.detail-drawer,
.bottom-sheet {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: none;
  background: var(--dim);
}

.detail-drawer.is-open,
.bottom-sheet.is-open {
  display: block;
}

.drawer-card {
  position: absolute;
  right: 18px;
  top: 18px;
  bottom: 18px;
  width: min(430px, calc(100vw - 36px));
  overflow: auto;
  border-radius: 26px;
  background: var(--bg);
  padding: 18px;
  box-shadow: var(--warm-shadow);
}

.sheet-card {
  position: absolute;
  left: 50%;
  bottom: 18px;
  width: min(720px, calc(100vw - 24px));
  max-height: min(780px, calc(100vh - 36px));
  overflow: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  transform: translateX(-50%);
  border-radius: 28px;
  background: var(--bg);
  padding: 18px;
  box-shadow: var(--warm-shadow);
}

.drawer-close {
  border: 0;
  border-radius: 50%;
  width: 38px;
  height: 38px;
  background: var(--thumb);
  color: var(--ink);
  font-size: 1.35rem;
}

.drawer-card > .drawer-close {
  position: sticky;
  top: 0;
  margin-left: auto;
  z-index: 1;
}

.sheet-header {
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.upload-zone {
  display: grid;
  place-items: center;
  min-height: 148px;
  border: 1.5px dashed var(--line);
  border-radius: 20px;
  background: var(--thumb);
  color: var(--text);
  text-align: center;
}

.upload-zone input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.add-form,
.form-grid {
  display: grid;
  gap: 12px;
}

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

.add-form label,
.field-block {
  display: grid;
  gap: 6px;
  color: var(--text);
  font-size: 0.88rem;
  font-weight: 700;
}

.field-label {
  display: block;
}

.color-choice-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(92px, 1fr));
  gap: 8px;
}

.color-choice {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--paper);
  color: var(--ink);
  padding: 0 10px;
  text-align: left;
  font-weight: 800;
}

.color-choice.is-active {
  border-color: var(--yellow);
  box-shadow: 0 0 0 3px rgba(244, 199, 83, 0.18);
}

.color-swatch {
  flex: 0 0 20px;
  width: 20px;
  height: 20px;
  border: 1px solid rgba(30, 30, 30, 0.18);
  border-radius: 999px;
  background: var(--choice-color);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.38);
}

.source-tabs {
  gap: 8px;
  margin-bottom: 12px;
}

.source-tab {
  flex: 1;
  min-height: 40px;
  border: 0;
  border-radius: 999px;
  background: var(--thumb);
  color: var(--text);
  font-weight: 800;
}

.source-tab.is-active {
  background: var(--yellow);
  color: var(--ink);
}

.source-card {
  overflow: hidden;
  aspect-ratio: 1 / 1;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--thumb);
}

.source-card button {
  width: 100%;
  height: 100%;
  border: 0;
  background: transparent;
  padding: 0;
}

.detail-image {
  aspect-ratio: 1 / 1;
  overflow: hidden;
  border-radius: 24px;
  background: var(--thumb);
}

.detail-title {
  margin: 14px 0 8px;
  font-size: 1.5rem;
}

.detail-tags,
.detail-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 10px 0;
}

.detail-row {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr);
  gap: 10px;
  padding: 10px 0;
  border-bottom: 1px solid var(--line-soft);
  color: var(--text);
}

.detail-row strong {
  color: var(--ink);
}

.toast {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 40;
  max-width: min(360px, calc(100vw - 40px));
  padding: 12px 14px;
  border-radius: 16px;
  background: var(--ink);
  color: #fff;
  box-shadow: var(--warm-shadow);
  opacity: 0;
  transform: translateY(12px);
  pointer-events: none;
  transition:
    opacity 160ms ease,
    transform 160ms ease;
}

.toast.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (min-width: 980px) {
  .phone-frame {
    padding: 22px 22px 98px;
  }

  .closet-grid {
    grid-template-columns: repeat(6, minmax(0, 1fr));
  }

  .outfit-grid,
  .recent-grid,
  .source-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .tryon-selectors {
    grid-template-columns: repeat(2, minmax(260px, 1fr));
  }
}

@media (max-width: 720px) {
  .app {
    padding: 10px;
  }

  .app-header {
    align-items: flex-start;
    flex-direction: column;
  }

  .header-actions {
    width: 100%;
    justify-content: flex-end;
  }

  .cloud-pill {
    display: none;
  }

  .phone-frame {
    min-height: calc(100vh - 118px);
    border-radius: 22px;
    padding: 14px 14px 90px;
  }

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

  .tryon-selectors,
  .insight-grid,
  .backup-grid,
  .form-grid {
    grid-template-columns: 1fr;
  }

  .outfit-canvas {
    min-height: 440px;
  }

  .bottom-nav {
    left: 10px;
    right: 10px;
    bottom: 10px;
  }

  .fab {
    right: 18px;
    bottom: 88px;
  }
}

/* Reference-inspired mobile app skin based on zebangeth/ai-closet. */
body {
  background: var(--bg);
}

.app {
  width: min(560px, 100%);
  min-height: 100vh;
  padding: 0;
  background: var(--bg);
}

.app-header {
  display: none;
}

.phone-frame {
  min-height: 100vh;
  padding: 0 0 86px;
  border: 0;
  border-radius: 0;
  background: var(--bg);
  box-shadow: none;
  overflow: visible;
}

.view.is-active {
  display: block;
}

.screen-header {
  justify-content: space-between;
  gap: 16px;
  margin: 0;
  padding: 22px 16px 12px;
}

.screen-header h2 {
  font-size: 2.15rem;
  line-height: 1.05;
  font-weight: 900;
  letter-spacing: 0;
}

.screen-header p {
  display: none;
}

.screen-intro {
  margin: 0;
  padding: 0 16px 22px;
  color: var(--text);
  font-size: 1.12rem;
  line-height: 1.35;
}

.filter-button,
.canvas-icon-action {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 0;
  background: transparent;
  color: var(--ink);
  padding: 0;
}

.filter-button {
  gap: 3px;
}

.filter-button span {
  display: block;
  height: 3px;
  border-radius: 999px;
  background: var(--ink);
}

.filter-button span:nth-child(1) {
  width: 26px;
}

.filter-button span:nth-child(2) {
  width: 18px;
}

.filter-button span:nth-child(3) {
  width: 8px;
}

.icon-button {
  display: none;
}

.category-tabs {
  gap: 8px;
  padding: 0 16px 10px;
}

.tag-strip {
  gap: 10px;
  padding: 0 16px 16px;
  border-bottom: 1px solid var(--line-soft);
}

.tab-chip {
  min-height: 44px;
  padding: 0 14px;
  border-radius: 18px;
  background: var(--thumb);
  color: var(--text);
  font-size: 1rem;
  font-weight: 700;
}

.tab-chip span {
  font-size: inherit;
  color: inherit;
  opacity: 0.72;
}

.tab-chip.is-active {
  background: var(--yellow);
  color: var(--ink);
}

.tag-chip {
  min-height: 30px;
  border-radius: 10px;
  background: var(--tag-dark, #2c2c2c);
  color: #f5f5f5;
  font-size: 0.9rem;
  font-weight: 500;
}

.tag-chip.is-light {
  border: 0;
  background: #f5f5f5;
  color: #757575;
}

.closet-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  padding: 16px 16px 120px;
}

.clothing-card {
  border: 0;
  border-radius: 14px;
  background: var(--thumb);
  box-shadow: none;
}

.clothing-card img {
  object-fit: contain;
  padding: 4px;
}

.clothing-card .mini-add {
  display: none;
}

.empty-state {
  min-height: 320px;
  border-color: var(--line);
  border-radius: 16px;
  background: transparent;
  color: var(--text);
}

.empty-state strong {
  color: var(--ink);
  font-size: 1.2rem;
}

.outfit-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  padding: 20px 16px 120px;
}

.outfit-card,
.try-thumb,
.source-card {
  border: 0;
  border-radius: 16px;
  background: var(--thumb);
  box-shadow: none;
}

.outfit-card img,
.source-card img {
  object-fit: contain;
  padding: 8px;
}

.outfit-name {
  display: none;
}

#outfitsView.is-canvas-open > .screen-header,
#outfitsView.is-canvas-open > .tag-strip {
  display: none;
}

.canvas-toolbar {
  justify-content: space-between;
  margin: 0;
  padding: 20px 16px;
  border-bottom: 1px solid var(--line-soft);
}

.canvas-toolbar strong {
  font-size: 1.6rem;
  font-weight: 900;
}

.canvas-icon-action {
  font-size: 1.7rem;
  font-weight: 800;
}

.outfit-canvas {
  min-height: min(66vh, 660px);
  margin: 16px;
  border-radius: 16px;
  background: var(--thumb);
}

.canvas-piece {
  border-radius: 12px;
  background: transparent;
}

.canvas-piece.is-active {
  border-color: var(--yellow);
}

.piece-remove {
  background: var(--yellow);
  color: var(--ink);
}

.canvas-bottom {
  margin: 0;
  padding: 0 16px 10px;
}

.canvas-bottom input {
  display: none;
}

.canvas-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.canvas-actions .gold-button {
  min-height: 54px;
  border-radius: 14px;
  font-size: 1rem;
}

.tray-title {
  margin: 10px 16px 8px;
}

.item-tray {
  padding: 0 16px 14px;
}

.tray-item {
  flex-basis: 88px;
  height: 88px;
  border: 0;
  border-radius: 12px;
}

.tryon-selectors {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin: 22px 16px;
}

.tryon-card {
  display: grid;
  gap: 10px;
  min-width: 0;
}

.tryon-card h3 {
  margin: 0;
  color: var(--ink);
  font-size: 1.25rem;
  line-height: 1.05;
}

.selection-box {
  min-height: 220px;
  border: 0;
  border-radius: 14px;
  background: var(--thumb);
  padding: 14px;
}

.selection-box strong {
  color: var(--text);
  font-size: 1rem;
  font-weight: 800;
}

.selection-box.has-image strong {
  position: relative;
  z-index: 1;
  width: fit-content;
  max-width: 100%;
  padding: 6px 8px;
  border-radius: 8px;
  background: rgba(255, 253, 248, 0.9);
}

.tips-toggle {
  display: grid;
  grid-template-columns: 36px 1fr 28px;
  align-items: center;
  width: calc(100% - 32px);
  min-height: 58px;
  margin: 0 16px;
  border-radius: 14px;
  background: var(--thumb);
  color: var(--text);
  text-align: left;
}

.tips-icon {
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--text);
  color: var(--bg);
  font-weight: 900;
}

.tips-caret {
  color: var(--text);
  font-size: 1.6rem;
}

.photo-tips {
  margin: 10px 16px 0;
  background: var(--thumb);
}

.try-progress,
.try-result,
.section-label,
.recent-grid {
  margin-left: 16px;
  margin-right: 16px;
}

.bottom-nav {
  position: fixed;
  left: 50%;
  right: auto;
  bottom: 0;
  z-index: 10;
  width: min(560px, 100%);
  height: 86px;
  transform: translateX(-50%);
  gap: 0;
  padding: 8px 8px 10px;
  border: 0;
  border-top: 1px solid var(--line-soft);
  border-radius: 0;
  background: var(--bg);
  box-shadow: none;
}

.nav-button {
  min-height: 58px;
  border-radius: 0;
  color: var(--text);
  font-size: 0.82rem;
  font-weight: 600;
}

.nav-button span {
  font-size: 1.45rem;
}

.nav-button.is-active {
  background: transparent;
  color: var(--ink);
}

.fab {
  position: fixed;
  left: calc(50% + min(220px, 38vw));
  right: auto;
  bottom: 112px;
  z-index: 12;
  width: 60px;
  height: 60px;
  box-shadow: none;
  transform: translateX(-50%);
}

.fab.is-hidden {
  display: none;
}

.detail-drawer,
.bottom-sheet {
  background: var(--dim);
}

.drawer-card {
  left: 50%;
  right: auto;
  top: 0;
  bottom: 0;
  width: min(560px, 100%);
  transform: translateX(-50%);
  border-radius: 0;
  background: var(--bg);
}

.sheet-card {
  bottom: 0;
  width: min(560px, 100%);
  max-height: min(82vh, 760px);
  border-radius: 28px 28px 0 0;
  background: var(--bg);
  padding: 22px 20px 28px;
}

.sheet-header h3 {
  font-size: 1.65rem;
  line-height: 1.05;
}

.source-tabs {
  display: grid;
  gap: 14px;
}

.source-tab {
  display: grid;
  grid-template-columns: 58px 1fr;
  align-items: center;
  gap: 14px;
  min-height: 90px;
  border-radius: 16px;
  background: var(--thumb);
  padding: 14px;
  text-align: left;
}

.source-tab.is-active {
  background: var(--thumb);
}

.source-option-icon {
  display: grid;
  place-items: center;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: var(--paper);
  color: var(--ink);
  font-size: 1.6rem;
}

.source-tab strong {
  display: block;
  color: var(--ink);
  font-size: 1.08rem;
}

.source-tab small {
  display: block;
  margin-top: 4px;
  color: var(--text);
  font-size: 0.86rem;
  line-height: 1.25;
}

.source-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 16px;
}

.insight-grid {
  padding: 0 16px;
}

.panel,
.backup-grid {
  margin-left: 16px;
  margin-right: 16px;
}

@media (min-width: 561px) {
  body {
    display: grid;
    place-items: start center;
    background: #ece8df;
  }

  .app {
    box-shadow: 0 0 0 1px var(--line-soft);
  }
}

@media (max-width: 420px) {
  .screen-header {
    padding-top: 20px;
  }

  .tab-chip {
    min-height: 42px;
    padding: 0 12px;
  }

  .closet-grid {
    gap: 10px;
    padding-left: 12px;
    padding-right: 12px;
  }

  .tryon-selectors {
    gap: 10px;
    margin-left: 12px;
    margin-right: 12px;
  }

  .selection-box {
    min-height: 188px;
  }

  .fab {
    left: auto;
    right: 30px;
    transform: none;
  }
}
