/* ==========================================================================
   PADEL ARENA CLUB - MOBILE-FIRST PWA STYLESHEET (v4.0)
   Look & Feel: Dark Graphite Sport + Padel Neon Yellow/Green (#CCFF00)
   ========================================================================== */

:root {
  --bg-base: #0B0E14;
  --bg-surface: #131824;
  --bg-surface-elevated: #1A2130;
  --bg-surface-glass: rgba(19, 24, 36, 0.88);
  --border-subtle: rgba(255, 255, 255, 0.08);
  --border-neon: rgba(204, 255, 0, 0.35);

  --neon-primary: #CCFF00;
  --neon-hover: #D9FF33;
  --neon-dim: rgba(204, 255, 0, 0.14);
  --green-match: #00E676;
  --green-dim: rgba(0, 230, 118, 0.14);
  --whatsapp-green: #25D366;
  --whatsapp-dim: rgba(37, 211, 102, 0.15);
  --red-redeem: #FF5252;
  --red-dim: rgba(255, 82, 82, 0.14);
  --amber-warning: #F59E0B;

  --text-primary: #F8FAFC;
  --text-secondary: #94A3B8;
  --text-muted: #64748B;
  --text-on-neon: #090D14;

  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --safe-left: env(safe-area-inset-left, 0px);
  --safe-right: env(safe-area-inset-right, 0px);

  --header-height: 68px;
  --bottom-nav-height: 70px;
  --radius-xl: 24px;
  --radius-lg: 18px;
  --radius-md: 14px;
  --radius-sm: 10px;

  --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-display: 'Space Grotesk', 'Plus Jakarta Sans', sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
}

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
  -webkit-touch-callout: none;
}

html,
body {
  width: 100%;
  height: 100%;
  min-height: 100dvh;
  background-color: var(--bg-base);
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 1.45;
  overflow: hidden;
  user-select: none;
  -webkit-user-select: none;
  touch-action: manipulation;
  -webkit-font-smoothing: antialiased;
}

input {
  user-select: text;
  -webkit-user-select: text;
}

button,
input,
select {
  font-family: inherit;
  color: inherit;
  background: none;
  border: none;
  outline: none;
  touch-action: manipulation;
}

button {
  cursor: pointer;
}

button:active,
.preset-chip:active,
.filter-pill:active,
.reward-card:active,
.inline-qr-preview:active,
.clickable-tier:active,
.clickable-block:active {
  transform: scale(0.965);
}

/* ==========================================================================
   LAYOUT MOBILE-FIRST & SIMULATORE SMARTPHONE SU DESKTOP (> 520px)
   ========================================================================== */

.desktop-viewport-bar,
.simulated-status-bar {
  display: none;
}

.app-shell {
  position: relative;
  width: 100%;
  height: 100dvh;
  max-width: 100%;
  display: flex;
  flex-direction: column;
  background: radial-gradient(circle at 50% -10%, rgba(204, 255, 0, 0.12) 0%, rgba(11, 14, 20, 0) 55%), var(--bg-base);
  overflow: hidden;
}

@media (min-width: 521px) {
  body {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: radial-gradient(circle at 50% 20%, #182235 0%, #07090E 100%);
    padding: 52px 16px 16px;
  }

  .desktop-viewport-bar {
    position: fixed;
    top: 10px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 9999;
    display: flex;
    align-items: center;
    gap: 18px;
    padding: 6px 14px;
    background: rgba(19, 24, 36, 0.92);
    backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 999px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
  }

  .viewport-bar-brand {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    font-weight: 700;
    color: var(--text-secondary);
  }

  .pulse-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--neon-primary);
    box-shadow: 0 0 8px var(--neon-primary);
  }

  .viewport-bar-controls {
    display: flex;
    gap: 6px;
  }

  .vp-btn {
    padding: 5px 11px;
    border-radius: 999px;
    font-size: 11.5px;
    font-weight: 600;
    color: var(--text-secondary);
    transition: all 0.2s ease;
  }

  .vp-btn.active {
    background: var(--neon-primary);
    color: var(--text-on-neon);
    font-weight: 700;
  }

  body.device-mode-iphone .app-shell {
    width: 393px;
    height: min(852px, calc(100dvh - 68px));
    border-radius: 48px;
    border: 10px solid #1E2534;
    box-shadow:
      0 0 0 2px #0D1119,
      0 28px 70px rgba(0, 0, 0, 0.75),
      0 0 45px rgba(204, 255, 0, 0.07);
    --safe-top: 40px;
    --safe-bottom: 20px;
  }

  body.device-mode-pixel .app-shell {
    width: 412px;
    height: min(880px, calc(100dvh - 68px));
    border-radius: 38px;
    border: 9px solid #222938;
    box-shadow:
      0 0 0 2px #0D1119,
      0 28px 70px rgba(0, 0, 0, 0.75);
    --safe-top: 36px;
    --safe-bottom: 16px;
  }

  body.device-mode-full {
    padding: 48px 0 0;
  }

  body.device-mode-full .app-shell {
    width: 100%;
    max-width: 480px;
    height: calc(100dvh - 48px);
    border-radius: 0;
    border: none;
  }

  body.device-mode-iphone .simulated-status-bar,
  body.device-mode-pixel .simulated-status-bar {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 40px;
    padding: 0 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    z-index: 120;
    font-size: 12px;
    font-weight: 700;
    color: var(--text-primary);
    pointer-events: none;
  }

  .dynamic-island {
    width: 108px;
    height: 26px;
    background: #040609;
    border-radius: 999px;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding-right: 10px;
    border: 1px solid rgba(255, 255, 255, 0.05);
  }

  body.device-mode-pixel .dynamic-island {
    width: 16px;
    height: 16px;
    padding: 0;
    justify-content: center;
  }

  .island-camera {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: radial-gradient(circle, #1E3A8A 25%, #090D16 70%);
  }

  .status-icons {
    display: flex;
    align-items: center;
    gap: 5px;
  }
}

