/* Modern Overlay bypassing old CSS rules completely */
.ddice-modal-overlay {
  display: none; position: fixed; inset: 0;
  background: rgba(15, 23, 42, 0.7); backdrop-filter: blur(5px);
  z-index: 99999; align-items: center; justify-content: center;
  padding: 15px; font-family: 'Arial', sans-serif;
}
.ddice-modal-overlay.visible { display: flex; animation: fadeIn 0.3s ease; }

@keyframes fadeIn { from { opacity: 0; transform: scale(0.95); } to { opacity: 1; transform: scale(1); } }

/* Modern Card */
.ddice-modal-card {
  background: #ffffff; width: 100%; max-width: 420px;
  border-radius: 20px; padding: 25px; box-shadow: 0 15px 35px rgba(0,0,0,0.2);
  position: relative; max-height: 90vh; overflow-y: auto;
  border: 1px solid #E2E8F0;
}

/* Close Button */
.ddice-close-btn {
  position: absolute; top: 15px; right: 15px;
  background: #E2E8F0; border: none; width: 32px; height: 32px;
  border-radius: 50%; font-size: 20px; color: #263147;
  cursor: pointer; display: flex; align-items: center; justify-content: center;
  transition: all 0.2s;
}
.ddice-close-btn:hover { background: #d32f2f; color: #fff; transform: rotate(90deg); }

/* Header & Avatar */
.ddice-profile-header { text-align: center; margin-bottom: 20px; }
.ddice-avatar-ring {
  width: 76px; height: 76px; margin: 0 auto 10px;
  border-radius: 50%; padding: 3px; background: linear-gradient(135deg, #00BFAF, #263147);
}
.ddice-avatar-img { width: 100%; height: 100%; border-radius: 50%; border: 2px solid #fff; object-fit: cover; }
.ddice-user-name { font-size: 20px; color: #263147; margin: 0 0 10px 0; font-weight: bold; }
.ddice-balance-badge {
  display: inline-flex; align-items: center; gap: 8px; background: #E2E8F0;
  padding: 8px 16px; border-radius: 30px; color: #263147; font-size: 14px;
}
.ddice-balance-badge strong { font-size: 18px; color: #00BFAF; }

/* Grid Buttons */
.ddice-action-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 20px; }
button[class^="ddice-btn"] {
  border: none; border-radius: 12px; padding: 12px; font-weight: bold; font-size: 14px;
  cursor: pointer; display: flex; align-items: center; justify-content: center; gap: 6px;
  transition: transform 0.1s, opacity 0.2s;
}
button[class^="ddice-btn"]:active { transform: scale(0.95); }

.ddice-btn-primary { background: #00BFAF; color: #fff; box-shadow: 0 4px 12px rgba(0,191,175,0.3); }
.ddice-btn-secondary { background: #263147; color: #fff; box-shadow: 0 4px 12px rgba(38,49,71,0.3); }
.ddice-btn-outline { background: #f1f5f9; color: #263147; border: 1px solid #cbd5e1; }
.ddice-btn-danger { background: #fee2e2; color: #d32f2f; }
.ddice-full-width { width: 100%; }
.ddice-btn-group { display: flex; gap: 10px; margin-top: 15px; }

/* Form Styles */
.ddice-form-card { background: #f8fafc; padding: 18px; border-radius: 16px; border: 1px solid #e2e8f0; animation: fadeIn 0.3s ease; }
.ddice-form-card.hidden { display: none; }
.ddice-form-title { margin: 0 0 15px 0; color: #263147; font-size: 16px; border-bottom: 2px solid #E2E8F0; padding-bottom: 8px;}
.ddice-input-group { margin-bottom: 12px; text-align: left; }
.ddice-input-group label { display: block; font-size: 13px; color: #475569; margin-bottom: 6px; font-weight: bold; }
.ddice-input {
  width: 100%; padding: 12px; border: 1px solid #cbd5e1; border-radius: 8px;
  font-size: 14px; background: #fff; outline: none; transition: border 0.3s; box-sizing: border-box;
}
.ddice-input:focus { border-color: #00BFAF; box-shadow: 0 0 0 3px rgba(0,191,175,0.1); }

/* Dynamic Copy Box for Deposit */
.ddice-send-to-box { background: #e0f2fe; padding: 1px; border-radius: 8px; margin-bottom: 15px; border: 1px dashed #7dd3fc; }
.ddice-send-to-box.hidden { display: none; }
.ddice-send-label { font-size: 12px; color: #0284c7; display: block; margin-bottom: -4px; }
.ddice-copy-wrapper { display: flex; justify-content: space-between; align-items: center; }
.ddice-highlight-text { font-size: 16px; font-weight: bold; color: #0369a1; letter-spacing: 1px; }
.ddice-copy-icon-btn { background: #0ea5e9; color: #fff; border: none; padding: 4px 10px; border-radius: 4px; cursor: pointer; font-size: 12px; }
.ddice-copy-success { font-size: 12px; color: #16a34a; display: block; margin-top: 4px; font-weight: bold; }

/* ⭐⭐⭐ COMING SOON BADGE - নতুন স্টাইল ⭐⭐⭐ */
.ddice-coming-soon-badge {
  display: inline-block;
  background: linear-gradient(135deg, #f59e0b, #d97706);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 20px;
  margin-left: 8px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  animation: pulseComingSoon 1.8s ease-in-out infinite;
  box-shadow: 0 2px 8px rgba(245, 158, 11, 0.3);
}

/* Coming Soon মেসেজ বক্স - যেখানে পুরো মেসেজ দেখাবে */
.ddice-coming-soon-box {
  background: #fffbeb;
  border: 2px dashed #f59e0b;
  border-radius: 12px;
  padding: 16px 20px;
  text-align: center;
  margin: 12px 0;
  animation: pulseComingSoon 2s ease-in-out infinite;
}

.ddice-coming-soon-box .icon {
  font-size: 32px;
  display: block;
  margin-bottom: 6px;
}

.ddice-coming-soon-box .title {
  font-size: 18px;
  font-weight: 700;
  color: #92400e;
  margin: 0;
}

.ddice-coming-soon-box .subtitle {
  font-size: 14px;
  color: #78350f;
  margin: 4px 0 0 0;
}

@keyframes pulseComingSoon {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.7; transform: scale(1.02); }
}

/* History Tables */
.ddice-info-container { margin-bottom: 10px; }
.ddice-table-wrapper { overflow-x: auto; border-radius: 8px; border: 1px solid #e2e8f0; }
.ddice-table { width: 100%; border-collapse: collapse; font-size: 13px; text-align: left; background: #fff; }
.ddice-table th { background: #263147; color: #fff; padding: 10px; white-space: nowrap; }
.ddice-table td { 
  padding: 10px; 
  border-bottom: 1px solid #e2e8f0; 
  color: #334155; 
  white-space: nowrap;
}
.ddice-table tr:last-child td { border-bottom: none; }
.ddice-win-text { color: #16a34a; font-weight: bold; }
.ddice-loss-text { color: #d32f2f; font-weight: bold; }
.ddice-alert-msg { color: #d32f2f; font-size: 13px; min-height: 18px; margin-bottom: 10px; font-weight: bold; text-align: center; }

/* Scrollbar Customization for Modal */
.ddice-modal-card::-webkit-scrollbar { width: 6px; }
.ddice-modal-card::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 10px; }






/* ==========================================================================
   MY ACCOUNT FLOATING BUTTON (Bottom-Left) - Fixed Size (ALL MODES)
   ========================================================================== */
#showProfileBtn {
  position: fixed;
  left: 18px;
  bottom: 18px;
  z-index: 9998;
  display: inline-flex; /* inline-flex ব্যবহার করলে width auto থাকবে */
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 16px;
  border: 2px solid var(--accent);
  border-radius: 999px;
  letter-spacing: .3px;
  color: var(--light);
  font-weight: 900;
  background: var(--dark);
  box-shadow: 0 4px 12px var(--shadow-heavy);
  cursor: pointer;
  transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
  text-transform: uppercase;
  font-size: 12px;
  white-space: nowrap;

  /* 🔥 মূল ফিক্স: কখনোই পুরো প্রস্থ নেবে না */
  width: auto !important;
  max-width: fit-content !important;
  min-width: 0 !important;
  flex-shrink: 0;
  flex-grow: 0;
}

/* ডট (সবুজ বিন্দু) */
#showProfileBtn .dot {
  width: 10px;
  height: 10px;
  background-color: #00ff00;
  border-radius: 50%;
  display: inline-block;
  animation: online-pulse 1.5s infinite;
  flex-shrink: 0;
}

#showProfileBtn:hover { 
  background: var(--accent); 
  color: var(--dark);
  border-color: var(--dark);
}

#showProfileBtn:active { 
  transform: translateY(2px); 
}

/* ============================================================
   মোবাইল পোর্ট্রেট ও ল্যান্ডস্কেপ - উভয় মোডেই সাইজ স্থির
   ============================================================ */
@media (max-width: 768px) {
  #showProfileBtn {
    padding: 10px 16px;
    font-size: 12px;
    gap: 8px;
    left: 14px;
    bottom: 14px;
    width: auto !important;
    max-width: fit-content !important;
  }
  #showProfileBtn .dot {
    width: 10px;
    height: 10px;
  }
}

/* 🔥 ল্যান্ডস্কেপ মোডের জন্য আলাদা ফিক্স */
@media (max-width: 768px) and (orientation: landscape) {
  #showProfileBtn {
    padding: 10px 16px;
    font-size: 12px;
    gap: 8px;
    left: 12px;
    bottom: 12px;
    border-width: 2px;
    width: auto !important;
    max-width: fit-content !important;
  }
  #showProfileBtn .dot {
    width: 10px;
    height: 10px;
  }
}

/* ============================================================
   খুব ছোট স্ক্রিনেও সাইজ একই থাকবে (যেমন: 320px width)
   ============================================================ */
@media (max-width: 400px) {
  #showProfileBtn {
    padding: 8px 14px;
    font-size: 11px;
    gap: 6px;
    left: 10px;
    bottom: 10px;
    width: auto !important;
    max-width: fit-content !important;
  }
  #showProfileBtn .dot {
    width: 8px;
    height: 8px;
  }
}









/* Conversion Hint */
.ddice-conversion-hint {
  background-color: #263147;
  color: #00BFAF;
  padding: 10px 12px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  margin-bottom: 15px;
  text-align: center;
  border-left: 3px solid #00BFAF;
  transition: all 0.2s ease;
  line-height: 1.5;
}

@keyframes fadeInSlide {
  from { opacity: 0; transform: translateY(-10px); }
  to { opacity: 1; transform: translateY(0); }
}
