
/* EVENT_INSENTIF_V9_NEW_SYSTEM_CLEAN_PAGE */

body.event-insentif-v9-active {
  overflow:hidden !important;
}

#event-insentif-v9-page {
  position:fixed;
  top:var(--eiv9-top,76px);
  left:0;
  right:0;
  bottom:0;
  z-index:2147483000;
  overflow-y:auto;
  overflow-x:hidden;
  -webkit-overflow-scrolling:touch;
  color:#f8f4fb;
  background:
    radial-gradient(circle at 7% 4%,rgba(111,54,204,.24),transparent 27%),
    radial-gradient(circle at 92% 88%,rgba(198,35,220,.18),transparent 30%),
    #08040c;
}

#event-insentif-v9-page[hidden] {
  display:none !important;
}

#event-insentif-v9-page * {
  box-sizing:border-box;
}

.eiv9-shell {
  width:min(1180px,100%);
  margin:0 auto;
  padding:70px 18px 34px;
}

.eiv9-head {
  display:flex;
  justify-content:space-between;
  align-items:flex-start;
  gap:12px;
}

.eiv9-head h1 {
  margin:0;
  font-size:28px;
  font-weight:1000;
}

.eiv9-head p {
  margin:5px 0 0;
  color:#ab9bb7;
  font-size:8.5px;
}

.eiv9-primary,
.eiv9-small,
.eiv9-tier-add,
.eiv9-tier-remove {
  border:1px solid rgba(255,255,255,.08);
  border-radius:10px;
  background:#0c0711;
  color:#f7effb;
  padding:9px 12px;
  font-size:8.5px;
  font-weight:1000;
  cursor:pointer;
}

.eiv9-primary {
  border-color:transparent;
  background:
    linear-gradient(
      90deg,
      #d61cf4,
      #9635f1
    );
  box-shadow:
    0 10px 28px
    rgba(203,35,240,.16);
}

.eiv9-small.danger {
  color:#ffa3b1;
  border-color:
    rgba(255,102,125,.25);
  background:
    rgba(255,102,125,.08);
}

.eiv9-small.good {
  color:#9df0be;
  border-color:
    rgba(54,225,141,.24);
  background:
    rgba(54,225,141,.07);
}

.eiv9-status {
  margin-top:12px;
  padding:9px 11px;
  border:
    1px solid
    rgba(255,255,255,.065);
  border-radius:10px;
  background:#0c0711;
  color:#a99bb5;
  font-size:8px;
}

.eiv9-grid {
  display:grid;
  grid-template-columns:
    repeat(2,minmax(0,1fr));
  gap:14px;
  margin-top:12px;
}

.eiv9-history-title {
  margin-top:24px;
  font-size:14px;
  font-weight:1000;
}

.eiv9-card {
  position:relative;
  overflow:hidden;
  min-width:0;
  min-height:360px;
  border:
    1px solid
    rgba(172,66,255,.42);
  border-radius:18px;
  background:
    radial-gradient(
      circle at 88% 4%,
      rgba(113,67,255,.18),
      transparent 33%
    ),
    linear-gradient(
      180deg,
      #190c24,
      #0c0711
    );
}

.eiv9-bg {
  position:absolute;
  inset:0;
  width:100%;
  height:100%;
  object-fit:cover;
  opacity:.32;
}

.eiv9-shade {
  position:absolute;
  inset:0;
  background:
    linear-gradient(
      180deg,
      rgba(5,3,9,.13) 0%,
      rgba(6,3,10,.63) 42%,
      rgba(6,3,10,.98) 100%
    );
}

.eiv9-card-body {
  position:relative;
  z-index:2;
  min-height:360px;
  display:flex;
  flex-direction:column;
  justify-content:flex-end;
  padding:16px;
  text-transform:uppercase;
}

.eiv9-top {
  position:absolute;
  inset:13px 13px auto;
  display:flex;
  justify-content:
    space-between;
  gap:8px;
}

.eiv9-top span {
  display:inline-flex;
  padding:5px 8px;
  border:
    1px solid
    rgba(255,255,255,.09);
  border-radius:999px;
  background:
    rgba(7,4,11,.80);
  color:#eee7f4;
  font-size:7.2px;
  font-weight:1000;
}

