/* SCALEWOVEN HAIR STUDIO & HAIR COLOR STORE
   Ultra-Luxury Dark Atelier Palette */

:root {
  --hair-bg: #121110;
  --hair-surface: #1a1816;
  --hair-card: #22201d;
  --hair-border: rgba(212, 175, 55, 0.22);
  --hair-border-subtle: rgba(255, 255, 255, 0.08);
  --hair-gold: #d4af37;
  --hair-gold-light: #f7e7b4;
  --hair-copper: #e07a38;
  --hair-wine: #9e2a47;
  --hair-text: #f4eee8;
  --hair-muted: #a39990;
  --hair-radius: 14px;
  --hair-font-heading: 'Italiana', Georgia, serif;
  --hair-font-sans: 'DM Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  --ambient-glow: rgba(212, 175, 55, 0.16);
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.35);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.5);
  --shadow-lg: 0 16px 48px rgba(0, 0, 0, 0.65);
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

[hidden] {
  display: none !important;
}

body {
  background-color: var(--hair-bg);
  color: var(--hair-text);
  font-family: var(--hair-font-sans);
  font-size: 14px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}

/* --------------------------------------------------------------------------
   SITE HEADER & NAVIGATION (72px Dark Studio Header)
   -------------------------------------------------------------------------- */
.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
  padding: 0 5.5%;
  background: rgba(18, 17, 16, 0.95);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--hair-border-subtle);
  position: sticky;
  top: 0;
  z-index: 100;
  gap: 24px;
}

