/* =========================
   НОВА ПОШТА — чекаут-стиль
   moda24.online
========================= */
#np-widget{
  --npw-line:#d9d9d9;
  --npw-dark:#1a1a1a;
  --npw-hi:#c8641e;
  --npw-err:#d0342c;
  font-family:inherit;width:100%;margin:0 0 20px;color:var(--npw-dark);
}
#np-widget *{box-sizing:border-box}

.npw-sec-title{
  font-size:15px;font-weight:700;letter-spacing:.02em;
  color:var(--npw-dark);margin-bottom:20px;
}

/* підписи */
.npw-label{display:block;font-size:15px;color:#444;margin:20px 0 8px;font-weight:400}
.npw-label:first-child{margin-top:0}
.npw-hi{color:var(--npw-hi)}

/* поля */
.npw-field{position:relative}
.npw-input{
  width:100%;padding:15px 46px 15px 16px;border:1px solid var(--npw-line);
  border-radius:2px;font-size:16px;color:var(--npw-dark);background:#fff;
  outline:none;transition:border-color .15s;
  appearance:none;-webkit-appearance:none;font-family:inherit;touch-action:manipulation;
}
.npw-input::placeholder{color:#b0b0b0}
.npw-input:focus{border-color:var(--npw-dark)}
.npw-input:focus-visible{outline:2px solid var(--npw-dark);outline-offset:1px}
.npw-input:disabled{background:#fafafa;color:#aaa;cursor:not-allowed}
.npw-input.np-err{border-color:var(--npw-err)}

.npw-caret{
  position:absolute;right:16px;top:50%;margin-top:-2px;
  width:0;height:0;border-left:5px solid transparent;border-right:5px solid transparent;
  border-top:5px solid #777;pointer-events:none;
}

/* хрестик очищення */
.npw-clear{
  display:none;position:absolute;right:10px;top:50%;transform:translateY(-50%);
  width:26px;height:26px;padding:0;border:none;background:none;
  cursor:pointer;align-items:center;justify-content:center;
  z-index:5;font-family:inherit;touch-action:manipulation;
}
.npw-clear svg{width:11px;height:11px;display:block}
.npw-clear svg path{stroke:#8a8a8a;transition:stroke .15s}
.npw-clear:hover svg path{stroke:var(--npw-dark)}
.npw-clear:focus-visible{outline:2px solid var(--npw-dark);outline-offset:0}

/* коли в полі є значення — ховаємо стрілку, показуємо хрестик */
.npw-field.npw-filled .npw-caret{display:none}
.npw-field.npw-filled .npw-clear{display:flex}

.npw-spin{
  display:none;position:absolute;right:40px;top:50%;transform:translateY(-50%);
  width:14px;height:14px;border:2px solid #eee;border-top-color:var(--npw-dark);
  border-radius:50%;animation:npws .65s linear infinite;pointer-events:none;
}
@keyframes npws{to{transform:translateY(-50%) rotate(360deg)}}
.npw-loading .npw-spin{display:block}

/* швидкі міста */
.npw-chips{display:flex;flex-wrap:wrap;gap:8px 22px;margin-top:12px}
.npw-chip{
  border:none;background:none;padding:0;font-family:inherit;font-size:15px;
  color:var(--npw-hi);cursor:pointer;touch-action:manipulation;
}
.npw-chip:hover{text-decoration:underline}
.npw-chip:focus-visible{outline:2px solid var(--npw-dark);outline-offset:2px}

/* випадайка */
.npw-dd{
  display:none;position:absolute;top:calc(100% - 1px);left:0;right:0;
  background:#fff;border:1px solid var(--npw-dark);border-radius:0 0 2px 2px;
  max-height:250px;overflow-y:auto;z-index:99999;
}
.npw-dd-item{
  padding:12px 16px;font-size:15px;color:var(--npw-dark);cursor:pointer;
  border-bottom:1px solid #f0f0f0;line-height:1.4;
}
.npw-dd-item:last-child{border-bottom:none}
.npw-dd-item:hover{background:#f6f6f6}
.npw-dd-item small{display:block;font-size:12px;color:#999;margin-top:3px}
.npw-dd-empty{padding:16px;font-size:14px;color:#999;text-align:center}

.npw-err-msg{font-size:13px;color:var(--npw-err);margin-top:6px;display:none}
.npw-err-msg.show{display:block}

/* спосіб доставки */
.npw-radio{
  display:flex;align-items:center;gap:14px;padding:13px 14px;
  border:1px dashed transparent;cursor:pointer;user-select:none;
  transition:border-color .15s;
}
.npw-radio:hover .npw-radio-dot{border-color:#888}
.npw-radio.active{border-color:#b5b5b5}
.npw-radio:focus-visible{outline:2px solid var(--npw-dark);outline-offset:1px}
.npw-radio-dot{
  width:22px;height:22px;border-radius:50%;border:1px solid #c9c9c9;
  flex-shrink:0;position:relative;transition:border-color .15s;
}
.npw-radio.active .npw-radio-dot{border-color:var(--npw-dark)}
.npw-radio.active .npw-radio-dot::after{
  content:"";position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);
  width:11px;height:11px;border-radius:50%;background:var(--npw-dark);
}
.npw-radio-txt{font-size:15px;color:var(--npw-dark);line-height:1.4}

.npw-addr-sec{display:none}
.npw-addr-sec.show{display:block}
.npw-row{display:flex;gap:12px}
.npw-row>div{flex:1}

/* підтвердження */
.npw-confirm{
  display:none;margin-top:20px;padding:14px 16px;background:#f6f6f6;
  align-items:flex-start;gap:12px;
}
.npw-confirm.show{display:flex}
.npw-confirm-check{
  width:20px;height:20px;border-radius:50%;background:var(--npw-dark);
  display:flex;align-items:center;justify-content:center;flex-shrink:0;margin-top:1px;
}
.npw-confirm-check svg{width:10px;height:8px}
.npw-confirm-txt{font-size:15px;color:var(--npw-dark);line-height:1.5}
.npw-confirm-txt small{display:block;font-size:13px;color:#888;margin-top:3px}

@media(max-width:480px){
  .npw-label,.npw-radio-txt,.npw-chip{font-size:14px}
  .npw-row{flex-direction:column;gap:0}
  .npw-chips{gap:8px 16px}
  .npw-clear{width:32px;height:32px;right:7px}
}

@media(prefers-reduced-motion:reduce){
  #np-widget *,#np-widget *::before,#np-widget *::after{
    animation-duration:.01ms !important;transition-duration:.01ms !important;
  }
}