/* ==========================================
   MTERMS2026 Reviewer Network Popup CSS
   Icon styled to match AI widget
   ========================================== */

/* Floating Button - same style as AI */
.rn-float-btn{
  position: fixed;
  bottom: 125px;       /* sits directly above AI button */
  right: 30px;
  width: 60px;
  height: 60px;
  background: #ffffff;
  border: none;
  border-radius: 50%;
  cursor: pointer;
  box-shadow: 0 6px 18px rgba(0,0,0,0.18);
  z-index: 10000;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}

.rn-float-btn:hover{
  transform: scale(1.08);
  box-shadow: 0 10px 24px rgba(0,0,0,0.25);
}

.rn-float-btn img{
  width: 44px;
  height: 44px;
  object-fit: contain;
  pointer-events: none;
  display: block;
}

/* Popup Backdrop */
.rn-backdrop{
  position:fixed;
  inset:0;
  z-index:10001;
  background:rgba(2,8,23,.48);
  backdrop-filter:blur(5px);
  display:none;
  align-items:center;
  justify-content:center;
  padding:18px;
}

.rn-backdrop.rn-show{
  display:flex;
}

/* Popup Modal */
.rn-modal{
  width:min(720px,100%);
  max-height:90vh;
  overflow:auto;
  background:#ffffff;
  color:#0b1220;
  border-radius:26px;
  box-shadow:0 30px 90px rgba(2,8,23,.34);
  border:1px solid rgba(255,255,255,.40);
  animation:rnPop .22s ease-out;
}

@keyframes rnPop{
  from{
    opacity:0;
    transform:translateY(10px) scale(.98);
  }
  to{
    opacity:1;
    transform:translateY(0) scale(1);
  }
}

.rn-modal-head{
  position:relative;
  padding:26px 28px 18px;
  background:
    radial-gradient(700px 240px at 12% 0%, rgba(47,123,220,.18), transparent 60%),
    radial-gradient(700px 240px at 88% 0%, rgba(14,165,166,.16), transparent 60%),
    linear-gradient(135deg,#f8fcff,#eef8ff);
  border-bottom:1px solid rgba(15,23,42,.10);
}

.rn-close{
  position:absolute;
  top:16px;
  right:16px;
  width:36px;
  height:36px;
  border-radius:999px;
  border:1px solid rgba(15,23,42,.12);
  background:#ffffff;
  cursor:pointer;
  font-size:1.2rem;
  font-weight:900;
  line-height:1;
  color:#334155;
}

.rn-kicker{
  display:inline-flex;
  align-items:center;
  gap:8px;
  background:#ffffff;
  border:1px solid rgba(30,90,168,.16);
  border-radius:999px;
  padding:7px 11px;
  color:#1e5aa8;
  font-weight:900;
  font-size:.84rem;
  margin-bottom:13px;
}

.rn-modal h2{
  margin:0;
  font-size:clamp(1.45rem,3vw,2.05rem);
  line-height:1.08;
  letter-spacing:-.03em;
}

.rn-modal-body{
  padding:22px 28px 26px;
}

.rn-modal-body h3{
  margin:0 0 12px;
  font-size:1.2rem;
  color:#0B2A6B;
}

.rn-modal-body p{
  margin:0 0 13px;
  color:#334155;
  line-height:1.62;
  font-size:1rem;
}

.rn-benefit-row{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:10px;
  margin:16px 0 18px;
}

.rn-benefit{
  border:1px solid rgba(15,23,42,.10);
  background:#f9fafb;
  border-radius:16px;
  padding:12px;
}

.rn-benefit strong{
  display:block;
  font-size:.9rem;
  margin-bottom:4px;
}

.rn-benefit span{
  display:block;
  font-size:.82rem;
  color:#667085;
  line-height:1.4;
}

.rn-actions{
  display:flex;
  gap:10px;
  flex-wrap:wrap;
  margin-top:18px;
}

.rn-btn{
  border:none;
  border-radius:999px;
  padding:11px 16px;
  font-weight:900;
  cursor:pointer;
  text-decoration:none;
  display:inline-flex;
  align-items:center;
  justify-content:center;
}

.rn-btn-primary{
  background:linear-gradient(135deg,#1e5aa8,#0ea5a6);
  color:#ffffff;
  box-shadow:0 14px 34px rgba(30,90,168,.22);
}

.rn-btn-secondary{
  background:#ffffff;
  color:#111827;
  border:1px solid rgba(15,23,42,.14);
}

.rn-small{
  margin-top:14px;
  color:#667085;
  font-size:.84rem;
  line-height:1.45;
}

/* Mobile */
@media(max-width:700px){
  .rn-float-btn{
    bottom: 125px;
    right: 30px;
    width: 60px;
    height: 60px;
  }

  .rn-float-btn img{
    width: 44px;
    height: 44px;
  }

  .rn-modal{
    border-radius:22px;
  }

  .rn-modal-head,
  .rn-modal-body{
    padding-left:20px;
    padding-right:20px;
  }

  .rn-benefit-row{
    grid-template-columns:1fr;
  }

  .rn-actions{
    flex-direction:column;
  }

  .rn-btn{
    width:100%;
  }
}