/* ==========================================================================
   SCHERMATA DI ACCESSO GIOCATORE (TELEFONO + CODICE WHATSAPP)
   ========================================================================== */

.auth-screen {
  position: absolute;
  inset: 0;
  z-index: 85;
  background:
    radial-gradient(circle at 50% 0%, rgba(204, 255, 0, 0.16) 0%, rgba(11, 14, 20, 0) 60%),
    var(--bg-base);
  padding: calc(max(var(--safe-top), 20px) + 12px) 20px calc(max(var(--safe-bottom), 20px) + 12px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  overflow-y: auto;
}

.auth-screen[hidden] {
  display: none !important;
}

.auth-card-wrapper {
  background: var(--bg-surface);
  border: 1px solid rgba(204, 255, 0, 0.25);
  border-radius: var(--radius-xl);
  padding: 24px 20px;
  box-shadow: 0 24px 50px rgba(0, 0, 0, 0.7);
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.auth-brand-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 8px;
}

.auth-logo-mark {
  width: 58px;
  height: 58px;
  border-radius: 18px;
  background: linear-gradient(135deg, var(--neon-primary) 0%, #9EF000 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 10px 26px rgba(204, 255, 0, 0.38);
  margin-bottom: 4px;
}

.auth-club-badge {
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 0.1em;
  color: var(--neon-primary);
}

.auth-title {
  font-family: var(--font-display);
  font-size: 23px;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.auth-subtitle {
  font-size: 13px;
  color: var(--text-secondary);
  max-width: 310px;
}

.auth-subtitle strong {
  color: var(--whatsapp-green);
}

.auth-step-form {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.auth-step-form[hidden] {
  display: none !important;
}

.input-field-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.input-field-group label {
  font-size: 12px;
  font-weight: 700;
  color: var(--text-secondary);
}

.optional-tag {
  font-weight: 500;
  color: var(--text-muted);
}

.phone-input-row {
  display: flex;
  align-items: center;
  background: var(--bg-base);
  border: 1.5px solid rgba(255, 255, 255, 0.14);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.phone-input-row:focus-within {
  border-color: var(--neon-primary);
  box-shadow: 0 0 0 3px rgba(204, 255, 0, 0.15);
}

.country-prefix {
  padding: 13px 12px;
  background: rgba(255, 255, 255, 0.04);
  border-right: 1px solid var(--border-subtle);
  font-family: var(--font-mono);
  font-size: 14px;
  font-weight: 700;
}

.phone-input-row input {
  flex: 1;
  padding: 13px 14px;
  font-family: var(--font-mono);
  font-size: 16px;
  font-weight: 700;
  color: var(--text-primary);
}

.text-input-standard {
  width: 100%;
  padding: 12px 14px;
  background: var(--bg-base);
  border: 1.5px solid rgba(255, 255, 255, 0.14);
  border-radius: var(--radius-md);
  font-size: 14.5px;
  font-weight: 600;
  color: var(--text-primary);
}

.auth-quick-presets {
  display: flex;
  flex-direction: column;
  gap: 6px;
  background: rgba(255, 255, 255, 0.03);
  padding: 10px 12px;
  border-radius: var(--radius-md);
  border: 1px dashed rgba(255, 255, 255, 0.12);
}

.presets-caption {
  font-size: 11px;
  font-weight: 700;
  color: var(--text-secondary);
}

.preset-chips-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.preset-chip {
  padding: 6px 10px;
  border-radius: 999px;
  background: var(--bg-surface-elevated);
  border: 1px solid rgba(204, 255, 0, 0.28);
  font-size: 11px;
  font-weight: 700;
  color: var(--neon-primary);
}

.auth-error-box {
  background: var(--red-dim);
  border: 1px solid rgba(255, 82, 82, 0.4);
  color: #FF8A8A;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  font-size: 12.5px;
  font-weight: 600;
}

.auth-submit-btn {
  position: relative;
  min-height: 48px;
}

.btn-spinner {
  width: 18px;
  height: 18px;
  border: 2.5px solid rgba(9, 13, 20, 0.25);
  border-top-color: #090D14;
  border-radius: 50%;
  animation: spinAnim 0.7s linear infinite;
}

@keyframes spinAnim {
  to { transform: rotate(360deg); }
}

.otp-sent-info {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
}

.whatsapp-pill {
  font-size: 12px;
  color: var(--whatsapp-green);
  background: var(--whatsapp-dim);
  padding: 5px 11px;
  border-radius: 999px;
  border: 1px solid rgba(37, 211, 102, 0.3);
}

.link-change-phone {
  font-size: 12px;
  font-weight: 700;
  color: var(--neon-primary);
  text-decoration: underline;
}

.whatsapp-preview-card {
  background: rgba(37, 211, 102, 0.1);
  border: 1px solid rgba(37, 211, 102, 0.4);
  border-radius: var(--radius-md);
  padding: 11px 13px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.wa-preview-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.wa-badge {
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.06em;
  color: var(--whatsapp-green);
}

.wa-autofill-btn {
  font-size: 11px;
  font-weight: 800;
  padding: 3px 9px;
  border-radius: 999px;
  background: var(--whatsapp-green);
  color: #06130B;
}

.wa-message-bubble {
  font-size: 12.5px;
  color: var(--text-primary);
  line-height: 1.35;
}

.wa-message-bubble strong {
  font-family: var(--font-mono);
  font-size: 14px;
  color: var(--neon-primary);
  background: rgba(0, 0, 0, 0.35);
  padding: 1px 6px;
  border-radius: 4px;
}

.otp-boxes-row {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 8px;
}

.otp-digit-input {
  width: 100%;
  height: 52px;
  text-align: center;
  font-family: var(--font-mono);
  font-size: 21px;
  font-weight: 800;
  background: var(--bg-base);
  border: 1.5px solid rgba(255, 255, 255, 0.16);
  border-radius: 12px;
  color: var(--neon-primary);
}

.otp-digit-input:focus {
  border-color: var(--neon-primary);
  box-shadow: 0 0 0 3px rgba(204, 255, 0, 0.18);
  transform: translateY(-2px);
}

.otp-resend-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
  color: var(--text-secondary);
}

.btn-resend-otp {
  font-weight: 700;
  color: var(--neon-primary);
}

.btn-resend-otp:disabled {
  color: var(--text-muted);
  cursor: not-allowed;
}

/* ==========================================================================
   TOP HEADER CON SAFE AREA INSET TOP & BADGE LIVELLO CLICCABILE
   ========================================================================== */

.app-header {
  flex-shrink: 0;
  padding-top: calc(max(var(--safe-top), 12px) + 6px);
  padding-bottom: 12px;
  padding-left: calc(max(var(--safe-left), 18px));
  padding-right: calc(max(var(--safe-right), 18px));
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(11, 14, 20, 0.85);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid var(--border-subtle);
  z-index: 30;
}

.user-profile-row {
  display: flex;
  align-items: center;
  gap: 11px;
  min-width: 0;
}

.avatar-wrapper {
  position: relative;
  width: 44px;
  height: 44px;
  flex-shrink: 0;
}

.avatar-ring {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  padding: 2px;
  background: linear-gradient(135deg, var(--neon-primary) 0%, #00E676 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.avatar-ring svg {
  border-radius: 50%;
}

.online-badge {
  position: absolute;
  bottom: 1px;
  right: 1px;
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: var(--green-match);
  border: 2px solid var(--bg-base);
}

.user-greeting {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.greeting-top {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.tier-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 9px;
  border-radius: 999px;
  font-size: 10.5px;
  font-weight: 800;
  background: rgba(255, 255, 255, 0.08);
  color: var(--text-primary);
  border: 1px solid rgba(204, 255, 0, 0.35);
  transition: all 0.15s ease;
}

.tier-pill.clickable-tier:hover {
  background: rgba(204, 255, 0, 0.16);
}

.tier-dot-color {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #c0c0c0;
  box-shadow: 0 0 6px currentColor;
}

.user-phone-pill {
  font-family: var(--font-mono);
  font-size: 10.5px;
  color: var(--text-secondary);
}

.user-name-row {
  display: flex;
  align-items: center;
  gap: 6px;
}

.user-name {
  font-family: var(--font-display);
  font-size: 17.5px;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.edit-name-btn {
  color: var(--text-secondary);
  padding: 3px;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.icon-btn {
  width: 38px;
  height: 38px;
  border-radius: 12px;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: center;
}

.icon-btn.logout-btn {
  color: #FF8A8A;
  border-color: rgba(255, 82, 82, 0.22);
}

/* ==========================================================================
   MAIN SCROLL AREA & TESSERA DIGITALE CON QR CODE INTEGRATO
   ========================================================================== */

.app-main {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  overscroll-behavior-y: contain;
  -webkit-overflow-scrolling: touch;
  padding: 16px 18px calc(var(--bottom-nav-height) + max(var(--safe-bottom), 16px) + 22px);
  scrollbar-width: none;
}

.app-main::-webkit-scrollbar {
  display: none;
}

.tab-view {
  display: flex;
  flex-direction: column;
  gap: 18px;
  animation: viewFadeIn 0.24s cubic-bezier(0.22, 1, 0.36, 1);
}

.tab-view[hidden] {
  display: none !important;
}

@keyframes viewFadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

.loyalty-card {
  position: relative;
  border-radius: var(--radius-xl);
  padding: 20px 18px 18px;
  background: linear-gradient(145deg, rgba(28, 37, 54, 0.96) 0%, rgba(15, 20, 30, 0.98) 100%);
  border: 1px solid rgba(204, 255, 0, 0.35);
  box-shadow:
    0 18px 40px -12px rgba(0, 0, 0, 0.65),
    0 0 28px -6px rgba(204, 255, 0, 0.16),
    inset 0 1px 0 rgba(255, 255, 255, 0.12);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.loyalty-card-glow {
  position: absolute;
  top: -50px;
  right: -40px;
  width: 180px;
  height: 180px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(204, 255, 0, 0.28) 0%, rgba(204, 255, 0, 0) 70%);
  pointer-events: none;
}

.loyalty-card-mesh {
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(255, 255, 255, 0.06) 1px, transparent 1px);
  background-size: 16px 16px;
  opacity: 0.45;
  pointer-events: none;
}

.loyalty-card-top {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.club-brand {
  display: flex;
  align-items: center;
  gap: 8px;
}

.club-logo-badge {
  width: 26px;
  height: 26px;
  border-radius: 8px;
  background: var(--neon-primary);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.club-title {
  font-family: var(--font-display);
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.09em;
}

.card-member-id {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 700;
  color: var(--neon-primary);
  background: rgba(204, 255, 0, 0.1);
  padding: 3px 9px;
  border-radius: 6px;
  border: 1px solid rgba(204, 255, 0, 0.22);
}

.loyalty-card-split {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.loyalty-balance-block {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.balance-label {
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--text-secondary);
}

.balance-value-row {
  display: flex;
  align-items: baseline;
  gap: 6px;
}

.balance-number {
  font-family: var(--font-display);
  font-size: 44px;
  font-weight: 800;
  line-height: 1;
  color: var(--neon-primary);
  text-shadow: 0 0 24px rgba(204, 255, 0, 0.35);
  transition: transform 0.25s ease;
}

.balance-number.pop {
  transform: scale(1.12);
}

.balance-unit {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 700;
}

.card-holder-caption {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-primary);
}

.inline-qr-preview {
  background: #FFFFFF;
  padding: 6px 6px 4px;
  border-radius: 12px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  cursor: pointer;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.45);
  flex-shrink: 0;
}

.inline-qr-svg svg {
  width: 68px;
  height: 68px;
  display: block;
}

.inline-qr-caption {
  font-size: 9px;
  font-weight: 800;
  color: #0B0E14;
}

.tier-progress-container {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 8px 10px;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.06);
  cursor: pointer;
}

.tier-progress-container.is-max-tier {
  background: linear-gradient(90deg, rgba(255, 215, 0, 0.14) 0%, rgba(255, 215, 0, 0.05) 100%);
  border-color: rgba(255, 215, 0, 0.38);
  padding: 9px 12px;
}

.tier-current-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 700;
  color: var(--text-primary);
  text-decoration: none !important;
  cursor: pointer;
}

.tier-progress-labels {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 11.5px;
  color: var(--text-secondary);
}

.tier-progress-labels strong {
  color: var(--neon-primary);
}

.tier-max-gold-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 11px;
  font-weight: 800;
  color: #FFD700;
  background: rgba(255, 215, 0, 0.14);
  border: 1px solid rgba(255, 215, 0, 0.35);
  padding: 2px 9px;
  border-radius: 999px;
}

.tier-progress-track {
  width: 100%;
  height: 8px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  overflow: hidden;
}

.tier-progress-track[hidden] {
  display: none !important;
}

.tier-progress-fill {
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, #00E676 0%, var(--neon-primary) 100%);
  transition: width 0.45s ease;
}

.loyalty-card-actions {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1.55fr 1fr;
  gap: 10px;
}

.btn-neon-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 14px;
  border-radius: var(--radius-md);
  background: var(--neon-primary);
  color: var(--text-on-neon);
  font-weight: 800;
  font-size: 13.5px;
  box-shadow: 0 8px 20px -4px rgba(204, 255, 0, 0.45);
}

.btn-neon-primary.full-width {
  width: 100%;
}

.btn-card-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 13px 12px;
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: var(--text-primary);
  font-weight: 700;
  font-size: 13px;
}

/* ==========================================================================
   SEZIONE PREMI A DOPPIA SCHEDA (CATALOGO PREMI / PREMI RISCATTATI)
   ========================================================================== */

.rewards-segment-control {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  padding: 5px;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
}

.segment-tab-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 10px 12px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 800;
  color: var(--text-secondary);
  transition: all 0.2s ease;
}

.segment-tab-btn.active {
  background: var(--neon-primary);
  color: var(--text-on-neon);
  box-shadow: 0 4px 14px rgba(204, 255, 0, 0.28);
}

.segment-count-badge {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 800;
  padding: 1px 6px;
  border-radius: 999px;
  background: rgba(11, 14, 20, 0.2);
  color: inherit;
}

.segment-tab-btn:not(.active) .segment-count-badge {
  background: var(--neon-dim);
  color: var(--neon-primary);
}

.rewards-subview[hidden] {
  display: none !important;
}

/* Card "Premi Riscattati" (Coupon con Codice Univoco e Copia Rapida) */
.redeemed-coupons-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.redeemed-coupon-card {
  background: var(--bg-surface);
  border: 1px solid rgba(204, 255, 0, 0.28);
  border-radius: var(--radius-lg);
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  position: relative;
  overflow: hidden;
}

.redeemed-coupon-card.is-used {
  border-color: var(--border-subtle);
  opacity: 0.85;
}

.coupon-top-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.coupon-reward-info {
  display: flex;
  align-items: center;
  gap: 11px;
}

.coupon-reward-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  flex-shrink: 0;
}

.coupon-reward-title {
  font-size: 15px;
  font-weight: 800;
  color: var(--text-primary);
}

.coupon-reward-date {
  font-size: 11.5px;
  color: var(--text-secondary);
}

.coupon-status-badge {
  font-size: 11px;
  font-weight: 800;
  padding: 4px 10px;
  border-radius: 999px;
  white-space: nowrap;
}

.coupon-status-badge.ready {
  background: var(--green-dim);
  color: var(--green-match);
  border: 1px solid rgba(0, 230, 118, 0.35);
}

.coupon-status-badge.used {
  background: rgba(255, 255, 255, 0.07);
  color: var(--text-secondary);
  border: 1px solid var(--border-subtle);
}

.coupon-code-box {
  background: var(--bg-base);
  border: 1.5px dashed rgba(204, 255, 0, 0.45);
  border-radius: var(--radius-md);
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.coupon-code-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.coupon-code-label {
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: var(--text-secondary);
  text-transform: uppercase;
}

.coupon-code-value {
  font-family: var(--font-mono);
  font-size: 18px;
  font-weight: 800;
  color: var(--neon-primary);
  letter-spacing: 0.05em;
}

.btn-copy-code {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 13px;
  border-radius: 10px;
  background: var(--neon-primary);
  color: var(--text-on-neon);
  font-size: 12px;
  font-weight: 800;
  flex-shrink: 0;
}

.btn-copy-code.copied {
  background: var(--green-match);
  color: #06150D;
}

.coupon-desk-instruction {
  font-size: 11.5px;
  color: var(--text-secondary);
  font-weight: 600;
}

/* ==========================================================================
   MODALE / BOTTOM SHEET LIVELLI & BENEFIT DEL CENTRO
   ========================================================================== */

.bottom-sheet-modal.tiers-sheet {
  width: 100%;
  max-height: 88dvh;
  background: var(--bg-surface-elevated);
  border-top: 1px solid rgba(204, 255, 0, 0.4);
  border-radius: 28px 28px 0 0;
  padding: 12px 18px calc(max(var(--safe-bottom), 18px) + 12px);
  display: flex;
  flex-direction: column;
  gap: 12px;
  box-shadow: 0 -20px 50px rgba(0, 0, 0, 0.8);
  animation: slideUpSheet 0.26s cubic-bezier(0.22, 1, 0.36, 1);
}

@keyframes slideUpSheet {
  from { transform: translateY(100%); }
  to { transform: translateY(0); }
}

.tiers-sheet-intro {
  font-size: 12.5px;
  color: var(--text-secondary);
}

/* Nascondi scrollbar per Chrome, Safari e Opera */
.modal-content::-webkit-scrollbar,
.tiers-benefits-scroll::-webkit-scrollbar,
.bottom-sheet-modal::-webkit-scrollbar {
  display: none;
  width: 0;
  height: 0;
}

/* Nascondi scrollbar per Firefox e IE/Edge mantenendo scorrimento touch fluido */
.modal-content,
.tiers-benefits-scroll,
.bottom-sheet-modal {
  -ms-overflow-style: none;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}

.tiers-benefits-scroll {
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  -ms-overflow-style: none;
  scrollbar-width: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding-right: 0;
  max-height: 54dvh;
}

.tier-benefit-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 13px 14px;
  display: flex;
  flex-direction: column;
  gap: 9px;
}

.tier-benefit-card.is-current-tier {
  border: 1.5px solid var(--neon-primary);
  background: linear-gradient(145deg, rgba(204, 255, 0, 0.1) 0%, rgba(19, 24, 36, 0.95) 100%);
  box-shadow: 0 0 22px rgba(204, 255, 0, 0.16);
}

.tier-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.tier-card-title-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
}

.tier-card-name {
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 800;
}

.tier-current-tag {
  font-size: 10px;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--neon-primary);
  color: var(--text-on-neon);
}

