/* EgyptFun PWA — баланс пользователя (карточка гостя + оплата балансом в брони). */

/* ---- Карточка баланса в профиле ---- */
#ef-balance:empty { display: none; }
.ef-balCard {
  margin: 4px 16px;
  background: #fff;
  border: 1px solid rgba(14, 77, 86, .10);
  border-radius: 16px;
  padding: 14px 16px;
  box-shadow: 0 6px 20px rgba(14, 77, 86, .06);
}
.ef-balCard--on {
  background: radial-gradient(120% 140% at 90% 0, #12707E, #0E4D56 70%);
  border-color: transparent;
  box-shadow: 0 12px 30px rgba(14, 77, 86, .28);
}
.ef-balTop { display: flex; align-items: center; gap: 12px; }
.ef-balIco {
  width: 42px; height: 42px; border-radius: 12px; flex: 0 0 auto;
  display: grid; place-items: center;
  background: linear-gradient(135deg, #FF7A50, #FF5A2C);
  box-shadow: 0 6px 16px rgba(255, 90, 44, .32);
}
.ef-balCard:not(.ef-balCard--on) .ef-balIco {
  background: linear-gradient(135deg, #12707E, #0E4D56);
}
.ef-balMain { flex: 1; min-width: 0; }
.ef-balLabel {
  font-size: 12.5px; font-weight: 700; letter-spacing: .01em;
  color: #12707E; display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
}
.ef-balCard--on .ef-balLabel { color: rgba(234, 247, 248, .85); }
.ef-balReserved {
  font-size: 11px; font-weight: 700; color: #8c5e00;
  background: #FFF3E6; border-radius: 20px; padding: 2px 9px;
}
.ef-balCard--on .ef-balReserved { color: #FFE0B2; background: rgba(255, 255, 255, .14); }
.ef-balAmount {
  font-size: 26px; font-weight: 800; letter-spacing: -.02em; color: #0C2A2E;
  margin-top: 2px; line-height: 1.05;
}
.ef-balCard--on .ef-balAmount { color: #fff; }
.ef-balRub { font-size: 13px; font-weight: 600; color: #5C7B7F; margin-left: 4px; }
.ef-balCard--on .ef-balRub { color: rgba(234, 247, 248, .7); }
.ef-balSub {
  font-size: 12.5px; line-height: 1.45; color: #5C7B7F; margin-top: 10px;
}
.ef-balCard--on .ef-balSub { color: rgba(234, 247, 248, .82); }

/* История операций */
.ef-balHistToggle {
  margin-top: 12px; width: 100%; border: none; cursor: pointer;
  background: rgba(18, 112, 126, .08); color: #12707E;
  font: 700 13px inherit; padding: 9px 12px; border-radius: 10px;
  display: flex; align-items: center; justify-content: center; gap: 6px;
}
.ef-balCard--on .ef-balHistToggle { background: rgba(255, 255, 255, .14); color: #EAF7F8; }
.ef-balHistChev { transition: transform .2s; font-size: 11px; }
.ef-balHistChev.on { transform: rotate(180deg); }
.ef-balHist { margin-top: 8px; display: grid; gap: 2px; }
.ef-balHistRow {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 4px; border-top: 1px solid rgba(14, 77, 86, .08);
}
.ef-balCard--on .ef-balHistRow { border-top-color: rgba(255, 255, 255, .12); }
.ef-balHistMain { flex: 1; min-width: 0; }
.ef-balHistT { font-size: 13.5px; font-weight: 600; color: #0C2A2E; }
.ef-balCard--on .ef-balHistT { color: #fff; }
.ef-balHistS {
  font-size: 11.5px; color: #5C7B7F; margin-top: 1px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 200px;
}
.ef-balCard--on .ef-balHistS { color: rgba(234, 247, 248, .7); }
.ef-balHistR { text-align: right; flex: 0 0 auto; }
.ef-balHistAmt { font-size: 14px; font-weight: 800; }
.ef-balHistW { font-size: 11px; color: #9DB2B4; margin-top: 1px; }
.ef-balCard--on .ef-balHistW { color: rgba(234, 247, 248, .55); }

/* ---- Блок «оплатить с баланса» в форме бронирования ---- */
.ef-bkBal {
  margin-top: 12px; border: 1px solid rgba(18, 112, 126, .25);
  border-radius: 12px; padding: 12px 14px; background: #F4FBFB;
}
.ef-bkBalHead {
  display: flex; align-items: center; justify-content: space-between; gap: 10px; cursor: pointer;
}
.ef-bkBalTitle { font-size: 13.5px; font-weight: 700; color: #0E4D56; display: flex; align-items: center; gap: 7px; }
.ef-bkBalAvail { font-size: 12px; font-weight: 700; color: #12707E; }
.ef-bkBalSwitch {
  position: relative; width: 42px; height: 24px; border-radius: 20px;
  background: #cdd8d9; transition: background .2s; flex: 0 0 auto;
}
.ef-bkBalSwitch::after {
  content: ""; position: absolute; top: 2px; left: 2px; width: 20px; height: 20px;
  border-radius: 50%; background: #fff; transition: transform .2s; box-shadow: 0 1px 3px rgba(0, 0, 0, .25);
}
.ef-bkBal.on .ef-bkBalSwitch { background: #12707E; }
.ef-bkBal.on .ef-bkBalSwitch::after { transform: translateX(18px); }
.ef-bkBalBody { margin-top: 10px; }
.ef-bkBal:not(.on) .ef-bkBalBody { display: none; }
.ef-bkBalRow {
  display: flex; align-items: center; justify-content: space-between;
  font-size: 13px; color: #0C2A2E; padding: 3px 0;
}
.ef-bkBalUse { font-weight: 800; color: #12707E; }
.ef-bkBalHint { font-size: 11.5px; line-height: 1.45; color: #5C7B7F; margin-top: 6px; }
.ef-bkBalMax {
  border: none; background: rgba(18, 112, 126, .12); color: #12707E;
  font: 700 11px inherit; padding: 3px 9px; border-radius: 8px; cursor: pointer; margin-left: 8px;
}
