/* Cores Ano Novo 2027 — Programa-Inspired Architectural Studio UI */

:root {
  /* Warm-stone neutral scale (Programa DNA) */
  --bg-base: #ffffff;
  --bg-soft: #fcfbf9;
  --bg-inset: #f8f6f3;
  --bg-section: #eeece6;
  --bg-detail: #dddad3;
  --bg-dark: #1a1916;
  --bg-dark-card: #23221f;
  --bg-dark-elevated: #2b2926;

  /* Ink hierarchy */
  --ink: #1a1916;
  --ink-secondary: #45403a;
  --ink-muted: #7b736c;
  --ink-subtle: #9a948c;
  --ink-on-dark: #ffffff;
  --ink-on-dark-muted: #b8b2a8;

  /* Hairlines & Borders */
  --border: #eeece6;
  --border-hairline: rgba(0, 0, 0, 0.08);
  --border-strong: rgba(26, 25, 22, 0.16);
  --border-dark: rgba(255, 255, 255, 0.12);

  /* Signature Programa Accents */
  --yellow: #fdffa2;
  --yellow-hover: #f2f58a;
  --yellow-border: rgba(204, 202, 136, 0.95);
  --mint-bg: #dff0ee;
  --mint-border: #5a948f;
  --mint-ink: #164441;

  /* Semantic Status (subtle studio tints) */
  --ok-bg: #e7f6ee;
  --ok-border: #b3e2c8;
  --ok-ink: #0f5132;
  --warn-bg: #fff6df;
  --warn-border: #ebd18a;
  --warn-ink: #7c4a03;
  --err-bg: #ffe9ec;
  --err-border: #f5b5be;
  --err-ink: #881337;

  /* Micro-radius restraint */
  --radius-btn: 6px;
  --radius-card: 8px;
  --radius-surface: 12px;

  /* Programa Tactile Shadows */
  --shadow-hairline: 0 0 0 1px rgba(0, 0, 0, 0.08), 0 1px 2px 0 rgba(0, 0, 0, 0.08);
  --shadow-btn-dark: 0 0 0 1px #18181b, 0 1px 2px 0 rgba(0, 0, 0, 0.36), inset 0 0.75px 0 0 rgba(255, 255, 255, 0.22);
  --shadow-btn-yellow: 0 0 0 1px rgba(212, 209, 128, 0.92), 0 1px 2px 0 rgba(0, 0, 0, 0.16), inset 0 0.75px 0 0 rgba(255, 255, 255, 0.45);
  --shadow-card-hover: 0 8px 18px rgba(26, 25, 22, 0.08), 0 0 0 1px rgba(0, 0, 0, 0.12);
  --shadow-surface: 0 2px 10px rgba(0, 0, 0, 0.07), 0 1px 2px -1px rgba(0, 0, 0, 0.06), 0 0 0 1px rgba(0, 0, 0, 0.08);
  --shadow-float: 0 0 0 1px rgba(0, 0, 0, 0.08), 0 8px 20px rgba(26, 25, 22, 0.09);

  /* Typography Triplet */
  --font-serif: "Newsreader", Georgia, "Times New Roman", serif;
  --font-sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-mono: "Roboto Mono", ui-monospace, SFMono-Regular, Menlo, monospace;

  --max-w: 1180px;
}

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

[hidden] {
  display: none !important;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg-base);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

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

a {
  color: var(--ink);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

a:hover {
  color: var(--ink-secondary);
}

button,
input,
select {
  font-family: inherit;
}

:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 2px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.container {
  width: 100%;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 28px;
}

.mono-label {
  font-family: var(--font-mono);
  font-size: 11.5px;
  font-weight: 500;
  line-height: 1.5;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--ink-muted);
}

/* ==========================================================================
   HEADER — Transparent studio top bar -> floating frosted compact dock
   ========================================================================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  padding: 12px 20px;
  pointer-events: none;
  transition: transform 0.24s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.2s ease;
}

.site-header.is-hidden {
  transform: translateY(-115%);
  opacity: 0;
}

.site-header.is-hidden .header-dock {
  pointer-events: none;
}

.header-dock {
  pointer-events: auto;
  width: 100%;
  max-width: var(--max-w);
  margin: 0 auto;
  min-height: 54px;
  padding: 8px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border-radius: var(--radius-surface);
  background: rgba(255, 255, 255, 0.86);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  box-shadow: var(--shadow-float);
  transition: max-width 0.22s ease, background-color 0.22s ease;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  text-decoration: none;
  color: var(--ink);
  font-weight: 600;
  font-size: 14.5px;
  letter-spacing: -0.01em;
  white-space: nowrap;
}

.brand-mark {
  width: 22px;
  height: 22px;
  border-radius: 5px;
  background: var(--ink);
  display: inline-grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: 1fr 1fr;
  gap: 2px;
  padding: 3px;
  flex-shrink: 0;
}

.brand-mark span {
  display: block;
  border-radius: 2px;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 20px;
  font-size: 13.5px;
}

.site-nav a {
  color: var(--ink-secondary);
  text-decoration: none;
  font-weight: 500;
  white-space: nowrap;
  transition: color 0.14s ease;
}

.site-nav a:hover {
  color: var(--ink);
}

.nav-divider {
  width: 1px;
  height: 16px;
  background: var(--border-strong);
  display: inline-block;
}

.nav-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 30px;
  padding: 0 11px;
  border-radius: var(--radius-btn);
  background: var(--mint-bg);
  border: 1px solid var(--mint-border);
  color: var(--mint-ink) !important;
  font-size: 13px;
  font-weight: 500 !important;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06);
  transition: background-color 0.14s ease, transform 0.1s ease;
}

.nav-cta:hover {
  background: #cfe7e4;
}

/* ==========================================================================
   BUTTONS — Sharp 6px corners, tactile inset shadows (Programa signature)
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 36px;
  padding: 0 14px;
  border-radius: var(--radius-btn);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: -0.005em;
  border: none;
  cursor: pointer;
  text-decoration: none;
  white-space: nowrap;
  transition: background-color 0.15s ease, box-shadow 0.15s ease, transform 0.1s ease, color 0.15s ease;
}

.btn:active {
  transform: translateY(1px);
}

.btn-primary {
  background: var(--ink);
  color: #ffffff;
  box-shadow: var(--shadow-btn-dark);
}

.btn-primary:hover {
  background: #2b2926;
  color: #ffffff;
}

.btn-secondary {
  background: #ffffff;
  color: var(--ink);
  box-shadow: var(--shadow-hairline);
}

.btn-secondary:hover {
  background: var(--bg-inset);
  color: var(--ink);
}

.btn-yellow {
  background: var(--yellow);
  color: var(--ink);
  box-shadow: var(--shadow-btn-yellow);
  font-weight: 500;
}

.btn-yellow:hover {
  background: var(--yellow-hover);
  color: var(--ink);
}

.btn-dark-outline {
  background: var(--bg-dark-card);
  color: #ffffff;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.18), 0 1px 2px rgba(0, 0, 0, 0.35);
}

.btn-dark-outline:hover {
  background: var(--bg-dark-elevated);
  color: #ffffff;
}

.btn-ghost {
  background: transparent;
  color: var(--ink-muted);
  box-shadow: 0 0 0 1px var(--border-hairline);
  min-height: 32px;
  padding: 0 11px;
  font-size: 13px;
}

.btn-ghost:hover {
  background: var(--bg-soft);
  color: var(--ink);
}

/* ==========================================================================
   HERO — Clean White Cotton Cloth + Colorful Stitched Fabric Patchwork
   ========================================================================== */
