/* ============================================================
 * Global Header — Premium Glass + OLED Luxury
 * BEM namespace: .gh-*
 * Refinamento visual: glassmorphism, esfera 3D, microinterações.
 * ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@500;600;700&display=swap');

/* Reset body/html margins — elimina faixa branca em volta do header em
   QUALQUER layout (publico, /panel, member-area). Browser default tem
   body { margin: 8px } que cria 8px de gap em todas as bordas. */
body,
html {
    margin: 0 !important;
    padding: 0 !important;
}

:root {
    /* Header SEMPRE acima de qualquer conteudo — so help-widget pode subir mais */
    --z-header: 999990;
    --z-header-overlay: 999980;
    --z-header-dropdown: 999985;
    --z-header-mobile-sheet: 999988;

    --gh-header-height: 68px;
    --gh-header-height-scrolled: 56px;
    --gh-max-width: 1400px;

    --gh-orange: #F36707;
    --gh-orange-soft: #FF8A3D;
    --gh-green: #749A17;
    --gh-purple: #A78BFA;

    --gh-ease-out: cubic-bezier(0.22, 0.61, 0.36, 1);
    --gh-ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);

    --gh-font-display: 'Space Grotesk', 'Poppins', system-ui, sans-serif;
    --gh-font-mono: 'JetBrains Mono', ui-monospace, monospace;
}

/* ===== HEADER ===== */
.gh-header {
    position: relative;
    width: 100%;
    height: var(--gh-header-height);
    z-index: var(--z-header);
    transition: height 220ms var(--gh-ease-out), background-color 300ms var(--gh-ease-out), box-shadow 300ms var(--gh-ease-out), border-color 300ms var(--gh-ease-out);
    font-family: 'Inter', system-ui, sans-serif;
    box-sizing: border-box;
}

.gh-header *,
.gh-header *::before,
.gh-header *::after { box-sizing: border-box; }

.gh-header--sticky-enabled {
    position: sticky;
    top: 0;
}

/* NB0.18: shrink removido — header com altura fixa (alinha com --header-height
   do member-area/layout.css e elimina gap no topo do sidebar ao rolar).
.gh-header--scrolled {
    height: var(--gh-header-height-scrolled);
    box-shadow: 0 1px 0 rgba(255,255,255,0.04), 0 4px 24px rgba(0,0,0,0.4);
}
*/
/* Mantém só a sombra quando rolado (sem mudar altura) */
.gh-header--scrolled {
    box-shadow: 0 1px 0 rgba(255,255,255,0.04), 0 4px 24px rgba(0,0,0,0.4);
}

/* THEMES — blur sutil (nao sobrepoe conteudo) */
.gh-header--dark {
    background: linear-gradient(180deg, rgba(10,10,12,0.92) 0%, rgba(15,15,18,0.88) 100%);
    color: #FFFFFF;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(255,255,255,0.06);
}

.gh-header--light {
    background: rgba(255,255,255,0.94);
    color: #0F172A;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(15,23,42,0.08);
}

/* Quando dropdown aberto, header fica fully opaque PRESERVANDO o tema */
.gh-header--dark:has(.gh-mega-dropdown) {
    background: rgba(10,10,12,0.98);
}
.gh-header--light:has(.gh-mega-dropdown) {
    background: rgba(255,255,255,0.98);
}

.gh-header--transparent:not(.gh-header--scrolled) {
    background: transparent;
    border-bottom: none;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
}

/* INNER LAYOUT — full-bleed total (encostado nas bordas) */
.gh-header__inner {
    height: 100%;
    width: 100%;
    max-width: 100%;
    margin: 0;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

/* Primeiro/ultimo item ganham um respiro lateral menor pra nao colar 100% */
.gh-header__left { padding-left: 6px; }
.gh-header__right { padding-right: 6px; }

.gh-header__left,
.gh-header__right {
    display: flex;
    align-items: center;
    gap: 14px;
    flex: 0 0 auto;
}

.gh-header__center {
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 1 1 auto;
}

/* LOGO */
.gh-header__logo-link {
    display: inline-flex;
    align-items: center;
    text-decoration: none;
    color: inherit;
    line-height: 0;
    transition: transform 250ms var(--gh-ease-spring), box-shadow 220ms var(--gh-ease-out);
    border-radius: 12px;
    padding: 4px 10px;
}

.gh-header__logo-link:hover { transform: scale(1.03); }

/* No tema DARK, logo ganha caixa branca pra destacar (igual aos logos dos pilares) */
.gh-header--dark .gh-header__logo-link {
    background: #FFFFFF;
    box-shadow: 0 4px 12px rgba(0,0,0,0.35), 0 0 0 1px rgba(0,0,0,0.04);
}

.gh-header--dark .gh-header__logo-link:hover {
    box-shadow: 0 6px 18px rgba(0,0,0,0.45), 0 0 0 1px rgba(255,255,255,0.1);
}

.gh-header__logo {
    height: 36px;
    width: auto;
    object-fit: contain;
    transition: height 220ms var(--gh-ease-out);
    filter: drop-shadow(0 2px 6px rgba(243,103,7,0.18));
}

/* NB0.18: logo não encolhe mais — mantém altura natural */

.gh-header__logo-text {
    font-family: var(--gh-font-display);
    font-weight: 700;
    font-size: 22px;
    letter-spacing: -0.03em;
}

/* ===== PILLAR SWITCHER — moldura quadrada compativel com tamanho do logo ===== */
.gh-pillar-switcher { position: relative; display: inline-block; }

.gh-pillar-switcher__trigger {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    padding: 0;
    border-radius: 12px;
    background: rgba(255,255,255,0.04);
    border: 1.5px solid rgba(255,255,255,0.12);
    cursor: pointer;
    transition: transform 200ms var(--gh-ease-spring), background 200ms var(--gh-ease-out), border-color 200ms var(--gh-ease-out), box-shadow 200ms var(--gh-ease-out);
    overflow: hidden;
    color: rgba(255,255,255,0.6);
}
.gh-header--light .gh-pillar-switcher__trigger {
    background: rgba(15,23,42,0.04);
    border-color: rgba(15,23,42,0.12);
    color: rgba(15,23,42,0.6);
}

.gh-pillar-switcher__trigger:hover {
    background: rgba(255,255,255,0.08);
    border-color: rgba(243,103,7,0.5);
    transform: translateY(-1px);
    box-shadow: 0 6px 18px rgba(243,103,7,0.25);
}
.gh-header--light .gh-pillar-switcher__trigger:hover {
    background: rgba(243,103,7,0.06);
}

.gh-pillar-switcher[data-pillar="x"] .gh-pillar-switcher__trigger {
    border-color: rgba(243,103,7,0.45);
    box-shadow: 0 0 0 1px rgba(243,103,7,0.12) inset;
}
.gh-pillar-switcher[data-pillar="ai"] .gh-pillar-switcher__trigger {
    border-color: rgba(167,139,250,0.45);
    box-shadow: 0 0 0 1px rgba(167,139,250,0.12) inset;
}
.gh-pillar-switcher[data-pillar="ai"] .gh-pillar-switcher__trigger:hover { box-shadow: 0 6px 18px rgba(167,139,250,0.3); }
.gh-pillar-switcher[data-pillar="in"] .gh-pillar-switcher__trigger {
    border-color: rgba(116,154,23,0.45);
    box-shadow: 0 0 0 1px rgba(116,154,23,0.12) inset;
}
.gh-pillar-switcher[data-pillar="in"] .gh-pillar-switcher__trigger:hover { box-shadow: 0 6px 18px rgba(116,154,23,0.3); }

.gh-pillar-switcher__current-img {
    width: 36px; height: 36px;
    object-fit: contain;
    background: #FFFFFF;
    border-radius: 8px;
    padding: 3px;
    transition: transform 280ms var(--gh-ease-spring);
}

.gh-pillar-switcher__trigger:hover .gh-pillar-switcher__current-img {
    transform: scale(1.08);
}

.gh-pillar-switcher__current-fallback {
    opacity: 0.55;
    transition: opacity 200ms var(--gh-ease-out);
}
.gh-pillar-switcher__trigger:hover .gh-pillar-switcher__current-fallback {
    opacity: 0.85;
}

/* Dropdown menu pilares */
.gh-pillar-switcher__menu {
    position: absolute;
    top: calc(100% + 10px);
    left: 0;
    min-width: 320px;
    background: rgba(18,18,22,0.92);
    backdrop-filter: blur(40px) saturate(1.6);
    -webkit-backdrop-filter: blur(40px) saturate(1.6);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 18px;
    box-shadow:
        0 1px 0 rgba(255,255,255,0.06) inset,
        0 24px 48px -12px rgba(0,0,0,0.65),
        0 0 0 1px rgba(243,103,7,0.08);
    padding: 10px;
    z-index: var(--z-header-dropdown);
    color: #FFFFFF;
}

.gh-header--light .gh-pillar-switcher__menu {
    background: rgba(255,255,255,0.96);
    border-color: rgba(15,23,42,0.08);
    box-shadow: 0 24px 48px -12px rgba(15,23,42,0.18);
    color: #0F172A;
}

.gh-pillar-switcher__menu-header {
    font-family: var(--gh-font-display);
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: rgba(255,255,255,0.4);
    padding: 10px 14px 8px;
    margin-bottom: 4px;
}

.gh-header--light .gh-pillar-switcher__menu-header { color: rgba(15,23,42,0.45); }

.gh-pillar-switcher__item {
    display: flex; align-items: center; gap: 14px;
    padding: 12px 14px;
    border-radius: 12px;
    text-decoration: none;
    color: inherit;
    transition: background 160ms var(--gh-ease-out), transform 160ms var(--gh-ease-spring);
    position: relative;
    overflow: hidden;
}

.gh-pillar-switcher__item::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.04), transparent);
    transform: translateX(-100%);
    transition: transform 600ms var(--gh-ease-out);
    pointer-events: none;
}

