/* Ridmi — product reviews page (reviews.html). Scoped under .rrev, builds on the
   .rp token set from ridmi-card.css (link ridmi-card.css BEFORE this file).
   Class contract with premium-optimized.new.js (do not rename): .reviews-page,
   .write-review(_expand/_collapse), #product-review-form, .review-field, .rate,
   .icon16/.icon10 star*, .reviews-branch, .reviews-list__content-block, .review,
   .actions, .review-reply(_expand/_collapse), .provider-fields, .errormsg */

.rrev{ max-width:860px; }
.rrev h1.title{ font-size:24px; font-weight:800; line-height:1.3; margin:10px 0 0; }
.rrev h1.title > span{ color:var(--slate); }
.rrev__page-num{ font-size:14px; font-weight:600; color:var(--muted); white-space:nowrap; }

/* ---- product summary card ---- */
.rrev__product{ display:flex; gap:16px; align-items:flex-start;
  background:#fff; border-radius:var(--r-card); box-shadow:var(--sh-sm);
  margin-top:14px; padding:18px; }
.rrev__cover{ flex:0 0 auto; }
.rrev__cover img{ width:96px; height:auto; border-radius:10px; box-shadow:var(--sh-sm); }
.rrev__product-info{ flex:1 1 auto; min-width:0; }
.rrev__count{ font-size:15px; font-weight:700; color:var(--ink); line-height:1.4; }
.rrev__count a{ color:var(--slate); }
.rrev dl.rrev__meta{ margin-top:16px; font-size:13px; }
.rrev__meta-row{ display:flex; gap:8px; padding:5px 8px; border-radius:8px; }
.rrev__meta-row:nth-child(odd){ background:var(--blue-bg); }
.rrev__meta-row dt{ flex:0 0 110px; color:var(--muted); }
.rrev__meta-row dd{ color:var(--ink); overflow-wrap:break-word; min-width:0; }
.rrev__more{ display:inline-flex; align-items:center; margin-top:12px; padding:9px 18px;
  border-radius:var(--r-pill); background:var(--blue-bg); color:var(--slate);
  font-size:13px; font-weight:700; transition:background .15s ease; }
.rrev__more:hover{ background:var(--blue-bg2); }

/* ---- add-review button ---- */
.rrev__add{ display:inline-flex; align-items:center; justify-content:center; margin-top:18px;
  min-height:44px; padding:0 22px; border:none; border-radius:var(--r-btn);
  background:var(--cyan); color:#fff; font-size:14.5px; font-weight:700;
  transition:background .18s ease; }
.rrev__add:hover{ background:var(--cyan-dark); }
.rrev__add .write-review_collapse{ display:none; }
.rrev__add.active{ background:var(--slate); }
.rrev__add.active .write-review_expand{ display:none; }
.rrev__add.active .write-review_collapse{ display:inline; }

/* ---- review form (movable block: appears under the button or inside a reply) ---- */
.rrev .review-form{ background:#fff; border-radius:var(--r-card); box-shadow:var(--sh-sm);
  margin-top:12px; padding:18px; }
/* ridmi-card.css turns .rp .wa-form into a 2-col grid for the profile page —
   here it would squeeze .review-form-fields into one column; keep normal flow */
.rrev .wa-form{ display:block; }
.rrev .review-field{ margin-top:12px; }
.rrev .review-field:first-child{ margin-top:0; }
.rrev__grid{ display:grid; grid-template-columns:1fr 1fr; gap:0 14px; }
.rrev__label{ display:block; font-size:12.5px; font-weight:700; color:var(--slate); margin-bottom:5px; }
.rrev__req{ color:var(--rose); margin-left:3px; font-weight:700; }
.rrev__opt{ color:var(--muted); font-weight:600; text-transform:none; letter-spacing:0; margin-left:5px; }
.rrev .wa-value input::placeholder,
.rrev .wa-value textarea::placeholder{ color:var(--muted); opacity:1; }
.rrev .wa-value input[type=text],
.rrev .wa-value input[type=email],
.rrev .wa-value textarea{ width:100%; min-height:42px; padding:9px 13px;
  border:1.5px solid var(--line); border-radius:var(--r-sm); background:#fff;
  font-family:var(--ff-ui); font-size:14px; color:var(--ink);
  transition:border-color .15s ease, box-shadow .15s ease; }
