:root{
  --navy:#26297b;
  --navy2:#1e215f;
  --sheet:#ffffff;
  --ink:#0b0f2a;
  --muted:#6b7280;
  --cyan:#19c7ff;
  --pink:#ff5fa2;
  --orange:#ff9f1c;
  --yellow:#ffd93d;
  --grad:linear-gradient(90deg,var(--cyan),var(--pink));
  --radius:26px;
  --card:18px;
  --shadow:0 14px 38px rgba(0,0,0,.18);
  --shadow2:0 8px 22px rgba(0,0,0,.14);
}
*{box-sizing:border-box}
html,body{height:100%}
body{
  margin:0;
  font-family:"Outfit",system-ui,-apple-system,Segoe UI,Roboto,Arial,sans-serif;
  background:var(--navy);
  color:var(--ink);
  overflow:hidden;
}
a{color:inherit;text-decoration:none}
button,input,select,textarea{font:inherit}

#app{height:100%;display:flex;flex-direction:column}

.topbar{
  height:64px;min-height:64px;
  display:flex;align-items:center;justify-content:space-between;
  padding:0 16px;color:#fff;
  background:var(--navy);
  position:relative;
}
.topbar .title{font-weight:700;font-size:18px;letter-spacing:.2px}
.iconbtn{
  width:38px;height:38px;border-radius:12px;
  display:grid;place-items:center;
  background:rgba(255,255,255,.14);
  border:1px solid rgba(255,255,255,.16);
  cursor:pointer;
}
.iconbtn:active{transform:translateY(1px)}

.sheet{
  flex:1;
  background:var(--sheet);
  border-radius:var(--radius) var(--radius) 0 0;
  overflow:auto;
  padding:18px 16px 110px;
  box-shadow:0 -18px 40px rgba(0,0,0,.18);
}

.bottomnav{
  height:78px;min-height:78px;
  background:var(--navy);
  display:flex;align-items:center;justify-content:space-around;
  position:relative;
}
.navbtn{
  background:transparent;border:0;
  color:rgba(255,255,255,.70);
  display:flex;flex-direction:column;align-items:center;gap:5px;
  font-size:12px;cursor:pointer;min-width:54px;
}
.navbtn.active{color:#fff}
.navbtn .ico{font-size:18px;line-height:1}
.eventfab{
  width:60px;height:60px;border-radius:50%;
  background:var(--grad);
  display:grid;place-items:center;
  box-shadow:var(--shadow);
  margin-top:-36px;
  border:0;color:#fff;font-weight:800;
  cursor:pointer;
}
.badge{
  position:absolute;
  top:10px; transform:translateX(10px);
  min-width:18px;height:18px;border-radius:999px;
  background:#ff2d55;color:#fff;
  font-size:11px;display:grid;place-items:center;
  padding:0 6px;
}

.view{display:none}
.view.active{display:block}

.section-title{
  display:flex;align-items:center;justify-content:space-between;
  margin:16px 2px 10px;
}
.section-title h3{margin:0;font-size:16px}
.pill{
  display:inline-flex;align-items:center;gap:8px;
  padding:8px 12px;border-radius:999px;
  background:rgba(38,41,123,.08);
  color:var(--navy);
  font-weight:600;font-size:12px;
}

.card{
  background:#fff;border-radius:var(--card);
  box-shadow:var(--shadow2);
  padding:14px 14px;
  border:1px solid rgba(15,18,47,.06);
}
.card + .card{margin-top:12px}

/* ------------------------------
   MEMBERSHIP CARD (IMAGE BASED)
--------------------------------*/
.membership{
  border-radius:20px;
  box-shadow:var(--shadow);
  position:relative;
  overflow:hidden;
  min-height:150px;
}
.tscard-bg{
  position:absolute; inset:0;
  width:100%; height:100%;
  object-fit:cover;
  transform:scale(1.02);
}
.tscard-overlay{
  position:absolute; inset:0;
  background:linear-gradient(90deg, rgba(0,0,0,.32), rgba(0,0,0,.08));
}
.tscard-inner{
  position:relative;
  padding:16px 16px 14px;
  color:#fff;
}
.tscard-top{
  display:flex; align-items:flex-start; justify-content:space-between;
}
.tscard-brand{
  display:flex; gap:10px; align-items:center;
}
.tscard-brand img{
  width:28px;height:28px;border-radius:8px;
  background:rgba(255,255,255,.18);
  padding:4px;
}
.tscard-brandtext{
  display:flex; flex-direction:column; gap:2px;
}
#memberStatus{font-size:13px;font-weight:800;line-height:1}
#pillMode{
  display:inline-flex;
  width:fit-content;
  font-size:11px;
  opacity:.9;
}

