/* =====================================================
   MOSAIC STORRA — Simulador de Suelo
   Estilo: editorial + lujo + artesanal
   CSS Layer v2 — 4-column workspace
===================================================== */

/* ----- Design tokens ----- */
:root {
  --accent:       #6b1d2c;
  --accent-ink:   #ffffff;
  --accent-soft:  #f3e8e8;

  --bg:           #f7f3ee;
  --bg-elev:      #ffffff;
  --bg-2:         #efeae3;
  --bg-3:         #e8e2d6;

  --ink:          #1a1816;
  --ink-2:        #4a4642;
  --ink-3:        #8a847a;
  --ink-4:        #b9b1a4;

  --line:         #d9d2c5;
  --line-soft:    #ece6da;

  --shadow-sm:  0 1px 2px rgba(40,30,20,.04), 0 1px 1px rgba(40,30,20,.03);
  --shadow-md:  0 6px 18px -8px rgba(40,30,20,.18), 0 2px 6px rgba(40,30,20,.06);
  --shadow-lg:  0 24px 60px -24px rgba(40,30,20,.28), 0 10px 24px -12px rgba(40,30,20,.16);

  --radius-sm: 4px;
  --radius-md: 6px;
  --radius-lg: 10px;
  --radius-xl: 16px;

  --font-sans:    'Roboto', system-ui, -apple-system, sans-serif;
  --font-display: 'Cormorant Garamond', 'Playfair Display', Georgia, serif;
  --font-mono:    'JetBrains Mono', ui-monospace, Menlo, monospace;

  --pad: 22px;
  --gap: 16px;
}

:root[data-dark="true"] {
  --bg:        #18161a;
  --bg-elev:   #221f23;
  --bg-2:      #1f1c20;
  --bg-3:      #2a262a;
  --ink:       #f0ece4;
  --ink-2:     #c8c1b5;
  --ink-3:     #8a8278;
  --ink-4:     #58524c;
  --line:      #34302f;
  --line-soft: #2a2725;
  --accent-soft: rgba(180,90,90,.12);
}

:root[data-density="compact"]     { --pad: 14px; --gap: 10px; }
:root[data-density="comfortable"] { --pad: 22px; --gap: 16px; }
:root[data-density="spacious"]    { --pad: 32px; --gap: 24px; }

:root[data-display-font="roboto"] { --font-display: 'Roboto', sans-serif; }

* { box-sizing: border-box; }

html, body {
  margin: 0; padding: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 14px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
body { min-height: 100vh; }
a { color: inherit; }
button { font-family: inherit; }

/* ----- Typography ----- */
.display, .page-title, h1.display {
  font-family: var(--font-display);
  font-weight: 400;
  letter-spacing: -.015em;
  line-height: 1.02;
  color: var(--ink);
}
:root[data-display-font="roboto"] .display,
:root[data-display-font="roboto"] .page-title,
:root[data-display-font="roboto"] h1.display { font-weight: 300; letter-spacing: -.03em; }

.display em, .page-title em { font-style: italic; font-weight: 400; color: var(--accent); }
:root[data-display-font="roboto"] .display em,
:root[data-display-font="roboto"] .page-title em { font-style: normal; color: var(--accent); }

.eyebrow {
  font-family: var(--font-sans);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.eyebrow.inline { display: inline; }

.meta {
  font-size: 11px;
  letter-spacing: .04em;
  color: var(--ink-3);
}
.meta-swatch {
  display: inline-block;
  width: 10px; height: 10px;
  border-radius: 50%;
  vertical-align: -1px;
  margin: 0 4px;
  box-shadow: inset 0 0 0 1px rgba(0,0,0,.18);
}
.capitalize { text-transform: capitalize; }
.dot { color: var(--ink-4); margin: 0 6px; }

/* ----- App bar ----- */
.app-bar {
  height: 52px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 16px;
  background: var(--bg-elev);
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  z-index: 50;
}
.app-bar-collections {
  display: flex;
  gap: 4px;
  flex: 1;
  overflow: hidden;
}
.app-bar-right { display: flex; align-items: center; gap: 6px; margin-left: auto; flex-shrink: 0; }

.brand-logo { display: flex; align-items: center; gap: 8px; color: var(--ink); text-decoration: none; }
.brand-mark { display: inline-grid; place-items: center; }
.brand-wordmark { font-family: var(--font-sans); font-weight: 600; letter-spacing: .14em; font-size: 11.5px; }
.brand-wordmark b { color: var(--ink); }
.brand-wordmark span { color: var(--ink-3); font-weight: 400; margin-left: 4px; }

.ws-tagline {
  font-size: 11px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--ink-3);
}

/* ----- Buttons ----- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  border-radius: var(--radius-md);
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 13px;
  letter-spacing: .02em;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform .12s ease, background .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--accent); color: var(--accent-ink); box-shadow: var(--shadow-md); }
.btn-primary:hover { filter: brightness(1.08); }
.btn-outline { background: var(--bg-elev); color: var(--ink); border-color: var(--line); }
.btn-outline:hover { background: #732030; color: #fff; border-color: #732030; }
.btn-ghost { background: transparent; color: var(--ink-2); border-color: transparent; }
.btn-ghost:hover { background: #732030; color: #fff; }
.btn.full { width: 100%; justify-content: center; }

.btn-tiny {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--ink-2);
  font-size: 11.5px;
  letter-spacing: .02em;
  border: 1px solid var(--line);
  cursor: pointer;
  transition: border-color .18s, color .18s, background .18s;
}
.btn-tiny:hover { background: #732030; color: #fff; border-color: #732030; }
.btn-tiny.ghost { border-color: transparent; }
.btn-tiny.ghost:hover { background: #732030; color: #fff; }
.btn-tiny.accent { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.btn-tiny.accent:hover { filter: brightness(1.08); }

.icon-btn {
  width: 28px; height: 28px;
  display: inline-grid; place-items: center;
  background: transparent;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  color: var(--ink-2);
  cursor: pointer;
  transition: background .18s, color .18s, border-color .18s;
}
.icon-btn:hover { background: #732030; color: #fff; border-color: #732030; }
.icon-btn:disabled { opacity: .35; cursor: not-allowed; }
.ws-inspire-btn {
  height: 28px; padding: 0 12px;
  background: transparent; border: 1px solid var(--line); border-radius: 999px;
  color: var(--ink-2); cursor: pointer; font-size: 11px; font-weight: 500;
  letter-spacing: .02em; white-space: nowrap;
  transition: background .18s, color .18s, border-color .18s;
}
.ws-inspire-btn:hover { background: #732030; color: #fff; border-color: #732030; }
.ws-inspire-btn:focus { outline: none; }
.ws-clear-btn {
  position: absolute; bottom: 10px; left: 50%; transform: translateX(-50%);
  height: 26px; padding: 0 14px;
  background: #6B1D2C; border: none; border-radius: 999px;
  color: #fff; font-size: 10.5px; font-weight: 500; letter-spacing: .04em;
  cursor: pointer; white-space: nowrap; z-index: 5;
  transition: background .14s;
}
.ws-clear-btn:hover { background: #732030; }

/* Segmented controls */
.studio-mode-switch, .surface-switch, .cenefa-piece-switch {
  display: inline-flex;
  background: var(--bg-2);
  border-radius: 999px;
  padding: 3px;
  border: 1px solid var(--line);
}
.seg {
  border: none;
  background: transparent;
  color: var(--ink-2);
  font-family: var(--font-sans);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: .04em;
  padding: 5px 12px;
  border-radius: 999px;
  cursor: pointer;
  transition: background .18s, color .18s;
}
.seg.on { background: var(--bg-elev); color: var(--ink); box-shadow: var(--shadow-sm); }
.seg:disabled { opacity: .35; cursor: not-allowed; }

.chip {
  background: var(--bg-elev);
  border: 1px solid var(--line);
  color: var(--ink-2);
  padding: 5px 11px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: .04em;
  cursor: pointer;
  transition: border-color .18s, color .18s, background .18s;
}
.chip:hover { background: #732030; color: #fff; border-color: #732030; }
.chip.on { background: var(--ink); color: var(--bg-elev); border-color: var(--ink); }
:root[data-dark="true"] .chip.on { background: var(--bg-elev); color: var(--ink); border-color: var(--bg-elev); }

.check-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: var(--ink-2);
  cursor: pointer;
  user-select: none;
}
.check-pill input { accent-color: var(--accent); }

/* ----- Floor grid (shared) ----- */
.floor-view-wrap {
  position: relative;
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  min-height: 0;
  overflow: hidden;
}
/* Botón Rotar — superpuesto sobre el área del suelo (#efeae3); cicla el patrón */
.floor-rotate-btn {
  position: absolute;
  right: 16px;
  bottom: 16px;
  z-index: 6;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: #732030;
  color: #fff;
  border: none;
  border-radius: 999px;
  padding: 9px 18px;
  font-family: inherit;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: .02em;
  cursor: pointer;
  box-shadow: 0 4px 14px -2px rgba(40,30,20,.35);
  transition: background .15s ease, transform .15s ease;
}
.floor-rotate-btn:hover { background: #5e1a27; }
.floor-rotate-btn:active { transform: scale(.96); }
.floor-rotate-btn .floor-rotate-ico { font-size: 15px; line-height: 1; }
.floor-meta {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: .06em;
  color: var(--ink-3);
  text-transform: uppercase;
}
.floor-meta b { color: var(--ink); font-weight: 500; }
.floor-stage {
  background: transparent; /* MT: sin fondo detrás del suelo, solo la baldosa */
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  flex: 1;
  min-height: 0;
  overflow: hidden;
  position: relative;
}
.floor-grid {
  display: grid;
  background: #f8f8f8;
  /* MT: sin marco (se quitó el anillo de 8px) — solo una sombra de apoyo muy sutil */
  box-shadow: 0 14px 36px -22px rgba(40,30,20,.30);
}
.floor-cell {
  position: relative;
  overflow: hidden;
  outline: .5px solid rgba(0,0,0,.04);
}
.floor-cell.is-border::after {
  content: '';
  position: absolute; inset: 0;
  pointer-events: none;
  outline: 1px solid rgba(107,29,44,.12);
  outline-offset: -2px;
}
.skirting { position: absolute; inset: 16px; pointer-events: none; }
.skirting-line { position: absolute; inset: 0; border: 2px solid rgba(40,30,20,.18); border-radius: 2px; }

/* Shared palette */
.palette-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line-soft);
  margin-bottom: 12px;
}
.palette-families { display: flex; flex-direction: column; gap: 14px; }
.palette-fam-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 6px;
}
.palette-fam-name {
  font-size: 9.5px;
  font-weight: 600;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--ink-2);
}
.palette-fam-count {
  font-family: var(--font-mono);
  font-size: 9px;
  color: var(--ink-4);
  letter-spacing: .06em;
}
.pal-color-list {
  display: flex;
  flex-direction: column;
  gap: 1px;
}
.pal-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 5px 6px;
  border-radius: var(--radius-md);
  background: transparent;
  border: 1.5px solid transparent;
  cursor: pointer;
  width: 100%;
  text-align: left;
  transition: background 0.12s, border-color 0.12s;
}
.pal-item:hover { background: var(--bg-2); }
.pal-item-on {
  border-color: var(--accent);
  background: var(--accent-soft);
}
.pal-swatch {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  flex-shrink: 0;
}
.pal-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  overflow: hidden;
  min-width: 0;
}
.pal-top {
  display: flex;
  align-items: baseline;
  gap: 5px;
  min-width: 0;
  line-height: 1.4;
}
.pal-code {
  font-family: var(--font-mono);
  font-size: 11.5px;
  font-weight: 600;
  color: var(--ink);
  white-space: nowrap;
  flex-shrink: 0;
  line-height: 1.4;
}
.pal-desc {
  font-size: 11px;
  color: var(--ink-2);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.4;
}
.pal-ref {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--ink-3);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  display: block;
  line-height: 1.4;
}

