/* ==========================================================================
   CYBERCLOUD PC - Next-Gen Cloud Gaming & Station Manager UI (Full Width & Unified)
   ========================================================================== */

/* Full Screen Edge-to-Edge Dashboard Container */
.cyber-dashboard {
  width: 100%;
  max-width: 100%;
  padding: 1.25rem 1.75rem 3.5rem 1.75rem;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  box-sizing: border-box;
}

/* ==========================================================================
   TOP UNIFIED PANEL (Circled in Red by User - Header + Stats + Filters)
   ========================================================================== */
.cyber-top-panel {
  width: 100%;
  background: #0d1424;
  border: 1px solid #1a253c;
  border-radius: 16px;
  padding: 1.4rem 1.75rem;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.45);
  box-sizing: border-box;
}

/* 1. Header Row inside Unified Top Panel */
.cyber-top-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.cyber-brand {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.cyber-brand-icon {
  width: 46px;
  height: 46px;
  background: linear-gradient(135deg, #00d2ff, #2563eb);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  color: #fff;
  box-shadow: 0 0 16px rgba(0, 210, 255, 0.4);
  flex-shrink: 0;
}

.cyber-title {
  font-size: 1.35rem;
  font-weight: 800;
  color: #f8fafc;
  letter-spacing: 0.02em;
  margin-bottom: 2px;
}

.cyber-subtitle {
  font-size: 0.82rem;
  color: #94a3b8;
}

.cyber-header-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-shrink: 0;
}

.cyber-icon-btn {
  background: #111b2f;
  border: 1px solid #1e2d4a;
  color: #cbd5e1;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.cyber-icon-btn:hover {
  background: #1a2944;
  border-color: #00d2ff;
  color: #fff;
}

.cyber-reset-btn {
  background: #111b2f;
  border: 1px solid #1e2d4a;
  color: #cbd5e1;
  padding: 0.5rem 1.1rem;
  border-radius: var(--radius-pill);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  transition: all var(--transition-fast);
}

.cyber-reset-btn:hover {
  background: #1a2944;
  border-color: #00d2ff;
  color: #00d2ff;
}

/* 2. Top Summary Stats Bar (4 Metric Cards inside Panel) */
.stats-summary-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.25rem;
  width: 100%;
}

.stat-metric-card {
  background: #090e1a;
  border: 1px solid #162035;
  border-radius: 12px;
  padding: 1.15rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
  cursor: pointer;
  transition: all var(--transition-fast);
  user-select: none;
}

.stat-metric-card:hover {
  transform: translateY(-2px);
  border-color: #2a3a5a;
  background: #0c1424;
}

.stat-metric-card.active {
  border-color: #00d2ff;
  box-shadow: 0 0 16px rgba(0, 210, 255, 0.25);
  background: #0e172a;
}

.stat-label {
  font-size: 0.85rem;
  color: #94a3b8;
  margin-bottom: 0.4rem;
}

.stat-value {
  font-size: 2.2rem;
  font-weight: 800;
  font-family: var(--font-mono);
  color: #f8fafc;
  line-height: 1;
}

.stat-value.online {
  color: #10b981;
}

.stat-value.in-use {
  color: #f43f5e;
}

.stat-value.offline {
  color: #94a3b8;
}

.stat-icon {
  font-size: 1.8rem;
  opacity: 0.9;
}