.tscard-chip{
  margin-top:14px;
  width:44px; height:34px;
  border-radius:8px;
  background:
    linear-gradient(135deg, rgba(255,215,120,.95), rgba(255,190,80,.65));
  box-shadow:0 10px 22px rgba(0,0,0,.18);
  border:1px solid rgba(0,0,0,.18);
  position:relative;
}
.tscard-chip:before, .tscard-chip:after{
  content:"";
  position:absolute; left:6px; right:6px;
  height:2px; background:rgba(0,0,0,.18);
  top:11px;
}
.tscard-chip:after{top:20px; opacity:.6}

.tscard-number{
  margin-top:10px;
  font-size:20px;
  font-weight:900;
  letter-spacing:1px;
  text-shadow:0 6px 14px rgba(0,0,0,.22);
}
.tscard-bottom{
  margin-top:10px;
  display:flex;
  justify-content:space-between;
  gap:14px;
}
.tscard-col{
  display:flex; flex-direction:column; gap:2px;
  min-width:120px;
}
.tscard-label{
  font-size:10px;
  opacity:.85;
  letter-spacing:.9px;
}
.tscard-value{
  font-size:12px;
  font-weight:800;
  letter-spacing:.6px;
}

/* Search */
.search{
  margin:14px 0;
  display:flex;gap:10px;
}
.search input{
  flex:1;
  padding:13px 14px;border-radius:16px;border:0;
  background:#f2f3f7;
  outline:none;
}
.neon-dot{width:10px;height:10px;border-radius:50%;background:var(--cyan);box-shadow:0 0 0 6px rgba(25,199,255,.18)}

.grid2{display:grid;grid-template-columns:1fr 1fr;gap:12px}
.hscroll{display:flex;gap:12px;overflow:auto;padding-bottom:6px}
.hscroll::-webkit-scrollbar{height:0}

.offer{
  min-width:190px;
  background:#fff;border-radius:18px;
  box-shadow:var(--shadow2);
  padding:12px;border:1px solid rgba(15,18,47,.06);
}
.offer .tag{font-size:11px;font-weight:700;color:var(--navy);opacity:.8}
.offer .name{font-weight:800;margin:6px 0 4px}
.offer .meta{font-size:12px;color:var(--muted)}

.btn{
  width:100%;
  border:0;border-radius:18px;
  padding:13px 14px;
  background:var(--grad);
  color:#fff;font-weight:800;
  cursor:pointer;
}
.btn.secondary{
  background:#eef0ff;color:var(--navy)
}
.btn:active{transform:translateY(1px)}

.form{
  max-width:520px;margin:0 auto;
}
.form h2{margin:0 0 6px;font-size:22px}
.form p{margin:0 0 14px;color:var(--muted);font-size:13px}
.input{
  width:100%;
  padding:13px 14px;border-radius:16px;border:0;
  background:#f2f3f7;outline:none;
  margin:0 0 10px;
}
.row{display:flex;gap:10px}
.row > *{flex:1}
.smalllink{font-size:13px;color:var(--navy);font-weight:700}
.center{text-align:center}

.toast{
  position:fixed;left:50%;bottom:96px;transform:translateX(-50%);
  background:#0f122f;color:#fff;
  padding:12px 14px;border-radius:14px;
  box-shadow:var(--shadow);
  display:none;max-width:92vw;
}
.toast.show{display:block}