/* Mobile: 2-column grid of expanded items */
.mob-pal-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
}

/* ----- AR sheet + modal backdrop ----- */
.ar-sheet-backdrop {
  position: fixed; inset: 0;
  background: rgba(20,15,10,.6);
  z-index: 100000;
  display: grid;
  place-items: center;
  padding: 32px;
  backdrop-filter: blur(6px);
}
.ar-sheet {
  background: var(--bg-elev);
  border-radius: var(--radius-xl);
  width: min(960px, 100%);
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}
.ar-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 20px 24px;
  border-bottom: 1px solid var(--line);
  position: relative;
  z-index: 10;
  flex-shrink: 0;
}
.ar-head h3 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 22px;
  margin: 4px 0 0;
}
.ar-body { display: grid; grid-template-columns: 1fr 220px; flex: 1; min-height: 0; }
.ar-canvas { position: relative; background: #1a1816; overflow: hidden; min-height: 360px; }
.ar-dropzone {
  position: absolute; inset: 20px;
  border: 2px dashed rgba(255,255,255,.25);
  border-radius: var(--radius-md);
  display: grid;
  place-items: center;
  text-align: center;
  color: rgba(255,255,255,.6);
  padding: 28px;
  cursor: pointer;
  transition: border-color .25s, color .25s;
}
.ar-dropzone:hover { border-color: rgba(255,255,255,.5); color: rgba(255,255,255,.9); }
.ar-dropzone p { font-family: var(--font-display); font-size: 20px; margin: 10px 0 4px; color: rgba(255,255,255,.85); }
.ar-dropzone small { font-size: 11px; color: rgba(255,255,255,.5); letter-spacing: .04em; }
.ar-photo { width: 100%; height: 100%; object-fit: cover; display: block; }
.ar-overlay {
  position: absolute; left: 50%; bottom: 0;
  width: 140%; height: 80%;
  transform-origin: center bottom;
  margin-left: -70%;
  pointer-events: none;
}
.ar-grid { display: grid; grid-template-columns: repeat(10, 1fr); }
.ar-controls { padding: 16px; border-left: 1px solid var(--line); display: flex; flex-direction: column; gap: 12px; font-size: 11px; }
.ar-controls label { display: flex; flex-direction: column; gap: 5px; font-weight: 600; letter-spacing: .10em; text-transform: uppercase; color: var(--ink-3); }
.ar-controls input[type=range] { accent-color: var(--accent); }

/* Export/compare modals */
.ws-export-sheet {
  background: var(--bg-elev);
  border-radius: var(--radius-xl);
  width: min(1040px, 100%);
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  position: relative;
}
.export-close-btn {
  position: absolute;
  top: 14px;
  right: 16px;
  z-index: 999;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: none;
  background: var(--bg-2);
  color: var(--ink-2);
  font-size: 16px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background .15s, color .15s, transform .12s;
}
.export-close-btn:hover {
  background: var(--accent);
  color: var(--accent-ink);
  transform: scale(1.1);
}
.export-close-btn:active {
  transform: scale(.93);
}
.ws-export-body { display: grid; grid-template-columns: 3fr 2fr; flex: 1; min-height: 0; overflow: hidden; }
.ws-export-preview {
  display: flex; flex-direction: column;
  border-right: 1px solid var(--line);
  background: var(--bg-2);
  overflow: hidden;
}
.ws-export-floor { flex: 1; min-height: 0; display: flex; flex-direction: column; pointer-events: none; }
.ws-export-summary { padding: 16px 20px; overflow: auto; display: flex; flex-direction: column; }
.ws-export-tiles-row { display: flex; gap: 10px; padding-bottom: 4px; }
.ws-export-tile-detail { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 7px; background: var(--bg-2); border-radius: var(--radius-md); padding: 12px 8px; }
.ws-export-tile-detail svg { filter: drop-shadow(0 4px 12px rgba(40,30,20,.12)); border-radius: 3px; }
.ws-export-tile-label { font-size: 9px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-3); text-align: center; line-height: 1.4; }
.export-row { display: grid; grid-template-columns: 90px 1fr; gap: 12px; padding: 8px 0; font-size: 13px; align-items: start; }
.export-label { font-size: 9.5px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-3); padding-top: 2px; }
.export-val { color: var(--ink); }
.export-divider { height: 1px; background: var(--line-soft); margin: 12px 0; }
.export-row.total { align-items: baseline; }
.price b { font-family: var(--font-display); font-size: 32px; display: block; line-height: 1.1; }
.price small { color: var(--ink-3); font-size: 11px; }
.used-colors { display: flex; flex-wrap: wrap; gap: 5px; }
.used-color { display: inline-flex; align-items: center; gap: 5px; font-size: 10.5px; padding: 2px 7px 2px 3px; background: var(--bg-2); border-radius: 999px; }
.used-color i { width: 11px; height: 11px; border-radius: 50%; box-shadow: inset 0 0 0 1px rgba(0,0,0,.12); }
.export-row-colors { align-items: flex-start; }
.export-color-list { display: flex; flex-direction: column; gap: 2px; padding: 2px 0; }
.export-color-item { display: flex; align-items: center; gap: 8px; padding: 4px 0; }
.export-color-item .pal-swatch { width: 22px; height: 22px; }
.export-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 7px; margin-top: 16px; }
.export-actions .btn-primary { grid-column: 1 / -1; }
.quote-form { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.quote-form label { display: flex; flex-direction: column; gap: 3px; font-size: 10px; color: var(--ink-3); letter-spacing: .08em; text-transform: uppercase; }
.quote-form label.full { grid-column: 1 / -1; }
.quote-form input, .quote-form textarea {
  background: var(--bg); border: 1px solid var(--line);
  border-radius: var(--radius-sm); padding: 8px 10px;
  font-family: var(--font-sans); font-size: 13px; color: var(--ink);
  text-transform: none; letter-spacing: 0;
}
.quote-form input:focus, .quote-form textarea:focus { outline: none; border-color: var(--accent); }

.ws-compare-sheet {
  background: var(--bg-elev); border-radius: var(--radius-xl);
  width: min(1080px, 100%); max-height: 90vh;
  display: flex; flex-direction: column; overflow: hidden; box-shadow: var(--shadow-lg);
}
.ws-compare-body { display: grid; grid-template-columns: 1fr 1fr; gap: 1px; background: var(--line); flex: 1; overflow: auto; }
.ws-compare-col { background: var(--bg-elev); padding: 20px; display: flex; flex-direction: column; align-items: center; gap: 10px; }
.ws-compare-tile { background: var(--bg-2); padding: 14px; border-radius: var(--radius-md); }
.ws-compare-name { font-family: var(--font-display); font-size: 20px; }
.ws-compare-floor { width: 100%; flex: 1; display: flex; justify-content: center; }

/* Editable number */
.editable-number { display: inline-flex; align-items: center; cursor: text; padding: 0 2px; border-radius: 3px; position: relative; transition: background .15s; }
.editable-number:hover { background: var(--accent-soft); }
.editable-number:hover::after { content: '✎'; position: absolute; top: -8px; right: -10px; font-size: 9px; color: var(--accent); }
.editable-number b { font-family: var(--font-mono); font-size: 11px; font-weight: 500; letter-spacing: .04em; color: var(--ink); border-bottom: 1px dashed var(--ink-4); padding-bottom: 1px; }
.editable-number input { width: 52px; font-family: var(--font-mono); font-size: 11px; font-weight: 500; letter-spacing: .04em; color: var(--ink); background: var(--bg-elev); border: 1px solid var(--accent); border-radius: 3px; padding: 2px 5px; outline: none; }
.editable-number input::-webkit-outer-spin-button,
.editable-number input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }

/* ----- Cenefa picker modal ----- */
.cenefa-picker {
  background: var(--bg-elev);
  border-radius: var(--radius-xl);
  width: min(900px, 100%);
  max-height: 88vh;
  display: flex; flex-direction: column; overflow: hidden;
  box-shadow: var(--shadow-lg);
}
.cenefa-picker-sub { font-size: 12px; color: var(--ink-2); margin: 6px 0 0; max-width: 520px; }
.cenefa-picker-sub b { color: var(--ink); }
.cenefa-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1px; background: var(--line); overflow: auto; flex: 1; }
.cenefa-card { background: var(--bg-elev); border: none; padding: 18px; display: flex; flex-direction: column; gap: 12px; cursor: pointer; text-align: left; position: relative; transition: background .2s; }
.cenefa-card:hover { background: var(--bg-2); }
.cenefa-card.is-current { background: var(--accent-soft); }
.cenefa-preview {
  background: repeating-linear-gradient(45deg, rgba(0,0,0,.025), rgba(0,0,0,.025) 1px, transparent 1px, transparent 12px), var(--bg-2);
  padding: 12px; border-radius: var(--radius-md);
}
.cenefa-preview-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 2px; justify-items: center; }
.cenefa-preview-tile { display: flex; flex-direction: column; align-items: center; gap: 4px; }
.cenefa-preview-tile small { font-size: 8px; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-3); font-weight: 600; }
.cenefa-preview-tile svg { background: var(--bg-elev); filter: drop-shadow(0 2px 4px rgba(0,0,0,.08)); }
.cenefa-card-body h4 { font-family: var(--font-display); font-weight: 400; font-size: 20px; margin: 0 0 3px; }
.cenefa-card-body p { font-size: 11.5px; color: var(--ink-2); margin: 0; font-style: italic; }
.cenefa-card-current { position: absolute; top: 12px; right: 12px; background: var(--accent); color: var(--accent-ink); font-size: 8.5px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; padding: 3px 7px; border-radius: 2px; }
.cenefa-chip-swatch { display: inline-block; width: 9px; height: 9px; border-radius: 2px; margin-right: 2px; box-shadow: inset 0 0 0 1px rgba(0,0,0,.12); }

/* =====================================================
   WORKSPACE — 4-column layout
   Col 1: Designs rail (220px)
   Col 2: Palette (230px)
   Col 3: Paint panel (1fr)
   Col 4: Floor panel (1.1fr)
===================================================== */

/* ----- Shell ----- */
.ws-shell {
  display: grid;
  grid-template-columns: 350px 264px minmax(0, 310px) minmax(0, 1fr);
  grid-template-rows: 1fr auto;
  column-gap: 36px;
  height: calc(100vh - 52px - var(--wp-admin--admin-bar--height, 0px));
  background: var(--bg-elev);
  overflow: hidden;
}

:root[data-density="compact"]  .ws-shell { grid-template-columns: 252px 200px minmax(0, 256px) minmax(0, 1fr); column-gap: 24px; }
:root[data-density="spacious"] .ws-shell { grid-template-columns: 320px 256px minmax(0, 340px) minmax(0, 1fr); column-gap: 42px; }

/* ===== RESPONSIVE ===== */