.eiv9-top span.active {
  color:#95f0b6;
  border-color:
    rgba(54,225,141,.28);
}

.eiv9-top span.upcoming {
  color:#a9d1ff;
  border-color:
    rgba(113,183,255,.28);
}

.eiv9-card-body h3 {
  margin:0;
  color:#fff;
  font-size:21px;
  line-height:1.08;
  font-weight:1000;
}

.eiv9-date {
  margin-top:5px;
  color:#ffe56f;
  font-size:8.4px;
  font-weight:1000;
}

.eiv9-card-body > p {
  margin:7px 0 0;
  color:#eee6f3;
  font-size:8.2px;
  line-height:1.45;
}

.eiv9-meta {
  display:flex;
  flex-wrap:wrap;
  gap:5px;
  margin-top:8px;
}

.eiv9-meta span {
  padding:5px 7px;
  border:
    1px solid
    rgba(255,255,255,.06);
  border-radius:999px;
  background:
    rgba(8,5,12,.68);
  color:#d0c3d7;
  font-size:6.9px;
}

.eiv9-rule {
  margin-top:10px;
  color:#d6c2df;
  font-size:6.8px;
  font-weight:900;
}

.eiv9-progress,
.eiv9-people,
.eiv9-tiers {
  margin-top:10px;
}

.eiv9-progress-head,
.eiv9-reward-line,
.eiv9-person-top {
  display:flex;
  justify-content:
    space-between;
  gap:8px;
  align-items:center;
}

.eiv9-progress-head {
  font-size:7.3px;
}

.eiv9-track {
  position:relative;
  height:8px;
  margin-top:5px;
  overflow:hidden;
  border-radius:999px;
  background:
    rgba(255,255,255,.08);
}

.eiv9-track i {
  position:absolute;
  inset:0 auto 0 0;
  border-radius:inherit;
  background:
    linear-gradient(
      90deg,
      #2be0c7,
      #c72dee 72%,
      #8f5cff
    );
}

.eiv9-people {
  display:grid;
  gap:7px;
}

.eiv9-person {
  padding:9px;
  border:
    1px solid
    rgba(255,255,255,.06);
  border-radius:10px;
  background:
    rgba(7,4,11,.76);
}

.eiv9-person-top b {
  display:block;
  color:#fff;
  font-size:8.5px;
}

.eiv9-person-top small {
  display:block;
  margin-top:1px;
  color:#9f91a9;
  font-size:6.5px;
}

.eiv9-person-top strong {
  color:#8ff0b4;
  font-size:8.5px;
}

.eiv9-reward-line {
  margin-top:7px;
}

.eiv9-reward-line div {
  min-width:0;
}

.eiv9-reward-line span {
  display:block;
  color:#9f91a9;
  font-size:6.3px;
}

.eiv9-reward-line b {
  display:block;
  margin-top:2px;
  color:#fff;
  font-size:7.4px;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}

.eiv9-reward-line em {
  color:#ffd77f;
  font-size:7.3px;
  font-style:normal;
  font-weight:1000;
  white-space:nowrap;
}

.eiv9-complete {
  margin-top:7px;
  color:#8ff0b4;
  font-size:7.2px;
  font-weight:1000;
}

.eiv9-tier-title {
  margin-top:11px;
  color:#d4c1de;
  font-size:7px;
  font-weight:1000;
}

.eiv9-tier {
  display:grid;
  grid-template-columns:
    auto 72px minmax(0,1fr);
  gap:7px;
  align-items:center;
  padding:6px 7px;
  margin-top:4px;
  border:
    1px solid
    rgba(255,255,255,.05);
  border-radius:8px;
  background:
    rgba(7,4,11,.70);
}

.eiv9-tier b {
  color:#c9a7ff;
  font-size:6.6px;
}

.eiv9-tier span {
  color:#fff;
  font-size:6.8px;
  font-weight:1000;
}

