/* =====================================================================
   Offerr Wizard — Public CSS
   Alle selectors beginnen met .offerr- om conflicten te voorkomen
   ===================================================================== */

:root {
  --offerr-red:         #ab4239;
  --offerr-dark:        #40373a;
  --offerr-bg:          #faf9f7;
  --offerr-surface:     #fff;
  --offerr-border:      #e5e2de;
  --offerr-text:        #2a2424;
  --offerr-muted:       #8a8080;
  --offerr-success:     #2d7a4f;
  --offerr-font:        'Roboto Slab', Georgia, serif;
  --offerr-btn-radius:  8px;
  --offerr-card-radius: 12px;
}

/* Override via admin settings — injected as inline style */

#offerr-wizard {
  font-family: var(--offerr-font);
  color: var(--offerr-text);
  background: var(--offerr-bg);
  padding: 32px 20px;
  max-width: 100%;
  box-sizing: border-box;
}

#offerr-wizard * {
  box-sizing: border-box;
}

.offerr-brand {
  font-family: var(--offerr-font);
  font-size: 28px;
  font-weight: 700;
  color: var(--offerr-dark);
  margin-bottom: 28px;
  letter-spacing: -0.5px;
}

/* ------------------------------------------------------------------ */
/*  Steps bar                                                          */
/* ------------------------------------------------------------------ */
.offerr-steps-bar {
  display: flex;
  gap: 6px;
  margin-bottom: 28px;
  background: var(--offerr-surface);
  border: 1px solid var(--offerr-border);
  border-radius: var(--offerr-card-radius);
  padding: 8px;
  max-width: 1100px;
}

.offerr-step-ind {
  flex: 1;
  padding: 9px 6px;
  text-align: center;
  border-radius: 8px;
  background: transparent;
  font-size: 13px;
  font-weight: 500;
  color: var(--offerr-muted);
  transition: all 0.2s;
  cursor: default;
  white-space: nowrap;
}
.offerr-step-ind.active {
  background: var(--offerr-red);
  color: #fff;
}
.offerr-step-ind.done {
  color: var(--offerr-dark);
}

/* ------------------------------------------------------------------ */
/*  Layout                                                             */
/* ------------------------------------------------------------------ */
.offerr-layout {
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
  align-items: flex-start;
  max-width: 1100px;
}
.offerr-main { flex: 1; min-width: 320px; }
.offerr-sidebar {
  width: 300px;
  background: var(--offerr-surface);
  border: 1px solid var(--offerr-border);
  padding: 20px;
  border-radius: var(--offerr-card-radius);
  position: sticky;
  top: 24px;
  height: fit-content;
}

/* ------------------------------------------------------------------ */
/*  Step boxes                                                         */
/* ------------------------------------------------------------------ */
.offerr-step { display: none; }
.offerr-step.active { display: block; }

.offerr-step-box {
  background: var(--offerr-surface);
  border: 1px solid var(--offerr-border);
  padding: 24px;
  border-radius: var(--offerr-card-radius);
  margin-bottom: 16px;
}
.offerr-step-box h2 {
  font-family: var(--offerr-font);
  font-size: 22px;
  margin-bottom: 20px;
  color: var(--offerr-dark);
}

/* ------------------------------------------------------------------ */
/*  Form fields                                                        */
/* ------------------------------------------------------------------ */
.offerr-label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--offerr-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 6px;
  margin-top: 16px;
}
.offerr-label:first-of-type { margin-top: 0; }

#offerr-wizard select,
#offerr-wizard input[type=text],
#offerr-wizard input[type=number],
#offerr-wizard input[type=email],
#offerr-wizard input[type=tel],
#offerr-wizard textarea {
  width: 100%;
  padding: 10px 14px;
  border: 1.5px solid var(--offerr-border);
  border-radius: calc(var(--offerr-btn-radius) * 0.75);
  font-family: var(--offerr-font);
  font-size: 14px;
  color: var(--offerr-text);
  background: var(--offerr-surface);
  outline: none;
  transition: border-color 0.15s;
  appearance: auto;
  -webkit-appearance: auto;
}
#offerr-wizard select:focus,
#offerr-wizard input:focus,
#offerr-wizard textarea:focus {
  border-color: var(--offerr-red);
}
#offerr-wizard textarea { resize: vertical; }