.wordmark {
  font-family: var(--hair-font-heading);
  font-size: 1.6rem;
  letter-spacing: 0.08em;
  color: var(--hair-text);
  text-decoration: none;
  font-weight: 400;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.wordmark span,
.wordmark-dot {
  color: var(--hair-gold);
}

.header-divider {
  display: inline-block;
  width: 1px;
  height: 16px;
  background: var(--hair-border-subtle);
  margin: 0 4px;
}

.header-caption {
  font-size: 0.72rem;
  letter-spacing: 0.2em;
  color: var(--hair-muted);
  text-transform: uppercase;
  font-weight: 600;
}

.site-header nav {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 24px;
  font-size: 12px;
}

.site-header nav a {
  color: var(--hair-muted);
  text-decoration: none;
  letter-spacing: 0.03em;
  padding: 8px 0;
  transition: color 0.18s ease;
}

.site-header nav a:hover,
.site-header nav a.nav-active {
  color: var(--hair-text);
  border-bottom: 1px solid var(--hair-gold);
}

.nav-hub-link {
  color: var(--hair-gold) !important;
  font-weight: 600;
}

.nav-help-btn {
  background: none;
  border: 0;
  color: var(--hair-muted);
  font: inherit;
  font-size: 12px;
  cursor: pointer;
  padding: 8px 0;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: color 0.18s;
}

.nav-help-btn:hover {
  color: var(--hair-text);
}

/* --------------------------------------------------------------------------
   INTRO HERO SECTION
   -------------------------------------------------------------------------- */
.intro {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  padding: 44px 5.5% 24px;
  max-width: 1480px;
  margin: 0 auto;
}

.eyebrow {
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  color: var(--hair-gold);
  text-transform: uppercase;
  margin-bottom: 12px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 8px;
}

.eyebrow .asterisk {
  color: var(--hair-gold);
  font-size: 1rem;
  line-height: 1;
}

.intro h1 {
  font-family: var(--hair-font-heading);
  font-size: clamp(2.4rem, 4.5vw, 3.8rem);
  font-weight: 400;
  line-height: 1.06;
  color: var(--hair-text);
  letter-spacing: -0.02em;
  margin-bottom: 12px;
}

.intro h1 em {
  font-family: Georgia, serif;
  font-style: italic;
  font-weight: 400;
  color: var(--hair-gold-light);
}

.intro-copy {
  max-width: 620px;
  color: var(--hair-muted);
  font-size: 0.95rem;
  line-height: 1.65;
}

.intro-index {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  color: var(--hair-muted);
  text-transform: uppercase;
  gap: 4px;
  padding-bottom: 6px;
}

.intro-index span:first-child {
  color: var(--hair-gold);
  font-weight: 600;
}

/* --------------------------------------------------------------------------
   STUDIO RULE STEPS
   -------------------------------------------------------------------------- */
.studio-rule {
  display: flex;
  justify-content: space-between;
  padding: 12px 5.5%;
  border-top: 1px solid var(--hair-border-subtle);
  border-bottom: 1px solid var(--hair-border-subtle);
  font-size: 0.7rem;
  letter-spacing: 0.18em;
  color: var(--hair-muted);
  text-transform: uppercase;
  max-width: 1480px;
  margin: 0 auto 36px;
}

/* --------------------------------------------------------------------------
   MAIN WORKBENCH & 2-COLUMN GRID
   -------------------------------------------------------------------------- */
.workbench {
  display: grid;
  grid-template-columns: minmax(360px, 540px) 1fr;
  gap: 40px;
  align-items: start;
  max-width: 1480px;
  margin: 0 auto;
  padding: 0 5.5% 72px;
}

/* --------------------------------------------------------------------------
   LEFT COLUMN: STICKY INTERACTIVE PREVIEW
   -------------------------------------------------------------------------- */
.preview-column {
  position: sticky;
  top: 14px;
  max-height: calc(100dvh - 28px);
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.preview-column::-webkit-scrollbar {
  width: 4px;
}
.preview-column::-webkit-scrollbar-thumb {
  background: var(--hair-border-subtle);
  border-radius: 4px;
}

.preview-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.badge-status {
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  color: var(--hair-gold);
  background: rgba(212, 175, 55, 0.12);
  border: 1px solid var(--hair-border);
  padding: 4px 12px;
  border-radius: 100px;
  font-weight: 600;
}

/* Keep the portrait as the focus, matching the Face Studio preview. */
.preview-head, .preview-no, .preview-small, .preview-subdetail,
.preview-corner, .stage-instruction { display: none; }
.stage.preview-frame {
  border-radius: 14px;
  border-color: #e4d9d2;
  box-shadow: 0 16px 44px -8px rgba(45,25,34,.15);
}
.stage-zoom-bar {
  border-radius: 14px;
  background: #f7f1eb;
  border: 1px solid #e4d9d2;
}

/* STAGE PREVIEW FRAME (High-End Dark Studio Stage) */
.stage.preview-frame {
  position: relative;
  aspect-ratio: 1122 / 1402;
  max-height: clamp(480px, 72vh, 760px);
  border-radius: 16px;
  overflow: hidden;
  background: radial-gradient(circle at 50% 35%, #24201c 0%, #121110 100%);
  border: 1px solid var(--hair-border);
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.65), 0 0 32px var(--ambient-glow);
  transition: box-shadow 0.4s ease;
}

/* Face Studio photo controls: one status line, a right compare action, and round tools. */
.stage.preview-frame { border-radius: 14px; border-color: #e4d9d2; box-shadow: 0 16px 44px -8px rgba(45,25,34,.15); }
.stage-top { top: 22px; left: 24px; right: 24px; }
.stage-top .preview-label { padding: 0; border: 0; background: none; box-shadow: none; color: #fff; font-size: 10px; font-weight: 700; letter-spacing: .18em; text-shadow: 0 1px 3px #21191d; }
.stage .compare-btn { top: 56px; right: 20px; left: auto; padding: 6px 12px; background: rgba(41,29,35,.7); border-color: rgba(255,255,255,.3); color: #fff; font-size: 10px; font-weight: 700; }
.stage .stage-shine-btn { top: 56px; left: 20px; right: auto; width: 36px; height: 36px; padding: 0; border-radius: 50%; justify-content: center; background: rgba(41,29,35,.7); border-color: rgba(255,255,255,.3); color: #fff; }
.stage .stage-shine-btn span:last-child { display: none; }
.stage .stage-fullscreen-fab { right: 20px; bottom: 84px; background: rgba(41,29,35,.7); border-color: rgba(255,255,255,.3); color: #fff; }
.stage-bottom { left: 24px; right: 24px; bottom: 22px; color: #fff; }

@media (max-width: 600px) {
  #stage.stage:not(.is-stage-fullscreen):not(:fullscreen) {
    display: flex;
    flex-wrap: wrap;
    align-content: flex-end;
    justify-content: flex-start;
    gap: 6px;
    height: min(68svh, 360px);
    aspect-ratio: auto;
    padding: 10px;
    border-radius: 0 0 20px 20px !important;
    box-shadow: 0 8px 24px rgba(45,25,34,.18) !important;
  }
  #stage.stage:not(.is-stage-fullscreen):not(:fullscreen) canvas,
  #stage.stage:not(.is-stage-fullscreen):not(:fullscreen) .preview-shade { position: absolute; inset: 0; width: 100%; height: 100%; }
  #stage.stage:not(.is-stage-fullscreen):not(:fullscreen) > :is(.compare-btn,.stage-shine-btn,.stage-fullscreen-fab) {
    position: relative; inset: auto; z-index: 12; order: 2;
    width: 44px; min-width: 44px; height: 44px; min-height: 44px;
    flex: 0 0 44px; padding: 0; margin: 0; justify-content: center; border-radius: 50%;
  }
  #stage.stage:not(.is-stage-fullscreen):not(:fullscreen) .stage-fullscreen-fab { order: 1; }
  #stage.stage:not(.is-stage-fullscreen):not(:fullscreen) .compare-btn span { display: none; }
  #stage.stage:not(.is-stage-fullscreen):not(:fullscreen) .stage-top { top: 10px; left: 12px; right: 12px; }
  #stage.stage:not(.is-stage-fullscreen):not(:fullscreen) .stage-bottom { top: 36px; bottom: auto; left: 12px; right: 12px; }
  #stage.stage:not(.is-stage-fullscreen):not(:fullscreen) .stage-bottom strong { font-size: 18px; line-height: 1.1; }
}

.stage canvas {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Face Studio portrait frame and on-photo controls. */
#stage.stage.preview-frame { background: #c5ada2; border: 0; border-radius: 8px; max-height: none; box-shadow: none; }
#stage.stage.preview-frame::before { content: ''; position: absolute; inset: 12px; z-index: 2; border: 1px solid rgba(255,255,255,.35); border-radius: 2px; pointer-events: none; }
#stage.stage.preview-frame canvas { object-fit: contain; }
#stage.stage.preview-frame .preview-shade { background: linear-gradient(to bottom, rgba(27,14,21,.34), transparent 15%, transparent 87%, rgba(27,14,21,.25)); z-index: 1; }
#stage.stage.preview-frame .stage-top { z-index: 3; }
#stage.stage.preview-frame .preview-no { display: inline; color: #fff; font-size: 9px; letter-spacing: .18em; font-weight: 700; text-shadow: 0 1px 3px #241b20; }
#stage.stage.preview-frame .compare-btn { z-index: 4; }
#stage.stage.preview-frame .stage-shine-btn { top: auto; left: auto; right: 20px; bottom: 126px; z-index: 4; width: 36px; height: 36px; }
#stage.stage.preview-frame .stage-fullscreen-fab { z-index: 4; }
#stage.stage.preview-frame .stage-bottom { z-index: 3; bottom: 12px; left: 16px; right: 16px; }
#stage.stage.preview-frame .stage-bottom strong { font: 400 clamp(18px,2vw,26px)/1 var(--display); text-transform: none; }
@media (max-width: 600px) {
  #stage.stage.preview-frame:not(.is-stage-fullscreen):not(:fullscreen) { display: block; width: 100%; height: auto; aspect-ratio: 1122 / 1402; padding: 0; border-radius: 8px !important; }
  #stage.stage.preview-frame:not(.is-stage-fullscreen):not(:fullscreen) > :is(.compare-btn,.stage-shine-btn,.stage-fullscreen-fab) { position: absolute; margin: 0; }
  #stage.stage.preview-frame:not(.is-stage-fullscreen):not(:fullscreen) .compare-btn { top: 56px; right: 20px; left: auto; width: auto; min-width: 0; height: auto; min-height: 0; padding: 6px 12px; border-radius: 20px; }
  #stage.stage.preview-frame:not(.is-stage-fullscreen):not(:fullscreen) .compare-btn span { display: inline; }
  #stage.stage.preview-frame:not(.is-stage-fullscreen):not(:fullscreen) .stage-shine-btn { inset: auto 20px 126px auto; width: 36px; min-width: 36px; height: 36px; min-height: 36px; }
  #stage.stage.preview-frame:not(.is-stage-fullscreen):not(:fullscreen) .stage-fullscreen-fab { inset: auto 20px 84px auto; width: 36px; min-width: 36px; height: 36px; min-height: 36px; }
  #stage.stage.preview-frame:not(.is-stage-fullscreen):not(:fullscreen) .stage-top { top: 22px; left: 24px; right: 24px; }
  #stage.stage.preview-frame:not(.is-stage-fullscreen):not(:fullscreen) .stage-bottom { top: auto; bottom: 12px; left: 16px; right: 16px; }
}

.preview-shade {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: none;
}

/* TOP OVERLAY STATUS */
.stage-top {
  position: absolute;
  top: 14px;
  left: 16px;
  right: 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  pointer-events: none;
  z-index: 10;
}

.preview-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  color: var(--hair-gold-light);
  background: rgba(18, 17, 16, 0.85);
  padding: 5px 12px;
  border-radius: 100px;
  border: 1px solid rgba(212, 175, 55, 0.3);
  backdrop-filter: blur(8px);
  box-shadow: var(--shadow-sm);
  font-weight: 500;
  max-width: 90%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.preview-label span:last-child {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.live-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #2dd4bf;
  box-shadow: 0 0 8px #2dd4bf;
  animation: beaconPulse 2s infinite ease-in-out;
  flex-shrink: 0;
}

@keyframes beaconPulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(0.85); }
}

.preview-no {
  display: none;
}

/* OVERLAID STAGE ACTIONS */
.compare-btn {
  position: absolute;
  top: 50px;
  left: 16px;
  z-index: 10;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: rgba(18, 17, 16, 0.85);
  border: 1px solid var(--hair-border);
  color: var(--hair-text);
  padding: 6px 14px;
  border-radius: 100px;
  font-size: 0.72rem;
  letter-spacing: 0.05em;
  cursor: pointer;
  backdrop-filter: blur(8px);
  box-shadow: var(--shadow-sm);
  transition: background 0.18s, border-color 0.18s, transform 0.18s;
}

.compare-btn:hover {
  background: rgba(212, 175, 55, 0.2);
  border-color: var(--hair-gold);
  transform: translateY(-1px);
}

.compare-btn.is-active,
.compare-btn[aria-pressed="true"] {
  background: var(--hair-gold);
  color: #111;
  border-color: var(--hair-gold);
  font-weight: 600;
}

.compare-btn svg {
  width: 14px;
  height: 14px;
}

.stage-shine-btn {
  position: absolute;
  top: 50px;
  right: 16px;
  z-index: 10;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(18, 17, 16, 0.85);
  border: 1px solid rgba(212, 175, 55, 0.35);
  color: var(--hair-gold-light);
  padding: 6px 14px;
  border-radius: 100px;
  font-size: 0.72rem;
  cursor: pointer;
  backdrop-filter: blur(8px);
  box-shadow: var(--shadow-sm);
  transition: all 0.18s ease;
}

.stage-shine-btn:hover {
  background: rgba(212, 175, 55, 0.25);
  transform: translateY(-1px);
}

.stage-shine-btn .shine-icon {
  color: var(--hair-gold);
  font-size: 1rem;
}

.stage-fullscreen-fab {
  position: absolute;
  bottom: 16px;
  right: 18px;
  z-index: 10;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(18, 17, 16, 0.85);
  border: 1px solid var(--hair-border);
  color: var(--hair-text);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  backdrop-filter: blur(8px);
  box-shadow: var(--shadow-sm);
  transition: transform 0.18s, background 0.18s;
}

.stage-fullscreen-fab:hover {
  background: rgba(212, 175, 55, 0.25);
  border-color: var(--hair-gold);
  transform: scale(1.08);
}

.stage-fullscreen-fab svg {
  width: 16px;
  height: 16px;
}

.stage-fullscreen-fab svg[hidden],
.stage-fullscreen-fab svg.is-hidden {
  display: none !important;
}

.stage-action-tooltip {
  position: absolute;
  right: calc(100% + 10px);
  top: 50%;
  transform: translateY(-50%);
  background: rgba(18, 17, 16, 0.95);
  border: 1px solid var(--hair-border-subtle);
  padding: 4px 8px;
  font-size: 11px;
  color: #fff;
  border-radius: 4px;
  white-space: nowrap;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.15s;
}

.stage-fullscreen-fab:hover .stage-action-tooltip {
  opacity: 1;
}

/* HAIR ZONE FOCUS BAR */
.hair-zone-nav {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--hair-surface);
  padding: 6px 12px;
  border-radius: 12px;
  border: 1px solid var(--hair-border-subtle);
}

.zone-nav-label {
  display: none;
}

.zone-nav-buttons {
  display: flex;
  justify-content: space-between;
  width: 100%;
  gap: 6px;
}

.zone-btn {
  background: transparent;
  border: 1px solid transparent;
  color: var(--hair-muted);
  font-size: 0.72rem;
  padding: 6px 12px;
  border-radius: 8px;
  cursor: pointer;
  white-space: nowrap;
  font-weight: 500;
  transition: all 0.18s ease;
}

.zone-btn:hover {
  background: rgba(255, 255, 255, 0.08);
  color: var(--hair-text);
}

.zone-btn.is-active,
.zone-btn[aria-pressed="true"] {
  background: rgba(212, 175, 55, 0.2);
  border-color: var(--hair-gold);
  color: var(--hair-gold-light);
  font-weight: 600;
  box-shadow: var(--shadow-sm);
}

/* BOTTOM STAGE META */
.stage-bottom {
  display: none;
}

/* STAGE ZOOM TOOLBAR */
.stage-zoom-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--hair-surface);
  padding: 10px 16px;
  border-radius: var(--hair-radius);
  border: 1px solid var(--hair-border-subtle);
  box-shadow: var(--shadow-sm);
}

.zoom-btn {
  width: 28px;
  height: 28px;
  border-radius: 6px;
  background: var(--hair-card);
  border: 1px solid var(--hair-border-subtle);
  color: var(--hair-text);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 1rem;
  transition: all 0.18s ease;
}

.zoom-btn:hover {
  background: rgba(212, 175, 55, 0.15);
  border-color: var(--hair-gold);
}

.zoom-slider-wrap {
  flex: 1;
  display: flex;
  align-items: center;
}

.stage-zoom-slider {
  width: 100%;
  accent-color: var(--hair-gold);
  cursor: pointer;
}

.zoom-level-badge {
  font-size: 0.72rem;
  padding: 4px 8px;
  border-radius: 6px;
  background: var(--hair-card);
  border: 1px solid var(--hair-border-subtle);
  color: var(--hair-gold-light);
  font-weight: 600;
  cursor: pointer;
}

.stage-quick-actions {
  display: flex;
  gap: 8px;
  margin-left: auto;
}

.quick-btn {
  background: var(--hair-card);
  border: 1px solid var(--hair-border-subtle);
  color: var(--hair-text);
  font-size: 0.74rem;
  padding: 6px 12px;
  border-radius: 8px;
  cursor: pointer;
  letter-spacing: 0.04em;
  font-weight: 500;
  transition: all 0.18s ease;
}

.quick-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: var(--hair-gold);
}

.quick-btn.is-accent {
  background: rgba(212, 175, 55, 0.18);
  border-color: var(--hair-border);
  color: var(--hair-gold-light);
  font-weight: 600;
}

.quick-btn.is-accent:hover {
  background: var(--hair-gold);
  color: #111;
}

.stage-instruction {
  font-size: 0.76rem;
  color: var(--hair-muted);
  text-align: center;
  font-style: italic;
}

/* CHEMICAL SUMMARY CARD */
.chemical-summary-card {
  background: var(--hair-surface);
  border: 1px solid var(--hair-border);
  border-radius: var(--hair-radius);
  padding: 16px 20px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  box-shadow: var(--shadow-sm);
}

.chem-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.chem-title {
  font-size: 0.74rem;
  letter-spacing: 0.12em;
  color: var(--hair-gold-light);
  text-transform: uppercase;
  font-weight: 700;
}

.chem-badge {
  font-size: 0.68rem;
  padding: 3px 10px;
  border-radius: 100px;
  letter-spacing: 0.05em;
  font-weight: 600;
}

.chem-badge.is-deposit {
  background: rgba(45, 212, 191, 0.15);
  color: #2dd4bf;
  border: 1px solid rgba(45, 212, 191, 0.35);
}

.chem-badge.is-medium-lift {
  background: rgba(212, 175, 55, 0.15);
  color: var(--hair-gold-light);
  border: 1px solid rgba(212, 175, 55, 0.35);
}

.chem-badge.is-high-lift {
  background: rgba(248, 113, 113, 0.15);
  color: #f87171;
  border: 1px solid rgba(248, 113, 113, 0.35);
}

.chem-meter-track {
  height: 6px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  overflow: hidden;
}

.chem-meter-fill {
  height: 100%;
  background: linear-gradient(90deg, #2dd4bf 0%, var(--hair-gold) 60%, #f87171 100%);
  border-radius: 10px;
  transition: width 0.3s ease;
}

.chem-text {
  font-size: 0.76rem;
  color: var(--hair-muted);
  line-height: 1.5;
}

.chem-text strong {
  color: var(--hair-text);
}

/* --------------------------------------------------------------------------
   RIGHT COLUMN: SCROLLABLE ATELIER PANELS
   -------------------------------------------------------------------------- */
.editor-column {
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.editor-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  border-bottom: 1px solid var(--hair-border-subtle);
  padding-bottom: 14px;
}

.editor-head h2 {
  font-family: var(--hair-font-heading);
  font-size: 2.2rem;
  font-weight: 400;
  line-height: 1.15;
  color: var(--hair-text);
}

.editor-head h2 em {
  font-style: italic;
  color: var(--hair-gold-light);
}

.editor-subhead {
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  color: var(--hair-muted);
  text-transform: uppercase;
}

/* SECTION CONTAINERS (Rich Dark Surface Cards) */
.editor-section {
  background: var(--hair-surface);
  border: 1px solid var(--hair-border-subtle);
  border-radius: var(--hair-radius);
  padding: 24px;
  box-shadow: var(--shadow-sm);
  transition: border-color 0.2s, box-shadow 0.2s;
}

.editor-section:focus-within {
  border-color: var(--hair-border);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
}

.section-heading {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 6px;
}

.section-heading > span:first-child {
  font-family: var(--hair-font-heading);
  font-size: 1.15rem;
  color: var(--hair-gold);
  background: rgba(212, 175, 55, 0.12);
  padding: 2px 8px;
  border-radius: 6px;
  font-weight: 600;
  line-height: 1.2;
}

.section-heading h3 {
  font-size: 1.12rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--hair-text);
}

.section-heading > span:last-child {
  margin-left: auto;
  font-size: 0.68rem;
  letter-spacing: 0.16em;
  color: var(--hair-muted);
  text-transform: uppercase;
}

.section-desc {
  font-size: 0.84rem;
  color: var(--hair-muted);
  margin-bottom: 18px;
  line-height: 1.5;
}

/* --------------------------------------------------------------------------
   01 / CANVAS & BASE LEVEL
   -------------------------------------------------------------------------- */
.source-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 18px;
}