.tier-unlocked-tag {
  font-size: 10.5px;
  font-weight: 700;
  color: var(--green-match);
}

.tier-threshold-pill {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-primary);
}

.tier-benefits-ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.tier-benefits-ul li {
  display: flex;
  align-items: flex-start;
  gap: 7px;
  font-size: 12px;
  color: var(--text-secondary);
}

.tier-benefit-card.is-current-tier .tier-benefits-ul li {
  color: var(--text-primary);
}

.benefit-check {
  color: var(--neon-primary);
  font-weight: 800;
  flex-shrink: 0;
}

/* Avviso di Fine Stagione (31 Dicembre) */
.season-reset-warning {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 11px 13px;
  border-radius: var(--radius-md);
  background: rgba(245, 158, 11, 0.12);
  border: 1px solid rgba(245, 158, 11, 0.4);
  color: #FDE68A;
  font-size: 11.5px;
  font-weight: 600;
  line-height: 1.38;
}

.season-warning-icon {
  font-size: 16px;
  flex-shrink: 0;
}

/* ==========================================================================
   STORICO MOVIMENTI PUNTI (+ VERDE ENTRATE / - ROSSO USCITE) & ALTRI STILI
   ========================================================================== */

.view-top-title h2 {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 700;
}

.view-top-title p {
  font-size: 13px;
  color: var(--text-secondary);
  margin-top: 2px;
}