.offerr-error {
  color: var(--offerr-red);
  font-size: 13px;
  margin-top: 4px;
  display: none; /* JS zet display:block of display:none direct */
}
.offerr-error.visible { display: block; } /* backwards compat */

/* ------------------------------------------------------------------ */
/*  Sliders                                                            */
/* ------------------------------------------------------------------ */
.offerr-slider-row { margin-top: 4px; }

#offerr-wizard input[type=range] {
  width: 100%;
  accent-color: var(--offerr-red);
  height: 6px;
  padding: 0;
  border: none;
  background: transparent;
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
}
#offerr-wizard input[type=range]::-webkit-slider-runnable-track {
  height: 6px;
  border-radius: 3px;
  background: #c0b8b4;
}
#offerr-wizard input[type=range]::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--offerr-red);
  margin-top: -7px;
  cursor: pointer;
  box-shadow: 0 1px 4px rgba(0,0,0,0.25);
}
#offerr-wizard input[type=range]::-moz-range-track {
  height: 6px;
  border-radius: 3px;
  background: #c0b8b4;
}
#offerr-wizard input[type=range]::-moz-range-thumb {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--offerr-red);
  border: none;
  cursor: pointer;
  box-shadow: 0 1px 4px rgba(0,0,0,0.25);
}
.offerr-time-label {
  font-size: 15px;
  font-weight: 600;
  color: var(--offerr-dark);
  margin-top: 4px;
}

/* ------------------------------------------------------------------ */
/*  Cards                                                              */
/* ------------------------------------------------------------------ */
.offerr-card-grid { display: flex; flex-direction: column; gap: 12px; }

