/* =====================================================================
   ZEIBAN — Shell: header, sidebar, conteúdo, painel direito, footer
   ===================================================================== */
#app { height: 100%; }

/* ---------------- HEADER ---------------- */
.app-header { position: fixed; top: 0; left: 0; right: 0; height: var(--header-h); display: flex; background: var(--bg-header); border-bottom: 1px solid var(--border); z-index: var(--z-header); }
.header-side { width: var(--side-w); flex: none; display: flex; align-items: center; gap: 10px; padding: 0 16px; background: var(--side); border-right: 1px solid var(--border); transition: width var(--dur) var(--ease); overflow: hidden; }
.header-main { flex: 1; min-width: 0; padding: 0 var(--gutter); transition: padding-right var(--dur) var(--ease); }
.header-inner { max-width: calc(var(--content-max) - var(--gutter) * 2); margin: 0 auto; height: 100%; display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.header-logo { display: flex; align-items: center; }
.logo-mark-only { display: none; }
.brand-logo { display: inline-flex; align-items: center; gap: 0.5rem; }
.brand-word { font-family: var(--font-display); font-size: 1.7rem; letter-spacing: 0.04em; line-height: 1; color: #fff; }

.icon-btn { width: 40px; height: 40px; border-radius: var(--r-md); display: grid; place-items: center; color: var(--muted); transition: background var(--dur-fast), color var(--dur-fast); flex: none; }
.icon-btn:hover { background: var(--btn-dark); color: #fff; }
.burger { width: 32px; height: 32px; color: #fff; margin-left: 1px; }
html.sidebar-collapsed .burger { color: var(--purple-soft); }

.seg-toggle { display: flex; flex: 1; background: var(--panel-2); border-radius: 6px; padding: 0; gap: 0; min-width: 0; height: 48px; }
.seg { flex: 1; display: flex; align-items: center; justify-content: center; gap: 0.35rem; height: 48px; border-radius: 6px; border: 1px solid transparent; font-weight: 700; font-size: 14px; color: #fff; transition: background var(--dur-fast), color var(--dur-fast); white-space: nowrap; }
.seg:hover { color: #fff; }
.seg-ic { display: none; }
/* ativo: textura ilustrada (arte original Zeiban) sobre o roxo; canto arredondado só do lado externo */
.seg.active { color: #fff; font-weight: 700; border-color: transparent; background: #7717ff url("../img/ui/seg-active.svg?v=qa1") left center / cover no-repeat; }
.seg:first-child { border-radius: 6px 0 0 6px; }
.seg:last-child { border-radius: 0 6px 6px 0; }
.seg:last-child.active { background-position: right center; }
.seg-toggle { overflow: hidden; }
.seg:not(.active) { font-weight: 500; }

.header-auth { display: flex; align-items: center; gap: 0.5rem; }
.hdr-wallet { display: flex; align-items: center; background: var(--panel-2); border: 1px solid var(--border-2); border-radius: var(--r-md); padding: 3px; gap: 3px; }
.hdr-balance { display: flex; align-items: center; gap: 0.4rem; padding: 0 0.7rem; height: 38px; font-weight: 700; font-size: var(--text-sm); }
.hdr-balance .z-icon { color: var(--dim); }
.hdr-wallet-btn { height: 38px; }
.coin-ic { display: inline-flex; width: 18px; height: 18px; flex: none; }
.coin-ic svg { width: 100%; height: 100%; }
.coin-ic.sm { width: 14px; height: 14px; }

/* ---------------- BODY / CONTEÚDO ---------------- */
.app-body { position: fixed; top: var(--header-h); left: 0; right: 0; bottom: 0; display: flex; }
.app-content { flex: 1; min-width: 0; overflow-y: auto; overflow-x: hidden; scrollbar-width: none; container-type: inline-size; }
.app-content::-webkit-scrollbar { display: none; }
.content-inner { max-width: var(--content-max); margin: 0 auto; padding: 1.5rem var(--gutter) 3rem; min-height: calc(100vh - var(--header-h) - 1px); }
#outlet { min-width: 0; }

/* ---------------- SIDEBAR ---------------- */
.sidebar { width: var(--side-w); flex: none; background: var(--side); border-right: 1px solid var(--border); display: flex; flex-direction: column; overflow: hidden; transition: width var(--dur) var(--ease); z-index: var(--z-side); }
.sidebar-scroll { flex: 1; overflow-y: auto; overflow-x: hidden; padding-bottom: 1.5rem; scrollbar-width: none; }
.sidebar-scroll::-webkit-scrollbar { display: none; }
.side-top { padding: 16px 16px 0; display: flex; flex-direction: column; gap: 0; }
.side-seg { display: none; }
.side-search { display: flex; align-items: center; gap: 8px; width: 100%; height: 48px; padding: 0 16px; background: #080808; border: 1px solid #2a2e38; border-radius: 6px; color: #828998; font-size: 14px; margin-bottom: 16px; transition: border-color var(--dur-fast); }
.side-search:hover { border-color: #3a3e48; }
.token-card { display: flex; flex-direction: column; gap: 10px; margin: 0 -16px; padding: 16px; border-top: 1px solid #2a2e38; }
.token-main { display: flex; align-items: center; gap: 10px; }
.token-chip { width: 48px; height: 48px; border-radius: 8px; background: #202329; display: grid; place-items: center; flex: none; }
.token-chip svg { width: 30px; height: 30px; }
.token-name { font-size: 14px; font-weight: 500; white-space: nowrap; line-height: 21px; }
.token-name b { font-weight: 500; }
.token-name span { color: #9ba5b4; }
.token-price { display: flex; gap: 4px; font-size: 14px; font-weight: 500; color: #9ba5b4; line-height: 16px; margin-top: 2px; }
.token-change { color: var(--red); }
.token-change.up { color: var(--green); }
.token-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 0.5rem; }
.token-actions .btn { height: 36px; font-size: 12px; font-weight: 400; }

.nav-divider { height: 1px; background: #2a2e38; margin: 0; }
.nav-divider.top { margin-top: 0; }
.side-nav { display: flex; flex-direction: column; }
.nav-section { display: flex; flex-direction: column; padding: 8px 0; }
.side-nav > .nav-section:first-child { padding-top: 10px; padding-bottom: 10px; }
.nav-item { position: relative; display: flex; align-items: center; gap: 10px; height: 48px; padding: 0 25px 0 24px; border-radius: 0; color: #fff; font-weight: 500; font-size: 14px; white-space: nowrap; transition: background var(--dur-fast), color var(--dur-fast); width: 100%; text-align: left; }
.nav-item:hover { background: #202329; }
.nav-ic { display: inline-flex; flex: none; color: currentColor; }
.nav-ic svg { width: 16px; height: 16px; }
.nav-label { flex: 1; overflow: hidden; text-overflow: ellipsis; }
.nav-item.active { color: var(--purple-soft); }
.nav-item.active::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 4px; border-radius: 0 24px 24px 0; background: #886cff; }
.nav-item.disabled { color: var(--faint); }
.nav-item.gold { color: var(--gold); }
.nav-badge { font-size: 12px; font-weight: 700; line-height: 20px; height: 20px; min-width: 28px; text-align: center; padding: 0 5px; border-radius: 4px; }
.nav-badge.purple { background: #886cff; color: #fff; }
.nav-badge.green { background: #1f9d55; color: #fff; }
.nav-badge.green-text { color: #6fef8a; }
.nav-dot { display: none; }
.nav-caret { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 8px; background: #202329; color: #fff; transition: transform var(--dur); margin-right: -9px; }
.nav-caret svg { width: 10px; height: 10px; }
.nav-group.open .nav-caret { transform: rotate(180deg); }
.nav-sub { display: grid; grid-template-rows: 0fr; transition: grid-template-rows var(--dur) var(--ease); }
.nav-group.open .nav-sub { grid-template-rows: 1fr; }
.nav-sub-inner { overflow: hidden; display: flex; flex-direction: column; }
.nav-subitem { display: flex; align-items: center; gap: 10px; height: 48px; padding: 0 25px 0 32px; color: #fff; font-weight: 400; font-size: 14px; white-space: nowrap; }
.nav-subitem > span:not(.z-icon):not(.nav-badge) { flex: 1; overflow: hidden; text-overflow: ellipsis; }
.nav-subitem .z-icon svg { width: 16px; height: 16px; }
.nav-subitem:hover { background: #202329; color: #fff; }
.nav-subitem.active { color: var(--purple-soft); }

/* recolhida (64px) */
html.sidebar-collapsed { --side-w: var(--side-w-collapsed); }
html.sidebar-collapsed .header-side { padding: 0; justify-content: center; }
html.sidebar-collapsed .seg-toggle { display: none; }
html.sidebar-collapsed .side-seg { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 0.75rem 0 0.5rem; margin: 0 auto; }
.side-seg-btn { width: 36px; height: 36px; border-radius: var(--r-md); display: grid; place-items: center; color: var(--muted); background: var(--panel-2); border: 1px solid var(--border-2); }
.side-seg-btn svg { width: 18px; height: 18px; }
.side-seg-btn.active { background: #7717ff url("../img/ui/seg-active.svg?v=qa1") 70% center / cover no-repeat; color: #fff; border-color: var(--purple); }
html.sidebar-collapsed .side-top { padding: 0.5rem 0 0.75rem; align-items: center; }
html.sidebar-collapsed .side-search { width: 40px; height: 40px; padding: 0; justify-content: center; border-color: transparent; background: var(--panel-2); }
html.sidebar-collapsed .side-search > span:not(.z-icon), html.sidebar-collapsed .token-info, html.sidebar-collapsed .token-actions,
html.sidebar-collapsed .nav-label, html.sidebar-collapsed .nav-badge, html.sidebar-collapsed .nav-caret, html.sidebar-collapsed .nav-sub { display: none; }
html.sidebar-collapsed .token-main { justify-content: center; }
html.sidebar-collapsed .nav-section { padding: 8px 0; }
html.sidebar-collapsed .nav-item { justify-content: center; padding: 0; height: 48px; }
html.sidebar-collapsed .nav-item.active::before { left: 0; }
html.sidebar-collapsed .nav-dot { display: block; position: absolute; right: 8px; top: 50%; width: 6px; height: 6px; border-radius: 50%; transform: translateY(-50%); background: var(--purple); }
html.sidebar-collapsed .nav-dot.green, html.sidebar-collapsed .nav-dot.green-text { background: var(--green); }
html.sidebar-collapsed [data-tip] { position: relative; }
html.sidebar-collapsed .sidebar [data-tip]:hover::after { content: attr(data-tip); position: fixed; left: calc(var(--side-w-collapsed) + 8px); transform: translateY(-50%); margin-top: 21px; background: var(--btn-dark); color: #fff; padding: 0.4rem 0.7rem; border-radius: var(--r-sm); font-size: var(--text-sm); font-weight: 600; white-space: nowrap; z-index: 100; box-shadow: var(--shadow-pop); pointer-events: none; }
.sidebar-scrim { position: fixed; inset: var(--header-h) 0 0 0; background: rgba(0, 0, 0, 0.6); opacity: 0; pointer-events: none; transition: opacity var(--dur); z-index: 44; }

/* ---------------- PAINEL DIREITO ---------------- */
/* painel direito ocupa a altura toda; header e conteúdo encolhem (como no original) */
.right-panel { position: fixed; top: 0; right: 0; bottom: 0; width: 0; overflow: hidden; background: var(--panel); border-left: 1px solid var(--border); transition: width var(--dur) var(--ease); z-index: var(--z-right); }
html.right-open .right-panel { width: var(--right-w); }
.app-header { transition: right var(--dur) var(--ease); }
.app-content { transition: margin-right var(--dur) var(--ease); }
html.right-open .app-header { right: var(--right-w); }
html.right-open .app-content { margin-right: var(--right-w); }
.rp-inner { width: var(--right-w); height: 100%; display: flex; flex-direction: column; }
.rp-head { position: relative; display: flex; align-items: center; justify-content: space-between; gap: 0.5rem; height: var(--header-h); padding: 0 1rem; border-bottom: 1px solid var(--border); flex: none; }
.slip-title { display: flex; align-items: center; gap: 0.5rem; font-weight: 700; font-size: var(--text-lg); }
.slip-count { background: var(--purple); color: #fff; font-size: 0.72rem; font-weight: 800; padding: 0.15rem 0.4rem; border-radius: 4px; }
.slip-title-caret svg { width: 16px; height: 16px; color: var(--dim); }
.slip-menu { position: absolute; top: 52px; left: 0.75rem; background: var(--panel-3); border: 1px solid var(--border-2); border-radius: var(--r-md); box-shadow: var(--shadow-pop); padding: 0.3rem; display: none; flex-direction: column; z-index: 5; min-width: 240px; }
.rp-head.menu-open .slip-menu { display: flex; }
.slip-menu button { text-align: left; padding: 0.55rem 0.7rem; border-radius: var(--r-sm); font-size: var(--text-sm); color: var(--muted); font-weight: 600; }
.slip-menu button:hover { background: var(--btn-dark); color: #fff; }
.slip-body { flex: 1; overflow-y: auto; padding: 0.25rem 0 1rem; }
.slip-acc-head { width: 100%; display: flex; align-items: center; justify-content: space-between; padding: 0.9rem 1rem; font-size: var(--text-sm); font-weight: 600; color: var(--muted); }
.slip-acc-caret { transition: transform var(--dur); display: inline-flex; }
.slip-acc-caret svg { width: 16px; height: 16px; }
.slip-acc.open .slip-acc-caret { transform: rotate(180deg); }
.slip-acc-body { display: grid; grid-template-rows: 0fr; transition: grid-template-rows var(--dur) var(--ease); }
.slip-acc.open .slip-acc-body { grid-template-rows: 1fr; }
.slip-acc-body > div { overflow: hidden; padding: 0 1rem; }
.slip-cards { display: flex; flex-direction: column; gap: 0.6rem; }
.slip-card { background: var(--panel-2); border: 1px solid var(--border-2); border-radius: var(--r-md); overflow: hidden; margin-bottom: 0.6rem; }
.slip-card-head { display: flex; align-items: center; gap: 0.5rem; padding: 0.6rem 0.75rem; background: var(--panel-3); font-size: var(--text-sm); font-weight: 700; }
.slip-sport { display: inline-flex; color: var(--purple-soft); }
.slip-sport svg { width: 15px; height: 15px; }
.slip-match { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.slip-x { color: var(--dim); display: grid; place-items: center; }
.slip-x svg { width: 15px; height: 15px; }
.slip-x:hover { color: #fff; }
.slip-card-body { padding: 0.7rem 0.75rem; display: flex; flex-direction: column; gap: 0.4rem; }
.slip-pick-row { display: flex; justify-content: space-between; }
.slip-pick { color: var(--purple-soft); }
.slip-market { font-size: var(--text-xs); color: var(--dim); }
.slip-stake-row { display: flex; align-items: center; gap: 0.6rem; margin-top: 0.2rem; }
.slip-input { flex: 1; display: flex; align-items: center; gap: 0.45rem; background: var(--input); border: 1px solid var(--border-2); border-radius: var(--r-sm); padding: 0 0.6rem; height: 38px; min-width: 0; }
.slip-input:focus-within { border-color: var(--purple); }
.slip-stake { flex: 1; min-width: 0; background: none; border: none; outline: none; font-size: var(--text-sm); font-weight: 600; }
.slip-est { text-align: right; font-size: var(--text-xs); }
.slip-est div { display: flex; align-items: center; gap: 0.3rem; justify-content: flex-end; font-weight: 700; font-size: var(--text-sm); }
.slip-info { border: 1px solid var(--purple); background: rgba(119, 23, 255, 0.06); border-radius: var(--r-md); padding: 0.8rem; font-size: var(--text-sm); font-weight: 600; margin-bottom: 0.5rem; }
.slip-empty { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 0.5rem; padding: 2rem; text-align: center; }
.slip-empty-ic { width: 56px; height: 56px; border-radius: 50%; background: var(--panel-2); display: grid; place-items: center; color: var(--dim); margin-bottom: 0.3rem; }
.slip-empty-ic svg { width: 26px; height: 26px; }
.slip-empty .dim { font-size: var(--text-sm); margin-bottom: 0.5rem; }
.slip-foot { flex: none; border-top: 1px solid var(--border); padding: 0.9rem 1rem 1rem; display: flex; flex-direction: column; gap: 0.5rem; }
.slip-line { display: flex; align-items: center; justify-content: space-between; font-size: var(--text-sm); }
.slip-line > div { display: flex; align-items: center; gap: 0.35rem; font-weight: 700; }
.slip-foot .btn { margin-top: 0.4rem; height: 44px; }

/* chat */
.chat-room { display: flex; align-items: center; gap: 0.4rem; font-size: var(--text-sm); background: var(--panel-2); border: 1px solid var(--border-2); border-radius: var(--r-md); padding: 0.4rem 0.6rem; cursor: pointer; }
.chat-online { display: flex; align-items: center; gap: 0.35rem; font-size: var(--text-sm); color: var(--muted); margin-left: auto; }
.chat-online i { width: 8px; height: 8px; border-radius: 50%; background: var(--green); box-shadow: 0 0 8px var(--green); }
.chat-msgs { flex: 1; overflow-y: auto; padding: 0.75rem 1rem; display: flex; flex-direction: column; gap: 0.85rem; }
.chat-msg { display: flex; gap: 0.6rem; animation: fadeUp 0.25s var(--ease); }
.chat-avatar { width: 32px; height: 32px; border-radius: 50%; background: var(--btn-dark); display: grid; place-items: center; font-weight: 800; font-size: var(--text-xs); flex: none; }
.chat-bubble { background: var(--panel-2); border-radius: 0 var(--r-md) var(--r-md) var(--r-md); padding: 0.45rem 0.65rem; font-size: var(--text-sm); min-width: 0; }
.chat-meta { display: flex; align-items: center; gap: 0.4rem; margin-bottom: 0.1rem; }
.chat-user { font-size: var(--text-xs); }
.chat-lvl { font-size: 0.65rem; font-weight: 800; color: #e3a05b; background: rgba(205, 127, 50, 0.18); padding: 0.05rem 0.3rem; border-radius: 3px; }
.chat-text { color: var(--muted); word-break: break-word; }
.chat-foot { border-top: 1px solid var(--border); padding: 0.75rem 1rem; display: flex; flex-direction: column; gap: 0.5rem; }
.chat-input-row { display: flex; gap: 0.5rem; }
.chat-input { flex: 1; min-width: 0; height: 42px; background: var(--input); border: 1px solid var(--border-2); border-radius: var(--r-md); padding: 0 0.75rem; outline: none; }
.chat-input:focus { border-color: var(--purple); }
.chat-send { width: 42px; height: 42px; border-radius: var(--r-md); background: var(--purple); display: grid; place-items: center; }
.chat-send svg { width: 18px; height: 18px; }
.chat-rules { display: flex; justify-content: space-between; font-size: var(--text-xs); }
.chat-rules a { color: var(--purple-soft); }

/* user menu */
.user-wrap { position: relative; }
.user-menu { position: absolute; top: calc(100% + 10px); right: 0; width: 220px; background: var(--panel-3); border: 1px solid var(--border-2); border-radius: var(--r-md); box-shadow: var(--shadow-pop); padding: 0.35rem; opacity: 0; transform: translateY(-6px); pointer-events: none; transition: opacity var(--dur-fast), transform var(--dur-fast); z-index: 60; }
.user-wrap.open .user-menu { opacity: 1; transform: none; pointer-events: auto; }
.user-menu-item { display: flex; align-items: center; gap: 0.7rem; width: 100%; padding: 0.6rem 0.7rem; border-radius: var(--r-sm); color: var(--muted); font-weight: 600; font-size: var(--text-sm); }
.user-menu-item:hover { background: var(--btn-dark); color: #fff; }
.user-menu-item.danger { color: var(--red); }
.hdr-ic { background: var(--panel-2); border: 1px solid var(--border-2); }

/* ---------------- FOOTER ---------------- */
.app-footer { border-top: 1px solid var(--border); background: var(--side); }
.ft-inner { max-width: var(--content-max); margin: 0 auto; padding: 2.5rem var(--gutter) 1.25rem; }
.ft-top { display: grid; grid-template-columns: 200px 1fr 250px; gap: 2rem; align-items: start; }
.ft-brand { display: flex; flex-direction: column; gap: 1.25rem; }
.ft-logo .brand-word { font-size: 1.5rem; }
.ft-partner { display: flex; align-items: center; gap: 0.6rem; font-size: var(--text-sm); color: var(--muted); line-height: 1.3; }
.ft-partner b { color: #fff; }
.ft-cols { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.5rem; }
.ft-col h4 { font-size: var(--text-md); font-weight: 700; margin-bottom: 0.9rem; }
.ft-col li { margin-bottom: 0.65rem; }
.ft-col a { color: var(--dim); font-size: var(--text-sm); font-weight: 500; transition: color var(--dur-fast); }
.ft-col a:hover { color: #fff; }
.ft-dds { display: flex; flex-direction: column; gap: 0.75rem; }
.ft-dd { position: relative; }
.ft-dd-btn { width: 100%; height: 48px; display: flex; align-items: center; justify-content: space-between; padding: 0 1rem; background: var(--panel-2); border: 1px solid var(--border-2); border-radius: var(--r-md); font-weight: 600; font-size: var(--text-sm); }
.ft-dd-caret svg { width: 16px; height: 16px; transition: transform var(--dur); }
.ft-dd.open .ft-dd-caret svg { transform: rotate(180deg); }
.ft-dd-list { position: absolute; bottom: calc(100% + 6px); left: 0; right: 0; max-height: 280px; overflow-y: auto; background: var(--panel-3); border: 1px solid var(--border-2); border-radius: var(--r-md); box-shadow: var(--shadow-pop); padding: 0.3rem; display: none; z-index: 10; }
.ft-dd.open .ft-dd-list { display: block; }
.ft-dd-list button { display: block; width: 100%; text-align: left; padding: 0.5rem 0.7rem; border-radius: var(--r-sm); font-size: var(--text-sm); color: var(--muted); }
.ft-dd-list button:hover, .ft-dd-list button.active { background: var(--btn-dark); color: #fff; }
.ft-legal { color: var(--dim); font-size: var(--text-sm); margin: 2.25rem 0 1.25rem; line-height: 1.6; }
.ft-bottom { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding-top: 1.25rem; border-top: 1px solid var(--border); font-size: var(--text-sm); flex-wrap: wrap; }
.ft-copy { display: flex; align-items: center; gap: 0.9rem; }
.ft-seal { font-weight: 900; font-size: 0.8rem; background: #1a8a3d; color: #fff; padding: 0.2rem 0.45rem; border-radius: 4px; letter-spacing: 0.04em; }
.ft-seal.round { background: transparent; padding: 0; }
.ft-seal.age { background: transparent; border: 2px solid var(--muted); color: var(--muted); border-radius: 50%; width: 30px; height: 30px; display: grid; place-items: center; padding: 0; font-size: 0.7rem; }

/* ---------------- COOKIES / SUPORTE ---------------- */
.cookie-banner { position: fixed; bottom: 1.25rem; left: 50%; transform: translateX(-50%); display: flex; align-items: center; gap: 0.9rem; background: var(--panel-3); border: 1px solid var(--border-2); border-radius: var(--r-md); padding: 0.75rem 0.9rem; box-shadow: var(--shadow-pop); z-index: 66; font-size: var(--text-sm); font-weight: 600; transition: opacity var(--dur), transform var(--dur); width: max-content; max-width: calc(100vw - 2rem); }
.cookie-banner.hide { opacity: 0; transform: translate(-50%, 12px); }
.cookie-ic { font-size: 1.2rem; }
.cookie-banner .btn { height: 38px; flex: none; }
.cookie-banner .cookie-text { max-width: 440px; line-height: 1.4; }
/* selo fixo do modo demonstração (ZEIBAN_DEMO_MODE=1) */
.demo-ribbon { position: fixed; left: 1.1rem; bottom: 1.1rem; z-index: 64; display: flex; align-items: center; gap: 0.45rem; padding: 0.35rem 0.7rem 0.35rem 0.4rem; border-radius: 999px; background: rgba(20, 20, 24, 0.92); border: 1px solid #ff9d2e; color: #ffd9a8; font-size: 0.72rem; font-weight: 600; pointer-events: none; box-shadow: var(--shadow-pop); }
.demo-ribbon b { background: #ff9d2e; color: #1a1206; border-radius: 999px; padding: 0.1rem 0.45rem; font-weight: 900; letter-spacing: 0.06em; }
.support-bubble { position: fixed; right: 1.1rem; bottom: 1.1rem; width: 48px; height: 48px; border-radius: 50%; background: var(--purple); color: #fff; display: grid; place-items: center; z-index: 65; box-shadow: 0 6px 20px rgba(119, 23, 255, 0.45); transition: transform var(--dur-fast); }
.support-bubble:hover { transform: scale(1.06); }
.support-bubble svg { width: 22px; height: 22px; }
html.right-open .support-bubble { right: calc(var(--right-w) + 1.1rem); }
.support-widget { position: fixed; right: 1.1rem; bottom: 5rem; width: 360px; max-width: calc(100vw - 2rem); height: 480px; max-height: calc(100vh - 7rem); background: var(--panel); border: 1px solid var(--border-2); border-radius: var(--r-lg); box-shadow: var(--shadow-pop); z-index: 66; display: flex; flex-direction: column; overflow: hidden; opacity: 0; transform: translateY(12px); pointer-events: none; transition: opacity var(--dur), transform var(--dur); }
.support-widget.open { opacity: 1; transform: none; pointer-events: auto; }
.sup-head { display: flex; align-items: center; justify-content: space-between; padding: 1rem; background: linear-gradient(135deg, var(--purple), var(--purple-deep)); }
.sup-head span { display: block; font-size: var(--text-xs); opacity: 0.85; }
.sup-msgs { flex: 1; overflow-y: auto; padding: 1rem; display: flex; flex-direction: column; gap: 0.8rem; }
.sup-msg { display: flex; gap: 0.6rem; font-size: var(--text-sm); }
.sup-msg p { background: var(--panel-2); padding: 0.55rem 0.7rem; border-radius: 0 var(--r-md) var(--r-md) var(--r-md); color: var(--muted); margin-top: 0.2rem; }
.sup-msg.me { justify-content: flex-end; }
.sup-msg.me p { background: var(--purple); color: #fff; border-radius: var(--r-md) 0 var(--r-md) var(--r-md); }
.sup-av svg { width: 28px; height: 28px; }
.sup-foot { display: flex; gap: 0.5rem; padding: 0.75rem; border-top: 1px solid var(--border); }
.sup-foot input { flex: 1; height: 40px; background: var(--input); border: 1px solid var(--border-2); border-radius: var(--r-md); padding: 0 0.7rem; outline: none; min-width: 0; }
.sup-send { width: 40px; height: 40px; border-radius: var(--r-md); background: var(--purple); display: grid; place-items: center; }
.sup-send svg { width: 18px; height: 18px; }

/* ---------------- MOBILE NAV ---------------- */
.mobile-nav { display: none; position: fixed; left: 0; right: 0; bottom: 0; height: var(--mobile-nav-h); background: var(--bg-header); border-top: 1px solid var(--border); z-index: 50; }
.mnav-item { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; color: var(--dim); font-size: 0.66rem; font-weight: 700; }
.mnav-item:active { color: #fff; }

/* ---------------- MODAIS ---------------- */
html.no-scroll .app-content { overflow: hidden; }
.modal-overlay { position: fixed; inset: 0; background: rgba(0, 0, 0, 0.72); display: grid; place-items: center; padding: 1rem; z-index: var(--z-modal); opacity: 0; transition: opacity var(--dur); overflow-y: auto; }
.modal-overlay.show { opacity: 1; }
.modal { position: relative; width: 100%; max-width: 520px; background: var(--panel); border: 1px solid var(--border-2); border-radius: var(--r-lg); box-shadow: var(--shadow-pop); transform: translateY(10px) scale(0.985); transition: transform var(--dur) var(--ease); }
.modal-overlay.show .modal { transform: none; }
.modal-close { position: absolute; top: 0.75rem; right: 0.75rem; width: 32px; height: 32px; border-radius: var(--r-sm); display: grid; place-items: center; color: var(--muted); z-index: 3; }
.modal-close:hover { background: var(--btn-dark); color: #fff; }
.modal-close svg { width: 18px; height: 18px; }

/* auth */
.auth-overlay .modal { max-width: 1000px; overflow: hidden; background: #121418; }
.auth-grid { display: grid; grid-template-columns: 524px minmax(0, 1fr); height: min(768px, calc(100vh - 2rem)); }
.auth-left { position: relative; overflow: hidden; display: flex; flex-direction: column; justify-content: space-between; align-items: center; padding: 36px 32px 24px; background: #4d5361; }
.auth-left-art { position: absolute; inset: 0; }
.auth-left-art svg { width: 100%; height: 100%; }
.auth-left-top, .auth-left-note { position: relative; z-index: 1; }
.auth-left-top .brand-word { font-size: 1.5rem; }
.auth-left-note { font-size: 12px; text-align: center; color: #fff; font-weight: 700; max-width: 320px; text-shadow: 0 1px 4px rgba(0,0,0,0.6); }
.auth-left-note a { text-decoration: underline; }
.auth-right { position: relative; padding: 40px; display: flex; flex-direction: column; overflow-y: auto; scrollbar-width: none; }
.auth-tabs { display: grid; grid-template-columns: 1fr 1fr; border-bottom: 1px solid #4d5361; margin-bottom: 26px; }
.auth-tab { height: 33px; padding: 0 0 12px; font-weight: 400; font-size: 14px; color: #fff; position: relative; }
.auth-tab.active { color: #886cff; font-weight: 700; }
.auth-tab.active::after { content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 2px; background: #886cff; }
.auth-form { display: flex; flex-direction: column; gap: 16px; }
.af-field { display: flex; flex-direction: column; gap: 6px; }
.af-label { font-size: 12px; font-weight: 500; color: #fff; }
.af-label i { color: #fff; font-style: normal; }
.af-box { display: flex; align-items: center; background: #202329; border: 1px solid transparent; border-radius: 6px; padding: 0 16px; height: 48px; transition: border-color var(--dur-fast); }
.af-box:focus-within { border-color: var(--purple); }
.af-field.invalid .af-box { border-color: var(--red); }
.af-input { flex: 1; min-width: 0; background: none; border: none; outline: none; font-size: var(--text-md); }
.af-eye { color: var(--dim); display: grid; place-items: center; }
.af-eye svg { width: 18px; height: 18px; }
.af-err { color: var(--red); font-size: var(--text-xs); min-height: 0; }
.af-err:empty { display: none; }
.auth-forgot { display: flex; justify-content: flex-end; margin-top: -0.4rem; }
.link-btn { color: var(--purple-soft); font-weight: 600; font-size: var(--text-sm); }
.link-btn:hover { text-decoration: underline; }
.link-btn.center { align-self: center; }
.auth-ref { border-top: 1px solid #2a2e38; border-bottom: 1px solid #2a2e38; }
.auth-ref-head { width: 100%; display: flex; align-items: center; justify-content: space-between; height: 44px; padding: 0; font-size: 12px; font-weight: 500; }
.auth-ref-body { display: grid; grid-template-rows: 0fr; transition: grid-template-rows var(--dur) var(--ease); }
.auth-ref.open .auth-ref-body { grid-template-rows: 1fr; }
.auth-ref-body > div { overflow: hidden; }
.auth-ref.open .auth-ref-body > div { padding-bottom: 0.75rem; }
.auth-ref.open .acc-caret { transform: rotate(180deg); }
.auth-check { display: flex; align-items: flex-start; gap: 8px; font-size: 12px; color: #fff; cursor: pointer; line-height: 18px; }
.auth-check input { width: 16px; height: 16px; accent-color: #7717ff; margin-top: 1px; flex: none; }
.auth-check a { color: #fff; font-weight: 700; text-decoration: underline; }
.auth-or { text-align: center; font-size: 14px; font-weight: 400; color: #fff; margin: 16px 0 8px; }
.auth-socials { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.auth-social { height: 48px; border: 1px solid #fff; border-radius: 6px; display: grid; place-items: center; transition: background var(--dur-fast); }
.auth-social:hover { background: rgba(255,255,255,0.06); }
.auth-social svg { width: 16px; height: 16px; }
.auth-overlay .auth-submit { height: 54px; font-size: 14px; font-weight: 500; margin-top: 16px; }
.auth-forgot .link-btn { color: #fff; font-size: 12px; font-weight: 700; text-decoration: underline; }
.auth-back { position: absolute; top: 12px; left: 12px; width: 44px; height: 44px; display: grid; place-items: center; color: #fff; border-radius: 50%; }
.auth-back:hover { background: #202329; }
.auth-back svg { width: 16px; height: 16px; }
.auth-form.forgot { margin: auto 0; }
.auth-overlay .auth-form.forgot .auth-submit { margin-top: 24px; }
.auth-h3 { font-size: 22px; font-weight: 700; text-align: center; margin: 0 0 12px; }
.auth-desc { font-size: 12px; font-weight: 500; color: #fff; line-height: 18px; margin: 0; }

/* busca */
.search-overlay { align-items: start; padding-top: 7vh; }
.search-overlay .modal { max-width: 1000px; background: var(--panel); }
.sm-bar { display: flex; align-items: center; gap: 0.7rem; padding: 0.9rem 1rem; border-bottom: 1px solid var(--border); color: var(--dim); }
.sm-input { flex: 1; background: none; border: none; outline: none; font-size: 1.05rem; color: #fff; }
.sm-close { font-size: var(--text-xs); font-weight: 800; color: var(--dim); border: 1px solid var(--border-2); border-radius: var(--r-sm); padding: 0.25rem 0.5rem; }
.sm-results { max-height: 68vh; overflow-y: auto; padding: 1rem; }
.sm-hint { color: var(--dim); font-size: var(--text-sm); margin-bottom: 1rem; }
.sm-sec b { display: block; margin-bottom: 0.75rem; }
.sm-recent { margin-bottom: 1rem; }
.sm-chips { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-top: 0.5rem; }
.chip-btn { background: var(--btn-dark); border-radius: var(--r-full); padding: 0.3rem 0.75rem; font-size: var(--text-sm); font-weight: 600; }

/* toasts */
#z-toasts { position: fixed; top: calc(var(--header-h) + 0.75rem); right: 1rem; display: flex; flex-direction: column; gap: 0.5rem; z-index: var(--z-toast); align-items: flex-end; pointer-events: none; }
.z-toast { background: var(--panel-3); border: 1px solid var(--border-2); border-left: 3px solid var(--purple); color: #fff; padding: 0.75rem 1rem; border-radius: var(--r-md); font-size: var(--text-sm); font-weight: 600; box-shadow: var(--shadow-pop); opacity: 0; transform: translateX(16px); transition: all var(--dur) var(--ease); max-width: 360px; }
.z-toast.show { opacity: 1; transform: none; }
.z-toast.ok { border-left-color: var(--green); }
.z-toast b { color: var(--purple-soft); }

@keyframes fadeUp { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
/* foco 31/10: contraste do menu (itens de quem nao entrou e selo roxo) */
.nav-item.disabled { color: #7f8696; }
.nav-badge.purple { background: #6a4cf0; }
/* foco 31/10: esportes no PC - o cupom de aposta fica no canto direito do iframe; o suporte vai para o canto esquerdo */
@media (min-width: 821px) { body:has(.esp-frame-wrap) .support-bubble { right: auto; left: calc(var(--side-w) + 0.6rem); } }
