:root{
  --mgr-accent:#1d3a6b;
  --mgr-star:#fbbc05;
  --mgr-radius:16px;
  --mgr-card-min-h:260px;
  --mgr-container-w:1440px;
}

/* Container width (NOT full width) */
.mgr-wrap{
  width:100%;
  max-width:var(--mgr-container-w);
  margin:0 auto;
  padding:44px 18px 30px;
  font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Inter,Arial,sans-serif;
  color:#202124;
  box-sizing:border-box;
}
.mgr-wrap *{ box-sizing:border-box; }

/* Header */
.mgr-header{
  background:#fff;
  border:1px solid #eef0f1;
  border-radius:14px;
  padding:22px 22px 18px;
  box-shadow:0 1px 0 rgba(0,0,0,.03);
  margin-bottom:28px;
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:16px;
}

.mgr-logo-title{
  display:flex;
  align-items:center;
  gap:10px;
}
.mgr-google-logo{ height:30px !important; width:auto; }
.mgr-title{ font-weight:600; font-size:20px; }

/* Score */
.mgr-score{
  display:flex;
  align-items:center;
  gap:10px;
  margin-top:4px;
}
.mgr-avg{
  font-size:22px;
  font-weight:700;
  line-height:1;
}
.mgr-stars{
  color:var(--mgr-star);
  font-size:22px;
  letter-spacing:2px;
  line-height:1;
}
.mgr-total{ color:#70757a; font-size:14px; }

/* Top right button */
.mgr-btn{
  background:var(--mgr-accent);
  color:#fff;
  text-decoration:none;
  border-radius:999px;
  padding:12px 20px;
  font-weight:500;
  font-size:15px;
  line-height:1;
  white-space:nowrap;
  box-shadow:0 10px 20px rgba(0,0,0,.10);
  transition:transform .2s ease, box-shadow .2s ease;
  align-self:flex-start;
}
.mgr-btn:hover{
  transform:translateY(-1px);
  box-shadow:0 14px 26px rgba(0,0,0,.14);
  color:white !important;
}
.mgr-btn:active, .mgr-btn:focus{
    color:white !important;
}

/* Slider wrapper */
.mgr-swiper{
  width:100%;
  position:relative;
  overflow:visible; /* arrows not clipped */
}

/* Equal-height slides */
.mgr-swiper .swiper-wrapper{ align-items:stretch; }
.mgr-swiper .swiper-slide{ height:auto; display:flex; }
.mgr-swiper .swiper-slide > *{ width:100%; }

/* Card */
.mgr-card{
  background:#fff;
  border-radius:var(--mgr-radius);
  padding:22px;
  border:1px solid #eef0f1;
  height:100%;
  min-height:var(--mgr-card-min-h);
  display:flex;
  flex-direction:column;
}

/* Card Header */
.mgr-card-header{
  display:flex;
  gap:12px;
  align-items:center;
  margin-bottom:12px;
}

/* Avatar (IMPORTANT: allow overlay) */
.mgr-avatar{
  position:relative;
  width:56px;
  height:56px;
  border-radius:999px;
  background:#e8eaed;
  display:flex;
  align-items:center;
  justify-content:center;
  overflow:visible; /* <-- so g-small can sit outside */
  flex:0 0 auto;
}

.mgr-avatar span{
  font-weight:800;
  font-size:22px;
  color:#1f1f1f;
}
.mgr-avatar img{
  width:56px;
  height:56px;
  border-radius:999px;
  object-fit:cover;
}

/* Small G overlay */
.mgr-gsmall{
  position:absolute;
  right:-2px;
  bottom:-2px;
  width:22px !important;
  height:22px !important;
  z-index:6;
  pointer-events:none;
  display:block;
  max-width:none !important;
}

/* Meta */
.mgr-meta{ flex:1; min-width:0; }
.mgr-nameRow{
  display:flex;
  align-items:center;
  gap:8px;
  min-width:0;
}

/* Name */
.mgr-author-name{
  font-weight:800;
  font-size:16px;
  color:#202124;
  text-decoration:none;
  display:inline-block;
  max-width:100%;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}
.mgr-author-name:hover{ text-decoration:underline; }

.mgr-verifiedName{
  width:18px;
  height:18px;
  flex:0 0 auto;
  margin-top:1px;
}

.mgr-time{
  color:#8a8d91;
  font-size:14px;
  margin-top:-5px;
}

/* Rating */
.mgr-rating{
  color:var(--mgr-star);
  font-size:18px;
  letter-spacing:2px;
  margin:8px 0 12px;
}

/* Text clamp */
.mgr-text{
  flex:1 1 auto;
  display:flex;
  flex-direction:column;
  font-size:16px;
  line-height:1.6;
  color:#202124;

  display:-webkit-box;
  -webkit-line-clamp:5;
  -webkit-box-orient:vertical;
  overflow:hidden;
}

.mgr-readmore{
  display:inline-block;
  margin-top:10px;
  border:0;
  background:transparent;
  color:var(--mgr-accent);
  font-weight:700;
  cursor:pointer;
  padding:0;
  align-self:flex-start;
}

/* Arrows */
.mgr-arrows{ pointer-events:none; }
.mgr-arrow{
  pointer-events:auto;
  position:absolute;
  top:50%;
  transform:translateY(-50%);
  width:44px;
  height:44px;
  border-radius:999px;
  border:0;
  background:rgba(0,0,0,.45);
  color:#fff;
  cursor:pointer;
  display:flex;
  align-items:center;
  justify-content:center;
  z-index:20;
  font-size:28px;
  line-height:1;
}
.mgr-prev{ left:10px; }
.mgr-next{ right:10px; }

/* Pagination */
.mgr-pagination{
  bottom:-28px !important;
  display:flex;
  justify-content:center;
  flex-wrap:nowrap;
  gap:8px;
}

.mgr-pagination .swiper-pagination-bullet{
  width:8px;
  height:8px;
  opacity:.25;
  background:#202124;
}
.mgr-pagination .swiper-pagination-bullet-active{ opacity:1; }

.mgr-pagination.swiper-pagination-fraction{
  font-size:14px;
  color:#70757a;
}

/* Mobile header stack */
@media (max-width:700px){
  .mgr-header{ flex-direction:column; align-items:flex-start; }
  .mgr-btn{ margin-top:10px; }
}

/* Modal */
.mgr-modal{
  display:none;
  position:fixed;
  inset:0;
  background:rgba(0,0,0,.65);
  z-index:999999;
  align-items:center;
  justify-content:center;
  padding:18px;
}
.mgr-modal__dialog{
  background:#fff;
  width:min(760px,100%);
  border-radius:18px;
  padding:22px 22px 18px;
  box-shadow:0 30px 80px rgba(0,0,0,.35);
  position:relative;
  max-height:86vh;
  overflow:auto;
}
.mgr-modal__close{
  position:absolute;
  top:10px;
  right:12px;
  border:0;
  background:transparent;
  font-size:34px;
  cursor:pointer;
  color:#5f6368;
}
.mgr-modal__head{
  display:flex;
  gap:14px;
  align-items:center;
  margin-bottom:12px;
}
.mgr-modal__avatar{
  width:56px;
  height:56px;
  border-radius:999px;
  background:#e8eaed;
  display:flex;
  align-items:center;
  justify-content:center;
  overflow:hidden;
  font-weight:800;
  font-size:22px;
}
.mgr-modal__avatar img{
  width:100%;
  height:100%;
  object-fit:cover;
}
.mgr-modal__name{ font-weight:600; font-size:16px; }
.mgr-modal__time{ color:#8a8d91; font-size:14px; margin-top:2px; }
.mgr-modal__rating{ color:var(--mgr-star); font-size:18px; letter-spacing:2px; margin-top:6px; }
.mgr-modal__text{ font-size:16px; line-height:1.7; color:#202124; margin-top:8px; }


/* Outer wrapper: allows arrows to sit outside */
.mgr-slider{
  position:relative;
  width:100%;
}

/* Inner viewport: clips the slides/cards so nothing spills out */
.mgr-swiper{
  width:100%;
  overflow:hidden;     /* ✅ clips card overflow */
  border-radius: 0;    /* optional */
}

/* Make sure arrows are not clipped */
.mgr-arrows{
  position:absolute;
  inset:0;
  pointer-events:none;
  z-index:30;
}
.mgr-arrow{
  pointer-events:auto;
}

/* If your arrows still look cut on small screens, push them inside a bit */
.mgr-prev{ left:10px; }
.mgr-next{ right:10px; }