.stat-icon.blue { color: #00d2ff; }
.stat-icon.green { color: #10b981; }
.stat-icon.red { color: #f43f5e; }
.stat-icon.gray { color: #64748b; }

/* 3. Filter Bar & Search inside Panel */
.filter-search-bar {
  background: #090e1a;
  border: 1px solid #162035;
  border-radius: 12px;
  padding: 0.6rem 1.1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  width: 100%;
  box-sizing: border-box;
}

.filter-pills-group {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.filter-pill {
  background: transparent;
  border: 1px solid transparent;
  color: #94a3b8;
  padding: 0.45rem 1.1rem;
  border-radius: var(--radius-pill);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-fast);
  display: flex;
  align-items: center;
  gap: 0.45rem;
  font-family: inherit;
}

.filter-pill:hover {
  background: #111b2f;
  color: #fff;
}

.filter-pill.active {
  background: #1e3a8a;
  color: #fff;
  border-color: #3b82f6;
  box-shadow: 0 0 12px rgba(59, 130, 246, 0.4);
}

.search-input-box {
  position: relative;
  width: 280px;
}

.search-input-box input {
  width: 100%;
  background: #060911;
  border: 1px solid #1e2d4a;
  color: #fff;
  padding: 0.5rem 1rem 0.5rem 2.2rem;
  border-radius: var(--radius-pill);
  font-size: 0.85rem;
  font-family: inherit;
  outline: none;
  transition: all var(--transition-fast);
  box-sizing: border-box;
}

.search-input-box input:focus {
  border-color: #00d2ff;
  box-shadow: 0 0 12px rgba(0, 210, 255, 0.2);
}

.search-icon-fixed {
  position: absolute;
  left: 0.85rem;
  top: 50%;
  transform: translateY(-50%);
  color: #64748b;
  font-size: 0.85rem;
  pointer-events: none;
}

/* ==========================================================================
   BOTTOM PC STATIONS GRID (Exact 4 Columns Matching Top Width)
   ========================================================================== */
.pc-stations-grid {
  width: 100%;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.25rem;
  box-sizing: border-box;
}

.station-card {
  background: #0d1424;
  border: 1px solid #1a253c;
  border-radius: 16px;
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 1.25rem;
  position: relative;
  transition: all var(--transition-normal);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.35);
  box-sizing: border-box;
}

.station-card:hover {
  transform: translateY(-2px);
  border-color: #2a3a5a;
}

/* Status Variations on Station Cards */
.station-card.in-use {
  border: 1px solid rgba(244, 63, 94, 0.45);
  box-shadow: 0 0 20px rgba(244, 63, 94, 0.12);
}

.station-card.online {
  border: 1px solid rgba(16, 185, 129, 0.45);
  box-shadow: 0 0 20px rgba(16, 185, 129, 0.12);
}

.station-card.selected-active {
  border: 2px solid #00d2ff;
  box-shadow: 0 0 24px rgba(0, 210, 255, 0.3);
}

/* Station Card Header */
.station-header-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.5rem;
}

.station-info-left {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.station-monitor-badge {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.15rem;
  flex-shrink: 0;
}

.station-monitor-badge.in-use {
  background: rgba(244, 63, 94, 0.15);
  color: #f43f5e;
  border: 1px solid rgba(244, 63, 94, 0.3);
}

.station-monitor-badge.online {
  background: rgba(16, 185, 129, 0.15);
  color: #10b981;
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.station-monitor-badge.offline {
  background: rgba(100, 116, 139, 0.15);
  color: #94a3b8;
  border: 1px solid rgba(100, 116, 139, 0.3);
}

.station-title {
  font-size: 0.95rem;
  font-weight: 700;
  color: #f8fafc;
  line-height: 1.2;
}

.station-subtitle {
  font-size: 0.7rem;
  color: #64748b;
  font-weight: 600;
  letter-spacing: 0.05em;
  margin-top: 2px;
}

/* Status Pill on top-right of card */
.station-status-pill {
  font-size: 0.68rem;
  font-weight: 700;
  padding: 0.25rem 0.65rem;
  border-radius: var(--radius-pill);
  white-space: nowrap;
  letter-spacing: 0.02em;
}

.station-status-pill.in-use {
  background: rgba(244, 63, 94, 0.18);
  color: #f43f5e;
  border: 1px solid rgba(244, 63, 94, 0.4);
}

.station-status-pill.online {
  background: rgba(16, 185, 129, 0.18);
  color: #10b981;
  border: 1px solid rgba(16, 185, 129, 0.4);
}

.station-status-pill.offline {
  background: rgba(100, 116, 139, 0.18);
  color: #94a3b8;
  border: 1px solid rgba(100, 116, 139, 0.4);
}

/* 2x2 Specs Grid */
.station-specs-grid {
  background: #090e1a;
  border: 1px solid #162035;
  border-radius: 10px;
  padding: 0.85rem 1rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.65rem 1rem;
}

.spec-node {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.78rem;
  color: #cbd5e1;
  font-weight: 500;
}

.spec-node span.spec-icon {
  font-size: 0.85rem;
  color: #00d2ff;
  opacity: 0.85;
}

/* Station Card Footer */
.station-footer-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid #162035;
  padding-top: 0.85rem;
}

.station-rate {
  font-size: 1.15rem;
  font-weight: 800;
  color: #f8fafc;
  font-family: var(--font-mono);
}

.station-rate span {
  font-size: 0.75rem;
  color: #64748b;
  font-weight: 500;
}

/* Action Buttons */
.station-action-btn {
  padding: 0.5rem 1rem;
  border-radius: var(--radius-pill);
  font-size: 0.82rem;
  font-weight: 700;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  transition: all var(--transition-fast);
  font-family: inherit;
  white-space: nowrap;
}

.station-action-btn.in-use {
  background: rgba(244, 63, 94, 0.15);
  color: #f43f5e;
  border: 1px solid rgba(244, 63, 94, 0.35);
  cursor: not-allowed;
}

.station-action-btn.online {
  background: #00d2ff;
  color: #030712;
  box-shadow: 0 0 16px rgba(0, 210, 255, 0.4);
}

.station-action-btn.online:hover {
  background: #33dcff;
  box-shadow: 0 0 24px rgba(0, 210, 255, 0.6);
  transform: translateY(-1px);
}

.station-action-btn.offline {
  background: #f59e0b;
  color: #030712;
  box-shadow: 0 0 16px rgba(245, 158, 11, 0.3);
}

.station-action-btn.offline:hover {
  background: #fbbf24;
  box-shadow: 0 0 22px rgba(245, 158, 11, 0.5);
  transform: translateY(-1px);
}

/* Mobile Device Connect Tabs & Styles */
.remote-device-tabs {
  display: flex;
  gap: 0.5rem;
  background: #060a14;
  padding: 0.35rem;
  border-radius: 12px;
  border: 1px solid #1a253c;
  margin-bottom: 1.25rem;
}

.device-tab-btn {
  flex: 1;
  background: transparent;
  border: none;
  color: #94a3b8;
  padding: 0.55rem 0.75rem;
  border-radius: 8px;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  transition: all var(--transition-fast);
  font-family: inherit;
}

.device-tab-btn:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.04);
}

.device-tab-btn.active {
  background: #1e3a8a;
  color: #fff;
  box-shadow: 0 0 12px rgba(37, 99, 235, 0.4);
}

.device-tab-content {
  display: none;
}

.device-tab-content.active {
  display: block;
}

/* Mobile QR Connect Card */
.mobile-qr-grid {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 1.25rem;
  align-items: center;
  background: #090e1a;
  border: 1px solid #1a253c;
  border-radius: 12px;
  padding: 1.25rem;
  margin-bottom: 1rem;
}

.qr-code-wrapper {
  background: #ffffff;
  padding: 0.75rem;
  border-radius: 10px;
  text-align: center;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
}

.mobile-instructions-box {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.mobile-step-pill {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.82rem;
  color: #cbd5e1;
}

.mobile-step-num {
  width: 22px;
  height: 22px;
  background: #1e3a8a;
  color: #00d2ff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
  flex-shrink: 0;
}

.store-badges-row {
  display: flex;
  gap: 0.6rem;
  flex-wrap: wrap;
  margin-top: 0.5rem;
}

.store-badge-btn {
  background: #111b2f;
  border: 1px solid #1e2d4a;
  color: #fff;
  padding: 0.4rem 0.85rem;
  border-radius: 8px;
  font-size: 0.78rem;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  text-decoration: none;
  transition: all var(--transition-fast);
}

.store-badge-btn:hover {
  background: #1a2944;
  border-color: #00d2ff;
  transform: translateY(-1px);
}

.touch-gestures-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
  margin-top: 0.85rem;
}

/* ==========================================================================
   noVNC HTML5 IN-BROWSER REMOTE VIEWPORT (FULLY RESPONSIVE FOR ALL SCREENS)
   ========================================================================== */

#cyber-remote-modal {
  padding: 0 !important;
  background: rgba(0, 0, 0, 0.95);
  backdrop-filter: blur(16px);
  z-index: 99999;
}