.source-tabs button {
  flex: 1;
  background: var(--hair-card);
  border: 1px solid var(--hair-border-subtle);
  color: var(--hair-muted);
  padding: 10px 16px;
  border-radius: 8px;
  font-size: 0.8rem;
  letter-spacing: 0.04em;
  cursor: pointer;
  font-weight: 500;
  transition: all 0.18s ease;
}

.source-tabs button:hover {
  color: var(--hair-text);
  background: rgba(255, 255, 255, 0.08);
}

.source-tabs button.is-active,
.source-tabs button[aria-pressed="true"] {
  background: rgba(212, 175, 55, 0.18);
  border-color: var(--hair-border);
  color: var(--hair-gold-light);
  font-weight: 600;
  box-shadow: var(--shadow-sm);
}

.source-options[hidden] { display: none !important; }
.source-options .photo-source-button {
  min-height: 44px;
  padding: 10px 18px;
  border: 1px solid var(--hair-border);
  border-radius: 8px;
  background: var(--hair-card);
  color: var(--hair-text);
  font: inherit;
  font-size: 0.82rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.18s ease;
}
.source-options .photo-source-button:hover {
  border-color: var(--hair-gold);
  color: var(--hair-gold-light);
}
.source-options .source-help,
.hair-source-status {
  max-width: 56ch;
  color: var(--hair-muted);
  font-size: 12px;
  line-height: 1.55;
}
.hair-source-status:empty { display: none; }

