.rch-area-section .rch-area-manage-row{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:8px;
  margin-top:8px;
}

.rch-area-editor{
  position:absolute;
  z-index:1250;
  top:72px;
  right:14px;
  width:min(390px,calc(100% - 28px));
  max-height:calc(100% - 86px);
  overflow:auto;
  padding:16px;
  border-radius:16px;
  background:rgba(255,255,255,.98);
  box-shadow:0 18px 50px rgba(15,23,42,.24);
  backdrop-filter:blur(14px);
}

.rch-area-editor[hidden]{
  display:none!important;
}

.rch-area-editor__header{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:12px;
  margin-bottom:14px;
}

.rch-area-editor__header h2{
  margin:2px 0 4px;
  font-size:18px;
}

.rch-area-editor__subtitle{
  margin:0;
  color:#64748b;
  font-size:12px;
  line-height:1.45;
}

.rch-area-editor__field{
  display:grid;
  gap:6px;
  margin-bottom:12px;
}

.rch-area-editor__field>span{
  font-size:12px;
  font-weight:700;
  color:#334155;
}

.rch-area-editor__state{
  display:grid;
  gap:3px;
  padding:11px 12px;
  margin-bottom:12px;
  border:1px solid #dbe4f0;
  border-radius:12px;
  background:#f8fafc;
}

.rch-area-editor__state strong{
  font-size:13px;
}

.rch-area-editor__state span,
.rch-area-editor__state small{
  color:#64748b;
  font-size:11px;
}

.rch-area-editor__review{
  display:grid;
  gap:9px;
  margin-bottom:12px;
  padding:11px 12px;
  border:1px solid #dbe4f0;
  border-radius:12px;
  background:#fff;
}

.rch-area-editor__review-head{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:10px;
}

.rch-area-editor__review-head>div{
  display:grid;
  gap:2px;
  min-width:0;
}

.rch-area-editor__review-head strong{
  font-size:12px;
}

.rch-area-editor__review-head span{
  color:#64748b;
  font-size:10px;
}

.rch-area-editor__reference-link{
  flex:0 0 auto;
  font-size:10px;
  font-weight:700;
  color:#075bd8;
  text-decoration:none;
}

.rch-area-editor__reference-link:hover,
.rch-area-editor__reference-link:focus-visible{
  text-decoration:underline;
}

.rch-area-editor__review progress{
  width:100%;
  height:7px;
  border:0;
  border-radius:999px;
  overflow:hidden;
  background:#e8eef7;
  accent-color:#1570ef;
}

.rch-area-editor__review progress::-webkit-progress-bar{
  background:#e8eef7;
  border-radius:999px;
}

.rch-area-editor__review progress::-webkit-progress-value{
  background:#1570ef;
  border-radius:999px;
}

.rch-area-editor__review progress::-moz-progress-bar{
  background:#1570ef;
  border-radius:999px;
}

.rch-area-editor__review-note{
  margin:0;
  color:#64748b;
  font-size:10px;
  line-height:1.45;
}

.rch-area-editor__official-toggle,
.rch-area-editor__legacy-toggle{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
  min-width:0;
  padding:8px 9px;
  border:1px solid #e2e8f0;
  border-radius:9px;
  background:#f8fafc;
  cursor:pointer;
}

.rch-area-editor__official-toggle{
  border-color:#bfdbeb;
  background:#f6fbfe;
}

.rch-area-editor__official-toggle>span,
.rch-area-editor__legacy-toggle>span{
  display:grid;
  gap:2px;
  min-width:0;
}

.rch-area-editor__official-toggle strong,
.rch-area-editor__legacy-toggle strong{
  color:#334155;
  font-size:10px;
}

.rch-area-editor__official-toggle small,
.rch-area-editor__legacy-toggle small{
  color:#64748b;
  font-size:9px;
  line-height:1.3;
}

.rch-area-editor__official-toggle input,
.rch-area-editor__legacy-toggle input{
  flex:0 0 auto;
  width:18px;
  height:18px;
  margin:0;
}

.rch-area-editor__official-legend,
.rch-area-editor__legacy-legend{
  display:flex;
  align-items:flex-start;
  gap:7px;
  color:#64748b;
  font-size:9px;
  line-height:1.35;
}

.rch-area-editor__official-legend i{
  display:inline-block;
  flex:0 0 auto;
  width:14px;
  height:0;
  margin-top:5px;
  border-top:2px dashed #0b6fa4;
}

.rch-area-editor__legacy-legend i{
  display:inline-block;
  flex:0 0 auto;
  width:8px;
  height:8px;
  margin-top:2px;
  border:2px solid #b54708;
  border-radius:50%;
  background:transparent;
  box-sizing:border-box;
}

.rch-area-editor__review-list{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:6px;
}

.rch-area-editor__review-item{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:7px;
  min-width:0;
  padding:7px 8px;
  border:1px solid #e2e8f0;
  border-radius:9px;
  background:#f8fafc;
  color:#1e293b;
  text-align:left;
  cursor:pointer;
}

.rch-area-editor__review-item:hover,
.rch-area-editor__review-item:focus-visible{
  border-color:#9fc2f4;
  background:#f3f8ff;
}

.rch-area-editor__review-item.is-selected{
  border-color:#82aff0;
  background:#eef6ff;
}

.rch-area-editor__review-item>span{
  display:grid;
  gap:1px;
  min-width:0;
}