.gh-pillar-switcher__item:hover {
    background: rgba(255,255,255,0.06);
    transform: translateX(2px);
    color: inherit;
}

.gh-pillar-switcher__item:hover::before { transform: translateX(100%); }

.gh-header--light .gh-pillar-switcher__item:hover { background: rgba(15,23,42,0.05); }

.gh-pillar-switcher__item--active { background: rgba(243,103,7,0.12); }
.gh-pillar-switcher__item[data-pillar="ai"].gh-pillar-switcher__item--active { background: rgba(167,139,250,0.14); }
.gh-pillar-switcher__item[data-pillar="in"].gh-pillar-switcher__item--active { background: rgba(163,230,53,0.12); }

.gh-pillar-switcher__item-icon {
    width: 44px; height: 44px;
    object-fit: contain;
    flex-shrink: 0;
    background: #FFFFFF;
    border-radius: 10px;
    padding: 5px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.35), 0 0 0 1px rgba(0,0,0,0.04);
    transition: transform 280ms var(--gh-ease-spring), box-shadow 220ms var(--gh-ease-out);
}

.gh-pillar-switcher__item:hover .gh-pillar-switcher__item-icon {
    transform: scale(1.08) rotate(-3deg);
    box-shadow: 0 6px 18px rgba(0,0,0,0.45);
}

.gh-pillar-switcher__item-text {
    flex: 1 1 auto; display: flex; flex-direction: column; gap: 2px; min-width: 0;
}

.gh-pillar-switcher__item-label {
    font-family: var(--gh-font-display);
    font-size: 14px; font-weight: 600; line-height: 1.2;
    letter-spacing: -0.01em;
}

.gh-pillar-switcher__item-tagline {
    font-size: 12px; opacity: 0.6; line-height: 1.2;
}

.gh-pillar-switcher__item-check { flex-shrink: 0; color: var(--gh-orange); }
.gh-pillar-switcher__item[data-pillar="ai"] .gh-pillar-switcher__item-check { color: var(--gh-purple); }
.gh-pillar-switcher__item[data-pillar="in"] .gh-pillar-switcher__item-check { color: #BEF264; }

/* Alpine helpers */
.gh-transition-enter { transition: opacity 180ms var(--gh-ease-out), transform 220ms var(--gh-ease-spring); }
.gh-transition-enter-start { opacity: 0; transform: translateY(-8px) scale(0.98); }
.gh-transition-enter-end { opacity: 1; transform: translateY(0) scale(1); }

/* ============================================================
 * GLOBE 3D — esfera CSS pura com bandeira
 * ============================================================ */
.gh-language-globe { position: relative; display: inline-block; }

.gh-language-globe__trigger {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 4px 14px 4px 6px;
    height: 42px;
    border-radius: 999px;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.1);
    color: inherit;
    cursor: pointer;
    font-family: var(--gh-font-display);
    font-size: 13px;
    font-weight: 600;
    transition: background 180ms var(--gh-ease-out), border-color 180ms var(--gh-ease-out), transform 200ms var(--gh-ease-spring);
}

.gh-header--light .gh-language-globe__trigger {
    background: rgba(15,23,42,0.03);
    border-color: rgba(15,23,42,0.1);
}

.gh-language-globe__trigger:hover {
    background: rgba(255,255,255,0.08);
    border-color: rgba(255,255,255,0.18);
    transform: translateY(-1px);
}
.gh-header--light .gh-language-globe__trigger:hover {
    background: rgba(15,23,42,0.06);
    border-color: rgba(15,23,42,0.16);
}

.gh-language-globe__label { line-height: 1; letter-spacing: 0.06em; opacity: 0.85; }

.gh-language-globe__caret {
    flex-shrink: 0; opacity: 0.55;
    transition: transform 220ms var(--gh-ease-out);
}
.gh-language-globe__caret--up { transform: rotate(180deg); }

