body.pg-home-consult-open {
  overflow: hidden;
}

.pg-home-consult-modal{
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
  z-index: 9999;
}
.pg-home-consult-modal.active{
  display: flex;
}
.pg-home-consult-backdrop{
  position: absolute;
  inset: 0;
  background: rgba(13, 23, 46, 0.72);
  backdrop-filter: blur(6px);
}
.pg-home-consult-card{
  position: relative;
  direction: rtl;
  text-align: right;
  width: min(520px, 100%);
  max-width: 520px;
  max-height: calc(100vh - 64px);
  overflow: hidden;
  border-radius: 28px;
  background: #ffffff;
  box-shadow: 0 24px 64px rgba(15, 34, 77, 0.16);
  padding: 40px 28px 28px;
  z-index: 1;
  font-family: inherit;
}
.pg-home-consult-close{
  position: absolute;
  top: 18px;
  left: 18px;
  right: auto;
  width: 42px;
  height: 42px;
  border: none;
  background: rgba(17, 24, 39, 0.06);
  border-radius: 50%;
  cursor: pointer;
  z-index: 2;
}
.pg-home-consult-header{
  margin-top: 12px;
}
.pg-home-consult-close::before{
  content: '✕';
  display: block;
  font-size: 17px;
  line-height: 42px;
  text-align: center;
}
.pg-home-consult-phone-wrap{display:flex;align-items:center;gap:8px;direction:ltr;}
.pg-home-consult-phone-prefix{background:#f1f5f9;padding:8px 10px;border-radius:8px;color:#0f172d}
.pg-home-consult-phone input{flex:1;min-width:0;}
.pg-home-consult-actions{
  display:flex;
  gap:8px;
  justify-content:space-between;
  align-items:center;
  flex-wrap:wrap;
}
.pg-home-consult-actions button[data-consult-next]{order:1}
.pg-home-consult-actions .pg-home-consult-submit{order:2}
.pg-home-consult-actions [data-consult-prev]{order:3}
.pg-home-consult-actions .pg-home-consult-submit{
  background-color: #10b981;
  color: #fff;
  border-color: transparent;
}
.pg-home-consult-actions .pg-home-consult-submit:hover{
  background-color: #0f9f6e;
}

/* countdown circle */
.pg-home-consult-countdown{display:flex;align-items:center;gap:10px;margin-top:12px}
.circular-chart{width:48px;height:48px}
.circle-bg{fill:none;stroke:#eee;stroke-width:3.8}
.circle{fill:none;stroke:#06b6d4;stroke-width:3.8;stroke-linecap:round;transform:rotate(-90deg);transform-origin:center;transition:stroke-dasharray 1s linear}
.pg-home-consult-countdown-text{font-size:14px;color:#334155}

/* small pulsing animation for step number */
.pg-home-consult-progress .step.active{animation: pulse 1s infinite}
@keyframes pulse{0%{transform:scale(1)}50%{transform:scale(1.08)}100%{transform:scale(1)}}

/* softer error box color */
.pg-home-consult-error{background:#fff4e6;color:#92400e;border-radius:12px}
.pg-home-consult-header{
  margin-bottom: 24px;
}
.pg-home-consult-header h2{
  margin: 0 0 10px;
  font-size: 24px;
  line-height: 1.2;
  color: #0f172d;
}
.pg-home-consult-header p{
  margin: 0;
  color: #475569;
  line-height: 1.7;
  font-size: 15px;
}
.pg-home-consult-modal.success .pg-home-consult-header,
.pg-home-consult-modal.success .pg-home-consult-step,
.pg-home-consult-modal.success .pg-home-consult-progress,
.pg-home-consult-modal.success .pg-home-consult-step-panel,
.pg-home-consult-modal.success .pg-home-consult-actions,
.pg-home-consult-modal.success .pg-home-consult-error,
.pg-home-consult-modal.success .pg-home-consult-status {
  display: none;
}
.pg-home-consult-step{
  display: inline-flex;
  align-items: center;
  margin-bottom: 16px;
  font-size: 13px;
  color: #2563eb;
  font-weight: 600;
}
.pg-home-consult-progress{
  display: flex;
  gap: 10px;
  margin-bottom: 22px;
}
.pg-home-consult-progress .step{
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #eff6ff;
  color: #475569;
  font-weight: 700;
  border: 1px solid rgba(37,99,235,0.16);
}
.pg-home-consult-progress .step.active{
  background: #2563eb;
  color: #ffffff;
  border-color: transparent;
}
.pg-home-consult-form{
  display: grid;
  gap: 18px;
}
.pg-home-consult-field{
  display: grid;
  gap: 10px;
}
.pg-home-consult-field label{
  display: block;
  font-size: 14px;
  color: #334155;
}
.pg-home-consult-field input{
  width: 100%;
  min-height: 44px;
  padding: 0 14px;
  border-radius: 14px;
  border: 1px solid #d1d5db;
  background: #f8fafc;
  color: #0f172d;
  font-size: 15px;
}
.pg-home-consult-step-panel{
  display: none;
}
.pg-home-consult-step-panel[data-step="2"] .pg-home-consult-field{
  gap: 16px;
}
.pg-home-consult-step-panel[data-step="2"] .pg-home-consult-field label,
.pg-home-consult-step-panel[data-step="2"] .pg-home-consult-field input{
  font-weight: 600;
}
.pg-home-consult-step-panel.active{
  display: block;
}
.pg-home-consult-options{
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.pg-home-consult-option{
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  padding: 14px 16px;
  cursor: pointer;
  transition: border-color .2s ease, box-shadow .2s ease, background .2s ease, transform .2s ease;
  background: #f8fafc;
}
.pg-home-consult-option input{
  display: none;
}
.pg-home-consult-option:hover{
  border-color: #2563eb;
  transform: translateY(-1px);
}
.pg-home-consult-option.selected{
  border-color: #2563eb;
  background: rgba(37,99,235,0.1);
  box-shadow: 0 10px 24px rgba(37,99,235,0.1);
}
.pg-home-consult-option span{
  display: block;
  font-size: 15px;
  color: #0f172d;
}
.pg-home-consult-actions{
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  direction: ltr;
  margin-top: 18px;
}
.pg-home-consult-actions button{
  min-width: 120px;
  padding: 12px 18px;
  border-radius: 14px;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.1;
}
.pg-home-consult-actions button.pg-btn--primary{
  padding: 12px 22px;
}
.pg-home-consult-actions button.pg-btn--ghost{
  min-width: auto;
}
.pg-home-consult-actions .pg-home-consult-submit{
  background-color: #10b981;
  color: #fff;
  border: 1px solid rgba(16,185,129,0.4);
  box-shadow: 0 12px 30px rgba(16,185,129,0.18);
  animation: pg-home-consult-pulse 1.6s ease-in-out infinite;
}
.pg-home-consult-actions .pg-home-consult-submit:hover{
  background-color: #0f9f6e;
  box-shadow: 0 14px 34px rgba(16,185,129,0.25);
}
@keyframes pg-home-consult-pulse{
  0%, 100%{ transform: translateY(0); }
  50%{ transform: translateY(-2px); }
  color: #0f172d;
  font-size: 15px;
  min-height: 22px;
}
.pg-home-consult-card .pg-btn{
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: auto;
  border: 1px solid transparent;
  cursor: pointer;
  font-family: inherit;
  text-decoration: none;
  transition: background-color .2s ease, border-color .2s ease, box-shadow .2s ease, transform .2s ease;
}
.pg-home-consult-card .pg-btn--primary{
  background: #19284F;
  color: #fff;
  box-shadow: 0 12px 28px rgba(25,40,79,.16);
}
.pg-home-consult-card .pg-btn--primary:hover,
.pg-home-consult-card .pg-btn--primary:focus-visible{
  background: #243764;
  transform: translateY(-1px);
}
.pg-home-consult-card .pg-btn--ghost{
  background: #f8fafc;
  color: #0f172d;
}
.pg-home-consult-option.selected .pg-home-consult-option-label,
.pg-home-consult-option span{
  font-weight: 600;
}
.pg-home-consult-card .pg-home-consult-actions .pg-btn--ghost{
  border: 1px solid #cbd5e1;
}
.pg-home-consult-success{
  display: none;
}
.pg-home-consult-success.active{
  display: block;
}
.pg-home-consult-success.active ~ .pg-home-consult-actions{
  display: none;
}
.pg-home-consult-success-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 18px;
  padding: 40px 0;
}
.pg-home-consult-success-icon {
  width: 80px;
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  border-radius: 50%;
  color: white;
  flex-shrink: 0;
  font-size: 42px;
  line-height: 1;
}
.pg-home-consult-success-title {
  font-size: 22px;
  font-weight: 700;
  color: #0f172d;
  margin: 0;
}
.pg-home-consult-success-text {
  font-size: 16px;
  color: #475569;
  margin: 0;
  line-height: 1.6;
}
.pg-home-consult-countdown-wrapper {
  position: relative;
  width: 140px;
  height: 140px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.pg-home-consult-countdown-circle {
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}
.pg-home-consult-circle-bg {
  fill: none;
  stroke: #e2e8f0;
  stroke-width: 3;
}
.pg-home-consult-circle-progress {
  fill: none;
  stroke: #10b981;
  stroke-width: 3;
  stroke-linecap: round;
  stroke-dasharray: 339.29;
  stroke-dashoffset: 0;
  transition: stroke-dashoffset 1s linear;
}
.pg-home-consult-countdown-number {
  position: absolute;
  font-size: 48px;
  font-weight: 700;
  color: #10b981;
  font-family: 'Vazirmatn', sans-serif;
}
.hidden{
  display: none !important;
}
@media (max-width: 640px) {
  .pg-home-consult-card{
    padding: 20px;
    border-radius: 20px;
  }
  .pg-home-consult-progress{
    gap: 10px;
  }
  .pg-home-consult-progress .step{
    width: 30px;
    height: 30px;
  }
  .pg-home-consult-actions{
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
  }
  .pg-home-consult-actions button{
    width: auto;
    flex: 1;
    min-width: 0;
  }
  .pg-home-consult-actions button + button{
    margin-left: 10px;
  }
}