.rrev .wa-value textarea{ min-height:110px; resize:vertical; }
.rrev .wa-value input:focus, .rrev .wa-value textarea:focus{ outline:none;
  border-color:var(--peri); box-shadow:0 0 0 3px rgba(115,142,200,.18); }
.rrev .wa-value input.error, .rrev .wa-value textarea.error{ border-color:var(--fav); }
.rrev .errormsg{ display:block; margin-top:4px; font-size:12px; font-style:normal; color:var(--fav); }

/* logged-in user / auth rows */
.rrev__user{ display:flex; align-items:center; gap:8px; font-size:13.5px; font-weight:600; }
.rrev__user .userpic{ width:24px; height:24px; border-radius:50%; }
.rrev__logout{ font-size:12.5px; font-weight:600; color:var(--muted); text-decoration:underline; }
.rrev__logout:hover{ color:var(--slate); }
.rrev__auth-note a{ color:var(--cyan); text-decoration:underline; }
.rrev .wa-auth-adapters__list{ list-style:none; display:flex; gap:8px; margin:0 0 4px; padding:0; }
.rrev .wa-auth-adapters__block{ border-radius:50%; }
.rrev .wa-auth-adapters__block.selected{ box-shadow:0 0 0 2px var(--peri); }
.rrev .wa-auth-adapters__link{ display:grid; place-items:center; width:36px; height:36px;
  border-radius:50%; background:var(--blue-bg); color:var(--slate); }