.hero {
  position: relative;
  overflow: clip;
  padding: 52px 0 44px;
  background: radial-gradient(ellipse 90% 75% at 50% 18%, #ffffff 0%, #fcfbf8 62%, #f7f4ee 100%);
  border-bottom: 1px solid var(--border);
}

.hero .container {
  position: relative;
  z-index: 4;
}

/* Colorful tactile fabric patches scattered across the white cloth */
.hero-patchwork {
  position: absolute;
  inset: 0;
  max-width: 1520px;
  margin: 0 auto;
  pointer-events: none;
  z-index: 3;
}

.patch {
  position: absolute;
  padding: 0;
  border: none;
  background: transparent;
  cursor: pointer;
  pointer-events: auto;
  transition: transform 0.24s cubic-bezier(0.22, 1, 0.36, 1), filter 0.24s ease, box-shadow 0.24s ease;
}

.patch-frayed img {
  display: block;
  width: 100%;
  height: auto;
  user-select: none;
  -webkit-user-drag: none;
}

/* Stitched fabric patches (real macro textures + dashed sewing thread border) */
.patch-sewn {
  border-radius: 4px;
  background-size: cover;
  background-position: center;
  box-shadow:
    0 12px 24px rgba(26, 25, 22, 0.16),
    0 2px 5px rgba(26, 25, 22, 0.1),
    inset 0 0 0 1px rgba(26, 25, 22, 0.1);
}

.patch-sewn::after {
  content: "";
  position: absolute;
  inset: 6px;
  border-radius: 2px;
  border: 1.5px dashed rgba(255, 255, 255, 0.62);
  pointer-events: none;
}

.patch-sewn:hover {
  transform: rotate(0deg) scale(1.07) !important;
  box-shadow:
    0 18px 32px rgba(26, 25, 22, 0.22),
    0 4px 10px rgba(26, 25, 22, 0.12),
    inset 0 0 0 1px rgba(26, 25, 22, 0.12);
  z-index: 8;
}

/* Left patchwork cluster */
.patch-linen {
  top: -14px;
  left: -26px;
  width: 176px;
  transform: rotate(-8deg);
  filter: drop-shadow(0 12px 18px rgba(26, 25, 22, 0.15));
}

.patch-linen:hover {
  transform: rotate(-1deg) scale(1.06);
  filter: drop-shadow(0 18px 26px rgba(26, 25, 22, 0.22));
}

.patch-rib-blue {
  top: 76px;
  left: 162px;
  width: 112px;
  height: 76px;
  background-image: url('/assets/hero/tiles/tile-rib-blue.webp');
  transform: rotate(6deg);
}

.patch-terracotta {
  top: 196px;
  left: 16px;
  width: 150px;
  transform: rotate(9deg);
  filter: drop-shadow(0 12px 20px rgba(120, 48, 16, 0.22));
}

.patch-terracotta:hover {
  transform: rotate(2deg) scale(1.06);
  filter: drop-shadow(0 18px 26px rgba(120, 48, 16, 0.28));
}

.patch-boucle-sage {
  top: 294px;
  left: 172px;
  width: 88px;
  height: 116px;
  background-image: url('/assets/hero/tiles/tile-boucle-sage.webp');
  transform: rotate(-9deg);
}

.patch-butter {
  bottom: 92px;
  left: 24px;
  width: 122px;
  height: 78px;
  background-image: url('/assets/hero/tiles/tile-silk-butter.webp');
  transform: rotate(-5deg);
}

.patch-cocoa {
  bottom: 24px;
  left: 158px;
  width: 96px;
  height: 82px;
  background-image: url('/assets/hero/tiles/tile-linen-cocoa.webp');
  transform: rotate(7deg);
}

/* Right patchwork cluster */
.patch-black {
  top: -8px;
  right: -22px;
  width: 168px;
  transform: rotate(10deg);
  filter: drop-shadow(0 14px 22px rgba(26, 25, 22, 0.22));
}

.patch-black:hover {
  transform: rotate(3deg) scale(1.06);
  filter: drop-shadow(0 20px 28px rgba(26, 25, 22, 0.28));
}

.patch-satin-rose {
  top: 66px;
  right: 166px;
  width: 108px;
  height: 74px;
  background-image: url('/assets/hero/tiles/tile-satin-rose.webp');
  transform: rotate(-7deg);
}

.patch-sketch {
  top: 174px;
  right: 136px;
  width: 108px;
  padding: 6px;
  border-radius: 3px;
  background: #fadbe4;
  box-shadow: 0 10px 20px rgba(26, 25, 22, 0.13), 0 0 0 1px rgba(200, 62, 43, 0.14);
  transform: rotate(5deg);
}

.patch-sketch:hover {
  transform: rotate(0deg) scale(1.07);
}

.patch-tweed-olive {
  top: 196px;
  right: 18px;
  width: 94px;
  height: 94px;
  background-image: url('/assets/hero/tiles/tile-tweed-olive.webp');
  transform: rotate(-11deg);
}

.patch-rose {
  top: 312px;
  right: -18px;
  width: 146px;
  transform: rotate(-9deg);
  filter: drop-shadow(0 12px 20px rgba(130, 58, 78, 0.2));
}

.patch-rose:hover {
  transform: rotate(-2deg) scale(1.06);
}

.patch-peach {
  bottom: 120px;
  right: 196px;
  width: 96px;
  height: 68px;
  background-image: url('/assets/hero/tiles/tile-silk-peach.webp');
  transform: rotate(8deg);
}

.collage-prop {
  position: absolute;
  pointer-events: none;
}

.collage-champagne {
  bottom: 20px;
  right: 54px;
  width: 144px;
  z-index: 4;
  filter: drop-shadow(0 14px 18px rgba(26, 25, 22, 0.18));
}

.hero-center {
  text-align: center;
  max-width: 720px;
  margin: 0 auto;
}

.eyebrow {
  margin: 0 0 14px;
}

h1 {
  font-family: var(--font-serif);
  font-weight: 500;
  font-optical-sizing: auto;
  font-size: clamp(36px, 4.8vw, 56px);
  line-height: 1.06;
  letter-spacing: -0.03em;
  margin: 0 0 16px;
  color: var(--ink);
}

.hero-lead {
  margin: 0 auto 24px;
  color: var(--ink-muted);
  font-size: 16.5px;
  line-height: 1.55;
  max-width: 54ch;
}

.hero-lead strong {
  color: var(--ink);
  font-weight: 500;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  align-items: center;
}

/* Layer 3 + 4: Centerpiece Multi-Outfit Showcase Board + Handwritten Sticky Notes */
.hero-stage {
  position: relative;
  max-width: 760px;
  margin: 32px auto 0;
  z-index: 5;
}

.hero-board {
  position: relative;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.97);
  box-shadow:
    0 20px 44px rgba(26, 25, 22, 0.14),
    0 2px 6px rgba(26, 25, 22, 0.08),
    0 0 0 1px rgba(26, 25, 22, 0.1);
  overflow: hidden;
}