.sample-row {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 12px 0;
  border-top: 1px solid var(--hair-border-subtle);
}

.row-label {
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  color: var(--hair-muted);
  text-transform: uppercase;
}

.model-options {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.model-pill {
  background: var(--hair-card);
  border: 1px solid var(--hair-border-subtle);
  color: var(--hair-muted);
  padding: 7px 16px;
  border-radius: 100px;
  font-size: 0.75rem;
  cursor: pointer;
  font-weight: 500;
  transition: all 0.18s ease;
}

.model-pill:hover {
  color: var(--hair-text);
}

.model-pill.is-active,
.model-pill[aria-pressed="true"] {
  background: rgba(212, 175, 55, 0.18);
  border-color: var(--hair-gold);
  color: var(--hair-gold-light);
  font-weight: 600;
  box-shadow: 0 0 0 1px var(--hair-gold);
}

.level-slider-wrap {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.slider-label-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.slider-val {
  font-size: 0.8rem;
  color: var(--hair-gold-light);
  font-weight: 600;
}

.customizer-slider {
  width: 100%;
  accent-color: var(--hair-gold);
  cursor: pointer;
}

.level-scale-ticks {
  display: flex;
  justify-content: space-between;
  font-size: 0.65rem;
  color: var(--hair-muted);
}

/* --------------------------------------------------------------------------
   02 / COLOR PLACEMENT TECHNIQUES
   -------------------------------------------------------------------------- */
.technique-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 10px;
}

.technique-card {
  background: var(--hair-card);
  border: 1px solid var(--hair-border-subtle);
  border-radius: 12px;
  padding: 14px;
  text-align: left;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 4px;
  transition: all 0.2s ease;
  color: var(--hair-text);
  box-shadow: var(--shadow-sm);
}

.technique-card:hover {
  border-color: var(--hair-gold);
  background: rgba(35, 32, 29, 0.95);
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4);
}