/* star input widget (JS rateWidget: toggles star / star-empty / star-hover on <i>) */
.rrev__rate-row{ display:flex; align-items:center; gap:10px; }
.rrev__rate-row .rrev__label{ margin-bottom:0; }
.rrev .rate{ display:inline-flex; gap:3px; background:none; padding:0; border-radius:0; }
.rrev .rate i, .rrev .rating i{ font-style:normal; line-height:1; }
.rrev .rate i::before, .rrev .rating i::before{ content:"\2605"; }
.rrev .rate .icon16{ font-size:24px; color:var(--line); transition:color .1s ease; }
.rrev .rate .icon16.star{ color:var(--star); }
.rrev .rate .icon16.star-hover{ color:#F7C34D; }
.rrev .rate-clear{ font-size:12px; color:var(--muted); text-decoration:underline; }

/* submit row */
.rrev .review-submit .wa-value{ display:flex; flex-wrap:wrap; align-items:center; gap:12px; }
.rrev__submit{ min-height:44px; padding:0 26px; border:none; border-radius:var(--r-btn);
  background:var(--cyan); color:#fff; font-family:var(--ff-ui); font-size:14.5px; font-weight:700;
  transition:background .18s ease; }
.rrev__submit:hover{ background:var(--cyan-dark); }
.rrev .service-agreement-wrapper{ flex-basis:100%; font-size:12px; color:var(--muted); }
.rrev .wa-captcha{ flex-basis:100%; }
.rrev .wa-captcha p{ display:flex; align-items:center; gap:10px; margin:0; }
.rrev .wa-captcha p + p{ margin-top:5px; }
.rrev .wa-captcha .wa-captcha-img{ border-radius:8px; }
.rrev .wa-captcha strong{ color:var(--muted); font-weight:400; }
.rrev .wa-captcha input, .rrev .wa-captcha input[type=text]{ width:180px; flex:0 0 auto;
  min-height:42px; padding:9px 13px; border:1.5px solid var(--line);
  border-radius:var(--r-sm); font-family:var(--ff-ui); font-size:14px;
  transition:border-color .15s ease, box-shadow .15s ease; }
.rrev .wa-captcha input:focus{ outline:none; border-color:var(--peri);
  box-shadow:0 0 0 3px rgba(115,142,200,.18); }
.rrev .wa-captcha-refresh{ font-size:12px; color:var(--muted); text-decoration:underline; }
.rrev .wa-captcha-refresh:hover{ color:var(--slate); }
/* ajax loading dots */
.rrev .ajax-status i{ display:inline-block; width:7px; height:7px; margin:0 2px;
  border-radius:50%; background:var(--peri); animation:rrev-dot 1s infinite ease-in-out; }
.rrev .ajax-status i.b{ animation-delay:.15s; }
.rrev .ajax-status i.c{ animation-delay:.3s; }
@keyframes rrev-dot{ 0%,80%,100%{ opacity:.25; } 40%{ opacity:1; } }

/* ---- reviews list ---- */
.rrev__empty{ margin-top:18px; font-size:14px; color:var(--muted); }
.rrev .reviews-list{ list-style:none; margin:0; padding:0; }
.rrev .reviews-list_main-branch{ margin-top:18px; }
.rrev .reviews-list_main-branch > .reviews-list__content-block{ margin-top:12px; }
.rrev .reviews-list_main-branch > .reviews-list__content-block > .review{
  background:#fff; border-radius:var(--r-card); box-shadow:var(--sh-sm); }
/* nested replies: indented thread line inside the parent card flow */
.rrev .reviews-branch .reviews-branch{ margin:0 0 0 22px; padding-left:14px;
  border-left:2px solid var(--blue-bg2); }
.rrev .review{ padding:16px 18px; border-radius:var(--r-sm); }
.rrev .reviews-branch .reviews-branch .review{ background:none; box-shadow:none; padding:12px 0 4px; }
.rrev .review.in-reply-to{ box-shadow:0 0 0 2px var(--peri); }
.rrev .review.new{ animation:rrev-new 1.6s ease; }
@keyframes rrev-new{ 0%{ background:#FDF3D0; } 100%{ background:#fff; } }

.rrev .reviews-list__content-title{ font-size:15px; font-weight:700; color:var(--ink); margin:8px 0 0; }
.rrev .reviews-list__content-author{ display:flex; flex-wrap:wrap; align-items:baseline; gap:6px 10px; }
.rrev .reviews-list__content-name{ font-size:13.5px; font-weight:700; color:var(--slate); }
.rrev .reviews-list__content-site{ font-size:12px; color:var(--muted); }
.rrev .reviews-list__content-staff{ font-size:10.5px; font-weight:700; padding:3px 9px;
  border-radius:var(--r-pill); background:var(--blue-bg); color:var(--slate); }
.rrev .reviews-list__content-date{ font-size:12px; color:var(--muted); }
.rrev .reviews-list__content-rating{ margin-top:6px; }
.rrev .rating{ display:inline-flex; gap:2px; }
.rrev .rating .icon10{ font-size:15px; color:var(--line); }
.rrev .rating .icon10.star{ color:var(--star); }
.rrev .rating .icon10.star-half::before{
  background:linear-gradient(90deg, var(--star) 50%, var(--line) 50%);
  -webkit-background-clip:text; background-clip:text; color:transparent; }
.rrev .reviews-list__content-text{ margin-top:8px; font-size:14px; line-height:1.55;
  color:var(--ink); overflow-wrap:break-word; }
.rrev .actions{ margin-top:8px; }
.rrev .review-reply{ font-size:12.5px; font-weight:600; color:var(--muted); }
.rrev .review-reply:hover{ color:var(--slate); }
.rrev .review-reply .review-reply_collapse{ display:none; }
.rrev .review-reply.active .review-reply_expand{ display:none; }
.rrev .review-reply.active .review-reply_collapse{ display:inline; }

/* ---- pagination (parent theme inc/pagination.html: .paging-nav a + div.p) ---- */
.rrev + .pagination, .rrev .pagination{ margin:22px auto 0; max-width:860px; padding:0 16px; }
.rrev .paging-nav{ display:flex; flex-wrap:wrap; justify-content:center; gap:6px; }
.rrev .paging-nav a, .rrev .paging-nav .p{ display:grid; place-items:center; min-width:38px;
  height:38px; padding:0 8px; border-radius:12px; font-family:var(--ff-num); font-size:14px;
  font-weight:700; }
.rrev .paging-nav a{ background:#fff; color:var(--slate); box-shadow:var(--sh-sm); }
.rrev .paging-nav a:hover{ background:var(--blue-bg2); }
.rrev .paging-nav .p{ background:var(--slate); color:#fff; }

/* ---- mobile ---- */
@media (max-width: 640px){
  .rrev h1.title{ font-size:19px; }
  .rrev__product{ padding:14px; gap:12px; flex-wrap:wrap; }
  .rrev__cover img{ width:72px; }
  /* cover + count side by side; meta table and CTA drop to full card width */
  .rrev__product-info{ display:contents; }
  .rrev__count{ flex:1 1 0; min-width:0; }
  .rrev dl.rrev__meta{ flex-basis:100%; margin-top:0; }
  .rrev__more{ margin-top:0; }
  .rrev__meta-row dt{ flex-basis:96px; }
  .rrev__grid{ grid-template-columns:1fr; }
  .rrev .review-form{ padding:14px; }
  .rrev .review{ padding:13px 14px; }
  .rrev .reviews-branch .reviews-branch{ margin-left:10px; padding-left:10px; }
  .rrev__add{ width:100%; }
  .rrev__submit{ width:100%; }
}

/* ---- dark theme ---- */
html.rd-dark .rrev__product,
html.rd-dark .rrev .review-form,
html.rd-dark .rrev .reviews-list_main-branch > .reviews-list__content-block > .review,
html.rd-dark .rrev .paging-nav a{ background:#1B2330; box-shadow:none;
  border:1px solid rgba(255,255,255,.07); }
html.rd-dark .rrev h1.title, html.rd-dark .rrev__count,
html.rd-dark .rrev .reviews-list__content-title,
html.rd-dark .rrev .reviews-list__content-text{ color:#E7ECF4; }
html.rd-dark .rrev__count a, html.rd-dark .rrev .reviews-list__content-name,
html.rd-dark .rrev .paging-nav a{ color:#C9D4E6; }
html.rd-dark .rrev__meta-row:nth-child(odd){ background:rgba(255,255,255,.05); }
html.rd-dark .rrev__meta-row dd{ color:#C9D4E6; }
html.rd-dark .rrev__more, html.rd-dark .rrev .reviews-list__content-staff,
html.rd-dark .rrev .wa-auth-adapters__link{ background:rgba(255,255,255,.08); color:#C9D4E6; }
html.rd-dark .rrev .wa-value input[type=text],
html.rd-dark .rrev .wa-value input[type=email],
html.rd-dark .rrev .wa-value textarea,
html.rd-dark .rrev .wa-captcha input{ background:#141A24; border-color:rgba(255,255,255,.12); color:#E7ECF4; }
html.rd-dark .rrev .rate .icon16, html.rd-dark .rrev .rating .icon10{ color:rgba(255,255,255,.18); }
html.rd-dark .rrev .rate .icon16.star, html.rd-dark .rrev .rating .icon10.star{ color:var(--star); }
html.rd-dark .rrev .reviews-branch .reviews-branch{ border-left-color:rgba(255,255,255,.12); }
html.rd-dark .rrev .review.new{ animation:none; }
html.rd-dark .rrev .paging-nav .p{ background:var(--peri); color:#141A24; }
