/* Layout refinements only: existing palette and brand typography are preserved. */
html { scroll-padding-top: 88px; }
body :is(button, input, select, textarea, a):focus-visible {
  outline: 3px solid var(--tl-primary); outline-offset: 3px;
}
body :is(button, .btn, .btn-small) { min-height: 40px; touch-action: manipulation; }
body :is(input, select, textarea) { min-height: 44px; }
body :is(.stat-card, .value-card, .winner-card, .market-card, .auth-card, .login-card) {
  border-radius: 18px !important;
}
body :is(.stat-card-value, .wallet-amount, .price, .balance) { font-variant-numeric: tabular-nums; }
body :is(.section, .legal-copy) p { max-width: 75ch; line-height: 1.85; }
body .table-wrap { overflow-x: auto; overscroll-behavior-x: contain; }
body table :is(th,td) { padding: 16px 18px; vertical-align: top; }
body .sidebar button.nav-item { width: 100%; text-align: left; font: inherit; }
body .sidebar { overflow-y: auto; }
body .review-toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin: 22px 0; }
body .review-toolbar input { flex: 1 1 220px; min-width: 0; padding: 10px 14px; border-radius: 10px; }
body #page-golden-winners td { white-space: pre-line; overflow-wrap: anywhere; min-width: 175px; }
body #page-golden-winners td:nth-child(4) { min-width: 220px; max-width: 320px; }
body #page-golden-winners :is(th,td):last-child { position: static; box-shadow: none; }
body #admin-sync-status { border: 1px solid var(--tl-line); border-radius: 12px; padding: 14px 18px; margin-bottom: 12px; }
body #admin-refresh-data { margin-bottom: 22px; }
body .section-sync-notice:not(:empty) { padding: 14px; border: 1px solid var(--tl-line); border-radius: 10px; }
@media (max-width: 640px) {
  body #app.visible { display: block !important; height: auto !important; }
  body .sidebar { position: static !important; width: 100% !important; height: auto !important; max-height: none !important; }
  body .sidebar-section { display: grid !important; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 6px; padding: 10px !important; overflow: visible !important; }
  body .sidebar-section-label { grid-column: 1 / -1; }
  body .sidebar .nav-item { min-width: 0 !important; width: 100% !important; white-space: normal !important; padding: 10px !important; }
  body .sidebar-footer { display: flex !important; gap: 12px; padding: 12px !important; }
  body #page-golden-winners { padding-bottom: 90px; }
  body :is(input, select, textarea) { font-size: 16px !important; }
  body :is(.login-card, .auth-card) { padding: 26px 20px !important; }
  body table :is(th,td) { padding: 12px; }
  body .review-toolbar { gap: 10px; }
  body .review-toolbar label { flex-basis: 100%; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto !important; }
  body *, body *::before, body *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; animation-iteration-count: 1 !important; }
}