.novnc-modal-dialog {
  max-width: 100vw;
  width: 100vw;
  height: 100vh;
  height: 100dvh;
  max-height: 100vh;
  max-height: 100dvh;
  display: flex;
  flex-direction: column;
  background: #000;
  border-radius: 0;
  border: none;
  overflow: hidden;
  box-shadow: none;
  padding: 0;
  margin: 0;
}

#cyber-remote-modal.is-fullscreen,
#cyber-remote-modal.is-fullscreen .novnc-modal-dialog {
  position: fixed !important;
  inset: 0 !important;
  width: 100vw !important;
  height: 100vh !important;
  height: 100dvh !important;
  z-index: 9999999 !important;
}

.novnc-top-bar {
  background: rgba(8, 13, 24, 0.95);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  padding: 0.35rem 0.75rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  flex-shrink: 0;
  height: 40px;
  z-index: 100;
}

.novnc-machine-info {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.novnc-live-dot {
  width: 9px;
  height: 9px;
  background: #10b981;
  border-radius: 50%;
  box-shadow: 0 0 10px #10b981;
  animation: pulseDot 2s infinite ease-in-out;
}

.novnc-station-title {
  font-size: 0.9rem;
  font-weight: 800;
  color: #f8fafc;
}

.novnc-station-sub {
  font-size: 0.7rem;
  color: #94a3b8;
}

.novnc-actions-bar {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  flex-wrap: wrap;
}

/* noVNC Canvas & Iframe Viewport Container */
.novnc-canvas-wrapper {
  flex: 1;
  width: 100vw;
  height: calc(100vh - 40px);
  height: calc(100dvh - 40px);
  position: relative;
  background: #000;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

#novnc-remote-iframe {
  width: 100%;
  height: 100%;
  border: none;
  background: #000;
  display: block;
}

/* Responsive Rules for iPad, Tablet & Mobile */
@media (max-width: 1024px) {
  .novnc-top-bar {
    padding: 0.25rem 0.5rem;
    height: 36px;
  }
  .novnc-station-sub {
    display: none;
  }
  .novnc-canvas-wrapper {
    height: calc(100vh - 36px);
    height: calc(100dvh - 36px);
  }
  .novnc-actions-bar .btn {
    padding: 0.25rem 0.45rem;
    font-size: 0.72rem;
  }
}

/* ==========================================================================
   TOP-UP & PROMPTPAY MODAL STYLING
   ========================================================================== */

#cyber-topup-modal {
  position: fixed !important;
  inset: 0 !important;
  width: 100vw !important;
  height: 100vh !important;
  height: 100dvh !important;
  background: rgba(4, 7, 13, 0.88) !important;
  backdrop-filter: blur(12px) !important;
  -webkit-backdrop-filter: blur(12px) !important;
  z-index: 99999 !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 1.5rem !important;
  opacity: 0 !important;
  visibility: hidden !important;
  pointer-events: none !important;
  transition: opacity 0.25s ease, visibility 0.25s ease !important;
}

