/* ============================================================
   Quote Form - Multi-step typeform-style
   Shared by: full-booking, get-call
   ============================================================ */

.qf-wrapper {
  padding: 60px 0 80px;
  background: #f8f9fa;
  min-height: 60vh;
}

/* ---------- Progress Steps ---------- */
.qf-progress {
  margin-bottom: 50px;
}

.qf-steps {
  display: flex;
  list-style: none;
  padding: 0;
  margin: 0;
  position: relative;
  justify-content: space-between;
}

.qf-steps::before {
  content: '';
  position: absolute;
  top: 20px;
  left: 0;
  right: 0;
  height: 2px;
  background: #dee2e6;
  z-index: 0;
}

.qf-step-indicator {
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
  z-index: 1;
  flex: 1;
}

.qf-step-number {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #fff;
  border: 2px solid #dee2e6;
  color: #adb5bd;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 14px;
  transition: all 0.3s ease;
  margin-bottom: 8px;
}

.qf-step-label {
  font-size: 11px;
  color: #adb5bd;
  text-align: center;
  font-weight: 500;
  line-height: 1.2;
  transition: color 0.3s;
  max-width: 70px;
}

.qf-step-indicator.qf-active .qf-step-number {
  background: #256F9C;
  border-color: #256F9C;
  color: #fff;
  box-shadow: 0 0 0 4px rgba(37, 111, 156, 0.2);
}

@keyframes qfStepPulse {
  0%   { box-shadow: 0 0 0 4px rgba(37, 111, 156, 0.4); }
  60%  { box-shadow: 0 0 0 12px rgba(37, 111, 156, 0); }
  100% { box-shadow: 0 0 0 4px rgba(37, 111, 156, 0.2); }
}

.qf-step-number--pulse {
  animation: qfStepPulse 1s ease-out 3;
}

.qf-step-indicator.qf-active .qf-step-label {
  color: #256F9C;
  font-weight: 700;
}

.qf-step-indicator.completed .qf-step-number {
  background: #28a745;
  border-color: #28a745;
  color: #fff;
}

.qf-step-indicator.completed .qf-step-label {
  color: #28a745;
}

/* ---------- Step Panels ---------- */
.qf-step-panel {
  display: none;
  animation: qfFadeIn 0.3s ease;
}

.qf-step-panel.qf-active {
  display: block;
}

@keyframes qfFadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: translateY(0); }
}

.qf-step-panel .qf-question {
  font-size: 26px;
  font-weight: 700;
  color: #212529;
  margin-bottom: 8px;
}

.qf-step-panel .qf-hint {
  font-size: 15px;
  color: #6c757d;
  margin-bottom: 30px;
}

/* ---------- Form Groups ---------- */
.qf-form-group {
  margin-bottom: 20px;
}

.qf-form-group label {
  font-weight: 600;
  color: #495057;
  margin-bottom: 6px;
  display: block;
}

.qf-form-group input[type="text"],
.qf-form-group input[type="email"],
.qf-form-group input[type="tel"],
.qf-form-group input[type="number"],
.qf-form-group input[type="date"],
.qf-form-group select,
.qf-form-group textarea {
  width: 100%;
  padding: 12px 16px;
  border: 2px solid #dee2e6;
  border-radius: 8px;
  font-size: 16px;
  transition: border-color 0.2s;
  background: #fff;
}

.qf-form-group input:focus,
.qf-form-group select:focus,
.qf-form-group textarea:focus {
  border-color: #256F9C;
  outline: none;
  box-shadow: 0 0 0 3px rgba(37, 111, 156, 0.15);
}

.qf-form-group input.error,
.qf-form-group textarea.error {
  border-color: #dc3545;
}

.qf-form-group label.error {
  color: #dc3545;
  font-size: 13px;
  font-weight: 400;
  margin-top: 4px;
}

/* ---------- Help link ---------- */
.qf-help-link {
  font-size: 14px;
  color: #256F9C;
  text-decoration: none;
  white-space: nowrap;
}

.qf-help-link:hover {
  text-decoration: underline;
}

/* ---------- Help overlays ---------- */
.qf-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  z-index: 9999;
  align-items: center;
  justify-content: center;
}

.qf-overlay.qf-overlay-open {
  display: flex;
}