.hero-board-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 16px;
  background: var(--bg-inset);
  border-bottom: 1px solid var(--border);
  flex-wrap: wrap;
}

.hero-board-dots {
  display: inline-flex;
  gap: 5px;
}

.hero-board-dots span {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #d8d3c9;
}

.hero-board-title {
  font-size: 10.5px;
  letter-spacing: 0.08em;
}

.hero-board-count {
  font-size: 10px;
  color: var(--ink-subtle);
  letter-spacing: 0.06em;
}

/* Lively, Borderless 10-Outfit Editorial Flat-lay Collage Wall */
.hero-collage-wall {
  padding: 18px 18px 16px;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 16px 8px;
  background:
    radial-gradient(circle at 1px 1px, rgba(26, 25, 22, 0.055) 1px, transparent 0) 0 0 / 16px 16px,
    linear-gradient(180deg, #fdfcf9 0%, #f6f2ea 100%);
  pointer-events: none;
  user-select: none;
}

.hc-outfit {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}

.hc-cluster {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  height: 100px;
  transform: rotate(var(--hc-tilt, 0deg));
}

.hc-garment-single {
  display: flex;
  align-items: center;
  justify-content: center;
}

.hc-garment-single .flatlay-svg {
  height: 92px;
  width: auto;
  max-width: 68px;
  filter: drop-shadow(0 5px 8px rgba(26, 25, 22, 0.14));
}

.hc-garment-stack {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1px;
}

.hc-garment-stack .flatlay-svg-top {
  width: 52px;
  height: auto;
  filter: drop-shadow(0 3px 6px rgba(26, 25, 22, 0.12));
}

.hc-garment-stack .flatlay-svg-bottom,
.hc-garment-stack .flatlay-svg-short {
  width: 44px;
  height: auto;
  max-height: 48px;
  filter: drop-shadow(0 4px 7px rgba(26, 25, 22, 0.12));
}

.hc-accents {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
}

.hc-accents .flatlay-svg-mini {
  width: 34px;
  height: 26px;
  filter: drop-shadow(0 3px 5px rgba(26, 25, 22, 0.12));
}

.hc-caption {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  font-size: 10.5px;
  font-weight: 500;
  color: var(--ink-secondary);
  white-space: nowrap;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
}

.hc-dots {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  flex-shrink: 0;
}

.hc-dot {
  width: 7px;
  height: 7px;
  border-radius: 2px;
  border: 1px solid rgba(26, 25, 22, 0.22);
}

@media (max-width: 720px) {
  .hero-collage-wall {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    padding: 14px 10px;
    gap: 14px 6px;
  }
  .hc-outfit:nth-child(n + 7) {
    display: none;
  }
}

@media (max-width: 460px) {
  .hero-board-count {
    display: none;
  }
  .hero-collage-wall {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.hero-board-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 16px;
  padding: 11px 16px;
  background: var(--bg-soft);
  border-top: 1px solid var(--border);
}

.hero-board-year {
  display: flex;
  align-items: center;
  gap: 10px;
}

.hero-board-year p {
  margin: 0;
  font-size: 12.5px;
  color: var(--ink-secondary);
  line-height: 1.4;
}

.hero-board-year strong {
  color: var(--ink);
  font-weight: 600;
}

.year-dots {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.year-dot {
  width: 15px;
  height: 15px;
  border-radius: 4px;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.14);
}

.year-strip-link {
  font-size: 12.5px;
  font-weight: 500;
  color: var(--ink);
  white-space: nowrap;
}

/* Handwritten Post-it Sticky Notes (Programa signature) */
.hero-sticky {
  position: absolute;
  z-index: 7;
  padding: 14px 16px;
  font-family: "Caveat", cursive;
  font-size: 23px;
  font-weight: 600;
  line-height: 1.12;
  color: #1a1916;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  border-radius: 2px;
  pointer-events: none;
  user-select: none;
}

.hero-sticky-yellow {
  top: -26px;
  left: -146px;
  width: 138px;
  min-height: 86px;
  font-size: 20px;
  background: linear-gradient(155deg, #feffad 0%, #f8fa8e 100%);
  box-shadow: 0 10px 20px rgba(26, 25, 22, 0.14), inset 0 1px 0 rgba(255, 255, 255, 0.55);
  transform: rotate(-5deg);
}

.hero-sticky-pink {
  bottom: -14px;
  right: -144px;
  width: 134px;
  min-height: 84px;
  font-size: 20px;
  background: linear-gradient(155deg, #ffb8cf 0%, #f59bb9 100%);
  box-shadow: 0 10px 20px rgba(26, 25, 22, 0.15), inset 0 1px 0 rgba(255, 255, 255, 0.45);
  transform: rotate(4deg);
}

/* Coastal Tabletop Band anchoring the bottom of the hero */
.hero-desk {
  position: absolute;
  inset: auto 0 0 0;
  height: 76px;
  background:
    linear-gradient(to bottom, rgba(255, 255, 255, 0.24) 0px, rgba(255, 255, 255, 0) 2px),
    linear-gradient(180deg, #95abc3 0%, #839cb8 100%);
  border-top: 1px solid rgba(26, 25, 22, 0.08);
  z-index: 2;
  pointer-events: none;
}

/* ==========================================================================
   SECTION RHYTHM — Alternating white / soft-stone / obsidian studio bands
   ========================================================================== */
.section {
  padding: 64px 0;
  background: var(--bg-base);
}

.section-soft {
  background: var(--bg-inset);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.section-dark {
  background: var(--bg-dark);
  color: var(--ink-on-dark);
}

.section-dark h2,
.section-dark h3 {
  color: var(--ink-on-dark);
}

.section-dark .section-sub,
.section-dark .mono-label {
  color: var(--ink-on-dark-muted);
}

.section-head {
  margin-bottom: 28px;
}

.section-head-centered {
  text-align: center;
  max-width: 680px;
  margin: 0 auto 36px;
}

.section-head-centered .section-sub {
  margin: 0 auto;
}

h2 {
  font-family: var(--font-serif);
  font-weight: 400;
  font-optical-sizing: auto;
  font-size: clamp(28px, 3.4vw, 40px);
  line-height: 1.14;
  letter-spacing: -0.02em;
  margin: 6px 0 10px;
  color: var(--ink);
}

h3 {
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 17px;
  line-height: 1.35;
  letter-spacing: -0.01em;
  margin: 0 0 8px;
  color: var(--ink);
}

.section-sub {
  margin: 0;
  color: var(--ink-muted);
  font-size: 15px;
  line-height: 1.55;
  max-width: 64ch;
}

/* ==========================================================================
   MODULE 2: MATERIAL SWATCH MATRIX + SPECIFICATION SHEET (4-LINE CARD)
   ========================================================================== */
.filter-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 20px;
}

.filter-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.pill {
  appearance: none;
  border: none;
  background: var(--bg-base);
  color: var(--ink-secondary);
  box-shadow: var(--shadow-hairline);
  height: 31px;
  padding: 0 11px;
  border-radius: var(--radius-btn);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: background-color 0.14s ease, color 0.14s ease, box-shadow 0.14s ease;
}

.pill:hover {
  background: var(--bg-inset);
  color: var(--ink);
}

.pill[aria-pressed="true"],
.pill.is-active {
  background: var(--ink);
  color: #ffffff;
  box-shadow: var(--shadow-btn-dark);
}

.section-dark .pill {
  background: var(--bg-dark-card);
  color: var(--ink-on-dark-muted);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.14);
}

.section-dark .pill:hover {
  color: #ffffff;
  background: var(--bg-dark-elevated);
}

.section-dark .pill.is-active,
.section-dark .pill[aria-pressed="true"] {
  background: var(--yellow);
  color: var(--ink);
  box-shadow: var(--shadow-btn-yellow);
}

.filter-search-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
}

.search-input {
  width: 248px;
  max-width: 100%;
  height: 32px;
  padding: 0 11px;
  border-radius: var(--radius-btn);
  border: 1px solid var(--border-strong);
  background: var(--bg-base);
  color: var(--ink);
  font-size: 13.5px;
}

/* Floating 4-Line Color Specification Modal */
.answer-modal[hidden] {
  display: none;
}

.answer-modal {
  position: fixed;
  inset: 0;
  z-index: 120;
  display: grid;
  place-items: center;
  padding: 20px;
}

.answer-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(26, 25, 22, 0.36);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  opacity: 0;
  transition: opacity 0.22s ease;
}

.answer-modal.is-open .answer-modal-backdrop {
  opacity: 1;
}

.answer-modal-dialog {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 720px;
  max-height: calc(100vh - 40px);
  overflow-y: auto;
  border-radius: 14px;
  background: var(--bg-base);
  box-shadow:
    0 24px 60px rgba(26, 25, 22, 0.24),
    0 4px 14px rgba(26, 25, 22, 0.1),
    0 0 0 1px rgba(26, 25, 22, 0.1);
  opacity: 0;
  transform: translateY(16px) scale(0.96);
  transition: opacity 0.24s cubic-bezier(0.22, 1, 0.36, 1), transform 0.28s cubic-bezier(0.22, 1, 0.36, 1);
}

.answer-modal.is-open .answer-modal-dialog {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.answer-modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 2;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  border: 1px solid var(--border-strong);
  background: var(--bg-soft);
  color: var(--ink-secondary);
  font-size: 20px;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background-color 0.14s ease, color 0.14s ease;
}

.answer-modal-close:hover {
  background: var(--bg-section);
  color: var(--ink);
}

.answer-card {
  background: transparent;
  border-radius: var(--radius-surface);
  padding: 24px;
  margin-bottom: 0;
  box-shadow: none;
}

.answer-card-grid {
  display: grid;
  grid-template-columns: 84px minmax(0, 1fr) auto;
  gap: 18px 24px;
  align-items: start;
}

.answer-modal .answer-card {
  padding: 28px;
}

.answer-modal .answer-card-grid {
  grid-template-columns: 84px minmax(0, 1fr);
}

.answer-modal .answer-header {
  padding-right: 44px;
}

.answer-modal .answer-cta-col {
  grid-column: 2;
  align-items: flex-start;
  padding-top: 2px;
}

.answer-swatch-col {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.answer-swatch {
  width: 84px;
  height: 84px;
  border-radius: var(--radius-card);
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.12), 0 1px 3px rgba(0, 0, 0, 0.06);
  flex-shrink: 0;
}

.answer-hex {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--ink-muted);
  text-align: center;
}

.answer-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.answer-title {
  font-family: var(--font-serif);
  font-size: 26px;
  font-weight: 500;
  letter-spacing: -0.02em;
  line-height: 1.1;
  margin: 0;
}

.badge-ok {
  display: inline-flex;
  align-items: center;
  padding: 3px 8px;
  border-radius: 4px;
  background: var(--ok-bg);
  border: 1px solid var(--ok-border);
  color: var(--ok-ink);
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.answer-lines {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 8px;
}

.answer-lines li {
  font-size: 14px;
  color: var(--ink-secondary);
  line-height: 1.5;
  padding-left: 12px;
  border-left: 2px solid var(--bg-section);
}

.answer-lines strong {
  color: var(--ink);
  font-weight: 600;
}

.answer-cta-col {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
}

/* Color Swatch Grid (Programa Bento Micro-Card Aesthetic) */
.group-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin: 26px 0 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border);
}