.modalback{
  position:fixed;inset:0;background:rgba(0,0,0,.45);
  display:none;align-items:flex-end;justify-content:center;
  padding:14px;
}
.modalback.show{display:flex}
.modal{
  width:min(520px,100%);
  background:#fff;border-radius:22px;
  padding:14px;
  box-shadow:var(--shadow);
}
.modal h3{margin:0 0 6px}
.modal p{margin:0 0 12px;color:var(--muted)}
.modal .actions{display:flex;gap:10px}

.drawerback{
  position:fixed;inset:0;background:rgba(0,0,0,.35);
  display:none;
}
.drawerback.show{display:block}
.drawer{
  position:fixed;top:0;left:0;height:100%;width:290px;
  background:var(--navy2);color:#fff;
  padding:18px 16px;
  transform:translateX(-100%);
  transition:transform .25s ease;
}
.drawerback.show .drawer{transform:translateX(0)}
.drawer .hdr{display:flex;align-items:center;gap:10px;margin-bottom:14px}
.drawer .hdr img{width:34px;height:34px;border-radius:10px}
.drawer .item{
  padding:12px 10px;border-radius:14px;
  display:flex;align-items:center;justify-content:space-between;
  cursor:pointer;
}
.drawer .item:hover{background:rgba(255,255,255,.10)}
.drawer .item span{opacity:.92;font-weight:650}
.drawer .item small{opacity:.7}

/* Chat */
.chatwrap{display:flex;flex-direction:column;height:calc(100vh - 64px - 78px - 40px)}
.chatbanner{
  background:rgba(25,199,255,.12);
  border:1px solid rgba(25,199,255,.18);
  padding:10px 12px;border-radius:18px;
  color:var(--navy);font-weight:750;font-size:12px;
  margin-bottom:10px;
}
.chatbox{
  flex:1;overflow:auto;
  background:#f5f6fb;border-radius:18px;padding:10px;
}
.bubble{
  max-width:78%;
  padding:10px 12px;border-radius:16px;
  margin:8px 0;font-size:13px;
  box-shadow:0 6px 16px rgba(0,0,0,.08);
}
.bubble.me{margin-left:auto;background:var(--grad);color:#fff;border-bottom-right-radius:6px}
.bubble.them{background:#fff;border-bottom-left-radius:6px}
.msgmeta{font-size:11px;opacity:.75;margin-top:4px}
.chatbar{
  display:flex;gap:10px;margin-top:10px
}
.chatbar input{
  flex:1;padding:12px 12px;border-radius:16px;border:0;background:#fff;box-shadow:0 6px 18px rgba(0,0,0,.08)
}
.chaticon{
  width:44px;height:44px;border-radius:16px;border:0;
  background:#eef0ff;color:var(--navy);font-weight:900;cursor:pointer;
}

/* --- FIX MEMBERSHIP CARD: fixed size, full image, non-scaled text --- */
#memberCard,
.member-card {
  width: 100% !important;
  max-width: 420px !important;     /* prevents huge scaling on desktop */
  height: 210px !important;        /* fixed height */
  border-radius: 22px !important;
  overflow: hidden !important;
  position: relative !important;

  background-repeat: no-repeat !important;
  background-position: center !important;
  background-size: contain !important; /* SHOW FULL IMAGE (no crop) */
  background-color: transparent !important;
}

/* If your layout makes it stretch wider, force center */
.member-card-wrap,
#memberCardWrap {
  display: flex !important;
  justify-content: center !important;
}

/* Remove any extra chip icon element if still present */
#cardChip,
.chip,
.member-chip {
  display: none !important;
}

/* Freeze text sizing so it does NOT scale */
#memberCard * {
  font-size: 14px !important;
  line-height: 1.1 !important;
}
#memberCard .card-title { font-size: 14px !important; font-weight: 800 !important; }
#memberCard .card-num   { font-size: 20px !important; font-weight: 900 !important; letter-spacing: 1px !important; }
#memberCard .card-small { font-size: 12px !important; opacity: .95 !important; }