.history-summary-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.summary-stat-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 13px 14px;
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.stat-label {
  font-size: 11.5px;
  color: var(--text-secondary);
  font-weight: 600;
}

.stat-value {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 800;
}

.summary-stat-card.positive .stat-value {
  color: var(--green-match);
}

.summary-stat-card.negative .stat-value {
  color: var(--red-redeem);
}

.stat-meta {
  font-size: 11px;
  color: var(--text-muted);
}

.filter-pills-bar {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  scrollbar-width: none;
}

.filter-pills-bar::-webkit-scrollbar {
  display: none;
}

.filter-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 14px;
  border-radius: 999px;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  font-size: 12.5px;
  font-weight: 700;
  color: var(--text-secondary);
  white-space: nowrap;
}

.filter-pill.active {
  background: var(--neon-primary);
  color: var(--text-on-neon);
  border-color: var(--neon-primary);
}

.pill-dot {
  font-family: var(--font-mono);
  font-weight: 800;
}

.transactions-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.tx-item {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 13px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.tx-left {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.tx-icon {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  flex-shrink: 0;
}

.tx-icon.earned {
  background: var(--green-dim);
  color: var(--green-match);
  border: 1px solid rgba(0, 230, 118, 0.28);
}

.tx-icon.spent {
  background: var(--red-dim);
  color: var(--red-redeem);
  border: 1px solid rgba(255, 82, 82, 0.28);
}

.tx-details {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.tx-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.tx-subtitle {
  font-size: 11.5px;
  color: var(--text-secondary);
}

.tx-points {
  font-family: var(--font-mono);
  font-size: 13.5px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 999px;
  flex-shrink: 0;
}

.tx-points.earned {
  color: var(--green-match);
  background: var(--green-dim);
  border: 1px solid rgba(0, 230, 118, 0.25);
}

.tx-points.spent {
  color: var(--red-redeem);
  background: var(--red-dim);
  border: 1px solid rgba(255, 82, 82, 0.25);
}

.section-block {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.section-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.section-title {
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 700;
}

.section-sub-caption {
  font-size: 12px;
  color: var(--text-secondary);
}

.text-link-btn {
  font-size: 12.5px;
  font-weight: 700;
  color: var(--neon-primary);
}

.rewards-count-pill {
  font-family: var(--font-mono);
  font-size: 11.5px;
  font-weight: 700;
  color: var(--neon-primary);
  background: var(--neon-dim);
  padding: 4px 10px;
  border-radius: 999px;
  border: 1px solid rgba(204, 255, 0, 0.3);
}

.rewards-top-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.rewards-wallet-pill {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-neon);
  padding: 8px 13px;
  border-radius: var(--radius-md);
  display: flex;
  flex-direction: column;
  align-items: flex-end;
}

.rewards-wallet-pill span {
  font-size: 10px;
  text-transform: uppercase;
  color: var(--text-secondary);
}

.rewards-wallet-pill strong {
  font-family: var(--font-mono);
  font-size: 16px;
  color: var(--neon-primary);
}

.rewards-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

.reward-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 14px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 12px;
}

.reward-card.unlocked {
  border-color: rgba(204, 255, 0, 0.4);
}

.reward-visual {
  height: 72px;
  border-radius: var(--radius-md);
  background: linear-gradient(135deg, #192234 0%, #101521 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 34px;
  position: relative;
}

.reward-cost-tag {
  position: absolute;
  top: 6px;
  right: 6px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 999px;
  background: rgba(11, 14, 20, 0.88);
  color: var(--neon-primary);
  border: 1px solid rgba(204, 255, 0, 0.35);
}

.reward-info h3 {
  font-size: 13.5px;
  font-weight: 700;
  line-height: 1.25;
}

.reward-info p {
  font-size: 11.5px;
  color: var(--text-secondary);
  margin-top: 2px;
}

.reward-progress-wrap {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.reward-progress-bar {
  width: 100%;
  height: 6px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  overflow: hidden;
}

.reward-progress-fill {
  height: 100%;
  border-radius: 999px;
  background: var(--neon-primary);
  transition: width 0.35s ease;
}

.reward-progress-text {
  font-size: 11px;
  color: var(--text-secondary);
  display: flex;
  justify-content: space-between;
}

.btn-redeem-reward {
  width: 100%;
  padding: 10px 12px;
  border-radius: 999px;
  font-size: 12.5px;
  font-weight: 800;
  text-align: center;
}

.btn-redeem-reward.can-redeem {
  background: var(--neon-primary);
  color: var(--text-on-neon);
  box-shadow: 0 4px 15px rgba(204, 255, 0, 0.3);
}

.btn-redeem-reward.locked {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-muted);
  cursor: not-allowed;
}

.tiers-showcase-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 4px;
  cursor: pointer;
}

.tier-showcase-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 9px 12px;
  border-radius: var(--radius-sm);
  background: var(--bg-base);
  border: 1px solid var(--border-subtle);
}

.tier-showcase-row.current {
  border-color: var(--neon-primary);
  background: rgba(204, 255, 0, 0.08);
}

.tier-showcase-left {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 13px;
  font-weight: 700;
}

.tier-color-swatch {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  display: inline-block;
}

.tier-showcase-pts {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text-secondary);
}