.technique-card.is-active,
.technique-card[aria-pressed="true"] {
  border-color: var(--hair-gold);
  background: linear-gradient(145deg, rgba(212, 175, 55, 0.15) 0%, rgba(35, 32, 29, 0.95) 100%);
  box-shadow: 0 0 16px rgba(212, 175, 55, 0.2);
}

.tech-icon,
.tech-tag {
  display: none;
}

.tech-title {
  font-size: 0.88rem;
  color: var(--hair-text);
  font-weight: 600;
}

.tech-desc {
  font-size: 0.74rem;
  color: var(--hair-muted);
  line-height: 1.4;
}

/* --------------------------------------------------------------------------
   03 / HAIR COLOR STORE & SHADES
   -------------------------------------------------------------------------- */
.shade-filter-bar {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 8px;
  margin-bottom: 16px;
}

.shade-filter-btn {
  background: var(--hair-card);
  border: 1px solid var(--hair-border-subtle);
  color: var(--hair-muted);
  padding: 6px 14px;
  border-radius: 100px;
  font-size: 0.74rem;
  cursor: pointer;
  white-space: nowrap;
  font-weight: 500;
  transition: all 0.18s ease;
}

.shade-filter-btn:hover {
  color: var(--hair-text);
}

.shade-filter-btn.is-active,
.shade-filter-btn[aria-pressed="true"] {
  background: rgba(212, 175, 55, 0.18);
  border-color: var(--hair-gold);
  color: var(--hair-gold-light);
  font-weight: 600;
}