/* Compact desktop */
@media (max-width: 1280px) {
  .ws-shell { grid-template-columns: 290px 214px minmax(0, 276px) minmax(0, 1fr); column-gap: 24px; }
}

/* ---- Tablet: 768–1023px ---- */
/* Left rail sticks, right panels scroll vertically */
@media (min-width: 768px) and (max-width: 1023px) {
  .ws-shell {
    grid-template-columns: 220px 1fr;
    grid-template-rows: auto 1fr auto auto;
    height: auto;
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
  }
  .ws-rail-left {
    grid-column: 1; grid-row: 1 / 5;
    position: sticky;
    top: 0;
    height: calc(100vh - 52px);
    overflow-y: auto;
  }
  .ws-palette-col {
    grid-column: 2; grid-row: 1;
    border-right: none;
    border-bottom: 1px solid var(--line);
    max-height: 38vh;
    overflow-y: auto;
  }
  .ws-paint-panel {
    grid-column: 2; grid-row: 2;
    border-right: none;
    border-bottom: 1px solid var(--line);
    min-height: 56vh;
  }
  .ws-floor-panel {
    grid-column: 2; grid-row: 3;
    border-right: none;
    min-height: 68vh;
  }
  .ws-saved-strip { grid-column: 2; grid-row: 4; }
}

/* ---- Mobile: <768px — bottom tab bar ---- */
@media (max-width: 767px) {
  .app-bar { padding: 0 12px; }

  /* On mobile, shell is just a transparent wrapper — MobilePaintView handles everything */
  .ws-shell {
    display: block;
    height: auto;
    overflow: visible;
  }

  /* Desktop panels hidden on mobile via React inline style, but ensure no bleed */
  .ws-rail-left,
  .ws-palette-col,
  .ws-paint-panel,
  .ws-floor-panel { border-right: none !important; }

  /* Saved strip hidden */
  .ws-saved-strip { display: none !important; }

  /* Tab bar hidden — mobile uses scroll, not tabs */
  .ws-mobile-tabs { display: none !important; }
}

/* ===== MOBILE PAINT VIEW ===== */
.mob-paint-view {
  display: flex;
  flex-direction: column;
  background: var(--bg-elev);
  min-height: calc(100dvh - 52px);
}
.mob-paint-header {
  display: flex;
  gap: 10px;
  padding: 12px 14px;
  flex-shrink: 0;
  background: var(--bg-elev);
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  z-index: 20;
}