.push-demo-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 15px 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.push-demo-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.push-demo-title-group {
  display: flex;
  align-items: center;
  gap: 11px;
}

.push-icon-box {
  width: 38px;
  height: 38px;
  border-radius: 11px;
  background: var(--neon-dim);
  border: 1px solid rgba(204, 255, 0, 0.25);
  display: flex;
  align-items: center;
  justify-content: center;
}

.section-subtitle {
  font-size: 14px;
  font-weight: 700;
}

.push-status-sub {
  font-size: 12px;
  color: var(--text-secondary);
}

.native-switch {
  position: relative;
  display: inline-block;
  width: 50px;
  height: 28px;
  flex-shrink: 0;
}

.native-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.switch-slider {
  position: absolute;
  cursor: pointer;
  inset: 0;
  background-color: #2A3449;
  border-radius: 34px;
  transition: 0.25s ease;
}

.switch-slider::before {
  position: absolute;
  content: "";
  height: 22px;
  width: 22px;
  left: 3px;
  bottom: 3px;
  background-color: #FFFFFF;
  border-radius: 50%;
  transition: 0.25s ease;
}

.native-switch input:checked + .switch-slider {
  background-color: var(--neon-primary);
}

.native-switch input:checked + .switch-slider::before {
  transform: translateX(22px);
  background-color: #0B0E14;
}

