/* ============================================================
   FORZZA MOBILE — Premium Glassmorphic 3D Theme & GPU Acceleration
   ============================================================ */

/* Authentic Forzza Mobile Splash Loading Screen */
.fz-splash {
  position: fixed !important;
  inset: 0 !important;
  z-index: 999999 !important;
  background: #0074c1 !important;
  background: linear-gradient(180deg, #0d7ac7 0%, #005b96 100%) !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
  opacity: 1;
  visibility: visible;
  transition: opacity 0.3s cubic-bezier(0.4, 0, 0.2, 1), visibility 0.3s !important;
  will-change: opacity, transform;
}

.fz-splash.hide {
  opacity: 0 !important;
  visibility: hidden !important;
  pointer-events: none !important;
}

.fz-splash-spinner {
  width: 40px !important;
  height: 40px !important;
  border: 3.5px solid rgba(255, 255, 255, 0.22) !important;
  border-top-color: #ffffff !important;
  border-radius: 50% !important;
  animation: fz-splash-spin 0.8s linear infinite !important;
  margin-bottom: 26px !important;
  box-sizing: border-box !important;
}

@keyframes fz-splash-spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.fz-splash-logo {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.25)) !important;
}

/* Base HTML & Body (No Overflow) */
html, body {
  margin: 0;
  padding: 0;
  min-height: 100%;
  max-width: 100vw;
  overflow-x: hidden !important;
  background: #ffffff;
  color: #183247;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  -webkit-tap-highlight-color: transparent;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.fz-app {
  max-width: 480px;
  margin: 0 auto;
  min-height: 100vh;
  background: #ffffff;
  position: relative;
  box-sizing: border-box;
  overflow-x: hidden;
}

/* 1. Premium Glassmorphic 3D Header (.fz-topbar) */
.fz-topbar {
  height: 48px !important;
  background: rgba(28, 28, 28, 0.88) !important;
  backdrop-filter: blur(12px) !important;
  -webkit-backdrop-filter: blur(12px) !important;
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex !important;
  align-items: center;
  justify-content: space-between;
  padding: 0 12px !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08) !important;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.25) !important;
  box-sizing: border-box;
}

.fz-topbar .fz-title {
  color: #ffffff !important;
  font-size: 16px !important;
  font-weight: 500 !important;
  text-align: center;
  flex: 1;
  letter-spacing: 0.2px;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.4);
}

.fz-topbar .fz-menu {
  background: transparent;
  border: 0;
  width: 32px;
  height: 32px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-end;
  gap: 4.5px;
  padding: 0;
  cursor: pointer;
  will-change: transform;
  transform: translateZ(0);
  transition: transform 0.12s ease;
}

.fz-topbar .fz-menu:active {
  transform: scale(0.92) translateZ(0);
}

