
/* Minimal MVP styling: mobile-first modal stepper */
body.slp-modal-open { overflow: hidden; }

.slp-lensflow .slp-open{
  width: 100%;
  padding: 14px 16px;
  border-radius: 4px;        /* REQUIRED */
  border: 1px solid #111;
  background: #111;
  color: #fff;
  font-weight: 800;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: .02em;
  cursor: pointer;
}

.slp-modal[hidden]{ display:none !important; }
.slp-modal{ position: fixed; inset: 0; z-index: 2147483647; }
.slp-modal__backdrop{ position: absolute; inset: 0; background: rgba(0,0,0,0.45); }
.slp-modal__panel{
  position: absolute;
  left: 0; right: 0; bottom: 0;
  max-height: 92vh;
  background: #fff;
  border-top-left-radius: 20px;
  border-top-right-radius: 20px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: 0 -14px 46px rgba(0,0,0,0.18);

}


/* ===== High-end configurator top header (black bar) ===== */
.slp-modal__topbar{
  background: #111;
  color: #fff;
  padding: 14px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.slp-modal__topbar-title{
  font-weight: 800;
  font-size: 14px;
  letter-spacing: .02em;
  text-transform: uppercase;
}

.slp-modal__topbar-close{
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: #111;
  color: #fff;
  border: 1px solid rgba(255,255,255,0.35);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.slp-modal__topbar-close span{
  font-size: 22px;
  line-height: 1;
}

/* Progress bar sits under the topbar and is centered */
.slp-modal__progress{
  background: #fff;
  padding: 10px 16px 12px;
  display: flex;
  justify-content: center;
  border-bottom: 1px solid #eee;
}



@media (max-width: 979px){
  .slp-modal__panel{
    inset: 0;
    width: 100vw;
    height: 100vh;
    height: 100dvh;
    max-height: 100vh;
    max-height: 100dvh;
    border-radius: 0;
    box-shadow: none;
  }
}


@media (min-width: 980px){
  .slp-modal__panel{
    inset: auto;

    left: 50%;
    right: auto;
    top: 50%;
    transform: translate(-50%, -50%);
    width: min(900px, 94vw);
    border-radius: 20px;
    bottom: auto;
    height: 80vh;
    max-height: 80vh; /* 80% viewport height */
  
    box-shadow: 0 18px 60px rgba(0,0,0,0.22);
  }
}


.slp-header, .slp-modal__head{
  padding: calc(14px + env(safe-area-inset-top)) 16px 14px;
  position: sticky;
  top: 0;
  z-index: 3;
  display:flex;
  align-items:center;
  justify-content: space-between;
  border-bottom: 1px solid #eee;
}


/* Premium header layout (Shopify x Uber Eats feel) */
.slp-modal__head{
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 12px;
  align-items: center;
  background: #fff;
}
.slp-modal__head .slp-progress{
  justify-self: center;
  width: 100%;
  display: flex;
  justify-content: center;
}
.slp-modal__head .slp-progress__row{
  max-width: 100%;
}

.slp-title, .slp-modal__title{ font-weight: 800; font-size: 16px; }
.slp-close, .slp-x{
  border: 0;
  background: #111;
  color: #fff;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  line-height: 1;
  cursor: pointer;
}
.slp-close:focus, .slp-x:focus{ outline: 2px solid rgba(17,17,17,0.25); outline-offset: 2px; }
.slp-close:hover, .slp-x:hover{ filter: brightness(1.06); }


.slp-body, .slp-steps{
  padding: 14px 16px;
  overflow: auto;
  flex: 1;
}


/* Ensure step container fills panel and scrolls nicely */
.slp-steps{
  flex: 1;
  overflow: auto;
  -webkit-overflow-scrolling: touch;
}

.slp-step{ display:none; }
.slp-step--active{ display:block; }
.slp-step--ghost{ display:none !important; }
.slp-step__title{ font-weight: 800; font-size: 15px; margin-bottom: 10px; }

.slp-choice-row{ display:flex; gap: 10px; }
.slp-choice{
  flex: 1;
  padding: 12px 12px;
  border-radius: 14px;
  border: 1px solid #ddd;
  background: #fff;
  font-weight: 700;
  cursor: pointer;
}
.slp-choice--active{
  border-color: #111;
  background: #111;
  color: #fff;
}

.slp-choice-col{ display:flex; flex-direction: column; gap: 10px; }

.slp-choicecard{
  border: 1px solid #eee;
  border-radius: 16px;
  padding: 12px;
  background: #fff;
  cursor: pointer;
  display:flex;
  justify-content: space-between;
  align-items: center;
  text-align: left;
}
.slp-choicecard .t{ font-weight: 800; font-size: 14px; }
.slp-choicecard .p{ font-weight: 900; font-size: 13px; color:#111; }
.slp-choicecard.is-selected{ border-color:#111; }

.slp-note{ margin-top: 10px; font-size: 13px; }
.slp-note--muted{ color: #666; }

.slp-hero{
  display:flex;
  gap: 12px;
  border: 1px solid #eee;
  border-radius: 16px;
  padding: 10px;
  align-items:center;
  margin-bottom: 12px;
}
.slp-hero__img{
  width: 76px; height: 76px;
  border-radius: 14px;
  object-fit: contain;
  background: #f6f6f6;
}
.slp-hero__name{ font-weight: 800; font-size: 14px; margin-bottom: 6px; }
.slp-hero__price{ font-weight: 800; }

/* Step 1: make the main product image large + centered so frame color is clearly visible */
.slp-step[data-step="1"] .slp-hero{
  flex-direction: column;
  align-items: center;
  text-align: center;
}
.slp-step[data-step="1"] .slp-hero__img{
  width: min(520px, 100%);
  height: auto;
  max-height: 360px;
  border-radius: 18px;
  object-fit: contain;
}
.slp-step[data-step="1"] .slp-hero__meta{
  width: 100%;
  text-align: center;
}
@media (max-width: 520px){
  .slp-step[data-step="1"] .slp-hero__img{
    max-height: 240px;
  }
}

.slp-vargrid{ display:grid; grid-template-columns: 1fr; gap: 10px; }
@media(min-width: 520px){
  .slp-vargrid{ grid-template-columns: 1fr 1fr; }
}
.slp-varcard{
  display:flex;
  gap: 10px;
  border: 1px solid #eee;
  border-radius: 16px;
  padding: 10px;
  background: #fff;
  cursor:pointer;
  text-align:left;
}
.slp-varcard:hover{ border-color:#ddd; }
.slp-varcard.is-selected{ border-color:#111; }
.slp-varcard.is-disabled{ opacity: 0.5; cursor:not-allowed; }

.slp-varcard__img img{
  width: 64px; height: 64px;
  border-radius: 12px;
  object-fit: contain;
  background: #f6f6f6;
}
.slp-varcard__ph{
  width: 64px; height: 64px;
  border-radius: 12px;
  background: #f6f6f6;
}
.slp-varcard__attrs{ font-weight: 800; font-size: 13px; margin-bottom: 4px; }
.slp-varcard__price{ font-size: 13px; color: #222; }
.slp-varcard__stock{ font-size: 12px; color: #a00; margin-top: 4px; }

.slp-upload{
  border: 1px solid #eee;
  border-radius: 16px;
  padding: 12px;
}
.slp-file{ width: 100%; }
.slp-upload__help{ font-size: 12px; color:#666; margin-top: 6px; }
.slp-upload__list{ margin-top: 10px; display:flex; flex-direction: column; gap: 8px; }
.slp-upload__row{ display:flex; justify-content: space-between; gap: 10px; font-size: 13px; }
.slp-upload__row em{ color:#666; font-style: normal; }

.slp-upload__remove{
  border: 0;
  background: transparent;
  color: #111;
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
  padding: 0 6px;
}
.slp-upload__remove:hover{ opacity: .7; }

.slp-sign{
  border: 1px solid #eee;
  border-radius: 16px;
  padding: 12px;
}
.slp-sign__pad{
  border: 1px solid #ddd;
  border-radius: 14px;
  overflow:hidden;
  background:#fff;
}
.slp-sign__canvas{
  width: 100%;
  height: 200px;
  display:block;
  touch-action: none;
  background:#fff;
}
.slp-sign__actions{
  margin-top: 10px;
  display:flex;
  justify-content: space-between;
  align-items:center;
}
.slp-sign__clear{
  border: 1px solid #111;
  background:#fff;
  border-radius: 12px;
  padding: 8px 10px;
  font-weight: 800;
  cursor:pointer;
}
.slp-sign__status{ font-size: 12px; color:#111; font-weight: 900; }

.slp-review__box{
  border: 1px solid #eee;
  border-radius: 16px;
  padding: 12px;
  display:flex;
  flex-direction: column;
  gap: 8px;
}
.slp-review__row{
  display:flex;
  justify-content: space-between;
  gap: 10px;
  font-size: 13px;
}
.slp-review__row strong{ font-weight: 900; }

.slp-review__row--total{ border-top: 1px solid #eee; padding-top: 12px; margin-top: 8px; }
.slp-review__row--total strong{ font-size: 16px; }

.slp-footer{
  border-top: 1px solid #eee;
  padding: 12px 16px;
  display:flex;
  align-items:center;
  justify-content: space-between;
  gap: 10px;
}
.slp-subtotal-label{ font-size: 12px; color:#666; }
.slp-subtotal{ font-weight: 900; }

.slp-footer__right{ display:flex; gap: 10px; }
.slp-back, .slp-next, .slp-add{
  padding: 10px 12px;
  border-radius: 14px;
  border: 1px solid #111;
  background: #fff;
  font-weight: 800;
  cursor:pointer;
}
.slp-next, .slp-add{
  background: #111;
  color: #fff;
}
.slp-back[disabled]{ opacity: 0.4; cursor:not-allowed; }


/* Launcher block (0000000two style): Product name, Color only, From price, button */
.slp-lensflow .slp-launcher{
  margin: 0 0 12px;
}

.slp-lensflow .slp-launcher__name{
  font-family: "Utopia Regular", "Utopia", serif !important;
  font-weight: 200 !important;
  font-size: clamp(22px, 5.2vw, 34px);
  line-height: 1.08;
  margin-bottom: 10px;
  letter-spacing: -.02em;
  text-transform: uppercase;
  color: #000;
}

.slp-lensflow .slp-launcher--multi .slp-launcher__name{
  font-size: clamp(20px, 3.5vw, 28px);
}

.slp-lensflow .slp-launcher__row{
  display:flex;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid #eee;
}

.slp-lensflow .slp-launcher__k{
  color:#111;
  font-weight: 600;
}

.slp-lensflow .slp-launcher__v{
  color:#111;
  font-weight: 800;
}


/* Launcher color list (clickable, comma-separated) */
.slp-lensflow .slp-color-list{
  display:inline;
  text-align:right;
}
.slp-lensflow .slp-color-option{
  background:none;
  border:0;
  padding:0;
  margin:0;
  font: inherit;
  color:#111;
  font-weight:700;
  cursor:pointer;
  text-decoration:none;
}
.slp-lensflow .slp-color-option:not(:last-child)::after{
  content: ", ";
  color:#111;
  font-weight:600;
}
.slp-lensflow .slp-color-option.is-active{
  text-decoration: underline;
  text-underline-offset: 3px;

  font-weight: 900;
  color:#111;
}

.slp-lensflow .slp-launcher__colors--multi .slp-color-option{
  font-size: 14px;
  font-weight: 800;
}


/* clickable color list (pulled from variations) */
.slp-lensflow .slp-launcher__row--colors .slp-launcher__v{
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
}

.slp-lensflow .slp-colorpick{
  appearance:none;
  border:none;
  background:transparent;
  padding:0;
  margin:0;
  cursor:pointer;
  font-weight: 700;
  font-size: 13px;
  color:#6b6b6b;
  text-transform: uppercase;
  letter-spacing: .02em;
}


.slp-lensflow .slp-colorpick.is-active{
  text-decoration: underline;
  text-underline-offset: 3px;
  font-weight: 900;
  color:#111;
}

.slp-lensflow .slp-colorsep{
  color: #111;
  font-weight: 600;
}



/* Progress bar (LensFlow modal) */
.slp-lensflow .slp-progress{
  margin-top: 10px;
}
.slp-lensflow .slp-progress__row{
  display:flex;
  align-items:center;
  gap: 8px;
  flex-wrap: nowrap;
  overflow-x: auto;
  padding-bottom: 4px;
}
.slp-lensflow .slp-progress__step{
  display:flex;
  align-items:center;
  gap: 6px;
  white-space: nowrap;
  font-size: 12px;
  color:#666;
  font-weight: 700;
}
.slp-lensflow .slp-progress__dot{
  width: 10px;
  height: 10px;
  border-radius: 999px;
  border: 2px solid #bbb;
  background: #fff;
  flex: 0 0 auto;
}
.slp-lensflow .slp-progress__line{
  height: 2px;
  width: 18px;
  background: #ddd;
  border-radius: 999px;
  flex: 0 0 auto;
}
.slp-lensflow .slp-progress__step.is-done{ color:#111; }
.slp-lensflow .slp-progress__step.is-done .slp-progress__dot{ border-color:#111; background:#111; }
.slp-lensflow .slp-progress__step.is-active{ color:#111; }
.slp-lensflow .slp-progress__step.is-active .slp-progress__dot{ border-color:#111; background:#fff; }


/* LensFlow primary buttons (white text => black background) */
.slp-lensflow .slp-open,
.slp-lensflow .slp-next,
.slp-lensflow .slp-add{
  background:#111 !important;
  color:#fff !important;
  border-color:#111 !important;
}


/* === Desktop polish + visibility fixes (v0.20.11.2) === */
.slp-header, .slp-modal__head{ background:#fff; }
.slp-close, .slp-x{
  color:#fff !important;
  background:#111 !important;
  opacity: 1 !important;
  width: 44px;
  height: 44px;
  border-radius: 10px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
}

/* If a theme forces white button text globally, reset within configurator */
.slp-modal__panel button,
.slp-modal__panel a{
  color:#111;
}
.slp-next, .slp-add, .slp-choice--active{
  color:#fff !important;
}

/* Variation (color) cards: images should not be cropped */
.slp-varcard__img img{
  object-fit: contain;
  background: #f6f6f6;
}
.slp-hero__img{
  object-fit: contain;
  background: #f6f6f6;
}

/* Make selected color text clearly visible in launcher list */
.slp-colorpick.is-active{
  font-weight: 900;
  text-decoration: underline;
}


/* === Mobile progress arrow indicator (small screens) === */
@media (max-width: 640px){
  .slp-lensflow .slp-progress__row{
    position: relative;
    padding-right: 44px; /* space for arrow */
  }
  .slp-lensflow .slp-progress__row::after{
    content: '›';
    position: absolute;
    right: 0;
    top: 0;
    bottom: 0;
    width: 40px;
    display:flex;
    align-items:center;
    justify-content:center;
    font-size: 24px;
    font-weight: 900;
    color:#111;
    background: linear-gradient(to right, rgba(255,255,255,0), #fff 60%);
    pointer-events: none;
  }
  .slp-lensflow .slp-progress__step{
    font-size: 11px;
  }
}


/* Signature subheading inside Prescription step */
.slp-step__subtitle{
  margin-top: 16px;
  font-weight: 800;
  font-size: 14px;
  letter-spacing: .2px;
}

/* Theme-proof button text colors inside configurator */
.slp-modal__panel button,
.slp-modal__panel a{
  color:#111 !important;
}
.slp-choice{ color:#111 !important; }
.slp-choice--active{ color:#fff !important; }
.slp-next, .slp-add{ background:#111; border-color:#111; color:#fff !important; }
.slp-back{ background:#fff; color:#111 !important; }

@media (max-width: 640px){
  .slp-modal__head .slp-progress{
    position: relative;
    padding-right: 24px;
  }
  .slp-modal__head .slp-progress::after{
    content: '›';
    position: absolute;
    right: 4px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 22px;
    font-weight: 900;
    color: #111;
    opacity: .55;
    pointer-events: none;
  }
  .slp-modal__head .slp-progress__row{
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    padding-right: 18px;
    scrollbar-width: none;
  }
  .slp-modal__head .slp-progress__row::-webkit-scrollbar{ display:none; }
}


@media (min-width: 980px){
  .slp-modal__topbar{
    border-top-left-radius: 20px;
    border-top-right-radius: 20px;
  }
}