#cyber-topup-modal.show {
  opacity: 1 !important;
  visibility: visible !important;
  pointer-events: auto !important;
}

.topup-modal-card {
  background: #0d1424 !important;
  border: 1px solid #1a253c !important;
  border-radius: 16px !important;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.6), 0 0 30px rgba(0, 210, 255, 0.15) !important;
  width: 100% !important;
  max-width: 580px !important;
  max-height: 90vh !important;
  overflow-y: auto !important;
  transform: scale(0.95) translateY(10px) !important;
  transition: all 0.25s ease !important;
}

#admin-queue-modal-backdrop,
#staff-login-modal-backdrop {
  position: fixed !important;
  top: 0 !important;
  left: 0 !important;
  right: 0 !important;
  bottom: 0 !important;
  width: 100vw !important;
  height: 100vh !important;
  background: rgba(4, 7, 15, 0.88) !important;
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
  z-index: 99999 !important;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

#admin-queue-modal-backdrop.show,
#staff-login-modal-backdrop.show {
  display: flex !important;
}

.cyber-modal-card.wide {
  background: #0d1424 !important;
  border: 1px solid rgba(168, 85, 247, 0.35) !important;
  border-radius: 16px !important;
  box-shadow: 0 15px 50px rgba(0, 0, 0, 0.7), 0 0 35px rgba(168, 85, 247, 0.2) !important;
  width: 100% !important;
  max-width: 780px !important;
  max-height: 90vh !important;
  overflow-y: auto !important;
}