.shades-catalog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(105px, 1fr));
  gap: 10px;
}

.shade-card {
  background: var(--hair-card);
  border: 1px solid var(--hair-border-subtle);
  border-radius: 10px;
  padding: 8px;
  text-align: left;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 8px;
  transition: all 0.2s ease;
  position: relative;
  box-shadow: var(--shadow-sm);
}

.shade-card:hover {
  border-color: var(--hair-gold);
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.4);
}

.shade-card.is-active,
.shade-card[aria-pressed="true"] {
  border-color: var(--hair-gold);
  background: rgba(212, 175, 55, 0.12);
  box-shadow: 0 0 14px rgba(212, 175, 55, 0.25);
}

.shade-swatch {
  height: 42px;
  border-radius: 6px;
  background: var(--swatch);
  border: 1px solid rgba(255, 255, 255, 0.12);
  position: relative;
  overflow: hidden;
}

.shade-swatch::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 40%;
  background: linear-gradient(180deg, rgba(255,255,255,0.3) 0%, transparent 100%);
}

.shade-meta {
  min-height: 2.5em;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.shade-level-badge {
  font-size: 0.62rem;
  letter-spacing: 0.14em;
  color: var(--hair-gold);
  font-weight: 700;
  text-transform: uppercase;
}

.shade-title {
  font-size: 0.76rem;
  font-weight: 600;
  color: var(--hair-text);
  line-height: 1.3;
}

.shade-tone-code {
  font-size: 0.68rem;
  color: var(--hair-muted);
}

/* --------------------------------------------------------------------------
   04 / BESPOKE COLOR FORMULATOR WORKBENCH
   -------------------------------------------------------------------------- */
.advanced-settings {
  background: var(--hair-surface);
  border: 1px solid var(--hair-border-subtle);
  border-radius: var(--hair-radius);
}

.advanced-settings > summary {
  cursor: pointer;
  padding: 20px 24px;
  font-weight: 600;
  color: var(--hair-text);
}

.advanced-settings > summary span {
  display: block;
  padding: 5px 0 0 18px;
  color: var(--hair-muted);
  font-size: 0.78rem;
  font-weight: 400;
}

.advanced-settings > summary:focus-visible,
.shade-card:focus-visible,
.technique-card:focus-visible {
  outline: 2px solid var(--hair-gold);
  outline-offset: 3px;
}

.advanced-content {
  display: grid;
  gap: 12px;
  padding: 0 16px 16px;
}

.advanced-note {
  color: var(--hair-muted);
  font-size: 0.78rem;
  line-height: 1.5;
  margin: 6px 0 10px;
}

#catalog-section .form-group {
  margin-top: 20px;
}

