/* Poke Ponte: a single final UI layer inspired by hero-centric game menus. */
:root {
  --ow-ink: #18202c;
  --ow-ink-soft: #3f4a59;
  --ow-muted: #6c7786;
  --ow-page: #edf1f5;
  --ow-panel: rgba(255, 255, 255, .9);
  --ow-white: #fff;
  --ow-line: rgba(24, 32, 44, .16);
  --ow-line-strong: rgba(24, 32, 44, .28);
  --ow-orange: #f06414;
  --ow-orange-dark: #ce4b05;
  --ow-orange-soft: #fff0e6;
  --ow-blue: #168dd8;
  --ow-cyan: #48c7e8;
  --ow-shadow: 0 18px 42px rgba(37, 48, 63, .14);
  --ow-shadow-small: 0 8px 22px rgba(37, 48, 63, .12);
  --ow-radius: 7px;
  --bg-body: var(--ow-page);
  --bg-body-grad: linear-gradient(180deg, #f7f9fb 0%, var(--ow-page) 48%, #e7ecf1 100%);
  --bg-elevado: var(--ow-white);
  --bg-card: var(--ow-white);
  --bg-card-2: #f4f7fa;
  --bg-sidebar: var(--ow-white);
  --bg-input: rgba(255, 255, 255, .94);
  --bg-hover: rgba(24, 32, 44, .07);
  --texto-primario: var(--ow-ink);
  --texto-secundario: var(--ow-ink-soft);
  --texto-terciario: var(--ow-muted);
  --borda-cor: var(--ow-line);
  --borda-forte: var(--ow-line-strong);
  --accent: var(--ow-orange);
  --accent-forte: var(--ow-orange-dark);
  --accent-suave: rgba(240, 100, 20, .13);
  --accent-rgb: 240, 100, 20;
  --fonte-base: 'Inter', 'Segoe UI', Arial, sans-serif;
  --fonte-indicador: 'Inter', 'Segoe UI', Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { background: var(--ow-page); color-scheme: light; font-family: var(--fonte-base); scroll-behavior: smooth; }
body {
  min-width: 320px;
  margin: 0;
  overflow-x: hidden;
  background: linear-gradient(118deg, rgba(255,255,255,.72) 0 42%, transparent 42%), var(--bg-body-grad);
  color: var(--ow-ink);
  font-family: var(--fonte-base);
  font-size: 16px;
  line-height: 1.5;
}
body::before {
  position: fixed;
  inset: 0;
  z-index: -1;
  background-image: linear-gradient(rgba(24,32,44,.025) 1px, transparent 1px);
  background-size: 100% 6px;
  content: '';
  pointer-events: none;
}
body :is(h1,h2,h3,h4,h5,h6) { margin-top: 0; color: var(--ow-ink); font-family: var(--fonte-base); font-weight: 800; letter-spacing: 0; line-height: 1.04; }
body h1 { font-size: 64px; }
body h2 { font-size: 48px; }
body h3 { font-size: 36px; }
body h4 { font-size: 28px; }
body h5 { font-size: 22px; }
body h6 { font-size: 18px; }
body :is(button,input,select,textarea) { font-family: inherit; }
body :is(a,button,input,select,textarea,[tabindex]):focus-visible { outline: 3px solid var(--ow-cyan); outline-offset: 3px; }

/* Header, account controls and primary navigation. */
.galar-masthead {
  position: fixed;
  inset: 0 0 auto;
  z-index: 510;
  display: block;
  width: 100%;
  height: 88px;
  padding: 0;
  border: 0;
  background: linear-gradient(180deg, rgba(245,248,251,.98), rgba(245,248,251,.72) 72%, transparent);
  pointer-events: none;
}
.galar-brand {
  position: absolute;
  top: 19px;
  left: 28px;
  display: flex !important;
  align-items: center;
  gap: 10px;
  color: var(--ow-ink);
  text-decoration: none;
  pointer-events: auto;
}
.galar-brand > span:last-child { display: grid; grid-template-columns: auto auto; column-gap: 4px; align-items: baseline; font-size: 16px; font-style: italic; font-weight: 900; line-height: 1; }
.galar-brand b { color: var(--ow-orange); }
.galar-brand small { grid-column: 1 / -1; margin-top: 4px; color: var(--ow-muted); font-size: 8px; font-style: normal; font-weight: 700; }
.galar-brand .galar-ball { width: 30px; height: 30px; color: var(--ow-orange); }
.galar-edition { display: none !important; }
.galar-top-actions { position: absolute; top: 18px; right: 28px; display: flex; align-items: stretch; gap: 8px; margin: 0; pointer-events: auto; }
.galar-top-profile,
body .galar-top-icon { min-height: 46px; border: 1px solid var(--ow-line); border-radius: 4px; background: rgba(255,255,255,.94); color: var(--ow-ink); box-shadow: var(--ow-shadow-small); }
.galar-top-profile { display: grid; grid-template-columns: 46px minmax(94px,144px); align-items: center; padding: 0; overflow: hidden; cursor: pointer; text-align: left; }
.galar-top-profile img { width: 46px; height: 46px; object-fit: cover; background: #11151c; }
.galar-top-profile span { align-self: stretch; display: flex; align-items: center; padding: 0 18px; background: var(--ow-orange); color: #fff; font-size: 12px; font-weight: 900; }
body .galar-top-icon { display: grid; width: 46px; height: 46px; padding: 0; place-items: center; color: var(--ow-blue); }
body .galar-top-icon:hover { border-color: var(--ow-blue); background: var(--ow-blue); color: #fff; }
body .galar-top-icon svg { width: 21px; height: 21px; }

body .sidebar,
body .sidebar:has(.sidebar-link[href='/Perfil_usuario']) {
  position: fixed;
  inset: 18px auto auto 50%;
  z-index: 520;
  display: flex;
  width: auto;
  height: 52px;
  min-height: 0;
  padding: 4px;
  transform: translateX(-50%);
  border: 1px solid rgba(255,255,255,.95) !important;
  border-radius: 999px;
  background: rgba(255,255,255,.88) !important;
  box-shadow: var(--ow-shadow);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}
body :is(.sidebar-logo,.galar-nav-caption,.galar-nav-note) { display: none; }
body .sidebar-nav { display: flex; width: auto; align-items: center; gap: 2px; margin: 0; padding: 0; border: 0; background: transparent; }
body .sidebar-link {
  position: relative;
  display: inline-flex;
  width: auto;
  min-width: 92px;
  min-height: 42px;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 0 18px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--ow-ink);
  font-size: 12px;
  font-style: italic;
  font-weight: 800;
  text-decoration: none;
  text-transform: uppercase;
}
body .sidebar-link::before { display: none !important; }
body .sidebar-link:hover { background: rgba(24,32,44,.07); color: var(--ow-ink); }
body .sidebar-link.ativo,
body .sidebar-link.ativo:hover { background: var(--ow-orange); color: #fff; box-shadow: 0 7px 18px rgba(240,100,20,.28); }
body .sidebar-icon { display: none; }

.galar-page-watermark {
  position: fixed;
  top: 88px;
  right: 28px;
  z-index: 0;
  color: var(--ow-ink);
  font-family: var(--fonte-base);
  font-size: 112px;
  font-style: italic;
  font-weight: 900;
  letter-spacing: 0;
  line-height: .82;
  opacity: .035;
  pointer-events: none;
  user-select: none;
}
body .page-wrap { position: relative; z-index: 2; width: 100%; min-height: 100vh; margin: 0; padding: 92px 0 0; background: transparent; }
body .page-wrap > main { width: min(1720px, calc(100% - 64px)); max-width: none; min-width: 0; margin: 0 auto; padding: 32px 0 48px; }
body .page-wrap > footer { border-color: var(--ow-line); color: var(--ow-muted); }

/* Reusable form and action language. */
body :is(.auth-btn-principal,.album-primary-button,.social-button.primary,.btn-mini:not(.btn-mini-secundario),.inventory-add-card-button,.trade-card-action) {
  min-height: 44px;
  border: 0;
  border-radius: 5px;
  background: var(--ow-orange);
  color: #fff;
  box-shadow: none;
  font-weight: 800;
}
body :is(.auth-btn-principal,.album-primary-button,.social-button.primary,.btn-mini:not(.btn-mini-secundario),.inventory-add-card-button,.trade-card-action):hover { background: var(--ow-orange-dark); color: #fff; }
body :is(.wishlist-search-field,.album-search-field,.lojas-search,.search-input-wrap,.social-search-field) { min-height: 50px; border: 1px solid var(--ow-line); border-radius: 5px; background: rgba(255,255,255,.9); box-shadow: none; }
body :is(.wishlist-search-field,.album-search-field,.lojas-search,.search-input-wrap,.social-search-field):focus-within { border-color: var(--ow-blue); outline: 2px solid rgba(22,141,216,.18); outline-offset: 1px; }

/* Home: visual card, editorial copy and a lower selector rail. */
body.home-page .home-compact-nav { display: none !important; }
body.home-page .page-wrap > main.home-page-main { width: 100%; padding: 0 0 64px; }
body.home-page :is(.home-wishlist-hero,.home-section-hero)::after { display: none; }
body.home-page :is(.home-wishlist-hero-button,.home-community-button) {
  position: relative;
  display: inline-flex;
  min-width: 196px;
  min-height: 46px;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 0 18px;
  overflow: hidden;
  border: 0;
  border-radius: 4px;
  background: var(--ow-orange);
  color: #fff;
  font-size: 12px;
  font-style: italic;
  font-weight: 900;
  text-decoration: none;
  text-transform: uppercase;
}
body.home-page :is(.home-wishlist-hero-button,.home-community-button)::after { position: absolute; inset: 0 0 0 auto; width: 52px; background: var(--ow-ink); clip-path: polygon(35% 0,100% 0,100% 100%,0 100%); content: ''; }
body.home-page :is(.home-wishlist-hero-button,.home-community-button) > * { position: relative; z-index: 1; }

@media (min-width: 901px) {
  body.home-page .sidebar { display: flex !important; }
  body.home-page .galar-masthead { inset: 0 0 auto !important; width: 100% !important; height: 88px !important; }
  body.home-page .galar-top-actions { top: 18px !important; right: 28px !important; }
  body.home-page .home-feature-shell { display: flex; width: min(1500px, calc(100% - 80px)); min-height: calc(100vh - 112px); flex-direction: column; justify-content: center; gap: 18px; margin: 0 auto; padding: 22px 0 32px; }
  body.home-page .home-carousel-stage { width: 100%; height: min(520px, calc(100vh - 260px)); min-height: 390px; overflow: visible; border-radius: 0; }
  body.home-page :is(.home-carousel-slide,.home-wishlist-hero,.home-collection-banner,.home-section-hero) { width: 100%; height: 100%; min-height: 0; margin: 0; }
  body.home-page :is(.home-wishlist-hero,.home-collection-banner,.home-section-hero) { display: grid; grid-template-columns: minmax(520px,1.25fr) minmax(340px,.75fr); align-items: stretch; gap: 46px; overflow: visible; border-radius: 0; background: transparent; }
  body.home-page :is(.home-wishlist-hero-art,.home-collection-banner picture,.home-section-hero > img) { position: relative; inset: auto; display: block; width: 100%; height: 100%; overflow: hidden; border: 1px solid rgba(255,255,255,.94); border-radius: var(--ow-radius); background: #dbe2e9; box-shadow: var(--ow-shadow); }
  body.home-page :is(.home-wishlist-hero-art img,.home-collection-banner picture img,.home-section-hero > img) { position: static; display: block; width: 100%; height: 100%; object-fit: cover; transform: none; }
  body.home-page :is(.home-wishlist-hero-copy,.home-section-hero-copy,.home-collection-hero-copy) { position: relative; inset: auto; z-index: 2; display: flex; width: auto; min-height: 0; align-self: center; align-items: flex-start; flex-direction: column; padding: 0; border: 0; background: transparent; color: var(--ow-ink); box-shadow: none; }
  body.home-page :is(.home-wishlist-hero-copy h1,.home-section-hero-copy h1,.home-collection-hero-copy h1) { max-width: 520px; margin: 0 0 22px; color: var(--ow-ink); font-size: 64px; font-style: italic; font-weight: 900; line-height: .9; text-transform: uppercase; }
  body.home-page :is(.home-wishlist-hero-copy p,.home-section-hero-copy p,.home-collection-hero-copy p) { max-width: 480px; margin: 0 0 30px; color: var(--ow-ink-soft); font-size: 20px; font-weight: 500; line-height: 1.38; }
  body.home-page :is(.home-section-hero-copy > span,.home-collection-hero-copy > span) { margin-bottom: 12px; color: var(--ow-orange); font-size: 11px; font-style: italic; font-weight: 900; letter-spacing: .08em; }
  body.home-page .home-collection-banner .home-community-button { position: absolute; right: 0; bottom: 54px; left: calc(62.5% + 12px); margin: 0; }
  body.home-page .home-carousel-previews { display: grid; width: 100%; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 12px; margin: 0; padding: 0; }
  body.home-page .home-carousel-preview { position: relative; display: flex; width: 100%; height: 104px; min-height: 0; align-items: flex-end; padding: 12px 14px; overflow: hidden; border: 1px solid var(--ow-line); border-radius: var(--ow-radius); background: #c8d0d8; color: #fff; box-shadow: none; font-size: 13px; font-style: italic; font-weight: 800; text-align: left; cursor: pointer; isolation: isolate; }
  body.home-page .home-carousel-preview::before { position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg,transparent 25%,rgba(13,18,27,.82)); content: ''; }
  body.home-page .home-carousel-preview::after { position: absolute; top: auto; right: 0; bottom: 0; left: 0; height: 4px; background: transparent; content: ''; }
  body.home-page .home-carousel-preview img { position: absolute; inset: 0; z-index: -2; display: block; width: 100%; height: 100%; border-radius: 0; object-fit: cover; }
  body.home-page .home-carousel-preview span { position: relative; z-index: 1; color: #fff; text-shadow: 0 2px 8px rgba(0,0,0,.5); }
  body.home-page .home-carousel-preview:hover { border-color: var(--ow-line-strong); background: #c8d0d8; transform: translateY(-2px); }
  body.home-page .home-carousel-preview.is-active { border-color: var(--ow-orange); background: #c8d0d8; box-shadow: var(--ow-shadow-small); }
  body.home-page .home-carousel-preview.is-active::after { background: var(--ow-orange); }
}

/* Inventory: compact library at left and a dominant inspection area. */
body:has(#wishlist-page) .page-wrap > main { width: min(1760px, calc(100% - 48px)); padding-top: 26px; }
body #wishlist-page { width: 100%; margin: 0; padding: 36px 0 64px; }
body #wishlist-page .wishlist-mode-tabs { display: inline-flex; gap: 2px; margin: 0 0 20px; padding: 4px; border: 1px solid var(--ow-line); border-radius: 5px; background: rgba(255,255,255,.78); }
body #wishlist-page .wishlist-mode-tab { min-height: 42px; padding: 0 16px; border-radius: 4px; color: var(--ow-ink-soft); font-size: 11px; font-style: italic; text-transform: uppercase; }
body #wishlist-page .wishlist-mode-tab.is-active { background: var(--ow-ink); color: #fff; box-shadow: inset 5px 0 0 var(--ow-orange); }
body #wishlist-page .inventory-workspace { display: grid; grid-template-columns: minmax(0,1fr) minmax(420px,520px); align-items: start; gap: 42px; }
body #wishlist-page .wishlist-library { min-width: 0; }
body #wishlist-page .wishlist-search-bar { display: grid; grid-template-columns: minmax(0,1fr) auto; gap: 10px; margin-bottom: 18px; }
body #wishlist-page .inventory-add-card-button { min-height: 50px; padding: 0 22px; border-radius: 5px 24px 24px 5px; background: var(--ow-orange); }
body #wishlist-page .wishlist-search-status { grid-column: 1 / -1; }
body #wishlist-page .wishlist-collections-carousel { grid-template-columns: 36px minmax(0,1fr) 36px; gap: 8px; margin-bottom: 22px; }
body #wishlist-page .wishlist-collection-icons { gap: 8px; }
body #wishlist-page .wishlist-collection-filter { flex: 0 0 142px; min-height: 62px; padding: 7px 9px; border: 1px solid var(--ow-line); border-radius: 5px; background: rgba(255,255,255,.82); color: var(--ow-ink); }
body #wishlist-page .wishlist-collection-filter:hover,
body #wishlist-page .wishlist-collection-filter.is-active { border-color: var(--ow-orange); background: #fff; }
body #wishlist-page .wishlist-collections-arrow { border-color: var(--ow-line); background: #fff; color: var(--ow-orange); }
body #wishlist-page .wishlist-card-grid { display: grid; grid-template-columns: repeat(auto-fill,minmax(150px,180px)); justify-content: start; gap: 18px 14px; }
body #wishlist-page .wishlist-grid-card { border-radius: 5px; }
body #wishlist-page .wishlist-grid-card img { width: 100%; }
body #wishlist-page .wishlist-grid-item.is-selected .wishlist-grid-card { outline: 3px solid var(--ow-orange); outline-offset: 3px; }
body #wishlist-page .wishlist-grid-actions { gap: 6px; }
body #wishlist-page .wishlist-grid-actions button { min-height: 34px; border-radius: 4px; font-size: 10px; }
body #wishlist-page .inventory-preview { position: sticky; top: 102px; display: grid; min-height: calc(100vh - 128px); align-content: start; gap: 16px; padding: 0; border: 0; background: transparent; }
body #wishlist-page .inventory-preview-card { width: min(100%,420px); margin: 0 auto; background: transparent; }
body #wishlist-page .inventory-preview-card img { width: 100%; max-height: calc(100vh - 330px); object-fit: contain; }
body #wishlist-page .inventory-preview-copy > span { color: var(--ow-orange); font-size: 10px; font-style: italic; font-weight: 900; }
body #wishlist-page .inventory-preview-copy h2 { margin: 0; color: var(--ow-ink); font-size: 36px; font-style: italic; text-transform: uppercase; }
body #wishlist-page .inventory-preview-copy p { color: var(--ow-muted); }
body #wishlist-page .inventory-preview-actions { margin-top: 4px; }
body #wishlist-page .inventory-preview-actions button { min-height: 42px; border-radius: 4px; }
body #wishlist-page .inventory-preview-actions .inventory-preview-owned { border-color: var(--ow-orange); background: var(--ow-orange); color: #fff; }

/* Trades and marketplace. */
body .trades-page { width: min(1680px, calc(100% - 64px)); margin: 0 auto; padding: 50px 0 72px; }
body .trades-page-header { margin-bottom: 38px; }
body .trades-page-header::after { display: block; max-width: 980px; margin-top: 12px; color: var(--ow-ink); content: 'TROCAS'; font-size: 64px; font-style: italic; font-weight: 900; line-height: .9; }
body .trades-page-header > span,
body .trades-section-heading > span { color: var(--ow-orange); font-style: italic; letter-spacing: .06em; }
body .trades-page-header p { max-width: 720px; color: var(--ow-ink-soft); font-size: 17px; }
body .trades-section { margin-bottom: 52px; }
body .trades-section-heading h2 { color: var(--ow-ink); font-size: 30px; font-style: italic; text-transform: uppercase; }
body .trades-grid { grid-template-columns: repeat(4,minmax(0,1fr)); gap: 14px; }
body .trade-card { border-color: var(--ow-line); border-radius: 6px; background: rgba(255,255,255,.88); box-shadow: var(--ow-shadow-small); }
body .trade-card > img { border-radius: 3px; background: #f1f4f7; }
body .trade-card-copy strong { color: var(--ow-ink); }
body .trade-card-copy span { color: var(--ow-muted); }
body .trade-card-action { border-radius: 4px; }
body .trade-card-action.is-announced { border-color: var(--ow-orange); background: var(--ow-orange-soft); color: var(--ow-orange-dark); }
body .trade-empty { border-color: var(--ow-line-strong); color: var(--ow-muted); background: rgba(255,255,255,.44); }

/* Social, chat and profile surfaces. */
body .social-main,
body .public-profile-main,
body .social-auth-required { width: min(1580px, calc(100% - 64px)); padding-top: 40px; }
body .social-page-header h1 { margin: 4px 0 8px; font-size: 56px; font-style: italic; text-transform: uppercase; }
body .social-page-header p { color: var(--ow-ink-soft); }
body .social-tabs { border: 1px solid var(--ow-line); border-radius: 5px; background: rgba(255,255,255,.78); box-shadow: none; }
body .social-tab { min-height: 44px; border-radius: 4px; font-style: italic; text-transform: uppercase; }
body .social-tab.is-active { background: var(--ow-ink); color: #fff; box-shadow: inset 5px 0 0 var(--ow-orange); }
body .social-tab.is-active::after { display: none; }
body :is(.social-search-card,.social-panel,.chat-shell,.public-profile-hero,.public-profile-stats) { border-color: var(--ow-line); border-radius: 7px; background: rgba(255,255,255,.86); box-shadow: var(--ow-shadow-small); }
body .social-user-card { border-radius: 6px; box-shadow: none; }
body .social-button { border-radius: 4px; }

/* Authentication keeps the illustration but removes the old orange slab. */
body.auth-body { padding: 88px 0 0; background: var(--bg-body-grad); }
body.auth-body .auth-shell { min-height: calc(100vh - 88px); }
body.auth-body .auth-panel-form { padding: 42px 7%; background: transparent; }
body.auth-body .auth-card { max-width: 460px; padding: 38px; border: 1px solid var(--ow-line); border-top: 5px solid var(--ow-orange); border-radius: 7px; background: rgba(255,255,255,.94); box-shadow: var(--ow-shadow); }
body.auth-body .auth-card h1 { margin-bottom: 10px; font-size: 48px; font-style: italic; text-transform: uppercase; }
body.auth-body .auth-panel-visual { border-left: 1px solid var(--ow-line); background: #d9e1e8; }
body.auth-body .auth-visual-overlay { background: linear-gradient(90deg, rgba(237,241,245,.24), transparent 34%); }
body.auth-body .auth-visual-badge { border-radius: 4px; box-shadow: var(--ow-shadow-small); }
body.auth-body .form-group input { min-height: 50px; border-width: 1px; border-radius: 5px; }
body.auth-body .auth-btn-principal,
body.auth-body .auth-btn-secundario { border-radius: 5px; }

/* Map controls float as one coherent instrument panel. */
body:has(#lojas-page) #lojas-page > header,
body:has(#lojas-page) .lojas-controles,
body:has(#lojas-page) #lojasStatus,
body:has(#lojas-page) .pokemon-indicador { border: 1px solid rgba(255,255,255,.88); border-radius: 6px; background: rgba(255,255,255,.9); box-shadow: var(--ow-shadow); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); }
body:has(#lojas-page) #lojas-page > header { padding: 16px 18px; }
body:has(#lojas-page) #lojas-page h1 { font-size: 28px; font-style: italic; text-transform: uppercase; }
body:has(#lojas-page) .btn-mini { border-radius: 5px; }
body:has(#lojas-page) #lojasSugestoes .busca-tag-pill { border-radius: 4px; }

/* Community drawer. */
body .galar-social-menu:has(.galar-community-frame) { top: 76px; right: 28px; width: min(760px,calc(100vw - 56px)); height: min(760px,calc(100dvh - 104px)); overflow: hidden; border: 1px solid var(--ow-line); border-top: 5px solid var(--ow-orange); border-radius: 7px; background: #fff; box-shadow: 0 26px 70px rgba(24,32,44,.24); }

@media (max-width: 1200px) {
  body h1 { font-size: 52px; }
  body h2 { font-size: 40px; }
  body h3 { font-size: 32px; }
  .galar-brand small { display: none; }
  body.home-page :is(.home-wishlist-hero-copy h1,.home-section-hero-copy h1,.home-collection-hero-copy h1) { font-size: 52px; }
  body .trades-grid { grid-template-columns: repeat(3,minmax(0,1fr)); }
  body #wishlist-page .inventory-workspace { grid-template-columns: minmax(0,1fr) 390px; gap: 28px; }
  body #wishlist-page .wishlist-card-grid { grid-template-columns: repeat(auto-fill,minmax(140px,1fr)); }
}

@media (max-width: 900px) {
  .galar-brand { display: none !important; }
  .galar-top-actions { top: 12px; right: 12px; gap: 5px; }
  .galar-top-profile { grid-template-columns: 42px; min-height: 42px; }
  .galar-top-profile img { width: 42px; height: 42px; }
  .galar-top-profile span { display: none; }
  body .galar-top-icon { width: 42px; height: 42px; min-height: 42px; }
  body .sidebar,
  body .sidebar:has(.sidebar-link[href='/Perfil_usuario']) { inset: auto auto calc(12px + env(safe-area-inset-bottom)) 50%; width: min(calc(100% - 24px),390px); height: 56px; padding: 5px; background: rgba(255,255,255,.92) !important; }
  body .sidebar-nav { width: 100%; }
  body .sidebar-link { flex: 1 1 0; min-width: 0; min-height: 46px; padding: 0 9px; font-size: 10px; }
  body.home-page .sidebar { display: flex !important; }
  body.home-page .galar-masthead { inset: 0 0 auto !important; width: 100% !important; height: 72px !important; }
  body.home-page .galar-top-actions { top: 12px !important; right: 12px !important; gap: 5px !important; }
  body.home-page .galar-top-profile { grid-template-columns: 42px !important; min-width: 42px !important; width: 42px !important; }
  body.home-page .galar-top-profile img { width: 42px !important; height: 42px !important; }
  body.home-page .galar-top-profile span { display: none !important; }
  body .page-wrap { padding-top: 72px; padding-bottom: calc(80px + env(safe-area-inset-bottom)); }
  body #wishlist-page .inventory-workspace { grid-template-columns: 1fr; }
  body #wishlist-page .inventory-preview { display: none; }
  body .trades-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
}

@media (max-width: 900px) {
  body { font-size: 15px; }
  body h1 { font-size: 40px; }
  body h2 { font-size: 34px; }
  body h3 { font-size: 28px; }
  .galar-masthead { height: 72px; }
  .galar-top-actions { top: 12px; right: 12px; gap: 5px; }
  .galar-top-profile { grid-template-columns: 42px; }
  .galar-top-profile span { display: none; }
  body .sidebar,
  body .sidebar:has(.sidebar-link[href='/Perfil_usuario']) { inset: auto auto calc(12px + env(safe-area-inset-bottom)) 50%; width: min(calc(100% - 24px),390px); height: 56px; padding: 5px; background: rgba(255,255,255,.92) !important; }
  body .sidebar-nav { width: 100%; }
  body .sidebar-link { flex: 1 1 0; min-width: 0; min-height: 46px; padding: 0 9px; font-size: 10px; }
  body .page-wrap { padding-top: 72px; padding-bottom: calc(80px + env(safe-area-inset-bottom)); }
  body .page-wrap > main { width: calc(100% - 24px); padding-top: 22px; }
  .galar-page-watermark { top: 76px; right: 10px; font-size: 64px; }

  body.home-page .page-wrap > main.home-page-main { padding: 0 0 88px; }
  body.home-page .home-feature-shell { width: 100%; margin: 0; padding: 12px 0 24px; }
  body.home-page .home-carousel-stage { height: auto; min-height: 0; overflow: visible; }
  body.home-page :is(.home-carousel-slide,.home-wishlist-hero,.home-collection-banner,.home-section-hero) { height: auto; min-height: 0; }
  body.home-page :is(.home-wishlist-hero,.home-collection-banner,.home-section-hero) { display: grid; width: min(100% - 24px,520px); grid-template-columns: 1fr; gap: 20px; margin: 0 auto; overflow: visible; border-radius: 0; background: transparent; }
  body.home-page :is(.home-wishlist-hero-art,.home-collection-banner picture,.home-section-hero > img) { position: relative; inset: auto; display: block; width: 100%; height: auto; aspect-ratio: 16 / 10; overflow: hidden; border-radius: var(--ow-radius); box-shadow: var(--ow-shadow-small); }
  body.home-page :is(.home-wishlist-hero-art img,.home-collection-banner picture img,.home-section-hero > img) { position: static; width: 100%; height: 100%; object-fit: cover; }
  body.home-page :is(.home-wishlist-hero-copy,.home-section-hero-copy,.home-collection-hero-copy) { position: relative; inset: auto; width: 100%; align-items: flex-start; padding: 0 4px; color: var(--ow-ink); }
  body.home-page :is(.home-wishlist-hero-copy h1,.home-section-hero-copy h1,.home-collection-hero-copy h1) { margin: 0 0 12px; color: var(--ow-ink); font-size: 40px; font-style: italic; text-transform: uppercase; }
  body.home-page :is(.home-wishlist-hero-copy p,.home-section-hero-copy p,.home-collection-hero-copy p) { margin: 0 0 20px; color: var(--ow-ink-soft); font-size: 16px; line-height: 1.4; }
  body.home-page .home-collection-banner .home-community-button { position: relative; inset: auto; margin: 0 4px; }
  body.home-page .home-carousel-previews { display: flex; gap: 10px; width: 100%; margin-top: 26px; padding: 0 12px 8px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; }
  body.home-page .home-carousel-previews::-webkit-scrollbar { display: none; }
  body.home-page .home-carousel-preview { position: relative; display: grid; flex: 0 0 150px; width: 150px; height: 82px; min-height: 82px; align-items: end; padding: 10px; overflow: hidden; border: 1px solid var(--ow-line); border-radius: 5px; background: #fff; color: var(--ow-ink); font-size: 11px; font-weight: 800; scroll-snap-align: start; }
  body.home-page .home-carousel-preview img { position: absolute; inset: 0; z-index: 0; width: 100%; height: 100%; object-fit: cover; opacity: .38; }
  body.home-page .home-carousel-preview span { position: relative; z-index: 1; }
  body.home-page .home-carousel-preview.is-active { border-color: var(--ow-orange); box-shadow: inset 0 -4px var(--ow-orange); }

  body:has(#wishlist-page) .page-wrap > main { width: calc(100% - 24px); padding-top: 12px; }
  body #wishlist-page { padding: 20px 0 36px; }
  body #wishlist-page .wishlist-mode-tabs { width: 100%; }
  body #wishlist-page .wishlist-mode-tab { flex: 1 1 0; padding: 0 8px; font-size: 10px; }
  body #wishlist-page .wishlist-search-bar { grid-template-columns: 1fr; }
  body #wishlist-page .inventory-add-card-button { width: 100%; }
  body #wishlist-page .wishlist-card-grid { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 14px 10px; }
  body .trades-page { width: calc(100% - 24px); padding: 24px 0 96px; }
  body .trades-page-header::after { font-size: 40px; }
  body .trades-grid { grid-template-columns: 1fr; }
  body .trade-card { grid-template-columns: 84px minmax(0,1fr); }
  body .social-main,
  body .public-profile-main,
  body .social-auth-required { width: calc(100% - 24px); padding-top: 20px; }
  body .social-page-header h1 { font-size: 40px; }
  body .galar-social-menu:has(.galar-community-frame) { top: 66px; right: 10px; width: calc(100vw - 20px); height: calc(100dvh - 154px); }
  body.auth-body { padding: 72px 0 76px; }
  body.auth-body .auth-shell { min-height: calc(100vh - 148px); }
  body.auth-body .auth-panel-form { padding: 28px 16px; }
  body.auth-body .auth-card { padding: 28px 22px; }
  body.auth-body .auth-card h1 { font-size: 40px; }
}

@media (max-width: 430px) {
  .galar-top-profile { grid-template-columns: 42px; width: 42px; }
  .galar-top-profile span { display: none; }
  body .galar-top-icon { width: 40px; }
  body .sidebar-link { font-size: 9px; }
  body.home-page :is(.home-wishlist-hero-button,.home-community-button) { min-width: 180px; }
}

@media (min-width: 901px) {
  body:has(#lojas-page) #lojas-page > header {
    top: 108px;
    left: 42px;
    width: 310px;
    max-width: 310px;
  }
  body:has(#lojas-page) #lojas-page h1 { white-space: normal; }
  body:has(#lojas-page) .lojas-controles {
    top: 112px;
    left: 370px;
    width: min(720px, calc(100vw - 690px));
    transform: none;
  }
  body:has(#lojas-page) #lojasSugestoes {
    top: 176px;
    left: 370px;
    width: min(720px, calc(100vw - 690px));
    justify-content: flex-start;
    transform: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; animation: none !important; }
}

/* Inventory collection selector: larger set artwork and cleaner card hierarchy. */
body #wishlist-page .wishlist-collection-filter {
  flex: 0 0 184px;
  min-height: 76px;
  grid-template-columns: 54px minmax(0,1fr);
  grid-template-rows: auto auto;
  column-gap: 10px;
  row-gap: 2px;
  padding: 8px 10px;
}
body #wishlist-page .wishlist-collection-all,
body #wishlist-page .wishlist-collection-logo {
  grid-row: 1 / 3;
  width: 54px;
  height: 54px;
  border-radius: 6px;
  background: #f3f6f8;
}
body #wishlist-page .wishlist-collection-logo img { width: 100%; height: 100%; padding: 4px; object-fit: contain; }
body #wishlist-page .wishlist-collection-filter strong { align-self: end; font-size: 12px; line-height: 1.15; }
body #wishlist-page .wishlist-collection-stats { align-self: start; font-size: 9px; line-height: 1.25; }

/* Quick profile: username + explicit link to the full profile page. */
.quick-profile-user { grid-template-columns: 58px minmax(0,1fr) auto; cursor: default; }
.quick-profile-user-name { align-self: center; }
.quick-profile-page-link {
  display: inline-flex;
  min-height: 38px;
  align-items: center;
  gap: 5px;
  padding: 0 10px 0 12px;
  border: 1px solid var(--ow-line);
  border-radius: 999px;
  background: #fff;
  color: var(--ow-ink);
  font-size: 11px;
  font-weight: 850;
  text-decoration: none;
  white-space: nowrap;
}
.quick-profile-page-link:hover { border-color: var(--ow-orange); color: var(--ow-orange-dark); }
.quick-profile-page-link svg { width: 15px; height: 15px; }

@media (max-width: 620px) {
  body #wishlist-page .wishlist-collection-filter { flex-basis: 166px; min-height: 70px; grid-template-columns: 48px minmax(0,1fr); }
  body #wishlist-page .wishlist-collection-all,
  body #wishlist-page .wishlist-collection-logo { width: 48px; height: 48px; }
}

/* Interaction fix: the masthead itself ignores pointer events, so the community
   drawer/iframe must opt back in explicitly. */
.galar-masthead .galar-social-menu,
.galar-masthead .galar-social-menu-overlay,
.galar-masthead .galar-community-frame {
  pointer-events: auto !important;
}

/* Let profile photos fill the avatar cell instead of looking like a tiny icon. */
.galar-top-profile img {
  padding: 0 !important;
  object-fit: cover !important;
  object-position: center !important;
}

@media (min-width: 761px) {
  body.home-page .galar-top-profile {
    height: 42px !important;
    min-height: 42px !important;
    grid-template-columns: 42px minmax(104px, 144px) !important;
  }
  body.home-page .galar-top-profile img {
    width: 42px !important;
    height: 42px !important;
    flex-basis: 42px !important;
    padding: 0 !important;
  }
  body.home-page .galar-top-profile span {
    padding: 0 14px !important;
    font-size: 10px !important;
  }
  body.home-page .galar-top-icon {
    width: 42px !important;
    height: 42px !important;
  }
}

