/* ================================================
   Smart Gold X - Premium Dark Navy + Gold Design
   ================================================ */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&family=Outfit:wght@400;600;700;800&display=swap');

:root {
  --primary: #f5c518;
  --primary-dark: #d4a017;
  --primary-light: #ffd700;
  --gold-gradient: linear-gradient(135deg, #f5c518 0%, #ffd700 50%, #d4a017 100%);
  --gold-gradient-soft: linear-gradient(135deg, #f5c51822 0%, #ffd70011 100%);
  --navy: #0a0e1a;
  --navy-2: #0d1225;
  --navy-3: #111827;
  --navy-card: #151c30;
  --navy-light: #1a2240;
  --glass: rgba(255, 255, 255, 0.04);
  --glass-border: rgba(255, 255, 255, 0.08);
  --glass-hover: rgba(255, 255, 255, 0.07);
  --text-primary: #f0f4ff;
  --text-secondary: #8892b0;
  --text-muted: #556080;
  --success: #00d4a8;
  --danger: #ff4d6d;
  --warning: #ffa500;
  --info: #4da6ff;
  --border-radius: 18px;
  --border-radius-sm: 12px;
  --shadow: 0 8px 40px rgba(0, 0, 0, 0.4);
  --shadow-gold: 0 4px 30px rgba(245, 197, 24, 0.25);
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { font-size: 16px; scroll-behavior: smooth; }

body {
  font-family: 'Inter', sans-serif;
  background: var(--navy);
  color: var(--text-primary);
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* ---- Scrollbar ---- */
::-webkit-scrollbar { width: 5px; }
::-webkit-scrollbar-track { background: var(--navy-2); }
::-webkit-scrollbar-thumb { background: var(--primary-dark); border-radius: 10px; }

/* ---- App Wrapper (Mobile-App Style) ---- */
.app-wrapper {
  max-width: 600px;
  margin: 0 auto;
  min-height: 100vh;
  background: var(--navy-2);
  position: relative;
  overflow-x: hidden;
  box-shadow: 0 0 100px rgba(0,0,0,0.5);
}

/* ---- Header ---- */
.app-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  background: var(--navy-card);
  border-bottom: 1px solid var(--glass-border);
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(20px);
}

.header-logo {
  display: flex;
  align-items: center;
  gap: 10px;
}

.header-logo img { width: 32px; height: 32px; object-fit: contain; }
.header-logo-text { font-family: 'Outfit', sans-serif; font-weight: 700; font-size: 15px; background: var(--gold-gradient); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }

.header-icons { display: flex; gap: 12px; align-items: center; }
.header-icon-btn {
  width: 36px; height: 36px;
  background: var(--glass);
  border: 1px solid var(--glass-border);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  transition: var(--transition);
  text-decoration: none;
  color: var(--text-secondary);
}
.header-icon-btn:hover { background: var(--gold-gradient-soft); border-color: var(--primary); color: var(--primary); }
.header-icon-btn svg { width: 16px; height: 16px; }

/* ---- Bottom Navigation ---- */
.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  max-width: 600px;
  background: var(--navy-card);
  border-top: 1px solid var(--glass-border);
  display: flex;
  align-items: center;
  padding: 8px 0 12px;
  z-index: 100;
}
.nav-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  text-decoration: none;
  color: var(--text-muted);
  transition: var(--transition);
  padding: 4px 0;
}
.nav-item.active { color: var(--primary); }
.nav-item svg { width: 22px; height: 22px; }
.nav-item span { font-size: 10px; font-weight: 500; }
.nav-item.active .nav-icon { filter: drop-shadow(0 0 6px rgba(245,197,24,0.6)); }

/* ---- Page Content ---- */
.page-content { padding: 16px 16px 110px; }

/* ---- Cards / Glass containers ---- */
.glass-card {
  background: var(--glass);
  border: 1px solid var(--glass-border);
  border-radius: var(--border-radius);
  padding: 20px;
  transition: var(--transition);
}
.glass-card:hover { background: var(--glass-hover); }

/* ---- Balance Card ---- */
.balance-card {
  background: linear-gradient(135deg, #1a2240 0%, #0d1834 100%);
  border: 1px solid rgba(245,197,24,0.2);
  border-radius: var(--border-radius);
  padding: 22px 20px;
  position: relative;
  overflow: hidden;
  text-align: center;
  margin-bottom: 20px;
}
.balance-card::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -20%;
  width: 200px;
  height: 200px;
  background: radial-gradient(circle, rgba(245,197,24,0.1) 0%, transparent 70%);
  border-radius: 50%;
}
.balance-label { font-size: 12px; color: var(--text-secondary); font-weight: 500; margin-bottom: 6px; }
.balance-amount { font-family: 'Outfit', sans-serif; font-size: 30px; font-weight: 800; background: var(--gold-gradient); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.balance-sub { font-size: 12px; color: var(--text-secondary); margin-top: 4px; }
.balance-btns { display: flex; gap: 10px; margin-top: 16px; }

/* ---- Buttons ---- */
.btn-gold {
  background: var(--gold-gradient);
  color: #1a0e00;
  border: none;
  border-radius: 50px;
  padding: 12px 24px;
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: var(--transition);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-decoration: none;
  box-shadow: var(--shadow-gold);
  letter-spacing: 0.3px;
}
.btn-gold:hover { transform: translateY(-2px); box-shadow: 0 8px 40px rgba(245,197,24,0.4); }
.btn-gold:active { transform: translateY(0); }
.btn-gold-outline {
  background: transparent;
  color: var(--primary);
  border: 1.5px solid var(--primary);
  border-radius: 50px;
  padding: 11px 24px;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: var(--transition);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-decoration: none;
}
.btn-gold-outline:hover { background: var(--gold-gradient-soft); }
.btn-full { width: 100%; }
.btn-sm { padding: 8px 16px; font-size: 12px; }

.btn-glass {
  background: var(--glass);
  border: 1px solid var(--glass-border);
  color: var(--text-primary);
  border-radius: 50px;
  padding: 10px 20px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  display: inline-flex;
  align-items: center;
  gap: 7px;
  text-decoration: none;
}
.btn-glass:hover { background: var(--glass-hover); color: var(--primary); border-color: var(--primary); }

.btn-danger { background: linear-gradient(135deg, #ff4d6d, #c9003a); color: #fff; }
.btn-success { background: linear-gradient(135deg, #00d4a8, #009977); color: #fff; }

/* ---- Quick Nav Icons ---- */
.quick-nav { display: flex; gap: 10px; padding: 4px 0 16px; overflow-x: auto; scrollbar-width: none; }
.quick-nav::-webkit-scrollbar { display: none; }
.quick-nav-item {
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  min-width: 72px;
}
.quick-nav-icon {
  width: 54px; height: 54px;
  background: var(--glass);
  border: 1px solid var(--glass-border);
  border-radius: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}
.quick-nav-item:hover .quick-nav-icon { background: var(--gold-gradient-soft); border-color: var(--primary); }
.quick-nav-icon img, .quick-nav-icon svg { width: 26px; height: 26px; }
.quick-nav-label { font-size: 11px; color: var(--text-secondary); font-weight: 500; text-transform: capitalize; white-space: nowrap; }

/* ---- Section Title ---- */
.section-title {
  font-family: 'Outfit', sans-serif;
  font-size: 16px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.section-title a { font-size: 12px; color: var(--primary); font-weight: 600; text-decoration: none; }

/* ---- Claim Section ---- */
/* ---- Premium Claim Section (My AI Robots) ---- */
.premium-claim-box {
  background: #fdfaf5 !important; /* Off-white / Cream background */
  border: 1px solid rgba(0,0,0,0.05);
  border-radius: 20px;
  padding: 18px 20px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.1);
  color: #1a0e00 !important;
  display: block;
  width: 100%;
  text-align: center;
}

.pcb-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 15px;
}
.pcb-title {
  font-family: 'Outfit', sans-serif;
  font-weight: 800;
  font-size: 15px;
  color: #3e2723;
}
.pcb-view {
  font-size: 13px;
  color: #bca89f;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 2px;
  font-weight: 500;
}

.pcb-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.pcb-animation {
  width: 70px;
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin-bottom: 10px;
}

.gold-bars-stack {
  position: relative;
  width: 50px;
  height: 40px;
}
.gb {
  position: absolute;
  width: 35px;
  height: 14px;
  background: linear-gradient(135deg, #ffd700 0%, #daa520 100%);
  border-radius: 2px;
  border: 1px solid rgba(0,0,0,0.1);
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
  opacity: 0;
  transform: translateY(10px);
}
.gb-1 { bottom: 0; left: 0; animation: barAppear 2s infinite 0s; }
.gb-2 { bottom: 6px; left: 8px; animation: barAppear 2s infinite 0.4s; }
.gb-3 { bottom: 12px; left: 4px; animation: barAppear 2s infinite 0.8s; }

@keyframes barAppear {
  0% { opacity: 0; transform: translateY(10px); }
  20% { opacity: 1; transform: translateY(0); }
  80% { opacity: 1; transform: translateY(0); }
  100% { opacity: 0; transform: translateY(-5px); }
}

.pcb-info {
  flex: 1;
}
.pcb-status {
  font-size: 14px;
  font-weight: 700;
  color: #8d6e63;
  margin-bottom: 3px;
}
.pcb-subtext {
  font-size: 11px;
  color: #bca89f;
  line-height: 1.4;
}

.pcb-btn {
  background: #ffc107;
  background: linear-gradient(135deg, #ffca28 0%, #ffa000 100%);
  border: none;
  color: #1a0e00;
  padding: 10px 24px;
  border-radius: 50px;
  font-weight: 700;
  font-size: 13px;
  cursor: pointer;
  box-shadow: 0 4px 10px rgba(255, 160, 0, 0.3);
  transition: all 0.2s;
}
.pcb-btn:hover { transform: scale(1.05); }
.pcb-btn.disabled { opacity: 0.5; cursor: not-allowed; transform: none; box-shadow: none; }

/* ---- Plan Cards ---- */
.plans-list { padding: 0; display: flex; flex-direction: column; gap: 14px; }
/* ---- Premium Plan Card (Redesign) ---- */
.plan-card.premium {
  background: #fdbb2d; /* Gold/Yellow background from image */
  background: linear-gradient(135deg, #fdbb2d 0%, #f9a01b 100%);
  border: none;
  border-radius: 18px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  color: #1a0e00;
  box-shadow: 0 4px 15px rgba(0,0,0,0.1);
  position: relative;
}

.premium-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.premium-timer-box {
  display: flex;
  align-items: center;
  gap: 8px;
}
.premium-timer-lbl { font-size: 13px; font-weight: 700; }
.timer-units { display: flex; gap: 4px; }
.t-unit {
  background: #fff;
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 12px;
  font-weight: 700;
  box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}
.premium-bonus { font-size: 13px; font-weight: 700; }

.premium-main {
  display: flex;
  gap: 16px;
  align-items: center;
}
.premium-img-wrap {
  width: 100px;
  height: 65px;
  border-radius: 12px;
  overflow: visible; /* Changed to visible for badge overflow */
  flex-shrink: 0;
  border: 1px solid rgba(255,255,255,0.3);
  position: relative;
}
.premium-img-wrap img { width: 100%; height: 100%; object-fit: cover; border-radius: 12px; }

.plan-badge {
  position: absolute;
  top: -8px;
  right: -8px;
  background: #ff0000;
  color: #fff;
  font-size: 9px;
  font-weight: 800;
  padding: 3px 8px;
  border-radius: 4px;
  text-transform: uppercase;
  box-shadow: 0 4px 8px rgba(0,0,0,0.3);
  z-index: 5;
  letter-spacing: 0.5px;
  border: 1px solid rgba(255,255,255,0.2);
  white-space: nowrap;
}

.premium-content {
  flex: 1;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.premium-name { 
  font-family: 'Outfit', sans-serif; 
  font-size: 16px; 
  font-weight: 800; 
  color: #1a0e00; 
  margin-bottom: 2px;
  line-height: 1.2;
}
.premium-actions { 
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 4px;
}
.premium-price {
  font-family: 'Outfit', sans-serif;
  font-size: 15px;
  font-weight: 800;
  color: #1a0e00;
}
.purchase-btn {
  background: transparent;
  border: 1.5px solid #1a0e00;
  color: #1a0e00;
  padding: 6px 14px;
  border-radius: 50px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
}
.purchase-btn:hover { background: #1a0e00; color: #fff; }
.purchase-btn.disabled { opacity: 0.5; cursor: not-allowed; }

.premium-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  padding-top: 10px;
  border-top: 1px solid rgba(0,0,0,0.05);
}
.p-stat { text-align: center; }
.p-val { font-size: 12px; font-weight: 700; margin-bottom: 2px; }
.p-lbl { font-size: 9px; opacity: 0.7; font-weight: 600; }

.plan-expired-overlay {
  position: absolute; inset: 0;
  background: rgba(0,0,0,0.5);
  border-radius: 18px;
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-weight: 700; z-index: 5;
  backdrop-filter: blur(2px);
}

/* ---- Form Styles ---- */
.form-group { margin-bottom: 14px; }
.form-label { font-size: 12px; font-weight: 600; color: var(--text-secondary); margin-bottom: 6px; display: block; }
.form-control {
  width: 100%;
  background: var(--glass);
  border: 1px solid var(--glass-border);
  border-radius: var(--border-radius-sm);
  padding: 13px 16px;
  color: var(--text-primary);
  font-size: 14px;
  font-family: 'Inter', sans-serif;
  transition: var(--transition);
  outline: none;
}
.form-control:focus { border-color: var(--primary); background: rgba(245,197,24,0.06); box-shadow: 0 0 20px rgba(245,197,24,0.2); }
.form-control::placeholder { color: var(--text-muted); opacity: 0.6; }
.input-group { position: relative; display: flex; align-items: center; width: 100%; transition: var(--transition); }
.input-icon { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--text-muted); width: 18px; height: 18px; pointer-events: none; z-index: 2; transition: var(--transition); }
.form-control:focus + .input-icon, .form-control:not(:placeholder-shown) + .input-icon { color: var(--primary); }
.input-group .form-control { padding-left: 44px; position: relative; z-index: 1; }
.input-action { position: absolute; right: 14px; top: 50%; transform: translateY(-50%); color: var(--text-muted); cursor: pointer; background: none; border: none; display: flex; z-index: 2; }
.prefix-group { display: flex; gap: 8px; }
.input-prefix {
  background: rgba(245,197,24,0.1);
  border: 1px solid rgba(245,197,24,0.2);
  border-radius: var(--border-radius-sm);
  padding: 13px 14px;
  color: var(--primary);
  font-weight: 700;
  font-size: 14px;
  white-space: nowrap;
  flex-shrink: 0;
}
.form-select {
  width: 100%;
  background: var(--glass);
  border: 1px solid var(--glass-border);
  border-radius: var(--border-radius-sm);
  padding: 13px 16px;
  color: var(--text-primary);
  font-size: 14px;
  font-family: 'Inter', sans-serif;
  outline: none;
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%238892b0' d='M6 8L0 0h12z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
  padding-right: 40px;
}
.form-select:focus { border-color: var(--primary); }
.form-select option { background: var(--navy-3); }

/* ---- Login Page ---- */
.auth-page {
  min-height: 100vh;
  background: linear-gradient(160deg, #0a0e1a 0%, #0d1834 50%, #0a0c18 100%);
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 40px 24px 30px;
}
.auth-logo { text-align: center; margin-bottom: 24px; }
.auth-logo img { width: 90px; height: 90px; object-fit: contain; filter: drop-shadow(0 0 20px rgba(245,197,24,0.5)); animation: logoPulse 3s ease-in-out infinite; }
@keyframes logoPulse {
  0%, 100% { filter: drop-shadow(0 0 20px rgba(245,197,24,0.5)); }
  50% { filter: drop-shadow(0 0 40px rgba(245,197,24,0.9)); }
}
.auth-title { font-family: 'Outfit', sans-serif; font-size: 26px; font-weight: 800; background: var(--gold-gradient); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; margin-bottom: 4px; }
.auth-subtitle { font-size: 13px; color: var(--text-secondary); }
.auth-tabs { display: flex; background: rgba(255,255,255,0.03); border: 1px solid var(--glass-border); border-radius: 50px; padding: 4px; margin: 24px 0 20px; position: relative; z-index: 1; overflow: hidden; }
.auth-tab {
  flex: 1;
  padding: 12px;
  border: none;
  border-radius: 50px;
  background: transparent;
  color: var(--text-secondary);
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: var(--transition);
  font-family: 'Outfit', sans-serif;
  position: relative;
  z-index: 2;
  text-transform: uppercase;
  letter-spacing: 1px;
}
.auth-tab.active { color: #1a0e00; }
.auth-tab-slider {
  position: absolute;
  top: 4px; left: 4px;
  height: calc(100% - 8px);
  width: calc(50% - 4px);
  background: var(--gold-gradient);
  border-radius: 50px;
  transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 1;
  box-shadow: var(--shadow-gold);
}
.auth-form { width: 100%; max-width: 500px; position: relative; z-index: 10; }
.auth-box {
  background: rgba(13, 18, 37, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 24px;
  padding: 30px 24px;
  backdrop-filter: blur(30px) saturate(150%);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
}
.forgot-link { text-align: center; margin-top: 12px; }
.forgot-link a { color: var(--primary); font-size: 13px; font-weight: 600; text-decoration: none; }
.terms-row { display: flex; align-items: flex-start; gap: 10px; margin: 14px 0; }
.terms-checkbox { width: 18px; height: 18px; accent-color: var(--primary); flex-shrink: 0; margin-top: 2px; cursor: pointer; }
.terms-text { font-size: 12px; color: var(--text-secondary); line-height: 1.5; }
.terms-text a { color: var(--primary); }

/* ---- Popup / Modal ---- */
.popup-overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,0.75);
  display: flex; align-items: center; justify-content: center;
  z-index: 1000;
  padding: 20px;
  opacity: 0; visibility: hidden;
  transition: var(--transition);
  backdrop-filter: blur(5px);
}
.popup-overlay.active { opacity: 1; visibility: visible; }
.popup-box {
  background: var(--navy-card);
  border: 1px solid var(--glass-border);
  border-radius: var(--border-radius);
  padding: 28px 24px;
  width: 100%;
  max-width: 360px;
  transform: scale(0.9) translateY(20px);
  transition: var(--transition);
  text-align: center;
}
.popup-overlay.active .popup-box { transform: scale(1) translateY(0); }
.popup-icon { font-size: 52px; margin-bottom: 12px; }
.popup-icon.success { animation: bounceIn 0.5s; }
@keyframes bounceIn { 0% { transform: scale(0); } 60% { transform: scale(1.2); } 100% { transform: scale(1); } }
.popup-green-tick {
  width: 70px; height: 70px;
  background: linear-gradient(135deg, #00d4a8, #009977);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 16px;
  font-size: 32px;
  color: white;
  animation: bounceIn 0.5s;
  box-shadow: 0 0 30px rgba(0,212,168,0.4);
}
.popup-title { font-family: 'Outfit', sans-serif; font-size: 20px; font-weight: 700; color: var(--text-primary); margin-bottom: 8px; }
.popup-msg { font-size: 13px; color: var(--text-secondary); margin-bottom: 20px; line-height: 1.6; }

/* ---- Alert / Toast ---- */
.toast {
  position: fixed;
  top: 20px; left: 50%;
  transform: translateX(-50%) translateY(-100px);
  background: var(--navy-card);
  border: 1px solid var(--glass-border);
  border-radius: var(--border-radius-sm);
  padding: 12px 20px;
  color: var(--text-primary);
  font-size: 13px;
  font-weight: 600;
  z-index: 9999;
  transition: transform 0.4s cubic-bezier(0.4,0,0.2,1);
  display: flex;
  align-items: center;
  gap: 10px;
  box-shadow: var(--shadow);
  max-width: 90%;
}
.toast.show { transform: translateX(-50%) translateY(0); }
.toast.success { border-color: var(--success); }
.toast.error { border-color: var(--danger); }
.toast.warning { border-color: var(--warning); }

/* ---- Profile Page ---- */
.profile-page { padding: 20px 16px 80px; }
.profile-header { position: relative; text-align: center; margin-bottom: 24px; }
.profile-settings-btn { position: absolute; top: 0; right: 0; background: var(--glass); border: 1px solid var(--glass-border); border-radius: 50%; width: 38px; height: 38px; display: flex; align-items: center; justify-content: center; cursor: pointer; color: var(--text-secondary); transition: var(--transition); text-decoration: none; }
.profile-settings-btn:hover { color: var(--primary); border-color: var(--primary); }
.profile-photo-wrap { position: relative; width: 90px; height: 90px; margin: 0 auto 12px; }
.profile-photo { width: 90px; height: 90px; border-radius: 50%; object-fit: cover; border: 3px solid var(--primary); box-shadow: var(--shadow-gold); }
.profile-photo-edit { position: absolute; bottom: 0; right: 0; width: 28px; height: 28px; background: var(--gold-gradient); border: none; border-radius: 50%; cursor: pointer; display: flex; align-items: center; justify-content: center; }
.profile-uid { font-size: 12px; color: var(--text-muted); margin-bottom: 4px; }
.profile-uid span { color: var(--primary); font-weight: 700; }
.profile-links { display: flex; flex-direction: column; gap: 10px; }
.profile-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--glass);
  border: 1px solid var(--glass-border);
  border-radius: var(--border-radius-sm);
  padding: 15px 16px;
  text-decoration: none;
  color: var(--text-primary);
  transition: var(--transition);
}
.profile-link:hover { background: var(--glass-hover); border-color: var(--primary); }

/* ---- Animations & Utilities ---- */
.loading-spinner {
  width: 14px; height: 14px;
  border: 2px solid rgba(26,14,0,0.3);
  border-radius: 50%;
  border-top-color: #1a0e00;
  animation: spin 0.8s linear infinite;
  display: inline-block;
}
@keyframes spin { to { transform: rotate(360deg); } }

.fade-in { animation: fadeIn 0.6s ease-out forwards; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }
.profile-link .link-left { display: flex; align-items: center; gap: 12px; }
.profile-link .link-icon { width: 36px; height: 36px; background: var(--gold-gradient-soft); border: 1px solid rgba(245,197,24,0.2); border-radius: 10px; display: flex; align-items: center; justify-content: center; }
.profile-link svg { width: 18px; height: 18px; }
.profile-link .link-text { font-size: 14px; font-weight: 600; }
.profile-link.danger { border-color: rgba(255,77,109,0.2); }
.profile-link.danger:hover { background: rgba(255,77,109,0.07); border-color: var(--danger); }
.profile-link.danger .link-icon { background: rgba(255,77,109,0.1); border-color: rgba(255,77,109,0.2); }
.profile-link.danger .link-text { color: var(--danger); }

/* ---- Stats Row ---- */
.stats-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; padding: 0 0 16px; }
.stat-card { background: var(--glass); border: 1px solid var(--glass-border); border-radius: var(--border-radius-sm); padding: 14px 16px; }
.stat-card-val { font-family: 'Outfit', sans-serif; font-size: 18px; font-weight: 700; color: var(--primary); }
.stat-card-label { font-size: 11px; color: var(--text-muted); margin-top: 3px; }

/* ---- History Page ---- */
.history-list { padding: 0; display: flex; flex-direction: column; gap: 10px; }
.history-item {
  background: var(--glass);
  border: 1px solid var(--glass-border);
  border-radius: var(--border-radius-sm);
  padding: 14px 16px;
  display: flex;
  align-items: center;
  gap: 14px;
}
.history-icon { width: 40px; height: 40px; border-radius: 12px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.history-icon.deposit { background: rgba(0,212,168,0.1); color: var(--success); }
.history-icon.withdraw { background: rgba(255,77,109,0.1); color: var(--danger); }
.history-icon.bonus { background: rgba(245,197,24,0.1); color: var(--primary); }
.history-icon.referral { background: rgba(77,166,255,0.1); color: var(--info); }
.history-icon.profit { background: rgba(0,212,168,0.1); color: var(--success); }
.history-body { flex: 1; }
.history-title { font-size: 13px; font-weight: 600; color: var(--text-primary); }
.history-date { font-size: 11px; color: var(--text-muted); margin-top: 2px; }
.history-amount { font-weight: 700; font-size: 14px; }
.history-amount.credit { color: var(--success); }
.history-amount.debit { color: var(--danger); }
.status-badge { display: inline-block; padding: 2px 8px; border-radius: 20px; font-size: 10px; font-weight: 700; }
.status-badge.pending { background: rgba(255,165,0,0.15); color: var(--warning); }
.status-badge.approved, .status-badge.paid { background: rgba(0,212,168,0.15); color: var(--success); }
.status-badge.rejected { background: rgba(255,77,109,0.15); color: var(--danger); }

/* ---- Referral Page ---- */
.referral-banner { width: 100%; border-radius: var(--border-radius); overflow: hidden; margin-bottom: 16px; }
.referral-banner img { width: 100%; height: 160px; object-fit: cover; }
.referral-qr-box { background: white; border-radius: 16px; padding: 16px; display: flex; align-items: center; justify-content: center; margin-bottom: 16px; }
.referral-qr-box img { max-width: 150px; }
.referral-link-box {
  background: var(--glass);
  border: 1px solid var(--glass-border);
  border-radius: var(--border-radius-sm);
  padding: 13px 16px;
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
}
.referral-link-text { flex: 1; font-size: 12px; color: var(--text-secondary); word-break: break-all; }
.copy-btn { background: none; border: none; color: var(--primary); cursor: pointer; flex-shrink: 0; }
.commission-levels { display: flex; gap: 10px; margin: 16px 0; }
.commission-level {
  flex: 1;
  background: var(--glass);
  border: 1px solid var(--glass-border);
  border-radius: var(--border-radius-sm);
  padding: 14px 10px;
  text-align: center;
}
.commission-pct { font-family: 'Outfit', sans-serif; font-size: 22px; font-weight: 800; background: var(--gold-gradient); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.commission-label { font-size: 11px; color: var(--text-muted); margin-top: 4px; }

/* ---- Live Chat ---- */
.chat-page { display: flex; flex-direction: column; height: 100vh; }
.chat-header { background: var(--navy-card); border-bottom: 1px solid var(--glass-border); padding: 16px 20px; display: flex; align-items: center; gap: 14px; }
.chat-admin-dp { width: 46px; height: 46px; border-radius: 50%; object-fit: cover; border: 2px solid var(--glass-border); }
.chat-admin-info { flex: 1; }
.chat-admin-name { font-weight: 700; font-size: 15px; }
.chat-status { font-size: 11px; display: flex; align-items: center; gap: 5px; }
.status-dot { width: 7px; height: 7px; border-radius: 50%; }
.status-dot.online { background: var(--success); box-shadow: 0 0 8px var(--success); }
.status-dot.offline { background: var(--text-muted); }
.chat-messages { flex: 1; overflow-y: auto; padding: 16px; display: flex; flex-direction: column; gap: 12px; }
.chat-msg { max-width: 80%; }
.chat-msg.user { align-self: flex-end; }
.chat-msg.admin { align-self: flex-start; }
.chat-bubble {
  padding: 10px 14px;
  border-radius: 18px;
  font-size: 13px;
  line-height: 1.5;
  position: relative;
}
.chat-msg.user .chat-bubble { background: var(--gold-gradient); color: #1a0e00; border-bottom-right-radius: 4px; }
.chat-msg.admin .chat-bubble { background: var(--navy-card); border: 1px solid var(--glass-border); color: var(--text-primary); border-bottom-left-radius: 4px; }
.chat-img { max-width: 200px; border-radius: 12px; }
.chat-time { font-size: 10px; color: var(--text-muted); margin-top: 4px; text-align: right; }
.chat-msg.admin .chat-time { text-align: left; }
.chat-input-wrap { border-top: 1px solid var(--glass-border); padding: 12px 16px; background: var(--navy-card); display: flex; align-items: center; gap: 10px; }
.chat-input { flex: 1; background: var(--glass); border: 1px solid var(--glass-border); border-radius: 50px; padding: 10px 16px; color: var(--text-primary); font-size: 13px; outline: none; font-family: 'Inter', sans-serif; }
.chat-input:focus { border-color: var(--primary); }
.chat-send-btn { width: 40px; height: 40px; background: var(--gold-gradient); border: none; border-radius: 50%; cursor: pointer; display: flex; align-items: center; justify-content: center; }
.chat-photo-btn { width: 36px; height: 36px; background: var(--glass); border: 1px solid var(--glass-border); border-radius: 50%; cursor: pointer; display: flex; align-items: center; justify-content: center; color: var(--text-secondary); }

/* ---- Chat Notification Badge ---- */
.chat-link-wrap { position: relative; display: inline-flex; }
.chat-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  background: #ff3b30; /* Brighter iOS style red */
  color: #fff;
  font-family: 'Outfit', sans-serif;
  font-size: 10px;
  font-weight: 800;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid #fff; /* White border as requested */
  box-shadow: 0 3px 10px rgba(255, 59, 48, 0.4);
  pointer-events: none;
  z-index: 5;
  animation: badgeIn 0.35s cubic-bezier(0.175, 0.885, 0.32, 1.35);
}
@keyframes badgeIn { from { transform: scale(0) rotate(-20deg); opacity: 0; } to { transform: scale(1) rotate(0deg); opacity: 1; } }

/* ---- Deposit Page ---- */
.amount-presets { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
.amount-preset {
  background: var(--glass);
  border: 1px solid var(--glass-border);
  border-radius: 8px;
  padding: 8px 14px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
  cursor: pointer;
  transition: var(--transition);
}
.amount-preset.active, .amount-preset:hover { background: rgba(245,197,24,0.15); border-color: var(--primary); color: var(--primary); }
.deposit-qr-card { background: white; border-radius: var(--border-radius); padding: 20px; text-align: center; margin-bottom: 16px; }
.deposit-qr-card img { max-width: 180px; margin-bottom: 12px; }
.deposit-number { background: var(--glass); border: 1px solid var(--glass-border); border-radius: var(--border-radius-sm); padding: 13px 16px; display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.deposit-info-row { background: rgba(245,197,24,0.05); border: 1px solid rgba(245,197,24,0.1); border-radius: var(--border-radius-sm); padding: 12px 14px; font-size: 12px; color: var(--text-secondary); margin-bottom: 14px; line-height: 1.8; }
.countdown-box { text-align: center; padding: 14px; background: rgba(255,77,109,0.08); border: 1px solid rgba(255,77,109,0.2); border-radius: var(--border-radius-sm); margin-bottom: 14px; }
.countdown-timer { font-family: 'Outfit', sans-serif; font-size: 28px; font-weight: 800; color: var(--danger); }
.upload-box {
  border: 2px dashed var(--glass-border);
  border-radius: var(--border-radius-sm);
  padding: 24px;
  text-align: center;
  cursor: pointer;
  transition: var(--transition);
  margin-bottom: 14px;
}
.upload-box:hover, .upload-box.dragover { border-color: var(--primary); background: rgba(245,197,24,0.03); }
.upload-box img.preview { max-width: 100%; border-radius: 8px; max-height: 200px; object-fit: contain; }
.upload-icon { width: 48px; height: 48px; color: var(--text-muted); margin: 0 auto 10px; }
.upload-text { color: var(--text-muted); font-size: 13px; }

/* ---- Page Header ---- */
.page-header {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 20px;
  border-bottom: 1px solid var(--glass-border);
}
.back-btn { background: var(--glass); border: 1px solid var(--glass-border); border-radius: 50%; width: 38px; height: 38px; display: flex; align-items: center; justify-content: center; cursor: pointer; color: var(--text-secondary); text-decoration: none; transition: var(--transition); }
.back-btn:hover { color: var(--primary); border-color: var(--primary); }
.page-header-title { font-family: 'Outfit', sans-serif; font-size: 18px; font-weight: 700; }

/* ---- Animations ---- */
@keyframes fadeInUp { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }
@keyframes slideInLeft { from { opacity: 0; transform: translateX(-20px); } to { opacity: 1; transform: translateX(0); } }
@keyframes shimmer { 0% { background-position: -200% 0; } 100% { background-position: 200% 0; } }

.fade-in { animation: fadeInUp 0.5s ease forwards; }
.slide-in { animation: slideInLeft 0.4s ease forwards; }

/* ---- Loading Skeleton ---- */
.skeleton {
  background: linear-gradient(90deg, var(--glass) 25%, rgba(255,255,255,0.06) 50%, var(--glass) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
  border-radius: 8px;
}

/* ---- Info panel ---- */
.info-notice {
  background: rgba(77,166,255,0.07);
  border: 1px solid rgba(77,166,255,0.15);
  border-radius: var(--border-radius-sm);
  padding: 12px 14px;
  font-size: 12px;
  color: var(--info);
  line-height: 1.7;
  margin-bottom: 14px;
}
.info-notice strong { display: block; margin-bottom: 4px; font-size: 13px; }

/* ---- User ID header ---- */
.user-id-bar {
  background: var(--navy-card);
  padding: 8px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--glass-border);
}
.user-id-text { font-size: 11px; color: var(--text-muted); }
.user-id-text span { color: var(--primary); font-weight: 700; }

/* ---- Responsive & Mobile Optimization ---- */
@media (max-width: 480px) {
  .app-wrapper { border-radius: 0; }
  
  /* Balance Card Scaling */
  .balance-card { padding: 18px 15px; margin: 4px 0; border-radius: 8px; width: 100%; border-left: none; border-right: none; }
  .balance-amount { font-size: 24px; }
  .balance-label { font-size: 11px; }
  .balance-btns { gap: 6px; }
  
  /* Button Scaling */
  .btn-gold, .btn-gold-outline { padding: 10px 16px; font-size: 12px; }
  .btn-sm { padding: 6px 10px; font-size: 11px; }

  /* Premium Components Scaling */
  .premium-claim-box { padding: 14px 15px !important; margin: 0 0 6px !important; border-radius: 6px; border-left: none; border-right: none; }
  .claim-title-box .main-lbl { font-size: 15px; }
  
  .plan-card.premium { padding: 12px 10px; margin: 0 0 8px; border-radius: 8px; border-left: none; border-right: none; }
  .premium-header { flex-wrap: wrap; gap: 6px; margin-bottom: 8px; }
  .premium-timer-box, .premium-timer-lbl { font-size: 10px; }
  .premium-bonus { font-size: 9px; padding: 3px 6px; }
  
  .premium-name { font-size: 14px; font-weight: 800; }
  .premium-price { font-size: 16px; font-weight: 800; }
  .purchase-btn { padding: 8px 12px; font-size: 12px; height: 34px; border-radius: 8px; }
  
  .stat-val { font-size: 12px; }
  .stat-lbl { font-size: 8px; }
  
  /* Spacing */
  .section-title { font-size: 14px; padding-left: 4px; margin-bottom: 8px; }
  .plans-list { gap: 6px; padding: 0; }
}

@media (max-width: 360px) {
  .balance-amount { font-size: 20px; }
  .premium-timer-box, .premium-bonus { font-size: 9px; }
  .header-logo-text { font-size: 12px; }
}

/* ---- Purchase Modal Styles ---- */
.plan-modal-img { width: 100%; height: 180px; object-fit: cover; border-radius: 12px; margin-bottom: 16px; }
.plan-modal-info { display: flex; justify-content: space-between; margin-bottom: 14px; }
.plan-modal-stat { text-align: center; flex: 1; }
.plan-modal-stat .val { font-family: 'Outfit', sans-serif; font-size: 16px; font-weight: 700; color: var(--primary); }
.plan-modal-stat .lbl { font-size: 10px; color: var(--text-muted); margin-top: 3px; }
.modal-close-row { display: flex; gap: 10px; }
.modal-close-row .btn-glass { flex: 1; justify-content: center; }
.modal-close-row .btn-gold { flex: 1; }
/* ---- VIP Membership Styles ---- */
.vip-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: linear-gradient(135deg, #f5c518 0%, #ffd700 50%, #d4a017 100%);
    color: #1a0e00;
    font-weight: 800;
    font-size: 10px;
    padding: 2px 6px;
    border-radius: 4px;
    text-transform: uppercase;
    box-shadow: 0 2px 10px rgba(245, 197, 24, 0.4);
    line-height: 1;
    margin-left: 6px;
}
.vip-frame {
    position: relative;
    padding: 4px;
    background: linear-gradient(45deg, #f5c518, #ffd700, #d4a017, #f5c518);
    background-size: 300% 300%;
    animation: goldRotate 4s linear infinite;
    border-radius: 50%;
    display: flex;
}
@keyframes goldRotate { 
    0% { background-position: 0% 50%; } 
    50% { background-position: 100% 50%; } 
    100% { background-position: 0% 50%; } 
}
.price-row { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.price-strike { text-decoration: line-through; color: var(--danger); font-size: 12px; opacity: 0.8; }
.vip-notice { font-size: 10px; color: var(--primary); font-weight: 700; display: block; margin-top: 2px; }