.customizer-form {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.form-label {
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  color: var(--hair-muted);
  text-transform: uppercase;
  font-weight: 600;
}

.tone-buttons-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 8px;
}

.tone-btn {
  background: var(--hair-card);
  border: 1px solid var(--hair-border-subtle);
  border-radius: 8px;
  padding: 8px 12px;
  color: var(--hair-muted);
  font-size: 0.74rem;
  cursor: pointer;
  text-align: left;
  font-weight: 500;
  transition: all 0.18s ease;
}

.tone-btn:hover {
  color: var(--hair-text);
  background: rgba(255, 255, 255, 0.08);
}

.tone-btn.is-active,
.tone-btn[aria-pressed="true"] {
  background: rgba(212, 175, 55, 0.18);
  border-color: var(--hair-gold);
  color: var(--hair-gold-light);
  font-weight: 600;
}

.developer-options {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.dev-pill {
  background: var(--hair-card);
  border: 1px solid var(--hair-border-subtle);
  border-radius: 100px;
  padding: 6px 14px;
  color: var(--hair-muted);
  font-size: 0.74rem;
  cursor: pointer;
  font-weight: 500;
  transition: all 0.18s ease;
}

.dev-pill:hover {
  color: var(--hair-text);
}

.dev-pill.is-active,
.dev-pill[aria-pressed="true"] {
  background: rgba(212, 175, 55, 0.18);
  border-color: var(--hair-gold);
  color: var(--hair-gold-light);
  font-weight: 600;
}

/* --------------------------------------------------------------------------
   05 / TEXTURE & LUSTRE FINISH
   -------------------------------------------------------------------------- */
.texture-options-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.texture-btn {
  background: var(--hair-card);
  border: 1px solid var(--hair-border-subtle);
  border-radius: 12px;
  padding: 14px 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 4px;
  cursor: pointer;
  color: var(--hair-text);
  box-shadow: var(--shadow-sm);
  transition: all 0.18s ease;
}

.texture-btn:hover {
  border-color: var(--hair-gold);
}

.texture-btn.is-active,
.texture-btn[aria-pressed="true"] {
  background: rgba(212, 175, 55, 0.16);
  border-color: var(--hair-gold);
}

.tex-icon {
  font-size: 1.2rem;
  color: var(--hair-gold);
}

.texture-btn strong {
  font-size: 0.82rem;
  color: var(--hair-text);
}

.texture-btn span {
  font-size: 0.68rem;
  color: var(--hair-muted);
  line-height: 1.35;
}

/* --------------------------------------------------------------------------
   06 / STYLIST FORMULATION BRIEF
   -------------------------------------------------------------------------- */
.formulation-card {
  background: var(--hair-card);
  border: 1px solid var(--hair-border);
  border-radius: 12px;
  padding: 20px;
  margin-bottom: 20px;
  box-shadow: var(--shadow-sm);
}

.form-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--hair-border-subtle);
  padding-bottom: 12px;
  margin-bottom: 14px;
}

