:root{
  --cg-green:#5b8d76;
  --cg-ink:#16221c;
  --cg-muted:#5b6b61;
  --cg-line:#e8eee9;
  --cg-bg:#ffffff;
  --cg-soft:#f6f8f6;
  --cg-gold:#f4b400;
  --cg-radius:18px;
  --cg-font: system-ui,-apple-system,Segoe UI,Roboto,Inter,Arial,sans-serif;
  --cg-serif: "Playfair Display", Georgia, serif;
}

.cgpr-wrap{ font-family: var(--cg-font); color: var(--cg-ink); }
.cgpr-h2,.cgpr-h3{ font-family: var(--cg-serif); color: var(--cg-green); margin:0; }
.cgpr-h2{ font-size:28px; }
.cgpr-h3{ font-size:22px; }

.cgpr-count-link{
  color: var(--cg-green);
  font-weight: 700;
  text-decoration: none;
  border-bottom: 1px dotted rgba(91,141,118,.45);
}
.cgpr-count-link:hover{ opacity:.88; }

.cgpr-summary{
  display:flex; justify-content:space-between; align-items:center;
  gap: 14px;
  max-width: 980px;
  margin: 0 auto;
}
.cgpr-center{ justify-content:center; text-align:center; }
.cgpr-center-title{ text-align:center; width:100%; }
.cgpr-center-score{ justify-content:center; }