.offerr-card {
  border: 1.5px solid var(--offerr-border);
  border-radius: var(--offerr-card-radius);
  background: var(--offerr-surface);
  cursor: pointer;
  transition: border-color 0.15s, box-shadow 0.15s;
  overflow: hidden;
}
.offerr-card:hover { border-color: #c9c0bc; box-shadow: 0 2px 8px rgba(0,0,0,0.06); }
.offerr-card.selected { border-color: var(--offerr-dark); box-shadow: 0 0 0 3px rgba(64,55,58,0.08); }

.offerr-card img {
  width: 100%;
  height: 320px;
  object-fit: cover;
  display: block;
}
.offerr-card-body { padding: 14px; }
.offerr-card-body h3 { font-size: 15px; font-weight: 600; margin-bottom: 4px; }
.offerr-card-body h4 { font-size: 14px; font-weight: 600; margin-bottom: 4px; }
.offerr-card-body ul { font-size: 13px; color: var(--offerr-muted); padding-left: 16px; margin-bottom: 6px; }
.offerr-card-body p.offerr-card-desc { font-size: 13px; color: var(--offerr-muted); margin-bottom: 6px; }
.offerr-card-price { font-size: 14px; font-weight: 600; color: var(--offerr-dark); }
.offerr-card-badge {
  display: inline-block;
  font-size: 12px;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 99px;
  background: var(--offerr-dark);
  color: #fff;
  margin-top: 6px;
}
.offerr-card.selected .offerr-card-badge { background: var(--offerr-red); }

/* ------------------------------------------------------------------ */
/*  Buttons                                                            */
/* ------------------------------------------------------------------ */
.offerr-btn {
  background: var(--offerr-dark);
  color: #fff;
  padding: 13px 20px;
  border: none;
  border-radius: var(--offerr-btn-radius);
  cursor: pointer;
  width: 100%;
  font-family: var(--offerr-font);
  font-size: 15px;
  font-weight: 600;
  transition: background 0.15s, transform 0.1s;
  margin-top: 8px;
  display: block;
}
.offerr-btn:hover { background: #2e2628; }
.offerr-btn:active { transform: scale(0.99); }
.offerr-btn-red { background: var(--offerr-red); }
.offerr-btn-red:hover { background: #8f3530; }
.offerr-btn:disabled { opacity: 0.6; cursor: not-allowed; }

/* ------------------------------------------------------------------ */
/*  Summary (stap 4)                                                   */
/* ------------------------------------------------------------------ */
.offerr-sum-row {
  display: flex;
  justify-content: space-between;
  padding: 7px 0;
  border-bottom: 1px solid var(--offerr-border);
  font-size: 14px;
}
.offerr-sum-row:last-of-type { border-bottom: none; }
.offerr-sum-label { color: var(--offerr-muted); }
.offerr-sum-val { font-weight: 600; color: var(--offerr-dark); text-align: right; max-width: 55%; }
.offerr-sum-total {
  display: flex;
  justify-content: space-between;
  padding: 12px 0 4px;
  font-size: 16px;
  font-weight: 600;
  color: var(--offerr-dark);
  border-top: 2px solid var(--offerr-dark);
  margin-top: 8px;
}

/* ------------------------------------------------------------------ */
/*  Sidebar                                                            */
/* ------------------------------------------------------------------ */
.offerr-sidebar h3 {
  font-family: var(--offerr-font);
  font-size: 18px;
  margin-bottom: 14px;
  color: var(--offerr-dark);
}
.offerr-ov-row {
  display: flex;
  justify-content: space-between;
  font-size: 13px;
  padding: 5px 0;
  border-bottom: 1px solid var(--offerr-border);
}
.offerr-ov-lbl { color: var(--offerr-muted); }
.offerr-ov-val { font-weight: 500; color: var(--offerr-dark); text-align: right; max-width: 55%; }
.offerr-ov-total {
  display: flex;
  justify-content: space-between;
  font-size: 15px;
  font-weight: 700;
  padding: 10px 0 4px;
  color: var(--offerr-dark);
  border-top: 2px solid var(--offerr-dark);
  margin-top: 8px;
}

/* ------------------------------------------------------------------ */
/*  Success                                                            */
/* ------------------------------------------------------------------ */
.offerr-success-box { text-align: center; padding: 40px 24px; }
.offerr-success-icon { font-size: 52px; margin-bottom: 16px; }
.offerr-success-box h2 {
  font-family: var(--offerr-font);
  font-size: 26px;
  margin-bottom: 10px;
}
.offerr-success-box p { color: var(--offerr-muted); font-size: 15px; line-height: 1.6; }

/* ------------------------------------------------------------------ */
/*  Step 4/5/6 — sidebar hidden                                       */
/* ------------------------------------------------------------------ */
.offerr-step4-active .offerr-sidebar,
.offerr-step5-active .offerr-sidebar,
.offerr-step6-active .offerr-sidebar { display: none; }
.offerr-step4-active .offerr-main,
.offerr-step5-active .offerr-main,
.offerr-step6-active .offerr-main { max-width: 680px; margin: 0 auto; flex: 1 1 100%; }
.offerr-step4-active .offerr-layout,
.offerr-step5-active .offerr-layout,
.offerr-step6-active .offerr-layout { justify-content: center; }

/* ------------------------------------------------------------------ */
/*  Loader                                                             */
/* ------------------------------------------------------------------ */
.offerr-loading {
  text-align: center;
  padding: 40px;
  color: var(--offerr-muted);
  font-size: 15px;
}

/* ------------------------------------------------------------------ */
/*  Mobile                                                             */
/* ------------------------------------------------------------------ */
@media (max-width: 640px) {
  #offerr-wizard { padding: 16px 12px; }
  .offerr-brand { font-size: 22px; margin-bottom: 16px; }

  .offerr-steps-bar {
    padding: 6px;
    gap: 4px;
    overflow: hidden;
  }
  .offerr-step-ind {
    font-size: 0;
    padding: 10px 4px;
    white-space: nowrap;
    overflow: hidden;
  }
  .offerr-step-ind::before {
    font-size: 12px;
    font-weight: 600;
    content: attr(data-step);
  }
  .offerr-step-ind.active {
    font-size: 12px;
    flex: 3;
    padding: 10px 8px;
  }
  .offerr-step-ind.active::before { content: ''; }

  .offerr-layout { flex-direction: column; }
  .offerr-sidebar {
    width: 100%;
    position: static;
    order: 2;
  }
  .offerr-main { order: 1; min-width: 0; width: 100%; }

  .offerr-step-box { padding: 16px; }

  .offerr-card img { height: 280px; }

  #offerr-wizard input[type=range] { height: 8px; }
  #offerr-wizard input[type=range]::-webkit-slider-thumb {
    width: 26px;
    height: 26px;
    margin-top: -9px;
  }
  #offerr-wizard input[type=range]::-moz-range-thumb {
    width: 26px;
    height: 26px;
  }
  #offerr-wizard input[type=range]::-webkit-slider-runnable-track { height: 8px; }
  #offerr-wizard input[type=range]::-moz-range-track { height: 8px; }

  .offerr-btn { padding: 14px 16px; font-size: 15px; }
}