.btn-simulate-match {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 13px 14px;
  border-radius: var(--radius-md);
  background: linear-gradient(90deg, rgba(204, 255, 0, 0.14) 0%, rgba(0, 230, 118, 0.1) 100%);
  border: 1px dashed rgba(204, 255, 0, 0.48);
  text-align: left;
}

.sim-btn-left {
  display: flex;
  align-items: center;
  gap: 11px;
}

.sim-icon-pulse {
  font-size: 20px;
}

.sim-btn-copy {
  display: flex;
  flex-direction: column;
}

.sim-btn-copy strong {
  font-size: 13px;
  font-weight: 800;
  color: var(--neon-primary);
}

.sim-btn-copy span {
  font-size: 11.5px;
  color: var(--text-secondary);
}

.sim-badge-plus {
  font-family: var(--font-mono);
  font-size: 12.5px;
  font-weight: 700;
  padding: 5px 10px;
  border-radius: 999px;
  background: var(--neon-primary);
  color: var(--text-on-neon);
}

.settings-card,
.demo-actions-panel {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.settings-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.settings-info strong {
  font-size: 14px;
  display: block;
}

.settings-info p {
  font-size: 12px;
  color: var(--text-secondary);
}

.settings-divider {
  height: 1px;
  background: var(--border-subtle);
}

.status-chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 11.5px;
  font-weight: 700;
  padding: 5px 11px;
  border-radius: 999px;
  background: var(--green-dim);
  color: var(--green-match);
  border: 1px solid rgba(204, 255, 0, 0.3);
}