.qf-overlay-box {
  background: #fff;
  border-radius: 12px;
  max-width: 720px;
  width: 90%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.qf-overlay-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid #dee2e6;
}

.qf-overlay-header h5 {
  margin: 0;
  font-size: 17px;
  font-weight: 600;
}

.qf-overlay-close {
  background: none;
  border: none;
  font-size: 24px;
  line-height: 1;
  color: #6c757d;
  cursor: pointer;
  padding: 0 4px;
}

.qf-overlay-close:hover {
  color: #212529;
}

.qf-overlay-body {
  padding: 20px;
  text-align: center;
}

.qf-overlay--lightbox {
  cursor: zoom-out;
}

.qf-lightbox-img {
  max-width: 90vw;
  max-height: 85vh;
  width: auto;
  height: auto;
  border-radius: 6px;
  box-shadow: 0 8px 40px rgba(0, 0, 0, 0.5);
  display: block;
}

.qf-thermos-count-input {
  max-width: 180px;
}

/* ---------- Size rows (repeatable width × height × qty) ---------- */
.qf-size-rows {
  margin-bottom: 12px;
}

.qf-size-row {
  display: flex;
  align-items: flex-end;
  gap: 12px;
  flex-wrap: wrap;
  border: 2px solid #dee2e6;
  border-radius: 12px;
  padding: 18px 16px;
  background: #fff;
  margin-bottom: 12px;
  transition: border-color 0.2s, background 0.2s;
}

.qf-size-row-field {
  display: flex;
  flex-direction: column;
}

.qf-size-row-label {
  font-size: 13px;
  color: #6c757d;
  font-weight: 500;
  margin-bottom: 6px;
}

.qf-size-row-field input[type="number"],
.qf-size-row-field select {
  box-sizing: border-box;
  height: 48px;
  width: 100px;
  padding: 0 10px;
  border: 1px solid #dee2e6;
  border-radius: 8px;
  font-size: 20px;
  background: #fff;
}

.qf-size-row-qty select {
  width: 90px;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  padding-right: 28px;
  background-image: url("data:image/svg+xml;charset=UTF-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236c757d' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 8px center;
  background-size: 16px;
}

.qf-size-row-field input[type="number"]:focus,
.qf-size-row-field select:focus {
  border-color: #256F9C;
  outline: none;
  box-shadow: 0 0 0 2px rgba(37, 111, 156, 0.15);
}

@media (min-width: 576px) {
  .qf-size-row-field input[type="number"] {
    width: 140px;
  }
}

.qf-size-row-sep {
  font-size: 24px;
  color: #adb5bd;
  padding-bottom: 12px;
  line-height: 1;
}

.qf-size-row-remove {
  margin-left: auto;
  border: none;
  background: none;
  color: #adb5bd;
  font-size: 22px;
  padding: 10px;
  cursor: pointer;
  transition: color 0.2s;
}

.qf-size-row-remove:hover {
  color: #dc3545;
}

.qf-size-add {
  border: 2px dashed #dee2e6;
  border-radius: 10px;
  background: #fff;
  color: #256F9C;
  font-size: 14px;
  font-weight: 600;
  padding: 10px 16px;
  width: 100%;
  text-align: center;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
  margin-bottom: 8px;
}

.qf-size-add:hover {
  border-color: #256F9C;
  background: #e8f3fa;
}

/* ---------- Address row ---------- */
.qf-addr-row {
  display: flex;
  gap: 12px;
}

.qf-addr-city   { flex: 1; }
.qf-addr-postal { flex: 0 0 140px; }

@media (max-width: 400px) {
  .qf-addr-row    { flex-direction: column; }
  .qf-addr-postal { flex: 1; }
}

/* ---------- Google Places dropdown ---------- */
.pac-container {
  z-index: 10000 !important;
  border-radius: 0 0 8px 8px;
  border: 1px solid #dee2e6;
  box-shadow: 0 4px 16px rgba(0,0,0,0.12);
  font-family: inherit;
  font-size: 15px;
}

.pac-item { padding: 8px 12px; cursor: pointer; }
.pac-item:hover, .pac-item-selected { background: #e8f3fa; }

/* ---------- Picture Cards ---------- */
.qf-card-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 8px;
}

.qf-card-option {
  flex: 0 0 calc(50% - 8px);
  border: 2px solid #dee2e6;
  border-radius: 12px;
  padding: 20px 16px;
  text-align: center;
  cursor: pointer;
  background: #fff;
  transition: all 0.2s ease;
  position: relative;
  user-select: none;
}

@media (min-width: 576px) {
  .qf-card-option.qf-col-4 {
    flex: 0 0 calc(25% - 12px);
  }
  .qf-card-option.qf-col-5 {
    flex: 0 0 calc(20% - 13px);
  }
}

.qf-card-option:hover {
  border-color: #256F9C;
  background: #f0f7fc;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(37, 111, 156, 0.12);
}

.qf-card-option.qf-selected {
  border-color: #256F9C;
  background: #e8f3fa;
}

.qf-card-option.qf-selected::after {
  content: '\f00c';
  font-family: 'Font Awesome 5 Free';
  font-weight: 900;
  position: absolute;
  top: 8px;
  right: 10px;
  font-size: 13px;
  color: #256F9C;
}

.qf-card-option input[type="checkbox"],
.qf-card-option input[type="radio"] {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.qf-card-img {
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 8px;
  background: #e9ecef;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 12px;
  overflow: hidden;
}

.qf-card-img i {
  font-size: 28px;
  color: #6c757d;
}

.qf-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 8px;
}

.qf-card-title {
  font-size: 14px;
  font-weight: 600;
  color: #343a40;
  line-height: 1.3;
}

.qf-card-option.qf-selected .qf-card-title {
  color: #256F9C;
}

.qf-card-error {
  color: #dc3545;
  font-size: 13px;
  margin-top: 6px;
  display: none;
}

.qf-card-error.qf-visible {
  display: block;
}

/* ---------- Appointment time cards (full-booking only) ---------- */
.qf-time-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 8px;
}