.eiv9-tier em {
  color:#cabdce;
  font-size:6.5px;
  font-style:normal;
  overflow:hidden;
  white-space:nowrap;
  text-overflow:ellipsis;
}

.eiv9-actions {
  display:flex;
  gap:6px;
  margin-top:10px;
}

.eiv9-empty,
.eiv9-empty-inline {
  padding:28px 12px;
  text-align:center;
  color:#a99bb5;
  font-size:8px;
}

/* Modal */
.eiv9-modal {
  position:fixed;
  inset:0;
  z-index:2147483720;
  display:grid;
  place-items:center;
  padding:16px;
  background:
    rgba(5,3,9,.76);
  backdrop-filter:blur(9px);
  -webkit-backdrop-filter:
    blur(9px);
}

.eiv9-modal[hidden] {
  display:none !important;
}

body.eiv9-modal-open {
  overflow:hidden !important;
}

.eiv9-modal-card {
  width:min(760px,96vw);
  max-height:91dvh;
  overflow:auto;
  padding:16px;
  border:
    1px solid
    rgba(255,255,255,.09);
  border-radius:18px;
  background:
    linear-gradient(
      180deg,
      #1d1029,
      #0d0713
    );
}

.eiv9-modal-head {
  display:flex;
  justify-content:
    space-between;
  gap:12px;
}

.eiv9-modal-head h2 {
  margin:0;
  font-size:18px;
}

.eiv9-modal-head p {
  margin:4px 0 0;
  color:#aa9bb7;
  font-size:8px;
}

.eiv9-close {
  width:36px;
  height:36px;
  border:
    1px solid
    rgba(255,255,255,.08);
  border-radius:10px;
  background:#0c0711;
  color:#fff;
  font-size:20px;
  cursor:pointer;
}

.eiv9-form {
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:9px;
  margin-top:12px;
}

.eiv9-form .wide {
  grid-column:1/-1;
}

.eiv9-form label,
.eiv9-label {
  display:grid;
  gap:5px;
  color:#c9bdd0;
  font-size:8.4px;
  font-weight:900;
}

.eiv9-form input,
.eiv9-form select,
.eiv9-form textarea {
  width:100%;
  min-width:0;
  border:
    1px solid
    rgba(255,255,255,.08);
  border-radius:10px;
  background:#0c0711;
  color:#fff;
  padding:9px 10px;
  font:inherit;
}

.eiv9-form textarea {
  min-height:78px;
  resize:vertical;
}

.eiv9-tier-builder {
  padding:10px;
  border:
    1px solid
    rgba(255,255,255,.07);
  border-radius:12px;
  background:
    rgba(255,255,255,.025);
}

.eiv9-tier-builder-head {
  display:flex;
  justify-content:
    space-between;
  gap:10px;
  margin-bottom:8px;
}

.eiv9-tier-add,
.eiv9-tier-remove {
  border:
    1px solid
    rgba(255,255,255,.08);
  border-radius:9px;
  background:#0c0711;
  padding:7px 9px;
  font-size:7.7px;
  font-weight:950;
  cursor:pointer;
}

.eiv9-tier-add {
  color:#9df0be;
}

.eiv9-tier-remove {
  color:#ffa1b0;
}

#eiv9TierRows {
  display:grid;
  gap:7px;
}

.eiv9-tier-edit-row {
  display:grid;
  grid-template-columns:
    auto .6fr 1.2fr 1fr auto;
  gap:7px;
  align-items:end;
  padding:8px;
  border:
    1px solid
    rgba(255,255,255,.055);
  border-radius:10px;
  background:#0c0711;
}

.eiv9-tier-number {
  align-self:center;
  padding:5px 7px;
  border-radius:999px;
  background:
    rgba(166,59,240,.12);
  color:#dab6fa;
  font-size:6.7px;
  font-weight:1000;
}

.eiv9-admins {
  display:grid;
  grid-template-columns:
    repeat(3,minmax(0,1fr));
  gap:6px;
  margin-top:6px;
}

.eiv9-admins label {
  display:flex;
  align-items:center;
  gap:6px;
  padding:8px;
  border:
    1px solid
    rgba(255,255,255,.055);
  border-radius:9px;
  background:#0c0711;
}

