/* Cashback Pro V36.8.4 — theme-aware CTA sizing and reliable touch release. */
:root { --v3684-action: var(--pumpkin, var(--accent, #ff8a30)); }

/* The account tile must remain a real, reachable control in the default theme. */
.app-header .user-pill #user-name-display,
.app-header #header-actions-menu #header-auth-menu-login {
  pointer-events: auto !important;
  touch-action: manipulation;
  cursor: pointer;
}
.app-header #header-actions-menu { z-index: 30002; }
.app-header #header-actions-menu #header-auth-menu-login { position: relative; z-index: 30003; }

/* Theme-aware action color: each seasonal theme already changes --pumpkin. */
.btn-convert,
.balance-withdraw-action .btn-copy,
.customer-withdrawals-refresh {
  transition: background .18s ease, color .18s ease, border-color .18s ease,
              box-shadow .18s ease, transform .14s ease, filter .18s ease !important;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
}
.btn-convert {
  background: linear-gradient(135deg,
    color-mix(in srgb, var(--v3684-action) 82%, white),
    var(--v3684-action)) !important;
  color: #fff !important;
  border: 1px solid color-mix(in srgb, var(--v3684-action) 72%, white) !important;
  justify-content: center;
  text-align: center;
}
@supports not (background: color-mix(in srgb, red, white)) {
  .btn-convert { background: var(--v3684-action) !important; }
}
@media (hover: hover) and (pointer: fine) {
  .btn-convert:hover,
  .balance-withdraw-action .btn-copy:hover,
  .customer-withdrawals-refresh:hover {
    filter: brightness(1.07) saturate(1.08);
    box-shadow: 0 7px 20px color-mix(in srgb, var(--v3684-action) 25%, transparent);
  }
}
.btn-convert:active,
.balance-withdraw-action .btn-copy:active,
.customer-withdrawals-refresh:active {
  transform: translateY(1px) scale(.975) !important;
  filter: brightness(.94) !important;
  box-shadow: inset 0 2px 5px rgba(0,0,0,.18) !important;
}
.btn-convert:focus-visible,
.balance-withdraw-action .btn-copy:focus-visible,
.customer-withdrawals-refresh:focus-visible {
  outline: 2px solid color-mix(in srgb, var(--v3684-action) 72%, white);
  outline-offset: 3px;
}

/* Withdrawal entry button: preserve its full-width layout, add a clear press state. */
.balance-withdraw-action .btn-copy {
  min-height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  border-color: color-mix(in srgb, var(--v3684-action) 40%, var(--border-light));
}

/* Refresh button should not remain in the hover state after a touch release. */
.customer-withdrawals-refresh {
  transform: none !important;
  filter: none;
  box-shadow: none;
  -webkit-user-select: none;
  user-select: none;
}
.customer-withdrawals-refresh.is-pressed { transform: translateY(1px) scale(.975) !important; }
@media (hover: none), (pointer: coarse) {
  .btn-copy:hover,
  .customer-withdrawals-refresh:hover,
  .btn-convert:hover {
    background: var(--bg-card) !important;
    border-color: var(--border-light) !important;
    color: var(--text-main) !important;
    filter: none !important;
    box-shadow: none !important;
    transform: none !important;
  }
  .customer-withdrawals-refresh:active,
  .btn-copy:active {
    background: color-mix(in srgb, var(--v3684-action) 18%, var(--bg-card)) !important;
    border-color: var(--v3684-action) !important;
    transform: scale(.975) !important;
  }
}

/* Converter action: comfortably wide, centered text and icon. */
#btn-convert-action {
  flex: 0 0 auto;
  min-width: 190px;
  min-height: 50px;
  padding: 10px 20px !important;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  white-space: normal;
  line-height: 1.25;
}

/* Manual order claim: button stays at the right, shorter horizontally and taller. */
#tab-orders #claim-order-id-input { min-width: 0; flex: 1 1 240px; }
#tab-orders #claim-order-id-input + .btn-convert {
  flex: 0 0 178px;
  width: 178px;
  min-width: 0;
  min-height: 52px;
  padding: 9px 14px !important;
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  white-space: normal;
  line-height: 1.25;
}

/* Support-page chat CTA: wider visual footprint and centered label. */
#tab-support button.btn-convert[onclick*="toggleChatWidget"] {
  width: min(100%, 520px);
  min-height: 54px;
  margin: 14px auto 0;
  padding: 12px 22px !important;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  white-space: normal;
  line-height: 1.25;
}
#tab-support button.btn-convert[onclick*="toggleChatWidget"] span { text-align: center; }

@media (max-width: 520px) {
  #btn-convert-action { min-width: 160px; min-height: 50px; padding-inline: 14px !important; }
  #tab-orders #claim-order-id-input + .btn-convert {
    flex-basis: 164px;
    width: 164px;
    min-height: 54px;
  }
  #tab-support button.btn-convert[onclick*="toggleChatWidget"] {
    width: min(100%, 520px);
    min-height: 56px;
    padding-inline: 16px !important;
  }
}
@media (prefers-reduced-motion: reduce) {
  .btn-convert, .balance-withdraw-action .btn-copy, .customer-withdrawals-refresh { transition: none !important; }
}
