/* ══════════════════════════════════════════
   Visual Interpreter V2 — Styles
   ══════════════════════════════════════════ */

@font-face {
  font-family: 'Satori';
  src: url('./Assets_design/Satori-Medium.woff2') format('woff2');
  font-weight: 500;
  font-style: normal;
}
@font-face {
  font-family: 'Satori';
  src: url('./Assets_design/Satori-Bold.woff2') format('woff2');
  font-weight: 700;
  font-style: normal;
}

*,*::before,*::after{box-sizing:border-box;margin:0;padding:0}
html,body{height:100%;overflow:hidden;font-family:'Satori',sans-serif;background-color:#f9fafb;background-image:url('Assets_design/mini bonilhas.png');background-repeat:repeat;color:#1a1a1a}
.app{display:flex;height:100vh;position:relative}

.sidebar{
  width:380px;min-width:300px;max-width:500px;background:#f9fafb;border-right:1px solid #e5e5e5;
  overflow:visible;padding:20px;display:flex;flex-direction:column;border-radius:10px;
  transition:transform .35s cubic-bezier(.4,0,.2,1);position:relative;z-index:20;flex-shrink:0;
}
.sidebar>*{margin-bottom:0}
.sidebar>*:last-child{margin-bottom:0}
.sidebar.collapsed{transform:translateX(-100%);position:absolute;top:0;bottom:0;left:0;pointer-events:none}
body:not(.is-compact-ui) .sidebar.collapsed{pointer-events:auto}
.sidebar.compact-mode{overscroll-behavior:contain}
.sidebar.compact-mode.collapsed{transform:translateX(calc(-100% - 28px))}
.sidebar-backdrop{
  position:fixed;
  inset:0;
  background:rgba(15,15,15,0.14);
  backdrop-filter:blur(4px);
  -webkit-backdrop-filter:blur(4px);
  opacity:0;
  pointer-events:none;
  transition:opacity .22s ease;
  z-index:18;
}
.sidebar-backdrop.show{
  opacity:1;
  pointer-events:auto;
}
.fullscreen-exit-btn{
  position:fixed;
  top:24px;
  right:24px;
  width:56px;
  height:56px;
  border:none;
  border-radius:50%;
  background:rgba(255,255,255,0.94);
  color:#1f1f1f;
  box-shadow:0 12px 28px rgba(0,0,0,0.16);
  display:flex;
  align-items:center;
  justify-content:center;
  opacity:0;
  pointer-events:none;
  transform:scale(.88);
  transition:opacity .18s ease, transform .18s ease;
  z-index:175;
}
.fullscreen-exit-btn:hover{transform:scale(.96)}
body.is-ui-fullscreen.is-fullscreen-exit-visible .fullscreen-exit-btn{
  opacity:1;
  pointer-events:auto;
  transform:scale(1);
}
.sidebar-reveal-btn{
  position:fixed;
  left:20px;
  top:50%;
  transform:translateY(-50%);
  height:48px;
  padding:0 16px 0 14px;
  border:none;
  border-radius:24px 0 0 0;
  background:rgba(255,255,255,0.95);
  color:#1f1f1f;
  display:none;
  align-items:center;
  gap:10px;
  cursor:pointer;
  box-shadow:0 14px 34px rgba(0,0,0,0.12);
  z-index:58;
}
.sidebar-reveal-btn:hover{transform:translateY(-50%) scale(1.02)}
.sidebar-reveal-btn svg{flex:0 0 auto}
.sidebar-reveal-label{
  font-size:12px;
  font-weight:700;
  letter-spacing:0.01em;
}
body:not(.is-compact-ui) .sidebar-reveal-btn{display:none !important}
.mobile-history-slot{display:none}
.camera-btn-mobile-only{display:none}
/* Editor panel children separators */
#editorPanel{display:flex;flex-direction:column;overflow-y:auto;overflow-x:hidden;border-radius:0 0 24px 24px;min-height:0;padding:0 0 24px !important}
#editorPanel::-webkit-scrollbar { display:none; }
#editorPanel { -ms-overflow-style:none; scrollbar-width:none; }
#uploadPanel{display:flex;flex-direction:column;gap:16px}

/* Hide scrollbar but keep scroll functionality */
.sidebar::-webkit-scrollbar{display:none}
.sidebar{scrollbar-width:none;-ms-overflow-style:none}

.brand h1{font-size:28px;font-weight:900;letter-spacing:-.5px;color:#111}
hr{border:none;border-top:1px solid #f0eeeb;margin:0}

.editor-brand{
  justify-content:center;
}

.editor-file-name-shell{
  position:absolute;
  left:50%;
  top:50%;
  transform:translate(-50%, -50%);
  display:flex;
  align-items:center;
  justify-content:center;
  min-width:0;
  max-width:calc(100% - 136px);
}

.editor-file-name-btn{
  border:none;
  background:transparent;
  padding:8px 14px;
  margin:0;
  border-radius:999px;
  display:flex;
  align-items:center;
  justify-content:center;
  cursor:text;
  transition:background .16s ease, transform .16s cubic-bezier(.23,1,.32,1);
}

.editor-file-name-btn:hover{
  background:#f5f5f3;
}

.editor-file-name-btn:active{
  transform:scale(.985);
}

.editor-brand .editor-brand-title{
  position:static;
  transform:none;
  margin:0;
  font-family:'neue-haas-grotesk-text', 'neue-haas-grotesk-display', sans-serif;
  font-size:14px !important;
  font-weight:500 !important;
  letter-spacing:0;
  color:#1f1f1f;
  line-height:1;
  pointer-events:none;
  max-width:220px;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}

.editor-file-name-editor{
  position:absolute;
  inset:0;
  display:flex;
  align-items:center;
  justify-content:center;
  gap:0;
  min-width:0;
  padding:8px 14px;
  border-radius:999px;
  background:transparent;
  box-shadow:none;
  opacity:0;
  pointer-events:none;
}

.editor-file-name-shell.is-editing .editor-file-name-btn{
  visibility:hidden;
}

.editor-file-name-shell.is-editing .editor-file-name-editor{
  opacity:1;
  pointer-events:auto;
}

.editor-file-name-input{
  min-width:0;
  width:140px;
  border:none;
  background:transparent;
  padding:0;
  margin:0;
  color:#1f1f1f;
  font-family:'neue-haas-grotesk-text', 'neue-haas-grotesk-display', sans-serif;
  font-size:14px;
  font-weight:500;
  line-height:1;
  outline:none;
  text-align:center;
  flex:0 1 auto;
  max-width:100%;
}

.editor-file-name-ext{
  flex:0 0 auto;
  font-family:'neue-haas-grotesk-text', 'neue-haas-grotesk-display', sans-serif;
  font-size:14px;
  font-weight:500;
  color:#1f1f1f;
  line-height:1;
}

.editor-menu-wrap{
  position:absolute;
  top:50%;
  right:14px;
  transform:translateY(-50%);
  z-index:180;
  isolation:isolate;
}

.editor-menu-btn{
  width:40px;
  height:40px;
  border:none;
  border-radius:999px;
  background:transparent;
  color:#1f1f1f;
  display:flex;
  align-items:center;
  justify-content:center;
  gap:4px;
  cursor:pointer;
  transition:background .16s ease, transform .16s cubic-bezier(.23,1,.32,1);
}

.editor-menu-btn span{
  width:4px;
  height:4px;
  border-radius:50%;
  background:currentColor;
}

.editor-menu-btn:hover{
  background:#f5f5f3;
}

.editor-menu-btn:active,
.editor-menu-wrap.is-open .editor-menu-btn{
  transform:scale(.97);
  background:#f3f4f6;
}

.editor-menu-popover{
  position:absolute;
  top:calc(100% + 10px);
  left:0;
  right:auto;
  width:244px;
  min-height:0;
  overflow:visible;
  opacity:0;
  pointer-events:none;
  transform:translateY(-8px) scale(.98);
  transform-origin:top left;
  transition:opacity .18s ease, transform .18s cubic-bezier(.23,1,.32,1);
}

.editor-menu-wrap.is-open .editor-menu-popover{
  opacity:1;
  pointer-events:auto;
  transform:translateY(0) scale(1);
}

.editor-menu-card{
  position:absolute;
  top:0;
  left:0;
  width:244px;
  padding:10px;
  border-radius:24px;
  background:rgba(255,255,255,0.98);
  box-shadow:0 20px 48px rgba(0,0,0,0.12), 0 1px 0 rgba(255,255,255,0.9) inset;
  backdrop-filter:blur(18px);
  -webkit-backdrop-filter:blur(18px);
  display:flex;
  flex-direction:column;
  gap:2px;
  opacity:0;
  visibility:hidden;
  pointer-events:none;
  transform:translateX(-8px) scale(.985);
  transition:opacity .16s ease, transform .16s cubic-bezier(.23,1,.32,1), visibility .16s ease;
}

.editor-menu-card-quality::before,
.editor-menu-card-export::before,
.editor-menu-card-html::before{
  content:'';
  position:absolute;
  top:0;
  left:-14px;
  width:14px;
  height:100%;
  pointer-events:auto;
}

.editor-menu-wrap.is-open .editor-menu-card-main{
  opacity:1;
  visibility:visible;
  pointer-events:auto;
  transform:translateX(0) scale(1);
}

.editor-menu-popover[data-branch="quality"] .editor-menu-card-quality,
.editor-menu-popover[data-branch="export"] .editor-menu-card-export,
.editor-menu-popover[data-branch="export-html"] .editor-menu-card-export,
.editor-menu-popover[data-branch="export-html"] .editor-menu-card-html{
  opacity:1;
  visibility:visible;
  pointer-events:auto;
  transform:translateX(0) scale(1);
}

.editor-menu-card-quality,
.editor-menu-card-export{
  left:calc(100% + 8px);
}

.editor-menu-card-html{
  left:calc(200% + 16px);
}

.editor-menu-item{
  position:relative;
  width:100%;
  min-height:46px;
  border:none;
  background:transparent;
  border-radius:16px;
  padding:0 14px;
  color:#1f1f1f;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  text-align:left;
  font-size:14px;
  font-weight:450;
  letter-spacing:0;
  cursor:pointer;
  transition:background .14s ease, transform .14s cubic-bezier(.23,1,.32,1), color .14s ease;
}

.editor-menu-item-back{
  display:none;
  justify-content:flex-start;
  gap:8px;
}

.editor-menu-back-icon{
  flex:0 0 auto;
  color:#b3b3b3;
  font-size:22px;
  line-height:1;
  margin-left:-2px;
}

.editor-menu-item[data-action^="quality-"]{
  padding-left:28px;
}

.editor-menu-item[data-action^="quality-"]::before{
  content:'';
  position:absolute;
  left:14px;
  top:50%;
  width:8px;
  height:8px;
  border-radius:50%;
  opacity:0;
  transform:translateY(-50%) scale(.7);
  transition:opacity .14s ease, transform .14s cubic-bezier(.23,1,.32,1);
}

.editor-menu-item[data-action="quality-1x"]::before{background:#22c55e}
.editor-menu-item[data-action="quality-2x"]::before{background:#f59e0b}
.editor-menu-item[data-action="quality-3x"]::before{background:#ef4444}
.editor-menu-item[data-action^="quality-"].is-active::before{
  opacity:1;
  transform:translateY(-50%) scale(1);
}

.editor-menu-item:hover,
.editor-menu-item:focus-visible,
.editor-menu-item.is-active{
  background:#f5f5f3;
}

.editor-menu-item:active{
  transform:scale(.985);
}

.editor-menu-item.is-disabled{
  color:#b8b8b8;
  cursor:not-allowed;
}

.editor-menu-item.is-disabled:hover,
.editor-menu-item.is-disabled:focus-visible{
  background:#f8f8f7;
}

.editor-menu-item.is-disabled::after{
  content:attr(data-disabled-reason);
  position:absolute;
  top:50%;
  right:calc(100% + 12px);
  width:220px;
  padding:10px 12px;
  border-radius:14px;
  background:rgba(31,31,31,0.96);
  color:#fff;
  font-size:12px;
  font-weight:400;
  line-height:1.35;
  opacity:0;
  visibility:hidden;
  pointer-events:none;
  transform:translateY(-50%) translateX(4px);
  transition:opacity .14s ease, transform .14s ease, visibility .14s ease;
  z-index:4;
}

.editor-menu-item.is-disabled:hover::after,
.editor-menu-item.is-disabled:focus-visible::after{
  opacity:1;
  visibility:visible;
  transform:translateY(-50%) translateX(0);
}

.editor-menu-meta{
  flex:0 0 auto;
  color:#b3b3b3;
  font-size:13px;
  font-weight:400;
}

.editor-menu-inline-icon{
  flex:0 0 auto;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:18px;
  height:18px;
  color:#c7c7c7;
}

.editor-menu-inline-icon svg{
  width:16px;
  height:16px;
  stroke:currentColor;
  fill:none;
  stroke-width:2.1;
  stroke-linecap:round;
  stroke-linejoin:round;
}

.editor-menu-chevron{
  flex:0 0 auto;
  color:#b3b3b3;
  font-size:22px;
  line-height:1;
  margin-right:-2px;
}

.editor-menu-divider{
  height:1px;
  margin:4px 8px;
  background:#ece8e8;
}

.editor-back-btn{
  position:absolute;
  left:16px;
  top:0;
  width:40px;
  height:62px;
  border:none;
  background:transparent;
  color:#1f1f1f;
  display:flex;
  align-items:center;
  justify-content:center;
  cursor:pointer;
  border-radius:0;
  transition:background .18s ease, color .18s ease;
  z-index:1;
  overflow:visible;
  box-shadow:none;
}

.editor-back-btn::after{
  display:none;
}

.editor-back-btn:hover{
  background:transparent;
}

.editor-back-btn:active{
  background:transparent;
}

/* ── Drag handle (fixed, center of screen) ── */
.drag-handle{
  width:12px;height:80px;background:#e0ddd8;border-radius:100px;cursor:col-resize;
  position:fixed;top:50%;transform:translateY(-50%);z-index:30;
  display:flex;align-items:center;justify-content:center;transition:background .15s,width .15s;
}
.drag-handle::after{content:'';width:2px;height:24px;background:#ccc;border-radius:2px}
.drag-handle:hover{background:#ccc;width:14px}
.drag-handle:hover::after{background:#999}
.sidebar.collapsed~.canvas-area .drag-handle{display:none}

/* ── Cards ──────────────────────────────── */
.card{background:#fff;border-radius:0; padding:35px; border-bottom: 1px solid #ECE8E8; display: flex; flex-direction: column; gap: 0; }
.card{flex:0 0 auto}
.card:last-child { border-bottom: none; border-radius: 0 0 24px 24px; }
.brand { border-radius: 24px 24px 0 0; margin-bottom: 0 !important; }
.card-hdr{display:flex;align-items:center;justify-content:space-between;cursor:pointer;user-select:none;margin-bottom:25px;}
#aspectCard .card-hdr{margin-bottom:0;}
.card-hdr h3{font-size:24px; color:#1f1f1f; font-weight:500; margin:0; letter-spacing:0;}
.card-hdr .badge{font-size:9px;font-weight:600;color:#bbb;letter-spacing:.5px;text-transform:uppercase}
.card-caret{width:20px;height:20px;display:flex;align-items:center;justify-content:center;color:#ccc;transition:transform .2s,color .15s;flex-shrink:0}
.card-caret:hover{color:#888}
.card-caret.closed{transform:rotate(-90deg)}
.card-body{
  display:flex;flex-direction:column;gap:20px;margin-top:25px;
  max-height:1500px;opacity:1;overflow:visible;
  transition:max-height 0.2s cubic-bezier(0.4,0.0,0.2,1),opacity 0.15s cubic-bezier(0.4,0.0,0.2,1),margin-top 0.2s cubic-bezier(0.4,0.0,0.2,1);
}
.card-body.closed{max-height:0;opacity:0;margin-top:0;overflow:hidden}
#ratioCard .card-hdr{margin-bottom:0}

/* ── Controls ──────────────────────────── */
.ctrl{display:flex;flex-direction:column;gap:12px}
.ctrl label{font-size:12px;font-weight:500;letter-spacing:0;color:#9ca3af;display:flex;justify-content:space-between;align-items:center;gap:12px}
.ctrl-slider label{margin:0 -27px 0 -12px;padding:0 27px 0 12px}
.ctrl-slider label .val-shell{transform:translateX(15px)}
.ctrl.is-webcam-driven label{color:#7d4b44}
.ctrl{transition:opacity .16s ease}
.ctrl-label-main{display:flex;align-items:center;gap:8px;min-width:0;flex:1}
.ctrl-label-text{min-width:0}
.ctrl label .val-shell{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-width:68px;
  flex:0 0 auto;
  user-select:none;
  -webkit-user-select:none;
  touch-action:none;
  outline:none;
}
.ctrl label .val-pill{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-width:58px;
  min-height:32px;
  padding:4px 8px;
  border-radius:999px;
  background:rgba(243,244,246,0);
  transform:scale(.94);
  transform-origin:center center;
  transition:
    background .14s ease,
    transform .14s cubic-bezier(.2,1.15,.35,1);
}
.ctrl label .val-shell:hover .val-pill,
.ctrl label .val-shell:focus-visible .val-pill,
.ctrl label .val-shell.is-active .val-pill,
.ctrl label .val-shell.is-editing .val-pill,
.ctrl label .val-shell.is-value-dragging .val-pill{
  background:#f3f4f6;
  transform:scale(1);
}
.ctrl label .val{
  font-weight:500;
  letter-spacing:0;
  color:#222;
  font-variant-numeric:tabular-nums;
  font-size:12px;
  line-height:1;
  cursor:ew-resize;
  text-align:center;
  white-space:nowrap;
  transition:color .14s ease;
}
.val-editing{
  display:none;
  width:auto;
  min-width:0;
  max-width:100%;
  background:transparent;
  border:none;
  outline:none;
  appearance:textfield;
  -moz-appearance:textfield;
  font-weight:500;
  letter-spacing:0;
  color:#222;
  font-variant-numeric:tabular-nums;
  font-size:12px;
  line-height:1;
  padding:0;
  margin:0;
  text-align:center;
  font-family:inherit;
}
.val-editing::-webkit-outer-spin-button,
.val-editing::-webkit-inner-spin-button{-webkit-appearance:none;margin:0}
.val-shell.is-editing .val{display:none}
.val-shell.is-editing .val-editing{display:block}
.val-shell.is-out-of-range .val,
.val-shell.is-out-of-range .val-editing{color:#a65d57}
.val-shell.is-value-dragging,
.val-shell.is-value-dragging *{cursor:ew-resize !important}
.slider-input-wrap{position:relative;padding:6px 12px 0;margin:-6px -12px 0;overflow:visible}
.webcam-link-indicator{
  display:none;
  align-items:center;
  gap:6px;
  padding:3px 8px;
  border-radius:999px;
  background:rgba(255,35,4,0.08);
  color:#ff2304;
  font-size:10px;
  font-weight:700;
  letter-spacing:0.01em;
  white-space:nowrap;
  transform:translateX(var(--webcam-shift, 0px));
  transition:opacity .18s ease, transform .18s ease, background .18s ease, color .18s ease;
  opacity:0;
}
.webcam-link-indicator.is-active{display:inline-flex;opacity:1}
.webcam-link-indicator.is-live{background:rgba(255,35,4,0.14)}
.webcam-link-dot{
  width:6px;
  height:6px;
  border-radius:50%;
  background:currentColor;
  box-shadow:0 0 0 0 rgba(255,35,4,0.25);
  animation:webcamSignalPulse 1.2s ease-in-out infinite;
  flex:0 0 auto;
}
.webcam-link-text{max-width:148px;overflow:hidden;text-overflow:ellipsis}

@keyframes webcamSignalPulse{
  0%,100%{transform:scale(1);box-shadow:0 0 0 0 rgba(255,35,4,0.18)}
  50%{transform:scale(1.18);box-shadow:0 0 0 6px rgba(255,35,4,0)}
}

/* No transitions on sliders — prevents iframe glitch */
input[type=range]{appearance:none;-webkit-appearance:none;width:100%;height:34px;background:#f3f4f6;border-radius:100px;outline:none;cursor:pointer;display:block;overflow:visible}
input[type=range]::-webkit-slider-thumb{appearance:none;-webkit-appearance:none;width:32px;height:32px;background:#1f1f1f;border:none;border-radius:50%;cursor:grab;box-shadow:none;transition:transform .16s ease;}
input[type=range]::-webkit-slider-thumb:active{cursor:grabbing}
input[type=range].is-scrubbing{opacity:.96}
input[type=range].is-scrubbing::-webkit-slider-thumb{transform:none;box-shadow:none}
body.is-value-scrubbing,
body.is-value-scrubbing *{cursor:ew-resize !important}

/* ── Color circles (Coloris) ──────────── */
.colors-group-row{display:flex;align-items:flex-start;gap:16px;flex-wrap:wrap;padding:2px 0}
.color-circle-wrap{display:flex;flex-direction:column;align-items:center;gap:4px}
.color-circle{width:36px;height:36px;border-radius:50%;cursor:pointer;border:3px solid #eee;position:relative;overflow:hidden;flex-shrink:0}
.color-circle:hover{transform:scale(1.12);border-color:#ccc}
.color-circle-name{font-size:9px;font-weight:600;color:#bbb;white-space:nowrap;text-align:center;max-width:60px;overflow:hidden;text-overflow:ellipsis}
.color-circle-wrap:hover .color-circle-name{color:#666}
/* Hide the text input Coloris creates */
.clr-field{position:absolute !important;width:1px !important;height:1px !important;opacity:0 !important;overflow:hidden !important;pointer-events:none !important}

/* ── Toggle ────────────────────────────── */
.toggle-row{display:flex;align-items:center;gap:16px;padding:4px 0}
.toggle-switch{position:relative;width:52px;height:30px;cursor:pointer;flex-shrink:0}
.toggle-switch input{opacity:0;width:0;height:0}
.toggle-track{position:absolute;inset:0;background:#e2dfdb;border-radius:100px;transition:background .25s}
.toggle-track::after{content:'';position:absolute;top:3px;left:3px;width:24px;height:24px;background:#fff;border-radius:50%;transition:transform .25s cubic-bezier(.34,1.56,.64,1);box-shadow:0 2px 6px rgba(0,0,0,.12)}
.toggle-switch input:checked+.toggle-track{background:#333}
.toggle-switch input:checked+.toggle-track::after{transform:translateX(22px)}
.toggle-label{font-size:13px;color:#666;font-weight:700}

/* ── Inputs ────────────────────────────── */
.prompt-area{background:#fff;color:#1f1f1f;border:1px solid #e5e5e5;padding:14px 16px;border-radius:12px;font-size:14px;font-weight:500;outline:none;width:100%;min-height:80px;resize:vertical;font-family:inherit;line-height:1.5;box-shadow:none;}
.prompt-area:focus{border-color:#1f1f1f;box-shadow:none;}
.prompt-area::placeholder{color:#a1a1aa}
.small-area{min-height:50px;font-size:12px}
.text-input{background:#fff;color:#1f1f1f;border:1px solid #e5e5e5;padding:12px 16px;border-radius:12px;font-size:14px;font-weight:500;outline:none;width:100%;font-family:inherit;box-shadow:none;}
.text-input:focus{border-color:#1f1f1f;box-shadow:none;}
.dropdown-input{background:#fff;color:#222;border:1px solid #e5e5e5;padding:12px 16px;border-radius:12px;font-size:13px;font-weight:400;outline:none;width:100%;font-family:inherit;cursor:pointer}
.dropdown-input:focus{border-color:#1f1f1f}
.dropdown-input:hover{border-color:#d1d5db}
.ctrl .text-input,
.ctrl .dropdown-input{
  background:#f3f4f6;
  border:none;
  border-radius:999px;
  padding:14px 18px;
}
.ctrl .text-input:focus,
.ctrl .dropdown-input:focus{
  border-color:transparent;
}
.typography-host-card .card-body{gap:18px}
.typography-card-hdr{align-items:center}
.typography-font-control{gap:14px}
.typeface-card-title{
  display:flex;
  align-items:center;
  gap:12px;
  min-width:0;
}
.typeface-card-tools{
  display:flex;
  align-items:center;
  gap:8px;
}
.typeface-icon-btn{
  position:relative;
  width:24px;
  height:24px;
  border:none;
  border-radius:50%;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  padding:0;
  cursor:pointer;
  flex:0 0 auto;
  color:#6d7278;
  transition:background .18s ease, color .18s ease, border-color .18s ease, box-shadow .18s ease;
}
.typeface-info-btn{
  background:#f3f4f6;
}
.typeface-info-btn:hover{
  background:#ebecef;
  color:#36363a;
}
.typeface-settings-btn{
  background:#fff;
  border:1px solid rgba(31,31,31,0.08);
  box-shadow:0 10px 24px rgba(31,31,31,0.08);
}
.typeface-settings-btn:hover,
.typeface-settings-wrap.open .typeface-settings-btn{
  color:#1f1f1f;
  border-color:rgba(31,31,31,0.14);
  box-shadow:0 12px 28px rgba(31,31,31,0.1);
}
.typeface-icon-mark{
  font-size:12px;
  font-weight:700;
  line-height:1;
}
.typeface-info-tooltip{
  position:absolute;
  left:50%;
  top:calc(100% + 12px);
  width:240px;
  padding:12px 14px;
  border-radius:14px;
  background:#171717;
  color:#fff;
  font-size:12px;
  line-height:1.45;
  font-weight:500;
  text-align:left;
  box-shadow:0 14px 32px rgba(0,0,0,0.22);
  transform:translateX(-50%) translateY(-4px);
  opacity:0;
  visibility:hidden;
  transition:opacity .18s ease, transform .18s ease, visibility .18s ease;
  pointer-events:none;
  z-index:20;
}
.typeface-info-tooltip::before{
  content:'';
  position:absolute;
  left:50%;
  top:-6px;
  width:12px;
  height:12px;
  background:#171717;
  transform:translateX(-50%) rotate(45deg);
}
.typeface-info-btn:hover .typeface-info-tooltip,
.typeface-info-btn:focus-visible .typeface-info-tooltip{
  opacity:1;
  visibility:visible;
  transform:translateX(-50%) translateY(0);
}
.typeface-settings-wrap{
  position:relative;
  display:inline-flex;
  align-items:center;
}
.typeface-settings-menu{
  position:absolute;
  top:calc(100% + 10px);
  right:0;
  min-width:200px;
  padding:8px;
  border-radius:16px;
  background:#fff;
  border:1px solid rgba(31,31,31,0.07);
  box-shadow:0 20px 44px rgba(31,31,31,0.14);
  opacity:0;
  visibility:hidden;
  pointer-events:none;
  transform:translateY(-4px) scale(.98);
  transform-origin:top right;
  transition:opacity .16s ease, transform .16s ease, visibility .16s ease;
  z-index:24;
}
.typeface-settings-wrap.open .typeface-settings-menu{
  opacity:1;
  visibility:visible;
  pointer-events:auto;
  transform:translateY(0) scale(1);
}
.typeface-settings-item{
  width:100%;
  border:none;
  background:#fff;
  color:#1f1f1f;
  text-align:left;
  font-size:13px;
  font-weight:400;
  line-height:1.35;
  padding:12px 14px;
  border-radius:12px;
  cursor:pointer;
}
.typeface-settings-item:hover{
  background:#f5f5f3;
}
.typeface-settings-item:disabled{
  color:#b3b3b3;
  cursor:default;
}
.typeface-settings-item:disabled:hover{
  background:#fff;
}
.typeface-settings-divider{
  height:1px;
  margin:6px 4px;
  background:#ece8e8;
}
.typography-preview{padding:14px 16px;border-radius:24px;background:#f3f4f6;color:#1f1f1f;font-size:22px;line-height:1.2;letter-spacing:0;overflow:hidden;text-overflow:ellipsis}
.typography-note{margin:0;font-size:11px;line-height:1.45;color:#8b8b8b}
.typography-family-input{font-size:15px}
.typography-font-select{font-size:15px;font-weight:400}
.history-action-btn{width:37px;height:37px;border-radius:50%;background:#f3f4f6;color:#1f1f1f;display:flex;align-items:center;justify-content:center;border:none;cursor:pointer;transition:background .2s;}
.img-drop{width:100%;height:60px;border:1px dashed #d1d5db;border-radius:12px;display:flex;align-items:center;justify-content:center;gap:8px;cursor:pointer;background:#fff;font-size:12px;color:#9ca3af;font-weight:600}
.img-drop:hover,.img-drop.over{border-color:#1f1f1f;background:rgba(31,31,31,.03);color:#1f1f1f}
.img-drop.has-file{border-color:#2ecc71;background:rgba(46,204,113,.05);color:#2ecc71}
.img-drop input{display:none}
.img-drop svg{width:16px;height:16px;stroke:currentColor;fill:none}
.api-input{background:#fff;border:1px solid #e5e5e5;padding:10px 14px;border-radius:12px;font-size:10px;font-family:monospace;outline:none;width:100%}
.api-input:focus{border-color:#1f1f1f}
.api-hint{font-size:9px;color:#bbb;font-weight:500}
.api-hint.ok{color:#2ecc71}

/* ── Custom control tags ───────────────── */
.custom-ctrl-tag{display:inline-flex;align-items:center;gap:6px;padding:8px 14px;font-size:11px;font-weight:600;background:#333;color:#fff;border-radius:12px}
.custom-ctrl-tag .tag-x{cursor:pointer;opacity:.5;font-size:10px}
.custom-ctrl-tag .tag-x:hover{opacity:1}

/* ── Ratio pills ───────────────────────── */
.ratio-pills{display:flex;gap:10px;flex-wrap:wrap}
.ratio-pill{min-height:40px;padding:10px 14px;font-size:11px;font-weight:600;background:#f3f4f6;color:#7a7d86;border:none;border-radius:100px;cursor:pointer;display:flex;align-items:center;justify-content:center;gap:8px}
.ratio-pill svg{width:17px;height:17px;stroke:currentColor;stroke-width:1.65;stroke-linecap:round;stroke-linejoin:round}
.ratio-pill-icon{display:inline-flex;align-items:center;justify-content:center;flex:0 0 auto}
.ratio-pill-label{display:inline-flex;align-items:center;justify-content:center;line-height:1}
.ratio-pill:hover{background:#ebecef;color:#555}
.ratio-pill.active{background:#222;color:#fff}

/* ── Buttons ───────────────────────────── */
.pill-btn{padding:14px 26px;font-size:14px;font-weight:700;background:#1f1f1f;color:#ffffff;border:none;border-radius:100px;cursor:pointer;text-align:center;box-shadow:none;}
.pill-btn:hover{background:#333333}
.pill-btn:active{transform:scale(.97)}
.pill-btn.secondary{background:#f3f4f6;color:#6b7280}
.pill-btn.secondary:hover{background:#e5e7eb;color:#374151}
.pill-btn.full{width:100%}
.pill-btn.sm{padding:10px 18px;font-size:11px;border-radius:100px}
.btn-row{display:flex;gap:10px}
.btn-row .pill-btn{flex:1}

.ai-settings-row{
  pointer-events:auto;
  align-items:center;
}
.ai-settings-launch{
  width:48px;
  height:48px;
  border-radius:999px;
  border:none;
  background:#ffffff;
  color:#111111;
  display:flex;
  align-items:center;
  justify-content:center;
  position:relative;
  cursor:pointer;
  box-shadow:0 10px 28px rgba(0,0,0,.08);
  transition:transform .2s ease, box-shadow .2s ease, background-color .2s ease;
}
.ai-settings-indicator{
  position:absolute;
  top:2px;
  right:2px;
  width:9px;
  height:9px;
  border-radius:999px;
  background:#d93114;
  transition:background-color .2s ease, transform .2s ease;
}
.ai-settings-indicator.is-saved{
  background:#16a34a;
}
.ai-settings-launch img{
  display:block;
  width:22px;
  height:22px;
  object-fit:contain;
}
.ai-settings-launch:hover{
  transform:translateY(-1px);
  box-shadow:0 14px 36px rgba(0,0,0,.12);
  background:#f8f8f8;
}
.ai-settings-launch:active{transform:scale(.97)}
.ai-provider-pill-group{
  display:flex;
  gap:10px;
  flex-wrap:wrap;
  margin-bottom:0;
}
.ai-provider-row{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:16px;
  margin-bottom:16px;
}
.ai-provider-pill{
  min-height:42px;
  padding:12px 18px;
  border:none;
  border-radius:999px;
  background:#efefef;
  color:#5f5f5f;
  cursor:pointer;
  transition:transform .2s ease, background-color .2s ease, color .2s ease;
  font-size:14px;
  font-weight:400;
  font-family:'Neue Haas Grotesk Display Std', 'neue-haas-grotesk-display', sans-serif;
}
.ai-provider-pill.is-disabled{
  opacity:.42;
  cursor:not-allowed;
  pointer-events:none;
}
.ai-provider-pill[data-provider="google"]{
  display:none;
}
.ai-provider-pill:hover{
  background:#e4e4e4;
  color:#191919;
}
.ai-provider-pill.is-active{
  background:#111111;
  color:#ffffff;
}
.ai-provider-pill:active{transform:scale(.98)}
.ai-modal-status.is-error{color:#d93114}
.ai-modal-status.is-success{color:#1d7a32}
.ai-guide-links{
  display:flex;
  justify-content:flex-end;
  align-items:center;
  min-height:18px;
}
.ai-why-btn{
  position:relative;
  border:none;
  background:none;
  padding:0;
  margin:0;
  color:#111111;
  font-size:14px;
  line-height:1.5;
  font-weight:400;
  font-family:'Neue Haas Grotesk Display Std', 'neue-haas-grotesk-display', sans-serif;
  cursor:help;
}
.ai-why-tooltip{
  position:absolute;
  right:0;
  top:calc(100% + 12px);
  width:280px;
  padding:12px 14px;
  border-radius:14px;
  background:#171717;
  color:#ffffff;
  font-size:12px;
  line-height:1.45;
  font-weight:500;
  text-align:left;
  box-shadow:0 14px 32px rgba(0,0,0,0.22);
  transform:translateY(-4px);
  opacity:0;
  visibility:hidden;
  transition:opacity .18s ease, transform .18s ease, visibility .18s ease;
  pointer-events:none;
  z-index:20;
}
.ai-why-tooltip::before{
  content:'';
  position:absolute;
  right:18px;
  top:-6px;
  width:12px;
  height:12px;
  background:#171717;
  transform:rotate(45deg);
}
.ai-why-btn:hover .ai-why-tooltip,
.ai-why-btn:focus-visible .ai-why-tooltip{
  opacity:1;
  visibility:visible;
  transform:translateY(0);
}
.ai-meta-separator{
  width:4px;
  height:4px;
  border-radius:999px;
  background:#111111;
  flex:0 0 auto;
}
.ai-guide-link{
  display:none;
  color:#6b6b6b;
  text-decoration:none;
  font-size:14px;
  line-height:1.5;
  font-weight:400;
  font-family:'Neue Haas Grotesk Display Std', 'neue-haas-grotesk-display', sans-serif;
  transition:color .2s ease;
}
.ai-guide-link:hover{
  color:#111111;
}
.ai-guide-link.is-active{
  display:inline-block;
}
.ai-field-meta-row{
  display:flex;
  align-items:center;
  justify-content:flex-end;
  flex:0 0 auto;
  gap:14px;
}
.ai-input-shell{
  position:relative;
}
.ai-input-actions{
  position:absolute;
  top:50%;
  right:14px;
  transform:translateY(-50%);
  display:flex;
  align-items:center;
  gap:8px;
}
.ai-input-action{
  width:24px;
  height:24px;
  border:none;
  background:none;
  padding:0;
  display:flex;
  align-items:center;
  justify-content:center;
  color:#6a6a6a;
  cursor:pointer;
  transition:color .2s ease, opacity .2s ease, transform .2s ease;
}
.ai-input-action:hover{
  color:#111111;
}
.ai-input-action:active{
  transform:scale(.96);
}
.ai-input-action svg{
  width:18px;
  height:18px;
}
.ai-input-action.is-hidden{
  opacity:0;
  pointer-events:none;
}
.friends-input-shell{
  position:relative;
}
.friends-input-action{
  position:absolute;
  top:50%;
  right:16px;
  transform:translateY(-50%);
  width:24px;
  height:24px;
  border:none;
  background:none;
  padding:0;
  display:flex;
  align-items:center;
  justify-content:center;
  color:#6a6a6a;
  cursor:pointer;
  transition:color .2s ease, opacity .2s ease, transform .2s ease;
}
.friends-input-action:hover{
  color:#111111;
}
.friends-input-action:active{
  transform:translateY(-50%) scale(.96);
}
.friends-input-action svg{
  width:18px;
  height:18px;
}
.friends-modal-status.is-error{color:#d93114}
.friends-modal-status.is-success{color:#1d7a32}

/* ── Labeled icon action buttons ───────── */
.icon-actions{display:flex;gap:10px;justify-content:center;padding:4px 0}
.icon-act{display:flex;align-items:center;gap:6px;padding:8px 16px;border-radius:100px;background:#f0f0f0;border:none;cursor:pointer;color:#999;font-size:11px;font-weight:700}
.icon-act:hover{background:#222;color:#fff}
.icon-act svg{width:16px;height:16px;stroke:currentColor;fill:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;flex-shrink:0}

/* ── AI Tabs ───────────────────────────── */
.ai-tabs{display:flex;gap:8px;margin-bottom:25px}
.ai-tab{flex:1;padding:12px;background:#fff;border:2px solid #eeece8;border-radius:14px;font-size:13px;font-weight:700;color:#999;cursor:pointer;transition:all .2s;display:flex;align-items:center;justify-content:center;gap:8px}
.ai-tab:hover:not(.loading){border-color:#ddd;color:#666}
.ai-tab.active{background:#1f1f1f;border-color:#1f1f1f;color:#fff}
.ai-tab.loading{opacity:0.6;pointer-events:none;cursor:wait;background:#f5f5f5}
.tab-label{flex-shrink:0}
.tab-loader{width:14px;height:14px;border:2px solid rgba(255,255,255,.3);border-top-color:#fff;border-radius:50%;animation:spin .6s linear infinite}
@keyframes spin{to{transform:rotate(360deg)}}

/* ── Hint ──────────────────────────────── */
.hint{font-size:11px;color:#bbb;line-height:1.6;padding:12px 16px;background:#fff;border-radius:16px;text-align:center}
.hint kbd{background:#f7f6f3;border:1px solid #e8e6e2;padding:3px 10px;border-radius:8px;font-family:'Helvetica Neue',monospace;font-size:11px;font-weight:700;color:#555}

/* ── Canvas area ───────────────────────── */
.canvas-area{flex:1;display:flex;align-items:center;justify-content:center;background:#f2f0ed url('Assets_design/Background_texture.png') no-repeat center center;background-size:cover;position:relative;overflow:hidden;transition:background-color .32s ease}
.canvas-area::before{content:'';position:absolute;inset:0;background:#000;opacity:0;pointer-events:none;transition:opacity .32s ease;z-index:0}
#preview{position:absolute;inset:0;width:100%;height:100%;border:none;display:none;z-index:1}
#preview.animating{transition:left .35s cubic-bezier(.4,0,.2,1),top .35s cubic-bezier(.4,0,.2,1),width .35s cubic-bezier(.4,0,.2,1),height .35s cubic-bezier(.4,0,.2,1),border-radius .35s ease}
#preview.no-interact{pointer-events:none}

/* ── Upload hero ───────────────────────── */
.upload-hero{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:16px;text-align:center;opacity:.6}
.upload-hero h2{font-size:16px;font-weight:700;color:#222}
.upload-hero p{font-size:12px;color:#aaa;max-width:280px;line-height:1.5}

/* ── Loading ───────────────────────────── */
.loader{
  position:absolute;inset:0;
  background:#f9fafb url('Assets_design/Background_texture.png') no-repeat center center;
  background-size:cover;
  display:none;flex-direction:column;align-items:center;justify-content:center;z-index:90;
  opacity:0;
  animation: fadeIn 0.5s ease-out forwards, breathingShadow 3s ease-in-out infinite 0.5s;
}
.loader.show{display:flex}
@keyframes fadeIn {
  0% { opacity: 0; }
  100% { opacity: 1; }
}
@keyframes breathingShadow {
  0%, 100% { box-shadow: 0 4px 70px 0 #FF2304 inset; }
  50% { box-shadow: 0 4px 250px 0 #FF2304 inset; }
}
.skel-mesh { background: linear-gradient(90deg, #f0f0f0 25%, #f8f8f8 50%, #f0f0f0 75%); background-size: 200% 100%; animation: shimmer 1.5s infinite linear; }
@keyframes shimmer { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }
@keyframes spin{to{transform:rotate(360deg)}}
@keyframes slideUp {
  0% { transform: translateY(20px); opacity: 0; }
  100% { transform: translateY(0); opacity: 1; }
}
@keyframes slideDown {
  0% { transform: translateY(-20px); opacity: 0; }
  100% { transform: translateY(0); opacity: 1; }
}
@keyframes shake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-3px); }
  75% { transform: translateX(3px); }
}

/* ── Summary ───────────────────────────── */
.summary{background:#fafaf8;border-radius:14px;padding:16px 18px;font-size:11px;color:#666;line-height:1.6}
.summary strong{color:#333;font-size:12px}
.swatches{display:flex;gap:6px;margin-top:8px}
.sw{width:20px;height:20px;border-radius:6px;border:1.5px solid rgba(0,0,0,.06)}

/* ── Toast ─────────────────────────────── */
.toast{position:fixed;bottom:24px;right:24px;left:auto;background:#222;color:#fff;padding:14px 28px;border-radius:100px;font-size:13px;font-weight:600;opacity:0;transition:opacity .3s, transform .3s;transform:translateY(20px);pointer-events:none;z-index:400;box-shadow:0 10px 30px rgba(0,0,0,.2)}
.toast.show{opacity:1;transform:translateY(0)}

/* ── FABs ──────────────────────────────── */
.fab-row{position:absolute;top:16px;right:18px;display:none;gap:10px;z-index:10}
.fab-row.show{display:flex}
.fab{width:44px;height:44px;border-radius:50%;background:#fff;border:none;cursor:pointer;display:flex;align-items:center;justify-content:center;box-shadow:0 2px 16px rgba(0,0,0,.10);color:#333;position:relative}
.fab:hover{transform:scale(1.08);background:#f3f4f6;}
.fab:active{transform:scale(.95)}

.rec-dot-fab{width:16px;height:16px;border-radius:50%;background:currentColor;transition:border-radius .2s}
.fab.recording .rec-dot-fab{border-radius:3px}
@keyframes pulse-rec{0%,100%{box-shadow:0 2px 16px rgba(255,107,0,.3)}50%{box-shadow:0 4px 24px rgba(255,107,0,.6)}}

/* FAB tooltip on hover */
.fab-tip{position:absolute;bottom:-32px;left:50%;transform:translateX(-50%);background:#222;color:#fff;padding:4px 10px;border-radius:8px;font-size:10px;font-weight:600;white-space:nowrap;opacity:0;pointer-events:none;transition:opacity .15s}
.fab:hover .fab-tip{opacity:1}

#followUpSection{
  position:relative;
  flex:0 0 auto;
  border-radius:0 0 24px 24px;
  overflow:hidden;
  transition:box-shadow .25s ease;
}

#sidebarToggle{
  opacity:1;
  transform:translateY(-50%) translateX(0);
  transition:opacity .18s ease, box-shadow .16s ease, background .16s ease, transform .22s cubic-bezier(.23,1,.32,1);
}

#sidebarToggle.is-stealth{
  opacity:0;
  transform:translateY(-50%) translateX(-14px);
  pointer-events:none;
}

#followUpSection.is-processing{
  box-shadow:inset 0 0 34px rgba(255,35,4,0.18);
  animation:followUpPulse 2.1s ease-in-out infinite;
}

@keyframes followUpPulse{
  0%,100%{box-shadow:inset 0 0 26px rgba(255,35,4,0.14)}
  50%{box-shadow:inset 0 0 54px rgba(255,35,4,0.24)}
}

#followUpBtn{
  display:flex;
  align-items:center;
  justify-content:center;
  gap:8px;
}

#followUpBtn:disabled{
  cursor:wait;
  opacity:.95;
}

.btn-inline-loader{
  width:14px;
  height:14px;
  border-radius:50%;
  border:2px solid rgba(255,255,255,0.32);
  border-top-color:#fff;
  animation:spin .8s linear infinite;
  flex:0 0 auto;
}

/* ── Sidebar toggle FAB ────────────────── */
.sidebar-toggle{position:absolute;top:16px;left:16px;z-index:25;width:44px;height:44px;border-radius:50%;background:#fff;border:none;cursor:pointer;display:flex;align-items:center;justify-content:center;box-shadow:0 2px 16px rgba(0,0,0,.10);color:#333}
.sidebar-toggle:hover{transform:scale(1.08);box-shadow:0 4px 24px rgba(0,0,0,.15)}

/* ── Gallery (edge to edge) ───────────── */
.gallery-wrap{position:absolute;bottom:12px;left:380px;right:40px;display:flex;align-items:center;z-index:24;justify-content:flex-start;overflow:visible}
.gallery-arrow{width:36px;height:36px;border-radius:50%;background:#1f1f1f;border:none;color:#fff;font-size:18px;cursor:pointer;display:none;align-items:center;justify-content:center;box-shadow:0 4px 12px rgba(0,0,0,.1);z-index:2;flex-shrink:0}
.gallery-arrow:hover{background:#fff;color:#333}
.gallery-arrow.show{display:flex}
.gallery-arrow.left{left:10px}
.gallery-arrow.right{right:10px}
.snap-gallery{display:flex;gap:10px;align-items:flex-end;overflow-x:auto;overflow-y:visible;padding:34px 16px 10px;scroll-behavior:smooth;scroll-snap-type:x mandatory;scroll-padding-left:16px;flex:1;min-width:0;cursor:grab;user-select:none;-webkit-user-select:none;touch-action:pan-x;overscroll-behavior-x:contain;-webkit-overflow-scrolling:touch}
.snap-gallery::-webkit-scrollbar{height:0}
.snap-gallery.is-dragging{cursor:grabbing;scroll-behavior:auto}
.snap-wrap{position:relative;flex-shrink:0;opacity:1;cursor:pointer;scroll-snap-align:start;scroll-snap-stop:always}
.snap-wrap.is-fresh{animation:bounceIn .5s cubic-bezier(.34,1.56,.64,1) forwards;opacity:0}
.snap-thumb-media,
.snap-thumb-fallback{height:68px;border-radius:10px;box-shadow:0 2px 12px rgba(0,0,0,.12);transition:transform .18s ease,border-color .18s ease}
.snap-thumb-media{width:auto;max-width:180px;min-width:0;display:block;background:transparent;border:none;object-fit:cover}
.snap-thumb-fallback{display:flex;align-items:center;justify-content:center;min-width:92px;padding:0 16px;color:#8d8f96;font-size:12px;font-weight:500;background:#f3f4f6;border:none}
.snap-wrap.is-video .snap-thumb-media,
.snap-wrap.is-video .snap-thumb-fallback{background:#f3f4f6}
.snap-del,.snap-download{position:absolute;top:-5px;width:28px;height:28px;border-radius:50%;background:rgba(0,0,0,.82);color:#fff;border:2px solid #fff;cursor:pointer;display:flex;align-items:center;justify-content:center;opacity:0;pointer-events:none;z-index:2}
.snap-del{right:-5px}
.snap-download{left:-5px;background:#fff;color:#111;border-color:#fff}
.snap-download.is-disabled{opacity:0 !important;pointer-events:none !important}
.snap-del svg{width:12px;height:12px;stroke:#fff;fill:none;stroke-width:2.5}
.snap-download svg{width:12px;height:12px;stroke:currentColor;fill:none;stroke-width:2.25}
.snap-del:hover{background:#ff3333}
.snap-download:hover{background:#f2f2f2}
.snap-status-badge{position:absolute;right:8px;bottom:8px;width:28px;height:28px;border-radius:50%;background:rgba(17,17,18,.82);display:flex;align-items:center;justify-content:center;color:#fff;box-shadow:0 8px 20px rgba(0,0,0,.16);z-index:2}
.snap-status-badge svg{width:13px;height:13px;display:block}
.snap-status-spinner{width:12px;height:12px;border-radius:50%;border:1.6px solid rgba(31,31,31,0.18);border-top-color:#1f1f1f;animation:spin .75s linear infinite}
@keyframes bounceIn{0%{opacity:0;transform:scale(.3) translateY(30px)}50%{opacity:1;transform:scale(1.12) translateY(-8px)}70%{transform:scale(.95) translateY(2px)}100%{opacity:1;transform:scale(1) translateY(0)}}
@keyframes spin{to{transform:rotate(360deg)}}

@media (hover:hover) and (pointer:fine){
  .snap-wrap:hover .snap-thumb-media,
  .snap-wrap:hover .snap-thumb-fallback{transform:scale(1.04);border-color:#1f1f1f}
  .snap-wrap:hover .snap-del,
  .snap-wrap:hover .snap-download{opacity:1;pointer-events:auto}
}

/* ── Lightbox ──────────────────────────── */
.lightbox{position:fixed;inset:0;background:rgba(0,0,0,.9);display:none;align-items:center;justify-content:center;z-index:300;flex-direction:column}
.lightbox.show{display:flex}
.lightbox img,
.lightbox video{max-width:85vw;max-height:75vh;border-radius:8px;box-shadow:0 8px 40px rgba(0,0,0,.4)}
.lightbox img{pointer-events:none}
.lb-nav{position:absolute;top:50%;transform:translateY(-50%);width:48px;height:48px;border-radius:50%;background:rgba(255,255,255,.1);border:none;cursor:pointer;display:flex;align-items:center;justify-content:center;color:#fff;font-size:20px;font-weight:700}
.lb-nav:hover{background:rgba(255,255,255,.25)}
.lb-prev{left:20px}
.lb-next{right:20px}
.lb-close{position:absolute;top:20px;right:20px;width:40px;height:40px;border-radius:50%;background:rgba(255,255,255,.1);border:none;cursor:pointer;display:flex;align-items:center;justify-content:center;color:#fff;font-size:18px;font-weight:700}
.lb-close:hover{background:rgba(255,255,255,.25)}
.lb-counter{position:absolute;bottom:76px;left:50%;transform:translateX(-50%);color:rgba(255,255,255,.5);font-size:12px;font-weight:600}
.lb-meta{position:absolute;top:24px;left:50%;transform:translateX(-50%);min-height:34px;padding:0 14px;border-radius:999px;background:rgba(255,255,255,.12);backdrop-filter:blur(12px);-webkit-backdrop-filter:blur(12px);color:rgba(255,255,255,.82);font-size:12px;font-weight:600;white-space:nowrap;text-align:center;display:flex;align-items:center;justify-content:center;box-shadow:0 14px 32px rgba(0,0,0,.22);z-index:4}
.lb-bottom-bar{position:absolute;bottom:24px;left:50%;transform:translateX(-50%);display:flex;gap:12px;z-index:5}
.lb-icon-btn{width:44px;height:44px;border-radius:50%;background:rgba(255,255,255,.15);border:none;cursor:pointer;display:flex;align-items:center;justify-content:center;color:#fff}
.lb-icon-btn:hover{background:rgba(255,255,255,.3);transform:scale(1.08)}
.lb-icon-btn.is-disabled{opacity:.35;pointer-events:none}
.lb-chip-btn{height:44px;padding:0 16px;border-radius:999px;background:rgba(255,255,255,.15);border:none;color:#fff;font-size:12px;font-weight:700;letter-spacing:.02em;display:inline-flex;align-items:center;justify-content:center;gap:8px;cursor:pointer;transition:background .16s ease, transform .16s ease, opacity .16s ease}
.lb-chip-btn:hover{background:rgba(255,255,255,.28);transform:scale(1.04)}
.lb-chip-btn.is-disabled{opacity:.5;cursor:default}
.lb-chip-btn[data-tip]{position:relative}
.lb-chip-btn[data-tip]::after{
  content:attr(data-tip);
  position:absolute;
  bottom:calc(100% + 10px);
  left:50%;
  transform:translateX(-50%) translateY(4px);
  min-width:170px;
  max-width:240px;
  padding:10px 12px;
  border-radius:14px;
  background:rgba(17,17,18,.96);
  color:#fff;
  font-size:11px;
  font-weight:500;
  line-height:1.35;
  text-align:center;
  white-space:normal;
  box-shadow:0 16px 34px rgba(0,0,0,.24);
  opacity:0;
  visibility:hidden;
  pointer-events:none;
  transition:opacity .16s ease, transform .16s cubic-bezier(.23,1,.32,1), visibility .16s ease;
  z-index:6;
}
.lb-chip-btn[data-tip]:hover::after,
.lb-chip-btn[data-tip]:focus-visible::after{
  opacity:1;
  visibility:visible;
  transform:translateX(-50%) translateY(0);
}
.lb-chip-spinner{width:12px;height:12px;border-radius:50%;border:1.6px solid rgba(255,255,255,.28);border-top-color:#fff;animation:spin .75s linear infinite;flex:0 0 auto}
.lb-chip-btn svg{width:16px;height:16px;stroke:currentColor;fill:none;stroke-width:2.2;stroke-linecap:round;stroke-linejoin:round;flex:0 0 auto}

/* ── Rec badge ─────────────────────────── */
.rec-badge{position:absolute;top:24px;left:calc(360px + (100vw - 360px) / 2);transform:translateX(-50%);display:none;align-items:center;gap:10px;background:#ef4444;color:#fff;padding:0 22px;height:56px;border-radius:100px;font-size:14px;font-weight:500;z-index:50;box-shadow:0 8px 24px rgba(0,0,0,0.08)}
.rec-badge.show{display:flex}
.rec-badge .blink{width:10px;height:10px;border-radius:50%;background:#fff;animation:blink 1s infinite}
@keyframes blink{0%,100%{opacity:1}50%{opacity:.3}}

#controlsWrap{display:flex;flex-direction:column;margin-top:0 !important;flex:0 0 auto}
#controlsWrap>fieldset{margin-bottom:20px; padding-bottom:20px; border-bottom:1px solid #ECE8E8;}
#controlsWrap>fieldset:last-child{margin-bottom:0; padding-bottom:0; border-bottom:none;}

/* ── Camera Controls ───────────────────── */
.camera-controls{
  position:fixed;top:50%;right:20px;transform:translateY(-50%);
  display:flex;flex-direction:column;gap:10px;z-index:15;
}
.camera-btn{
  --cam-offset-x:0px;
  --cam-offset-y:0px;
  --cam-scale:1;
  width:44px;height:44px;border-radius:50%;background:rgba(255,255,255,.92);
  border:none;cursor:pointer;display:flex;align-items:center;justify-content:center;
  box-shadow:0 2px 12px rgba(0,0,0,.12);transition:background .2s, box-shadow .2s, color .2s, transform .16s ease;color:#444;
  transform:translate(var(--cam-offset-x), var(--cam-offset-y)) scale(var(--cam-scale));
  position:relative;
}
#panBtn{cursor:grab}
#panBtn.active{cursor:grabbing}
#zoomBtn{cursor:ns-resize}
#zoomBtn.active{cursor:ns-resize}
#resetCameraBtn{cursor:pointer}
.camera-btn:hover{background:#fff;--cam-scale:1.08;box-shadow:0 4px 16px rgba(0,0,0,.18);color:#1f1f1f}
.camera-btn:active{--cam-scale:.95}
.camera-btn.active{background:#1f1f1f;color:#fff;box-shadow:0 4px 20px rgba(0,0,0,.15)}
.camera-btn svg{flex-shrink:0}

.camera-tip{
  position:absolute;
  right:calc(100% + 10px);
  top:50%;
  transform:translateY(-50%) translateX(6px);
  background:#222;
  color:#fff;
  padding:4px 10px;
  border-radius:8px;
  font-size:10px;
  font-weight:600;
  white-space:nowrap;
  opacity:0;
  pointer-events:none;
  transition:opacity .15s ease, transform .15s ease;
}

.camera-btn:hover .camera-tip,
.camera-btn.active .camera-tip{
  opacity:1;
  transform:translateY(-50%) translateX(0);
}

body.is-ui-fullscreen .sidebar-reveal-btn,
body.is-ui-fullscreen .gallery-wrap,
body.is-ui-fullscreen .camera-controls,
body.is-ui-fullscreen .rec-badge,
body.is-ui-fullscreen #fpsCounter,
body.is-ui-fullscreen #webcamCanvasFeedCard{
  opacity:0;
  pointer-events:none;
}

body.is-ui-fullscreen .fabs{
  opacity:1;
  pointer-events:none;
  transform:none;
}

body.is-ui-fullscreen #historyDesktopSlot,
body.is-ui-fullscreen .mobile-history-slot,
body.is-ui-fullscreen #historyFabWrap{
  opacity:0;
  pointer-events:none;
  visibility:hidden;
}

body.is-ui-fullscreen .fab-action-group{
  position:fixed;
  top:24px;
  right:96px;
  opacity:0;
  pointer-events:none;
  transform:translateY(-10px);
  transition:opacity .18s ease, transform .18s ease;
  z-index:169;
}

body.is-ui-fullscreen.is-fullscreen-exit-visible .fab-action-group{
  opacity:1;
  pointer-events:auto;
  transform:translateY(0);
}

body.is-ui-fullscreen #fullscreenBtn{
  display:none;
}

body.is-ui-fullscreen:not(.is-compact-ui) #sidebar{
  opacity:0;
  pointer-events:none;
  transform:translateX(-28px);
}

body.is-ui-fullscreen #sidebarBackdrop{
  opacity:0 !important;
  pointer-events:none !important;
}

body.is-ui-fullscreen .canvas-area::before{
  opacity:1;
}

/* ── Coloris overrides ─────────────────── */
.clr-picker{
  z-index:500;
}

/* ── History Modal / Version Menu ──────── */
@keyframes pulseBtn{0%{transform:scale(1)}50%{transform:scale(1.04)}100%{transform:scale(1)}}
@keyframes versionShimmer{0%{background-position:200% 50%}100%{background-position:-200% 50%}}

.version-menu-wrap{
  position:relative;
  top:0;
  left:0;
  display:flex;
  flex-direction:column;
  align-items:stretch;
  width:200px;
  z-index:55;
  opacity:0;
  transform:translateY(-6px);
  pointer-events:none;
  transition:opacity .18s ease, transform .18s cubic-bezier(.23,1,.32,1), width .18s cubic-bezier(.23,1,.32,1);
}

.version-menu-wrap.is-visible{
  opacity:1;
  transform:translateY(0);
  pointer-events:auto;
}

.version-menu-wrap.is-open{
  width:350px;
}

#historyBtn.pulse{animation:pulseBtn .32s ease;}

.version-pill{
  width:100%;
  height:56px;
  border:none;
  border-radius:999px;
  background:#fff;
  border:1px solid #f3f4f6;
  box-shadow:0 6px 16px rgba(0,0,0,0.06);
  color:#1f1f1f;
  display:flex;
  align-items:center;
  gap:14px;
  padding:8px 18px 8px 8px;
  cursor:pointer;
  transition:transform .2s, background .2s, box-shadow .2s;
}

.version-pill:hover{
  transform:scale(1.015);
  background:#f8f8f8;
}

.version-pill:active{
  transform:scale(.985);
}

.version-pill-preview{
  width:40px;
  height:40px;
  border-radius:50%;
  border:1px solid #ecebea;
  background:#f3f1ef;
  overflow:hidden;
  flex:0 0 auto;
  display:flex;
  align-items:center;
  justify-content:center;
}

.version-pill-preview.history-skeleton{
  background:linear-gradient(120deg,#f0efee 10%,#faf8f7 45%,#f0efee 80%);
  background-size:200% 100%;
  animation:versionShimmer 1.4s linear infinite;
}

.version-pill-preview img{
  display:block;
  width:100%;
  height:100%;
  object-fit:cover;
}

.version-pill-meta,
.history-time,
.history-current-tag,
.history-creating-pill{
  font-family:'neue-haas-grotesk-display', sans-serif;
  font-size:14px;
  font-weight:500;
  letter-spacing:-0.02em;
}

.version-pill-title,
.history-title{
  font-family:'neue-haas-grotesk-text', 'neue-haas-grotesk-display', sans-serif;
  font-size:14px;
  font-weight:500;
  letter-spacing:0;
}

.version-pill-title{
  line-height:1;
}

.version-pill-meta{
  margin-left:auto;
  display:flex;
  align-items:center;
  gap:10px;
  line-height:1;
}

.version-pill-loader{
  display:inline-block;
  flex:0 0 auto;
  width:12px;
  height:12px;
  border-radius:50%;
  border:2px solid rgba(31,31,31,0.18);
  border-top-color:#1f1f1f;
  opacity:0;
  transform:scale(.7);
  animation:spin .85s linear infinite;
  transition:opacity .18s ease, transform .18s ease;
}

.version-pill-loader.show{
  opacity:1;
  transform:scale(1);
}

.version-pill-meta svg{
  transition:transform .2s cubic-bezier(.23,1,.32,1);
}

.version-menu-wrap.is-open .version-pill-meta svg{
  transform:rotate(180deg);
}

.history-modal{
  position:absolute;
  top:calc(100% + 12px);
  left:-18px;
  width:calc(100% + 36px);
  max-height:min(calc(100vh - 120px), 620px);
  padding:0 0 26px;
  overflow:visible;
  opacity:0;
  transform:translateY(-10px) scale(.985);
  pointer-events:none;
  transition:opacity .16s ease, transform .18s cubic-bezier(.23,1,.32,1);
  z-index:210;
}

.version-menu-wrap.is-open .history-modal{
  opacity:1;
  transform:translateY(0) scale(1);
  pointer-events:auto;
}

.history-list{
  display:flex;
  flex-direction:column;
  gap:12px;
  max-height:inherit;
  overflow-y:auto;
  overflow-x:visible;
  padding:0 18px 26px;
}

.history-list::-webkit-scrollbar{display:none}
.history-list{-ms-overflow-style:none;scrollbar-width:none}

.history-item{
  position:relative;
  width:100%;
  min-height:100px;
  display:grid;
  grid-template-columns:70px minmax(0,1fr) auto;
  align-items:center;
  gap:16px;
  padding:15px 26px 15px 15px;
  border:none;
  border-radius:999px;
  background:#fff;
  box-shadow:0 8px 20px rgba(0,0,0,0.06);
  cursor:pointer;
  opacity:0;
  transform:translateY(-10px) scale(.985);
  transition:opacity .16s ease, transform .18s cubic-bezier(.23,1,.32,1), box-shadow .18s ease;
  transition-delay:calc(var(--history-order, 0) * 30ms);
  overflow:visible;
}

.version-menu-wrap.is-open .history-item{
  opacity:1;
  transform:translateY(0) scale(1);
}

.history-item:hover{
  box-shadow:0 10px 22px rgba(0,0,0,0.07);
}

.history-item.is-removing{
  opacity:0 !important;
  transform:translateX(-24px) scale(.96) !important;
  transition-delay:0ms !important;
  pointer-events:none;
}

.history-item.active{
  box-shadow:0 10px 24px rgba(0,0,0,0.08);
}

.history-thumb-shell{
  width:70px;
  height:70px;
  border-radius:50%;
  border:1px solid #ebe9e7;
  background:#f3f1ef;
  overflow:hidden;
  flex:0 0 auto;
  display:flex;
  align-items:center;
  justify-content:center;
}

.history-thumb-shell.history-skeleton{
  background:linear-gradient(120deg,#f0efee 10%,#faf8f7 45%,#f0efee 80%);
  background-size:200% 100%;
  animation:versionShimmer 1.4s linear infinite;
}

.history-thumb-img{
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
}

.history-copy{
  min-width:0;
  display:flex;
  flex-direction:column;
  justify-content:center;
  gap:6px;
}

.history-title-row{
  display:flex;
  align-items:center;
  gap:10px;
  min-width:0;
}

.history-title{
  line-height:1;
  color:#000;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}

.history-time{
  font-family:'neue-haas-grotesk-display', sans-serif;
  line-height:1;
  color:#b3b3b3;
  max-width:100%;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}

.history-side{
  display:flex;
  align-items:center;
  justify-content:flex-end;
  gap:0;
  min-width:124px;
  padding-right:0;
}

.history-current-tag{
  min-width:94px;
  height:30px;
  padding:0 14px;
  border-radius:999px;
  background:#ececec;
  display:flex;
  align-items:center;
  justify-content:center;
  line-height:1;
  color:#000;
  margin-left:auto;
  transform:translateX(0);
  transition:transform .18s cubic-bezier(.23,1,.32,1), background .18s ease, color .18s ease;
}

.history-item:hover .history-current-tag{
  transform:translateX(-34px);
}

.history-delete-btn{
  position:absolute;
  right:22px;
  top:50%;
  width:34px;
  height:34px;
  border:none;
  border-radius:50%;
  background:#ececec;
  color:#000;
  display:flex;
  align-items:center;
  justify-content:center;
  cursor:pointer;
  opacity:0;
  transform:translateY(-50%) translateX(6px) scale(.78);
  transition:opacity .16s ease, transform .18s cubic-bezier(.23,1,.32,1), background .2s, color .2s;
}

.history-item:hover .history-delete-btn{
  opacity:1;
  transform:translateY(-50%) translateX(0) scale(1);
}

.history-delete-btn:hover{
  background:#ff2304;
  color:#fff;
  transform:translateY(-50%) translateX(0) scale(1.06);
}

.history-item.is-pending{
  display:flex;
  align-items:center;
  justify-content:center;
  cursor:default;
  overflow:hidden;
}

.history-item.is-pending::before{
  content:'';
  position:absolute;
  inset:0;
  background:linear-gradient(110deg, rgba(255,255,255,0) 15%, rgba(238,238,238,0.9) 50%, rgba(255,255,255,0) 85%);
  background-size:200% 100%;
  animation:versionShimmer 1.8s linear infinite;
  opacity:.65;
}

.history-creating-pill{
  position:relative;
  z-index:1;
  min-width:108px;
  height:30px;
  padding:0 14px;
  border-radius:999px;
  background:#ececec;
  color:#000;
  line-height:1;
  display:flex;
  align-items:center;
  justify-content:center;
}

/* ── Action Fabs ───────────────────────── */
.fabs { position:absolute; top:24px; right:24px; display:flex; align-items:flex-start; gap:16px; z-index:50; }
.fab-action-group { display:flex; align-items:flex-start; gap:16px; }
#historyDesktopSlot{position:fixed;top:24px;left:392px;z-index:55}
#historyFabWrap,
.fab-action-group,
#fullscreenBtn{pointer-events:auto}
.fab { width:56px; height:56px; border-radius:50%; background:#fff; border:1px solid #f3f4f6; box-shadow:0 8px 24px rgba(0,0,0,0.08); display:flex; align-items:center; justify-content:center; cursor:pointer; color:#1f1f1f; transition:transform 0.2s, background 0.2s, box-shadow 0.2s, color 0.2s; position:relative; }
.fab.recording { background:#ef4444 !important; border-color:#ef4444 !important; color:#fff !important; }
.fab.recording .rec-dot-fab { background:#fff !important; }
.fab:hover { transform:scale(1.05); background:#f3f4f6; }
.rec-dot-fab { width:12px; height:12px; background:#ef4444; border-radius:50%; }
/* Old Rec Badge Removed */
.blink { width:8px; height:8px; background:#ef4444; border-radius:50%; animation:recBlink 1s infinite alternate; }
@keyframes recBlink { from { opacity:1; } to { opacity:0.3; } }

.history-actions { display:flex; align-items:center; gap:6px; margin-left:auto; }
.history-del-btn, .history-save-btn { width:28px; height:28px; border-radius:50%; display:flex; align-items:center; justify-content:center; font-size:16px; font-weight:bold; cursor:pointer; opacity:0; transition:transform 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275), background 0.2s, color 0.2s, opacity 0.2s; }
.history-del-btn { background:#fee; color:#e33; }
.history-save-btn { background:#eee; color:#333; }
.history-item:hover .history-del-btn, .history-item:hover .history-save-btn { opacity:1; }
.history-del-btn:hover { background:#f33; color:#fff; transform:scale(1.15); }
.history-save-btn:hover { background:#ccc; transform:scale(1.15); }

.gen-more-loader { display:inline-block; width:14px; height:14px; border:2px solid rgba(255,255,255,0.3); border-radius:50%; border-top-color:#fff; animation:spin 1s linear infinite; margin-right:8px; vertical-align:middle; }

/* ── Color FABs Redesign ───────────────── */
.color-fabs-row{
  display:flex;
  gap:12px;
  margin-bottom:16px;
  flex-wrap:wrap;
  padding:4px;
}

.color-fab-wrap{
  position:relative;
  display:inline-flex;
  align-items:center;
  justify-content:center;
}

.color-fab-wrap:hover .color-fab-tip{
  opacity:1;
  visibility:visible;
  transform:translateX(-50%) translateY(0);
}

.coloris-desktop-input{
  position:absolute;
  width:1px;
  height:1px;
  padding:0;
  margin:0;
  border:0;
  opacity:0;
  pointer-events:none;
  overflow:hidden;
  clip:rect(0 0 0 0);
  clip-path:inset(50%);
}

.color-fab{
  width:44px;
  height:44px;
  border-radius:50%;
  border:none;
  cursor:pointer;
  padding:0;
  transition:transform .18s ease, box-shadow .18s ease, background .18s ease, border-color .18s ease;
}

.color-fab:hover{
  transform:scale(1.04);
}

.color-fab-desktop{
  position:relative;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  background:
    linear-gradient(45deg, rgba(0,0,0,0.06) 25%, transparent 25%, transparent 75%, rgba(0,0,0,0.06) 75%),
    linear-gradient(45deg, rgba(0,0,0,0.06) 25%, transparent 25%, transparent 75%, rgba(0,0,0,0.06) 75%);
  background-position:0 0, 8px 8px;
  background-size:16px 16px;
  border:1px solid rgba(17,17,17,0.08);
  box-shadow:0 8px 20px rgba(0,0,0,0.08);
  overflow:hidden;
}

.color-fab-fill{
  position:absolute;
  inset:0;
  border-radius:50%;
  background:#000;
}

.color-fab-mobile{
  appearance:none;
  background:#fff;
  border:1px solid rgba(17,17,17,0.08);
  box-shadow:0 8px 20px rgba(0,0,0,0.08);
  overflow:hidden;
}

.color-fab-mobile::-webkit-color-swatch-wrapper{
  padding:0;
}

.color-fab-mobile::-webkit-color-swatch{
  border:none;
  border-radius:50%;
}

.color-fab-mobile::-moz-color-swatch{
  border:none;
  border-radius:50%;
}

.color-fab-tip{
  position:absolute;
  top:-35px;
  left:50%;
  transform:translateX(-50%) translateY(5px);
  background:rgba(0,0,0,0.8);
  color:#fff;
  padding:6px 10px;
  border-radius:8px;
  font-size:12px;
  font-weight:600;
  white-space:nowrap;
  opacity:0;
  visibility:hidden;
  transition:opacity .18s ease, visibility .18s ease, transform .18s ease;
  pointer-events:none;
  z-index:10;
}

@media (hover:hover) and (pointer:fine){
  .color-fab-desktop{ display:inline-flex; }
  .color-fab-mobile{ display:none; }

  .clr-picker{
    display:flex;
    width:332px;
    padding:0 0 16px;
    border:none;
    border-radius:24px;
    background:#fff;
    box-shadow:0 14px 34px rgba(0,0,0,0.12);
    overflow:hidden;
    justify-content:flex-start;
    align-items:flex-start;
    opacity:0;
    visibility:hidden;
    pointer-events:none;
    transform:translateY(8px) scale(.985);
    transition:opacity .14s ease, transform .14s cubic-bezier(.23,1,.32,1), visibility .14s ease, box-shadow .14s ease;
  }

  .clr-picker.clr-open,
  .clr-picker[data-inline="true"]{
    opacity:1;
    visibility:visible;
    pointer-events:auto;
    transform:translateY(0) scale(1);
  }

  .clr-gradient{
    order:1;
    width:100%;
    height:216px;
    margin:0 0 14px;
    border:none;
    border-radius:24px 24px 0 0;
  }

  .clr-marker{
    width:26px;
    height:26px;
    margin:-13px 0 0 -13px;
    border:4px solid #fff;
    box-shadow:0 6px 14px rgba(0,0,0,0.16);
  }

  .clr-hue{
    order:2;
  }

  .clr-alpha{
    order:3;
    margin-bottom:14px;
  }

  .clr-hue,
  .clr-alpha{
    width:calc(100% - 36px);
    height:16px;
    margin-left:18px;
    margin-right:18px;
    border:none;
    border-radius:999px;
  }

  .clr-alpha span{
    border-radius:999px;
  }

  .clr-hue div,
  .clr-alpha div{
    width:28px;
    height:28px;
    margin-left:-14px;
    border:4px solid #fff;
    box-shadow:0 6px 14px rgba(0,0,0,0.16);
  }

  .clr-preview{
    display:none !important;
  }

  input.clr-color{
    order:4;
    width:calc(100% - 104px);
    height:46px;
    margin:0 6px 12px 16px;
    padding:0 16px;
    border:2px solid rgba(17,17,17,0.08);
    border-radius:999px;
    box-shadow:none;
    color:#3e3e3e;
    background:#f3f4f6;
    font-family:'neue-haas-grotesk-display', sans-serif;
    font-size:14px;
    font-weight:500;
    letter-spacing:-0.02em;
    text-align:center;
    text-transform:lowercase;
  }

  input.clr-color:focus{
    border-color:#d8d8dd;
    box-shadow:none;
  }

  .clr-eyedropper{
    order:5;
    width:46px;
    height:46px;
    margin:0 16px 12px 0;
    padding:0;
    border:none;
    border-radius:999px;
    background:#f3f4f6;
    color:#111;
    display:inline-flex;
    align-items:center;
    justify-content:center;
    cursor:pointer;
    box-shadow:none;
    transition:transform .14s ease, background .14s ease, opacity .14s ease;
  }

  .clr-eyedropper:hover{
    transform:scale(1.03);
    background:#111;
  }

  .clr-eyedropper-icon{
    width:18px;
    height:18px;
    display:block;
    background-color:#111;
    -webkit-mask:url('Assets_design/color-picker.svg') center / contain no-repeat;
    mask:url('Assets_design/color-picker.svg') center / contain no-repeat;
    transition:background-color .14s ease;
  }

  .clr-eyedropper:hover .clr-eyedropper-icon{
    background-color:#fff;
  }

  .clr-picker.is-eyedropper-busy .clr-eyedropper{
    opacity:.55;
    pointer-events:none;
    transform:none;
  }

  .clr-swatches{
    order:6;
    width:calc(100% - 36px);
    margin:0 18px;
  }

  .clr-swatches div{
    justify-content:flex-start;
    gap:8px;
    padding-bottom:0;
  }

  .clr-swatches button{
    width:38px;
    height:38px;
    margin:0 0 8px;
    box-shadow:0 4px 12px rgba(0,0,0,0.08);
  }

  .clr-format,
  #clr-format,
  #clr-clear,
  #clr-close{
    display:none !important;
  }
}

@media (hover:none), (pointer:coarse){
  .color-fab-desktop{ display:none; }
  .color-fab-mobile{ display:block; }
}

/* ── Webcam Panel ─────────────────────── */
.webcam-card-title{
  display:flex;
  align-items:center;
  gap:10px;
}
.webcam-info-btn{
  position:relative;
  width:22px;
  height:22px;
  border:none;
  border-radius:50%;
  background:#f3f4f6;
  color:#7d7d82;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  cursor:pointer;
  padding:0;
  flex:0 0 auto;
}
.webcam-info-btn:hover{background:#ebecef;color:#36363a}
.webcam-info-btn-mark{
  font-size:12px;
  font-weight:700;
  line-height:1;
}
.webcam-info-tooltip{
  position:absolute;
  left:50%;
  top:calc(100% + 12px);
  width:240px;
  padding:12px 14px;
  border-radius:14px;
  background:#171717;
  color:#fff;
  font-size:12px;
  line-height:1.45;
  font-weight:500;
  text-align:left;
  box-shadow:0 14px 32px rgba(0,0,0,0.22);
  transform:translateX(-50%) translateY(-4px);
  opacity:0;
  visibility:hidden;
  transition:opacity .18s ease, transform .18s ease, visibility .18s ease;
  pointer-events:none;
  z-index:20;
}
.webcam-info-tooltip::before{
  content:'';
  position:absolute;
  left:50%;
  top:-6px;
  width:12px;
  height:12px;
  background:#171717;
  transform:translateX(-50%) rotate(45deg);
}
.webcam-info-btn:hover .webcam-info-tooltip,
.webcam-info-btn:focus-visible .webcam-info-tooltip{
  opacity:1;
  visibility:visible;
  transform:translateX(-50%) translateY(0);
}
.webcam-panel{
  display:flex;
  flex-direction:column;
  gap:14px;
}
.webcam-preview-shell{
  position:relative;
  border-radius:18px;
  overflow:hidden;
  background:#efebe3;
  min-height:214px;
  border:1px solid rgba(0,0,0,0.06);
}
.webcam-preview-shell.is-live{
  background:#efebe3;
}
.webcam-sidebar-preview{
  width:100%;
  aspect-ratio:4 / 3;
  object-fit:cover;
  display:block;
  background:transparent;
  transform:scaleX(-1);
}
.webcam-preview-shell[data-facing-mode="environment"] .webcam-sidebar-preview{
  transform:none;
}
.webcam-preview-overlay{
  position:absolute;
  inset:0;
  display:flex;
  flex-direction:column;
  justify-content:space-between;
  padding:16px;
  background:linear-gradient(180deg, rgba(8,8,8,0.14) 0%, rgba(8,8,8,0.03) 34%, rgba(8,8,8,0.08) 100%);
  pointer-events:none;
}
.webcam-preview-topbar{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:12px;
}
.webcam-status-badge{
  display:inline-flex;
  align-items:center;
  gap:8px;
  align-self:flex-start;
  padding:8px 11px;
  border-radius:999px;
  background:rgba(12,12,12,0.38);
  color:#fff;
  font-size:11px;
  font-weight:700;
  letter-spacing:0.01em;
  backdrop-filter:blur(12px);
  -webkit-backdrop-filter:blur(12px);
}
.webcam-status-badge.is-live{
  background:rgba(12,12,12,0.52);
}
.webcam-status-badge.is-blocked{
  background:rgba(12,12,12,0.52);
}
.webcam-status-badge-dot{
  width:8px;
  height:8px;
  border-radius:50%;
  background:#b9bcc6;
  box-shadow:0 0 0 0 rgba(185,188,198,0.26);
  flex:0 0 auto;
}
.webcam-status-badge.is-live .webcam-status-badge-dot{
  background:#ff5636;
  animation:webcamLivePulse 1.25s ease-in-out infinite;
}
.webcam-status-badge.is-blocked .webcam-status-badge-dot{
  background:#f8d26a;
}
.webcam-status-badge-label{
  white-space:nowrap;
}
.webcam-toggle-fab{
  width:44px;
  height:44px;
  border:none;
  border-radius:50%;
  background:rgba(18,18,18,0.88);
  color:#fff;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  cursor:pointer;
  pointer-events:auto;
  box-shadow:0 12px 24px rgba(0,0,0,0.18);
  transition:transform .18s ease, background .18s ease, opacity .18s ease;
}
.webcam-toggle-fab:hover{transform:translateY(-1px);background:#111}
.webcam-toggle-fab:disabled{
  opacity:.38;
  cursor:not-allowed;
  transform:none;
}
.webcam-toggle-fab svg{
  width:20px;
  height:20px;
  stroke:currentColor;
  fill:none;
  stroke-width:2;
  stroke-linecap:round;
  stroke-linejoin:round;
}
.webcam-toggle-fab.is-off{
  background:rgba(255,255,255,0.9);
  color:#171717;
}
.webcam-toggle-fab-inline{
  flex:0 0 auto;
  background:#171717;
  box-shadow:none;
}
.webcam-toggle-fab-inline.is-off{
  background:#f1efea;
  color:#171717;
}
.webcam-overlay-actions{
  display:flex;
  justify-content:center;
  align-items:flex-end;
  min-height:52px;
  pointer-events:none;
}
.webcam-overlay-actions.is-hidden{
  display:none;
}
.webcam-access-btn{
  min-height:44px;
  padding:12px 22px;
  font-size:12px;
  font-weight:700;
  pointer-events:auto;
  box-shadow:0 14px 32px rgba(0,0,0,0.18);
}
.webcam-control-bar{
  display:flex;
  gap:10px;
  align-items:center;
  justify-content:flex-start;
}
.webcam-tracking-pills{
  display:flex;
  flex-wrap:wrap;
  gap:8px;
}
.webcam-tracking-pills-overlay{
  max-width:62%;
  justify-content:flex-end;
  pointer-events:none;
}
.webcam-tracking-pill{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-height:32px;
  padding:8px 13px;
  border-radius:999px;
  background:rgba(255,255,255,0.84);
  color:#4f4d49;
  font-size:11px;
  font-weight:700;
  letter-spacing:0.01em;
  backdrop-filter:blur(10px);
  -webkit-backdrop-filter:blur(10px);
}
.webcam-export-setting{
  flex:1 1 auto;
  min-height:54px;
  padding:0 16px 0 18px;
  border-radius:999px;
  background:#f4f1eb;
  color:#2b2b2f;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
}
.webcam-export-setting-label{
  font-size:12px;
  font-weight:700;
  color:#4c4a46;
  line-height:1.2;
}
.webcam-export-switch{
  border:none;
  background:transparent;
  padding:0;
  margin:0;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  cursor:pointer;
  flex:0 0 auto;
}
.webcam-export-switch:disabled{
  opacity:.45;
  cursor:not-allowed;
}
.webcam-export-switch-track{
  position:relative;
  width:48px;
  height:28px;
  border-radius:999px;
  background:#d8d5cf;
  transition:background .18s ease;
  display:block;
}
.webcam-export-switch-knob{
  position:absolute;
  left:3px;
  top:3px;
  width:22px;
  height:22px;
  border-radius:50%;
  background:#fff;
  box-shadow:0 6px 14px rgba(0,0,0,0.14);
  transition:transform .18s ease;
}
.webcam-export-switch.is-on .webcam-export-switch-track{
  background:#171717;
}
.webcam-export-switch.is-on .webcam-export-switch-knob{
  transform:translateX(20px);
}
.webcam-canvas-feed-card{
  position:absolute;
  width:200px;
  height:150px;
  border-radius:18px;
  overflow:hidden;
  background:#0f0f10;
  box-shadow:0 18px 40px rgba(0,0,0,0.22);
  border:1px solid rgba(255,255,255,0.18);
  opacity:0;
  visibility:hidden;
  transform:translateY(-10px) scale(0.98);
  transition:opacity .2s ease, transform .2s ease, visibility .2s ease;
  pointer-events:none;
  z-index:8;
}

.home-brand-mobile{display:none}
.webcam-canvas-feed-card.is-visible{
  opacity:1;
  visibility:visible;
  transform:translateY(0) scale(1);
}
.webcam-canvas-preview{
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
  background:#050505;
  transform:scaleX(-1);
}
.webcam-canvas-feed-card[data-facing-mode="environment"] .webcam-canvas-preview{
  transform:none;
}

@keyframes webcamLivePulse{
  0%,100%{box-shadow:0 0 0 0 rgba(255,86,54,0.22)}
  50%{box-shadow:0 0 0 8px rgba(255,86,54,0)}
}

/* ══════════════════════════════════════════
   Figma-inspired Design Styles
   ══════════════════════════════════════════ */

/* Override font for Neue Haas Grotesk */
body {
  font-family: 'neue-haas-grotesk-display', 'Satori', sans-serif !important;
}

/* Figma Input Boxes */
.figma-input-box {
  background: #ffffff;
  border-radius: 10px;
  padding: 20px;
  position: relative;
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.mobile-home-menu-btn,
.mobile-home-menu-card,
.mobile-home-menu-backdrop{
  display:none;
}

.about-mobile-header{
  display:none;
}

.figma-input-box:hover {
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
}

.figma-input-box textarea::placeholder,
.figma-input-box input::placeholder {
  color: #C1C1C1;
  font-family: 'neue-haas-grotesk-display', sans-serif;
  font-weight: 450;
}

/* Image Drop Box Hover */
.img-drop:hover {
  background: #f8f8f8 !important;
  cursor: pointer;
}

/* Create Button Hover Effect */
.figma-create-button:hover:not(:disabled) {
  background: #E61F04 !important;
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(255, 35, 4, 0.25);
}

.figma-create-button:active:not(:disabled) {
  transform: translateY(0);
}

/* Number controls hover */
#varMinus:hover, #varPlus:hover {
  opacity: 0.7;
}

/* Adjust placeholder text styling */
#promptInput::placeholder {
  color: #C1C1C1;
}

#promptInput {
  display: block;
  width: 100%;
  min-height: 197px !important;
  height: 197px !important;
  padding: 20px 66px 20px 20px !important;
  box-sizing: border-box;
  overflow-y: auto;
}

#promptInput:focus::placeholder {
  opacity: 0.5;
}

.prompt-helper-card {
  overflow: visible;
}

.prompt-helper-drop-overlay {
  position: absolute;
  inset: 20px;
  display: flex;
  align-items: flex-end;
  justify-content: flex-start;
  z-index: 2;
  opacity: 0;
  transform: scale(0.985);
  pointer-events: none;
  transition: opacity 0.16s cubic-bezier(0.2, 0.8, 0.2, 1), transform 0.16s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.prompt-helper-card.is-drag-active .prompt-helper-drop-overlay {
  opacity: 1;
  transform: scale(1);
}

.prompt-helper-card.is-drag-active::after {
  content: '';
  position: absolute;
  inset: 10px;
  z-index: 1;
  border-radius: 22px;
  background: rgba(245, 245, 245, 0.9);
  border: 1px solid rgba(31, 31, 31, 0.08);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.75);
  pointer-events: none;
}

.prompt-helper-drop-pill {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 15px;
  border-radius: 999px;
  background: rgba(31, 31, 31, 0.92);
  color: #fff;
  font-family: 'neue-haas-grotesk-display', sans-serif;
  box-shadow: 0 14px 28px rgba(0, 0, 0, 0.18);
}

.prompt-helper-drop-title,
.prompt-helper-drop-copy {
  display: block;
  font-size: 14px;
  line-height: 1;
  letter-spacing: -0.01em;
}

.prompt-helper-drop-copy {
  color: rgba(255, 255, 255, 0.68);
}

.prompt-helper-wrap {
  position: absolute;
  right: 18px;
  bottom: 18px;
  width: 36px;
  min-height: 36px;
  z-index: 3;
}

.prompt-helper-wrap.is-open,
.prompt-helper-wrap.is-settings-open {
  min-height: 126px;
}

.prompt-helper-wrap.is-disabled {
  display: none;
}

.prompt-helper-wrap.is-loading {
  pointer-events: none;
}

.prompt-helper-fab {
  position: absolute;
  right: 0;
  bottom: 0;
  width: 36px;
  height: 36px;
  border: none;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  background: transparent;
  color: #d1d1d1;
  cursor: pointer;
  box-shadow: none;
  transition: transform 0.16s cubic-bezier(0.2, 0.8, 0.2, 1), background-color 0.16s ease, color 0.16s ease, box-shadow 0.16s ease, opacity 0.16s ease;
}

.prompt-helper-fab:hover {
  transform: scale(1.06);
  background: #f3f3f3;
  color: #1f1f1f;
  box-shadow: none;
}

.prompt-helper-fab:active {
  transform: scale(0.96);
}

.prompt-helper-wrap.is-open .prompt-helper-fab,
.prompt-helper-wrap.is-loading .prompt-helper-fab {
  background: #f3f3f3;
  color: #1f1f1f;
  box-shadow: none;
}

.prompt-helper-wrap.is-loading .prompt-helper-fab {
  box-shadow: none;
}

.prompt-helper-fab-icon,
.prompt-helper-action-icon {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.16s ease;
}

.prompt-helper-fab-icon svg,
.prompt-helper-fab-icon img {
  width: 18px;
  height: 18px;
  display: block;
  opacity: 0.26;
  transition: opacity 0.16s ease;
}

.prompt-helper-action-icon svg,
.prompt-helper-action-icon img {
  width: 18px;
  height: 18px;
  display: block;
  opacity: 0.38;
  transition: opacity 0.16s ease;
}

.prompt-helper-fab:hover .prompt-helper-fab-icon img,
.prompt-helper-fab:hover .prompt-helper-fab-icon svg,
.prompt-helper-wrap.is-open .prompt-helper-fab-icon img,
.prompt-helper-wrap.is-loading .prompt-helper-fab-icon img,
.prompt-helper-wrap.is-open .prompt-helper-fab-icon svg,
.prompt-helper-wrap.is-loading .prompt-helper-fab-icon svg,
.prompt-helper-action:hover .prompt-helper-action-icon img,
.prompt-helper-action:hover .prompt-helper-action-icon svg {
  opacity: 1;
}

.prompt-helper-fab::before {
  content: '';
  position: absolute;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  border: 2px solid rgba(31, 31, 31, 0.14);
  border-top-color: #1f1f1f;
  opacity: 0;
  transition: opacity 0.16s ease;
}

.prompt-helper-wrap.is-loading .prompt-helper-fab::before {
  opacity: 1;
  animation: promptHelperSpin 0.9s linear infinite;
}

.prompt-helper-wrap.is-loading .prompt-helper-fab-icon {
  opacity: 0;
}

.prompt-helper-menu,
.prompt-helper-settings-card {
  position: absolute;
  right: 0;
  bottom: 46px;
  opacity: 0;
  transform: translateY(8px) scale(0.9);
  pointer-events: none;
  transition: opacity 0.16s cubic-bezier(0.2, 0.8, 0.2, 1), transform 0.16s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.prompt-helper-wrap.is-open .prompt-helper-menu {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}

.prompt-helper-wrap.is-settings-open .prompt-helper-settings-card {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}

.prompt-helper-menu {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.prompt-helper-action {
  border: none;
  cursor: pointer;
  padding: 0;
  margin: 0;
  font-family: 'neue-haas-grotesk-display', sans-serif;
}

.prompt-helper-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #f3f3f3;
  color: #a7a7a7;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.06);
  transition: transform 0.14s cubic-bezier(0.2, 0.8, 0.2, 1), background-color 0.14s ease, color 0.14s ease, box-shadow 0.14s ease;
}

.prompt-helper-wrap.is-open .prompt-helper-action,
.prompt-helper-action:hover {
  transform: translateY(-1px) scale(1.06);
  background: #f3f3f3;
  color: #1f1f1f;
  box-shadow: none;
}

.prompt-helper-wrap.is-open .prompt-helper-action-icon img,
.prompt-helper-wrap.is-open .prompt-helper-action-icon svg {
  opacity: 1;
}

.prompt-helper-action:active {
  transform: scale(0.96);
}

.prompt-helper-action.is-loading {
  pointer-events: none;
  background: #f3f3f3;
  color: #1f1f1f;
}

.prompt-helper-action-icon {
  width: 18px;
  height: 18px;
}

.prompt-helper-fab::after,
.prompt-helper-action::after {
  content: attr(data-tooltip);
  position: absolute;
  top: 50%;
  left: calc(100% + 12px);
  transform: translateY(-50%) translateX(-4px);
  padding: 7px 10px;
  border-radius: 999px;
  background: rgba(31, 31, 31, 0.92);
  color: #fff;
  font-family: 'neue-haas-grotesk-display', sans-serif;
  font-size: 12px;
  line-height: 1;
  font-weight: 500;
  letter-spacing: -0.01em;
  white-space: nowrap;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.14s ease, transform 0.14s cubic-bezier(0.2, 0.8, 0.2, 1);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.12);
}

.prompt-helper-fab:hover::after,
.prompt-helper-action:hover::after {
  opacity: 1;
  transform: translateY(-50%) translateX(0);
}

.prompt-helper-wrap.is-loading .prompt-helper-fab::after,
.prompt-helper-wrap.is-loading .prompt-helper-action::after {
  opacity: 0 !important;
}

.prompt-helper-settings-card {
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-width: 240px;
  right: 44px;
  bottom: -4px;
  padding: 12px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.98);
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.12);
  transform-origin: bottom right;
}

.prompt-helper-settings-header {
  font-family: 'neue-haas-grotesk-display', sans-serif;
  font-size: 13px;
  line-height: 1;
  font-weight: 500;
  letter-spacing: -0.01em;
  color: #5f5f5f;
  padding: 2px 4px 4px;
}

.prompt-helper-select-row {
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.prompt-helper-select-label {
  font-family: 'neue-haas-grotesk-display', sans-serif;
  font-size: 13px;
  line-height: 1;
  font-weight: 500;
  letter-spacing: -0.01em;
  color: #1f1f1f;
  padding: 0 4px;
}

.prompt-helper-select {
  width: 100%;
  appearance: none;
  border: none;
  border-radius: 16px;
  background: #f4f4f4;
  color: #1f1f1f;
  min-height: 40px;
  padding: 0 38px 0 14px;
  font-family: 'neue-haas-grotesk-display', sans-serif;
  font-size: 14px;
  line-height: 1.1;
  font-weight: 450;
  letter-spacing: -0.01em;
  outline: none;
  background-image: linear-gradient(45deg, transparent 50%, #6f6f6f 50%), linear-gradient(135deg, #6f6f6f 50%, transparent 50%);
  background-position: calc(100% - 18px) calc(50% - 2px), calc(100% - 12px) calc(50% - 2px);
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
}

.prompt-helper-select:disabled {
  opacity: 0.55;
  cursor: default;
}

@keyframes promptHelperSpin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

/* Custom controls input */
#customControlsInput::placeholder {
  color: #C1C1C1;
}

#customControlsInput:focus::placeholder {
  color: #C1C1C1;
}

.reference-drop-text {
  color: #C1C1C1;
  font-size: 20px;
  font-family: 'neue-haas-grotesk-display', sans-serif;
  font-weight: 450;
  line-height: 1.15;
  letter-spacing: -0.01em;
}

.reference-mode-toggle {
  display: flex;
  align-items: center;
  gap: 14px;
}

.reference-mode-btn {
  border: none;
  background: none;
  padding: 0;
  margin: 0;
  font-family: 'neue-haas-grotesk-display', sans-serif;
  font-size: 20px;
  font-weight: 450;
  line-height: 1;
  letter-spacing: -0.02em;
  color: #C1C1C1;
  cursor: pointer;
  transition: color 0.18s ease, opacity 0.18s ease;
}

.reference-mode-btn:hover {
  color: #666;
}

.reference-mode-btn.is-active {
  color: #000;
}

/* Animation for decorative shape */
@keyframes floatShape {
  0%, 100% {
    transform: rotate(180deg) translateY(0);
  }
  50% {
    transform: rotate(180deg) translateY(-10px);
  }
}

/* Apply animation to decorative shape */
#formSection > div:first-child {
  animation: floatShape 6s ease-in-out infinite;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  #uploadPanel {
    max-width: 90% !important;
  }
  
  .figma-input-box {
    padding: 15px;
  }
  
  #formSection > div:nth-child(2) > div:nth-child(3) {
    flex-direction: column;
  }
  
  #formSection > div:nth-child(2) > div:nth-child(4) {
    flex-direction: column;
  }
  
  .figma-input-box[style*="width:175px"] {
    width: 100% !important;
  }
}

@media (max-width: 900px) {
  body{
    overflow:hidden;
  }

  #homePage{
    align-items:flex-start !important;
    justify-content:flex-start !important;
    padding:96px 24px 56px !important;
    overflow-y:auto !important;
    overflow-x:hidden !important;
  }

  #uploadPanel{
    width:100% !important;
    max-width:none !important;
    padding:0 0 20px !important;
    gap:16px !important;
    margin:0 auto !important;
    position:relative;
    z-index:1;
    overflow-x:hidden !important;
  }

  #uploadPanel > div:nth-child(2){
    flex-direction:column !important;
    gap:14px !important;
  }

  #uploadPanel > div:nth-child(3){
    flex-direction:column !important;
    align-items:stretch !important;
    gap:16px !important;
  }

  #numberSelectorBox{
    width:100% !important;
    min-width:0 !important;
    max-width:none !important;
    flex:0 0 auto !important;
    height:64px !important;
    min-height:64px !important;
    max-height:64px !important;
    justify-content:space-between !important;
    padding-inline:18px !important;
    border-radius:22px !important;
  }

  #generateBtn{
    min-height:64px !important;
    max-height:64px !important;
    height:64px !important;
    padding:0 20px !important;
    width:100% !important;
    flex:0 0 auto !important;
  }

  #varCount{
    font-size:24px !important;
  }

  #generateBtn span{
    font-size:16px !important;
  }

  #showcaseCornerText,
  #loadVisuBtn,
  #aboutCornerText,
  #closeAbout,
  #showcaseTitle{
    font-size:20px !important;
  }

  #showcaseCornerText,
  #loadVisuBtn,
  #aboutCornerText{
    top:auto !important;
  }

  #showcaseCornerText{
    top:16px !important;
    right:16px !important;
  }

  #loadVisuBtn{
    left:22px !important;
    bottom:22px !important;
    padding:10px 0 !important;
    border-radius:0 !important;
    background:transparent !important;
    box-shadow:none !important;
  }

  #aboutCornerText{
    right:16px !important;
    bottom:16px !important;
  }

  #showcaseCornerText,
  #loadVisuBtn,
  #aboutCornerText{
    display:none !important;
  }

  #homeBrandMark{
    top:24px !important;
    left:24px !important;
    height:52px !important;
    display:flex !important;
    align-items:center !important;
    font-size:32px !important;
    color:#FF2304 !important;
    line-height:1 !important;
    z-index:28 !important;
  }

  .mobile-home-menu-btn{
    position:fixed;
    top:24px;
    right:24px;
    width:52px;
    height:52px;
    border:none;
    border-radius:50%;
    background:#fff;
    color:#1f1f1f;
    box-shadow:0 10px 24px rgba(0,0,0,0.10);
    display:flex;
    align-items:center;
    justify-content:center;
    flex-direction:column;
    gap:4px;
    z-index:30;
  }

  .mobile-home-menu-btn span{
    width:18px;
    height:2px;
    border-radius:999px;
    background:currentColor;
    transition:transform .18s ease, opacity .18s ease;
  }

  .mobile-home-menu-btn.is-open span:nth-child(1){
    transform:translateY(6px) rotate(45deg);
  }

  .mobile-home-menu-btn.is-open span:nth-child(2){
    opacity:0;
  }

  .mobile-home-menu-btn.is-open span:nth-child(3){
    transform:translateY(-6px) rotate(-45deg);
  }

  .mobile-home-menu-card{
    position:fixed;
    top:92px;
    left:24px;
    right:24px;
    display:flex;
    flex-direction:column;
    gap:12px;
    padding:0;
    border-radius:0;
    background:transparent;
    box-shadow:none;
    opacity:0;
    pointer-events:none;
    transform:translateY(-10px) scale(.98);
    transition:opacity .22s ease, transform .22s cubic-bezier(.23,1,.32,1);
    z-index:29;
  }

  .mobile-home-menu-card.is-open{
    opacity:1;
    pointer-events:auto;
    transform:translateY(0) scale(1);
  }

  .mobile-home-menu-backdrop{
    position:fixed;
    inset:0;
    display:block;
    opacity:0;
    pointer-events:none;
    background:rgba(248,246,242,0);
    backdrop-filter:blur(0px);
    -webkit-backdrop-filter:blur(0px);
    transition:opacity .24s ease, background .24s ease, backdrop-filter .24s ease, -webkit-backdrop-filter .24s ease;
    z-index:24;
  }

  .mobile-home-menu-backdrop.is-open{
    opacity:1;
    pointer-events:auto;
    background:rgba(248,246,242,0.34);
    backdrop-filter:blur(18px);
    -webkit-backdrop-filter:blur(18px);
  }

  .mobile-home-menu-item{
    min-height:70px;
    border:none;
    border-radius:999px;
    background:#fff;
    color:#1f1f1f;
    font-family:'neue-haas-grotesk-display', sans-serif;
    font-size:20px;
    font-weight:450;
    text-align:left;
    padding:0 24px;
    box-shadow:0 14px 30px rgba(0,0,0,0.10);
  }

  #backgroundIframe{
    position:fixed !important;
    inset:0 !important;
    width:100% !important;
    height:100svh !important;
  }

  .onboarding-tooltip,
  .onboarding-beacon{
    display:none !important;
  }

  .home-brand-desktop{
    display:none !important;
  }

  .home-brand-mobile{
    display:block;
  }

  #globalVisuMark,
  #globalHausMark{
    display:none !important;
  }

  #aboutPage{
    top:0 !important;
    right:-100vw !important;
    width:100vw !important;
    height:100svh !important;
    border-radius:0 !important;
    background:#EAEAEA !important;
    box-shadow:none !important;
    overflow-y:auto !important;
    overflow-x:hidden !important;
    z-index:130 !important;
  }

  .loader .skeleton-sidebar{
    display:none !important;
  }

  #pongCanvas{
    display:none !important;
  }

  #analyzingPill{
    left:50% !important;
    top:50% !important;
    width:min(360px, calc(100vw - 56px)) !important;
    height:78px !important;
    padding:0 68px 0 30px !important;
  }

  #analyzingText{
    font-size:17px !important;
  }

  body.is-compact-ui #sidebar{
    top:82px !important;
    left:0 !important;
    right:0 !important;
    bottom:0 !important;
    width:100vw !important;
    min-width:0 !important;
    max-width:none !important;
    height:auto !important;
    max-height:calc(100svh - 82px) !important;
    border-radius:30px 30px 0 0 !important;
    box-shadow:0 -18px 54px rgba(0,0,0,0.18) !important;
    overflow:visible !important;
    background-color:rgba(255,255,255,0.96) !important;
    border:1px solid rgba(255,255,255,0.24) !important;
    backdrop-filter:none !important;
    -webkit-backdrop-filter:none !important;
    transform:translateY(var(--sheet-offset-y, 0px)) !important;
    transition:transform .32s cubic-bezier(.23,1,.32,1), background-color .24s cubic-bezier(.23,1,.32,1), opacity .24s cubic-bezier(.23,1,.32,1) !important;
    z-index:140 !important;
  }

  body.is-compact-ui.is-control-scrubbing #sidebar{
    background-color:rgba(255,255,255,0.60) !important;
    border-color:rgba(255,255,255,0.18) !important;
    backdrop-filter:none !important;
    -webkit-backdrop-filter:none !important;
  }

  body.is-compact-ui #sidebar.collapsed{
    transform:translateY(calc(100% + 18px)) !important;
    pointer-events:none !important;
  }

  body.is-compact-ui #sidebar.is-sheet-dragging{
    transition:none !important;
  }

  body.is-compact-ui .editor-brand{
    height:68px;
    flex-shrink:0;
    cursor:grab;
    touch-action:none;
  }

  body.is-compact-ui .editor-brand:active{
    cursor:grabbing;
  }

  body.is-compact-ui .editor-brand::before{
    content:'';
    position:absolute;
    top:6px;
    left:50%;
    width:46px;
    height:5px;
    border-radius:999px;
    background:rgba(31,31,31,0.14);
    transform:translateX(-50%);
  }

  body.is-compact-ui .editor-brand .editor-brand-title{
    font-size:16px !important;
    max-width:180px;
  }

  body.is-compact-ui .editor-file-name-shell{
    max-width:calc(100% - 128px);
  }

  body.is-compact-ui .editor-menu-wrap{
    right:10px;
  }

  body.is-compact-ui .editor-menu-popover{
    top:calc(100% + 8px);
    left:auto;
    right:0;
    width:min(248px, calc(100vw - 24px));
    transform-origin:top right;
    overflow:visible;
  }

  body.is-compact-ui .editor-menu-card{
    left:0;
    top:0 !important;
    width:100%;
    transform:translateX(12px) scale(.985);
  }

  body.is-compact-ui .editor-menu-card-quality::before,
  body.is-compact-ui .editor-menu-card-export::before,
  body.is-compact-ui .editor-menu-card-html::before{
    display:none;
  }

  body.is-compact-ui .editor-menu-wrap.is-open .editor-menu-card-main{
    opacity:0;
    visibility:hidden;
    pointer-events:none;
    transform:translateX(-12px) scale(.985);
  }

  body.is-compact-ui .editor-menu-wrap.is-open .editor-menu-popover[data-branch=""] .editor-menu-card-main{
    opacity:1;
    visibility:visible;
    pointer-events:auto;
    transform:translateX(0) scale(1);
  }

  body.is-compact-ui .editor-menu-popover[data-branch="quality"] .editor-menu-card-quality,
  body.is-compact-ui .editor-menu-popover[data-branch="export"] .editor-menu-card-export,
  body.is-compact-ui .editor-menu-popover[data-branch="export-html"] .editor-menu-card-html{
    opacity:1;
    visibility:visible;
    pointer-events:auto;
    transform:translateX(0) scale(1);
  }

  body.is-compact-ui .editor-menu-popover[data-branch="export-html"] .editor-menu-card-export{
    opacity:0;
    visibility:hidden;
    pointer-events:none;
    transform:translateX(-12px) scale(.985);
  }

  body.is-compact-ui .editor-menu-item-back{
    display:flex;
  }

  body.is-compact-ui .editor-back-btn{
    top:calc(50% - 10px);
    left:14px;
    width:40px;
    height:40px;
    border-radius:999px;
    border:none;
    box-shadow:none;
    background:rgba(255,255,255,0.92);
    transform:translateY(-14%);
  }

  body.is-compact-ui .editor-back-btn::after{
    display:none;
  }

  body.is-compact-ui #editorPanel{
    padding-bottom:calc(34px + env(safe-area-inset-bottom)) !important;
    overscroll-behavior:contain;
  }

  body.is-compact-ui .mobile-history-slot{
    display:none;
    padding:16px 16px 10px;
    position:relative;
    top:auto;
    z-index:3;
    margin-top:0;
    background:transparent;
    backdrop-filter:none;
    -webkit-backdrop-filter:none;
    overflow:visible;
  }

  body.is-compact-ui .mobile-history-slot:empty{
    display:none;
  }

  body.is-compact-ui .mobile-history-slot.has-history{
    display:block;
  }

  body.is-compact-ui .mobile-history-slot:not(.has-history){
    padding:0;
    margin-top:0;
  }

  body.is-compact-ui #sidebarToggle{
    display:none !important;
  }

  body.is-compact-ui .sidebar-reveal-btn{
    left:0;
    right:0;
    top:auto;
    bottom:0;
    width:100%;
    height:74px;
    padding:10px 24px 16px;
    transform:none;
    justify-content:center;
    flex-direction:column;
    gap:8px;
    border-radius:28px 28px 0 0;
    background:rgba(255,255,255,0.96);
    box-shadow:0 18px 38px rgba(0,0,0,0.16);
    z-index:100;
  }

  body.is-compact-ui .sidebar-reveal-btn::before{
    content:'';
    width:42px;
    height:5px;
    border-radius:999px;
    background:rgba(31,31,31,0.14);
    display:block;
    flex:0 0 auto;
    transform:translateY(-2px);
  }

  body.is-compact-ui .sidebar-reveal-btn svg{
    display:none;
  }

  body.is-compact-ui .sidebar-reveal-label{
    font-size:13px;
    letter-spacing:0;
  }

  body.is-compact-ui .sidebar-reveal-btn:hover{
    transform:none;
  }

  body.is-compact-ui .version-menu-wrap{
    width:min(244px, calc(100vw - 32px));
    z-index:72;
  }

  body.is-compact-ui .mobile-history-slot .version-menu-wrap{
    position:relative;
    top:auto !important;
    left:auto !important;
    width:100% !important;
    z-index:auto;
    overflow:visible;
  }

  body.is-compact-ui .mobile-history-slot .version-menu-wrap:not(.is-visible){
    display:none;
  }

  body.is-compact-ui .version-menu-wrap.is-open{
    width:min(340px, calc(100vw - 24px));
  }

  body.is-compact-ui .mobile-history-slot .version-menu-wrap.is-open{
    width:100% !important;
  }

  body.is-compact-ui .version-pill{
    height:60px;
    gap:12px;
    padding:8px 16px 8px 8px;
    border-radius:24px;
    background:#fff;
    border-color:rgba(0,0,0,0.05);
    box-shadow:0 6px 14px rgba(0,0,0,0.05);
  }

  body.is-compact-ui .version-pill-preview{
    width:44px;
    height:44px;
  }

  body.is-compact-ui .version-pill-title,
  body.is-compact-ui .version-pill-meta{
    font-size:15px;
  }

  body.is-compact-ui .version-pill-title{
    min-width:0;
    flex:1 1 auto;
  }

  body.is-compact-ui .version-pill-meta{
    gap:8px;
    flex:0 0 auto;
  }

  body.is-compact-ui #activeVersLabel{
    white-space:nowrap;
  }

  body.is-compact-ui .version-pill-meta svg{
    display:block;
    flex:0 0 auto;
  }

  body.is-compact-ui .history-modal{
    left:0;
    width:100%;
    max-height:min(44vh, 360px);
    padding:4px 0 22px;
  }

  body.is-compact-ui .mobile-history-slot .history-modal{
    position:absolute;
    top:calc(100% + 8px);
    left:0;
    width:100%;
    padding:4px 0 14px;
  }

  body.is-compact-ui .history-list{
    padding:0 0 20px;
  }

  body.is-compact-ui .history-item{
    min-height:88px;
    border-radius:28px;
    background:#fff;
    box-shadow:0 7px 16px rgba(0,0,0,0.05);
  }

  body.is-compact-ui .fabs{
    top:18px;
    left:0;
    right:0;
    transform:none;
    gap:0;
    z-index:70;
    pointer-events:none;
    justify-content:center;
  }

  body.is-compact-ui .fab-action-group{
    position:fixed;
    top:18px;
    left:50%;
    right:auto;
    flex-direction:row;
    gap:12px;
    z-index:68;
    transform:translateX(-50%);
    pointer-events:auto;
  }

  body.is-compact-ui #fullscreenBtn{
    position:fixed;
    top:18px;
    right:16px;
    left:auto;
    z-index:69;
    pointer-events:auto;
  }

  body.is-compact-ui .camera-controls{
    right:16px;
    top:50%;
    bottom:auto;
    transform:translateY(-50%);
    z-index:66;
  }

  body.is-compact-ui #panBtn{
    display:none;
  }

  body.is-compact-ui #zoomBtn{
    display:flex;
  }

  body.is-compact-ui #zoomBtn.active{
    background:#1f1f1f;
    color:#fff;
    box-shadow:0 0 0 4px rgba(31,31,31,0.18), 0 10px 22px rgba(0,0,0,0.2);
    animation:mobileZoomPulse 1.35s ease-in-out infinite;
  }

  body.is-compact-ui .camera-btn-mobile-only{
    display:none !important;
  }

  body.is-compact-ui input[type=range]{
    height:44px;
    width:calc(100% - 12px);
    margin:0 6px;
    box-shadow:inset 0 0 0 1px rgba(31,31,31,0.10);
  }

  body.is-compact-ui input[type=range]::-webkit-slider-thumb{
    width:36px;
    height:36px;
  }

  body.is-compact-ui input[type=range].is-scrubbing::-webkit-slider-thumb{
    transform:scale(1.18);
  }

  body.is-compact-ui .gallery-wrap{
    left:12px !important;
    right:12px !important;
    bottom:96px !important;
    z-index:40;
  }

  body.is-compact-ui .snap-gallery{
    gap:8px;
    padding:28px 8px 6px;
  }

  body.is-compact-ui .snap-thumb-media,
  body.is-compact-ui .snap-thumb-fallback{
    height:58px;
  }

  body.is-compact-ui .snap-del{
    display:none !important;
  }

  body.is-compact-ui .snap-download{
    display:none !important;
  }

  body.is-compact-ui .rec-badge{
    top:16px;
    height:48px;
    padding:0 18px;
    font-size:12px;
  }

  body.is-compact-ui #fpsCounter{
    bottom:96px !important;
    right:16px !important;
    font-size:9px !important;
  }

  body.is-compact-ui #sidebarBackdrop{
    z-index:130;
    background:transparent;
    backdrop-filter:none;
    -webkit-backdrop-filter:none;
  }

  body.is-compact-ui .card,
  body.is-compact-ui #followUpSection,
  body.is-compact-ui .card-body{
    background:transparent !important;
  }

  body.is-compact-ui .card,
  body.is-compact-ui #followUpSection{
    padding:24px 24px 28px !important;
  }

  body.is-compact-ui .editor-brand,
  body.is-compact-ui .mobile-history-slot,
  body.is-compact-ui .card-hdr,
  body.is-compact-ui .ratio-pills,
  body.is-compact-ui #followUpSection,
  body.is-compact-ui .webcam-panel,
  body.is-compact-ui .ctrl{
    transition:opacity .24s cubic-bezier(.23,1,.32,1);
  }

  body.is-compact-ui.is-control-scrubbing .editor-brand,
  body.is-compact-ui.is-control-scrubbing .mobile-history-slot,
  body.is-compact-ui.is-control-scrubbing .card-hdr,
  body.is-compact-ui.is-control-scrubbing .ratio-pills,
  body.is-compact-ui.is-control-scrubbing #followUpSection,
  body.is-compact-ui.is-control-scrubbing .webcam-panel,
  body.is-compact-ui.is-control-scrubbing .ctrl{
    opacity:.34;
  }

  body.is-compact-ui.is-control-scrubbing .ctrl.is-active-scrub,
  body.is-compact-ui.is-control-scrubbing .ctrl.is-active-scrub *{
    opacity:1 !important;
  }

  body.is-ui-fullscreen.is-compact-ui #sidebar{
    opacity:0;
    pointer-events:none;
    transform:translateY(calc(100% + 24px)) !important;
  }

  body.is-ui-fullscreen.is-compact-ui .fullscreen-exit-btn{
    top:18px;
    right:16px;
    width:56px;
    height:56px;
  }

  body.is-ui-fullscreen.is-compact-ui .fab-action-group{
    top:18px;
    left:50%;
    right:auto;
    gap:12px;
    transform:translateX(-50%);
  }

  body.is-ui-fullscreen.is-fullscreen-exit-visible.is-compact-ui .fab-action-group{
    transform:translateX(-50%);
  }

  body.is-compact-ui .showcase-title,
  body.is-compact-ui .showcase-close{
    top:24px;
  }

  body.is-compact-ui .showcase-title,
  body.is-compact-ui #showcaseTitle{
    left:24px;
    height:52px;
    display:flex;
    align-items:center;
    font-size:32px !important;
    line-height:1;
  }

  body.is-compact-ui .showcase-close,
  body.is-compact-ui #closeShowcase{
    right:24px;
    width:52px;
    height:52px;
    border-radius:50%;
    background:#fff;
    box-shadow:0 10px 24px rgba(0,0,0,0.10);
    display:flex;
    align-items:center;
    justify-content:center;
    font-size:0;
    line-height:0;
    padding:0;
    color:transparent;
    overflow:hidden;
  }

  body.is-compact-ui .showcase-close::before,
  body.is-compact-ui #closeShowcase::before{
    content:'×';
    font-size:28px;
    line-height:1;
    color:#1f1f1f;
  }

  body.is-compact-ui .fab-tip,
  body.is-compact-ui .camera-tip{
    display:none;
  }

  #uploadPanel{
    padding:50px 0 28px !important;
  }

  #uploadPanel .form-card{
    min-height:166px !important;
  }

  #numberSelectorBox.form-card,
  #generateBtn.form-card{
    min-height:64px !important;
    max-height:64px !important;
    height:64px !important;
    padding-top:0 !important;
    padding-bottom:0 !important;
  }

  #promptInput,
  #customControlsInput{
    min-height:126px !important;
    font-size:18px !important;
  }

  #promptInput{
    height:126px !important;
    padding:20px 58px 20px 20px !important;
  }

  .prompt-helper-wrap{
    right:14px;
    bottom:14px;
  }

  .prompt-helper-fab{
    width:34px;
    height:34px;
  }

  .prompt-helper-action{
    width:34px;
    height:34px;
  }

  .prompt-helper-settings-card{
    min-width:206px;
    bottom:-4px;
  }

  .prompt-helper-select,
  .prompt-helper-select-label,
  .prompt-helper-settings-header{
    font-size:12px;
  }

  #aboutOverlay{
    background:rgba(0,0,0,0.12) !important;
    z-index:129 !important;
  }

  .about-mobile-header{
    position:sticky;
    top:0;
    z-index:3;
    display:flex;
    align-items:center;
    justify-content:space-between;
    height:76px;
    padding:24px;
    background:transparent;
  }

  .about-mobile-title{
    height:52px;
    display:flex;
    align-items:center;
    font-family:'neue-haas-grotesk-display', sans-serif;
    font-size:32px;
    font-weight:450;
    line-height:1;
    color:#000;
  }

  .about-mobile-close{
    width:52px;
    height:52px;
    border:none;
    border-radius:50%;
    background:#fff;
    box-shadow:0 10px 24px rgba(0,0,0,0.10);
    padding:0;
    font-size:0;
    display:flex;
    align-items:center;
    justify-content:center;
    cursor:pointer;
  }

  .about-mobile-close::before{
    content:'×';
    font-size:28px;
    line-height:1;
    color:#1f1f1f;
  }

  .about-content-shell{
    padding:16px 24px 32px;
  }

  .about-meta-list{
    margin-top:4px;
  }

  .about-meta-row{
    align-items:flex-start;
  }

  .about-meta-label,
  .about-meta-value{
    display:block;
  }

  .about-description-block{
    margin-top:28px;
  }

  #closeAbout{
    display:none !important;
  }

  .about-accordion-trigger,
  .about-accordion-copy,
  #aboutPage a,
  #aboutPage span,
  #aboutPage p{
    font-size:18px !important;
  }
}

@keyframes mobileZoomPulse{
  0%,100%{box-shadow:0 0 0 4px rgba(31,31,31,0.18), 0 10px 22px rgba(0,0,0,0.2)}
  50%{box-shadow:0 0 0 8px rgba(31,31,31,0.08), 0 12px 26px rgba(0,0,0,0.24)}
}

/* Load Demo and Load Session buttons */
#demoBtn, #loadBtnUpload {
  transition: color 0.2s;
}

#demoBtn:hover, #loadBtnUpload:hover {
  color: #1f1f1f !important;
}

/* Text inputs - gray placeholder, black when typing/focused */
#promptInput:focus,
#promptInput:not(:placeholder-shown) {
  color: #1f1f1f !important;
}

/* Fix text cursor - remove border radius that cuts the cursor */
#promptInput {
  border-radius: 0 !important;
}

#customControlsInput:focus,
#customControlsInput:not(:placeholder-shown) {
  color: #1f1f1f !important;
}

/* Image upload box - fix click area and remove outlines */
.img-drop {
  pointer-events: auto !important;
  outline: none !important;
}

#imageUploadContent {
  pointer-events: auto !important;
}

.img-drop:focus,
.img-drop.has-file {
  outline: none !important;
  box-shadow: none !important;
  border: none !important;
}

/* Image preview centering and delete button animation */
#imagePreviewContainer {
  display: flex;
  align-items: center !important;
  justify-content: center !important;
  width: 100%;
  height: 100%;
}

#imagePreviewShell {
  position: relative;
  width: 100%;
  height: 100%;
  padding: 20px;
  box-sizing: border-box;
  display: flex;
  align-items: center;
  justify-content: center;
}

#imagePreviewStage {
  background: #EAE8E6;
  border-radius: 999px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

#imagePreview {
  display: block;
  width: 100%;
  height: 100%;
  max-width: none;
  max-height: none;
  object-fit: contain;
  border-radius: 999px;
  pointer-events: none; /* Prevent image from blocking clicks when hidden */
}

#deleteImage {
  transition: opacity 0.3s cubic-bezier(0.4, 0, 0.2, 1), transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), background 0.2s;
  pointer-events: auto;
  top: 20px !important;
  right: 20px !important;
  z-index: 2;
}

/* Only show delete button on hover when image container is visible */
#imagePreviewContainer[style*="display: block"]:hover #deleteImage,
#imagePreviewContainer[style*="display: flex"]:hover #deleteImage {
  opacity: 1 !important;
  transform: scale(1.1) !important;
}

/* Additional hover effect for delete button when visible */
#deleteImage:hover {
  background: #333 !important;
}

/* Ensure delete button is completely hidden when container is hidden */
#imagePreviewContainer[style*="display: none"] #deleteImage {
  display: none !important;
  pointer-events: none !important;
}

/* Hide any circles that might appear on hover */
.img-drop::before,
.img-drop::after,
.img-drop:hover::before,
.img-drop:hover::after {
  display: none !important;
  content: none !important;
}

/* Remove any lines/strokes from image upload area */
#imgDrop,
#imgDrop *,
#imageUploadContent,
#imageUploadContent * {
  border: none !important;
  outline: none !important;
  box-shadow: none !important;
  text-decoration: none !important;
}

#imagePreviewContainer::before,
#imagePreviewContainer::after,
#imgDrop::before,
#imgDrop::after,
#imageUploadContent::before,
#imageUploadContent::after {
  display: none !important;
  content: none !important;
}

/* Ensure no stroke on SVG elements EXCEPT delete button */
#imgDrop svg:not(#deleteImage svg),
#imgDrop svg:not(#deleteImage svg) *,
#imageUploadContent svg,
#imageUploadContent svg * {
  stroke: none !important;
  border: none !important;
  outline: none !important;
}

/* Keep the white stroke on delete button X */
#deleteImage svg,
#deleteImage svg * {
  stroke: #fff !important;
}

.showcase-page {
  position: fixed;
  inset: 0;
  z-index: 130;
  overflow-y: auto;
  visibility: hidden;
  pointer-events: none;
  background: #EAEAEA;
}

.showcase-page.is-open {
  visibility: visible;
  pointer-events: auto;
}

.showcase-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1;
  background: #EAEAEA;
}

.showcase-page.is-open .showcase-backdrop {
  background: #EAEAEA;
}

.showcase-title,
.showcase-close {
  position: fixed;
  top: 32px;
  z-index: 3;
  font-family: 'neue-haas-grotesk-display', sans-serif;
  font-size: 33px;
  font-weight: 450;
  line-height: 0.9;
  color: #000;
}

.showcase-title {
  left: 32px;
}

.showcase-close {
  right: 32px;
  border: none;
  background: none;
  padding: 0;
  cursor: pointer;
}

.showcase-close:hover {
  color: rgba(0, 0, 0, 0.58);
}

.showcase-stage {
  position: relative;
  z-index: 2;
  min-height: 1700px;
  padding: 110px 24px 72px;
}

.showcase-card {
  position: absolute;
  width: min(var(--card-width), calc(100vw - 48px));
  opacity: 0;
  transform: translateY(26px) scale(0.985);
  cursor: grab;
  transition: opacity 0.24s ease, transform 0.24s ease;
}

.showcase-page.is-open .showcase-card {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.showcase-card.dragging {
  cursor: grabbing;
  z-index: 4;
  transition: none;
}

.showcase-card.resizing {
  z-index: 4;
  transition: none;
}

.showcase-media {
  width: 100%;
  overflow: hidden;
  border-radius: 10px;
  position: relative;
}

.showcase-media img,
.showcase-media video {
  display: block;
  width: 100%;
  height: auto;
}

.showcase-meta {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  margin-top: 12px;
}

.showcase-author {
  font-family: 'neue-haas-grotesk-display', sans-serif;
  font-size: 14px;
  font-weight: 450;
  line-height: 1.1;
  color: #000;
}

.showcase-use-wrap {
  position: absolute;
  inset: 0;
  display: block;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.18s ease;
}

.showcase-card:hover .showcase-use-wrap,
.showcase-card:focus-within .showcase-use-wrap {
  opacity: 1;
  pointer-events: auto;
}

.showcase-resize-handle {
  position: absolute;
  width: 18px;
  height: 18px;
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.18);
  opacity: 0;
  pointer-events: none;
  transform: scale(0.82);
  transition: opacity 0.18s ease, transform 0.18s ease, background 0.18s ease;
  z-index: 3;
}

.showcase-resize-handle-top-left,
.showcase-resize-handle-bottom-left {
  left: -10px;
}

.showcase-resize-handle-top-right,
.showcase-resize-handle-bottom-right {
  right: -10px;
}

.showcase-resize-handle-top-left,
.showcase-resize-handle-bottom-right {
  cursor: nwse-resize;
}

.showcase-resize-handle-top-right,
.showcase-resize-handle-bottom-left {
  cursor: nesw-resize;
}

.showcase-card:hover .showcase-resize-handle,
.showcase-card:focus-within .showcase-resize-handle,
.showcase-card.resizing .showcase-resize-handle {
  opacity: 1;
  pointer-events: auto;
  transform: scale(1);
}

.showcase-resize-handle:hover {
  background: #fff;
}

.showcase-use-btn {
  position: absolute;
  right: 30px;
  bottom: 30px;
  width: 100px;
  height: 100px;
  border: none;
  border-radius: 50%;
  background: rgba(255,255,255,0.92);
  color: #000;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 10px 28px rgba(0,0,0,0.16);
  cursor: pointer;
  transition: transform 0.18s ease, background 0.18s ease, box-shadow 0.18s ease;
}

.showcase-use-btn:hover {
  transform: scale(1.04);
  background: #fff;
  box-shadow: 0 12px 32px rgba(0,0,0,0.2);
}

.showcase-use-btn:active {
  transform: scale(0.98);
}

.showcase-use-tip {
  position: absolute;
  bottom: calc(100% + 10px);
  left: 50%;
  transform: translateX(-50%);
  background: #222;
  color: #fff;
  padding: 4px 10px;
  border-radius: 8px;
  font-size: 10px;
  font-weight: 600;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.15s ease;
}

.showcase-use-btn:hover .showcase-use-tip,
.showcase-use-btn:focus-visible .showcase-use-tip {
  opacity: 1;
}

.onboarding-tooltip {
  position: fixed;
  z-index: 210;
  width: 205px;
  pointer-events: none;
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.32s ease, transform 0.32s ease;
}

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

.onboarding-tooltip-box {
  position: relative;
  background: #000;
  border-radius: 10px;
  box-sizing: border-box;
  padding: 18px;
  color: #fff;
  pointer-events: auto;
}

.onboarding-tooltip-box::after {
  content: '';
  position: absolute;
  width: 0;
  height: 0;
}

.onboarding-tooltip.point-left .onboarding-tooltip-box::after {
  right: -12px;
  top: var(--pointer-offset, 24px);
  border-top: 12px solid transparent;
  border-bottom: 12px solid transparent;
  border-left: 12px solid #000;
}

.onboarding-tooltip.point-right .onboarding-tooltip-box::after {
  left: -12px;
  top: var(--pointer-offset, 24px);
  border-top: 12px solid transparent;
  border-bottom: 12px solid transparent;
  border-right: 12px solid #000;
}

.onboarding-tooltip.point-top .onboarding-tooltip-box::after {
  left: var(--pointer-left, 24px);
  bottom: -12px;
  border-left: 12px solid transparent;
  border-right: 12px solid transparent;
  border-top: 12px solid #000;
}

.onboarding-tooltip.point-bottom .onboarding-tooltip-box::after {
  left: var(--pointer-left, 24px);
  top: -12px;
  border-left: 12px solid transparent;
  border-right: 12px solid transparent;
  border-bottom: 12px solid #000;
}

.onboarding-tooltip-header {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin-bottom: 16px;
}

.onboarding-tooltip-step {
  font-family: 'neue-haas-grotesk-display', sans-serif;
  font-size: 12px;
  font-weight: 450;
  line-height: 1.2;
}

.onboarding-tooltip-prev {
  border: none;
  background: none;
  padding: 0;
  color: rgba(255, 255, 255, 0.58);
  font-family: 'neue-haas-grotesk-display', sans-serif;
  font-size: 22px;
  font-weight: 450;
  line-height: 1.2;
  cursor: pointer;
  width: 16px;
  height: auto;
  display: flex;
  align-items: baseline;
  justify-content: center;
  text-align: center;
  transform: none;
}

.onboarding-tooltip-copy {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 35px;
}

.onboarding-tooltip-text,
.onboarding-tooltip-example {
  margin: 0;
  font-family: 'neue-haas-grotesk-display', sans-serif;
  font-size: 12px;
  font-weight: 450;
  line-height: 1.45;
  color: #fff;
}

.onboarding-tooltip-example {
  color: rgba(255, 255, 255, 0.72);
}

.onboarding-tooltip-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.onboarding-tooltip-next,
.onboarding-tooltip-close {
  border: none;
  background: none;
  padding: 0;
  font-family: 'neue-haas-grotesk-display', sans-serif;
  font-size: 12px;
  font-weight: 450;
  cursor: pointer;
}

.onboarding-tooltip-next {
  height: 36px;
  border-radius: 999px;
  background: #fff;
  color: #000;
}

.onboarding-tooltip-close {
  color: rgba(255, 255, 255, 0.72);
}

.onboarding-tooltip-close:hover {
  color: #fff;
}

.onboarding-beacon {
  position: fixed;
  z-index: 209;
  width: 34px;
  height: 34px;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.25s ease;
}

.onboarding-beacon.is-visible {
  opacity: 1;
}

.onboarding-beacon-pulse,
.onboarding-beacon-core {
  position: absolute;
  inset: 0;
  border-radius: 50%;
}

.onboarding-beacon-pulse {
  background: rgba(255, 109, 45, 0.26);
  animation: beaconPulse 1.6s ease-out infinite;
}

.onboarding-beacon-core {
  inset: 7px;
  background: #ff5f1f;
}

@keyframes beaconPulse {
  0% {
    transform: scale(0.78);
    opacity: 0.82;
  }
  70% {
    transform: scale(1.7);
    opacity: 0;
  }
  100% {
    transform: scale(1.7);
    opacity: 0;
  }
}

@media (max-width: 900px) {
  .showcase-stage {
    min-height: auto;
    display: flex;
    flex-direction: column;
    gap: 44px;
    padding-top: 108px;
  }

  .showcase-card {
    position: static;
    width: calc(100vw - 48px);
    cursor: default;
  }
}

/* Hover state for corner text elements */
#loadVisuBtn:hover,
#aboutCornerText:hover,
#showcaseCornerText:hover,
#closeAbout:hover {
  color: #666 !important;
  transition: color 0.2s;
}

/* Entrance animations for form cards */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* About page links hover effect */
#aboutPage a:hover {
  color: #666 !important;
  transition: color 0.2s;
}

.about-content-shell{
  position:relative;
  padding:37px 35px 35px;
  box-sizing:border-box;
  min-height:100%;
}

.about-scroll-area{
  height:auto;
  overflow:visible;
  padding-bottom:35px;
  padding-right:0;
  box-sizing:border-box;
  scrollbar-width:none;
  -ms-overflow-style:none;
}

.about-scroll-area::-webkit-scrollbar{
  display:none;
}

.about-description-block{
  margin-top:240px;
}

.about-accordion{
  margin-top:32px;
  display:flex;
  flex-direction:column;
}

.about-accordion-item{
  border-top:1px solid rgba(0,0,0,0.8);
}

.about-accordion-item:last-child{
  border-bottom:1px solid rgba(0,0,0,0.8);
}

.about-accordion-trigger{
  width:100%;
  background:none;
  border:none;
  padding:18px 0 16px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:20px;
  cursor:pointer;
  color:#000;
  font-family:'neue-haas-grotesk-display', sans-serif;
  font-size:21px;
  font-weight:450;
  text-align:left;
}

.about-accordion-trigger:hover{
  color:#444;
}

.about-accordion-icon{
  flex:0 0 auto;
  font-size:28px;
  line-height:1;
  font-weight:450;
}

.about-accordion-panel{
  max-height:0;
  overflow:hidden;
  opacity:0;
  transition:max-height .28s cubic-bezier(.23,1,.32,1), opacity .2s ease;
}

.about-accordion-item.is-open .about-accordion-panel{
  opacity:1;
}

.about-accordion-copy{
  padding:2px 0 24px;
  font-family:'neue-haas-grotesk-display', sans-serif;
  font-size:21px;
  font-weight:450;
  line-height:1.1;
  color:#000;
}

.about-accordion-copy a{
  color:#000;
  text-decoration:underline;
}

.about-accordion-copy p + p{
  margin-top:16px;
}