/* Step indicator */
.mob-step-bar {
  padding: 10px 16px;
  background: var(--bg-2);
  border-bottom: 1px solid var(--line-soft);
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}
.mob-step-num {
  width: 22px; height: 22px;
  border-radius: 50%;
  background: var(--accent);
  color: var(--accent-ink, #fff);
  font-size: 11px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.mob-step-text {
  font-size: 13px;
  font-weight: 500;
  color: var(--ink);
}
.mob-step-sub {
  font-size: 11px;
  color: var(--ink-3);
  margin-left: auto;
}

/* Empty state (step 1 — no design yet) */
.mob-empty-stage {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  padding: 48px 24px;
  min-height: 260px;
}
.mob-empty-icon {
  width: 90px; height: 90px;
  border: 2px dashed var(--line);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--ink-4);
}
.mob-empty-text {
  font-size: 14px;
  color: var(--ink-3);
  text-align: center;
  line-height: 1.5;
}
.mob-empty-cta {
  font-size: 13px;
  font-weight: 600;
  color: var(--accent);
  background: var(--accent-soft);
  border: 1.5px solid var(--accent);
  border-radius: var(--radius-sm);
  padding: 10px 20px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

/* Scroll CTA — step 3 arrow */
.mob-scroll-cta {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 20px 16px 8px;
  color: var(--ink-2);
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  text-decoration: none;
}
.mob-scroll-cta-text {
  font-size: 13px;
  font-weight: 500;
  color: var(--ink-2);
  text-align: center;
}
.mob-scroll-arrow {
  font-size: 22px;
  animation: bounce-down 1.4s ease-in-out infinite;
  color: var(--accent);
}
@keyframes bounce-down {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(6px); }
}

/* Floor section (below paint canvas, revealed by scroll) */
.mob-floor-section {
  background: var(--bg-elev);
  border-top: 1px solid var(--line);
  padding: 0 0 24px;
}
.mob-floor-section-head {
  padding: 16px 16px 10px;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.mob-floor-view-wrap {
  padding: 0 10px 12px;
  height: min(92vw, 520px);
  display: flex;
  flex-direction: column;
}

/* Cenefa section on mobile */
.mob-cenefa-section {
  margin: 0 12px;
  padding: 16px;
  background: var(--bg-2);
  border-radius: var(--radius-md);
  border: 1px solid var(--line-soft);
}
.mob-cenefa-head {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin-bottom: 10px;
}
.mob-cenefa-thumbs {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 6px;
  margin-bottom: 12px;
}
.mob-cenefa-thumb {
  aspect-ratio: 1;
  background: var(--bg-elev);
  border: 1.5px solid transparent;
  border-radius: 5px;
  padding: 3px;
  cursor: pointer;
  display: grid;
  place-items: center;
  overflow: hidden;
  -webkit-tap-highlight-color: transparent;
  transition: border-color .15s;
}
.mob-cenefa-thumb svg { width: 100% !important; height: 100% !important; }
.mob-cenefa-thumb.on { border-color: var(--accent); background: var(--accent-soft); }

.mob-cenefa-paint-area {
  border-top: 1px solid var(--line-soft);
  padding-top: 12px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}
.mob-cenefa-paint-tile {
  background: var(--bg-elev);
  border-radius: 8px;
  padding: 8px;
  box-shadow: var(--shadow-sm);
}
.mob-cenefa-deact {
  font-size: 11px;
  color: var(--ink-3);
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 5px 14px;
  cursor: pointer;
}
.mob-hdr-btn {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  padding: 10px 12px;
  background: var(--bg-2);
  border: 1.5px solid var(--line);
  border-radius: var(--radius-sm);
  cursor: pointer;
  text-align: left;
  transition: border-color .15s;
  min-width: 0;
}
.mob-hdr-btn:active { opacity: .8; }
.mob-hdr-btn.no-color {
  border-color: var(--accent);
  background: var(--accent-soft);
}
.mob-hdr-btn.has-color {
  border-color: transparent;
}
.mob-hdr-label {
  font-size: 9px;
  font-weight: 600;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.mob-hdr-value {
  font-size: 13px;
  font-weight: 500;
  color: var(--ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}
/* Surface switcher bar (Baldosa / + Añadir cenefa / Cenefa: nombre) */
.mob-surface-bar {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: var(--bg-elev);
  border-bottom: 1px solid var(--line-soft);
  flex-shrink: 0;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.mob-surface-bar::-webkit-scrollbar { display: none; }
.mob-surface-chip {
  height: 28px;
  padding: 0 12px;
  border-radius: 14px;
  border: 1.5px solid var(--line);
  background: transparent;
  color: var(--ink-3);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  white-space: nowrap;
  flex-shrink: 0;
  transition: background .15s, border-color .15s, color .15s;
}
.mob-surface-chip.on {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--accent-ink, #fff);
}
.mob-add-cenefa {
  border-style: dashed;
}
.mob-cenefa-deact-x {
  width: 22px; height: 22px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--ink-3);
  font-size: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  -webkit-tap-highlight-color: transparent;
}
.mob-cenefa-step-dot {
  color: var(--accent);
  font-size: 14px;
  flex-shrink: 0;
}

.mob-tile-stage {
  height: min(65vw, 380px);
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: var(--bg-2);
  overflow: hidden;
  touch-action: manipulation;
}
.mob-tile-stage svg {
  max-width: 100%;
  max-height: 100%;
  width: auto !important;
  height: auto !important;
}
.mob-design-thumb {
  touch-action: manipulation;
}
.mob-paint-hint {
  flex-shrink: 0;
  font-size: 11.5px;
  color: var(--ink-3);
  text-align: center;
  padding: 10px 16px;
  background: var(--bg-elev);
  border-top: 1px solid var(--line-soft);
  margin: 0;
}

/* ===== MOBILE PATTERN SELECTOR ===== */
.mob-pattern-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  background: var(--bg-elev);
  border-top: 1px solid var(--line-soft);
  flex-wrap: wrap;
}
.mob-pattern-label {
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--ink-3);
  flex-shrink: 0;
}

/* Save toast */
.mob-save-toast {
  position: sticky;
  bottom: 72px;  /* just above the action bar */
  z-index: 16;
  margin: 0 14px;
  padding: 10px 16px;
  background: var(--accent);
  color: var(--accent-ink, #fff);
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 600;
  text-align: center;
  box-shadow: 0 4px 16px rgba(0,0,0,.18);
  animation: toast-in .2s cubic-bezier(.2,.7,.2,1);
  pointer-events: none;
}
@keyframes toast-in {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}
.mob-action-saved {
  border-color: var(--accent) !important;
  color: var(--accent) !important;
}

/* ===== MOBILE ACTION BAR (bottom of scroll view) ===== */
.mob-actions-bar {
  position: sticky;
  bottom: 0;
  z-index: 15;
  display: flex;
  gap: 8px;
  padding: 14px 14px;
  background: var(--bg-elev);
  border-top: 1px solid var(--line);
  flex-wrap: wrap;
}
.mob-action-btn {
  flex: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 11px 14px;
  background: transparent;
  border: 1.5px solid var(--line);
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 500;
  color: var(--ink);
  cursor: pointer;
}
.mob-action-primary {
  flex: 1 1 100%;   /* always own row — full width */
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 12px 16px;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}

/* ===== MIS DISEÑOS — badge + sheet ===== */
.mob-saved-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 99px;
  background: var(--accent);
  color: var(--accent-ink, #fff);
  font-size: 11px;
  font-weight: 700;
  line-height: 1;
}
.mob-toast-link {
  display: block;
  margin-top: 4px;
  font-size: 12px;
  font-weight: 500;
  opacity: .88;
  text-decoration: underline;
}

/* Saved sheet list */
.mob-saved-list {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.mob-saved-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 4px;
  border-bottom: 1px solid var(--line);
}
.mob-saved-item:last-child { border-bottom: none; }
.mob-saved-thumbs {
  position: relative;
  flex-shrink: 0;
  width: 62px;
  height: 62px;
  cursor: pointer;
}
.mob-saved-cenefa-thumb {
  position: absolute;
  right: -8px;
  bottom: -8px;
  border: 2px solid var(--bg-elev);
  border-radius: 4px;
  overflow: hidden;
  background: var(--bg-2);
}
.mob-saved-info {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.mob-saved-name {
  font-size: 14px;
  font-weight: 600;
  color: var(--ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.mob-saved-cenefa-name {
  font-size: 11px;
  color: var(--ink-2);
}
.mob-saved-date {
  font-size: 11px;
  color: var(--ink-3);
}
.mob-saved-item-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}
.mob-saved-load-btn {
  height: 32px;
  padding: 0 14px;
  border: 1.5px solid var(--accent);
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--accent);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
}
.mob-saved-del-btn {
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  background: transparent;
  color: var(--ink-3);
  cursor: pointer;
  border-radius: 50%;
}
.mob-saved-del-btn:hover { background: var(--bg-2); color: var(--ink); }

/* Empty state */
.mob-saved-empty {
  padding: 40px 16px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  color: var(--ink-2);
  font-size: 14px;
  line-height: 1.5;
}
.mob-saved-empty p { margin: 0; }

/* ===== MOBILE BOTTOM SHEETS (overlays) ===== */
.mob-sheet-backdrop {
  position: fixed;
  inset: 0;
  z-index: 900;
  background: rgba(0,0,0,.45);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}
.mob-sheet {
  background: var(--bg-elev);
  border-radius: 20px 20px 0 0;
  display: flex;
  flex-direction: column;
  max-height: 90dvh;
  overflow: hidden;
  box-shadow: 0 -8px 40px rgba(0,0,0,.18);
}
.mob-sheet-handle {
  width: 36px;
  height: 4px;
  border-radius: 99px;
  background: var(--line);
  margin: 10px auto 0;
  flex-shrink: 0;
}
.mob-sheet-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px 10px;
  flex-shrink: 0;
}
.mob-sheet-title {
  font-size: 17px;
  font-weight: 600;
  color: var(--ink);
}
.mob-sheet-close {
  width: 30px; height: 30px;
  border-radius: 50%;
  background: var(--bg-2);
  border: none;
  font-size: 14px;
  color: var(--ink-2);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}
.mob-sheet-body {
  overflow-y: auto;
  flex: 1;
  padding: 12px 16px 24px;
  -webkit-overflow-scrolling: touch;
}

/* Design picker inside sheet */
.mob-col-group { margin-bottom: 22px; }
.mob-col-name {
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 400;
  color: var(--ink);
  margin: 0 0 10px;
}
.mob-designs-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
}
.mob-design-thumb {
  background: var(--bg-2);
  border: 1.5px solid transparent;
  border-radius: 6px;
  padding: 4px;
  cursor: pointer;
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  overflow: hidden;
  transition: border-color .15s;
  -webkit-tap-highlight-color: transparent;
}
.mob-design-thumb svg { width: 100% !important; height: 100% !important; }
.mob-design-thumb.on { border-color: var(--accent); background: var(--accent-soft); }

/* Color picker inside sheet */
.mob-color-family { margin-bottom: 18px; }
.mob-color-fam-name {
  font-size: 9px;
  font-weight: 600;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin-bottom: 8px;
}
.mob-color-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 8px;
}
.mob-color-swatch {
  aspect-ratio: 1;
  border-radius: 6px;
  border: 2.5px solid transparent;
  cursor: pointer;
  transition: transform .1s, box-shadow .15s;
  -webkit-tap-highlight-color: transparent;
}
.mob-color-swatch.on {
  box-shadow: 0 0 0 2px var(--bg-elev), 0 0 0 4px var(--accent);
  transform: scale(1.1);
}

/* Desktop/tablet: hide mobile tab bar */
@media (min-width: 768px) {
  .ws-mobile-tabs { display: none !important; }
}

/* ----- Left rail — Designs ----- */
.ws-rail-left {
  grid-column: 1;
  grid-row: 1 / 3;
  background: var(--bg-elev);
  border-right: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.ws-rail-section {
  padding: 14px 14px;
}
.ws-rail-section + .ws-rail-section {
  border-top: 1px solid var(--line-soft);
}
.ws-designs-section {
  flex: 13;
  display: flex;
  flex-direction: column;
  min-height: 0;
  overflow: hidden;
  padding: 2px 6px 12px 10px;
}

/* Collection tabs */
.ws-collections-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  margin-top: 0;
}
.ws-tab {
  background: transparent;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 7px 5px;
  font-family: var(--font-sans);
  font-size: 10.5px;
  font-weight: 500;
  letter-spacing: .04em;
  color: var(--ink-2);
  cursor: pointer;
  transition: all .18s;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.ws-tab:hover { background: #732030; color: #fff; border-color: #732030; }
.ws-tab.on { background: var(--ink); color: var(--bg-elev); border-color: var(--ink); }
:root[data-dark="true"] .ws-tab.on { background: var(--bg-elev); color: var(--ink); }

/* Designs grid */
.ws-designs-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  column-gap: 8px;
  row-gap: 8px;
  overflow-y: auto;
  padding-right: 2px;
  flex: 1;
  margin-top: 4px;
  align-content: start;
}
.ws-design-card {
  background: transparent;
  border: 0;
  border-radius: 2px;
  cursor: pointer;
  position: relative;
  padding-top: 100%; /* intrinsic square: height = column width, no circular dep */
  transition: box-shadow .15s;
  overflow: hidden;
}
.ws-design-card:hover {
  box-shadow: inset 0 0 0 2px #732030;
  z-index: 2;
}
.ws-design-card.on {
  box-shadow: inset 0 0 0 2px var(--accent);
}
.ws-design-card-art {
  position: absolute;
  inset: 0;
  overflow: hidden;
}
.ws-design-card-art svg {
  display: block;
  width: 100% !important;
  height: 100% !important;
}


/* Cursor-following tooltip for design/cenefa cards */
.design-tip {
  position: fixed;
  z-index: 9999;
  pointer-events: none;
  background: rgba(18,10,3,.80);
  color: #fff;
  font-family: var(--font-sans);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: .01em;
  padding: 3px 8px 4px;
  border-radius: 5px;
  white-space: nowrap;
  max-width: 160px;
  overflow: hidden;
  text-overflow: ellipsis;
  box-shadow: 0 2px 8px rgba(0,0,0,.22);
  transform: translate(14px, 6px);
}

.ws-design-current {
  position: absolute;
  top: 4px;
  right: 4px;
  font-size: 7px;
  color: var(--accent);
  line-height: 1;
}

/* ----- Palette column ----- */
.ws-palette-col {
  grid-column: 2;
  grid-row: 1 / 3;
  background: var(--bg-elev);
  border-right: 1px solid var(--line);
  overflow-y: auto;
  overflow-x: hidden;
}
.ws-palette-col .palette {
  padding: 14px 14px;
}

/* ----- Paint panel ----- */
.ws-paint-panel {
  grid-column: 3;
  grid-row: 1;
  background: var(--bg-elev);
  border-left: 1px solid var(--line);
  border-right: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  min-height: 0;
}
.ws-paint-inner {
  display: flex;
  flex-direction: column;
  flex: 1;
  overflow: hidden;
  padding: 14px 16px;
  gap: 10px;
}
.ws-panel-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
  flex-shrink: 0;
}
.ws-paint-tools {
  display: flex;
  gap: 3px;
  flex-shrink: 0;
}

/* Paint tile container — smaller */
.ws-paint-tile {
  background:
    repeating-linear-gradient(45deg, var(--bg-2), var(--bg-2) 7px, transparent 7px, transparent 14px),
    var(--bg-elev);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-md);
  flex: 1;
  min-height: 0;
  display: grid;
  place-items: center;
  position: relative;
  overflow: hidden;
}
.ws-paint-tile svg {
  background: var(--bg-elev);
  filter: drop-shadow(0 6px 18px rgba(40,30,20,.14));
  border-radius: 4px;
  max-width: 100%;
  max-height: 100%;
}
.ws-paint-tile svg.is-hex {
  background: transparent;
  border-radius: 0;
}