.rch-area-editor__review-copy{
  display:grid;
  gap:2px;
  min-width:0;
}

.rch-area-editor__review-kicker{
  display:flex;
  align-items:center;
  gap:5px;
  min-width:0;
}

.rch-area-editor__review-kicker b{
  flex:0 0 auto;
  padding:2px 4px;
  border-radius:999px;
  background:#e8eef8;
  color:#475569;
  font-size:8px;
  line-height:1;
}

.rch-area-editor__review-kicker i{
  overflow:hidden;
  color:#9a3412;
  font-size:8px;
  font-style:normal;
  font-weight:700;
  line-height:1.1;
  text-overflow:ellipsis;
  white-space:nowrap;
}

.rch-area-editor__review-evidence{
  color:#475569!important;
  font-size:8px!important;
}

.rch-area-editor__review-item strong{
  font-size:10px;
  line-height:1.2;
}

.rch-area-editor__review-item small{
  overflow:hidden;
  color:#64748b;
  font-size:9px;
  line-height:1.2;
  text-overflow:ellipsis;
  white-space:nowrap;
}

.rch-area-editor__review-item em{
  flex:0 0 auto;
  padding:3px 5px;
  border-radius:999px;
  font-size:9px;
  font-style:normal;
  font-weight:700;
}

.rch-area-editor__review-item em[data-state="saved"]{
  background:#ecfdf3;
  color:#067647;
}

.rch-area-editor__review-item em[data-state="missing"]{
  background:#fff7ed;
  color:#b54708;
}

.rch-area-editor__review>#rchAreaEditorNextMissingBtn{
  width:100%;
  min-width:0;
  white-space:normal;
}

.rch-area-editor__actions{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:8px;
}

.rch-area-editor__actions .btn{
  min-width:0;
  white-space:normal;
  line-height:1.25;
}

.rch-area-editor__notice{
  margin:12px 0;
  padding:10px 12px;
  border-radius:10px;
  background:#eef6ff;
  color:#334155;
  font-size:11px;
  line-height:1.45;
}

.rch-area-editor__preview{
  display:grid;
  gap:10px;
}

.rch-area-editor__preview-title{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:8px;
}

.rch-area-editor__preview-title strong{
  font-size:13px;
}

.rch-area-editor__preview-title span{
  color:#64748b;
  font-size:10px;
  text-align:right;
}

.rch-area-editor__metrics{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:8px;
}

.rch-area-editor__metric{
  min-width:0;
  padding:9px 10px;
  border:1px solid #e2e8f0;
  border-radius:10px;
  background:#fff;
}

.rch-area-editor__metric strong{
  display:block;
  font-size:16px;
  line-height:1.15;
}

.rch-area-editor__metric span{
  display:block;
  margin-top:3px;
  color:#64748b;
  font-size:10px;
  line-height:1.25;
}

.rch-area-editor__metric.primary{
  border-color:#b9d5ff;
  background:#f3f8ff;
}

.rch-area-editor__metric.warning{
  border-color:#f7d794;
  background:#fffaf0;
}

.rch-area-editor__metric.danger{
  border-color:#fecaca;
  background:#fff5f5;
}

.rch-area-editor__conflicts{
  display:grid;
  gap:6px;
  padding-top:4px;
}

.rch-area-editor__conflicts>strong{
  font-size:11px;
}

.rch-area-editor__conflicts>div{
  display:flex;
  justify-content:space-between;
  gap:10px;
  padding:7px 0;
  border-top:1px solid #eef2f7;
  font-size:10px;
}

.rch-area-editor__conflicts span{
  min-width:0;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}

.rch-area-editor__conflicts small{
  color:#b42318;
  flex:0 0 auto;
}

@media (max-width:900px){
  .rch-area-editor{
    top:auto;
    right:10px;
    bottom:76px;
    left:10px;
    width:auto;
    max-height:min(68vh,620px);
    border-radius:16px;
  }

  .rch-area-editor__actions{
    grid-template-columns:1fr 1fr;
  }
}

@media (max-width:430px){
  .rch-area-editor{
    padding:13px;
  }

  .rch-area-editor__metrics{
    grid-template-columns:1fr 1fr;
  }

  .rch-area-editor__actions{
    grid-template-columns:1fr;
  }

  .rch-area-editor__review-list{
    grid-template-columns:1fr;
  }

  .rch-area-editor__review-head{
    align-items:flex-start;
  }
}


.rch-area-editor__scope-gate{
  display:grid;
  gap:3px;
  padding:9px 10px;
  border:1px solid #d0d5dd;
  border-radius:10px;
  background:#f8fafc;
  color:#344054;
  font-size:10px;
  line-height:1.3;
}

.rch-area-editor__scope-gate strong{
  font-size:10px;
}

.rch-area-editor__scope-gate span{
  color:#667085;
  font-size:9px;
}

.rch-area-editor__scope-gate[data-state="approved"]{
  border-color:#a6f4c5;
  background:#ecfdf3;
}

.rch-area-editor__scope-gate[data-state="approved"] strong{
  color:#027a48;
}

.rch-area-editor__scope-gate[data-state="blocked"],
.rch-area-editor__scope-gate[data-state="unavailable"]{
  border-color:#fedf89;
  background:#fffaeb;
}

.rch-area-editor__scope-gate[data-state="blocked"] strong,
.rch-area-editor__scope-gate[data-state="unavailable"] strong{
  color:#b54708;
}
