/* =============================================
   WP Reviews Pro — Redesign v2
   Mobile-first · Modern · ValyutaMobile brand
   ============================================= */

@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700;800&display=swap');

.wprp, .wprp *, .wprp *::before, .wprp *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

.wprp {
  --brand:        #0067dd;
  --brand-dark:   #0052b3;
  --brand-light:  #e8f1ff;
  --star:         #f59e0b;
  --star-empty:   #e2e8f0;
  --text-primary: #0f172a;
  --text-sec:     #64748b;
  --text-hint:    #94a3b8;
  --border:       #e2e8f0;
  --bg:           #f8fafc;
  --white:        #ffffff;
  --green:        #10b981;
  --green-bg:     #ecfdf5;
  --red:          #ef4444;
  --radius-lg:    16px;
  --radius-md:    12px;
  --radius-sm:    8px;
  --shadow-md:    0 4px 16px rgba(0,103,221,.10), 0 1px 4px rgba(0,0,0,.06);
  --transition:   .18s cubic-bezier(.4,0,.2,1);

  all: initial;
  display: block;
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-size: 14px;
  line-height: 1.5;
  color: var(--text-primary);
  margin: 32px 0;
}

/* TOP CARD */
.wprp-top {
  display: grid;
  grid-template-columns: 1fr 280px;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  overflow: hidden;
  margin-bottom: 24px;
}

.wprp-form-col {
  padding: 28px 32px;
  border-right: 1px solid var(--border);
  min-width: 0;
}

.wprp-form-col__title {
  font-size: 18px;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.wprp-form-col__title::before {
  content: '';
  display: inline-block;
  width: 4px;
  height: 20px;
  background: var(--brand);
  border-radius: 2px;
  flex-shrink: 0;
}

.wprp-picker-row { margin-bottom: 14px; }

.wprp-star-input {
  display: inline-flex;
  gap: 4px;
}

.wprp-star-btn {
  font-size: 32px;
  color: var(--star-empty);
  cursor: pointer;
  line-height: 1;
  transition: color var(--transition), transform var(--transition), filter var(--transition);
  user-select: none;
  display: inline-block;
}
.wprp-star-btn.active,
.wprp-star-btn.hovered {
  color: var(--star);
  transform: scale(1.15);
  filter: drop-shadow(0 2px 6px rgba(245,158,11,.4));
}
.wprp-star-btn--locked { cursor: default; }

.wprp-restrict-notice {
  background: var(--brand-light);
  border: 1px solid rgba(0,103,221,.2);
  border-radius: var(--radius-sm);
  padding: 10px 14px;
  font-size: 13px;
  color: var(--brand);
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  line-height: 1.5;
  font-weight: 500;
}
.wprp-restrict-notice__link {
  color: var(--brand-dark);
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
  padding: 2px 8px;
  background: rgba(0,103,221,.1);
  border-radius: 4px;
}
.wprp-restrict-notice__link:hover { text-decoration: underline; }

.wprp-textarea {
  display: block;
  width: 100%;
  min-height: 110px;
  padding: 12px 14px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-md);
  font-size: 14px;
  font-family: inherit;
  color: var(--text-primary);
  background: var(--bg);
  resize: vertical;
  line-height: 1.6;
  transition: border-color var(--transition), box-shadow var(--transition), background var(--transition);
  outline: none;
  -webkit-appearance: none;
}
.wprp-textarea::placeholder { color: var(--text-hint); }
.wprp-textarea:focus {
  border-color: var(--brand);
  background: var(--white);
  box-shadow: 0 0 0 3px rgba(0,103,221,.12);
}
.wprp-textarea--locked { cursor: default; color: var(--text-hint); background: var(--bg); }
.wprp-textarea--locked:focus { border-color: var(--border); box-shadow: none; }

.wprp-err {
  font-size: 12px;
  font-weight: 600;
  color: var(--red);
  margin-top: 6px;
  display: none;
}