.cyber-modal-header {
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid #1a253c;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}

.cyber-modal-close {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #94a3b8;
  font-size: 1.15rem;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
  line-height: 1;
  padding: 0;
}

.cyber-modal-close:hover {
  background: rgba(239, 68, 68, 0.2);
  border-color: rgba(239, 68, 68, 0.5);
  color: #ef4444;
  transform: scale(1.05);
}

.modal-title-wrap .modal-title {
  font-size: 1.15rem;
  font-weight: 800;
  color: #f8fafc;
}

.modal-title-wrap .modal-subtitle {
  font-size: 0.78rem;
  color: #94a3b8;
  margin-top: 0.2rem;
}

/* Portal Tab Switcher (3-in-1 Header) */
.portal-tabs-nav {
  display: flex;
  background: #060a14;
  padding: 0.35rem 0.5rem;
  border-bottom: 1px solid #1a253c;
  gap: 0.5rem;
}

.portal-tab-btn, .cyber-tab-btn {
  flex: 1;
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: #94a3b8;
  padding: 0.55rem 0.75rem;
  border-radius: 8px;
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  transition: all 0.2s ease;
  font-family: inherit;
}

.portal-tab-btn.active, .cyber-tab-btn.active {
  background: rgba(168, 85, 247, 0.15) !important;
  color: #c084fc !important;
  border-color: rgba(168, 85, 247, 0.4) !important;
}

.portal-tab-btn:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.05);
}

.portal-tab-btn.active {
  background: linear-gradient(135deg, rgba(2, 132, 199, 0.25), rgba(0, 210, 255, 0.2));
  color: #00d2ff;
  border: 1px solid rgba(0, 210, 255, 0.35);
  box-shadow: 0 0 12px rgba(0, 210, 255, 0.2);
}

/* Member Topup Tiers Grid */
.topup-tiers-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
}

@media (max-width: 580px) {
  .topup-tiers-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.topup-tier-card {
  background: rgba(15, 23, 42, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  padding: 0.85rem;
  cursor: pointer;
  transition: all 0.2s ease;
  text-align: center;
}

.topup-tier-card:hover {
  border-color: rgba(0, 210, 255, 0.4);
  background: rgba(15, 23, 42, 0.9);
  transform: translateY(-2px);
}

.topup-tier-card.selected {
  border: 2px solid #00d2ff;
  background: rgba(0, 210, 255, 0.1);
  box-shadow: 0 0 16px rgba(0, 210, 255, 0.3);
}

.tier-badge {
  font-size: 0.7rem;
  font-weight: 700;
  color: #00d2ff;
  background: rgba(0, 210, 255, 0.15);
  padding: 0.15rem 0.4rem;
  border-radius: 4px;
  display: inline-block;
  margin-bottom: 0.35rem;
}

.tier-price {
  font-size: 1.35rem;
  font-weight: 800;
  color: #10b981;
  font-family: var(--font-mono);
}

.tier-desc {
  font-size: 0.72rem;
  color: #94a3b8;
  margin-top: 0.2rem;
}

/* Registration Form Layouts */
.form-grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.85rem;
}

@media (max-width: 580px) {
  .form-grid-2 {
    grid-template-columns: 1fr;
  }
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}

.form-label {
  font-size: 0.78rem;
  font-weight: 600;
  color: #cbd5e1;
}

.form-group .cyber-input {
  width: 100%;
  padding: 0.6rem 0.8rem;
  border-radius: 8px;
  border: 1px solid #1a253c;
  background: #070b14;
  color: #fff;
  font-size: 0.88rem;
  transition: border-color 0.2s ease;
}

.form-group .cyber-input:focus {
  outline: none;
  border-color: #00d2ff;
  box-shadow: 0 0 8px rgba(0, 210, 255, 0.25);
}

.cyber-topup-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  background: linear-gradient(135deg, #0284c7 0%, #00d2ff 100%);
  color: #0b0f19;
  font-weight: 800;
  font-size: 0.82rem;
  padding: 0.42rem 0.95rem;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  box-shadow: 0 0 16px rgba(0, 210, 255, 0.35);
  transition: all 0.2s ease;
}

.cyber-topup-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 0 24px rgba(0, 210, 255, 0.6);
  filter: brightness(1.1);
}