.group-heading h3 {
  margin: 0;
  font-size: 15px;
  font-weight: 500;
  color: var(--ink);
}

.group-count {
  font-family: var(--font-mono);
  font-size: 11.5px;
  color: var(--ink-subtle);
  text-transform: uppercase;
  white-space: nowrap;
  flex-shrink: 0;
}

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

.color-card {
  appearance: none;
  width: 100%;
  text-align: left;
  background: var(--bg-soft);
  border: none;
  border-radius: var(--radius-card);
  padding: 13px;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  cursor: pointer;
  box-shadow: var(--shadow-hairline);
  transition: box-shadow 0.16s ease, transform 0.14s ease, background-color 0.14s ease;
}

.color-card:hover {
  background: #ffffff;
  box-shadow: var(--shadow-card-hover);
  transform: translateY(-1px);
}

.color-card.is-selected {
  background: #ffffff;
  box-shadow: 0 0 0 1.5px var(--ink), 0 6px 16px rgba(26, 25, 22, 0.09);
}

.color-card.is-hidden {
  display: none;
}

.swatch {
  width: 38px;
  height: 38px;
  border-radius: 6px;
  flex-shrink: 0;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.12);
}

.color-card-body {
  min-width: 0;
  flex: 1;
}

.color-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}

.color-name {
  font-weight: 500;
  font-size: 14px;
  color: var(--ink);
  line-height: 1.25;
}

.color-meaning {
  margin: 3px 0 0;
  font-size: 12.5px;
  color: var(--ink-muted);
  line-height: 1.38;
}

/* ==========================================================================
   MODULE 3: 3-LAYER SPECIFICATION WORKSPACE
   ========================================================================== */
.generator-layout {
  display: grid;
  grid-template-columns: minmax(0, 0.96fr) minmax(0, 1.04fr);
  gap: 24px;
  align-items: start;
}

.panel {
  background: var(--bg-base);
  border-radius: var(--radius-surface);
  padding: 24px;
  box-shadow: var(--shadow-surface);
}

.step-block + .step-block {
  margin-top: 22px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
}

.step-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
}

.step-title {
  font-weight: 500;
  font-size: 14.5px;
  color: var(--ink);
}

.step-opt {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--ink-subtle);
  text-transform: uppercase;
  white-space: nowrap;
  flex-shrink: 0;
}

/* 24-Color Swatch Button (used inside Lookboard inline editor) */
.swatch-pick-btn {
  width: 100%;
  aspect-ratio: 1;
  padding: 0;
  border-radius: 6px;
  border: 1px solid rgba(26, 25, 22, 0.16);
  cursor: pointer;
  transition: transform 0.14s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.14s ease;
}

.swatch-pick-btn:hover {
  transform: scale(1.14);
  z-index: 2;
  box-shadow: 0 4px 10px rgba(26, 25, 22, 0.18);
}

.swatch-pick-btn.is-selected {
  transform: scale(1.08);
  outline: 2px solid var(--ink);
  outline-offset: 2px;
  z-index: 3;
}

/* Left Panel Scene Cards & Bridge Hint */
.scene-picker-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.scene-card-btn {
  appearance: none;
  border: 1px solid var(--border-strong);
  background: var(--bg-soft);
  border-radius: var(--radius-card);
  padding: 10px 10px 9px;
  text-align: left;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 2px;
  transition: background-color 0.14s ease, border-color 0.14s ease, box-shadow 0.14s ease, transform 0.12s ease;
}