/* Zone tooltip on hover */
.ws-zone-tooltip {
  position: absolute;
  display: flex;
  align-items: center;
  gap: 6px;
  background: var(--ink);
  color: var(--bg-elev);
  font-size: 10.5px;
  font-weight: 500;
  padding: 4px 10px 4px 6px;
  border-radius: 999px;
  pointer-events: none;
  white-space: nowrap;
  transform: translate(-50%, -130%);
  box-shadow: var(--shadow-md);
  z-index: 10;
  letter-spacing: .02em;
}
.ws-zone-tooltip i {
  width: 10px; height: 10px;
  border-radius: 50%;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.2);
  flex-shrink: 0;
}

/* Paint hint */
.ws-paint-hint {
  font-size: 11px;
  color: var(--ink-3);
  text-align: center;
  flex-shrink: 0;
  line-height: 1.5;
}
.ws-paint-hint b { color: var(--ink-2); font-weight: 500; }

/* Surface switch */
.ws-surface-switch, .ws-piece-switch { align-self: flex-start; flex-shrink: 0; }

/* Paint empty state */
.paint-empty { font-style: italic; color: var(--ink-3); padding: 60px 20px; text-align: center; }

/* ----- Floor panel ----- */
.ws-floor-panel {
  grid-column: 4;
  grid-row: 1;
  background: var(--bg-elev);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  min-height: 0;
}
.ws-floor-inner {
  display: flex;
  flex-direction: column;
  flex: 1;
  overflow: hidden;
  padding: 14px 14px;
  gap: 10px;
}
.ws-floor-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
  flex-shrink: 0;
}
.ws-floor-head-left { display: flex; flex-direction: column; gap: 4px; }
.ws-floor-head-right { display: flex; align-items: center; gap: 6px; flex-shrink: 0; }
.ws-vista-title {
  font-family: var(--font-sans);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.ws-floor-meta {
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: .06em;
  color: var(--ink-4);
  text-transform: uppercase;
}

/* Pattern chips row */
.ws-pattern-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
  flex-wrap: wrap;
}
.ws-pattern-row .eyebrow { min-width: 52px; font-size: 9px; }
.ws-pattern-chips { display: flex; gap: 4px; flex-wrap: wrap; }

/* ---- Visual cenefa section ---- */
.ws-cenefa-section {
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex-shrink: 0;
  padding-top: 10px;
  border-top: 1px solid var(--line-soft);
}

/* ---- Cenefa section inside the left designs rail ---- */
.ws-cenefa-rail {
  flex: 10;
  min-height: 0;
  padding: 0 6px 10px 10px;
  border-top: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  gap: 0;
  overflow-y: auto;
  overflow-x: hidden;
}
.ws-cenefa-rail-head {
  position: sticky;
  top: 0;
  z-index: 2;
  background: var(--bg-elev);
  padding: 14px 0 8px;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 6px;
}
.ws-cenefa-rail-title {
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: .10em;
  text-transform: uppercase;
  color: var(--ink-1);
}
.ws-cenefa-rail-hint {
  font-size: 9px;
  color: var(--ink-4);
}
.ws-cenefa-rail-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 4px;
}
.ws-cenefa-deactivate {
  font-size: 9px;
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--ink-3);
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 5px 8px;
  cursor: pointer;
  transition: all .15s;
  white-space: nowrap;
}
.ws-cenefa-deactivate:hover {
  border-color: var(--ink-3);
  color: var(--ink);
}
.ws-cenefa-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.ws-cenefa-title { font-size: 9px; font-weight: 600; letter-spacing: .18em; text-transform: uppercase; color: var(--ink-3); }
.ws-cenefa-toggle {
  display: flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
}
.ws-cenefa-toggle-track {
  width: 30px; height: 16px;
  border-radius: 999px;
  background: var(--bg-3);
  border: 1px solid var(--line);
  position: relative;
  transition: background .2s, border-color .2s;
  cursor: pointer;
}
.ws-cenefa-toggle-track.on { background: var(--accent); border-color: var(--accent); }
.ws-cenefa-toggle-thumb {
  position: absolute;
  top: 2px; left: 2px;
  width: 10px; height: 10px;
  border-radius: 50%;
  background: white;
  box-shadow: 0 1px 2px rgba(0,0,0,.2);
  transition: transform .18s;
}
.ws-cenefa-toggle-track.on .ws-cenefa-toggle-thumb { transform: translateX(14px); }
.ws-cenefa-toggle-label { font-size: 11px; font-weight: 500; color: var(--ink-2); cursor: pointer; }