.fz-topbar .fz-menu span {
  display: block;
  width: 22px;
  height: 2.5px;
  background: #ffffff;
  border-radius: 2px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.fz-topbar .fz-back {
  background: transparent;
  border: 0;
  color: #ffffff;
  font-size: 24px;
  cursor: pointer;
  display: none;
  width: 32px;
  height: 32px;
  padding: 0;
  line-height: 1;
  position: relative;
  will-change: transform;
  transform: translateZ(0);
}

.fz-topbar .fz-back:after {
  content: '‹';
  font-size: 28px;
  position: absolute;
  left: 4px;
  top: -2px;
}

.fz-topbar.sub .fz-back {
  display: block !important;
}

/* Main Content Area */
.fz-content {
  box-sizing: border-box;
  background: #ffffff;
  padding-bottom: 64px;
}

/* 2. Home Grid: Preserved Tight 4px Gap */
.fz-home-grid {
  display: grid !important;
  grid-template-columns: repeat(3, 1fr) !important;
  gap: 4px !important;
  padding: 4px !important;
  background: #ffffff !important;
  box-sizing: border-box !important;
  width: 100% !important;
}

.fz-spacer {
  display: none !important;
}

/* 2. 12 Home Tiles: GPU Accelerated 60fps & Touch Feedback (scale 0.955) */
.fz-tile {
  position: relative !important;
  aspect-ratio: 1 / 1 !important;
  background: #0074c1 !important;
  background: linear-gradient(180deg, #0d7ac7 0%, #0066a9 100%) !important;
  border: 1px solid rgba(255, 255, 255, 0.16) !important;
  border-radius: 4px !important;
  overflow: hidden !important;
  display: block !important;
  text-decoration: none !important;
  box-sizing: border-box;
  box-shadow: 0 2px 5px rgba(0, 60, 120, 0.18), 0 1px 0 rgba(255, 255, 255, 0.15) inset !important;
  will-change: transform;
  transform: translateZ(0);
  transition: transform 0.12s cubic-bezier(0.2, 0.8, 0.2, 1), filter 0.12s ease !important;
  user-select: none;
}

.fz-tile:active {
  transform: scale(0.955) translateZ(0) !important;
  filter: brightness(0.92) !important;
}

.fz-tile .tile-icon {
  position: absolute !important;
  left: 50% !important;
  top: 42% !important;
  transform: translate(-50%, -50%) !important;
  width: 76% !important;
  height: 66% !important;
  background-repeat: no-repeat !important;
  background-position: center !important;
  background-size: contain !important;
  display: block !important;
  pointer-events: none !important;
}

.fz-tile .tile-label {
  position: absolute !important;
  left: 5px !important;
  right: 3px !important;
  bottom: 4px !important;
  color: #ffffff !important;
  font-weight: 400 !important;
  font-size: clamp(12px, 3.4vw, 14px) !important;
  line-height: 1.15 !important;
  text-align: left !important;
  white-space: nowrap !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.35) !important;
  pointer-events: none !important;
}

/* 3. Bottom Navigation Footer (Fixed Glassy Black Bar) */
.fz-footer,
.fz-footer.logged-in {
  position: fixed !important;
  left: 0 !important;
  right: 0 !important;
  bottom: 0 !important;
  height: 56px !important;
  background: rgba(10, 10, 10, 0.94) !important;
  backdrop-filter: blur(12px) !important;
  -webkit-backdrop-filter: blur(12px) !important;
  display: grid !important;
  grid-template-columns: repeat(5, 1fr) !important;
  z-index: 60 !important;
  border-top: 1px solid rgba(255, 255, 255, 0.1) !important;
  box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.3) !important;
  max-width: 480px !important;
  margin: 0 auto !important;
  box-sizing: border-box !important;
  padding: 0 !important;
}

.fz-foot {
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: flex-end !important;
  padding: 0 2px 4px !important;
  position: relative !important;
  background: transparent !important;
  border: 0 !important;
  color: #ffffff !important;
  font-size: 10px !important;
  cursor: pointer !important;
  text-decoration: none !important;
  gap: 1px !important;
  will-change: transform;
  transform: translateZ(0);
  transition: transform 0.12s cubic-bezier(0.2, 0.8, 0.2, 1) !important;
}

.fz-foot:active {
  transform: scale(0.955) translateZ(0) !important;
}

.fz-foot.active {
  background: rgba(255, 255, 255, 0.08) !important;
}

.fz-foot-ico {
  width: 32px !important;
  height: 28px !important;
  background-repeat: no-repeat !important;
  background-position: center !important;
  background-size: contain !important;
  display: block !important;
  margin-top: auto !important;
  margin-bottom: 2px !important;
}

.fz-foot span:last-child {
  font-size: 10px !important;
  color: #ffffff !important;
  white-space: nowrap !important;
  line-height: 1 !important;
}

/* 3. Emerald Glow for Balance Badge & Crystal Styling */
.fz-badge {
  position: absolute !important;
  top: -8px !important;
  left: 50% !important;
  transform: translateX(-50%) !important;
  font-size: 9.5px !important;
  font-weight: 700 !important;
  border-radius: 4px !important;
  padding: 1px 5px !important;
  line-height: 13px !important;
  min-width: 18px !important;
  text-align: center !important;
  box-sizing: border-box !important;
  white-space: nowrap !important;
  z-index: 10 !important;
}