.qf-time-card {
  flex: 1 1 calc(33% - 8px);
  min-width: 130px;
  border: 2px solid #dee2e6;
  border-radius: 10px;
  padding: 16px 12px;
  text-align: center;
  cursor: pointer;
  background: #fff;
  transition: all 0.2s ease;
  position: relative;
}

.qf-time-card:hover,
.qf-time-card.qf-selected {
  border-color: #256F9C;
  background: #e8f3fa;
}

.qf-time-card input[type="radio"] {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.qf-time-card i {
  font-size: 22px;
  color: #6c757d;
  display: block;
  margin-bottom: 8px;
}

.qf-time-card.qf-selected i {
  color: #256F9C;
}

.qf-time-label {
  font-weight: 600;
  font-size: 14px;
  color: #343a40;
  display: block;
}

.qf-time-sub {
  font-size: 12px;
  color: #6c757d;
  display: block;
  margin-top: 2px;
}

/* ---------- Navigation ---------- */
.qf-nav {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 40px;
  padding-top: 24px;
  border-top: 1px solid #dee2e6;
}

.qf-nav .btn {
  padding: 12px 32px;
  font-size: 16px;
  font-weight: 600;
  border-radius: 8px;
}

.qf-step-counter {
  margin-left: auto;
  font-size: 13px;
  color: #adb5bd;
}

/* ---------- Success state ---------- */
.qf-success-panel {
  display: none;
  text-align: center;
  padding: 60px 20px;
}

.qf-success-panel.qf-visible {
  display: block;
  animation: qfFadeIn 0.4s ease;
}

.qf-success-panel .qf-success-icon {
  font-size: 64px;
  color: #28a745;
  margin-bottom: 24px;
}

.qf-success-panel h3 {
  font-size: 28px;
  font-weight: 700;
  color: #212529;
  margin-bottom: 12px;
}

.qf-success-panel p {
  font-size: 17px;
  color: #6c757d;
  max-width: 500px;
  margin: 0 auto;
}

/* ---------- Mobile ---------- */
@media (max-width: 575px) {
  .qf-wrapper {
    min-height: 0;
  }
  .qf-step-label {
    display: none;
  }
  .qf-step-number {
    width: 32px;
    height: 32px;
    font-size: 12px;
  }
  .qf-steps::before {
    top: 16px;
  }
  .qf-step-panel .qf-question {
    font-size: 20px;
  }
}