/* Visual cenefa cards row */
.ws-cenefa-cards {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 4px;
  animation: fadeIn .18s ease;
}
@keyframes fadeIn { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }
.ws-cenefa-card-btn {
  background: var(--bg-2);
  border: 1.5px solid transparent;
  border-radius: var(--radius-sm);
  padding: 6px 4px;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  transition: all .18s;
}
.ws-cenefa-card-btn:hover { background: var(--bg-3); transform: translateY(-1px); box-shadow: var(--shadow-sm); }
.ws-cenefa-card-btn.active { background: var(--accent-soft); border-color: var(--accent); }
.ws-cenefa-thumb { display: grid; place-items: center; }
.ws-cenefa-card-name {
  font-size: 8.5px;
  font-weight: 500;
  color: var(--ink-3);
  letter-spacing: .02em;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}
.ws-cenefa-card-btn.active .ws-cenefa-card-name { color: var(--accent); }
.ws-cenefa-paint-row {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

/* ----- Floor actions bar (inside floor panel) ----- */
.ws-floor-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
  padding-top: 10px;
  border-top: 1px solid var(--line-soft);
}
.ws-action-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 7px 10px;
  background: transparent;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  color: var(--ink-2);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: .02em;
  cursor: pointer;
  transition: all .18s;
  white-space: nowrap;
}
.ws-action-btn:hover { background: #732030; color: #fff; border-color: #732030; }
.ws-action-btn.primary {
  background: var(--accent);
  color: var(--accent-ink);
  border-color: var(--accent);
  flex: 1;
  justify-content: center;
}
.ws-action-btn.primary:hover { filter: brightness(1.08); }

/* ----- Saved strip (bottom, col 3+4) ----- */
.ws-saved-strip {
  grid-column: 3 / 5;
  grid-row: 2;
  background: var(--bg-elev);
  border-top: 1px solid var(--line);
  padding: 10px 16px;
  flex-shrink: 0;
}
.ws-saved-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 7px;
}
.ws-saved-row {
  display: flex;
  align-items: center;
  gap: 7px;
  overflow-x: auto;
  padding-bottom: 2px;
}
.ws-saved-row::-webkit-scrollbar { height: 4px; }
.ws-saved-card {
  flex-shrink: 0;
  background: var(--bg-2);
  border: 1.5px solid var(--line-soft);
  border-radius: var(--radius-sm);
  padding: 5px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  position: relative;
}
.ws-saved-card.is-compared { border-color: var(--accent); background: var(--accent-soft); }
.ws-saved-new {
  cursor: pointer;
  justify-content: center;
  width: 88px; height: 88px;
  border-style: dashed;
  border-color: var(--line);
  color: var(--ink-3);
  font-size: 9.5px;
  letter-spacing: .04em;
  text-align: center;
  padding: 6px;
  transition: all .2s;
}
.ws-saved-new:hover { border-color: var(--accent); color: var(--accent); }
.ws-plus { font-size: 20px; font-weight: 300; line-height: 1; }
.ws-saved-art { background: var(--bg-elev); padding: 3px; border-radius: 2px; cursor: pointer; transition: transform .15s; }
.ws-saved-art:hover { transform: scale(1.05); }
.ws-saved-actions { display: flex; gap: 3px; }
.ws-saved-compare, .ws-saved-del { width: 17px; height: 17px; border: none; background: var(--bg-elev); border-radius: 50%; font-size: 8px; color: var(--ink-3); cursor: pointer; display: grid; place-items: center; }
.ws-saved-compare.on { background: var(--accent); color: var(--accent-ink); }
.ws-saved-del:hover { color: var(--accent); }
.ws-compare-cta { margin-left: 6px; flex-shrink: 0; }

/* ----- Ambientes sheet ----- */
.amb-sheet {
  width: min(900px, 100%);
  max-height: 90vh;
  background: var(--bg-elev);
  border-radius: var(--radius-lg);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  position: relative;
}
.amb-tabs {
  display: flex;
  gap: 4px;
}
.amb-tab {
  appearance: none;
  border: none;
  background: transparent;
  color: var(--ink-3);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .05em;
  text-transform: uppercase;
  padding: 5px 10px;
  border-radius: 6px;
  cursor: pointer;
  transition: background .15s, color .15s;
}
.amb-tab:hover { background: var(--bg-2); color: var(--ink-1); }
.amb-tab.active { background: var(--accent); color: var(--accent-ink); }
.amb-body {
  flex: 1;
  min-height: 480px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  background: #1a1714;
  overflow: hidden;
}
/*
 * .amb-room mirrors old simulator .ambiente:
 *   - NO explicit width/height — it wraps its image content
 *   - overflow:hidden clips the oversized .amb-bg div
 *   - The .bg 3D transforms use % of this element, so it MUST match the image size
 */
.amb-room {
  display: none;
  position: relative;
  overflow: hidden;
  flex-direction: column;
}
.amb-room.active {
  display: flex;
}
.amb-photo {
  display: block;
  position: relative;
  z-index: 3;            /* PNG del ambiente SOBRE el patrón → muebles tapan las baldosas */
  width: auto;
  height: auto;
  max-height: 500px;
  max-width: calc(min(900px, 100vw) - 2px);
}
/* Patrón proyectado en el suelo. Metodología idéntica al simulador clásico en producción.
   Densidad: el clásico rasteriza un bloque de 8 columnas y lo repite con background-size
   25/15/15/28%. buildFloorBg entrega un bloque de 4 columnas → background-size = clásico ÷ 2
   (mismo nº de baldosas proyectadas → tamaño proporcional y realista). Transforms 3D
   idénticos al clásico. */
.amb-bg {
  position: absolute;
  z-index: 1;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background-repeat: repeat;
  background-position: center;
}
.amb-bg.bg0 {
  width: 180%; height: 180%; top: -25%; left: -25%;
  background-size: 12.5% auto;
  transform: perspective(122px) scaleZ(.1) rotateX(74deg) rotateZ(90deg) rotateY(0);
}
.amb-bg.bg1 {
  width: 180%; height: 180%; top: -30%; left: -25%;
  background-size: 7.5% auto;
  transform: perspective(632px) scaleZ(1.2) rotateX(70deg) rotateZ(51deg) rotateY(0deg);
}
.amb-bg.bg2 {
  width: 180%; height: 180%; top: -25%; left: -25%;
  background-size: 7.5% auto;
  transform: perspective(933px) scaleZ(1) rotateX(72deg) rotateY(1deg) rotateZ(-3deg);
}
.amb-bg.bg3 {
  width: 180%; height: 180%; top: -25%; left: -25%;
  background-size: 14% auto;
  transform: perspective(720px) scaleZ(1) rotateX(70deg) rotateY(0deg) rotateZ(0deg);
}
/* Loading placeholder shown while server renders the composite */
.amb-loading {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 320px;
  max-height: 500px;
  background: #1a1714;
  color: rgba(255,255,255,.45);
  font-size: 13px;
}
@keyframes amb-spin { to { transform: rotate(360deg); } }
.amb-spinner {
  display: inline-block;
  width: 32px; height: 32px;
  border: 3px solid rgba(255,255,255,.15);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: amb-spin .8s linear infinite;
}
.amb-hint { opacity: .6; }
.amb-footer {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 16px;
  background: rgba(20,15,10,.55);
  backdrop-filter: blur(8px);
}
.amb-hint {
  font-size: 11px;
  color: rgba(255,255,255,.6);
}
.amb-refresh {
  font-size: 11px;
  padding: 5px 12px;
  height: auto;
  border-color: rgba(255,255,255,.3);
  color: rgba(255,255,255,.85);
}
.amb-refresh:hover { border-color: rgba(255,255,255,.7); color: #fff; }

/* ----- Scrollbar ----- */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--line); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--ink-4); }