.wprp-response {
  margin-top: 10px;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 600;
}
.wprp-response--ok  { background: var(--green-bg); border: 1px solid #6ee7b7; color: #065f46; }
.wprp-response--err { background: #fef2f2; border: 1px solid #fca5a5; color: #991b1b; }

.wprp-btn-submit {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 16px;
  padding: 11px 28px;
  background: var(--brand);
  color: #fff;
  border: none;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  letter-spacing: .04em;
  text-transform: uppercase;
  transition: background var(--transition), box-shadow var(--transition), transform var(--transition);
  text-decoration: none;
  line-height: 1.4;
  -webkit-appearance: none;
  touch-action: manipulation;
}
.wprp-btn-submit:hover {
  background: var(--brand-dark);
  box-shadow: 0 4px 14px rgba(0,103,221,.4);
  transform: translateY(-1px);
}
.wprp-btn-submit--disabled {
  background: #cbd5e1;
  color: #94a3b8;
  cursor: not-allowed;
  box-shadow: none;
  transform: none;
}

.wprp-btn-login {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 16px;
  padding: 11px 24px;
  background: var(--brand);
  color: #fff !important;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
  text-decoration: none !important;
  font-family: inherit;
  transition: background var(--transition), box-shadow var(--transition);
  touch-action: manipulation;
}
.wprp-btn-login:hover { background: var(--brand-dark); box-shadow: 0 4px 14px rgba(0,103,221,.4); }

/* STATS COLUMN */
.wprp-stats-col {
  padding: 28px 24px;
  background: linear-gradient(160deg, #f0f6ff 0%, var(--white) 100%);
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.wprp-stats-col__avg {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 4px;
}
.wprp-stats-col__num {
  font-size: 22px;
  font-weight: 800;
  color: var(--text-primary);
  letter-spacing: -.02em;
}
.wprp-stats-col__total {
  font-size: 12px;
  font-weight: 500;
  color: var(--text-sec);
  margin-bottom: 18px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--border);
}

.wprp-dist { display: flex; flex-direction: column; gap: 8px; }
.wprp-dist__row { display: flex; align-items: center; gap: 8px; }
.wprp-dist__label {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-sec);
  white-space: nowrap;
  min-width: 48px;
}
.wprp-dist__track {
  flex: 1;
  height: 8px;
  background: var(--border);
  border-radius: 99px;
  overflow: hidden;
}
.wprp-dist__fill {
  height: 100%;
  background: linear-gradient(90deg, var(--star) 0%, #fbbf24 100%);
  border-radius: 99px;
  transition: width .5s cubic-bezier(.4,0,.2,1);
}
.wprp-dist__pct {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-hint);
  min-width: 28px;
  text-align: right;
}

/* REVIEWS LIST */
.wprp-list { display: flex; flex-direction: column; gap: 0; }

.wprp-no-reviews {
  padding: 32px 0;
  color: var(--text-hint);
  font-size: 14px;
  font-weight: 500;
  text-align: center;
  border-top: 1px solid var(--border);
}

.wprp-card {
  padding: 20px 0;
  border-bottom: 1px solid var(--border);
  animation: wprpFadeIn .3s ease both;
}
.wprp-card:first-child { border-top: 1px solid var(--border); }

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

.wprp-card__head {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 10px;
}
.wprp-card__av {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  display: block;
  border: 2.5px solid var(--brand-light);
}
.wprp-card__meta { flex: 1; min-width: 0; }
.wprp-card__name {
  font-weight: 700;
  font-size: 14px;
  color: var(--text-primary);
  display: block;
  margin-bottom: 3px;
}
.wprp-card__badges { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.wprp-card__badge {
  background: var(--green-bg);
  color: #065f46;
  border: 1px solid #6ee7b7;
  padding: 1px 8px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 700;
}
.wprp-card__date {
  font-size: 12px;
  color: var(--text-hint);
  font-weight: 500;
  margin-left: auto;
  flex-shrink: 0;
  padding-left: 8px;
}
.wprp-card__stars { margin-bottom: 8px; }
.wprp-card__title { font-weight: 700; font-size: 14px; margin-bottom: 5px; color: var(--text-primary); }
.wprp-card__text { font-size: 14px; color: #334155; line-height: 1.65; }
.wprp-card__reply {
  margin-top: 12px;
  padding: 12px 14px;
  background: var(--brand-light);
  border-left: 3px solid var(--brand);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-size: 13px;
  color: #1e3a5f;
  line-height: 1.5;
}
.wprp-card__foot {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 12px;
  flex-wrap: wrap;
}

.wprp-helpful {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: var(--bg);
  border: 1.5px solid var(--border);
  border-radius: 20px;
  padding: 4px 12px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  color: var(--text-sec);
  font-family: inherit;
  transition: background var(--transition), border-color var(--transition), color var(--transition);
  touch-action: manipulation;
}
.wprp-helpful:hover  { background: #fffbeb; border-color: var(--star); color: var(--text-primary); }
.wprp-helpful--voted { background: #fffbeb; border-color: var(--star); color: #92400e; }

.wprp-reply-toggle {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: none;
  border: 1.5px solid var(--border);
  border-radius: 20px;
  padding: 4px 12px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  color: var(--text-sec);
  font-family: inherit;
  transition: border-color var(--transition), color var(--transition);
  touch-action: manipulation;
}
.wprp-reply-toggle:hover { border-color: var(--brand); color: var(--brand); }

.wprp-reply-box { margin-top: 12px; display: flex; flex-direction: column; gap: 8px; }
.wprp-reply-send {
  align-self: flex-start;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--green);
  color: #fff;
  border: none;
  border-radius: var(--radius-sm);
  padding: 8px 18px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  font-family: inherit;
  transition: background var(--transition), box-shadow var(--transition);
  touch-action: manipulation;
}
.wprp-reply-send:hover { background: #059669; box-shadow: 0 4px 12px rgba(16,185,129,.35); }

/* PAGINATION */
.wprp-pagination {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-wrap: wrap;
  margin-top: 20px;
}
.wprp-page {
  all: unset;
  cursor: pointer;
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-sec);
  font-family: inherit;
  transition: background var(--transition), color var(--transition);
  touch-action: manipulation;
}
.wprp-page:hover   { background: var(--bg); color: var(--text-primary); }
.wprp-page--active { background: var(--brand) !important; color: #fff !important; box-shadow: 0 2px 8px rgba(0,103,221,.4); }

/* ══════════════════════════════════════════════
   MOBILE
   ══════════════════════════════════════════════ */
@media (max-width: 680px) {
  .wprp { margin: 20px 0; }

  .wprp-top {
    grid-template-columns: 1fr;
    border-radius: var(--radius-md);
  }
  .wprp-form-col {
    padding: 20px 16px;
    border-right: none;
    border-bottom: 1px solid var(--border);
  }
  .wprp-form-col__title { font-size: 16px; }

  /* Stats: score big + bars compact */
  .wprp-stats-col {
    padding: 16px;
    background: linear-gradient(135deg, #f0f6ff 0%, var(--white) 100%);
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 16px;
    align-items: center;
  }
  .wprp-stats-col__avg {
    flex-direction: column;
    align-items: flex-start;
    gap: 2px;
    margin-bottom: 0;
  }
  .wprp-stats-col__num {
    font-size: 36px;
    line-height: 1;
    color: var(--brand);
  }
  .wprp-stats-col__total {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
    font-size: 11px;
    grid-column: 1 / -1;
  }
  .wprp-dist { gap: 6px; }
  .wprp-dist__label { min-width: 40px; font-size: 11px; }

  /* Stars bigger on mobile for easy tapping */
  .wprp-star-btn { font-size: 36px !important; }

  /* Full-width button */
  .wprp-btn-submit,
  .wprp-btn-login {
    width: 100%;
    justify-content: center;
    padding: 13px 20px;
    font-size: 14px;
    border-radius: var(--radius-sm);
    margin-top: 14px;
  }

  .wprp-card { padding: 16px 0; }
  .wprp-card__date { font-size: 11px; }
  .wprp-page { width: 40px; height: 40px; font-size: 14px; }
}

/* ══════════════════════════════════════════════
   ISOLATION — override aggressive theme resets
   ══════════════════════════════════════════════ */
.wprp .wprp-btn-submit,
.wprp button.wprp-btn-submit,
.wprp input[type=submit].wprp-btn-submit {
  all: unset !important;
  box-sizing: border-box !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 8px !important;
  margin-top: 16px !important;
  padding: 11px 28px !important;
  background: var(--brand) !important;
  color: #fff !important;
  border: none !important;
  border-radius: var(--radius-sm) !important;
  font-size: 13px !important;
  font-weight: 700 !important;
  font-family: 'Plus Jakarta Sans', -apple-system, sans-serif !important;
  cursor: pointer !important;
  letter-spacing: .04em !important;
  text-transform: uppercase !important;
  transition: background var(--transition), box-shadow var(--transition) !important;
  -webkit-appearance: none !important;
  touch-action: manipulation !important;
}
.wprp button.wprp-btn-submit:hover {
  background: var(--brand-dark) !important;
  box-shadow: 0 4px 14px rgba(0,103,221,.4) !important;
  color: #fff !important;
}
.wprp button.wprp-btn-submit:disabled,
.wprp button.wprp-btn-submit--disabled {
  background: #cbd5e1 !important;
  color: #94a3b8 !important;
  cursor: not-allowed !important;
  box-shadow: none !important;
}

.wprp .wprp-btn-login {
  all: unset !important;
  box-sizing: border-box !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 8px !important;
  margin-top: 16px !important;
  padding: 11px 24px !important;
  background: var(--brand) !important;
  color: #fff !important;
  border-radius: var(--radius-sm) !important;
  font-size: 13px !important;
  font-weight: 700 !important;
  letter-spacing: .04em !important;
  text-transform: uppercase !important;
  text-decoration: none !important;
  font-family: 'Plus Jakarta Sans', -apple-system, sans-serif !important;
  touch-action: manipulation !important;
}

.wprp .wprp-helpful {
  all: unset !important;
  box-sizing: border-box !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 5px !important;
  background: var(--bg) !important;
  border: 1.5px solid var(--border) !important;
  border-radius: 20px !important;
  padding: 4px 12px !important;
  font-size: 12px !important;
  font-weight: 600 !important;
  cursor: pointer !important;
  color: var(--text-sec) !important;
  font-family: inherit !important;
  touch-action: manipulation !important;
}
.wprp .wprp-helpful:hover     { background: #fffbeb !important; border-color: var(--star) !important; }
.wprp .wprp-helpful--voted    { background: #fffbeb !important; border-color: var(--star) !important; color: #92400e !important; }

.wprp .wprp-reply-toggle {
  all: unset !important;
  box-sizing: border-box !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 5px !important;
  background: none !important;
  border: 1.5px solid var(--border) !important;
  border-radius: 20px !important;
  padding: 4px 12px !important;
  font-size: 12px !important;
  font-weight: 600 !important;
  cursor: pointer !important;
  color: var(--text-sec) !important;
  font-family: inherit !important;
  touch-action: manipulation !important;
}

.wprp .wprp-reply-send {
  all: unset !important;
  box-sizing: border-box !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 6px !important;
  align-self: flex-start !important;
  background: var(--green) !important;
  color: #fff !important;
  border: none !important;
  border-radius: var(--radius-sm) !important;
  padding: 8px 18px !important;
  font-size: 13px !important;
  font-weight: 700 !important;
  cursor: pointer !important;
  font-family: inherit !important;
  touch-action: manipulation !important;
}

.wprp .wprp-page {
  all: unset !important;
  box-sizing: border-box !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 36px !important;
  height: 36px !important;
  border-radius: 50% !important;
  font-size: 13px !important;
  font-weight: 600 !important;
  color: var(--text-sec) !important;
  background: transparent !important;
  border: none !important;
  cursor: pointer !important;
  font-family: inherit !important;
  touch-action: manipulation !important;
}
.wprp .wprp-page--active { background: var(--brand) !important; color: #fff !important; }

.wprp .wprp-star-btn {
  all: unset !important;
  box-sizing: border-box !important;
  font-size: 32px !important;
  color: var(--star-empty) !important;
  cursor: pointer !important;
  line-height: 1 !important;
  transition: color var(--transition), transform var(--transition), filter var(--transition) !important;
  user-select: none !important;
  display: inline-block !important;
  background: none !important;
  border: none !important;
  padding: 0 !important;
  margin: 0 !important;
  touch-action: manipulation !important;
}
.wprp .wprp-star-btn.active,
.wprp .wprp-star-btn.hovered {
  color: var(--star) !important;
  transform: scale(1.15) !important;
  filter: drop-shadow(0 2px 6px rgba(245,158,11,.4)) !important;
}
.wprp .wprp-star-btn--locked { cursor: default !important; }

.wprp textarea.wprp-textarea,
.wprp .wprp-textarea,
#wprp-text-1 {
  all: unset !important;
  box-sizing: border-box !important;
  display: block !important;
  width: 100% !important;
  min-height: 110px !important;
  padding: 12px 14px !important;
  border: 1.5px solid var(--border) !important;
  border-radius: var(--radius-md) !important;
  font-size: 14px !important;
  font-family: 'Plus Jakarta Sans', -apple-system, sans-serif !important;
  color: var(--text-primary) !important;
  background: var(--bg) !important;
  resize: vertical !important;
  line-height: 1.6 !important;
  outline: none !important;
  -webkit-appearance: none !important;
  appearance: none !important;
}
.wprp textarea.wprp-textarea:focus,
.wprp .wprp-textarea:focus {
  border-color: var(--brand) !important;
  background: var(--white) !important;
  box-shadow: 0 0 0 3px rgba(0,103,221,.12) !important;
}
.wprp textarea.wprp-textarea::placeholder,
.wprp .wprp-textarea::placeholder {
  color: var(--text-hint) !important;
  opacity: 1 !important;
}
.wprp .wprp-textarea--locked {
  cursor: default !important;
  color: var(--text-hint) !important;
  background: var(--bg) !important;
}