.form-client-title {
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  color: var(--hair-gold);
  font-weight: 700;
  text-transform: uppercase;
}

.form-id-badge {
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  color: var(--hair-muted);
}

.form-card-body {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.form-row {
  display: flex;
  justify-content: space-between;
  font-size: 0.78rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
  padding-bottom: 8px;
}

.f-label {
  color: var(--hair-muted);
}

.form-row strong {
  color: var(--hair-gold-light);
  text-align: right;
  max-width: 60%;
}

.concierge-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.btn-concierge-copy,
.btn-concierge-export {
  padding: 12px 18px;
  border-radius: 10px;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: all 0.18s ease;
}

.btn-concierge-copy {
  background: var(--hair-card);
  border: 1px solid var(--hair-border);
  color: var(--hair-gold-light);
  box-shadow: var(--shadow-sm);
}

.btn-concierge-copy:hover {
  background: rgba(212, 175, 55, 0.2);
}

.btn-concierge-export {
  background: var(--hair-gold);
  border: 1px solid var(--hair-gold);
  color: #111;
}

.btn-concierge-export:hover {
  background: var(--hair-gold-light);
}

/* --------------------------------------------------------------------------
   FOOTER
   -------------------------------------------------------------------------- */
.site-footer {
  border-top: 1px solid var(--hair-border-subtle);
  padding: 32px 5.5%;
  background: #100f0e;
  color: var(--hair-muted);
  margin-top: 48px;
}

.footer-inner {
  max-width: 1480px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.footer-wordmark {
  font-family: var(--hair-font-heading);
  letter-spacing: 0.16em;
  color: var(--hair-gold);
  font-size: 0.85rem;
}

.footer-copy {
  color: var(--hair-muted);
  font-size: 0.75rem;
}

/* --------------------------------------------------------------------------
   MOBILE RESPONSIVENESS & STICKY STAGE PINNED TO TOP
   -------------------------------------------------------------------------- */
@media (max-width: 900px) {
  .site-header {
    padding: 0 16px;
    height: 64px;
  }
  .site-header nav {
    display: none;
  }

  .intro {
    padding: 24px 16px 16px;
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }
  .intro h1 {
    font-size: 2.2rem;
  }
  .intro-index {
    align-items: flex-start;
  }

  .studio-rule {
    padding: 10px 16px;
    font-size: 0.62rem;
    flex-wrap: wrap;
    gap: 8px 16px;
  }

  .workbench {
    display: flex;
    flex-direction: column;
    padding: 0 16px 48px;
    gap: 20px;
  }

  .preview-column {
    display: contents !important;
  }

  #stage.stage {
    position: relative !important;
    top: auto !important;
    z-index: 1 !important;
    max-height: none !important;
    width: 100%;
    border-radius: 16px !important;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.6) !important;
    order: 1 !important;
  }

  .hair-zone-nav {
    order: 2;
    width: 100%;
  }

  .preview-toolbar {
    order: 3;
    width: 100%;
  }

  .stage-instruction {
    order: 4;
    width: 100%;
  }

  .chemical-summary-card {
    order: 5;
  }

  .source-panel {
    order: 0;
  }

  .editor-column {
    order: 6;
    width: 100%;
    min-width: 0;
  }

  .editor-head {
    min-width: 0;
    gap: 12px;
  }

  .editor-subhead {
    display: none;
  }

  .concierge-actions {
    grid-template-columns: 1fr;
  }

  .texture-options-grid {
    grid-template-columns: 1fr;
  }

  .shades-catalog-grid {
    grid-template-columns: repeat(auto-fill, minmax(90px, 1fr));
  }

  .advanced-settings > summary {
    padding: 18px;
  }

  .section-heading > span:last-child {
    font-size: 0.6rem;
    letter-spacing: 0.08em;
  }
}
