/* UFAATK · black / vivid yellow-gold, inspired by ufabomb5.com.
   Paint-only layer: UFAPUNG dimensions, layout and responsive rules are retained. */
html {
  color-scheme: dark;
  accent-color: #ffe447;
  scrollbar-color: #a08028 #090909;
  --pc-gold-grad: linear-gradient(115deg, #e8ae36 0%, #fff56c 40%, #ffe447 66%, #e8ae36 100%);
  --pc-coin: linear-gradient(135deg, #fff99a 0%, #ffe447 52%, #dca52b 100%);
  --pc-wallet: linear-gradient(135deg, #2a2510 0%, #19180f 42%, #11110d 100%);
}
html body[data-page] {
  background-color: #090909;
  background-image:
    linear-gradient(126deg, #efb21f2b 0%, #efb21f2b 9%, transparent 9.1%, transparent 87%, #efb21f24 87.1%),
    linear-gradient(54deg, transparent 70%, #efb21f14 70.1%, transparent 84%),
    radial-gradient(ellipse at 0% 35%, #e3a80030, transparent 48%),
    radial-gradient(ellipse at 100% 95%, #efb21f2b, transparent 45%);
  background-attachment: fixed;
}
html ::selection { background: #ffe447; color: #131105; }
html header > div.bg-card\/90 { background: #090909f5; border-color: #806b26; }
html header button[aria-label="เปิดเมนู"] { color: #ffe447; }
html body[data-page] .mos-announcement {
  background: linear-gradient(90deg, #131105, #30270c 50%, #131105);
  border-color: #a08028;
}
html .foil-frame { box-shadow: inset 0 0 0 1px #b08b29; }
html [data-slot="card"].bg-felt.border-gold-2 { border-color: #a08028; }
html .rounded-2xl.bg-secondary { background: #111214; }
html body[data-page] .mos-shortcut {
  --mos-shortcut-surface: radial-gradient(ellipse 55% 65% at 50% 118%, #ffbd2636 0%, #ef961514 34%, transparent 68%), #08090b;
  background: #08090b;
  border-color: #806b26;
}
@supports (background: radial-gradient(in oklab, white, black)) {
  html body[data-page] .mos-shortcut {
    --mos-shortcut-surface: radial-gradient(ellipse 55% 65% at 50% 118% in oklab, #ffbd2636 0%, #ef961514 34%, transparent 68%), #08090b;
  }
}
/* Stronger yellow-orange coin edge; keep the original size, position and motion. */
html body[data-page] .mos-shortcut::before {
  border-color: #ffd43d;
  background: linear-gradient(145deg, #fff082 0%, #ffc526 36%, #f3a515 70%, #dc800e 100%);
  background: linear-gradient(145deg in oklab, #fff082 0%, #ffc526 36%, #f3a515 70%, #dc800e 100%);
  box-shadow: inset 0 0 0 3px #ffc52d99, inset 0 2px 3px #fff5bd80, 0 0 22px #ffad2030;
}
html body[data-page] .mos-shortcut::after { border-color: #a65a10; }
html body[data-page] .mos-shortcut-label { color: #ffffff; }
html body[data-page] .mos-hero-border-base { stroke: #e8c03a; }
html body[data-page] .mos-play-token--play { background: var(--pc-coin); color: #131105; }
html input[data-slot="input"], html select, html textarea { border-color: #847644; }
html input::placeholder { color: #aaa798; }
html input[data-slot="input"]:focus-visible { border-color: #ffe447; outline: 2px solid #ffe447; outline-offset: 2px; }
html footer.bg-felt {
  background: #090a0b;
  border-color: #806b26;
}
html nav[aria-label="เมนูด่วน"] { background: #0c0c09fa; border-color: #a08028; }
/* Readability on the warm background: white copy, yellow-led emphasis.
   Color-only changes; native disabled states and dark text on light buttons stay intact. */
@media (forced-colors: none) {
  html[data-theme].dark, html[data-theme] {
    --foreground: #ffffff;
    --card-foreground: #ffffff;
    --popover-foreground: #ffffff;
    --secondary-foreground: #ffffff;
    --accent-foreground: #ffffff;
    --muted-foreground: #f2f2ed;
    --pc-ivory: #ffffff;
    --pc-silver: #f7f7f2;
    --pc-grey: #f2f2ed;
    --mos-type-muted: #f2f2ed;
    --mos-ui-muted: #f2f2ed;
    --brand: #ffe35a;
    --pc-gold: #ffe35a;
    --pc-gold-light: #ffed91;
    --pc-gold-value: #ffe35a;
    --card: #0b0c0e;
    --popover: #0b0c0e;
    --secondary: #111214;
    --muted: #111214;
    --accent: #151619;
    --felt: #0b0c0e;
    --felt-1: #111214;
    --felt-2: #191b1e;
    --pc-surface: #0b0c0e;
    --pc-surface-2: #111214;
  }
  html body[data-page] main :is([data-slot="card"].bg-felt, [data-slot="card"].bg-hero, .foil-frame > div.bg-felt) { background: #090a0c; }
  html body[data-page] .profile-v2 :is(.pv-card:not(.pv-member), .pv-service) { background: #0a0b0d; }
  html body[data-page="wheel"] .mos-wheel-card { background: #090a0c; }
  html body[data-page] input::placeholder,
  html body[data-page] .mos-field::placeholder { color: #e4e4dd; opacity: 1; }
  html body[data-page] main .text-foil.tabular-nums {
    color: var(--pc-gold-value);
    -webkit-text-fill-color: var(--pc-gold-value);
  }
  html body[data-page] main .rounded-2xl.bg-secondary .font-deco.text-brand { color: var(--pc-gold-value); }
  html body[data-page] :is(.mos-shortcut-label, .mos-shortcut-text, .mos-announcement-item),
  html body[data-page] .mos-shortcut:is(:hover, :focus-visible, :active, .mos-is-pressed) .mos-shortcut-text { color: #ffffff; }
  html body[data-page] .profile-v2 :is(.pv-tier, .pv-metric dd) { color: var(--pc-gold-value); }
  html body[data-page] .profile-v2 :is(.pv-balance small, .pv-joined time) { color: var(--pc-grey); }
  html body[data-page="wheel"] :is(
    .mos-wheel-balance, .mos-wheel-note, .mos-wheel-result-caption,
    .mos-wheel-prize-count, .mos-wheel-prize-item,
    .mos-wheel-history-heading span, .mos-wheel-history-empty,
    .mos-wheel-history-list li, .mos-wheel-history-list time, .mos-wheel-demo-tag
  ) { color: var(--pc-grey); }
  html body[data-page="wheel"] .mos-wheel-prize-item.is-winner { color: var(--pc-gold-light); }
}
/* Gradient text/frames remain readable when the OS removes author backgrounds. */
@media (forced-colors: active) {
  html {
    --pc-bg: Canvas; --pc-surface: Canvas; --pc-surface-2: Canvas;
    --pc-ivory: CanvasText; --pc-grey: CanvasText; --pc-silver: CanvasText;
    --pc-gold: LinkText; --pc-gold-light: LinkText; --pc-gold-value: CanvasText;
    --pc-line: ButtonText; --pc-line-gold: ButtonText; --pc-on-gold: ButtonText;
  }
  html body[data-page] .text-foil { background: none; color: CanvasText; -webkit-text-fill-color: CanvasText; }
  html body[data-page] :is(.foil-frame, .bg-foil, .bg-gold-grad, .chip) { outline: 1px solid ButtonText; }
  html body[data-page] a[aria-current="page"] { outline: 2px solid Highlight; }
  html body[data-page] input[data-slot="input"]:focus-visible { outline-color: Highlight; }
}