.btn-secondary-action {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 13px 14px;
  border-radius: var(--radius-md);
  background: var(--bg-surface-elevated);
  border: 1px solid rgba(255, 82, 82, 0.35);
  color: #FF8A8A;
  font-size: 13px;
  font-weight: 700;
}

/* ==========================================================================
   BOTTOM NAVIGATION BAR NATIVA FISSA (5 VOCI)
   ========================================================================== */

.bottom-nav {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  min-height: calc(var(--bottom-nav-height) + max(var(--safe-bottom), 8px));
  padding-top: 8px;
  padding-bottom: max(var(--safe-bottom), 10px);
  padding-left: 8px;
  padding-right: 8px;
  background: rgba(13, 17, 26, 0.92);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  align-items: center;
  z-index: 40;
}

.nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  color: var(--text-muted);
  padding: 4px 0;
}

.nav-icon-wrap {
  position: relative;
  width: 42px;
  height: 28px;
  border-radius: 999px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.nav-item.active {
  color: var(--neon-primary);
}

.nav-item.active .nav-icon-wrap {
  background: rgba(204, 255, 0, 0.15);
}

.nav-label {
  font-size: 10.5px;
  font-weight: 700;
}

.nav-badge {
  position: absolute;
  top: -3px;
  right: 2px;
  min-width: 16px;
  height: 16px;
  padding: 0 4px;
  border-radius: 999px;
  background: var(--neon-primary);
  color: var(--text-on-neon);
  font-size: 10px;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.nav-qr-fab {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  margin-top: -20px;
}

.fab-inner {
  width: 48px;
  height: 48px;
  border-radius: 16px;
  background: linear-gradient(135deg, var(--neon-primary) 0%, #9EF000 100%);
  box-shadow: 0 8px 22px rgba(204, 255, 0, 0.45);
  display: flex;
  align-items: center;
  justify-content: center;
  border: 3px solid var(--bg-base);
}

.fab-label {
  color: var(--text-primary);
}

/* ==========================================================================
   MODALE NATIVO QR CODE & BANNER PUSH / TOAST
   ========================================================================== */

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(5, 7, 11, 0.82);
  backdrop-filter: blur(10px);
  z-index: 90;
  display: flex;
  align-items: flex-end;
  justify-content: center;
}

.modal-backdrop[hidden] {
  display: none !important;
}

.qr-sheet {
  width: 100%;
  background: var(--bg-surface-elevated);
  border-top: 1px solid rgba(204, 255, 0, 0.35);
  border-radius: 28px 28px 0 0;
  padding: 12px 20px calc(max(var(--safe-bottom), 18px) + 12px);
  display: flex;
  flex-direction: column;
  gap: 15px;
  animation: slideUpSheet 0.26s cubic-bezier(0.22, 1, 0.36, 1);
}

.sheet-handle {
  width: 42px;
  height: 5px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.2);
  align-self: center;
}

.qr-sheet-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.qr-pass-tag {
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.09em;
  color: var(--neon-primary);
}

.qr-sheet-header h3 {
  font-family: var(--font-display);
  font-size: 18.5px;
  font-weight: 700;
}

.modal-close-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
}

