/* Shared top navigation, used on every page with the site header.
   Extracted from the /play inline styles so all pages match. */

  .navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    /* Above the chat (#chat is z-index 1004) so the user/hamburger dropdown
       is not clipped on mobile, but still below modal overlays (9999). */
    z-index: 1010;
    background: rgba(10, 10, 10, 0.95);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  }

  .nav-container {
    max-width: 100%;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 53px;
  }

  .nav-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
  }

  /* === Brand Logo (3D + Glow + Hover Rotate) === */
  .brand-logo {
    width: 44px;
    height: 44px;
    position: relative;
    cursor: pointer;
    transform-style: preserve-3d;
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    will-change: transform;
  }

  .brand-logo:hover {
    transform: rotateY(180deg) scale(1.1);
  }

  .bitcoin-symbol {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 30px;
    font-weight: 900;
    color: #000;
    background: linear-gradient(145deg, #00ffcc, #00d4aa, #4ecdc4);
    border-radius: 11px;
    overflow: hidden;
    transform-style: preserve-3d;
  }

  .bitcoin-symbol::before {
    content: '';
    position: absolute;
    inset: -2px;
    background: linear-gradient(145deg, #00b8a3, #009688);
    border-radius: 18px;
    z-index: -1;
    transform: translateZ(-4px);
  }

  .bitcoin-symbol::after {
    content: '';
    position: absolute;
    inset: -4px;
    background: conic-gradient(
      from 0deg,
      transparent,
      rgba(0, 255, 204, 0.6),
      transparent,
      rgba(0, 255, 204, 0.6),
      transparent
    );
    border-radius: 20px;
    z-index: -2;
    opacity: 0;
    animation: logoRotate 3s linear infinite;
    transition: opacity 0.3s ease;
  }

  .brand-logo:hover .bitcoin-symbol::after {
    opacity: 1;
  }

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

  /* === Floating Particles === */
  .brand-logo-particles {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 80px;
    height: 80px;
    transform: translate(-50%, -50%);
    pointer-events: none;
    z-index: -1;
  }

  .particle {
    position: absolute;
    width: 3px;
    height: 3px;
    background: #00ffcc;
    border-radius: 50%;
    opacity: 0;
    animation: particleFloat 2s ease-in-out infinite;
  }

  .particle:nth-child(1) { top: 10%; left: 20%; animation-delay: 0s; }
  .particle:nth-child(2) { top: 20%; right: 15%; animation-delay: 0.3s; }
  .particle:nth-child(3) { bottom: 20%; left: 15%; animation-delay: 0.6s; }
  .particle:nth-child(4) { bottom: 10%; right: 20%; animation-delay: 0.9s; }

  .user-menu-container { position: relative; display: flex; align-items: center; height: 38px; }
  .user-menu-toggle { cursor: pointer; border: none; background: linear-gradient(145deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.05)); display: flex; align-items: center; gap: 8px; padding: 6px 10px 6px 12px; height: 38px; }
  .user-menu-hamburger { width: 14px; height: 10px; display: flex; flex-direction: column; justify-content: space-between; position: relative; margin-left: 4px; }
  .user-menu-hamburger span { display: block; height: 1.5px; width: 100%; background: #fff; border-radius: 2px; transition: all 0.25s ease; transform-origin: center; }
  .user-menu-toggle.active .user-menu-hamburger span:nth-child(1) { transform: translateY(4.25px) rotate(45deg); }
  .user-menu-toggle.active .user-menu-hamburger span:nth-child(2) { opacity: 0; }
  .user-menu-toggle.active .user-menu-hamburger span:nth-child(3) { transform: translateY(-4.25px) rotate(-45deg); }
  .user-menu-dropdown {
    display: none;
    position: absolute;
    right: 0;
    top: calc(100% + 8px);
    z-index: 9999;
  }
  .user-menu-dropdown.active { display: block; }
  .user-menu-panel {
    display: flex;
    flex-direction: column;
    min-width: 230px;
    background: rgb(23, 23, 23);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 16px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.6);
    overflow: hidden;
    padding: 6px 0;
  }
  .user-menu-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 18px;
    color: rgba(255, 255, 255, 0.9);
    text-decoration: none;
    background: transparent;
    border: none;
    width: 100%;
    text-align: left;
    font-size: 14px;
    cursor: pointer;
    font-family: 'Inter', sans-serif;
    position: relative;
    transition: all 0.2s ease;
    white-space: nowrap;
  }
  .user-menu-link i { width: 18px; text-align: center; opacity: 0.9; }
  .user-menu-link:hover {
    color: #fff;
    background: linear-gradient(90deg, rgba(0, 255, 204, 0.18) 0%, rgba(0, 255, 204, 0.08) 40%, transparent 100%);
    box-shadow: inset 3px 0 0 rgba(0, 255, 204, 0.7);
    text-shadow: 0 0 12px rgba(0, 255, 204, 0.25);
  }
  .user-menu-link:hover i { color: #00ffcc; }
  .user-menu-logout { color: #ff7b7b; }
  .user-menu-logout:hover { color: #ff8f8f; background: linear-gradient(90deg, rgba(255, 107, 107, 0.18) 0%, rgba(255, 107, 107, 0.08) 40%, transparent 100%); box-shadow: inset 3px 0 0 rgba(255, 107, 107, 0.7); }
  .user-menu-logout:hover i { color: #ff6b6b; }

  @keyframes particleFloat {
    0%, 100% {
      opacity: 0;
      transform: translateY(0px) scale(0.5);
    }
    50% {
      opacity: 1;
      transform: translateY(-20px) scale(1);
    }
  }

  /* === Brand Text === */
  .brand-text {
    font-size: 28px;
    font-weight: 900;
    color: #fff;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5), 0 0 20px rgba(0, 255, 204, 0.3);
    letter-spacing: -0.5px;
    transform-style: preserve-3d;
    transition: all 0.3s ease;
  }

  .brand-text .gradient-text {
    background: linear-gradient(45deg, #00ffcc, #00d4aa, #4ecdc4, #00ffcc, #00d4aa);
    background-size: 200% 200%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: holographicShift 3s ease-in-out infinite;
  }

.brand-text .gradient-text i.fa-btc,
.brand-text .gradient-text i.fab {
    font-family: "Font Awesome 6 Brands" !important;
    font-weight: 400 !important;
    font-style: normal !important;
}
.brand-text .gradient-text i.fa-btc::before,
.brand-text .gradient-text i.fab::before {
    background: linear-gradient(45deg, #00ffcc, #00d4aa, #4ecdc4, #00ffcc, #00d4aa);
    background-size: 200% 200%;
    -webkit-background-clip: text !important;
    background-clip: text !important;
    -webkit-text-fill-color: transparent !important;
    color: transparent !important;
}


  @keyframes holographicShift {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
  }

  .nav-brand:hover .gradient-text {
    animation-duration: 1s;
  }

  .nav-brand:hover .particle {
    animation-play-state: running;
  }

  /* === User Navigation Panel (.x8sd89) === */
  .x8sd89 {
    display: flex;
    align-items: center;
    gap: 16px;
    font-family: 'Inter', sans-serif;
  }

  .bal9k2x, .usr5q8w {
    display: flex;
    align-items: center;
    gap: 8px;
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.05));
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 12px;
    overflow: hidden;
    position: relative;
    transition: all 0.3s ease;
  }

  .bal9k2x {
    padding: 10px 12px;
    height: 38px;
  }

  .usr5q8w {
    padding: 6px 12px;
    cursor: pointer;
    color: inherit;
    height: 38px;
    text-decoration: none;
  }

  .bal9k2x::before,
  .usr5q8w::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transition: left 0.5s;
  }

  .bal9k2x:hover::before,
  .usr5q8w:hover::before {
    left: 100%;
  }

  .bal9k2x:hover,
  .usr5q8w:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 255, 204, 0.2);
    border-color: rgba(0, 255, 204, 0.3);
  }

  .lbl4m8n {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.7);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
  }

  .amt7k4p {
    font-size: 14px;
    color: #fff;
    font-weight: 700;
    font-family: 'Monaco', monospace;
    text-shadow: 0 0 8px rgba(0, 255, 204, 0.3);
  }

  .balance-deposit-group {
    display: flex;
    align-items: center;
    gap: 0;
    transition: transform 0.3s ease;
  }

  /* Balance + Deposit read as one control: rounded on the outer corners,
     square where they meet, with the shared border collapsed. */
  .balance-deposit-group .bal9k2x {
    border-radius: 12px 0 0 12px;
  }

  .balance-deposit-group:hover {
    transform: translateY(-1px);
  }

  .balance-deposit-group .bal9k2x:hover {
    transform: none;
  }

  .deposit-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    height: 38px;
    margin-left: -1px;
    padding: 0 12px;
    border-radius: 0 12px 12px 0;
    background: linear-gradient(145deg, #00b8a3, #009688);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #001a17;
    font-family: 'Inter', sans-serif;
    font-size: 13px;
    font-weight: 800;
    white-space: nowrap;
    text-decoration: none;
    box-shadow: 0 12px 32px rgb(0 255 204 / 0%), inset 0 1px 0 rgba(255, 255, 255, 0.4);
    transition: all 0.3s ease;
  }

  .deposit-btn:hover {
    transform: none;
    box-shadow: 0 4px 12px rgba(0, 255, 204, 0.35);
    border-color: rgba(0, 255, 204, 0.55);
    color: #001a17;
  }

  .deposit-btn i {
    display: none;
  }

  .avt2r6e {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: linear-gradient(145deg, #00a796, #00d4aa);
    font-size: 12px;
    font-weight: 700;
    color: #000;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
  }

  .usr5q8w:hover .avt2r6e {
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(0, 255, 204, 0.4);
  }

  .nam1t9y {
    font-size: 14px;
    color: #fff;
    font-weight: 600;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
  }

  /* === Responsive Layout === */
  .large-screen { display: none; }

  @media (min-width: 768px) {
    .large-screen { display: inline; }
  }

  @media (max-width: 767px) {
    .nav-actions, .x8sd89 { gap: 12px; }
    .bal9k2x { padding: 8px 10px; }
    .lbl4m8n { font-size: 11px; }
    .amt7k4p { font-size: 13px; }
    .balance-deposit-group { gap: 0; }
    .deposit-btn { width: 38px; height: 38px; padding: 0; }
    .deposit-btn-text { display: none; }
    .deposit-btn i { display: inline-block; font-size: 13px; }
    .usr5q8w { padding: 5px 10px; }
    .avt2r6e { width: 22px; height: 22px; font-size: 11px; }
    .nam1t9y { font-size: 13px; }
  }

  @media (max-width: 640px) {
    .x8sd89 { gap: 8px; }
    .nam1t9y {
      max-width: 80px;
      overflow: hidden;
      text-overflow: ellipsis;
      white-space: nowrap;
    }
  }

  @media (max-width: 480px) {
    .x8sd89 { gap: 6px; align-items: center; flex-direction: row-reverse; }
    .balance-deposit-group { order: 2; }
    .balance-deposit-group .bal9k2x { order: 0; }
    .balance-deposit-group .deposit-btn { order: 0; }
    .user-menu-toggle .nam1t9y { display: none; }
    .bal9k2x { order: 2; }
    .usr5q8w { order: 1; }
    .nam1t9y { max-width: 70px; }
    .user-menu-dropdown { right: -6px; }
    .user-menu-panel { min-width: 210px; }
  }