.eiv9-admins input,
.eiv9-checkline input {
  width:auto;
  accent-color:#d61cf4;
}

.eiv9-checkline {
  display:flex !important;
  align-items:center;
  gap:7px !important;
}

.eiv9-preview {
  display:flex;
  gap:8px;
  align-items:center;
  padding:8px;
  border:
    1px dashed
    rgba(255,255,255,.1);
  border-radius:10px;
}

.eiv9-preview[hidden] {
  display:none !important;
}

.eiv9-preview img {
  width:88px;
  height:60px;
  object-fit:cover;
  border-radius:8px;
}

.eiv9-save-row {
  display:flex;
  justify-content:flex-end;
}

.eiv9-error {
  display:none;
  margin-top:10px;
  padding:9px 10px;
  border:
    1px solid
    rgba(255,102,125,.26);
  border-radius:10px;
  color:#ff9dac;
  font-size:8px;
}

.eiv9-error.show {
  display:block;
}

@media(max-width:760px) {
  .eiv9-shell {
    padding:
      66px 10px 24px;
  }

  .eiv9-head {
    display:grid;
    grid-template-columns:
      minmax(0,1fr) auto;
  }

  .eiv9-head h1 {
    font-size:22px;
  }

  .eiv9-grid {
    grid-template-columns:
      minmax(0,1fr);
    gap:11px;
  }

  .eiv9-card,
  .eiv9-card-body {
    min-height:300px;
  }

  .eiv9-card-body {
    padding:14px;
  }

  .eiv9-card-body h3 {
    font-size:18px;
  }

  .eiv9-form {
    grid-template-columns:
      minmax(0,1fr);
  }

  .eiv9-form .wide {
    grid-column:auto;
  }

  .eiv9-tier-edit-row {
    grid-template-columns:
      1fr;
  }

  .eiv9-tier-number,
  .eiv9-tier-remove {
    justify-self:start;
  }

  .eiv9-admins {
    grid-template-columns:
      1fr 1fr;
  }

  .eiv9-modal {
    padding:9px;
  }

  .eiv9-modal-card {
    width:100%;
    max-height:93dvh;
  }
}

@media(max-width:390px) {
  .eiv9-head {
    grid-template-columns:1fr;
  }

  .eiv9-head .eiv9-primary {
    justify-self:start;
    margin-top:7px;
  }

  .eiv9-admins {
    grid-template-columns:1fr;
  }
}


/* EVENT_V10_DASHBOARD_CLEANUP_AND_FULLSCREEN */

/* Full isolation: Dashboard/native pages can never bleed above Event. */
#event-insentif-v9-page {
  top: 0 !important;
  z-index: 2147483000 !important;
  background:
    radial-gradient(circle at 7% 4%, rgba(111,54,204,.24), transparent 27%),
    radial-gradient(circle at 92% 88%, rgba(198,35,220,.18), transparent 30%),
    #08040c !important;
}

/* Drawer must stay above the Event fullscreen page. */
#rekapMenuDrawer {
  z-index: 2147483645 !important;
}

#rekapMenuBackdrop {
  z-index: 2147483644 !important;
}