.qr-code-frame {
  background: #FFFFFF;
  color: #0B0E14;
  border-radius: 20px;
  padding: 18px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

.qr-svg-container {
  width: 196px;
  height: 196px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.qr-brightness-hint {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  font-weight: 700;
  color: #334155;
}

.qr-member-details {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  background: var(--bg-surface);
  padding: 12px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-subtle);
}

.qr-detail-item {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.detail-label {
  font-size: 9.5px;
  font-weight: 700;
  color: var(--text-muted);
}

.detail-val {
  font-size: 12px;
  font-weight: 700;
  overflow: hidden;
  text-overflow: ellipsis;
}

.detail-val.mono {
  font-family: var(--font-mono);
}

.detail-val.neon {
  color: var(--neon-primary);
}

.in-app-push-banner {
  position: absolute;
  top: calc(max(var(--safe-top), 10px) + 6px);
  left: 12px;
  right: 12px;
  z-index: 110;
  background: rgba(20, 26, 38, 0.96);
  backdrop-filter: blur(20px);
  border: 1px solid var(--neon-primary);
  border-radius: 18px;
  padding: 12px 14px;
  display: flex;
  align-items: center;
  gap: 12px;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.75);
}

.in-app-push-banner[hidden] {
  display: none !important;
}

.push-banner-icon {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: rgba(204, 255, 0, 0.14);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.push-banner-content {
  flex: 1;
  min-width: 0;
}

.push-banner-meta {
  display: flex;
  justify-content: space-between;
  font-size: 10px;
  font-weight: 800;
  color: var(--neon-primary);
  margin-bottom: 2px;
}

.push-banner-content strong {
  display: block;
  font-size: 13px;
}

.push-banner-content p {
  font-size: 11.5px;
  color: var(--text-secondary);
}

.push-banner-close {
  color: var(--text-muted);
  padding: 4px;
}

.app-toast {
  position: absolute;
  bottom: calc(var(--bottom-nav-height) + max(var(--safe-bottom), 12px) + 12px);
  left: 50%;
  transform: translateX(-50%);
  z-index: 105;
  background: rgba(19, 25, 38, 0.96);
  border: 1px solid rgba(204, 255, 0, 0.4);
  border-radius: 999px;
  padding: 10px 18px;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12.5px;
  font-weight: 700;
  white-space: nowrap;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.6);
}

.app-toast[hidden] {
  display: none !important;
}

/* Empty States eleganti per liste vuote in produzione */
.empty-state-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 28px 20px;
  border-radius: var(--radius-lg);
  background: rgba(19, 25, 38, 0.72);
  border: 1px dashed rgba(148, 163, 184, 0.22);
  gap: 10px;
}

.empty-state-icon {
  font-size: 26px;
  line-height: 1;
  opacity: 0.9;
}

.empty-state-text {
  font-size: 13px;
  line-height: 1.5;
  color: var(--text-secondary);
  max-width: 300px;
}