.cgpr-score{ display:flex; gap: 10px; align-items:center; flex-wrap:wrap; margin-top: 10px; color: var(--cg-muted); justify-content:flex-start; }
.cgpr-score-num{ font-size: 34px; font-weight: 800; color: var(--cg-ink); }
.cgpr-stars-inline{ display:inline-flex; gap:3px; }
.cgpr-star-inline{ font-size: 16px; }
.cgpr-star-inline.is-on{ color: var(--cg-gold); }
.cgpr-star-inline.is-off{ color: #c6cec9; }
.cgpr-score-count{ color: var(--cg-muted); }

.cgpr-btn{
  background: var(--cg-green);
  color: #fff;
  border: none;
  border-radius: 999px;
  padding: 12px 18px;
  font-weight: 800;
  cursor: pointer;
}
.cgpr-btn:active{ transform: translateY(1px); }
.cgpr-ico{ margin-right: 8px; opacity:.9; }

.cgpr-strip{ margin: 14px auto 18px; display:flex; gap:10px; overflow:auto; padding-bottom: 6px; max-width: 980px; justify-content:center; }
.cgpr-thumb{ display:block; width: 88px; height: 60px; border-radius: 12px; overflow:hidden; border:1px solid var(--cg-line); background: var(--cg-soft); flex: 0 0 auto; }
.cgpr-thumb img{ width:100%; height:100%; object-fit: cover; }

.cgpr-toolbar{ max-width: 980px; margin: 10px auto 14px; }
.cgpr-toolbar-row{ display:flex; justify-content:center; }
.cgpr-sort{ display:flex; gap: 10px; align-items:center; color: var(--cg-muted); }
.cgpr-sort select{ border:1px solid var(--cg-line); border-radius: 999px; padding: 9px 12px; background: #fff; }

.cgpr-ajax-status{
  max-width: 980px;
  margin: 0 auto;
  min-height: 18px;
  color: var(--cg-muted);
  font-weight: 650;
  text-align:center;
}

.cgpr-list{ max-width: 980px; margin: 0 auto; }
.cgpr-compact .cgpr-review{ padding: 14px 0; }
.cgpr-review{ display:grid; grid-template-columns: 46px 1fr; gap: 12px; border-top: 1px solid var(--cg-line); }
.cgpr-avatar{
  width:46px; height:46px; border-radius: 999px;
  background: rgba(91,141,118,.12); color: var(--cg-green);
  font-weight: 900; display:flex; align-items:center; justify-content:center;
  font-size: 14px;
  margin-top: 2px;
}
.cgpr-review-top{ display:flex; justify-content:space-between; gap: 10px; align-items:flex-start; }
.cgpr-review-author{ display:flex; gap: 10px; align-items:center; flex-wrap:wrap; }
.cgpr-name{ font-weight: 850; }
.cgpr-badge{ font-size: 12px; padding: 5px 10px; border-radius: 999px; background: rgba(91,141,118,.12); color: var(--cg-green); font-weight: 850; }
.cgpr-date{ color: var(--cg-muted); font-size: 13px; white-space:nowrap; }
.cgpr-title{ margin: 8px 0 0; font-size: 15px; font-weight: 900; }
.cgpr-body{ color: #233028; }
.cgpr-media{ display:flex; gap:10px; flex-wrap:wrap; margin-top: 10px; }
.cgpr-media-item{ width: 96px; height: 72px; border-radius: 12px; overflow:hidden; border:1px solid var(--cg-line); background: var(--cg-soft); display:block; }
.cgpr-media-item img{ width:100%; height:100%; object-fit: cover; }
.cgpr-media-video{ width:auto; height:auto; padding: 10px 12px; text-decoration:none; color: var(--cg-green); font-weight: 800; }

.cgpr-reply{ margin-top: 10px; border-left: 3px solid rgba(91,141,118,.35); background: rgba(91,141,118,.06); border-radius: 12px; padding: 12px; }
.cgpr-reply-head{ font-weight: 900; color: var(--cg-green); margin-bottom: 6px; }
.cgpr-empty{ padding: 18px; border:1px dashed var(--cg-line); border-radius: var(--cg-radius); background: var(--cg-soft); color: var(--cg-muted); text-align:center; }

.cgpr-pagination{ max-width: 980px; margin: 14px auto 0; display:flex; justify-content:center; }
.cgpr-pager{ display:flex; gap: 12px; align-items:center; }
.cgpr-page-btn{
  border:1px solid rgba(91,141,118,.35);
  background:#fff;
  color: var(--cg-green);
  font-weight: 800;
  padding: 10px 14px;
  border-radius: 999px;
  cursor:pointer;
}
.cgpr-page-btn[disabled]{ opacity:.45; cursor:not-allowed; }
.cgpr-page-info{ color: var(--cg-muted); font-weight: 700; }

/* MODAL */
.cgpr-modal[hidden]{ display:none !important; }
.cgpr-modal{
  position: fixed;
  inset: 0;
  z-index: 2147483647 !important;
  pointer-events: auto !important;
}
.cgpr-modal *{ pointer-events:auto !important; }

.cgpr-modal-backdrop{
  position:absolute; inset:0;
  background: rgba(0,0,0,.40);
}
.cgpr-modal-card{
  position:relative;
  width: min(680px, calc(100% - 28px));
  margin: 6vh auto;
  background: #fff;
  border-radius: 18px;
  border: 1px solid rgba(0,0,0,.06);
  box-shadow: 0 18px 50px rgba(0,0,0,.22);
  padding: 18px 18px 16px;
}
.cgpr-modal-close{
  position:absolute;
  right: 10px; top: 10px;
  width: 42px; height: 42px;
  border-radius: 999px;
  border: 1px solid rgba(0,0,0,.08);
  background:#fff;
  cursor:pointer;
  font-size: 22px;
  line-height: 1;
}
.cgpr-form-head{ margin-bottom: 12px; }
.cgpr-sub{ margin: 6px 0 0; color: var(--cg-muted); font-size: 14px; }

.cgpr-field{ margin: 14px 0; text-align:left; }
.cgpr-label{ display:block; font-weight: 700; margin-bottom: 8px; }
.cgpr-input,.cgpr-textarea{
  width:100%;
  border:1px solid var(--cg-line);
  border-radius: 14px;
  padding: 12px 14px;
  font-size: 15px;
  outline: none;
  background: #fff;
}
.cgpr-input:focus,.cgpr-textarea:focus{ border-color: rgba(91,141,118,.6); box-shadow: 0 0 0 4px rgba(91,141,118,.12); }

.cgpr-grid{ display:grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 720px){ .cgpr-grid{ grid-template-columns: 1fr; } }

.cgpr-stars{ display:flex; gap: 6px; align-items:center; }
.cgpr-star{
  border:1px solid var(--cg-line);
  background: #fff;
  width: 44px; height: 44px;
  border-radius: 14px;
  cursor: pointer;
  display:flex; align-items:center; justify-content:center;
  transition: transform .08s ease, border-color .12s ease, background .12s ease;
  font-size: 20px;
  color: #c6cec9;
}
.cgpr-star:hover{ transform: translateY(-1px); border-color: rgba(91,141,118,.55); }
.cgpr-star.is-on{ color: var(--cg-gold); border-color: rgba(244,180,0,.45); background: rgba(244,180,0,.08); }
.cgpr-rating-help{ display:none; }
.cgpr-rating-help.is-show{ display:block; color:#b00020; margin-top:8px; font-size: 13px; }

.cgpr-help{ color: var(--cg-muted); font-size: 13px; margin-top: 6px; }
.cgpr-previews{ display:flex; gap:10px; flex-wrap:wrap; margin-top:10px; }
.cgpr-preview{
  width:64px; height:64px;
  border-radius: 12px;
  border:1px solid var(--cg-line);
  overflow:hidden;
  background: var(--cg-soft);
  display:flex; align-items:center; justify-content:center;
}
.cgpr-preview img{ width:100%; height:100%; object-fit:cover; }

/* Lock scroll behind modal */
html.cgpr-modal-open, html.cgpr-modal-open body{
  overflow:hidden !important;
  height:100%;
}