/* ===== MOBILE MODALS: Ambientes + Export como bottom sheets ===== */
@media (max-width: 767px) {

  /* Backdrop: de centrado a bottom-aligned, sin padding lateral */
  .ar-sheet-backdrop {
    padding: 0;
    align-items: end;           /* grid: empuja los hijos al fondo */
  }

  /* Handle visual (drag indicator) en la parte superior de cada sheet */
  .amb-sheet::before,
  .ws-export-sheet::before {
    content: '';
    display: block;
    width: 40px;
    height: 4px;
    background: var(--line);
    border-radius: 2px;
    margin: 10px auto 4px;
    flex-shrink: 0;
  }

  /* ---- Ambientes Sheet ---- */
  .amb-sheet {
    width: 100%;
    max-height: 93dvh;
    border-radius: 18px 18px 0 0;
  }

  /* Header: envuelve al siguiente renglón si no cabe */
  .ar-head {
    padding: 12px 16px 10px;
    flex-wrap: wrap;
    gap: 6px;
    align-items: flex-start;
  }
  .ar-head > div:first-child {
    flex: 1 1 100%;         /* título ocupa toda la primera línea */
  }
  .ar-head h3 { font-size: 17px; margin-top: 2px; }

  /* Tabs: segunda fila, scrollable horizontal */
  .amb-tabs {
    flex: 1 1 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding-bottom: 2px;
    display: flex;
    gap: 4px;
  }
  .amb-tabs::-webkit-scrollbar { display: none; }

  /* Body: sin min-height forzado, scrollable */
  .amb-body {
    min-height: 0;
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
  }

  /* Room: full width, foto ocupa el ancho disponible */
  .amb-room { width: 100%; }
  .amb-photo {
    width: 100%;
    height: auto;
    max-height: none;
    max-width: 100%;
  }

  /* ---- Export Sheet ---- */
  .ws-export-sheet {
    width: 100%;
    max-height: 95dvh;
    border-radius: 18px 18px 0 0;
    display: flex;
    flex-direction: column;
  }

  /* Cuerpo: columna en lugar de grid 2-col */
  .ws-export-body {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
    overflow: hidden;
  }

  /* Preview del suelo: franja compacta en la parte superior */
  .ws-export-preview {
    border-right: none;
    border-bottom: 1px solid var(--line);
    height: 54vw;
    max-height: 280px;
    flex-shrink: 0;
    overflow: hidden;
  }

  /* Summary: ocupa el resto, scrollable internamente */
  .ws-export-summary {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
    padding: 12px 16px 24px;
  }

  /* Tile detail row: más compacto */
  .ws-export-tiles-row { gap: 8px; }
  .ws-export-tile-detail { padding: 8px 6px; }

  /* Precio más compacto */
  .price b { font-size: 26px; }

  /* Formulario: 1 columna */
  .quote-form { grid-template-columns: 1fr; }

  /* Acciones: apiladas */
  .export-actions { grid-template-columns: 1fr; }
  .export-actions .btn-primary { grid-column: 1; }

  /* Header del export: compacto */
  .ws-export-sheet .ar-head {
    padding: 12px 46px 12px 16px;   /* deja espacio para el ✕ absoluto */
  }
  .ws-export-sheet .ar-head h3 { font-size: 16px; }
}

/* =====================================================
   GUÍA PANTONE · RAL — botón y modal
===================================================== */
.ws-pg-guide-btn {
  display: block;
  width: calc(100% - 28px);
  margin: 12px 14px 8px;
  padding: 0 12px;
  height: 32px;
  background: transparent;
  border: 1px solid var(--accent);
  border-radius: 999px;
  color: var(--accent);
  font-family: var(--font-sans);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.08em;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
  white-space: nowrap;
}
.ws-pg-guide-btn:hover {
  background: #732030;
  border-color: #732030;
  color: #fff;
}

/* Overlay */
.pg-overlay {
  position: fixed;
  inset: 0;
  background: rgba(20, 16, 14, 0.55);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

/* Modal box */
.pg-modal {
  background: var(--bg-elev);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-lg);
  width: 100%;
  max-width: 780px;
  max-height: 82vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.pg-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px 14px;
  border-bottom: 1px solid var(--line);
  flex-shrink: 0;
}
.pg-title {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 600;
  color: var(--ink);
  letter-spacing: 0.02em;
}
.pg-close {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: transparent;
  cursor: pointer;
  font-size: 14px;
  color: var(--ink-2);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s, color 0.15s;
}
.pg-close:hover {
  background: #732030;
  border-color: #732030;
  color: #fff;
}

.pg-body {
  overflow-y: auto;
  flex: 1;
  padding: 16px 20px 24px;
}

.pg-family {
  margin-bottom: 20px;
}
.pg-fam-label {
  font-family: var(--font-sans);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin-bottom: 8px;
  padding-bottom: 4px;
  border-bottom: 1px solid var(--line-soft);
}

.pg-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
}

.pg-pick-hint {
  padding: 6px 20px 0;
  font-family: var(--font-sans);
  font-size: 11px;
  color: var(--ink-3);
  text-align: center;
}

.pg-item {
  display: grid;
  grid-template-columns: 40px 1fr;
  grid-template-rows: auto auto auto;
  column-gap: 10px;
  row-gap: 1px;
  align-items: start;
  padding: 8px 10px;
  border-radius: var(--radius-md);
  background: var(--bg);
  border: 2px solid transparent;
  transition: border-color 0.12s, background 0.12s;
}
.pg-item-pick {
  cursor: pointer;
}
.pg-item-pick:hover {
  background: var(--bg-2);
  border-color: var(--line);
}
.pg-item-active {
  border-color: var(--accent) !important;
  background: var(--accent-soft) !important;
}

.pg-swatch {
  grid-row: 1 / 4;
  grid-column: 1;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid rgba(0,0,0,0.08);
  flex-shrink: 0;
  align-self: center;
  display: flex;
  align-items: center;
  justify-content: center;
}
.pg-swatch-check {
  font-size: 14px;
  font-weight: 700;
  line-height: 1;
  mix-blend-mode: difference;
  color: #fff;
  pointer-events: none;
}

.pg-name {
  grid-column: 2;
  display: flex;
  flex-direction: column;
  gap: 1px;
  overflow: hidden;
}
.pg-name span {
  font-family: var(--font-sans);
  font-size: 11px;
  font-weight: 400;
  color: var(--ink-2);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.pg-code-badge {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  color: var(--ink) !important;
  letter-spacing: 0.04em;
}

.pg-code {
  grid-column: 2;
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--ink-3);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Guía Pantone button inside mobile color picker */
.mob-pg-guide-btn {
  display: block;
  width: 100%;
  margin: 0 0 14px;
  padding: 0 14px;
  height: 36px;
  background: transparent;
  border: 1px solid var(--accent);
  border-radius: 999px;
  color: var(--accent);
  font-family: var(--font-sans);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}
.mob-pg-guide-btn:hover,
.mob-pg-guide-btn:active {
  background: #732030;
  border-color: #732030;
  color: #fff;
}

@media (max-width: 560px) {
  .pg-grid { grid-template-columns: 1fr; }
  .pg-overlay { padding: 0; align-items: flex-end; }
  .pg-modal {
    max-width: 100%;
    border-radius: var(--radius-xl) var(--radius-xl) 0 0;
    max-height: 88vh;
  }
}