/* === A esfera — bandeira ocupa 100% + glow da cor da bandeira === */
.gh-globe-3d {
    position: relative;
    display: inline-block;
    width: 32px; height: 32px;
    border-radius: 50%;
    overflow: visible;
    flex-shrink: 0;
    background: #FFFFFF;
    box-shadow:
        0 0 0 1px rgba(0,0,0,0.15),
        0 4px 12px rgba(0,0,0,0.35),
        0 0 14px var(--gh-globe-tint, #1E3A8A),
        0 0 28px color-mix(in srgb, var(--gh-globe-tint, #1E3A8A) 50%, transparent);
    transition: transform 600ms var(--gh-ease-spring), box-shadow 300ms var(--gh-ease-out);
    will-change: transform;
    animation: gh-globe-glow-pulse 3.6s ease-in-out infinite;
}

/* Mascara interna pra bandeira nao vazar fora do circulo (overflow:visible no parent) */
.gh-globe-3d::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 50%;
    overflow: hidden;
    pointer-events: none;
    z-index: 0;
}

.gh-header--light .gh-globe-3d {
    box-shadow:
        0 0 0 1px rgba(15,23,42,0.18),
        0 3px 10px rgba(15,23,42,0.18),
        0 0 12px var(--gh-globe-tint, #1E3A8A),
        0 0 24px color-mix(in srgb, var(--gh-globe-tint, #1E3A8A) 35%, transparent);
}

@keyframes gh-globe-glow-pulse {
    0%, 100% {
        box-shadow:
            0 0 0 1px rgba(0,0,0,0.15),
            0 4px 12px rgba(0,0,0,0.35),
            0 0 14px var(--gh-globe-tint, #1E3A8A),
            0 0 28px color-mix(in srgb, var(--gh-globe-tint, #1E3A8A) 50%, transparent);
    }
    50% {
        box-shadow:
            0 0 0 1px rgba(0,0,0,0.15),
            0 4px 12px rgba(0,0,0,0.35),
            0 0 18px var(--gh-globe-tint, #1E3A8A),
            0 0 38px color-mix(in srgb, var(--gh-globe-tint, #1E3A8A) 65%, transparent);
    }
}

/* Garantir que o flag-wrap e camadas internas mantenham o circulo (overflow visible no parent) */
.gh-globe-3d__flag-wrap,
.gh-globe-3d__meridians,
.gh-globe-3d__highlight,
.gh-globe-3d__shadow {
    border-radius: 50%;
}

.gh-globe-3d--small {
    width: 28px; height: 28px;
}

/* Cores da tinta (override por locale) */
.gh-globe-3d[data-locale="pt-br"], .gh-globe-3d[data-locale="br"] { --gh-globe-tint: #009C3B; }
.gh-globe-3d[data-locale="pt"]                                    { --gh-globe-tint: #046A38; }
.gh-globe-3d[data-locale="en"]                                    { --gh-globe-tint: #1E3A8A; }
.gh-globe-3d[data-locale="es"]                                    { --gh-globe-tint: #AA151B; }
.gh-globe-3d[data-locale="ar"]                                    { --gh-globe-tint: #006C35; }
.gh-globe-3d[data-locale="fr"]                                    { --gh-globe-tint: #0055A4; }
.gh-globe-3d[data-locale="it"]                                    { --gh-globe-tint: #008C45; }

/* Bandeira SVG ocupa 100% da esfera — fica como o "tecido" da bola */
.gh-globe-3d__flag-wrap {
    position: absolute;
    inset: 0;
    display: flex; align-items: center; justify-content: center;
    z-index: 1;
    border-radius: 50%;
    overflow: hidden;
    transition: transform 600ms var(--gh-ease-spring);
}

.gh-globe-3d__flag-wrap .gh-flag-svg {
    width: 100%; height: 100%;
    object-fit: cover;
    transform: scale(1.0);
}

/* Linhas meridianas — sutis, por cima da bandeira pra dar 3D */
.gh-globe-3d__meridians {
    position: absolute;
    inset: 0;
    z-index: 3;
    background:
        radial-gradient(ellipse 100% 50% at 50% 50%, transparent 47%, rgba(255,255,255,0.18) 49%, rgba(255,255,255,0.18) 51%, transparent 53%),
        radial-gradient(ellipse 50% 100% at 50% 50%, transparent 47%, rgba(255,255,255,0.12) 49%, rgba(255,255,255,0.12) 51%, transparent 53%);
    opacity: 0.5;
    pointer-events: none;
    mix-blend-mode: overlay;
}

/* Highlight specular topo-esquerdo (gloss) — branco translucido */
.gh-globe-3d__highlight {
    position: absolute;
    top: 6%; left: 14%;
    width: 38%; height: 32%;
    border-radius: 50%;
    background: radial-gradient(ellipse at 30% 30%, rgba(255,255,255,0.7) 0%, rgba(255,255,255,0.25) 35%, transparent 75%);
    filter: blur(1px);
    z-index: 4;
    pointer-events: none;
}

/* Sombra interna inferior (oclusão) — escurece o "polo sul" */
.gh-globe-3d__shadow {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    height: 55%;
    background: radial-gradient(ellipse at 50% 100%, rgba(0,0,0,0.35) 0%, rgba(0,0,0,0.15) 35%, transparent 70%);
    z-index: 5;
    pointer-events: none;
    border-radius: 0 0 50% 50%;
}

/* Hover: scale + glow MUITO mais forte */
.gh-language-globe__trigger:hover .gh-globe-3d {
    transform: scale(1.1);
    animation: none;
    box-shadow:
        0 0 0 1px rgba(0,0,0,0.2),
        0 6px 18px rgba(0,0,0,0.45),
        0 0 22px var(--gh-globe-tint, #1E3A8A),
        0 0 50px color-mix(in srgb, var(--gh-globe-tint, #1E3A8A) 75%, transparent);
}

.gh-language-globe__trigger:hover .gh-globe-3d__flag-wrap {
    transform: rotateZ(-4deg);
}

/* Reduced motion: desliga pulse */
@media (prefers-reduced-motion: reduce) {
    .gh-globe-3d { animation: none; }
}

/* Dropdown idiomas */
.gh-language-globe__menu {
    position: absolute;
    top: calc(100% + 10px);
    left: 50%;
    transform: translateX(-50%);
    min-width: 280px;
    background: rgba(18,18,22,0.92);
    backdrop-filter: blur(40px) saturate(1.6);
    -webkit-backdrop-filter: blur(40px) saturate(1.6);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 18px;
    box-shadow:
        0 1px 0 rgba(255,255,255,0.06) inset,
        0 24px 48px -12px rgba(0,0,0,0.65);
    padding: 10px;
    z-index: var(--z-header-dropdown);
    color: #FFFFFF;
}

.gh-header--light .gh-language-globe__menu {
    background: rgba(255,255,255,0.96);
    border-color: rgba(15,23,42,0.08);
    box-shadow: 0 24px 48px -12px rgba(15,23,42,0.18);
    color: #0F172A;
}

.gh-language-globe__menu-header {
    font-family: var(--gh-font-display);
    font-size: 10px; font-weight: 700;
    text-transform: uppercase; letter-spacing: 0.12em;
    color: rgba(255,255,255,0.4);
    padding: 10px 14px 8px;
    margin-bottom: 4px;
}
.gh-header--light .gh-language-globe__menu-header { color: rgba(15,23,42,0.45); }

.gh-language-globe__form { margin: 0; padding: 0; }

.gh-language-globe__item {
    display: flex; align-items: center; gap: 14px;
    padding: 10px 12px;
    border-radius: 12px;
    background: transparent;
    border: none;
    color: inherit;
    cursor: pointer;
    width: 100%;
    text-align: left;
    transition: background 160ms var(--gh-ease-out), transform 160ms var(--gh-ease-spring);
    font-family: inherit; font-size: inherit;
}

.gh-language-globe__item:hover:not(:disabled) {
    background: rgba(255,255,255,0.05);
    transform: translateX(2px);
}
.gh-header--light .gh-language-globe__item:hover:not(:disabled) {
    background: rgba(15,23,42,0.05);
}

.gh-language-globe__item--active {
    background: rgba(243,103,7,0.10);
    cursor: default;
}
.gh-language-globe__item--active:disabled { opacity: 1; color: inherit; }

.gh-language-globe__item-text {
    flex: 1 1 auto; display: flex; flex-direction: column; gap: 2px; min-width: 0;
}

.gh-language-globe__item-label {
    font-family: var(--gh-font-display);
    font-size: 14px; font-weight: 600; line-height: 1.2;
    letter-spacing: -0.01em;
}

.gh-language-globe__item-code {
    font-size: 11px; opacity: 0.5; line-height: 1.2;
    letter-spacing: 0.08em;
    font-family: var(--gh-font-mono);
}

.gh-language-globe__item-check { flex-shrink: 0; color: var(--gh-orange); }

/* ============================================================
 * USER CHIP
 * ============================================================ */
.gh-user-chip,
.gh-user-chip--placeholder {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 4px 14px 4px 4px;
    height: 42px;
    border-radius: 999px;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.1);
    color: inherit;
    cursor: pointer;
    transition: background 180ms var(--gh-ease-out), border-color 180ms var(--gh-ease-out), transform 200ms var(--gh-ease-spring);
    font-family: var(--gh-font-display);
}
.gh-header--light .gh-user-chip,
.gh-header--light .gh-user-chip--placeholder {
    background: rgba(15,23,42,0.03);
    border-color: rgba(15,23,42,0.1);
}

.gh-user-chip:hover {
    background: rgba(255,255,255,0.07);
    border-color: rgba(243,103,7,0.4);
    transform: translateY(-1px);
}
.gh-header--light .gh-user-chip:hover {
    background: rgba(243,103,7,0.06);
}

.gh-user-chip:hover .gh-user-chip__avatar,
.gh-user-chip:hover .gh-user-chip__avatar--initial {
    transform: scale(1.08);
}

.gh-user-chip__avatar,
.gh-user-chip__avatar--initial {
    transition: transform 220ms var(--gh-ease-spring);
}

.gh-user-chip--open {
    border-color: var(--gh-orange);
    background: linear-gradient(135deg, rgba(243,103,7,0.14) 0%, rgba(243,103,7,0.06) 100%);
    box-shadow: 0 0 0 4px rgba(243,103,7,0.18), 0 6px 18px rgba(243,103,7,0.25);
}

.gh-user-chip__avatar-wrap {
    position: relative; display: inline-block;
    width: 34px; height: 34px; flex-shrink: 0;
}

.gh-user-chip__avatar {
    width: 34px; height: 34px;
    border-radius: 50%; object-fit: cover;
    background: #1F1F1F;
    display: block;
    border: 2px solid rgba(255,255,255,0.1);
}

.gh-user-chip__avatar--initial {
    display: inline-flex; align-items: center; justify-content: center;
    background: linear-gradient(135deg, var(--gh-orange) 0%, var(--gh-orange-soft) 100%);
    color: #FFFFFF;
    font-weight: 700; font-size: 14px;
    font-family: var(--gh-font-display);
    border: 2px solid rgba(255,255,255,0.15);
}

.gh-user-chip__ai-badge {
    position: absolute;
    bottom: -3px; right: -3px;
    width: 18px; height: 18px;
    border-radius: 50%;
    background: #0A0A0C;
    border: 2px solid var(--gh-orange);
    overflow: hidden;
    line-height: 0;
    box-shadow: 0 2px 6px rgba(243,103,7,0.5);
}
.gh-user-chip__ai-badge img { width: 100%; height: 100%; object-fit: cover; display: block; }

.gh-user-chip__name {
    font-size: 14px; font-weight: 600;
    white-space: nowrap; line-height: 1;
    letter-spacing: -0.01em;
}

.gh-user-chip__caret {
    flex-shrink: 0; opacity: 0.6;
    transition: transform 220ms var(--gh-ease-out);
}
.gh-user-chip__caret--up { transform: rotate(180deg); }

/* Counter badge (carrinho + notif) */
.gh-user-chip__count-badge {
    position: absolute;
    top: -5px; left: -5px;
    min-width: 20px; height: 20px;
    padding: 0 6px;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--gh-orange) 0%, var(--gh-orange-soft) 100%);
    color: #FFFFFF;
    font-size: 10px; font-weight: 800;
    line-height: 20px; text-align: center;
    box-shadow: 0 3px 8px rgba(243,103,7,0.55), 0 0 0 2px rgba(10,10,12,0.95);
    font-family: var(--gh-font-display);
    pointer-events: none;
    animation: gh-pulse-badge 2.4s ease-in-out infinite;
}
.gh-header--light .gh-user-chip__count-badge {
    box-shadow: 0 3px 8px rgba(243,103,7,0.55), 0 0 0 2px rgba(255,255,255,0.95);
}

@keyframes gh-pulse-badge {
    0%, 100% { box-shadow: 0 3px 8px rgba(243,103,7,0.55), 0 0 0 2px rgba(10,10,12,0.95), 0 0 0 0 rgba(243,103,7,0.5); }
    50%      { box-shadow: 0 3px 8px rgba(243,103,7,0.55), 0 0 0 2px rgba(10,10,12,0.95), 0 0 0 6px rgba(243,103,7,0); }
}

/* ===== AUTH BUTTONS ===== */
.gh-auth-buttons { display: inline-flex; align-items: center; gap: 10px; }

.gh-auth-buttons__login,
.gh-auth-buttons__register {
    display: inline-flex; align-items: center;
    height: 42px; padding: 0 20px;
    border-radius: 999px;
    font-family: var(--gh-font-display);
    font-size: 14px; font-weight: 600;
    text-decoration: none; cursor: pointer;
    transition: background 180ms var(--gh-ease-out), transform 200ms var(--gh-ease-spring), box-shadow 220ms var(--gh-ease-out);
    line-height: 1; letter-spacing: -0.01em;
}

.gh-auth-buttons__login {
    color: inherit;
    background: transparent;
    border: 1px solid rgba(255,255,255,0.18);
}
.gh-header--light .gh-auth-buttons__login { border-color: rgba(15,23,42,0.14); }

.gh-auth-buttons__login:hover {
    background: rgba(255,255,255,0.06);
    transform: translateY(-1px);
}
.gh-header--light .gh-auth-buttons__login:hover { background: rgba(15,23,42,0.04); }

.gh-auth-buttons__register {
    color: #FFFFFF;
    background: linear-gradient(135deg, var(--gh-orange) 0%, var(--gh-orange-soft) 100%);
    box-shadow: 0 6px 18px rgba(243,103,7,0.32), 0 1px 0 rgba(255,255,255,0.18) inset;
    border: 1px solid transparent;
    position: relative;
    overflow: hidden;
}

.gh-auth-buttons__register::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(110deg, transparent 30%, rgba(255,255,255,0.3) 50%, transparent 70%);
    transform: translateX(-110%);
    transition: transform 800ms var(--gh-ease-out);
}
.gh-auth-buttons__register:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 24px rgba(243,103,7,0.45), 0 1px 0 rgba(255,255,255,0.25) inset;
    color: #FFFFFF;
}
.gh-auth-buttons__register:hover::before { transform: translateX(110%); }

/* ============================================================
 * MEGA DROPDOWN — premium glass
 * ============================================================ */
.gh-mega-dropdown {
    position: fixed; inset: 0;
    z-index: var(--z-header-overlay);
    pointer-events: none;
}

/* Trava scroll da pagina por tras quando dropdown aberto (todos breakpoints) */
body:has(.gh-mega-dropdown),
html:has(.gh-mega-dropdown) {
    overflow: hidden !important;
    /* iOS safe — evita scroll fantasma */
    position: relative;
    height: 100vh;
}

.gh-mega-dropdown__overlay {
    /* Comeca abaixo do header (top: header height) — header continua visivel/clicavel */
    position: absolute;
    top: var(--gh-header-height);
    left: 0; right: 0; bottom: 0;
    background: radial-gradient(ellipse at top, rgba(0,0,0,0.45) 0%, rgba(0,0,0,0.7) 100%);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    pointer-events: auto;
}

.gh-header--scrolled ~ .gh-mega-dropdown .gh-mega-dropdown__overlay {
    top: var(--gh-header-height-scrolled);
}

.gh-mega-dropdown__inner {
    position: absolute;
    top: var(--gh-header-height);
    left: 16px; right: 16px;
    z-index: var(--z-header-dropdown);
    pointer-events: auto;
    max-width: var(--gh-max-width);
    margin: 0 auto;
    padding: 28px;
    /* Background TOTALMENTE opaco — no flicker com fundo claro/escuro */
    background-color: #0F0F12;
    background-image: linear-gradient(180deg, rgba(255,255,255,0.02) 0%, rgba(0,0,0,0.05) 100%);
    backdrop-filter: blur(40px) saturate(1.6);
    -webkit-backdrop-filter: blur(40px) saturate(1.6);
    border: 1px solid rgba(255,255,255,0.08);
    border-top: none;
    border-radius: 0 0 22px 22px;
    box-shadow:
        0 1px 0 rgba(255,255,255,0.04) inset,
        0 30px 60px -20px rgba(0,0,0,0.7),
        0 0 0 1px rgba(243,103,7,0.06);
    color: #FFFFFF;
}

.gh-header--light .gh-mega-dropdown__inner {
    background-color: #FFFFFF;
    background-image: linear-gradient(180deg, rgba(15,23,42,0.01) 0%, rgba(15,23,42,0.03) 100%);
    border-color: rgba(15,23,42,0.1);
    color: #0F172A;
    box-shadow:
        0 1px 0 rgba(0,0,0,0.02) inset,
        0 30px 60px -20px rgba(15,23,42,0.18),
        0 0 0 1px rgba(243,103,7,0.06);
}

.gh-mega-dropdown__row {
    display: grid;
    gap: 16px;
}

.gh-mega-dropdown__row--top {
    grid-template-columns: minmax(280px, 1.2fr) repeat(3, minmax(180px, 1fr));
    margin-bottom: 16px;
}

.gh-mega-dropdown__row--bottom {
    grid-template-columns: 1fr 1.4fr 1fr;
}

/* Cards base — glass */
.gh-mega-dropdown__col {
    background: linear-gradient(180deg, rgba(255,255,255,0.04) 0%, rgba(255,255,255,0.02) 100%);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 16px;
    padding: 18px;
    min-width: 0;
    transition: border-color 220ms var(--gh-ease-out), transform 220ms var(--gh-ease-spring), background 220ms var(--gh-ease-out);
    position: relative;
    overflow: hidden;
}

.gh-mega-dropdown__col::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    padding: 1px;
    background: linear-gradient(135deg, rgba(255,255,255,0.08), transparent 40%, transparent 60%, rgba(255,255,255,0.04));
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    pointer-events: none;
}

.gh-mega-dropdown__col:hover {
    border-color: rgba(255,255,255,0.12);
    background: linear-gradient(180deg, rgba(255,255,255,0.06) 0%, rgba(255,255,255,0.03) 100%);
    transform: translateY(-2px);
}

.gh-header--light .gh-mega-dropdown__col {
    background: linear-gradient(180deg, rgba(15,23,42,0.025) 0%, rgba(15,23,42,0.015) 100%);
    border-color: rgba(15,23,42,0.06);
}

.gh-mega-dropdown__col--avatar {
    background: linear-gradient(135deg, rgba(243,103,7,0.10) 0%, rgba(116,154,23,0.05) 100%);
    border-color: rgba(243,103,7,0.22);
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.05), 0 8px 24px -8px rgba(243,103,7,0.18);
}

.gh-mega-dropdown__col--avatar:hover {
    border-color: rgba(243,103,7,0.4);
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.08), 0 12px 32px -8px rgba(243,103,7,0.3);
}

/* Footer dropdown */
.gh-mega-dropdown__footer {
    display: flex; justify-content: flex-end; align-items: center;
    gap: 10px;
    margin-top: 18px;
    padding-top: 18px;
    border-top: 1px solid rgba(255,255,255,0.06);
}
.gh-header--light .gh-mega-dropdown__footer { border-top-color: rgba(15,23,42,0.06); }

.gh-mega-dropdown__logout-form { margin: 0; padding: 0; }

.gh-mega-dropdown__action {
    display: inline-flex; align-items: center; gap: 8px;
    height: 38px; padding: 0 16px;
    border-radius: 10px;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.08);
    color: inherit;
    text-decoration: none;
    font-family: var(--gh-font-display);
    font-size: 13px; font-weight: 600;
    cursor: pointer;
    transition: background 160ms var(--gh-ease-out), border-color 160ms var(--gh-ease-out), transform 200ms var(--gh-ease-spring);
}
.gh-header--light .gh-mega-dropdown__action {
    background: rgba(15,23,42,0.04);
    border-color: rgba(15,23,42,0.08);
}

.gh-mega-dropdown__action:hover {
    background: rgba(255,255,255,0.08);
    border-color: rgba(255,255,255,0.16);
    color: inherit;
    transform: translateY(-1px);
}
.gh-header--light .gh-mega-dropdown__action:hover {
    background: rgba(15,23,42,0.07);
}

.gh-mega-dropdown__action--danger:hover {
    background: rgba(239,68,68,0.14);
    border-color: rgba(239,68,68,0.45);
    color: #FCA5A5;
}
.gh-header--light .gh-mega-dropdown__action--danger:hover { color: #DC2626; }

/* ===== PILLAR COLUMN (no dropdown) ===== */
.gh-pillar-col__header {
    display: flex; align-items: center; gap: 12px;
    margin-bottom: 14px; padding-bottom: 12px;
    border-bottom: 1px solid rgba(255,255,255,0.06);
}
.gh-header--light .gh-pillar-col__header { border-bottom-color: rgba(15,23,42,0.06); }

.gh-pillar-col__icon {
    width: 44px; height: 44px;
    object-fit: contain; flex-shrink: 0;
    /* Frame branco arredondado — destaca logos coloridos em qualquer fundo */
    background: #FFFFFF;
    border-radius: 10px;
    padding: 5px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.35), 0 0 0 1px rgba(0,0,0,0.04);
    transition: transform 280ms var(--gh-ease-spring), box-shadow 220ms var(--gh-ease-out);
}
.gh-mega-dropdown__col:hover .gh-pillar-col__icon {
    transform: scale(1.08) rotate(-3deg);
    box-shadow: 0 6px 18px rgba(0,0,0,0.45), 0 0 0 1px rgba(255,255,255,0.1);
}

.gh-pillar-col__heading { min-width: 0; flex: 1; }

.gh-pillar-col__label {
    font-family: var(--gh-font-display);
    font-size: 14px; font-weight: 700; line-height: 1.2;
    letter-spacing: -0.01em;
    margin-bottom: 3px;
}

.gh-pillar-col__tagline {
    font-size: 11px; opacity: 0.55; line-height: 1.2;
}

.gh-pillar-col__links {
    list-style: none; margin: 0; padding: 0;
    display: flex; flex-direction: column; gap: 1px;
}

.gh-pillar-col__link {
    display: flex; align-items: center; gap: 10px;
    padding: 8px 10px;
    border-radius: 8px;
    color: inherit;
    text-decoration: none;
    font-size: 13px; font-weight: 500;
    transition: background 140ms var(--gh-ease-out), color 140ms var(--gh-ease-out), padding 200ms var(--gh-ease-spring);
    opacity: 0.85;
}

.gh-pillar-col__link svg {
    flex-shrink: 0; opacity: 0.4;
    transition: transform 200ms var(--gh-ease-spring), opacity 140ms var(--gh-ease-out);
}

.gh-pillar-col__link:hover {
    background: rgba(255,255,255,0.05);
    color: inherit; opacity: 1;
    padding-left: 14px;
}
.gh-pillar-col__link:hover svg {
    transform: translateX(3px);
    opacity: 1; color: var(--gh-orange);
}
.gh-header--light .gh-pillar-col__link:hover { background: rgba(15,23,42,0.04); }

.gh-mega-dropdown__col--pillar[data-pillar="ai"] .gh-pillar-col__icon { filter: drop-shadow(0 4px 12px rgba(167,139,250,0.5)); }
.gh-mega-dropdown__col--pillar[data-pillar="in"] .gh-pillar-col__icon { filter: drop-shadow(0 4px 12px rgba(163,230,53,0.5)); }
.gh-mega-dropdown__col--pillar[data-pillar="x"]  .gh-pillar-col__icon { filter: drop-shadow(0 4px 12px rgba(243,103,7,0.5)); }

.gh-mega-dropdown__col--pillar[data-pillar="ai"] .gh-pillar-col__link:hover svg { color: var(--gh-purple); }
.gh-mega-dropdown__col--pillar[data-pillar="in"] .gh-pillar-col__link:hover svg { color: #BEF264; }

/* ===== CARDS (afiliados, notif, cart) ===== */
.gh-card { display: flex; flex-direction: column; }

.gh-card__header {
    display: flex; align-items: center; gap: 10px;
    margin-bottom: 14px;
}

.gh-card__icon {
    color: var(--gh-orange); flex-shrink: 0;
    filter: drop-shadow(0 0 8px rgba(243,103,7,0.4));
}

.gh-card__title {
    flex: 1; margin: 0;
    font-family: var(--gh-font-display);
    font-size: 11px; font-weight: 700;
    text-transform: uppercase; letter-spacing: 0.12em;
    line-height: 1; opacity: 0.75;
}

.gh-card__see-all {
    font-family: var(--gh-font-display);
    font-size: 10px; color: var(--gh-orange-soft);
    text-decoration: none; font-weight: 700;
    text-transform: uppercase; letter-spacing: 0.1em;
    transition: color 160ms var(--gh-ease-out), transform 160ms var(--gh-ease-spring);
}
.gh-card__see-all:hover { color: #FBBF24; transform: translateX(2px); }

.gh-card__count-pill {
    display: inline-flex; align-items: center; justify-content: center;
    min-width: 22px; height: 22px;
    padding: 0 8px;
    border-radius: 999px;
    background: rgba(243,103,7,0.18);
    color: #FBBF24;
    font-size: 11px; font-weight: 700;
    font-family: var(--gh-font-display);
}

.gh-card__body { flex: 1; min-height: 60px; }

.gh-card__big-number {
    font-family: var(--gh-font-display);
    font-size: 30px; font-weight: 700;
    line-height: 1; margin-bottom: 4px;
    background: linear-gradient(135deg, var(--gh-orange) 0%, var(--gh-orange-soft) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    letter-spacing: -0.02em;
    font-variant-numeric: tabular-nums;
}

.gh-card__big-label {
    font-size: 12px; opacity: 0.55; margin-bottom: 14px;
    text-transform: uppercase; letter-spacing: 0.06em;
    font-weight: 600;
}

.gh-card__empty {
    display: flex; flex-direction: column;
    align-items: center; justify-content: center; gap: 10px;
    padding: 18px 8px;
    opacity: 0.35; font-size: 12px;
    text-align: center;
}

.gh-card__actions {
    display: flex; flex-direction: column; gap: 8px;
    margin-top: 14px;
}

.gh-card__btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 6px;
    height: 38px; padding: 0 14px;
    border-radius: 10px;
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.1);
    color: inherit;
    font-family: var(--gh-font-display);
    font-size: 13px; font-weight: 600;
    text-decoration: none; cursor: pointer;
    transition: background 160ms var(--gh-ease-out), border-color 160ms var(--gh-ease-out), transform 200ms var(--gh-ease-spring);
    width: 100%;
    letter-spacing: -0.01em;
}
.gh-header--light .gh-card__btn {
    background: rgba(15,23,42,0.04);
    border-color: rgba(15,23,42,0.08);
}

.gh-card__btn:hover {
    background: rgba(255,255,255,0.10);
    border-color: rgba(255,255,255,0.18);
    color: inherit;
    transform: translateY(-1px);
}
.gh-header--light .gh-card__btn:hover { background: rgba(15,23,42,0.07); }

.gh-card__btn--ghost { background: transparent; }

.gh-card__btn--primary,
.gh-card__btn--primary:link,
.gh-card__btn--primary:visited {
    background-color: #F36707 !important;
    background-image: linear-gradient(135deg, #F36707 0%, #FF8A3D 50%, #F36707 100%) !important;
    border-color: transparent !important;
    color: #FFFFFF !important;
    box-shadow: 0 6px 20px rgba(243,103,7,0.5), 0 1px 0 rgba(255,255,255,0.3) inset, 0 0 0 1px rgba(243,103,7,0.4);
    height: 46px;
    font-size: 15px; font-weight: 700;
    text-shadow: 0 1px 2px rgba(0,0,0,0.25);
    letter-spacing: 0.01em;
    position: relative; overflow: hidden;
}

.gh-card__btn--primary svg { color: #FFFFFF !important; stroke: #FFFFFF !important; }

.gh-card__btn--primary::before {
    content: '';
    position: absolute; inset: 0;
    background: linear-gradient(110deg, transparent 30%, rgba(255,255,255,0.35) 50%, transparent 70%);
    transform: translateX(-110%);
    transition: transform 800ms var(--gh-ease-out);
}

.gh-card__btn--primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 24px rgba(243,103,7,0.5), 0 1px 0 rgba(255,255,255,0.25) inset;
    color: #FFFFFF;
}
.gh-card__btn--primary:hover::before { transform: translateX(110%); }

/* ===== NOTIFICATIONS LIST ===== */
.gh-notif-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }

.gh-notif-item {
    display: flex; align-items: flex-start; gap: 12px;
    padding: 12px 10px;
    border-radius: 10px;
    background: rgba(255,255,255,0.025);
    transition: background 140ms var(--gh-ease-out), transform 160ms var(--gh-ease-spring);
}

.gh-notif-item:hover {
    background: rgba(255,255,255,0.06);
    transform: translateX(2px);
}
.gh-header--light .gh-notif-item { background: rgba(15,23,42,0.025); }
.gh-header--light .gh-notif-item:hover { background: rgba(15,23,42,0.05); }

.gh-notif-item__dot {
    width: 8px; height: 8px;
    border-radius: 50%;
    background: var(--gh-orange);
    flex-shrink: 0;
    margin-top: 6px;
    box-shadow: 0 0 8px rgba(243,103,7,0.7);
    animation: gh-pulse-dot 2s ease-in-out infinite;
}

@keyframes gh-pulse-dot {
    0%, 100% { box-shadow: 0 0 8px rgba(243,103,7,0.7), 0 0 0 0 rgba(243,103,7,0.4); }
    50%      { box-shadow: 0 0 8px rgba(243,103,7,0.7), 0 0 0 4px rgba(243,103,7,0); }
}

.gh-notif-item__body { flex: 1; min-width: 0; }

.gh-notif-item__title {
    font-family: var(--gh-font-display);
    font-size: 13px; font-weight: 600;
    line-height: 1.3; margin-bottom: 3px;
    letter-spacing: -0.01em;
}

.gh-notif-item__msg {
    font-size: 12px; opacity: 0.65;
    line-height: 1.4; margin-bottom: 5px;
}

.gh-notif-item__when {
    font-size: 10px; opacity: 0.4;
    font-family: var(--gh-font-mono);
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

/* ===== CART LIST ===== */
.gh-cart-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 5px; }

.gh-cart-item {
    display: flex; justify-content: space-between; align-items: center;
    gap: 12px;
    padding: 9px 11px;
    border-radius: 8px;
    background: rgba(255,255,255,0.025);
    font-size: 12px;
    transition: background 140ms var(--gh-ease-out);
}
.gh-cart-item:hover { background: rgba(255,255,255,0.06); }
.gh-header--light .gh-cart-item { background: rgba(15,23,42,0.025); }

.gh-cart-item__title {
    flex: 1; min-width: 0;
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
    opacity: 0.85;
    font-weight: 500;
}

.gh-cart-item__price {
    font-family: var(--gh-font-display);
    font-weight: 700;
    color: var(--gh-orange-soft);
    flex-shrink: 0;
    font-variant-numeric: tabular-nums;
}

.gh-cart-total {
    display: flex; justify-content: space-between; align-items: baseline;
    gap: 8px;
    margin-top: 14px; padding-top: 14px;
    border-top: 1px solid rgba(255,255,255,0.08);
}
.gh-header--light .gh-cart-total { border-top-color: rgba(15,23,42,0.08); }

.gh-cart-total__label {
    font-size: 11px; opacity: 0.55;
    text-transform: uppercase; letter-spacing: 0.1em;
    font-weight: 700;
    font-family: var(--gh-font-display);
}

.gh-cart-total__value {
    font-family: var(--gh-font-display);
    font-size: 22px; font-weight: 700;
    background: linear-gradient(135deg, var(--gh-orange) 0%, var(--gh-orange-soft) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    letter-spacing: -0.02em;
    font-variant-numeric: tabular-nums;
}

/* ============================================================
 * USER AVATAR CARD (variants: header / expanded / profile-hero)
 * ============================================================ */
.gh-avatar-card {
    display: flex; flex-direction: column;
    align-items: center; gap: 14px;
    padding: 8px;
    text-align: center;
}

.gh-avatar-card--profile-hero {
    flex-direction: row; align-items: flex-start; text-align: left;
    gap: 24px; padding: 0;
}

.gh-avatar-card__pic-wrap {
    position: relative;
    width: var(--gh-avatar-size, 96px);
    height: var(--gh-avatar-size, 96px);
    flex-shrink: 0;
    border-radius: 50%;
    /* Anel cônico animado (gamer feel) */
    background: conic-gradient(from 180deg, var(--gh-orange), var(--gh-orange-soft), #FBBF24, var(--gh-green), var(--gh-orange));
    padding: 3px;
    box-shadow: 0 0 0 1px rgba(255,255,255,0.06), 0 12px 32px -10px rgba(243,103,7,0.5);
    animation: gh-ring-spin 14s linear infinite;
}

@keyframes gh-ring-spin {
    to { transform: rotate(360deg); }
}

.gh-avatar-card__pic-wrap > * { animation: gh-ring-spin 14s linear infinite reverse; }

.gh-avatar-card__pic {
    width: 100%; height: 100%;
    border-radius: 50%; object-fit: cover;
    background: #0A0A0C;
    display: block;
    border: 2px solid #0A0A0C;
}
.gh-header--light .gh-avatar-card__pic { border-color: #FFFFFF; }

.gh-avatar-card__pic--initial {
    display: inline-flex; align-items: center; justify-content: center;
    background: linear-gradient(135deg, var(--gh-orange) 0%, var(--gh-orange-soft) 100%);
    color: #FFFFFF; font-weight: 800;
    font-family: var(--gh-font-display);
    font-size: calc(var(--gh-avatar-size, 96px) * 0.4);
    border: 2px solid #0A0A0C;
}

.gh-avatar-card__badge {
    position: absolute; top: 6px; right: 6px;
    width: 24px; height: 24px;
    border-radius: 50%;
    display: inline-flex; align-items: center; justify-content: center;
    border: 2px solid #0A0A0C;
    color: #FFFFFF;
    box-shadow: 0 2px 6px rgba(0,0,0,0.4);
    z-index: 3;
    animation: none;
}
.gh-header--light .gh-avatar-card__badge { border-color: #FFFFFF; }

.gh-avatar-card__badge--verified { background: linear-gradient(135deg, var(--gh-green) 0%, #5d7b12 100%); }
.gh-avatar-card__badge--unavailable { background: linear-gradient(135deg, #6B7280 0%, #4B5563 100%); }

.gh-avatar-card__ai-badge {
    position: absolute;
    bottom: -4px; right: -4px;
    width: var(--gh-ai-badge-size, 38px);
    height: var(--gh-ai-badge-size, 38px);
    border-radius: 50%;
    background: #0A0A0C;
    border: 3px solid var(--gh-orange);
    overflow: visible;
    display: inline-flex; align-items: center; justify-content: center;
    line-height: 0;
    box-shadow: 0 4px 14px rgba(243,103,7,0.5);
    transition: transform 280ms var(--gh-ease-spring);
    z-index: 4;
    animation: none;
}

.gh-avatar-card__ai-badge img {
    width: 100%; height: 100%; object-fit: cover; border-radius: 50%; display: block;
}

.gh-avatar-card:hover .gh-avatar-card__ai-badge {
    transform: scale(1.1) rotate(-6deg);
}

.gh-avatar-card__ai-level {
    position: absolute;
    bottom: -8px; left: 50%;
    transform: translateX(-50%);
    background-color: #F36707 !important;
    background-image: linear-gradient(135deg, #F36707 0%, #FF8A3D 100%) !important;
    color: #FFFFFF !important;
    font-family: var(--gh-font-display);
    font-size: 11px; font-weight: 800;
    padding: 3px 9px;
    border-radius: 8px;
    line-height: 1;
    border: 2px solid #FFFFFF;
    box-shadow: 0 4px 10px rgba(243,103,7,0.6), 0 0 0 1px rgba(0,0,0,0.1);
    z-index: 5;
    text-shadow: 0 1px 2px rgba(0,0,0,0.3);
    letter-spacing: 0.02em;
}

.gh-avatar-card__stat--accent {
    background-color: #F36707 !important;
    background-image: linear-gradient(135deg, #F36707 0%, #FF8A3D 100%) !important;
    color: #FFFFFF !important;
    border-color: transparent !important;
}
.gh-avatar-card__stat--accent strong,
.gh-avatar-card__stat--accent span { color: #FFFFFF !important; }

.gh-avatar-card__info { min-width: 0; width: 100%; }
.gh-avatar-card--profile-hero .gh-avatar-card__info { flex: 1; text-align: left; }

.gh-avatar-card__name-link {
    text-decoration: none; color: inherit;
    transition: color 160ms var(--gh-ease-out);
}
.gh-avatar-card__name-link:hover { color: var(--gh-orange-soft); }

.gh-avatar-card__name {
    font-family: var(--gh-font-display);
    font-size: 17px; font-weight: 700;
    line-height: 1.15; margin: 0 0 4px;
    letter-spacing: -0.02em;
}
.gh-avatar-card--expanded .gh-avatar-card__name { font-size: 19px; }
.gh-avatar-card--profile-hero .gh-avatar-card__name { font-size: 30px; }

.gh-avatar-card__headline {
    font-size: 12px; opacity: 0.6;
    line-height: 1.35; margin: 0 0 12px;
    font-style: italic;
}
.gh-avatar-card--profile-hero .gh-avatar-card__headline { font-size: 14px; }

.gh-avatar-card__stats {
    display: flex; flex-wrap: wrap; justify-content: center; gap: 6px;
}
.gh-avatar-card--profile-hero .gh-avatar-card__stats { justify-content: flex-start; }

.gh-avatar-card__stat {
    display: inline-flex; align-items: center; gap: 5px;
    font-size: 11px; opacity: 0.85;
    padding: 5px 10px;
    border-radius: 999px;
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.08);
    line-height: 1;
    font-family: var(--gh-font-display);
    font-weight: 500;
}
.gh-header--light .gh-avatar-card__stat {
    background: rgba(15,23,42,0.05);
    border-color: rgba(15,23,42,0.08);
}

.gh-avatar-card__stat strong {
    font-weight: 700; opacity: 1; font-size: 12px;
    font-variant-numeric: tabular-nums;
}
.gh-avatar-card__stat-suffix { opacity: 0.6; font-size: 10px; }

.gh-avatar-card__stat-icon { flex-shrink: 0; opacity: 0.7; }
.gh-avatar-card__stat-icon--gold { color: #FBBF24; opacity: 1; filter: drop-shadow(0 0 4px rgba(251,191,36,0.6)); }

.gh-avatar-card__stat--accent {
    background: linear-gradient(135deg, var(--gh-orange) 0%, var(--gh-orange-soft) 100%);
    border-color: transparent;
    color: #FFFFFF;
    opacity: 1;
    box-shadow: 0 3px 10px rgba(243,103,7,0.4), 0 0 0 1px rgba(255,255,255,0.15) inset;
    text-shadow: 0 1px 1px rgba(0,0,0,0.2);
}
.gh-avatar-card__stat--accent strong { color: #FFFFFF; font-weight: 800; }

/* XP bar */
.gh-avatar-card__xp { margin-top: 14px; width: 100%; }

.gh-avatar-card__xp-bar {
    height: 7px;
    border-radius: 4px;
    background: rgba(255,255,255,0.08);
    overflow: hidden;
    margin-bottom: 5px;
    position: relative;
}
.gh-header--light .gh-avatar-card__xp-bar { background: rgba(15,23,42,0.08); }

.gh-avatar-card__xp-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--gh-orange) 0%, var(--gh-orange-soft) 50%, #FBBF24 100%);
    border-radius: 4px;
    transition: width 800ms var(--gh-ease-spring);
    box-shadow: 0 0 12px rgba(243,103,7,0.6);
    position: relative;
}

.gh-avatar-card__xp-fill::after {
    content: '';
    position: absolute; inset: 0;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.4), transparent);
    animation: gh-xp-shimmer 2.5s ease-in-out infinite;
}

@keyframes gh-xp-shimmer {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

.gh-avatar-card__xp-text {
    display: flex; justify-content: space-between;
    font-size: 10px; opacity: 0.55;
    font-family: var(--gh-font-mono);
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.gh-avatar-card__actions { display: flex; gap: 8px; margin-top: 16px; }

/* NB0.36 — Usage info (daily/monthly/credits) abaixo da barra XP */
.gh-avatar-card__usage { margin-top: 12px; width: 100%; display: flex; flex-direction: column; gap: 6px; }
.gh-avatar-card__usage-row { display: flex; align-items: center; gap: 8px; font-size: 11px; opacity: 0.85; }
.gh-avatar-card__usage-icon { font-size: 12px; line-height: 1; flex-shrink: 0; width: 14px; text-align: center; }
.gh-avatar-card__usage-label { font-size: 10px; text-transform: uppercase; letter-spacing: 0.04em; opacity: 0.6; min-width: 48px; flex-shrink: 0; }
.gh-avatar-card__usage-bar { flex: 1; height: 6px; border-radius: 3px; background: rgba(255,255,255,0.08); overflow: hidden; min-width: 40px; }
.gh-header--light .gh-avatar-card__usage-bar { background: rgba(15,23,42,0.08); }
.gh-avatar-card__usage-fill { height: 100%; border-radius: 3px; transition: width 0.4s ease; }
.gh-avatar-card__usage-fill--daily { background: linear-gradient(90deg, #3b82f6, #60a5fa); }
.gh-avatar-card__usage-fill--monthly { background: linear-gradient(90deg, #ef4444, #f87171); }
.gh-avatar-card__usage-text { font-size: 10px; font-family: var(--gh-font-mono); letter-spacing: 0.04em; opacity: 0.75; white-space: nowrap; flex-shrink: 0; }
.gh-avatar-card__usage-text--big { font-size: 13px; font-weight: 700; opacity: 1; margin-left: auto; }
.gh-avatar-card__usage-row--credits { justify-content: space-between; padding-top: 4px; border-top: 1px dashed rgba(255,255,255,0.08); margin-top: 2px; }
.gh-header--light .gh-avatar-card__usage-row--credits { border-top-color: rgba(15,23,42,0.08); }

/* ===== AVATAR PLACEHOLDER (compat) ===== */
.gh-avatar-placeholder { display: flex; flex-direction: column; align-items: center; gap: 12px; padding: 8px; }
.gh-avatar-placeholder__pic-wrap { position: relative; width: 96px; height: 96px; flex-shrink: 0; }
.gh-avatar-placeholder__pic { width: 96px; height: 96px; border-radius: 50%; object-fit: cover; border: 3px solid rgba(243,103,7,0.3); background: #1F1F1F; display: block; }
.gh-avatar-placeholder__pic--initial { display: inline-flex; align-items: center; justify-content: center; background: linear-gradient(135deg, var(--gh-orange) 0%, var(--gh-orange-soft) 100%); color: #FFF; font-size: 36px; font-weight: 800; font-family: var(--gh-font-display); }
.gh-avatar-placeholder__ai-badge { position: absolute; bottom: -4px; right: -4px; width: 38px; height: 38px; border-radius: 50%; background: #0F0F0F; border: 3px solid rgba(243,103,7,0.5); overflow: hidden; display: inline-flex; align-items: center; justify-content: center; }
.gh-avatar-placeholder__ai-badge img { width: 100%; height: 100%; object-fit: cover; }
.gh-avatar-placeholder__info { text-align: center; min-width: 0; width: 100%; }
.gh-avatar-placeholder__name { font-family: var(--gh-font-display); font-size: 16px; font-weight: 700; line-height: 1.2; margin-bottom: 4px; }
.gh-avatar-placeholder__headline { font-size: 12px; opacity: 0.6; line-height: 1.3; margin-bottom: 10px; }
.gh-avatar-placeholder__stats { display: flex; justify-content: center; gap: 10px; flex-wrap: wrap; }
.gh-avatar-placeholder__stat { display: inline-flex; align-items: center; gap: 4px; font-size: 11px; opacity: 0.75; padding: 3px 8px; border-radius: 999px; background: rgba(255,255,255,0.05); }

/* ===== Animações de entrada do dropdown ===== */
.gh-fade-enter { transition: opacity 220ms var(--gh-ease-out); }
.gh-fade-enter-start { opacity: 0; }
.gh-fade-enter-end { opacity: 1; }

.gh-slide-enter { transition: opacity 280ms var(--gh-ease-out), transform 320ms var(--gh-ease-spring); }
.gh-slide-enter-start { opacity: 0; transform: translateY(-12px) scale(0.99); }
.gh-slide-enter-end { opacity: 1; transform: translateY(0) scale(1); }

/* ===== RESPONSIVO ===== */
@media (max-width: 1279px) {
    .gh-language-globe__label { display: none; }
    .gh-language-globe__trigger { padding: 4px 6px; }
    .gh-mega-dropdown__row--top { grid-template-columns: 1fr 1fr; }
    .gh-mega-dropdown__col--avatar { grid-column: 1 / -1; }
    .gh-mega-dropdown__row--bottom { grid-template-columns: 1fr 1fr; }
    .gh-mega-dropdown__col--card.gh-card--notif { grid-column: 1 / -1; }
}

@media (max-width: 768px) {
    .gh-header__inner { padding: 0 16px; gap: 8px; }
    .gh-header__logo { height: 28px; }
    .gh-header__logo-text { font-size: 16px; }
    .gh-pillar-switcher__trigger { width: 38px; height: 38px; padding: 0; }
    .gh-pillar-switcher__current-img { width: 30px; height: 30px; padding: 2px; }
    .gh-pillar-switcher__menu { min-width: 260px; left: -8px; }
    .gh-language-globe__trigger { padding: 4px; height: 38px; }
    .gh-globe-3d { width: 28px; height: 28px; }
    .gh-user-chip { padding: 3px 12px 3px 3px; height: 38px; }
    .gh-user-chip__avatar-wrap { width: 30px; height: 30px; }
    .gh-user-chip__avatar { width: 30px; height: 30px; }
    .gh-user-chip__name { display: none; }
    .gh-user-chip__caret { display: none; }
    .gh-auth-buttons__login,
    .gh-auth-buttons__register { padding: 0 14px; font-size: 13px; height: 38px; }

    /* Mega dropdown -> FULLSCREEN top-to-bottom (max app feel) */
    .gh-mega-dropdown__inner {
        position: fixed;
        top: var(--gh-header-height) !important;
        left: 0; right: 0; bottom: 0 !important;
        width: 100% !important;
        max-width: 100% !important;
        margin: 0 !important;
        padding: 16px;
        border-radius: 0;
        height: calc(100vh - var(--gh-header-height));
        max-height: none;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
        overscroll-behavior: contain;
        animation: gh-sheet-down 280ms var(--gh-ease-spring) both;
    }
    .gh-header--scrolled ~ .gh-mega-dropdown .gh-mega-dropdown__inner,
    .gh-header--scrolled .gh-mega-dropdown__inner {
        top: var(--gh-header-height-scrolled) !important;
        height: calc(100vh - var(--gh-header-height-scrolled));
    }

    @keyframes gh-sheet-down {
        from { transform: translateY(-12px); opacity: 0; }
        to { transform: translateY(0); opacity: 1; }
    }

    .gh-mega-dropdown__row--top,
    .gh-mega-dropdown__row--bottom { grid-template-columns: 1fr; }
    .gh-mega-dropdown__col { padding: 14px; }
    .gh-mega-dropdown__col--avatar { grid-column: 1 / -1; }

    /* Footer NATURAL no fim do scroll (nao sticky — evita conflito de layout) */
    .gh-mega-dropdown__footer {
        flex-direction: column-reverse; align-items: stretch;
        margin-top: 24px;
        padding-top: 18px;
        gap: 8px;
    }
    .gh-mega-dropdown__action { justify-content: center; height: 46px; }

    .gh-avatar-card__pic-wrap { animation-duration: 18s; }

    /* Esconder overlay (e fullscreen, nao precisa overlay separado) */
    .gh-mega-dropdown__overlay { display: none; }
}

/* Tablet (769-1279): dropdown ainda flutuante mas trava scroll body */
@media (min-width: 769px) and (max-width: 1279px) {
    .gh-mega-dropdown__inner {
        max-height: calc(100vh - var(--gh-header-height) - 24px);
        overflow-y: auto;
        overscroll-behavior: contain;
    }
}

/* ===== A11Y ===== */
.gh-header :focus-visible {
    outline: 2px solid var(--gh-orange);
    outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
    .gh-header *,
    .gh-header *::before,
    .gh-header *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    .gh-avatar-card__pic-wrap,
    .gh-avatar-card__pic-wrap > * { animation: none; }
}

[x-cloak] { display: none !important; }