.scene-card-btn strong {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--ink);
  line-height: 1.25;
}

.scene-card-btn span {
  font-size: 11.5px;
  color: var(--ink-muted);
  line-height: 1.3;
}

.scene-card-btn:hover {
  background: #ffffff;
  border-color: rgba(26, 25, 22, 0.32);
  transform: translateY(-1px);
}

.scene-card-btn.is-active {
  background: var(--ink);
  border-color: var(--ink);
  box-shadow: var(--shadow-btn-dark);
}

.scene-card-btn.is-active strong {
  color: #ffffff;
}

.scene-card-btn.is-active span {
  color: #c8c2b8;
}

.inputs-bridge-hint {
  margin: 18px 0 0;
  padding-top: 14px;
  border-top: 1px solid var(--border);
  font-size: 12.5px;
  color: var(--ink-muted);
  line-height: 1.45;
}

@media (max-width: 480px) {
  .scene-picker-grid {
    grid-template-columns: 1fr;
  }
}

.step-opt.is-full {
  color: #a84b18;
  font-weight: 600;
}

.wish-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.wish-grid[hidden] {
  display: none;
}

.wish-chip {
  appearance: none;
  border: none;
  background: var(--bg-soft);
  color: var(--ink-secondary);
  box-shadow: var(--shadow-hairline);
  min-height: 32px;
  padding: 5px 11px;
  border-radius: var(--radius-btn);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all 0.14s ease;
}

.wish-chip:hover:not(:disabled) {
  background: #ffffff;
  color: var(--ink);
  box-shadow: 0 0 0 1px rgba(26, 25, 22, 0.24), 0 1px 2px rgba(0, 0, 0, 0.08);
}

.wish-chip.is-selected {
  background: var(--ink);
  color: #ffffff;
  box-shadow: var(--shadow-btn-dark);
}

.wish-chip.is-selected:hover {
  background: #2f2d29;
  color: #ffffff;
}

.wish-chip:disabled {
  opacity: 0.36;
  cursor: not-allowed;
  background: var(--bg-inset);
  color: var(--ink-subtle);
  box-shadow: none;
}

.wish-more-wrap {
  margin-top: 10px;
}

.wish-helper {
  margin: 8px 0 0;
  font-size: 12.5px;
  color: var(--ink-muted);
}

.birthday-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.birthday-input {
  width: 140px;
  height: 36px;
  padding: 0 12px;
  border-radius: var(--radius-btn);
  border: 1px solid var(--border-strong);
  background: var(--bg-soft);
  color: var(--ink);
  font-family: var(--font-mono);
  font-size: 14px;
  font-variant-numeric: tabular-nums;
}

.input-feedback {
  margin: 9px 0 0;
  font-size: 12.5px;
  padding: 8px 11px;
  border-radius: var(--radius-btn);
}

.input-feedback.is-error {
  color: var(--err-ink);
  background: var(--err-bg);
  border: 1px solid var(--err-border);
}

.input-feedback.is-ok {
  color: var(--ok-ink);
  background: var(--ok-bg);
  border: 1px solid var(--ok-border);
}

/* Output Specification Sheet */
.result-panel {
  background: var(--bg-base);
}

.scene-bar,
.studio-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding-bottom: 14px;
  margin-bottom: 14px;
  border-bottom: 1px solid var(--border);
}

.scene-label {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--ink-muted);
}

.scene-segment {
  display: inline-flex;
  background: var(--bg-inset);
  padding: 3px;
  border-radius: 7px;
  box-shadow: inset 0 0 0 1px var(--border-hairline);
  gap: 2px;
}

.scene-btn {
  appearance: none;
  border: none;
  background: transparent;
  color: var(--ink-muted);
  height: 28px;
  padding: 0 10px;
  border-radius: 5px;
  font-size: 12.5px;
  font-weight: 500;
  cursor: pointer;
}

.scene-btn.is-active {
  background: #ffffff;
  color: var(--ink);
  box-shadow: var(--shadow-hairline);
}

/* Editorial Flat-lay Visual Lookboard (Gender-Neutral Studio Surface) */
.lookboard-shell {
  border-radius: var(--radius-surface);
  border: 1px solid var(--border-strong);
  padding: 14px;
  transition: background-color 0.24s ease, border-color 0.24s ease;
}

.lookboard-shell.is-scene-casa {
  background:
    radial-gradient(circle at 1px 1px, rgba(26, 25, 22, 0.05) 1px, transparent 0) 0 0 / 16px 16px,
    linear-gradient(180deg, #fcfbf8 0%, #f5f1e9 100%);
}

.lookboard-shell.is-scene-praia {
  background:
    radial-gradient(circle at 82% 14%, rgba(255, 225, 168, 0.34), transparent 46%),
    linear-gradient(180deg, #faf4ea 0%, #f1e6d6 100%);
  border-color: rgba(164, 134, 92, 0.28);
}

.lookboard-shell.is-scene-festa {
  background:
    radial-gradient(circle at 24% 12%, rgba(255, 241, 200, 0.11), transparent 48%),
    linear-gradient(180deg, #242320 0%, #1a1916 100%);
  border-color: rgba(255, 255, 255, 0.14);
}

.lookboard-topbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 12px;
}

.lookboard-vibe {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 4px 8px;
  border-radius: 5px;
  background: rgba(255, 255, 255, 0.78);
  color: var(--ink-secondary);
  border: 1px solid rgba(26, 25, 22, 0.1);
}

.lookboard-shell.is-scene-festa .lookboard-vibe {
  background: rgba(255, 255, 255, 0.1);
  color: #e6e1d8;
  border-color: rgba(255, 255, 255, 0.14);
}

.lookboard-controls {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.lookboard-length-toggle {
  display: inline-flex;
  background: rgba(26, 25, 22, 0.07);
  padding: 2px;
  border-radius: 6px;
  gap: 2px;
}

.lookboard-shell.is-scene-festa .lookboard-length-toggle {
  background: rgba(255, 255, 255, 0.1);
}

.lb-mini-btn {
  appearance: none;
  border: none;
  background: transparent;
  color: var(--ink-secondary);
  height: 24px;
  padding: 0 8px;
  border-radius: 4px;
  font-size: 11.5px;
  font-weight: 500;
  cursor: pointer;
}

.lb-mini-btn.is-active {
  background: #ffffff;
  color: var(--ink);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.12);
}

.lookboard-shell.is-scene-festa .lb-mini-btn {
  color: #c9c3b9;
}

.lookboard-shell.is-scene-festa .lb-mini-btn.is-active {
  background: #ffffff;
  color: var(--ink);
}

.lookboard-stage {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 0.95fr);
  gap: 10px;
  align-items: stretch;
}

.lookboard-col-main,
.lookboard-col-side {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.flatlay-main-onepiece {
  flex: 1;
  display: flex;
}

.flatlay-main-twopiece {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.flatlay-piece {
  appearance: none;
  border: 1px solid rgba(26, 25, 22, 0.08);
  background: rgba(255, 255, 255, 0.66);
  border-radius: 10px;
  padding: 10px 8px 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: 100%;
  cursor: pointer;
  transition: transform 0.16s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.16s ease, border-color 0.16s ease, background-color 0.16s ease;
}

.lookboard-shell.is-scene-festa .flatlay-piece {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.11);
}

.flatlay-piece:hover {
  transform: translateY(-2px);
  background: rgba(255, 255, 255, 0.92);
  border-color: rgba(26, 25, 22, 0.24);
  box-shadow: 0 6px 16px rgba(26, 25, 22, 0.09);
}

.lookboard-shell.is-scene-festa .flatlay-piece:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.3);
}