.fz-badge.green,
#navAccountBadge {
  background: linear-gradient(135deg, #05c03a 0%, #008f23 100%) !important;
  color: #ffffff !important;
  border: 1px solid rgba(255, 255, 255, 0.3) !important;
  box-shadow: 0 2px 8px rgba(0, 168, 38, 0.5), 0 0 1px rgba(255, 255, 255, 0.6) inset !important;
}

.fz-badge.blue {
  background: linear-gradient(135deg, #0d86d2 0%, #005f9f 100%) !important;
  color: #ffffff !important;
  border: 1px solid rgba(255, 255, 255, 0.3) !important;
  box-shadow: 0 2px 8px rgba(0, 116, 193, 0.5), 0 0 1px rgba(255, 255, 255, 0.6) inset !important;
}

/* 1. Glassmorphic Drawer (.fz-drawer) */
.fz-drawer {
  position: fixed;
  top: 0;
  right: -280px;
  width: 280px;
  height: 100%;
  background: rgba(24, 24, 24, 0.94) !important;
  backdrop-filter: blur(16px) !important;
  -webkit-backdrop-filter: blur(16px) !important;
  border-left: 1px solid rgba(255, 255, 255, 0.08) !important;
  z-index: 100;
  transition: right 0.24s cubic-bezier(0.2, 0.8, 0.2, 1);
  box-shadow: -8px 0 25px rgba(0, 0, 0, 0.5);
  display: flex;
  flex-direction: column;
  overflow-y: auto;
}

.fz-drawer.open {
  right: 0;
}

.fz-drawer .drawer-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  background: rgba(18, 18, 18, 0.95);
  color: #ffffff;
  font-size: 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.fz-drawer .drawer-head button {
  background: transparent;
  border: 0;
  color: #ffffff;
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
}

.fz-drawer a {
  padding: 13px 18px;
  color: #e0e0e0;
  text-decoration: none;
  font-size: 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  display: block;
  transition: background 0.1s ease;
}

.fz-drawer a:active {
  background: rgba(255, 255, 255, 0.12);
}

.shade {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: 90;
  display: none;
}

.shade.show {
  display: block;
}

/* 1. Modal Glassmorphism */
.modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 120;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.modal.show {
  display: flex;
}

.modal > div {
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  color: #183247;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.5);
  padding: 22px 20px;
  width: 100%;
  max-width: 320px;
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.35);
  text-align: center;
}

.modal h3 {
  margin: 0 0 10px;
  font-size: 18px;
  color: #0b6fb8;
}

.modal p {
  margin: 0 0 16px;
  font-size: 14px;
  color: #4a5568;
  line-height: 1.4;
}

.modal button {
  width: 100%;
  height: 42px;
  border: 0;
  border-radius: 8px;
  background: linear-gradient(135deg, #0b7ac7 0%, #00609f 100%);
  color: #ffffff;
  font-size: 14px;
  font-weight: bold;
  cursor: pointer;
  will-change: transform;
  transform: translateZ(0);
  transition: transform 0.12s ease, filter 0.12s ease;
  box-shadow: 0 4px 12px rgba(0, 116, 193, 0.3);
}

.modal button:active {
  transform: scale(0.955) translateZ(0);
  filter: brightness(0.92);
}

/* Account Balance Presentation */
#accBalanceAmount,
.acc-balance-emerald {
  color: #00a826 !important;
  font-weight: bold !important;
  text-shadow: 0 1px 4px rgba(0, 168, 38, 0.25) !important;
}

/* Card Touch & 60fps Transitions */
.oro-card, .sp-card, .lm-event {
  will-change: transform;
  transform: translateZ(0);
  transition: transform 0.12s cubic-bezier(0.2, 0.8, 0.2, 1), box-shadow 0.12s ease;
}

.oro-card:active, .sp-card:active {
  transform: scale(0.955) translateZ(0) !important;
}