.packages-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.85rem;
}

@media (max-width: 580px) {
  .packages-grid {
    grid-template-columns: 1fr;
  }
}

.package-card {
  background: rgba(15, 23, 42, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 1rem;
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
}

.package-card:hover {
  border-color: rgba(0, 210, 255, 0.4);
  background: rgba(15, 23, 42, 0.9);
  transform: translateY(-2px);
}

.package-card.selected {
  border: 2px solid #00d2ff;
  background: rgba(0, 210, 255, 0.08);
  box-shadow: 0 0 20px rgba(0, 210, 255, 0.25);
}

.pkg-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.45rem;
}

.pkg-badge {
  font-size: 0.7rem;
  font-weight: 700;
  color: #00d2ff;
  background: rgba(0, 210, 255, 0.15);
  padding: 0.2rem 0.5rem;
  border-radius: 6px;
}

.pkg-price {
  font-size: 1.2rem;
  font-weight: 800;
  color: #10b981;
}

.pkg-title {
  font-size: 0.92rem;
  font-weight: 700;
  color: #f8fafc;
  margin-bottom: 0.25rem;
}

.pkg-desc {
  font-size: 0.75rem;
  color: #94a3b8;
  line-height: 1.35;
}

.cyber-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.6rem 1.15rem;
  border-radius: 8px;
  font-weight: 700;
  font-size: 0.85rem;
  cursor: pointer;
  border: none;
  transition: all 0.2s ease;
}

