:root {
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

/* Custom Scrollbar for Left Panel */
aside::-webkit-scrollbar {
  width: 4px;
}
aside::-webkit-scrollbar-track {
  background: transparent;
}
aside::-webkit-scrollbar-thumb {
  background-color: #e5e7eb;
  border-radius: 10px;
}

/* Checkerboard Background for 2D Canvas */
.checkerboard-bg {
  background:
    linear-gradient(45deg, #f3f4f6 25%, transparent 25%),
    linear-gradient(-45deg, #f3f4f6 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, #f3f4f6 75%),
    linear-gradient(-45deg, transparent 75%, #f3f4f6 75%),
    #ffffff;
  background-position:
    0 0,
    0 12px,
    12px -12px,
    -12px 0;
  background-size: 24px 24px;
}

/* Force hiding standard color picker wrapper */
.color-wheel::-webkit-color-swatch-wrapper {
  padding: 0;
}
.color-wheel::-webkit-color-swatch {
  border: 2px solid #ffffff;
  border-radius: 999px;
  box-shadow: 0 1px 2px rgba(0,0,0,0.1);
}

/* --- Original Welcome / Naming Screen CSS --- */
.phone-shell {
  position: relative;
  width: min(100%, 430px);
  min-height: min(860px, calc(100vh - 36px));
  border: 2px solid #2f2b27;
  border-radius: 28px;
  overflow: hidden;
  background: #fffaf2;
  box-shadow: 0 24px 70px rgb(34 31 32 / 18%);
}

.screen {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  gap: 18px;
  padding: 22px;
}

.top-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: #524841;
}

.top-strip span {
  padding: 8px 10px;
  border-radius: 999px;
  background: #eef7ff;
  color: #22577a;
  font-size: 0.82rem;
  font-weight: 850;
}

.mascot-bubble {
  flex: 1;
  min-height: 300px;
  display: grid;
  place-items: center;
}

.mini-cat {
  width: 190px;
  height: 190px;
  border: 2px solid #2f2b27;
  border-radius: 44% 44% 48% 48%;
  background: #ffffff;
  position: relative;
  animation: floaty 2.8s ease-in-out infinite;
}

.mini-cat::before,
.mini-cat::after {
  content: "";
  position: absolute;
  top: -28px;
  width: 66px;
  height: 72px;
  border: 2px solid #2f2b27;
  background: #ffffff;
}

.mini-cat::before {
  left: 12px;
  border-radius: 80% 10% 30% 20%;
  transform: rotate(-18deg);
}

.mini-cat::after {
  right: 12px;
  border-radius: 10% 80% 20% 30%;
  transform: rotate(18deg);
}

.name-label {
  font-weight: 850;
  font-size: 1rem;
}

.name-input {
  min-height: 58px;
  width: 100%;
  border: 2px solid #2f2b27;
  border-radius: 16px;
  padding: 0 16px;
  background: #ffffff;
  font-size: 1.35rem;
  font-weight: 850;
}

.step-actions {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 12px;
  margin-top: auto;
}

.primary-button,
.ghost-button {
  min-height: 52px;
  border-radius: 16px;
  border: 2px solid #2f2b27;
  cursor: pointer;
  font-weight: 850;
}

.primary-button {
  background: #2ec4b6;
  color: #073b3a;
}

.ghost-button {
  background: #ffffff;
}

@keyframes floaty {
  0%,
  100% {
    transform: translateY(0) rotate(-2deg);
  }
  50% {
    transform: translateY(-14px) rotate(2deg);
  }
}

/* ── Vertical Size Slider ── */
#popoverBrushSize {
  -webkit-appearance: none;
  appearance: none;
  writing-mode: vertical-lr;
  direction: rtl;
  width: 6px;
  height: 120px;
  background: transparent;
  cursor: pointer;
  outline: none;
}

/* Track */
#popoverBrushSize::-webkit-slider-runnable-track {
  width: 6px;
  height: 120px;
  background: #e5e7eb;
  border-radius: 999px;
}
#popoverBrushSize::-moz-range-track {
  width: 6px;
  height: 120px;
  background: #e5e7eb;
  border-radius: 999px;
}

/* Thumb */
#popoverBrushSize::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: #6366f1;
  box-shadow: 0 2px 8px rgba(99,102,241,0.35);
  margin-left: -10px;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
#popoverBrushSize::-moz-range-thumb {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: #6366f1;
  box-shadow: 0 2px 8px rgba(99,102,241,0.35);
  border: none;
  cursor: pointer;
}
#popoverBrushSize::-webkit-slider-thumb:hover {
  transform: scale(1.15);
  box-shadow: 0 4px 14px rgba(99,102,241,0.45);
}