.flatlay-piece.is-active {
  background: #ffffff;
  border-color: var(--ink);
  box-shadow: 0 0 0 1.5px var(--ink), 0 8px 20px rgba(26, 25, 22, 0.12);
}

.lookboard-shell.is-scene-festa .flatlay-piece.is-active {
  background: rgba(255, 255, 255, 0.15);
  border-color: var(--yellow);
  box-shadow: 0 0 0 1.5px var(--yellow);
}

.flatlay-piece.is-hero-piece {
  flex: 1;
  min-height: 280px;
}

.flatlay-piece.is-top-piece {
  flex: 1;
}

.flatlay-piece.is-bottom-piece {
  flex: 1.1;
}

.flatlay-piece.is-side-piece {
  flex: 1;
  padding: 8px 8px 7px;
}

.flatlay-svg {
  display: block;
  filter: drop-shadow(0 4px 8px rgba(26, 25, 22, 0.1));
}

.flatlay-svg-onepiece {
  width: 156px;
  max-width: 100%;
  height: auto;
  max-height: 240px;
}

.flatlay-svg-top {
  width: 136px;
  max-width: 100%;
  height: auto;
}

.flatlay-svg-bottom {
  width: 122px;
  max-width: 100%;
  height: auto;
}

.flatlay-svg-short {
  width: 126px;
  max-width: 100%;
  height: auto;
}

.flatlay-svg-mini {
  width: 82px;
  height: 58px;
}

.flatlay-tag {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  max-width: 100%;
  padding: 3px 7px;
  border-radius: 5px;
  background: rgba(255, 255, 255, 0.92);
  color: var(--ink);
  border: 1px solid rgba(26, 25, 22, 0.1);
  font-size: 11.5px;
  font-weight: 500;
  line-height: 1.25;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.flatlay-tag-dot {
  width: 8px;
  height: 8px;
  border-radius: 2px;
  border: 1px solid rgba(26, 25, 22, 0.22);
  flex-shrink: 0;
}

.flatlay-sub {
  font-size: 11px;
  color: var(--ink-muted);
  line-height: 1.2;
  max-width: 100%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.flatlay-sub.is-manual {
  color: var(--ink);
  font-weight: 500;
}

.lookboard-shell.is-scene-festa .flatlay-sub {
  color: #c2bcb2;
}

.lookboard-shell.is-scene-festa .flatlay-sub.is-manual {
  color: var(--yellow);
}

.lookboard-footer-bar {
  margin-top: 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.ratio-bar {
  display: flex;
  width: 100%;
  height: 9px;
  border-radius: 99px;
  overflow: hidden;
  background: rgba(26, 25, 22, 0.08);
  border: 1px solid rgba(26, 25, 22, 0.12);
}

.ratio-seg {
  height: 100%;
  transition: width 0.2s ease, background 0.2s ease;
}

.lookboard-utility-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.lookboard-utility-left {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.lookboard-hint {
  font-size: 11.5px;
  color: var(--ink-muted);
}

.lookboard-shell.is-scene-festa .lookboard-hint {
  color: #b8b2a8;
}

.lb-ghost-link,
.lb-nails-link {
  appearance: none;
  border: none;
  background: transparent;
  padding: 2px 4px;
  border-radius: 4px;
  font-size: 11.5px;
  font-weight: 500;
  color: var(--ink-secondary);
  cursor: pointer;
  transition: color 0.14s ease, background-color 0.14s ease;
}

.lb-ghost-link {
  text-decoration: underline;
  color: var(--ink-muted);
}

.lb-ghost-link:hover,
.lb-nails-link:hover {
  color: var(--ink);
  background: rgba(26, 25, 22, 0.06);
}

.lb-nails-link.is-active {
  color: var(--ink);
  font-weight: 600;
  background: rgba(26, 25, 22, 0.08);
  padding: 2px 7px;
}

.lookboard-shell.is-scene-festa .lb-ghost-link,
.lookboard-shell.is-scene-festa .lb-nails-link {
  color: #cfc9bf;
}

.lookboard-shell.is-scene-festa .lb-nails-link:hover,
.lookboard-shell.is-scene-festa .lb-ghost-link:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.1);
}

.lookboard-shell.is-scene-festa .lb-nails-link.is-active {
  color: var(--yellow);
  background: rgba(253, 255, 162, 0.14);
}

.slot-idle-bar {
  margin-top: 12px;
  padding: 11px 13px;
  border-radius: var(--radius-card);
  background: var(--bg-soft);
  border: 1px dashed var(--border-strong);
  font-size: 12.5px;
  color: var(--ink-muted);
  line-height: 1.45;
}

/* Inline Piece Color & Style Editor */
.slot-editor {
  margin-top: 12px;
  padding: 14px;
  border-radius: var(--radius-card);
  background: #ffffff;
  border: 1.5px solid var(--ink);
  box-shadow: 0 8px 22px rgba(26, 25, 22, 0.09);
}

.slot-editor-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 6px;
}

.slot-editor-title-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
}

.slot-editor-meta {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 2px;
}

.slot-editor-meta .layer-badge {
  margin-bottom: 0;
}

.slot-mode-pill {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 1px 6px;
  border-radius: 4px;
  background: var(--bg-inset);
  color: var(--ink-muted);
  border: 1px solid var(--border);
}

.slot-mode-pill.is-manual {
  background: var(--ink);
  color: #ffffff;
  border-color: var(--ink);
}

.slot-editor-dot {
  width: 30px;
  height: 30px;
  border-radius: 6px;
  border: 1px solid rgba(26, 25, 22, 0.18);
  flex-shrink: 0;
}

.slot-editor-title {
  margin: 0;
  font-size: 15px;
  font-weight: 600;
  color: var(--ink);
  line-height: 1.25;
}

.slot-editor-close {
  appearance: none;
  border: none;
  background: var(--bg-inset);
  color: var(--ink-secondary);
  width: 26px;
  height: 26px;
  border-radius: 6px;
  font-size: 17px;
  line-height: 1;
  cursor: pointer;
  flex-shrink: 0;
}

.slot-editor-close:hover {
  background: var(--bg-section);
  color: var(--ink);
}

.slot-editor-reason {
  margin: 0 0 8px;
  font-size: 13px;
  color: var(--ink-secondary);
  line-height: 1.45;
}

.editor-control-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-top: 8px;
}

.editor-pill-group {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 5px;
}

.editor-pill {
  appearance: none;
  border: 1px solid var(--border-strong);
  background: var(--bg-soft);
  color: var(--ink-secondary);
  height: 26px;
  padding: 0 9px;
  border-radius: 5px;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
}

.editor-pill.is-active {
  background: var(--ink);
  border-color: var(--ink);
  color: #ffffff;
}

.alt-btn-more {
  background: var(--bg-inset);
  color: var(--ink-secondary);
}