.cyber-btn.primary {
  background: linear-gradient(135deg, #0284c7 0%, #00d2ff 100%);
  color: #0b0f19;
  box-shadow: 0 0 16px rgba(0, 210, 255, 0.3);
}

.cyber-btn.primary:hover {
  filter: brightness(1.1);
  box-shadow: 0 0 22px rgba(0, 210, 255, 0.5);
}

.cyber-btn.secondary {
  background: rgba(255, 255, 255, 0.08);
  color: #cbd5e1;
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.cyber-btn.secondary:hover {
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
}

.cyber-btn.success {
  background: linear-gradient(135deg, #059669 0%, #10b981 100%);
  color: #fff;
  box-shadow: 0 0 16px rgba(16, 185, 129, 0.3);
}

.cyber-btn.success:hover {
  filter: brightness(1.1);
  box-shadow: 0 0 22px rgba(16, 185, 129, 0.5);
}

/* Ensure Toast Notifications Always Display Above All Modals in Bottom-Right */
.toast-container {
  position: fixed !important;
  bottom: 24px !important;
  right: 24px !important;
  z-index: 99999999 !important;
  display: flex !important;
  flex-direction: column !important;
  gap: 10px !important;
  pointer-events: none !important;
}

.toast {
  pointer-events: auto !important;
  z-index: 99999999 !important;
}

/* ==========================================================================
   FLOATING CREDENTIALS PIN WIDGET (หน้าต่างลอยแสดงรหัสผ่าน CafeThai ค้างไว้บนหน้าจอ)
   ========================================================================== */
.floating-credentials-widget {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 999999;
  width: 330px;
  max-width: calc(100vw - 32px);
  background: linear-gradient(135deg, rgba(13, 20, 36, 0.96), rgba(15, 23, 42, 0.98));
  border: 1.5px solid rgba(0, 210, 255, 0.45);
  border-radius: 14px;
  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.7), 0 0 25px rgba(0, 210, 255, 0.25);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  color: #f8fafc;
  overflow: hidden;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  box-sizing: border-box;
  animation: floatWidgetIn 0.3s ease-out;
}

@keyframes floatWidgetIn {
  from {
    opacity: 0;
    transform: translateY(20px) scale(0.95);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.floating-credentials-widget.minimized {
  width: auto;
  min-width: 250px;
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.96), rgba(14, 116, 144, 0.95));
  border: 1.5px solid #00d2ff;
  box-shadow: 0 6px 25px rgba(0, 210, 255, 0.4);
}

.floating-cred-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.65rem 0.85rem;
  background: rgba(0, 210, 255, 0.08);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.floating-cred-title-wrap {
  display: flex;
  align-items: center;
  gap: 0.45rem;
}

.floating-cred-ctrls {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.floating-icon-btn {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #94a3b8;
  width: 26px;
  height: 26px;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  cursor: pointer;
  transition: all 0.15s ease;
  line-height: 1;
}

.floating-icon-btn:hover {
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
}

.floating-icon-btn.close:hover {
  background: rgba(239, 68, 68, 0.3);
  border-color: rgba(239, 68, 68, 0.5);
  color: #fca5a5;
}

.floating-cred-body {
  padding: 0.85rem;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.floating-cred-field {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 8px;
  padding: 0.45rem 0.65rem;
  gap: 0.5rem;
}

.floating-cred-field-info {
  text-align: left;
  overflow: hidden;
}

.floating-cred-field-label {
  font-size: 0.7rem;
  color: #94a3b8;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  margin-bottom: 2px;
}

.floating-cred-field-val {
  font-size: 1.05rem;
  font-weight: 800;
  font-family: var(--font-mono, monospace);
  color: #ffffff;
  letter-spacing: 0.5px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.floating-cred-field-val.cyan {
  color: #00d2ff;
}

.floating-cred-field-val.green {
  color: #10b981;
}

.floating-copy-btn {
  background: rgba(0, 210, 255, 0.12);
  border: 1px solid rgba(0, 210, 255, 0.3);
  color: #38bdf8;
  padding: 0.3rem 0.6rem;
  border-radius: 6px;
  font-size: 0.75rem;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  flex-shrink: 0;
  transition: all 0.15s ease;
}

.floating-copy-btn:hover {
  background: #00d2ff;
  color: #050b14;
  box-shadow: 0 0 10px rgba(0, 210, 255, 0.4);
}

.floating-cred-actions {
  display: flex;
  gap: 0.5rem;
  margin-top: 0.25rem;
}

.floating-btn {
  flex: 1;
  padding: 0.45rem 0.65rem;
  border-radius: 6px;
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.3rem;
  border: none;
  transition: all 0.15s ease;
}

.floating-btn.primary {
  background: linear-gradient(135deg, #0284c7, #00d2ff);
  color: #050b14;
}

.floating-btn.primary:hover {
  filter: brightness(1.1);
  box-shadow: 0 0 12px rgba(0, 210, 255, 0.4);
}

.floating-btn.secondary {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #cbd5e1;
}

.floating-btn.secondary:hover {
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
}

.floating-cred-footer-hint {
  font-size: 0.68rem;
  color: #64748b;
  text-align: center;
  margin-top: 0.1rem;
}

/* Minimized Floating Pill */
.floating-pill-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.4rem 0.75rem;
  gap: 0.6rem;
  cursor: pointer;
}

.floating-pill-left {
  display: flex;
  align-items: center;
  gap: 0.45rem;
}

.floating-pill-pulse {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #00d2ff;
  box-shadow: 0 0 8px #00d2ff;
  animation: pulsePill 2s infinite;
}

@keyframes pulsePill {
  0% { transform: scale(0.95); opacity: 0.8; }
  50% { transform: scale(1.2); opacity: 1; }
  100% { transform: scale(0.95); opacity: 0.8; }
}

@media (max-width: 600px) {
  .floating-credentials-widget {
    right: 16px;
    bottom: 16px;
    width: calc(100vw - 32px);
  }
}

