/* ==========================================================================
   Viz Inline Result - Redesigned: full-width blurred image with form overlay
   ========================================================================== */
.viz-ir { background: #f8f7f4; padding: 60px 0; }
.viz-ir__inner { max-width: 1100px; margin: 0 auto; padding: 0 20px; }
.viz-ir__header { text-align: center; margin-bottom: 32px; }
.viz-ir__tag {
  display: inline-flex; align-items: center; gap: 6px;
  background: linear-gradient(135deg, #2D5E3F, #3A7D52); color: #fff;
  padding: 6px 16px; border-radius: 20px; font-size: 13px; font-weight: 600;
  margin-bottom: 12px;
}
.viz-ir__title { font-size: 28px; color: #1A1A1A; margin: 0; }

/* ── Layout: stacked with overlay ──────────────────────────────── */
.viz-ir__content {
  display: block;
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 12px 48px rgba(0,0,0,.15);
}

/* ── Image area ────────────────────────────────────────────────── */
.viz-ir__image-area {
  position: relative;
  width: 100%;
  text-align: center;
  z-index: 1;
}
.viz-ir__image-wrap {
  position: relative;
  border-radius: 0;
  overflow: hidden;
  box-shadow: none;
  background: #1a1a1a;
}

/* ── Before / After Slider ─────────────────────────────────────── */
.viz-ir__slider {
  position: relative;
  width: 100%;
  min-height: 400px;
  overflow: hidden;
  cursor: default;
  user-select: none;
  -webkit-user-select: none;
}
.viz-ir__slider-img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: filter .8s ease;
  pointer-events: none;
}
.viz-ir__slider-img--after {
  width: 100%;
  height: auto;
  min-height: 400px;
}
.viz-ir__slider-img--before {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  clip-path: inset(0 50% 0 0);
}
.viz-ir__image--blurred {
  filter: blur(22px) saturate(1.1) brightness(0.7);
}

/* ── Divider line + handle ─────────────────────────────────────── */
.viz-ir__slider-divider {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 3px;
  background: rgba(255, 255, 255, 0.85);
  transform: translateX(-50%);
  z-index: 3;
  pointer-events: none;
}
.viz-ir__slider-handle {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 2px 12px rgba(0, 0, 0, .3);
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}
.viz-ir__slider-handle i {
  font-size: 16px;
  color: #2D5E3F;
}

/* ── Before / After labels ─────────────────────────────────────── */
.viz-ir__slider-label {
  position: absolute;
  top: 16px;
  z-index: 4;
  padding: 4px 12px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  pointer-events: none;
  color: #fff;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}
.viz-ir__slider-label--before { left: 16px; }
.viz-ir__slider-label--after  { right: 16px; }

/* Hide slider controls in locked state */
.viz-ir__slider-divider,
.viz-ir__slider-label {
  opacity: 0;
  transition: opacity .5s ease;
}
.viz-ir__content.--unlocked .viz-ir__slider-divider,
.viz-ir__content.--unlocked .viz-ir__slider-label {
  opacity: 1;
}

/* ── Lock overlay (over the slider) ────────────────────────────── */
.viz-ir__lock-overlay {
  position: absolute;
  inset: 0;
  z-index: 6;
  display: none;
}
.viz-ir__lock-overlay.--visible {
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ── Download button (shown after unlock) ──────────────────────── */
.viz-ir__download {
  display: inline-flex; align-items: center; gap: 8px; margin-top: 16px;
  padding: 10px 24px; background: #2D5E3F; color: #fff; border-radius: 8px;
  font-weight: 600; font-size: 14px; text-decoration: none;
  transition: background .2s;
}
.viz-ir__download:hover { background: #3A7D52; color: #fff; }

/* ── Details panel: overlaid on the image when locked ──────────── */
.viz-ir__details {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 40px 20px;
  z-index: 5;
  transition: opacity .5s ease;
}

/* ── Hide chips/estimate/phone/retry when form is visible (locked state) ─ */
.viz-ir__details > .viz-ir__section,
.viz-ir__details > .viz-ir__phone-btn,
.viz-ir__details > .viz-ir__retry {
  display: none;
}

/* ── Form card: semi-transparent dark glass ────────────────────── */
.viz-ir__form-section {
  background: rgba(0, 0, 0, 0.78);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  padding: 32px 36px;
  border-radius: 16px;
  border: 1px solid rgba(201, 169, 110, 0.25);
  max-width: 400px;
  width: 100%;
  text-align: center;
  box-shadow: 0 8px 40px rgba(0, 0, 0, 0.35);
}
.viz-ir__form-section h4 {
  font-family: 'Playfair Display', serif;
  font-size: 22px;
  color: #C4A265;
  text-transform: none;
  letter-spacing: 0;
  margin: 0 0 6px;
  line-height: 1.3;
}
.viz-ir__form-section h4 i {
  display: none;
}
.viz-ir__form-section > p {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.65);
  margin: 0 0 20px;
  line-height: 1.4;
}

/* ── Form fields ───────────────────────────────────────────────── */
.viz-ir__field { margin-bottom: 10px; }
.viz-ir__field input {
  width: 100%;
  padding: 12px 16px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 10px;
  font-size: 15px;
  font-family: inherit;
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  transition: border-color .2s, box-shadow .2s;
  box-sizing: border-box;
}
.viz-ir__field input::placeholder {
  color: rgba(255, 255, 255, 0.45);
}
.viz-ir__field input:focus {
  border-color: #C4A265;
  box-shadow: 0 0 0 3px rgba(201, 169, 110, 0.2);
  outline: none;
}

/* ── Submit button ─────────────────────────────────────────────── */
.viz-ir__submit {
  width: 100%;
  padding: 14px;
  background: linear-gradient(135deg, #C4A265, #B87333);
  color: #fff;
  border: none;
  border-radius: 10px;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  transition: transform .15s, box-shadow .2s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 4px;
  letter-spacing: .3px;
}
.viz-ir__submit:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(196, 162, 101, 0.4);
}
.viz-ir__submit:disabled { opacity: .5; cursor: not-allowed; transform: none; }

/* ── Form error ────────────────────────────────────────────────── */
.viz-ir__form-error {
  background: rgba(254, 178, 178, 0.15);
  color: #feb2b2;
  padding: 8px 12px;
  border-radius: 8px;
  font-size: 13px;
  margin-bottom: 10px;
  border: 1px solid rgba(254, 178, 178, 0.2);
}

/* ==========================================================================
   UNLOCKED STATE - after form submission
   Form hides, details panel becomes a normal flow under the image
   ========================================================================== */
.viz-ir__content.--unlocked .viz-ir__details {
  position: static;
  padding: 32px 32px;
  background: #fff;
  align-items: center;
  text-align: center;
  gap: 16px;
}
.viz-ir__content.--unlocked .viz-ir__details > .viz-ir__section,
.viz-ir__content.--unlocked .viz-ir__details > .viz-ir__phone-btn,
.viz-ir__content.--unlocked .viz-ir__details > .viz-ir__retry {
  display: flex;
}
.viz-ir__content.--unlocked .viz-ir__details > .viz-ir__section {
  flex-direction: column;
  align-items: center;
}
.viz-ir__content.--unlocked .viz-ir__slider {
  min-height: auto;
}
.viz-ir__content.--unlocked .viz-ir__slider-img--after {
  min-height: auto;
}
.viz-ir__content.--unlocked .viz-ir__slider {
  cursor: col-resize;
}

/* ── Chips, estimate, phone (unlocked state) ───────────────────── */
.viz-ir__section h4 {
  font-size: 14px; text-transform: uppercase; letter-spacing: .5px;
  color: #7A7A7A; margin: 0 0 10px; display: flex; align-items: center;
  justify-content: center; gap: 6px;
}
.viz-ir__chips { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; }
.viz-ir__chip {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 6px 14px; background: #f8f7f4; border: 1px solid #E5E2DC;
  border-radius: 20px; font-size: 13px; color: #1A1A1A; font-weight: 500;
}
.viz-ir__chip i { color: #2D5E3F; font-size: 12px; }
.viz-ir__estimate {
  font-size: 28px; font-weight: 700; color: #2D5E3F;
  letter-spacing: -.5px; line-height: 1.2;
}
.viz-ir__estimate-note { font-size: 12px; color: #7A7A7A; margin: 6px 0 0; text-align: center; }
.viz-ir__phone-btn {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  padding: 14px; background: #2D5E3F; color: #fff; border-radius: 8px;
  font-size: 16px; font-weight: 600; text-decoration: none;
  transition: background .2s; width: 100%;
}
.viz-ir__phone-btn:hover { background: #3A7D52; color: #fff; }
.viz-ir__retry {
  width: 100%; padding: 12px; background: transparent;
  border: 1px solid #E5E2DC; border-radius: 8px; font-size: 14px;
  color: #4A4A4A; cursor: pointer; transition: all .2s;
  display: flex; align-items: center; justify-content: center; gap: 6px;
}
.viz-ir__retry:hover { border-color: #2D5E3F; color: #2D5E3F; }

/* ── Responsive ────────────────────────────────────────────────── */
@media (max-width: 768px) {
  .viz-ir { padding: 40px 0; }
  .viz-ir__title { font-size: 22px; }
  .viz-ir__slider { min-height: 300px; }
  .viz-ir__slider-img--after { min-height: 300px; }
  .viz-ir__form-section { padding: 24px 22px; max-width: 340px; }
  .viz-ir__form-section h4 { font-size: 19px; }
  .viz-ir__details { padding: 24px 16px; }
  .viz-ir__estimate { font-size: 24px; }
  .viz-ir__content.--unlocked .viz-ir__details { padding: 20px; }
}
@media (max-width: 480px) {
  .viz-ir__inner { padding: 0 16px; }
  .viz-ir__slider { min-height: 250px; }
  .viz-ir__slider-img--after { min-height: 250px; }
  .viz-ir__form-section { padding: 20px 18px; max-width: 300px; }
  .viz-ir__form-section h4 { font-size: 17px; }
  .viz-ir__form-section > p { font-size: 12px; margin-bottom: 14px; }
  .viz-ir__field input { padding: 10px 14px; font-size: 14px; }
}