.alt-btn-reset {
  background: transparent;
  color: var(--ink-muted);
  text-decoration: underline;
  box-shadow: none;
}

.editor-all-swatches {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--border);
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 5px;
}

@media (max-width: 560px) {
  .lookboard-stage {
    grid-template-columns: 1fr;
  }
  .lookboard-col-side {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
  }
  .editor-all-swatches {
    grid-template-columns: repeat(8, minmax(0, 1fr));
  }
}

.layer-list {
  display: grid;
  gap: 10px;
}

.layer-card {
  background: var(--bg-soft);
  border-radius: var(--radius-card);
  padding: 15px;
  box-shadow: var(--shadow-hairline);
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr);
  gap: 14px;
  align-items: start;
}

.layer-swatch {
  width: 44px;
  height: 44px;
  border-radius: 6px;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.12);
}

.layer-badge {
  font-family: var(--font-mono);
  font-size: 10.5px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--ink-muted);
  margin-bottom: 3px;
}

.layer-title {
  font-weight: 600;
  font-size: 15px;
  margin: 0 0 4px;
  color: var(--ink);
  line-height: 1.3;
}

.layer-detail {
  margin: 0 0 5px;
  font-size: 13.5px;
  color: var(--ink-secondary);
  line-height: 1.5;
}

.layer-reason {
  margin: 0;
  font-size: 12.5px;
  color: var(--ink-muted);
}

.layer-warn {
  margin-top: 8px;
  padding: 8px 10px;
  border-radius: var(--radius-btn);
  background: var(--warn-bg);
  border: 1px solid var(--warn-border);
  color: var(--warn-ink);
  font-size: 12.5px;
  font-weight: 500;
}

.alt-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin-top: 10px;
}

.alt-label {
  font-family: var(--font-mono);
  font-size: 10.5px;
  text-transform: uppercase;
  color: var(--ink-subtle);
}

.alt-btn {
  appearance: none;
  border: none;
  background: #ffffff;
  color: var(--ink);
  box-shadow: var(--shadow-hairline);
  height: 25px;
  padding: 0 8px;
  border-radius: 5px;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.alt-btn:hover {
  background: var(--bg-inset);
}

.alt-dot {
  width: 9px;
  height: 9px;
  border-radius: 2px;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.18);
}

.note-box {
  margin-top: 12px;
  padding: 13px 15px;
  border-radius: var(--radius-card);
  background: var(--yellow);
  box-shadow: 0 0 0 1px var(--yellow-border);
  font-size: 13px;
  color: var(--ink);
  line-height: 1.5;
}

.extra-item-box {
  margin-top: 12px;
  padding: 12px 14px;
  border-radius: var(--radius-card);
  background: var(--bg-inset);
  border: 1px dashed var(--border-strong);
  font-size: 13px;
  color: var(--ink-secondary);
}

/* Direct site-standard primary Share CTA below the 3-layer outfit result */
.generator-share-cta {
  margin-top: 18px;
}

.btn-share-cta {
  width: 100%;
  min-height: 44px;
  font-size: 15px;
  gap: 9px;
}

/* ==========================================================================
   MODULE 4: LIGHT STUDIO SHARE MODAL (Unified with Site Light UI & Buttons)
   ========================================================================== */
.poster-modal[hidden] {
  display: none;
}

.poster-modal {
  position: fixed;
  inset: 0;
  z-index: 130;
  display: grid;
  place-items: center;
  padding: 20px;
}

.poster-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(26, 25, 22, 0.36);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  opacity: 0;
  transition: opacity 0.22s ease;
}

.poster-modal.is-open .poster-modal-backdrop {
  opacity: 1;
}

.poster-modal-dialog {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 780px;
  max-height: calc(100vh - 36px);
  overflow-y: auto;
  border-radius: 14px;
  padding: 28px;
  background: var(--bg-base);
  color: var(--ink);
  box-shadow:
    0 24px 60px rgba(26, 25, 22, 0.24),
    0 4px 14px rgba(26, 25, 22, 0.1),
    0 0 0 1px rgba(26, 25, 22, 0.1);
  opacity: 0;
  transform: translateY(16px) scale(0.96);
  transition: opacity 0.24s cubic-bezier(0.22, 1, 0.36, 1), transform 0.28s cubic-bezier(0.22, 1, 0.36, 1);
}

.poster-modal.is-open .poster-modal-dialog {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.poster-modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  border: 1px solid var(--border-strong);
  background: var(--bg-soft);
  color: var(--ink-secondary);
  font-size: 20px;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background-color 0.14s ease, color 0.14s ease;
}

.poster-modal-close:hover {
  background: var(--bg-section);
  color: var(--ink);
}

.poster-modal-controls {
  padding-right: 16px;
}

.poster-modal-controls h2 {
  margin: 0 0 8px;
  font-family: var(--font-serif);
  font-size: clamp(24px, 3vw, 30px);
  font-weight: 500;
  line-height: 1.15;
  color: var(--ink);
}

.poster-modal-sub {
  margin: 0 0 20px;
  font-size: 14px;
  color: var(--ink-muted);
}

.poster-mode-segment {
  margin-bottom: 18px;
}

.poster-modal .poster-frame {
  background: var(--bg-inset);
  padding: 10px;
  border-radius: 12px;
  border: 1px solid var(--border);
}

.poster-modal .poster-canvas {
  box-shadow: 0 10px 26px rgba(26, 25, 22, 0.12);
}

.poster-modal .share-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.poster-modal .share-note {
  margin: 12px 0 0;
  font-size: 12.5px;
  color: var(--ink-muted);
}

.poster-layout {
  display: grid;
  grid-template-columns: 270px minmax(0, 1fr);
  gap: 36px;
  align-items: center;
}

.poster-frame {
  width: 100%;
  max-width: 270px;
  aspect-ratio: 9 / 16;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.14), 0 20px 44px rgba(0, 0, 0, 0.45);
  background: #fcfbf9;
  margin: 0 auto;
}

.poster-canvas {
  width: 100%;
  height: 100%;
  display: block;
}

.privacy-toggle {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 16px 0 20px;
}

.share-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 14px;
}

.share-note {
  margin: 0;
  font-size: 13px;
  color: var(--ink-on-dark-muted);
}

.affiliate-slot {
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

.affiliate-slot[hidden] {
  display: none;
}

/* ==========================================================================
   MODULE 5: EDITORIAL METHODOLOGY TABLES & HAIRLINE FAQ
   ========================================================================== */
.table-wrap {
  overflow-x: auto;
  background: var(--bg-base);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-hairline);
  margin: 14px 0 28px;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13.5px;
  min-width: 580px;
}

th,
td {
  padding: 12px 15px;
  text-align: left;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
}

th {
  background: var(--bg-soft);
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--ink-muted);
}

td {
  color: var(--ink-secondary);
}

td strong {
  color: var(--ink);
  font-weight: 600;
}

tr:last-child td {
  border-bottom: none;
}

.table-disclosure {
  background: var(--bg-soft);
  border-radius: var(--radius-card);
  padding: 14px 18px;
  box-shadow: var(--shadow-hairline);
}

