:root{--kb-font-stack:system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI Variable Text", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;--kb-text-scale:1.10}
html{font-size:calc(16px * var(--kb-text-scale,1.10))}
body,button,input,select,textarea,optgroup{font-family:var(--kb-font-stack,"Segoe UI",system-ui,sans-serif)!important}
body{font-size:1rem!important;line-height:1.62!important;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased}
p,li,dd,dt,td,th,label,.gv-subtle,.breadcrumb{line-height:1.58}
.form-control,input:not([type=checkbox]):not([type=radio]):not([type=color]),select,textarea{font-size:.92rem!important;line-height:1.45!important}
.form-label{font-size:.88rem!important;line-height:1.4!important}
.btn-gold,.btn-accent,.btn-ghost,button{font-size:.88rem}
.alert{font-size:.9rem!important;line-height:1.55!important}
.page-header h1,.gv-page-head h1{font-size:clamp(1.7rem,3vw,2.35rem)!important}
.page-header p,.gv-page-head p{font-size:.98rem!important;line-height:1.65!important}
.stat-card-label,.stat-card-change,.gv-subtle{font-size:.82rem!important}
small{font-size:.78rem}
.page-admin .sidebar-nav-item,.page-dashboard .sidebar-nav-item,.page-support .sidebar-nav-item{font-size:.88rem!important}
.page-admin .sidebar-section,.page-dashboard .sidebar-section,.page-support .sidebar-section{font-size:.72rem!important}
.page-admin .kb-sidebar-search input{font-size:.86rem!important}
.dashboard-market-header,.kb-market-topbar,.navbar{font-size:.9rem}
.dash-main,.gv-page,.kb36-shell{font-size:1rem}
@media(max-width:700px){
 html{font-size:calc(15.5px * var(--kb-text-scale,1.10))}
 body{line-height:1.58!important}
 .form-control,input:not([type=checkbox]):not([type=radio]):not([type=color]),select,textarea{font-size:16px!important}
 .btn-gold,.btn-accent,.btn-ghost{min-height:42px}
}
small{font-size:.78rem!important;line-height:1.5!important}
.authv2-form-title{font-size:clamp(1.55rem,3vw,2rem)!important;line-height:1.2!important}
.authv2-form-sub,.authv2-switch,.authv2-terms{font-size:.9rem!important;line-height:1.55!important}
.authv2-field label,.authv2-tab,.authv2-link{font-size:.88rem!important}
.gv-card__meta,.gv-card__delivery{font-size:.78rem!important}
.gv-card__title{font-size:.94rem!important;line-height:1.42!important}
.gv-card__seller,.gv-card__rating{font-size:.8rem!important}
.kb36-card p,.kb36-section-head p,.kb50-other-card p{font-size:.9rem;line-height:1.58}
:where(.dash-main,.dash-sidebar,.gv-page,.kb36-dashboard) [style*="font-size:10px"]{font-size:.74rem!important}
:where(.dash-main,.dash-sidebar,.gv-page,.kb36-dashboard) [style*="font-size:11px"]{font-size:.78rem!important}
:where(.dash-main,.dash-sidebar,.gv-page,.kb36-dashboard) [style*="font-size:12px"]{font-size:.82rem!important}
:where(.dash-main,.dash-sidebar,.gv-page,.kb36-dashboard) [style*="font-size:13px"]{font-size:.88rem!important}
.page-admin .settings-section h3{font-size:1rem!important}
.page-admin .toggle-row label{font-size:.88rem!important}
@media(max-width:700px){.authv2-form-sub,.authv2-switch,.authv2-terms{font-size:.92rem!important}.gv-card__title{font-size:1rem!important}}

/* ═══════════════════════════════════════════════════════════════════════════
   v24.5 TYPOGRAPHY POLISH  — additive, purely presentational refinements.
   Everything below degrades gracefully: unknown properties (text-wrap,
   font-feature-settings) are simply ignored by browsers that don't support
   them, so nothing breaks on older clients.
   ═══════════════════════════════════════════════════════════════════════════ */

/* Crisper rendering on every platform (webkit smoothing was already set;
   this adds the Firefox/macOS equivalent and enables real kerning + common
   ligatures so words look typeset rather than mono-spaced-ish). */
html{-moz-osx-font-smoothing:grayscale;text-size-adjust:100%}
body{font-kerning:normal;font-feature-settings:"kern" 1,"liga" 1,"calt" 1}

/* Headings: tighter optical tracking at large sizes reads as more premium,
   and balanced wrapping stops the lonely one-word last line. */
h1,h2,h3,.section-title,.page-header h1,.gv-page-head h1,
.gv-profile-page-head h1,.gv-profile-name-row h2,.authv2-form-title,
.gv-profile-card-head h3,.hero h1{
  text-wrap:balance;
  letter-spacing:-.011em;
}
.hero h1,.page-header h1,.gv-page-head h1,.gv-profile-page-head h1,.authv2-form-title{
  letter-spacing:-.022em;
}

/* Body copy: "pretty" wrapping avoids typographic orphans/rivers without
   changing a single measured font-size. */
p,li,dd,.gv-subtle,.gv-profile-identity-summary>p,.authv2-form-sub{
  text-wrap:pretty;
}

/* Numbers that sit in columns or update live (prices, balances, stats, counts)
   look wrong when digits jump width. Tabular figures lock them to a grid. */
.stat-card-num,.hero-stat-num,.gv-profile-stat-grid strong,
.summary-row strong,.summary-total strong,.checkout-product strong,
.account-highlight strong,[data-username-display],.kb-sidebar-badge,
.gv-profile-completion strong,.gv-profile-progress+*{
  font-variant-numeric:tabular-nums;
  font-feature-settings:"kern" 1,"tnum" 1;
}

/* Long unbroken strings (usernames, game names, order refs) must never force a
   horizontal scrollbar or overflow their card. */
.gv-card__title,.gv-profile-name-row h2,.checkout-product-title,
.gv-profile-stat-grid strong,td,.breadcrumb{
  overflow-wrap:anywhere;
}

/* Slightly more generous leading in the two places users read the most text:
   listing descriptions and bios. */
.gv-profile-bio,.listing-description,.gv-prose,.support-message-body{
  line-height:1.66;
}