.eiv10-appbar {
  position: sticky;
  top: 0;
  z-index: 30;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  min-height: 74px;
  padding:
    calc(10px + env(safe-area-inset-top))
    16px
    10px;
  border-bottom: 1px solid rgba(255,255,255,.07);
  background: rgba(8,4,12,.96);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

.eiv10-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.eiv10-logo-slot {
  width: 48px;
  height: 48px;
  flex: 0 0 48px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 13px;
  background: linear-gradient(145deg,#261331,#0c0711);
  color: #fff;
  font-size: 15px;
  font-weight: 1000;
}

.eiv10-logo-image {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.eiv10-brand b {
  display: block;
  color: #fff;
  font-size: 15px;
  font-weight: 1000;
  letter-spacing: .02em;
}

.eiv10-brand small {
  display: block;
  margin-top: 2px;
  color: #aa9bb7;
  font-size: 7px;
  font-weight: 800;
}

.eiv10-menu-button {
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 11px;
  background: #140a1d;
  color: #fff;
  padding: 10px 12px;
  font-size: 9px;
  font-weight: 1000;
  cursor: pointer;
}

#event-insentif-v9-page .eiv9-shell {
  padding-top: 18px !important;
}

/* Fix mobile card/table overflow. */
#event-insentif-v9-page,
#event-insentif-v9-page .eiv9-shell,
#event-insentif-v9-page .eiv9-grid,
#event-insentif-v9-page .eiv9-card,
#event-insentif-v9-page .eiv9-card-body,
#event-insentif-v9-page .eiv9-person,
#event-insentif-v9-page .eiv9-tier {
  min-width: 0 !important;
  max-width: 100% !important;
}

#event-insentif-v9-page .eiv9-card-body p,
#event-insentif-v9-page .eiv9-meta span,
#event-insentif-v9-page .eiv9-reward-line b,
#event-insentif-v9-page .eiv9-tier em {
  white-space: normal !important;
  overflow-wrap: anywhere !important;
  word-break: break-word !important;
}

@media (max-width: 760px) {
  .eiv10-appbar {
    min-height: 78px;
    padding-left: 10px;
    padding-right: 10px;
  }

  .eiv10-logo-slot {
    width: 44px;
    height: 44px;
    flex-basis: 44px;
  }

  .eiv10-brand b {
    font-size: 14px;
  }

  .eiv10-menu-button {
    padding: 9px 10px;
  }

  #event-insentif-v9-page .eiv9-shell {
    padding:
      14px
      10px
      calc(24px + env(safe-area-inset-bottom))
      !important;
  }

  #event-insentif-v9-page .eiv9-head {
    align-items: start;
  }

  #event-insentif-v9-page .eiv9-grid {
    grid-template-columns: minmax(0,1fr) !important;
  }

  #event-insentif-v9-page .eiv9-person-top,
  #event-insentif-v9-page .eiv9-reward-line {
    gap: 10px;
  }
}



/* EVENT_MENU_ACTIVE_STATE_V10_1 */

#rekapMenuDrawer [data-eiv101-event-active="1"] {
  border-color: rgba(214, 28, 244, .62) !important;
  background:
    linear-gradient(
      90deg,
      rgba(214, 28, 244, .20),
      rgba(150, 53, 241, .15)
    ) !important;
  box-shadow:
    0 8px 24px rgba(214, 28, 244, .14) !important;
  color: #fff !important;
}

#rekapMenuDrawer [data-eiv101-event-active="1"] .rm-copy b,
#rekapMenuDrawer [data-eiv101-event-active="1"] b,
#rekapMenuDrawer [data-eiv101-event-active="1"] strong {
  color: #fff !important;
}

/* While EVENT page is open, no other menu row may visually stay selected. */
body.event-insentif-v9-active
#rekapMenuDrawer
.rm-item.active:not([data-eiv101-event-active="1"]) {
  background: transparent !important;
  border-color: transparent !important;
  box-shadow: none !important;
}



/* EVENT_MENU_POSITION_V10_2 */

/*
  Match the rest of Web Rekap:
  brand/header on top, MENU on the LEFT underneath it.
*/
#event-insentif-v9-page .eiv10-appbar {
  flex-direction: column !important;
  align-items: flex-start !important;
  justify-content: flex-start !important;
  gap: 8px !important;
}

#event-insentif-v9-page .eiv10-brand {
  width: 100% !important;
}

#event-insentif-v9-page .eiv10-menu-button {
  align-self: flex-start !important;
  margin: 0 !important;
  min-width: 94px !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
}

/* Keep Event content directly below the menu without excessive empty space. */
#event-insentif-v9-page .eiv9-shell {
  padding-top: 14px !important;
}

@media (max-width: 760px) {
  #event-insentif-v9-page .eiv10-appbar {
    gap: 7px !important;
  }

  #event-insentif-v9-page .eiv10-menu-button {
    min-width: 92px !important;
    padding: 9px 11px !important;
  }

  #event-insentif-v9-page .eiv9-shell {
    padding-top: 12px !important;
  }
}