.table-disclosure summary {
  cursor: pointer;
  font-size: 14px;
  font-weight: 500;
  color: var(--ink);
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.table-disclosure summary::-webkit-details-marker {
  display: none;
}

.table-disclosure summary::after {
  content: "+";
  font-family: var(--font-mono);
  font-size: 17px;
  color: var(--ink-muted);
}

.table-disclosure[open] summary::after {
  content: "−";
  color: var(--ink);
}

.palette-figure {
  margin: 0 0 24px;
  background: var(--bg-soft);
  border-radius: var(--radius-surface);
  padding: 12px;
  box-shadow: var(--shadow-hairline);
}

.palette-figure img {
  width: 100%;
  height: auto;
  border-radius: var(--radius-card);
}

.palette-figure figcaption {
  margin-top: 8px;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--ink-subtle);
  text-transform: uppercase;
}

.faq-list {
  max-width: 820px;
  margin: 0 auto;
  border-top: 1px solid var(--border);
}

.faq-item {
  border-bottom: 1px solid var(--border);
  padding: 18px 4px;
}

.faq-item summary {
  font-weight: 500;
  font-size: 15.5px;
  color: var(--ink);
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  content: "+";
  font-family: var(--font-mono);
  font-size: 18px;
  font-weight: 400;
  color: var(--ink-muted);
  flex-shrink: 0;
}

.faq-item[open] summary::after {
  content: "−";
  color: var(--ink);
}

.faq-item p {
  margin: 10px 0 0;
  font-size: 14.5px;
  color: var(--ink-muted);
  line-height: 1.6;
  max-width: 68ch;
}

/* ==========================================================================
   FOOTER — Crisp White Elevated Studio Footer
   ========================================================================== */
.site-footer {
  background: var(--bg-base);
  box-shadow: 0 -1px 0 var(--border);
  padding: 40px 0 52px;
  font-size: 13.5px;
  color: var(--ink-muted);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr;
  gap: 28px;
  align-items: start;
}

.footer-col-title {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--ink-subtle);
  margin: 0 0 10px;
}

.footer-links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 7px;
}

.footer-links a {
  text-decoration: none;
  color: var(--ink-secondary);
}

.footer-links a:hover {
  color: var(--ink);
  text-decoration: underline;
}

.footer-bottom {
  margin-top: 28px;
  padding-top: 18px;
  border-top: 1px solid var(--border);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 10px 24px;
  font-size: 12.5px;
  color: var(--ink-subtle);
}

/* ==========================================================================
   RESPONSIVE
   ========================================================================== */
@media (max-width: 1320px) {
  .patch-linen { width: 146px; left: -34px; }
  .patch-rib-blue { left: 108px; width: 92px; height: 64px; }
  .patch-terracotta { width: 126px; left: -12px; }
  .patch-boucle-sage { left: 112px; width: 74px; height: 96px; }
  .patch-butter { left: -10px; width: 104px; height: 68px; }
  .patch-cocoa { left: 96px; width: 80px; height: 68px; }
  .patch-black { width: 142px; right: -34px; }
  .patch-satin-rose { right: 110px; width: 90px; height: 62px; }
  .patch-sketch { right: 106px; width: 92px; }
  .patch-tweed-olive { right: -10px; width: 82px; height: 82px; }
  .patch-rose { width: 122px; right: -30px; }
  .patch-peach { right: 146px; width: 82px; height: 58px; }
  .collage-champagne { right: 18px; width: 120px; }
}

@media (max-width: 1080px) {
  /* Keep outer colorful patches visible on ~900-1080px screens; hide only inner ones that could touch text */
  .patch-rib-blue,
  .patch-boucle-sage,
  .patch-cocoa,
  .patch-satin-rose,
  .patch-sketch,
  .patch-peach,
  .collage-champagne,
  .hero-sticky {
    display: none;
  }
  .patch-linen { width: 126px; left: -34px; top: -10px; }
  .patch-terracotta { width: 116px; left: -24px; top: 210px; }
  .patch-butter { width: 100px; height: 68px; left: -18px; bottom: 56px; }
  .patch-black { width: 126px; right: -34px; top: -8px; }
  .patch-tweed-olive { width: 82px; height: 82px; right: -18px; top: 196px; }
  .patch-rose { width: 114px; right: -26px; bottom: 48px; top: auto; }
  .color-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .generator-layout {
    grid-template-columns: 1fr;
  }
  .answer-card-grid {
    grid-template-columns: 76px minmax(0, 1fr);
  }
  .answer-cta-col {
    grid-column: 1 / -1;
    align-items: stretch;
  }
}

@media (max-width: 760px) {
  .container {
    padding: 0 18px;
  }
  .site-header {
    padding: 8px 12px;
  }
  .header-dock {
    padding: 7px 12px;
  }
  .site-nav a:not(.nav-cta),
  .nav-divider {
    display: none;
  }
  .hero {
    padding: 58px 0 34px;
  }
  .hero-patchwork {
    display: block;
  }
  /* Keep 4 colorful fabric patches peeking cleanly from the mobile Hero corners */
  .patch-rib-blue,
  .patch-boucle-sage,
  .patch-cocoa,
  .patch-satin-rose,
  .patch-sketch,
  .patch-peach,
  .patch-tweed-olive,
  .collage-champagne {
    display: none;
  }
  .patch-linen {
    width: 78px;
    top: -12px;
    left: -14px;
    transform: rotate(-10deg);
  }
  .patch-black {
    width: 74px;
    top: -10px;
    right: -14px;
    transform: rotate(10deg);
  }
  .patch-terracotta {
    width: 66px;
    top: 244px;
    left: -26px;
    transform: rotate(12deg);
  }
  .patch-butter {
    width: 68px;
    height: 44px;
    bottom: 24px;
    left: -18px;
    transform: rotate(-7deg);
  }
  .patch-rose {
    width: 66px;
    top: 238px;
    right: -26px;
    bottom: auto;
    transform: rotate(-11deg);
  }
  .hero-sticky {
    display: none;
  }
  .hero-board-row {
    grid-template-columns: 22px 24px minmax(0, 1fr);
    gap: 10px;
  }
  .hero-row-tag {
    display: none;
  }
  .hero-desk {
    height: 44px;
  }
  .section {
    padding: 44px 0;
  }
  .color-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }
  .color-card {
    padding: 11px;
    gap: 9px;
  }
  .swatch {
    width: 32px;
    height: 32px;
  }
  .poster-shell {
    padding: 22px 18px;
  }
  .poster-layout {
    grid-template-columns: 1fr;
    gap: 24px;
  }
  .filter-search-wrap,
  .search-input {
    width: 100%;
  }
  .answer-modal .answer-cta-col {
    grid-column: 1 / -1;
    align-items: stretch;
  }
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }
}

@media (max-width: 440px) {
  .color-grid {
    grid-template-columns: 1fr;
  }
  .answer-card,
  .answer-modal .answer-card {
    padding: 20px;
  }
  .answer-card-grid,
  .answer-modal .answer-card-grid {
    grid-template-columns: 1fr;
  }
  .answer-modal .answer-header {
    padding-right: 0;
  }
  .answer-modal .answer-swatch-col {
    padding-right: 44px;
  }
  .answer-modal .answer-cta-col {
    grid-column: 1 / -1;
    align-items: stretch;
  }
  .answer-swatch-col {
    flex-direction: row;
    align-items: center;
    gap: 12px;
  }
  .answer-swatch {
    width: 56px;
    height: 56px;
  }
}
