/* Aquamare UI system 2.3 · Single source of visual hierarchy.
   Loaded AFTER legacy simulator.css. All rules are scoped to .ampv. */
.ampv.ampv {
  --aq-blue: #2F63F6;
  --aq-blue-hover: #214EDF;
  --aq-blue-mid: #4C8DFF;
  --aq-blue-mid-hover: #3678E8;
  --aq-blue-soft: #A9D0FF;
  --aq-blue-pale: #EEF6FF;
  --aq-navy: #143A7B;
  --aq-muted: #5C6B82;
  --aq-border: #D9E5F4;
  --aq-mint: #BFE8D2;
  --aq-mint-ink: #145D47;
  --aq-coral: #F6B8A8;
  --aq-danger: #A93748;
  --aq-danger-bg: #FFF1F0;
  --aq-shadow: 0 7px 24px rgba(28,67,136,.065);
  --ampv-ink: var(--aq-navy);
  --ampv-muted: var(--aq-muted);
  --ampv-primary: var(--aq-blue);
  --ampv-primary-hover: var(--aq-blue-hover);
  --ampv-line: var(--aq-border);
  color:var(--aq-navy);
}
.ampv .ampv-head {
  background:linear-gradient(112deg,#EEF6FF 0%,#F7FAFF 58%,#EAF5FF 100%);
  border:1px solid #CDDFF5;
  box-shadow:var(--aq-shadow);
  padding:21px 25px;
  border-radius:18px;
}
.ampv .ampv-eyebrow {color:var(--aq-navy);font-size:10px;letter-spacing:.095em;font-weight:850;margin-bottom:11px}
.ampv .ampv-brand-mark {background:var(--aq-blue);border-radius:9px;}
.ampv .ampv-head h2 {color:var(--aq-navy);font-size:clamp(23px,2.5vw,32px);font-weight:820;letter-spacing:-.025em;margin-bottom:7px}
.ampv .ampv-head p {color:var(--aq-muted);font-size:13px;line-height:1.55}
.ampv .ampv-hero-content {display:flex;align-items:center;justify-content:space-between;gap:22px;flex-wrap:nowrap}
.ampv .ampv-hero-main {flex:1 1 auto;min-width:0}
.ampv .ampv-hero-right {display:flex;flex:0 0 auto;flex-direction:row;align-items:center;justify-content:flex-end;width:auto;max-width:100%}
.ampv .ampv-benefits {color:#365F99;margin-top:15px;gap:6px 19px;font-weight:720;font-size:11px}
/* Identical WhatsApp buttons in both positions: one label, one semantic level. */
.ampv .ampv-wa-top,.ampv .ampv-wa-final-button {
  display:inline-flex;align-items:center;justify-content:center;gap:10px;
  background:var(--aq-mint)!important;border:1px solid #9BD4BB!important;
  color:var(--aq-mint-ink)!important;border-radius:12px!important;
  padding:12px 18px!important;min-height:48px;font-size:13px!important;
  font-weight:800!important;white-space:nowrap;text-align:center;
  box-shadow:0 4px 12px rgba(34,115,87,.07);
  line-height:1.25;text-decoration:none!important;
}
.ampv .ampv-wa-top:hover,.ampv .ampv-wa-final-button:hover {background:#ACE0C6!important;border-color:#77C6A5!important;color:#104A39!important;transform:translateY(-1px)}
.ampv .ampv-wa-top svg,.ampv .ampv-wa-final-button svg {width:20px;height:20px}
/* Panels / text hierarchy */
.ampv .ampv-panel {border:1px solid var(--aq-border);border-radius:17px;padding:21px 23px;box-shadow:var(--aq-shadow);background:#fff}
.ampv .ampv-grid {column-gap:17px;row-gap:17px}
.ampv .ampv-section-head {gap:12px;margin-bottom:16px}
.ampv .ampv-section-head h3,.ampv .ampv-preview-top h3 {font-size:18px!important;font-weight:820!important;line-height:1.3!important;color:var(--aq-navy)!important;letter-spacing:-.02em!important}
.ampv .ampv-section-head p,.ampv .ampv-ai-feature-head p {color:var(--aq-muted);font-size:12.5px;line-height:1.55}
.ampv .ampv-step-number {background:#E3EEFF;color:var(--aq-blue);border:1px solid #CFE1FB;font-weight:850;border-radius:11px}
.ampv .ampv-step-number-finish {background:var(--aq-blue);border-color:var(--aq-blue);color:#fff}
.ampv .ampv-subsection-title,.ampv .ampv-field>span {font-size:12px;font-weight:780;color:var(--aq-navy)}
.ampv .ampv-help,.ampv .ampv-disclaimer,.ampv .ampv-zoom-hint {color:var(--aq-muted);font-size:11.5px;line-height:1.55}
.ampv .ampv-upload {border-color:#A9C8FA;background:#F3F8FF;min-height:145px;border-radius:13px}
.ampv .ampv-upload-icon {background:var(--aq-blue)}
.ampv .ampv-upload strong {color:var(--aq-navy)}
.ampv .ampv-upload input[type="file"]::file-selector-button {background:var(--aq-blue);border-color:var(--aq-blue);color:#fff}
.ampv .ampv-metrics,.ampv .ampv-surfaces-panel {background:#F8FBFF;border:1px solid var(--aq-border);border-radius:12px}
.ampv .ampv-field input[type="number"],.ampv select.ampv-quick-type {border-color:#B9CFEF!important;color:var(--aq-navy)!important;background:#fff!important}
.ampv .ampv-field input[type="number"]:focus,.ampv select.ampv-quick-type:focus {border-color:var(--aq-blue)!important;box-shadow:0 0 0 3px rgba(47,99,246,.13)!important}
.ampv .ampv-instruction {background:#EEF6FF;border:1px solid #D2E4FF;border-radius:11px}
.ampv .ampv-instruction p {color:#355780}
.ampv .ampv-instruction strong {color:var(--aq-navy)}
.ampv .ampv-instruction-icon {background:#DCEBFF;color:var(--aq-blue)}
.ampv .ampv-preview-kicker,.ampv .ampv-ai-feature-kicker,.ampv .ampv-type-popover-step {color:var(--aq-blue);letter-spacing:.1em;font-size:10px;font-weight:850}
.ampv .ampv-label,.ampv .ampv-area-count {background:#DFEDFF;color:var(--aq-navy)}
.ampv .ampv-canvas-wrap {border-color:#BFD7FC;background:#EDF5FF}
.ampv .ampv-status-box {border:1px solid #CBDFFF;background:#EAF4FF;border-radius:11px}
.ampv .ampv-status,.ampv .ampv-pending-label {color:var(--aq-navy)}
.ampv .ampv-status-dot {background:var(--aq-blue);box-shadow:0 0 0 4px #CCE2FF}
.ampv .ampv-water-option {border-color:#C7DCFB;background:#F0F7FF;color:var(--aq-navy)}
.ampv .ampv-water-option input {accent-color:var(--aq-blue)}
.ampv .ampv-zoom-toolbar {border-color:var(--aq-border);background:#F7FAFF}
.ampv .ampv-zoom-toolbar button:not(:disabled) {background:#EAF3FF!important;border-color:#BCD8FD!important;color:var(--aq-navy)!important}
.ampv .ampv-zoom-toolbar button:not(:disabled):hover {background:#DCEBFF!important;border-color:var(--aq-blue)!important}
.ampv .ampv-zoom-toolbar .ampv-zoom-display {color:var(--aq-navy)}
.ampv .ampv-surfaces-panel {margin-bottom:12px}
.ampv button.ampv-surface-item {background:#fff!important;border:1px solid #C9DDF8!important;color:var(--aq-navy)!important;min-height:45px}
.ampv button.ampv-surface-item.is-selected {background:#E8F1FF!important;border-color:var(--aq-blue)!important;color:var(--aq-navy)!important;box-shadow:inset 0 0 0 1px #83B5FF!important}
.ampv button.ampv-surface-item.is-selected .ampv-surface-indicator {background:var(--aq-blue)!important;color:white!important}
.ampv .ampv-surface-pencil {background:#DFECFF;color:var(--aq-navy);border-color:#B8D3FA}
.ampv .ampv-magnetic-row {border:1px solid #BCD7F9;background:#EFF6FF;border-radius:11px;padding:12px}
.ampv .ampv-magnetic-copy strong {color:var(--aq-navy);font-size:12.5px}
.ampv .ampv-magnetic-copy span {color:#516C91;font-size:11.5px}
/* Canonical button hierarchy: primary | secondary | tertiary | auxiliary | destructive. */
.ampv button.ampv-btn,.ampv a.ampv-btn {
  appearance:none!important;border-radius:10px!important;min-height:43px;
  font-family:inherit!important;font-size:12.5px!important;font-weight:800!important;
  line-height:1.3!important;text-transform:none!important;box-shadow:none!important;
  transition:background .15s,border-color .15s,transform .15s!important;
}
.ampv button.ampv-btn.ampv-primary:not(:disabled),.ampv button.ampv-render:not(:disabled),.ampv button.ampv-confirm-type:not(:disabled) {
  background:var(--aq-blue)!important;border:1px solid var(--aq-blue)!important;color:#fff!important;
}
.ampv button.ampv-btn.ampv-primary:not(:disabled):hover,.ampv button.ampv-render:not(:disabled):hover {
  background:var(--aq-blue-hover)!important;border-color:var(--aq-blue-hover)!important;color:#fff!important;
}
.ampv button.ampv-btn.ampv-secondary:not(:disabled),.ampv .ampv-ai-actions button.ampv-copy-prompt:not(:disabled),.ampv .ampv-actions-bottom button.ampv-download:not(:disabled) {
  background:var(--aq-blue-mid)!important;border:1px solid var(--aq-blue-mid)!important;color:#fff!important;
}
.ampv button.ampv-btn.ampv-secondary:not(:disabled):hover,.ampv .ampv-ai-actions button.ampv-copy-prompt:not(:disabled):hover,.ampv .ampv-actions-bottom button.ampv-download:not(:disabled):hover {
  background:var(--aq-blue-mid-hover)!important;border-color:var(--aq-blue-mid-hover)!important;color:#fff!important;
}
.ampv button.ampv-btn.ampv-tertiary:not(:disabled),.ampv button.ampv-change-type:not(:disabled) {
  background:var(--aq-blue-soft)!important;border:1px solid #8EBBF6!important;color:var(--aq-navy)!important;
}
.ampv button.ampv-btn.ampv-tertiary:not(:disabled):hover,.ampv button.ampv-change-type:not(:disabled):hover {
  background:#92C2FF!important;color:var(--aq-navy)!important;
}
.ampv button.ampv-btn.ampv-soft:not(:disabled),.ampv .ampv-ai-actions a.ampv-btn,.ampv button.ampv-magnetic-toggle:not(.is-active):not(:disabled) {
  background:var(--aq-blue-pale)!important;border:1px solid #BBD8FF!important;color:var(--aq-navy)!important;
}
.ampv button.ampv-btn.ampv-soft:not(:disabled):hover,.ampv .ampv-ai-actions a.ampv-btn:hover,.ampv button.ampv-magnetic-toggle:not(.is-active):not(:disabled):hover {
  background:#DEEDFF!important;border-color:#8DB8F7!important;color:var(--aq-navy)!important;
}
.ampv button.ampv-magnetic-toggle.is-active:not(:disabled) {background:var(--aq-blue)!important;border:1px solid var(--aq-blue)!important;color:white!important}
.ampv button.ampv-btn.ampv-danger:not(:disabled),.ampv button.ampv-reset:not(:disabled),.ampv .ampv-surface-trash:not(:disabled) {
  background:var(--aq-danger-bg)!important;border:1px solid #E7B3AE!important;color:var(--aq-danger)!important;
}
.ampv button.ampv-btn.ampv-danger:not(:disabled):hover,.ampv button.ampv-reset:not(:disabled):hover,.ampv .ampv-surface-trash:not(:disabled):hover {
  background:#FFE0D9!important;border-color:#D98A8F!important;color:#912334!important;
}
.ampv button.ampv-btn:disabled,.ampv .ampv-pending-controls button:disabled {background:#E9EDF3!important;border-color:#D9E1EB!important;color:#8490A3!important;opacity:1!important;cursor:not-allowed!important}
/* Contextual edit controls need strong active-state contrast. */
.ampv .ampv-drawing-tools:not([hidden]) {border:2px solid #6198FE;background:linear-gradient(110deg,#E4EFFF,#F3F8FF);box-shadow:0 5px 18px rgba(47,99,246,.13);padding:13px;border-radius:12px}
.ampv .ampv-edit-tools:not([hidden]) {border:2px solid #6198FE;background:linear-gradient(110deg,#DFEDFF,#F1F8FF);box-shadow:0 5px 18px rgba(47,99,246,.12);padding:13px;border-radius:12px}
.ampv .ampv-edit-tools .ampv-point-info {color:var(--aq-navy);font-size:13px;font-weight:760}
.ampv .ampv-pending-label {font-size:12.5px;font-weight:800}
.ampv .ampv-pending-controls button:not(:disabled) {background:#fff!important;border:1px solid #BDD4EF!important;color:var(--aq-navy)!important;border-radius:9px!important;min-height:38px}
.ampv .ampv-pending-controls .ampv-pending-delete:not(:disabled) {background:var(--aq-danger-bg)!important;border-color:#E6ACAF!important;color:var(--aq-danger)!important}
.ampv .ampv-pending-controls .ampv-pending-cancel:not(:disabled) {background:#E7F2FF!important;border-color:#B5D5F7!important;color:var(--aq-navy)!important}
.ampv .ampv-type-popover {border:2px solid #82B0FC;border-radius:15px;box-shadow:0 15px 40px rgba(32,79,160,.2)}
.ampv .ampv-type-popover h3 {color:var(--aq-navy)}
.ampv.is-drawing .ampv-mark-card,.ampv.is-editing .ampv-mark-card {border-color:#83B1FF;box-shadow:0 5px 22px rgba(47,99,246,.13)}
/* IA card: premium gradient ONLY in the header, white body, subtle mint/coral highlights. */
.ampv .ampv-ai-card {padding:0!important;border:1.5px solid #7CAFFE!important;background:#fff!important;box-shadow:0 12px 29px rgba(47,99,246,.11)!important;overflow:hidden}
.ampv .ampv-ai-feature-head {
  position:relative;isolation:isolate;margin:0!important;padding:22px 23px 23px;
  align-items:center;overflow:hidden;gap:13px;
  background:linear-gradient(113deg,#3A4EFB 0%,#3173FD 48%,#33A4FA 100%);
}
.ampv .ampv-ai-feature-head::after {content:"";position:absolute;z-index:-1;width:165px;height:165px;right:-34px;top:-71px;border-radius:50%;background:radial-gradient(circle,rgba(255,255,255,.21) 0%,rgba(255,255,255,0) 72%)}
.ampv .ampv-ai-feature-icon {background:rgba(255,255,255,.18);border:1px solid rgba(255,255,255,.4);color:#fff;box-shadow:none;border-radius:13px}
.ampv .ampv-ai-feature-head h3 {font-size:19px!important;line-height:1.24!important;color:#fff!important;margin:3px 0 6px!important;font-weight:820!important}
.ampv .ampv-ai-feature-head .ampv-ai-feature-kicker {color:#DCFFEB;font-size:10px;letter-spacing:.12em}
.ampv .ampv-ai-feature-head p {color:#F0F7FF!important;font-size:12px}
.ampv .ampv-ai-card .ampv-ai-content {padding:18px 22px 19px;display:flex;flex-direction:column;flex:1}
.ampv .ampv-ai-content[hidden]{display:none!important}
.ampv .ampv-ai-locked {margin:18px 22px!important;background:#EFF6FF;border:1px dashed #A7C9FF;color:var(--aq-navy)}
.ampv .ampv-ai-steps {border:1px solid #D3E4F9;background:#F4F9FF;color:#294E7A;padding:13px 14px 13px 33px!important;margin:0 0 14px!important;border-radius:12px}
.ampv .ampv-ai-steps li {font-size:12px;line-height:1.6;color:#375F8E}
.ampv .ampv-ai-steps li::marker {color:var(--aq-blue);font-weight:800}
.ampv .ampv-ai-prompt-details {background:#F7FAFF;border-color:#CBDDF8;margin:0 0 13px;border-radius:10px}
.ampv .ampv-ai-prompt-details summary {color:var(--aq-navy);font-weight:760}
.ampv .ampv-ai-note {color:var(--aq-muted);font-size:11px!important;margin-bottom:0}
.ampv .ampv-ai-actions {margin-top:auto!important;padding-top:2px;gap:9px}
.ampv .ampv-ai-actions a.ampv-btn {border-radius:10px!important;display:flex;text-decoration:none!important}
/* Step 04 and AI cards must be equal heights on desktop. */
.ampv .ampv-generate-card,.ampv .ampv-ai-card {height:100%}
.ampv .ampv-generate-card .ampv-actions-bottom {margin-top:auto;padding-top:14px}
/* Closing CTA uses same palette and same label as top CTA. */
.ampv .ampv-wa-final {background:linear-gradient(111deg,#2949E8 0%,#2F63F6 49%,#33A4FA 100%);border-color:#7FA9F5;border-radius:18px;box-shadow:0 14px 35px rgba(47,99,246,.15);padding:26px 30px}
.ampv .ampv-wa-final-copy h3 {color:white!important;font-size:21px!important}
.ampv .ampv-wa-final-copy p {color:#F0F7FF!important;font-size:12.5px}
.ampv .ampv-wa-kicker {color:#CDFFE6}
.ampv .ampv-wa-final-button {min-width:250px;font-size:13px!important}
.ampv .ampv-footer {color:#68809D}
/* Focus accessibility, consistent throughout. */
.ampv button:focus-visible,.ampv a:focus-visible,.ampv select:focus-visible,.ampv input:focus-visible,.ampv summary:focus-visible {outline:3px solid #3A86FF!important;outline-offset:3px}
/* Responsive: single aligned WhatsApp at right on desktop; full width below headline on phones. */
@container (max-width:780px){
  .ampv .ampv-hero-content {flex-wrap:wrap;gap:15px}
  .ampv .ampv-hero-right {flex:1 1 100%;width:100%;justify-content:flex-start}
  .ampv .ampv-wa-top {width:100%;white-space:normal}
  .ampv .ampv-wa-final {flex-direction:column;align-items:stretch;gap:15px;padding:23px}
  .ampv .ampv-wa-final-button {width:100%;min-width:0}
}
@container (max-width:540px){
  .ampv .ampv-head {padding:18px 16px}
  .ampv .ampv-hero-right {width:100%;flex:1 1 100%;flex-wrap:nowrap;justify-content:stretch}
  .ampv .ampv-wa-top {width:100%;flex:1 1 auto;min-height:46px;white-space:normal}
  .ampv .ampv-panel {padding:16px}
  .ampv .ampv-section-head h3,.ampv .ampv-preview-top h3 {font-size:17px!important}
  .ampv .ampv-ai-card {padding:0!important}
  .ampv .ampv-ai-feature-head {padding:19px 17px}
  .ampv .ampv-ai-card .ampv-ai-content {padding:17px}
  .ampv .ampv-ai-feature-head h3 {font-size:17px!important}
  .ampv .ampv-ai-locked {margin:17px!important}
  .ampv .ampv-wa-final {padding:20px 17px}
  .ampv .ampv-wa-final-button {white-space:normal}
}
@supports not (container-type:inline-size){
  @media(max-width:820px){.ampv .ampv-hero-content{flex-wrap:wrap}.ampv .ampv-hero-right{width:100%;flex:1 1 100%}.ampv .ampv-wa-top{width:100%}}
  @media(max-width:570px){.ampv .ampv-head{padding:17px}.ampv .ampv-panel{padding:16px}.ampv .ampv-ai-card{padding:0!important}.ampv .ampv-ai-card .ampv-ai-content{padding:17px}}
}
/* Mint/coral micro-accents: reserved for the AI feature, not competing buttons. */
.ampv .ampv-ai-feature-icon {position:relative}
.ampv .ampv-ai-feature-icon::after {content:"";position:absolute;right:-3px;bottom:-3px;width:9px;height:9px;border-radius:50%;background:var(--aq-coral);border:2px solid #4C8DFF}

/* v2.4 overrides */
.ampv.ampv {
  --aq-wa: #25D366;
  --aq-wa-hover: #1ebe5d;
  --aq-wa-border: #1cab55;
}
.ampv .ampv-wa-top,.ampv .ampv-wa-final-button {
  background: var(--aq-wa) !important;
  border-color: var(--aq-wa-border) !important;
  color: #fff !important;
  box-shadow: 0 8px 22px rgba(37,211,102,.18);
}
.ampv .ampv-wa-top:hover,.ampv .ampv-wa-final-button:hover {
  background: var(--aq-wa-hover) !important;
  border-color: var(--aq-wa-border) !important;
  color: #fff !important;
}
.ampv .ampv-wa-top img,.ampv .ampv-wa-final-button img {
  width: 20px; height: 20px; object-fit: contain; display:block;
  filter: brightness(0) invert(1);
}
.ampv .ampv-stepper {
  display:flex; gap:10px; flex-wrap:wrap; margin-top:18px;
  position:sticky; top:10px; z-index:4;
  padding:10px; border-radius:14px; border:1px solid #d6e5fb;
  background:rgba(255,255,255,.86); backdrop-filter: blur(8px);
  box-shadow:0 8px 24px rgba(19,58,123,.08);
}
.ampv .ampv-step-nav {
  appearance:none; border:1px solid #d5e4fb; background:#fff; color:var(--aq-navy);
  min-height:44px; padding:10px 12px; border-radius:12px; display:inline-flex;
  align-items:center; gap:9px; font:inherit; cursor:pointer; transition:.15s ease;
}
.ampv .ampv-step-nav span {
  width:24px; height:24px; border-radius:999px; display:inline-flex; align-items:center; justify-content:center;
  background:#e6f0ff; color:var(--aq-blue); font-size:12px; font-weight:800;
}
.ampv .ampv-step-nav strong {font-size:12.5px; font-weight:780; white-space:nowrap;}
.ampv .ampv-step-nav:hover {border-color:#a8c7fa; background:#f6faff;}
.ampv .ampv-step-nav.is-active {
  background:linear-gradient(110deg,#2F63F6,#4496ff); border-color:#2F63F6; color:#fff;
  box-shadow:0 8px 20px rgba(47,99,246,.18);
}
.ampv .ampv-step-nav.is-active span {background:rgba(255,255,255,.18); color:#fff;}
.ampv .ampv-context-toolbar {display:flex; flex-direction:column; gap:10px; margin:14px 0 11px;}
.ampv .ampv-drawing-tools:not([hidden]),
.ampv .ampv-edit-tools:not([hidden]) {
  display:flex; gap:10px; flex-wrap:wrap; align-items:center; justify-content:flex-start;
}
.ampv .ampv-drawing-tools .ampv-close {margin-left:auto; min-width:210px;}
.ampv .ampv-edit-tools .ampv-finish-edit-alt {margin-left:auto; min-width:190px;}
.ampv .ampv-pending-controls {display:flex; flex-wrap:wrap; align-items:center; gap:10px; flex:1 1 auto;}
.ampv .ampv-pending-controls .ampv-pending-cancel:not(:disabled) {
  background:#fff3f2 !important; border-color:#e2a9a5 !important; color:#a93748 !important;
}
.ampv .ampv-pending-controls .ampv-pending-delete:not(:disabled) {
  background:#ffe9e7 !important; border-color:#dd9ca0 !important; color:#a93748 !important;
}
.ampv .ampv-edit-tools .ampv-delete-area:not(:disabled) {
  background:#e8f4ff !important; border-color:#bad6ff !important; color:#143A7B !important;
}
.ampv .ampv-edit-tools .ampv-delete-point:not(:disabled) {
  background:#fff1f0 !important; border-color:#e0a9a6 !important; color:#a93748 !important;
}
.ampv .ampv-wa-final {
  position: sticky; bottom: 10px; z-index: 3;
}
@container (max-width: 900px){
  .ampv .ampv-stepper {top:6px; padding:8px; gap:8px;}
  .ampv .ampv-step-nav {flex:1 1 calc(50% - 8px); justify-content:flex-start;}
}
@container (max-width: 620px){
  .ampv .ampv-step-nav {flex:1 1 100%;}
  .ampv .ampv-drawing-tools .ampv-close,
  .ampv .ampv-edit-tools .ampv-finish-edit-alt {margin-left:0; width:100%; min-width:0;}
  .ampv .ampv-wa-final {position:static;}
}
@supports not (container-type:inline-size){
  @media(max-width:900px){
    .ampv .ampv-step-nav{flex:1 1 calc(50% - 8px)}
  }
  @media(max-width:620px){
    .ampv .ampv-step-nav{flex:1 1 100%}
    .ampv .ampv-drawing-tools .ampv-close,.ampv .ampv-edit-tools .ampv-finish-edit-alt{margin-left:0;width:100%;min-width:0}
    .ampv .ampv-wa-final{position:static}
  }
}

/* v2.5 - five-screen wizard. Only the currently selected step is displayed. */
.ampv.ampv .ampv-wizard {display:flex;flex-direction:column;gap:16px;min-width:0;margin:16px 0 18px;}
.ampv.ampv .ampv-wizard-screen {min-width:0;width:100%;}
.ampv.ampv .ampv-wizard-screen[hidden],
.ampv.ampv .ampv-wizard-screen:not(.is-current) {display:none!important;}
.ampv.ampv .ampv-wizard-screen.is-current {
 display:flex;flex-direction:column;gap:16px;
 animation:ampv-step-enter .23s cubic-bezier(.16,.7,.3,1) both;
}
@keyframes ampv-step-enter {from{opacity:.55;transform:translateX(16px)}to{opacity:1;transform:translateX(0)}}
@media(prefers-reduced-motion:reduce){.ampv.ampv .ampv-wizard-screen.is-current{animation:none}}
.ampv.ampv .ampv-wizard-screen .ampv-panel {width:100%;max-width:100%;height:auto;min-width:0;}
.ampv.ampv .ampv-wizard-screen .ampv-preview {position:relative;top:auto;}
.ampv.ampv .ampv-wizard-screen .ampv-preview-slot {width:100%;min-width:0;display:block;}
.ampv.ampv .ampv-wizard-screen .ampv-preview-slot:empty {display:none;}
.ampv.ampv .ampv-stepper {
 display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:8px;
 margin-top:18px;padding:9px;border:1px solid #D5E4FB;border-radius:15px;
 background:#fff;box-shadow:0 7px 25px rgba(47,99,246,.06);
 position:relative;top:auto;z-index:1;
}
.ampv.ampv .ampv-step-nav {
 width:100%;min-width:0;min-height:52px;flex-direction:column;align-items:center;justify-content:center;
 gap:4px;padding:8px 4px;line-height:1.25;background:#F4F8FF;border:1px solid #D8E6F7;
 text-align:center;border-radius:11px;
}
.ampv.ampv .ampv-step-nav span {width:25px;height:25px;flex:0 0 auto;}
.ampv.ampv .ampv-step-nav strong {font-size:11px;line-height:1.25;white-space:normal;text-wrap:balance;}
.ampv.ampv .ampv-step-nav.is-completed {background:#E7F2FF;border-color:#BDDBFF;}
.ampv.ampv .ampv-step-nav:disabled {cursor:not-allowed;opacity:.63;}
.ampv.ampv .ampv-step-nav.is-active:disabled {opacity:1;}
.ampv.ampv .ampv-wizard-bottom {
 display:flex;align-items:center;justify-content:space-between;gap:12px;
 background:#F3F8FF;border:1px solid #D1E2FA;border-radius:13px;padding:13px 15px;
}
.ampv.ampv .ampv-wizard-bottom button {min-width:130px;}
.ampv.ampv .ampv-wizard-bottom button[hidden] {display:none!important;}
.ampv.ampv .ampv-wizard-feedback {flex:1;min-width:0;margin:0;color:#426487;font-size:12px;line-height:1.5;}
.ampv.ampv .ampv-wizard-bottom .ampv-wizard-next {margin-left:auto;}
.ampv.ampv .ampv-upload-card,.ampv.ampv .ampv-measure-card {
 max-width:840px;min-height:270px;margin-inline:auto;
}
.ampv.ampv .ampv-mark-card {margin:0;display:grid;grid-template-columns: minmax(0,1fr) minmax(265px,.8fr);gap:16px;}
.ampv.ampv .ampv-preview-slot .ampv-canvas-wrap {max-height:min(66vh,740px);min-height:330px;}
.ampv.ampv .ampv-generate-card {max-width:100%;}
.ampv.ampv .ampv-generate-card .ampv-actions-bottom {margin-top:12px;}
.ampv.ampv .ampv-ai-card {max-width:100%;}
.ampv.ampv .ampv-wa-final {position:sticky;bottom:8px;z-index:5;padding:13px 19px;gap:12px;box-shadow:0 12px 28px rgba(38,80,170,.13);}
.ampv.ampv .ampv-wa-final-copy h3 {font-size:16px!important;line-height:1.3;}
.ampv.ampv .ampv-wa-final-copy p {font-size:11px;line-height:1.5;}
.ampv.ampv .ampv-wa-final-button {min-height:43px;}
@container (max-width:780px){
 .ampv.ampv .ampv-stepper {grid-template-columns:repeat(5,minmax(0,1fr));gap:5px;padding:6px;}
 .ampv.ampv .ampv-step-nav {min-width:0;flex-direction:column;min-height:56px;padding:6px 2px;}
 .ampv.ampv .ampv-step-nav strong {font-size:10px;}
 .ampv.ampv .ampv-mark-card {grid-template-columns:1fr;}
 .ampv.ampv .ampv-wizard-screen .ampv-preview-slot .ampv-canvas-wrap {min-height:235px;max-height:55vh;}
 .ampv.ampv .ampv-wa-final {position:sticky;bottom:4px;z-index:5;display:flex;flex-direction:row;align-items:center;gap:8px;padding:10px 11px;}
 .ampv.ampv .ampv-wa-final-copy {flex:1;min-width:0;}
 .ampv.ampv .ampv-wa-final-copy h3 {font-size:12px!important;}
 .ampv.ampv .ampv-wa-final-copy p,.ampv.ampv .ampv-wa-kicker {display:none;}
 .ampv.ampv .ampv-wa-final-button {width:auto;min-width:0;flex:0 0 auto;white-space:normal;padding:9px 10px!important;font-size:11px!important;}
 .ampv.ampv .ampv-wizard-bottom {padding:10px;flex-wrap:wrap;}
 .ampv.ampv .ampv-wizard-feedback {flex:1 1 100%;order:3;}
}
@container (max-width:420px){
 .ampv.ampv .ampv-step-nav strong {font-size:9px;}
 .ampv.ampv .ampv-step-nav span {width:23px;height:23px;}
 .ampv.ampv .ampv-wa-final-copy h3 {font-size:11px!important;}
 .ampv.ampv .ampv-wa-final-button {font-size:10.5px!important;}
}

/* Reserve toolbar height across idle/drawing/editing so the image never shifts mid-pointer. */
.ampv.ampv .ampv-context-toolbar {
  height:154px!important;min-height:154px!important;max-height:154px!important;
  position:relative;justify-content:center;margin:12px 0 10px;overflow:visible;
}
.ampv.ampv .ampv-context-idle {
  height:100%;display:flex;align-items:center;justify-content:center;text-align:center;
  padding:16px;color:#315d92;font-size:13px;border:1px dashed #B5D4FC;
  background:#F3F9FF;border-radius:12px;
}
.ampv.ampv.is-drawing .ampv-context-idle,
.ampv.ampv.is-editing .ampv-context-idle {display:none!important;}
.ampv.ampv .ampv-context-toolbar .ampv-drawing-tools:not([hidden]),
.ampv.ampv .ampv-context-toolbar .ampv-edit-tools:not([hidden]) {
  width:100%;height:100%;align-content:center;overflow-y:auto;
}
.ampv.ampv .ampv-wizard-bottom {display:grid!important;grid-template-columns:auto minmax(0,1fr) auto;min-height:75px;}
.ampv.ampv .ampv-wizard-bottom .ampv-wizard-prev,
.ampv.ampv .ampv-wizard-bottom .ampv-wizard-next {width:auto!important;min-width:140px!important;max-width:100%;flex:0 0 auto;white-space:nowrap;}
.ampv.ampv .ampv-wizard-bottom .ampv-wizard-prev[hidden] {display:none!important;}
.ampv.ampv .ampv-wizard-bottom .ampv-wizard-feedback {
  width:auto!important;min-width:0!important;max-width:100%;flex:auto;
  display:block;overflow-wrap:break-word;word-break:normal;line-height:1.45;
}
@container (max-width:620px){
 .ampv.ampv .ampv-context-toolbar {height:240px!important;min-height:240px!important;max-height:240px!important;}
 .ampv.ampv .ampv-wizard-bottom {grid-template-columns:1fr 1fr;gap:8px;}
 .ampv.ampv .ampv-wizard-bottom .ampv-wizard-feedback {grid-column:1 / -1;grid-row:2;}
 .ampv.ampv .ampv-wizard-bottom .ampv-wizard-next {grid-column:2;}
}
@supports not (container-type:inline-size){
 @media(max-width:620px){
  .ampv.ampv .ampv-context-toolbar {height:240px!important;min-height:240px!important;max-height:240px!important;}
  .ampv.ampv .ampv-wizard-bottom {grid-template-columns:1fr 1fr;gap:8px;}
  .ampv.ampv .ampv-wizard-bottom .ampv-wizard-feedback {grid-column:1 / -1;grid-row:2;}
 }
}
/* Strong active-state specificity so current step stays blue, even after disabled-state updates. */
.ampv.ampv .ampv-step-nav.is-active,
.ampv.ampv .ampv-step-nav.is-active:not(:disabled) {
  background:linear-gradient(110deg,#2F63F6,#4C8DFF)!important;
  color:#fff!important;border-color:#2F63F6!important;
  opacity:1!important;box-shadow:0 6px 18px rgba(47,99,246,.18);
}
.ampv.ampv .ampv-step-nav.is-active span {background:rgba(255,255,255,.22)!important;color:#fff!important;}
.ampv.ampv .ampv-step-nav.is-active strong {color:#fff!important;}
@container (max-width:620px){
  .ampv.ampv .ampv-context-toolbar {height:196px!important;min-height:196px!important;max-height:196px!important;}
}
@supports not (container-type:inline-size){@media(max-width:620px){
  .ampv.ampv .ampv-context-toolbar {height:196px!important;min-height:196px!important;max-height:196px!important;}
}}

/* Step 4 is read-only: photograph/result visible, drawing tools hidden. */
.ampv.ampv.is-wizard-generate .ampv-context-toolbar,
.ampv.ampv.is-wizard-generate .ampv-zoom-hint {display:none!important;}
.ampv.ampv.is-wizard-generate .ampv-canvas {cursor:default!important;touch-action:pan-x pan-y;}

/* V2.6: single step 3, compact preview toolbar and download reminder. */
.ampv.ampv .ampv-stepper {display:grid!important;grid-template-columns:repeat(4,minmax(0,1fr))!important;gap:10px}
.ampv.ampv .ampv-step-nav {width:100%!important;min-width:0!important;justify-content:center!important}
.ampv.ampv .ampv-step-nav strong {overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.ampv.ampv .ampv-preview-top {display:flex!important;gap:16px!important;align-items:center!important;justify-content:space-between!important;flex-wrap:wrap!important;margin-bottom:10px}
.ampv.ampv .ampv-preview-heading {flex:1 1 260px;min-width:0}
.ampv.ampv .ampv-preview-tip {font-size:12px!important;line-height:1.4;color:#44638b!important;margin:6px 0 0!important;max-width:550px}
.ampv.ampv .ampv-preview-options {display:flex!important;flex:0 1 auto!important;flex-wrap:wrap!important;align-items:center!important;justify-content:flex-end!important;gap:8px!important}
.ampv.ampv .ampv-preview-options .ampv-zoom-toolbar {display:flex!important;justify-content:flex-end!important;align-items:center!important;gap:8px!important;margin:0!important;padding:5px 7px!important;min-width:0!important;background:#f5f9ff!important}
.ampv.ampv .ampv-preview-options .ampv-zoom-set {display:flex!important;align-items:center!important;gap:5px!important}
.ampv.ampv .ampv-context-toolbar {margin:8px 0 9px!important;min-height:0!important}
.ampv.ampv .ampv-zoom-hint {font-size:11px!important;margin:0 0 10px!important}
.ampv.ampv .ampv-surfaces-title {display:flex;gap:10px;align-items:center;justify-content:space-between;flex-wrap:wrap;margin-bottom:10px}
.ampv.ampv .ampv-surfaces-title .ampv-subsection-title{margin:0!important}
.ampv.ampv button.ampv-new-area:not(:disabled){background:#DCEBFF!important;color:#143A7B!important;border:1px solid #B8D3FB!important;min-width:138px}
.ampv.ampv button.ampv-new-area:not(:disabled):hover{background:#bddaff!important}
.ampv.ampv .ampv-generate-card {display:grid!important;grid-template-columns:minmax(0,1fr) minmax(280px,.9fr);gap:20px;align-items:center;padding:20px 23px!important;margin:14px 0 0;min-height:0!important;position:relative}
.ampv.ampv .ampv-generate-copy{align-self:center;min-width:0}
.ampv.ampv .ampv-generate-copy .ampv-section-head{margin:0!important}
.ampv.ampv .ampv-generate-controls{display:flex;flex-direction:column;gap:9px;min-width:0}
.ampv.ampv .ampv-generate-controls .ampv-render{width:100%;min-height:43px!important}
.ampv.ampv .ampv-generate-controls .ampv-actions-bottom {display:flex;gap:9px;align-items:stretch;margin:0!important;padding:0!important}
.ampv.ampv .ampv-generate-controls .ampv-actions-bottom button{min-width:0;flex:1;white-space:normal}
.ampv.ampv .ampv-ai-download-modal[hidden] {display:none!important}
.ampv.ampv .ampv-ai-download-modal{position:fixed;inset:0;display:flex;align-items:center;justify-content:center;background:rgba(11,29,59,.64);z-index:100000;padding:16px;backdrop-filter:blur(3px)}
.ampv.ampv .ampv-ai-download-dialog{position:relative;width:min(100%,430px);padding:32px 26px 25px;background:white;border:1px solid #b7d2ff;border-radius:19px;box-shadow:0 20px 70px rgba(0,0,0,.27);display:flex;flex-direction:column;align-items:stretch;gap:10px}
.ampv.ampv .ampv-ai-download-dialog h3{color:#143A7B!important;margin:4px 0 0;font-size:20px!important;line-height:1.25!important}
.ampv.ampv .ampv-ai-download-dialog p{font-size:13px;line-height:1.6;color:#536884;margin:0 0 9px}
.ampv.ampv .ampv-ai-modal-icon{width:40px;height:40px;display:grid;place-items:center;background:#e4efff;border-radius:12px;color:#2f63f6;font-size:24px;font-weight:800}
.ampv.ampv .ampv-ai-modal-close{position:absolute;top:10px;right:12px;background:transparent!important;border:none!important;color:#536884!important;font-size:25px!important;padding:4px 10px;cursor:pointer}
.ampv.ampv .ampv-ai-download-dialog .ampv-ai-modal-download{min-height:47px}
.ampv.ampv .ampv-ai-download-dialog .ampv-ai-modal-dismiss{min-height:39px}
@container (max-width:780px){
 .ampv.ampv .ampv-stepper{grid-template-columns:repeat(2,minmax(0,1fr))!important}
 .ampv.ampv .ampv-generate-card{grid-template-columns:1fr;padding:18px!important;gap:15px}
 .ampv.ampv .ampv-preview-options{flex:1 1 100%!important;justify-content:flex-start!important}
 .ampv.ampv .ampv-preview-options .ampv-zoom-toolbar{flex:1 1 auto!important;justify-content:space-between!important}
}
@container (max-width:520px){
 .ampv.ampv .ampv-step-nav{padding:9px 5px!important;justify-content:center!important}
 .ampv.ampv .ampv-step-nav strong{font-size:11px!important}
 .ampv.ampv .ampv-preview-options .ampv-zoom-toolbar{flex-wrap:wrap!important}
 .ampv.ampv .ampv-generate-controls .ampv-actions-bottom{flex-wrap:wrap}
 .ampv.ampv .ampv-generate-controls .ampv-actions-bottom button{flex:1 1 120px}
}
@supports not (container-type:inline-size){
 @media(max-width:820px){.ampv.ampv .ampv-stepper{grid-template-columns:repeat(2,minmax(0,1fr))!important}.ampv.ampv .ampv-generate-card{grid-template-columns:1fr;gap:15px}.ampv.ampv .ampv-preview-options{justify-content:flex-start!important}}
}
/* Toolbar occupies the SAME small height in idle/drawing/editing, avoiding pointer jumps. */
.ampv.ampv .ampv-context-toolbar {height:105px!important;min-height:105px!important;max-height:105px!important;margin:8px 0 8px!important;display:flex!important;justify-content:center!important}
.ampv.ampv .ampv-context-idle {height:auto!important;min-height:34px!important;max-height:40px!important;align-self:flex-start!important;padding:8px 12px!important;background:#f4f9ff!important;border:1px solid #d3e5ff!important;text-align:left!important;justify-content:flex-start!important;font-size:12px!important}
.ampv.ampv .ampv-context-toolbar .ampv-drawing-tools:not([hidden]),
.ampv.ampv .ampv-context-toolbar .ampv-edit-tools:not([hidden]) {height:100%;padding:8px!important;overflow-y:auto;align-content:center}
@container (max-width:620px){.ampv.ampv .ampv-context-toolbar{height:166px!important;min-height:166px!important;max-height:166px!important}}
@supports not (container-type:inline-size){@media(max-width:620px){.ampv.ampv .ampv-context-toolbar{height:166px!important;min-height:166px!important;max-height:166px!important}}}
/* Contain the drawing controls within the preview; never allow negative horizontal overflow. */
.ampv.ampv .ampv-context-toolbar .ampv-drawing-tools:not([hidden]){
  display:flex!important;flex-direction:column!important;align-items:stretch!important;
  justify-content:center!important;max-width:100%!important;min-width:0!important;
}
.ampv.ampv .ampv-context-toolbar .ampv-pending-controls:not([hidden]){
  display:flex!important;flex-direction:row!important;flex-wrap:wrap!important;gap:7px!important;
  min-width:0!important;width:100%!important;max-width:100%!important;flex:0 0 auto!important;
  align-items:center!important;justify-content:flex-start!important;
}
.ampv.ampv .ampv-context-toolbar .ampv-close{width:100%!important;min-width:0!important;max-width:100%!important;flex:0 0 auto!important;margin:0!important;}
.ampv.ampv .ampv-context-toolbar .ampv-edit-tools:not([hidden]){max-width:100%;min-width:0;justify-content:flex-start;}
.ampv.ampv .ampv-context-toolbar .ampv-edit-tools .ampv-finish-edit-alt{margin-left:auto}
/* Mobile: CTA is still present at the bottom of every wizard screen, but
   must NOT overlay action links or intercept touches. */
@container (max-width:780px){.ampv.ampv .ampv-wa-final{position:static!important;bottom:auto!important;z-index:1!important}}
@supports not (container-type:inline-size){@media(max-width:820px){.ampv.ampv .ampv-wa-final{position:static!important;bottom:auto!important;z-index:1!important}}}
/* The viewport can be narrower than the layout viewport in mobile browsers.
   Keep the modal X inside the visible area rather than at the far-right edge. */
@media (max-width:700px){
 .ampv.ampv .ampv-ai-download-modal{justify-content:flex-start!important;padding:10px!important}
 .ampv.ampv .ampv-ai-download-dialog{width:292px!important;max-width:calc(100% - 12px)!important;padding:29px 17px 20px!important}
 .ampv.ampv .ampv-ai-modal-close{right:9px!important;top:8px!important;z-index:10!important}
}
/* Keep CTA present below the current wizard step without covering pool clicks. */
.ampv.ampv .ampv-wa-final {position:static!important;bottom:auto!important;z-index:1!important}

/* v2.7 · definitive order: directions, visor, edit status, surface list, actions. */
.ampv.ampv .ampv-mark-card {display:block!important;min-width:0!important;padding:17px 21px!important;}
.ampv.ampv .ampv-mark-intro {display:block!important;width:100%!important;max-width:none!important;}
.ampv.ampv .ampv-mark-intro .ampv-section-head {margin:0 0 9px!important;}
.ampv.ampv .ampv-instruction {width:100%!important;max-width:none!important;padding:10px 14px!important;min-height:0!important;}
.ampv.ampv .ampv-instruction p {line-height:1.48!important;margin:0!important;}
.ampv.ampv .ampv-mark-tools {width:100%!important;max-width:none!important;min-width:0!important;margin:0!important;display:grid!important;grid-template-columns:1fr!important;gap:12px!important;padding:15px 20px!important;border:1px solid #d8e7fc;border-radius:15px;background:#fff;}
.ampv.ampv .ampv-surfaces-panel {width:100%!important;min-width:0!important;margin:0!important;padding:13px 15px!important;}
.ampv.ampv .ampv-surfaces-title {flex-wrap:wrap!important;align-items:center!important;}
.ampv.ampv .ampv-surface-list {max-height:none!important;overflow:visible!important;scrollbar-width:auto!important;}
.ampv.ampv .ampv-surface-row {max-width:100%!important;min-width:0!important;}
.ampv.ampv .ampv-magnetic-tools,.ampv.ampv .ampv-magnetic-row{width:100%!important;min-width:0!important;}
.ampv.ampv .ampv-reset {justify-self:end!important;width:auto!important;max-width:100%!important;}
.ampv.ampv .ampv-preview {padding:17px 21px!important;overflow:visible!important;min-width:0!important;}
.ampv.ampv .ampv-preview-top {display:grid!important;grid-template-columns:minmax(220px,1fr) auto!important;align-items:start!important;gap:12px!important;flex-wrap:nowrap!important;margin:0 0 9px!important;}
.ampv.ampv .ampv-preview-heading {min-width:0!important;flex:auto!important;}
.ampv.ampv .ampv-preview-heading h3 {margin:2px 0 0!important;}
.ampv.ampv .ampv-preview-tip {font-size:11.5px!important;max-width:390px!important;margin:4px 0 0!important;line-height:1.4!important;}
.ampv.ampv .ampv-preview-options {display:grid!important;grid-template-columns:1fr auto!important;gap:5px 8px!important;align-items:center!important;justify-items:end!important;justify-content:end!important;flex:auto!important;min-width:0!important;}
.ampv.ampv .ampv-preview-options .ampv-water-option {grid-column:1!important;grid-row:1!important;margin:0!important;}
.ampv.ampv .ampv-preview-options .ampv-label {grid-column:2!important;grid-row:1!important;margin:0!important;}
.ampv.ampv .ampv-preview-options .ampv-zoom-toolbar {
 grid-column:1/-1!important;grid-row:2!important;
 display:flex!important;flex-wrap:wrap!important;justify-content:flex-end!important;gap:5px!important;
 padding:3px 5px!important;margin:0!important;width:auto!important;max-width:100%!important;min-width:0!important;
 background:#f5f9ff!important;border-radius:10px!important;
}
.ampv.ampv .ampv-preview-options .ampv-zoom-set{display:flex!important;align-items:center!important;gap:3px!important;min-width:0!important;}
.ampv.ampv .ampv-preview-options .ampv-zoom-toolbar button{min-height:31px!important;min-width:29px!important;padding:4px 7px!important;font-size:11px!important;}
.ampv.ampv .ampv-preview-options .ampv-zoom-toolbar .ampv-zoom-display{font-size:11px!important;white-space:nowrap!important;}
/* A single fixed-height contextual toolbar prevents the photo jumping on the first click.
   It wraps controls instead of introducing scrolling in either direction. */
.ampv.ampv .ampv-context-toolbar {
 box-sizing:border-box!important;width:100%!important;max-width:100%!important;min-width:0!important;
 height:118px!important;min-height:118px!important;max-height:118px!important;
 padding:0!important;margin:6px 0 7px!important;overflow:visible!important;display:flex!important;
 flex-direction:column!important;align-items:stretch!important;justify-content:center!important;
}
.ampv.ampv .ampv-context-idle{
 width:100%!important;max-width:100%!important;height:auto!important;min-height:0!important;max-height:none!important;
 padding:9px 12px!important;margin:0!important;align-self:center!important;
 font-size:11.5px!important;line-height:1.4!important;text-align:left!important;white-space:normal!important;
}
.ampv.ampv .ampv-context-toolbar .ampv-drawing-tools:not([hidden]),
.ampv.ampv .ampv-context-toolbar .ampv-edit-tools:not([hidden]),
.ampv.ampv .ampv-context-toolbar .ampv-cut-tools:not([hidden]) {
 box-sizing:border-box!important;width:100%!important;min-width:0!important;max-width:100%!important;
 height:auto!important;max-height:100%!important;min-height:0!important;
 display:flex!important;align-content:center!important;align-items:center!important;justify-content:flex-start!important;
 flex-wrap:wrap!important;gap:6px!important;overflow:visible!important;padding:7px!important;margin:0!important;
}
.ampv.ampv .ampv-context-toolbar .ampv-pending-controls:not([hidden]){
 width:auto!important;min-width:0!important;flex:1 1 260px!important;display:flex!important;
 gap:6px!important;align-items:center!important;flex-wrap:wrap!important;justify-content:flex-start!important;
}
.ampv.ampv .ampv-context-toolbar .ampv-close {width:auto!important;min-width:130px!important;flex:1 1 140px!important;max-width:none!important;margin:0!important;}
.ampv.ampv .ampv-context-toolbar .ampv-pending-label {flex:0 1 auto!important;margin-right:5px!important;}
.ampv.ampv .ampv-context-toolbar button {min-height:34px!important;min-width:0!important;padding:7px 9px!important;font-size:11.5px!important;white-space:normal!important;flex-shrink:0!important;}
.ampv.ampv .ampv-context-toolbar .ampv-edit-tools .ampv-finish-edit-alt{min-width:130px!important;margin-left:auto!important;}
.ampv.ampv .ampv-point-info {flex:1 1 100%!important;font-size:11.5px!important;line-height:1.25!important;}
.ampv.ampv .ampv-cut-list:not(:empty) {display:flex;align-items:center;gap:5px;flex-wrap:wrap;width:100%;background:#FFF6F1;padding:6px 10px;border-radius:9px;font-size:11px;color:#763927;}
.ampv.ampv .ampv-cut-remove {font-size:11px!important;color:#a9393d!important;background:#fff!important;border:1px solid #e5b0a7!important;border-radius:7px!important;padding:5px 8px!important;cursor:pointer;}
.ampv.ampv .ampv-cut-title {font-size:12px;color:#143A7B;font-weight:750;flex:1 1 100%;}
.ampv.ampv .ampv-cut-tools:not([hidden]){background:#FFF7F1;border:2px solid #EDA87F;border-radius:11px;}
.ampv.ampv .ampv-zoom-hint {font-size:10.5px!important;padding:0!important;margin:0 0 6px!important;line-height:1.2!important;}
.ampv.ampv .ampv-status-box {margin:9px 0 0!important;}
.ampv.ampv .ampv-disclaimer {margin:10px 0 0!important;}
/* Preview remains zoomable intentionally; toolbars and other panels have no scrollbars. */
@container (max-width:790px){
 .ampv.ampv .ampv-preview-top{grid-template-columns:1fr!important;gap:7px!important;}
 .ampv.ampv .ampv-preview-options{justify-content:start!important;justify-items:start!important;}
 .ampv.ampv .ampv-preview-options .ampv-zoom-toolbar{justify-content:flex-start!important;}
 .ampv.ampv .ampv-context-toolbar{height:182px!important;min-height:182px!important;max-height:182px!important;}
 .ampv.ampv .ampv-context-toolbar .ampv-close{flex:1 1 100%!important;}
 .ampv.ampv .ampv-mark-tools{padding:12px!important;}
}
@container (max-width:500px){
 .ampv.ampv .ampv-context-toolbar{height:230px!important;min-height:230px!important;max-height:230px!important;}
 .ampv.ampv .ampv-context-toolbar button{font-size:10.5px!important;min-height:31px!important;}
 .ampv.ampv .ampv-context-toolbar .ampv-edit-tools .ampv-finish-edit-alt{min-width:110px!important;}
}
@supports not (container-type:inline-size){
 @media(max-width:820px){.ampv.ampv .ampv-preview-top{grid-template-columns:1fr!important;}.ampv.ampv .ampv-context-toolbar{height:182px!important;min-height:182px!important;max-height:182px!important;}}
 @media(max-width:550px){.ampv.ampv .ampv-context-toolbar{height:230px!important;min-height:230px!important;max-height:230px!important;}}
}

/* Final compact toolbar: reserve enough height to avoid first-click displacement,
   without the oversized empty 230px area on phones. */
.ampv.ampv .ampv-context-toolbar {height:98px!important;min-height:98px!important;max-height:98px!important;}
@container (max-width:790px){.ampv.ampv .ampv-context-toolbar {height:134px!important;min-height:134px!important;max-height:134px!important;}}
@container (max-width:500px){.ampv.ampv .ampv-context-toolbar {height:162px!important;min-height:162px!important;max-height:162px!important;}}
@supports not (container-type:inline-size){
 @media(max-width:820px){.ampv.ampv .ampv-context-toolbar {height:134px!important;min-height:134px!important;max-height:134px!important;}}
 @media(max-width:550px){.ampv.ampv .ampv-context-toolbar {height:162px!important;min-height:162px!important;max-height:162px!important;}}
}

/* Fix V2.6 inherited column-wrap: at narrow widths it produced a second
   HORIZONTAL column outside the action bar. Buttons now wrap in rows. */
.ampv.ampv .ampv-context-toolbar .ampv-drawing-tools:not([hidden]) {
  flex-direction:row!important;flex-wrap:wrap!important;align-items:center!important;
  justify-content:flex-start!important;align-content:center!important;
}
@container (max-width:790px){
  .ampv.ampv .ampv-context-toolbar .ampv-pending-controls:not([hidden]) {flex:1 1 100%!important;width:100%!important;min-width:0!important;max-width:100%!important;}
  .ampv.ampv .ampv-context-toolbar .ampv-close {flex:1 1 100%!important;width:100%!important;max-width:100%!important;margin:0!important;}
}
@container (max-width:500px){
  .ampv.ampv .ampv-context-toolbar .ampv-pending-controls button {flex:1 1 calc(50% - 6px)!important;max-width:calc(50% - 3px)!important;}
  .ampv.ampv .ampv-context-toolbar .ampv-pending-label {flex:1 1 100%!important;}
}
@supports not (container-type:inline-size){
 @media(max-width:820px){.ampv.ampv .ampv-context-toolbar .ampv-pending-controls:not([hidden]){flex:1 1 100%!important;width:100%!important}.ampv.ampv .ampv-context-toolbar .ampv-close{width:100%!important;flex:1 1 100%!important}}
 @media(max-width:550px){.ampv.ampv .ampv-context-toolbar .ampv-pending-controls button {flex:1 1 calc(50% - 6px)!important;max-width:calc(50% - 3px)!important;}.ampv.ampv .ampv-context-toolbar .ampv-pending-label{flex:1 1 100%!important;}}
}

/* v2.8 · stable final layout and hierarchy (override accumulated legacy styles) */
.ampv.ampv .ampv-bottom-grid {
 display:grid!important;grid-template-columns:minmax(0,1.12fr) minmax(300px,.88fr)!important;
 align-items:start;gap:16px;margin-top:16px;
}
.ampv.ampv .ampv-bottom-grid > * {min-width:0;max-width:100%;}
.ampv.ampv .ampv-bottom-grid .ampv-mark-tools {
 display:flex!important;flex-direction:column!important;gap:12px!important;
 padding:15px!important;margin:0!important;width:100%!important;min-width:0!important;
 border:1px solid #d8e7fc!important;border-radius:15px!important;
}
.ampv.ampv .ampv-bottom-grid .ampv-generate-card {
 display:flex!important;flex-direction:column!important;align-items:stretch!important;
 gap:14px!important;padding:18px!important;margin:0!important;min-height:0!important;
 width:100%!important;height:auto!important;
}
.ampv.ampv .ampv-bottom-grid .ampv-generate-controls {
 display:flex!important;flex-direction:column!important;gap:9px!important;width:100%!important;
}
.ampv.ampv .ampv-bottom-grid .ampv-generate-controls .ampv-render {
 align-self:flex-start!important;min-width:0!important;width:auto!important;max-width:100%!important;
 padding:11px 20px!important;
}
.ampv.ampv .ampv-bottom-grid .ampv-generate-controls .ampv-actions-bottom {
 display:flex!important;gap:8px!important;flex-wrap:wrap!important;justify-content:flex-start!important;
}
.ampv.ampv .ampv-bottom-grid .ampv-actions-bottom button {flex:0 1 auto!important; min-width:125px!important;width:auto!important;max-width:100%!important;padding:9px 15px!important;}
.ampv.ampv .ampv-upload input[type="file"] {
 display:block!important;width:min(100%,500px)!important;max-width:100%!important;
 margin:14px auto 0!important;text-align:center!important;box-sizing:border-box!important;
}
.ampv.ampv .ampv-confirm-measures {width:auto!important;min-width:190px!important;max-width:100%!important;align-self:flex-start!important;padding:10px 18px!important;}
.ampv.ampv .ampv-ai-actions {display:grid!important;grid-template-columns:repeat(2,minmax(0,max-content))!important;justify-content:start!important;gap:8px!important;}
.ampv.ampv .ampv-ai-actions .ampv-copy-prompt {grid-column:1/-1!important;justify-self:start!important;width:auto!important;max-width:100%!important;padding:10px 18px!important;}
.ampv.ampv .ampv-ai-actions a.ampv-btn {width:auto!important;min-width:145px!important;max-width:100%!important;justify-content:center!important;padding:10px 16px!important;}
/* Context toolbar: three deterministic rows when editing. No fixed height or internal scrollbars. */
.ampv.ampv .ampv-context-toolbar {
 height:auto!important;min-height:118px!important;max-height:none!important;
 display:flex!important;flex-direction:column!important;justify-content:flex-start!important;
 padding:0!important;margin:8px 0!important;overflow:visible!important;
}
.ampv.ampv .ampv-context-idle {
 width:100%!important;max-width:100%!important;min-height:38px!important;
 align-self:flex-start!important;
}
.ampv.ampv .ampv-context-toolbar .ampv-edit-tools:not([hidden]) {
 display:grid!important;grid-template-columns:repeat(4,minmax(0,1fr))!important;
 gap:8px!important;align-items:stretch!important;align-content:start!important;
 width:100%!important;max-height:none!important;height:auto!important;overflow:visible!important;
 padding:10px!important;box-sizing:border-box!important;
}
.ampv.ampv .ampv-context-toolbar .ampv-edit-tools .ampv-point-info {
 grid-column:1/-1!important;min-width:0!important;margin:0!important;
 white-space:normal!important;line-height:1.4!important;
}
.ampv.ampv .ampv-context-toolbar .ampv-edit-tools button {
 display:inline-flex!important;justify-content:center!important;align-items:center!important;
 width:100%!important;min-width:0!important;max-width:none!important;
 margin:0!important;padding:8px 6px!important;box-sizing:border-box!important;
 height:auto!important;min-height:37px!important;
 white-space:normal!important;line-height:1.25!important;
}
.ampv.ampv .ampv-context-toolbar .ampv-edit-tools .ampv-change-type {grid-column:1!important;}
.ampv.ampv .ampv-context-toolbar .ampv-edit-tools .ampv-delete-area {grid-column:2!important;}
.ampv.ampv .ampv-context-toolbar .ampv-edit-tools .ampv-finish-edit-alt {grid-column:3/5!important;}
.ampv.ampv .ampv-context-toolbar .ampv-edit-tools .ampv-cut-list:not(:empty) {grid-column:1/-1!important;max-width:100%!important;}
.ampv.ampv .ampv-context-toolbar .ampv-drawing-tools:not([hidden]),
.ampv.ampv .ampv-context-toolbar .ampv-cut-tools:not([hidden]) {
 height:auto!important;min-height:60px!important;max-height:none!important;overflow:visible!important;
 display:flex!important;align-items:center!important;align-content:start!important;
 flex-wrap:wrap!important;gap:8px!important;
}
.ampv.ampv .ampv-context-toolbar .ampv-pending-controls:not([hidden]) {flex:1 1 430px!important;flex-wrap:wrap!important;}
.ampv.ampv .ampv-context-toolbar .ampv-close{flex:0 1 auto!important;width:auto!important;min-width:125px!important;}
@container (max-width:900px){
 .ampv.ampv .ampv-bottom-grid {grid-template-columns:1fr!important;}
}
@container (max-width:650px){
 .ampv.ampv .ampv-context-toolbar .ampv-edit-tools:not([hidden]) {grid-template-columns:repeat(2,minmax(0,1fr))!important;}
 .ampv.ampv .ampv-context-toolbar .ampv-edit-tools .ampv-change-type {grid-column:1!important;}
 .ampv.ampv .ampv-context-toolbar .ampv-edit-tools .ampv-delete-area {grid-column:2!important;}
 .ampv.ampv .ampv-context-toolbar .ampv-edit-tools .ampv-finish-edit-alt {grid-column:1/-1!important;}
 .ampv.ampv .ampv-ai-actions {grid-template-columns:repeat(2,minmax(0,1fr))!important;}
 .ampv.ampv .ampv-ai-actions a.ampv-btn{min-width:0!important;width:100%!important;}
 .ampv.ampv .ampv-bottom-grid .ampv-generate-controls .ampv-actions-bottom button{min-width:0!important;flex:1 1 120px!important;}
}
@supports not (container-type:inline-size){
 @media(max-width:950px){.ampv.ampv .ampv-bottom-grid{grid-template-columns:1fr!important}}
 @media(max-width:650px){
   .ampv.ampv .ampv-context-toolbar .ampv-edit-tools:not([hidden]){grid-template-columns:repeat(2,minmax(0,1fr))!important}
   .ampv.ampv .ampv-context-toolbar .ampv-edit-tools .ampv-finish-edit-alt{grid-column:1/-1!important}
 }
}
/* Reset legacy grid-area names, which otherwise create implicit off-screen grid tracks. */
.ampv.ampv .ampv-bottom-grid > .ampv-mark-tools,
.ampv.ampv .ampv-bottom-grid > .ampv-generate-card {
 grid-area:auto!important;grid-row:auto!important;grid-column:auto!important;
 justify-self:stretch!important;align-self:start!important;
}
/* A compact idle area; active tools may grow vertically without clipping. */
.ampv.ampv .ampv-context-toolbar {min-height:0!important;height:auto!important;max-height:none!important;}
.ampv.ampv .ampv-context-idle {min-height:35px!important;}
/* Container never introduces page-wide horizontal scroll; the photo zoom
   remains scrollable only inside .ampv-canvas-wrap. */
.ampv.ampv {max-width:100%!important;box-sizing:border-box!important;overflow-x:clip!important;}
.ampv.ampv .ampv-wizard,.ampv.ampv .ampv-wizard-screen {max-width:100%!important;min-width:0!important;}
/* Prevent the decorative circle in the WhatsApp footer from extending
   48px beyond the mobile viewport. */
.ampv.ampv .ampv-wa-final::before {right:0!important;}

/* 2.9 · Closed upload and button hierarchy. */
.ampv.ampv .ampv-upload {position:relative!important;display:flex!important;flex-direction:column!important;align-items:center!important;justify-content:center!important;gap:8px!important;cursor:pointer!important;min-height:180px!important}
.ampv.ampv .ampv-upload-file-row {display:flex!important;flex-direction:column!important;justify-content:center!important;align-items:center!important;gap:6px!important;width:100%!important;margin:6px 0 2px!important;text-align:center!important}
.ampv.ampv .ampv-upload-file-button {display:inline-flex!important;align-items:center!important;justify-content:center!important;padding:11px 18px!important;background:#2F63F6!important;color:white!important;font-weight:800!important;border-radius:10px!important;font-size:13px!important}
.ampv.ampv .ampv-file-selected {display:block!important;min-height:17px!important;color:#526783!important;font-size:12px!important;overflow-wrap:anywhere;max-width:95%!important}
.ampv.ampv .ampv-photo {position:absolute!important;inset:0!important;width:100%!important;height:100%!important;opacity:0!important;cursor:pointer!important;margin:0!important;padding:0!important;overflow:hidden!important;max-width:none!important;z-index:1!important}
.ampv.ampv .ampv-upload:focus-within {outline:3px solid #4289ff;outline-offset:2px}
/* A one-column button followed by two equal half-width buttons: exact alignment. */
.ampv.ampv .ampv-bottom-grid .ampv-generate-controls {width:min(100%,340px)!important;max-width:340px!important;display:grid!important;grid-template-columns:minmax(0,1fr)!important;gap:8px!important;align-self:flex-start!important}
.ampv.ampv .ampv-bottom-grid .ampv-generate-controls .ampv-render {display:block!important;width:100%!important;min-width:0!important;max-width:none!important;justify-self:stretch!important;box-sizing:border-box!important;margin:0!important;min-height:41px!important;padding:9px 10px!important}
.ampv.ampv .ampv-bottom-grid .ampv-generate-controls .ampv-actions-bottom {display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;width:100%!important;gap:8px!important;margin:0!important;justify-content:stretch!important}
.ampv.ampv .ampv-bottom-grid .ampv-generate-controls .ampv-actions-bottom button {width:100%!important;max-width:none!important;min-width:0!important;box-sizing:border-box!important;min-height:39px!important;margin:0!important;flex:none!important;padding:8px 5px!important}
.ampv.ampv .ampv-ai-content .ampv-ai-actions {display:grid!important;grid-template-columns:repeat(2,minmax(0,166px))!important;gap:8px!important;justify-content:start!important;width:100%!important;max-width:100%!important}
.ampv.ampv .ampv-ai-content .ampv-ai-actions button.ampv-copy-prompt {grid-column:1/-1!important;justify-self:stretch!important;width:100%!important;max-width:none!important;min-width:0!important;margin:0!important;box-sizing:border-box!important;padding:9px 10px!important}
.ampv.ampv .ampv-ai-content .ampv-ai-actions a.ampv-btn {justify-self:stretch!important;width:100%!important;max-width:none!important;min-width:0!important;box-sizing:border-box!important;margin:0!important;padding:9px 8px!important}
/* Show the calibration guide only when editing. Layout never overlaps. */
.ampv.ampv .ampv-context-toolbar .ampv-edit-tools .ampv-perspective-toggle {background:#E8E2FF!important;border:1px solid #B1A1FF!important;color:#383181!important}
.ampv.ampv .ampv-context-toolbar .ampv-edit-tools .ampv-perspective-toggle[aria-pressed="true"] {background:#5D4CD5!important;border-color:#5D4CD5!important;color:white!important}
.ampv.ampv .ampv-context-toolbar .ampv-edit-tools .ampv-perspective-reset:not([hidden]) {background:#F6F3FF!important;border-color:#C4B9FF!important;color:#49399E!important}
.ampv.ampv .ampv-context-toolbar .ampv-edit-tools:not([hidden]) {grid-template-columns:repeat(4,minmax(0,1fr))!important;grid-auto-flow:row!important;gap:8px!important;align-content:start!important}
.ampv.ampv .ampv-context-toolbar .ampv-edit-tools .ampv-change-type {grid-column:auto!important}
.ampv.ampv .ampv-context-toolbar .ampv-edit-tools .ampv-delete-area {grid-column:auto!important}
.ampv.ampv .ampv-context-toolbar .ampv-edit-tools .ampv-finish-edit-alt {grid-column:span 2!important}
@container (max-width:640px){
 .ampv.ampv .ampv-context-toolbar .ampv-edit-tools:not([hidden]) {grid-template-columns:repeat(2,minmax(0,1fr))!important}
 .ampv.ampv .ampv-context-toolbar .ampv-edit-tools .ampv-finish-edit-alt {grid-column:1/-1!important}
 .ampv.ampv .ampv-ai-content .ampv-ai-actions {grid-template-columns:repeat(2,minmax(0,1fr))!important}
}
@supports not (container-type:inline-size){
 @media(max-width:640px){
  .ampv.ampv .ampv-context-toolbar .ampv-edit-tools:not([hidden]) {grid-template-columns:repeat(2,minmax(0,1fr))!important}
  .ampv.ampv .ampv-context-toolbar .ampv-edit-tools .ampv-finish-edit-alt {grid-column:1/-1!important}
  .ampv.ampv .ampv-ai-content .ampv-ai-actions {grid-template-columns:repeat(2,minmax(0,1fr))!important}
 }
}
/* Match the specificity of the older native-file rule. Full upload surface is clickable. */
.ampv.ampv .ampv-upload input.ampv-photo {
 position:absolute!important;top:0!important;left:0!important;right:0!important;bottom:0!important;
 width:100%!important;height:100%!important;min-width:0!important;max-width:none!important;
 opacity:0!important;margin:0!important;padding:0!important;z-index:2!important;
 cursor:pointer!important;display:block!important;
}
