@import url("https://fonts.googleapis.com/css2?family=Chakra+Petch:wght@500;600;700&display=swap");   /* ฟอนต์ตัวเลข — ไฟล์ฟอนต์โหลดเฉพาะตอนมีข้อความใช้ (ธีมใหม่เปิด) */
/* theme_new.css — ธีมทดลอง "PUCHI//CORE" (2026-11-12 ผู้ใช้ขอ: UI ให้มีเอกลักษณ์ของเกม) — ตอนนี้หน้าแรกเท่านั้น
   เปิด: /?theme=new (จำใน localStorage ui.theme) · ปิด: /?theme=old — ผู้เล่นไม่เห็นถ้าไม่เปิดเอง
   ทุกหน้าเมนูลิงก์ไฟล์นี้ต่อจาก nav.css + สคริปต์ inline ตั้ง class theme-new (ชุดเดียวกันทุกหน้า)
   มุมตัดเขียน polygon ตรงในแต่ละกฎ (ห้ามทำเป็นตัวแปรที่ html — var(--c) ถูกแทนค่าที่ html ซึ่งไม่มี --c → clip-path ใช้ไม่ได้)
   ทุกกฎอยู่ใต้ html.theme-new · โหลดหลัง <style> ของหน้า + nav.css จึงทับได้
   ภาษาภาพ: มุมตัดเฉียงทิศเดียวกับ "//" (ซ้ายบน + ขวาล่าง), ขายึดมุม HUD สีส้ม (ขวาบน + ซ้ายล่าง), หัวข้อขึ้นต้น //,
     ตัวเลข (พลังรบ เหรียญ อันดับ) ใช้ Chakra Petch (เหลี่ยมแบบเทค มีภาษาไทย) — ความน่ารัก: ขอบบนสว่างแบบสติกเกอร์ + ปุ่มยุบเด้ง */
html.theme-new {
  --cut: 20px;                                  /* ขนาดมุมตัดของการ์ด */
  --cut-btn: 8px;
  --frame: #46557a;                              /* เส้นขอบการ์ด (สว่างกว่า --line เดิมนิดหน่อย — มุมตัดต้องเห็นชัด) */
  --font-num: "Chakra Petch", "Kanit", system-ui, sans-serif;
}

/* ---------- การ์ด (.panel + การ์ดรายชื่อ li.card ของหน้าคู่ต่อสู้/ถูกโจมตี): มุมตัด + ขอบ + ขายึดมุม HUD ---------- */
/* ขอบจริงวาดด้วย ::before (สีขอบ) + ::after (พื้นการ์ด inset 1px) ตัดด้วย clip-path ชุดเดียวกัน — border ปกติถูก clip-path ตัดหายที่มุม */
html.theme-new :is(.panel, li.card, section.player) { --c: var(--cut); position: relative; isolation: isolate; border-color: transparent; background: none; border-radius: 0; }
html.theme-new :is(.panel, li.card, section.player)::before, html.theme-new :is(.panel, li.card, section.player)::after { content: ""; position: absolute; z-index: -1; pointer-events: none; clip-path: polygon(var(--c) 0, 100% 0, 100% calc(100% - var(--c)), calc(100% - var(--c)) 100%, 0 100%, 0 var(--c)); }
html.theme-new :is(.panel, li.card, section.player)::before { inset: 0;
  background:
    /* ขายึดมุม HUD: ขวาบน + ซ้ายล่าง (มุมที่ไม่ได้ตัด) */
    linear-gradient(var(--ui-accent, var(--torch)), var(--ui-accent, var(--torch))) top right / 30px 3px no-repeat,
    linear-gradient(var(--ui-accent, var(--torch)), var(--ui-accent, var(--torch))) top right / 3px 30px no-repeat,
    linear-gradient(var(--ui-accent, var(--torch)), var(--ui-accent, var(--torch))) bottom left / 30px 3px no-repeat,
    linear-gradient(var(--ui-accent, var(--torch)), var(--ui-accent, var(--torch))) bottom left / 3px 30px no-repeat,
    /* เส้นมุมตัดสีส้มจาง */
    linear-gradient(135deg, var(--ui-accent, var(--torch)) calc(var(--c) * .7071 + 1.5px), transparent 0) top left / calc(var(--c) * 2) calc(var(--c) * 2) no-repeat,
    linear-gradient(315deg, var(--ui-accent, var(--torch)) calc(var(--c) * .7071 + 1.5px), transparent 0) bottom right / calc(var(--c) * 2) calc(var(--c) * 2) no-repeat,
    var(--frame); }
html.theme-new :is(.panel, li.card, section.player)::after { --c: calc(var(--cut) - 1px); inset: 1.5px;
  background-size: 100% 70px, auto, auto, auto; background-repeat: no-repeat, repeat, repeat, repeat; background-position: 0 -70px, 0 0, 0 0, 0 0;
  background-image:
    linear-gradient(to bottom, transparent, rgba(var(--holo-rgb), .16) 70%, rgba(var(--holo-rgb), .45) 96%, transparent),   /* เส้นสแกนตอนบูต (เลื่อนด้วย bootScan) */
    linear-gradient(to bottom, rgba(255, 255, 255, .05), transparent 28px),       /* ขอบบนสว่างแบบสติกเกอร์ */
    repeating-linear-gradient(-45deg, transparent 0 14px, rgba(255, 255, 255, .012) 14px 15px),   /* ลายขีดเฉียง // จางมาก */
    linear-gradient(color-mix(in srgb, color-mix(in srgb, var(--panel), #3a4565 32%) 92%, transparent), color-mix(in srgb, color-mix(in srgb, var(--panel), #3a4565 32%) 92%, transparent)); }   /* พื้นการ์ดสว่างกว่า --panel เล็กน้อย (2026-11-12 ผู้ใช้ขอ) */

/* ---------- แอนิเมชันบูต (ข้อ 5, 2026-11-12): การ์ดเลื่อนเข้า + เส้นสแกนวิ่งผ่านจากบนลงล่าง ตอนการ์ดแสดงขึ้นมา ----------
   เล่นทุกครั้งที่การ์ดเริ่มแสดง (hidden → แสดง / สร้างใหม่ / ย้ายที่ใน DOM) — #statsPanel ของโรงเก็บย้ายที่ทุกครั้งที่เลือกแท็บ จึงยกเว้น
   ใช้ translate (ไม่ใช่ transform) — ไม่ชนกับ transform ที่หน้าอื่นใช้ · การ์ดรายชื่อไล่ทีละใบ 40ms */
html.theme-new :is(.panel, li.card, section.player):not([id="statsPanel"]) { animation: bootIn .34s cubic-bezier(.2, .8, .2, 1) both; }
html.theme-new :is(.panel, li.card, section.player):not([id="statsPanel"])::after { animation: bootScan .6s ease-out .06s both; }
/* แผงค่าพลังโรงเก็บ: เล่นเฉพาะตอนเปิดหน้า (hangar.html ใส่ .boot แล้วถอดหลัง 0.9 วินาที) */
html.theme-new #statsPanel.boot { animation: bootIn .34s cubic-bezier(.2, .8, .2, 1) both; }
html.theme-new #statsPanel.boot::after { animation: bootScan .6s ease-out .06s both; }
html.theme-new li.card:nth-child(2) { animation-delay: 40ms; } html.theme-new li.card:nth-child(3) { animation-delay: 80ms; }
html.theme-new li.card:nth-child(4) { animation-delay: 120ms; } html.theme-new li.card:nth-child(5) { animation-delay: 160ms; }
html.theme-new li.card:nth-child(6) { animation-delay: 200ms; } html.theme-new li.card:nth-child(n + 7) { animation-delay: 240ms; }
@keyframes bootIn { from { opacity: 0; translate: -10px 0; } 60% { opacity: 1; } to { opacity: 1; translate: 0 0; } }
@keyframes bootScan { from { background-position: 0 -70px, 0 0, 0 0, 0 0; } to { background-position: 0 calc(100% + 70px), 0 0, 0 0, 0 0; } }

/* ---------- หัวข้อ: // นำหน้า ---------- */
html.theme-new h2 { font-family: var(--font-num); font-weight: 600; letter-spacing: .01em; }
/* "//" หัวการ์ด: "/" แรกชมพู "/" หลังฟ้า แบบโลโก้/ชื่อหน้า (2026-11-12 ผู้ใช้ขอ) — ไล่สีตัดครึ่งแล้วตัดตามตัวอักษร */
html.theme-new h2::before { content: "//"; margin-right: 8px; font-weight: 700; letter-spacing: -.08em; padding-right: .08em;
  background: linear-gradient(90deg, #ff6ad5 50%, #5cc8ff 50%); -webkit-background-clip: text; background-clip: text; color: transparent; -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 0 6px rgba(200, 120, 255, .45)); }

/* ---------- ปุ่ม: มุมตัด + ยุบเด้งตอนกด ---------- */
html.theme-new :is(button, .btn):not(.nav-link, .setbtn, .evt, .ab-go, .ab-x, .x, .slotarrow, .facebtn, .pickClose, .vclose, .pin, .wbpin, .hit, .evt-dots *, .tapStart *, .tuner, .npc, .smk, .bang, .vn *, .isle-mg *, .viewsw, .viewsw *, .dicon) { --c: var(--cut-btn); border-radius: 0; clip-path: polygon(var(--c) 0, 100% 0, 100% calc(100% - var(--c)), calc(100% - var(--c)) 100%, 0 100%, 0 var(--c));
  transition: transform .08s ease, filter .15s ease; }
html.theme-new :is(button, .btn):not(.nav-link, .setbtn, .evt, .ab-go, .ab-x, .x, .slotarrow, .facebtn, .pickClose, .vclose, .pin, .wbpin, .hit, .evt-dots *, .tapStart *, .tuner, .npc, .smk, .bang, .vn *, .isle-mg *, .viewsw, .viewsw *, .dicon):active { transform: translateY(1px) scale(.97); }
html.theme-new .primary { background: linear-gradient(to bottom, color-mix(in srgb, #fff 18%, var(--ui-accent, var(--torch))), var(--ui-accent, var(--torch)) 55%);
  font-family: var(--font-num); font-weight: 700; letter-spacing: .02em; }
/* ปุ่มมุมตัดแล้ว focus ring ถูกตัดด้วย → ใช้เงาด้านในแทน */
html.theme-new :is(button, .btn):not(.nav-link, .setbtn, .evt, .ab-go, .ab-x, .x, .slotarrow, .facebtn, .pickClose, .vclose, .pin, .wbpin, .hit, .evt-dots *, .tapStart *, .tuner, .npc, .smk, .bang, .vn *, .isle-mg *, .viewsw, .viewsw *, .dicon):focus-visible { outline: none; box-shadow: inset 0 0 0 2px var(--ui-accent, var(--torch)); }

/* ช่องกรอก: มุมตัดเล็ก */
html.theme-new :is(input:not([type="checkbox"]):not([type="radio"]), select) { --c: 6px; border-radius: 0; clip-path: polygon(var(--c) 0, 100% 0, 100% calc(100% - var(--c)), calc(100% - var(--c)) 100%, 0 100%, 0 var(--c)); }
html.theme-new input:focus-visible { outline: none; box-shadow: inset 0 0 0 2px var(--ui-accent, var(--torch)); }

/* ---------- ตัวเลข: พลังรบเป็นพระเอก ---------- */
html.theme-new .dash .cp { display: grid; grid-template-columns: auto 1fr; column-gap: 8px; align-items: baseline; color: var(--muted); font-size: 13px; letter-spacing: .04em; }
html.theme-new .dash .cp::after { content: "COMBAT POWER"; font-family: var(--font-num); font-size: 10.5px; font-weight: 600;
  letter-spacing: .28em; color: color-mix(in srgb, var(--ui-accent, var(--torch)) 75%, var(--muted)); }
html.theme-new .dash .cp b { grid-column: 1 / -1; order: 1; margin: 0; font-family: var(--font-num); font-weight: 700; font-size: clamp(34px, 7vw, 48px); line-height: 1.05;
  color: #ffd08a; letter-spacing: .02em;
  text-shadow: 0 0 18px color-mix(in srgb, var(--ui-accent, var(--torch)) 55%, transparent), 0 2px 0 #6b3a06; }
html.theme-new .dash .cp b::before { content: "▸ "; font-size: .45em; vertical-align: .55em; color: var(--ui-accent, var(--torch)); text-shadow: none; }
html.theme-new .dash .pname { font-family: var(--font-num); font-weight: 700; letter-spacing: .01em; }
html.theme-new .dash .meta b, html.theme-new .lb .val b { font-family: var(--font-num); font-weight: 700; }
html.theme-new .num-pop { animation: numPop .5s ease-out; }
@keyframes numPop { 0% { filter: brightness(1.8); } 100% { filter: none; } }

/* เวทีไฟเตอร์ในแดชบอร์ด: กรอบเล็ง HUD 4 มุม + เส้นสแกนจาง */
html.theme-new .dash .scene { position: relative; }
html.theme-new .dash .scene::after { content: ""; position: absolute; inset: 4px; pointer-events: none;
  --hud: color-mix(in srgb, var(--team-b) 70%, transparent);
  background:
    linear-gradient(var(--hud), var(--hud)) top left / 14px 1.5px no-repeat, linear-gradient(var(--hud), var(--hud)) top left / 1.5px 14px no-repeat,
    linear-gradient(var(--hud), var(--hud)) top right / 14px 1.5px no-repeat, linear-gradient(var(--hud), var(--hud)) top right / 1.5px 14px no-repeat,
    linear-gradient(var(--hud), var(--hud)) bottom left / 14px 1.5px no-repeat, linear-gradient(var(--hud), var(--hud)) bottom left / 1.5px 14px no-repeat,
    linear-gradient(var(--hud), var(--hud)) bottom right / 14px 1.5px no-repeat, linear-gradient(var(--hud), var(--hud)) bottom right / 1.5px 14px no-repeat,
    repeating-linear-gradient(to bottom, rgba(var(--holo-rgb), .05) 0 1px, transparent 1px 4px); }

/* ---------- ป้ายอีเวนท์: มุมตัดแบบเดียวกัน (ขอบเดิมสีม่วงถูกตัดที่มุม — ใช้เงาด้านในแทน) ---------- */
html.theme-new .evt { --c: var(--cut); border-radius: 0; border-color: transparent; clip-path: polygon(var(--c) 0, 100% 0, 100% calc(100% - var(--c)), calc(100% - var(--c)) 100%, 0 100%, 0 var(--c)); box-shadow: inset 0 0 0 1px #b04dff88; }

/* ---------- ตารางอันดับ ---------- */
html.theme-new .lb .lbtabs button { --c: 7px; border-radius: 0; }
html.theme-new .lb .lblist li { --c: 7px; border-radius: 0; clip-path: polygon(var(--c) 0, 100% 0, 100% calc(100% - var(--c)), calc(100% - var(--c)) 100%, 0 100%, 0 var(--c)); }
html.theme-new .lb .lblist li.me { box-shadow: inset 3px 0 0 var(--ui-accent, var(--torch)); }
html.theme-new .lb .lblist li.gap { clip-path: none; }
html.theme-new .lb .rk { font-family: var(--font-num); font-style: italic; }
html.theme-new .lb .lblist li:nth-child(1) .rk { color: #ffd25a; }
html.theme-new .lb .lblist li:nth-child(2) .rk { color: #d6dde8; }
html.theme-new .lb .lblist li:nth-child(3) .rk { color: #e3a26b; }

/* ---------- เช็คอินรายวัน: ช่องวันมุมตัด ---------- */
html.theme-new #dashCheckin .hd b { font-family: var(--font-num); }

/* ---------- แถบเมนูหลัก (nav.css) ---------- */
html.theme-new nav.bnav { --c: 12px; border-radius: 0; clip-path: polygon(var(--c) 0, 100% 0, 100% calc(100% - var(--c)), calc(100% - var(--c)) 100%, 0 100%, 0 var(--c)); }
html.theme-new nav.bnav .nav-link { --c: 7px; border-radius: 0; clip-path: polygon(var(--c) 0, 100% 0, 100% calc(100% - var(--c)), calc(100% - var(--c)) 100%, 0 100%, 0 var(--c)); }
@media (max-width: 640px) { html.theme-new nav.bnav { clip-path: none; } }   /* มือถือ: แถบเต็มความกว้างติดขอบล่าง ไม่ตัดมุม */

/* จูนเนอร์พูด (ข้อ 3, 2026-11-12) — กล่องคำพูดเต็มแถวใต้ฉาก หางชี้ขึ้นไปที่จูนเนอร์ (index.html #dashTalk, tuner_talk.mjs) */
html.theme-new .dash > .talk { grid-column: 1 / -1; justify-self: start; width: min(100%, 640px); box-sizing: border-box; position: relative; display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 4px 12px;
  margin-top: 2px; padding: 10px 14px 11px; cursor: pointer; background: color-mix(in srgb, #7fd6ff 9%, var(--panel-2, #1a2030));
  border: 1px solid color-mix(in srgb, #7fd6ff 45%, var(--frame));
  clip-path: polygon(10px 0, 100% 0, 100% calc(100% - 10px), calc(100% - 10px) 100%, 0 100%, 0 10px); }
html.theme-new .dash > .talk::before { content: ""; position: absolute; top: -1px; left: calc(min(300px, 40%) * .15 + 4px); width: 14px; height: 2px;
  background: #7fd6ff; box-shadow: 0 0 8px #7fd6ff; }   /* หางเป็นแถบเรืองที่ขอบบน ตรงกับจูนเนอร์ (clip-path ตัดหางสามเหลี่ยมที่ยื่นออกนอกกล่อง) */
html.theme-new .dash > .talk[data-k="attacked"], html.theme-new .dash > .talk[data-k="hpLow"] { border-color: color-mix(in srgb, #ff6a5a 55%, var(--frame)); background: color-mix(in srgb, #ff6a5a 9%, var(--panel-2, #1a2030)); }
html.theme-new .dash > .talk:is([data-k="attacked"], [data-k="hpLow"])::before { background: #ff6a5a; box-shadow: 0 0 8px #ff6a5a; }
html.theme-new .talk .tk-who { grid-column: 1 / -1; font-family: var(--font-num); font-size: 10.5px; font-weight: 600; letter-spacing: .16em; color: #7fd6ff; }
html.theme-new .talk .tk-who::before { content: "// "; opacity: .6; }
html.theme-new .talk:is([data-k="attacked"], [data-k="hpLow"]) .tk-who { color: #ff8a7a; }
html.theme-new .talk .tk-text { margin: 0; font-size: 14.5px; line-height: 1.45; color: var(--fg); }
html.theme-new .talk .tk-cta { justify-self: end; white-space: nowrap; font-size: 13px; font-weight: 600; color: var(--ui-accent, var(--torch)); text-decoration: none; padding: 4px 2px; }
html.theme-new .talk .tk-cta::after { content: " ›"; }
html.theme-new .talk .tk-cta:hover { text-decoration: underline; }
html.theme-new .talk.pop .tk-text { animation: talkIn .28s ease-out; }
html.theme-new #dashPilot { cursor: pointer; }
@keyframes talkIn { from { opacity: 0; translate: 0 4px; } to { opacity: 1; translate: 0 0; } }
@media (max-width: 640px) { html.theme-new .talk .tk-text { font-size: 13.5px; } }

@media (prefers-reduced-motion: reduce) {
  html.theme-new :is(.panel, li.card, section.player), html.theme-new :is(.panel, li.card, section.player)::after { animation: none; }
  html.theme-new #statsPanel.boot, html.theme-new #statsPanel.boot::after { animation: none; }
  html.theme-new .num-pop { animation: none; }
  html.theme-new .talk.pop .tk-text { animation: none; }
  html.theme-new :is(button, .btn):active { transform: none; }
}

/* ======================================================================================
   ธีมสีเงิน = มาตรฐาน (2026-11-12 ผู้ใช้กำหนด หลังลอง) — html.theme-new.ui-silver · ไม่มีค่า ui.accent = เงิน · ?accent=orange กลับส้ม (จำ "orange") · ?accent=silver ล้างค่า
   สีเน้นส้ม (--torch) → เงิน: ทุกที่ที่ใช้ var(--torch) (ปุ่มหลัก เมนูหน้าปัจจุบัน ขายึดมุม หัวข้อ //) กลายเป็นเงินเอง
   + ขอบการ์ดไล่เฉดโลหะ + ปุ่มหลักโลหะขัดเงา + พลังรบตัวอักษรเงินไล่เฉด
   ====================================================================================== */
html.theme-new.ui-silver {
  --torch: #c9d2de; --ui-accent: #c9d2de;   /* --ui-accent = สีเน้นของกรอบ/ปุ่ม UI — arena คืน --torch เป็นส้ม (เอฟเฟกต์ต่อสู้/หลอด HP) แต่ UI ยังเงิน */
  --frame: #5a6478;
  --silver-hi: #f5f8fc; --silver-mid: #aab4c3; --silver-lo: #6e7889;
}
/* ขอบการ์ด: โลหะไล่เฉด (สว่างบนซ้าย → เข้มล่างขวา) แทนสีขอบเรียบ */
html.theme-new.ui-silver :is(.panel, li.card, section.player)::before {
  background:
    linear-gradient(var(--silver-hi), var(--silver-hi)) top right / 30px 2px no-repeat,
    linear-gradient(var(--silver-hi), var(--silver-hi)) top right / 2px 30px no-repeat,
    linear-gradient(var(--silver-mid), var(--silver-mid)) bottom left / 30px 2px no-repeat,
    linear-gradient(var(--silver-mid), var(--silver-mid)) bottom left / 2px 30px no-repeat,
    linear-gradient(135deg, var(--silver-hi) calc(var(--c) * .7071 + 1.5px), transparent 0) top left / calc(var(--c) * 2) calc(var(--c) * 2) no-repeat,
    linear-gradient(315deg, var(--silver-mid) calc(var(--c) * .7071 + 1.5px), transparent 0) bottom right / calc(var(--c) * 2) calc(var(--c) * 2) no-repeat,
    linear-gradient(135deg, #9aa5b6, #4c5568 45%, #7d8899 70%, #3e4657); }
/* พื้นการ์ด: เทาอมน้ำเงินเย็นขึ้น + ประกายโลหะขอบบน */
html.theme-new.ui-silver :is(.panel, li.card, section.player)::after {
  background-image:
    linear-gradient(to bottom, transparent, rgba(220, 230, 245, .14) 70%, rgba(235, 242, 252, .4) 96%, transparent),
    linear-gradient(to bottom, rgba(220, 230, 245, .08), transparent 32px),
    repeating-linear-gradient(-45deg, transparent 0 14px, rgba(255, 255, 255, .016) 14px 15px),
    linear-gradient(color-mix(in srgb, color-mix(in srgb, var(--panel), #4a5266 38%) 92%, transparent), color-mix(in srgb, color-mix(in srgb, var(--panel), #4a5266 38%) 92%, transparent)); }
/* ปุ่มหลัก + เมนูหน้าปัจจุบัน: โลหะขัดเงา ตัวอักษรเข้ม */
html.theme-new.ui-silver .primary, html.theme-new.ui-silver nav.bnav .nav-link.current {
  background: linear-gradient(to bottom, var(--silver-hi), #d3dae4 45%, var(--silver-mid) 52%, #c8d0db);
  border-color: var(--silver-mid); color: #1b2130; text-shadow: 0 1px 0 rgba(255, 255, 255, .55); }
@media (max-width: 640px) { html.theme-new.ui-silver nav.bnav .nav-link.current { background: rgba(201, 210, 222, .14); color: var(--silver-hi); text-shadow: none; } }
/* h1 span (ส่วนเน้นในหัวหน้า) + ป้าย COMBAT POWER */
html.theme-new.ui-silver h1 span { background: linear-gradient(to bottom, var(--silver-hi), var(--silver-mid) 60%, #dfe5ee); -webkit-background-clip: text; background-clip: text; color: transparent; }
html.theme-new.ui-silver .dash .cp::after { color: var(--silver-mid); }
/* พลังรบ: ตัวอักษรเงินไล่เฉด + เงาเย็น */
html.theme-new.ui-silver .dash .cp b { background: linear-gradient(to bottom, #ffffff, #dfe5ee 40%, #97a2b3 55%, #e6ebf2); -webkit-background-clip: text; background-clip: text; color: transparent;
  text-shadow: none; filter: drop-shadow(0 0 10px rgba(200, 215, 235, .35)) drop-shadow(0 2px 0 #2c3342); }
html.theme-new.ui-silver .dash .cp b::before { -webkit-text-fill-color: var(--silver-mid); }
/* กล่องจูนเนอร์พูด: หางเงิน (สถานการณ์แดงยังแดง) */
html.theme-new.ui-silver .dash > .talk:not([data-k="attacked"], [data-k="hpLow"]) { border-color: color-mix(in srgb, var(--silver-mid) 55%, var(--frame)); background: color-mix(in srgb, #c9d2de 7%, var(--panel-2, #1a2030)); }
html.theme-new.ui-silver .dash > .talk:not([data-k="attacked"], [data-k="hpLow"])::before { background: var(--silver-hi); box-shadow: 0 0 8px var(--silver-mid); }
html.theme-new.ui-silver .talk:not([data-k="attacked"], [data-k="hpLow"]) .tk-who { color: var(--silver-mid); }

/* ---------- หน้า arena (2026-11-12 ผู้ใช้ขอ) — html.arena-page · --torch คืนเป็นส้มในหน้านี้ (สูตรสีกระสุน/หลอด HP 25–50%/ลูกไฟ) ---------- */
html.theme-new.arena-page.ui-silver { --torch: #f0a33a; }
/* ป้ายชื่อ + HP บนเวที: มุมตัด + ขอบโลหะจาง */
html.theme-new.arena-page .plate, html.theme-new.arena-page .turn { --c: 9px; border-radius: 0; clip-path: polygon(var(--c) 0, 100% 0, 100% calc(100% - var(--c)), calc(100% - var(--c)) 100%, 0 100%, 0 var(--c));
  border-color: color-mix(in srgb, var(--ui-accent, var(--torch)) 35%, var(--line)); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .08); }
html.theme-new.arena-page .plate .fname { font-family: var(--font-num); font-weight: 700; letter-spacing: .01em; }
html.theme-new.arena-page .role .cp, html.theme-new.arena-page .turn { color: var(--ui-accent, var(--torch)); font-family: var(--font-num); font-weight: 600; }
html.theme-new.arena-page .hpbar { --c: 4px; border-radius: 0; clip-path: polygon(var(--c) 0, 100% 0, 100% calc(100% - var(--c)), calc(100% - var(--c)) 100%, 0 100%, 0 var(--c)); }
/* ป้ายผลตอนจบ: ตัวอักษรใหญ่โลหะ + ขีด // */
html.theme-new.arena-page .banner .big { font-family: var(--font-num); letter-spacing: .02em; color: var(--ui-accent, var(--torch)); }
html.theme-new.arena-page.ui-silver .banner .big { background: linear-gradient(to bottom, #fff, #dfe5ee 40%, #97a2b3 55%, #e6ebf2); -webkit-background-clip: text; background-clip: text; color: transparent;
  filter: drop-shadow(0 0 12px rgba(200, 215, 235, .4)) drop-shadow(0 2px 0 #2c3342); }
/* ปุ่มความเร็ว + ปุ่มเสียงรอแตะ + focus */
html.theme-new.arena-page .seg { border-radius: 0; --c: 7px; clip-path: polygon(var(--c) 0, 100% 0, 100% calc(100% - var(--c)), calc(100% - var(--c)) 100%, 0 100%, 0 var(--c)); }
html.theme-new.arena-page .seg input:checked + span { background: color-mix(in srgb, var(--ui-accent, var(--torch)) 22%, var(--panel-2)); color: var(--fg); box-shadow: inset 0 -2px 0 var(--ui-accent, var(--torch)); font-family: var(--font-num); font-weight: 700; }
html.theme-new.arena-page .sndBtn.wait { border-color: var(--ui-accent, var(--torch)); }
html.theme-new.arena-page :is(.btn, input, select):focus-visible { outline: none; box-shadow: inset 0 0 0 2px var(--ui-accent, var(--torch)); }
/* บันทึกการต่อสู้: เทิร์นล่าสุดมีแถบโลหะซ้าย */
html.theme-new.arena-page .log li { border-radius: 0; }
html.theme-new.arena-page .log li.now { box-shadow: inset 3px 0 0 var(--ui-accent, var(--torch)); }
html.theme-new.arena-page .log .t { font-family: var(--font-num); }
/* หน้าต่างแชร์: มุมตัด */
html.theme-new.arena-page .shareDlg { --c: 16px; border-radius: 0; clip-path: polygon(var(--c) 0, 100% 0, 100% calc(100% - var(--c)), calc(100% - var(--c)) 100%, 0 100%, 0 var(--c)); }
/* หัวรีเพลย์ "รีเพลย์ A vs B": ชื่อเป็น <span> — ตัวอักษรเงินโปร่งใสโดนเงาหัวหน้าทับจนมืด → คงสีเดิม (ส้ม/ฟ้า) */
html.theme-new.arena-page h1 span { background: none; color: var(--torch); }

/* ---------- ชื่อหน้า "ส่วนแรก//ส่วนหลัง" สีแบบโลโก้ (2026-11-12 ผู้ใช้ขอ — เดิมขาว + ส่วนหลังเงินโดนเงาจนมืด) ----------
   h1.ttl ใน attack/hangar/explore/shop/history: ตัวอักษรขาว, "/" ตัวแรก = ชมพูนีออน, "/" ตัวที่สอง = ฟ้านีออน (ผู้ใช้ปรับวันเดียวกัน — เดิมทั้งท่อนเป็นสี)
   "/" อยู่ใน <i class="sl"> แยกจากข้อความ — ตัวแปลภาษาจับคำเดิมได้ (เลือก / คู่ต่อสู้ ฯลฯ) */
html.theme-new h1.ttl, html.theme-new h1.ttl span { color: #fff; background: none; -webkit-background-clip: border-box; background-clip: border-box; -webkit-text-fill-color: currentColor;
  text-shadow: 0 2px 6px rgba(0, 0, 0, .85); }
html.theme-new h1.ttl b { font-weight: inherit; }
html.theme-new h1.ttl span { color: #9aa2b1; }   /* ส่วนหลัง // = เทาอ่อน (2026-11-12 ผู้ใช้ขอ) */
html.theme-new h1.ttl .sl { font-style: normal; letter-spacing: -.12em; margin-inline: .02em; color: #ff6ad5; text-shadow: 0 0 12px rgba(255, 90, 215, .7), 0 2px 6px rgba(0, 0, 0, .85); }
html.theme-new h1.ttl span .sl { color: #5cc8ff; text-shadow: 0 0 12px rgba(80, 180, 255, .75), 0 2px 6px rgba(0, 0, 0, .85); }

/* ---------- พลังรบ (ป้าย + ตัวเลข) = เทาเดียวกับส่วนหลังชื่อหน้า (2026-11-12 ผู้ใช้ขอ — เดิมเงินไล่เฉด/ส้ม) ----------
   หน้าแรก (แดชบอร์ด) · การ์ด/โปรไฟล์หน้าคู่ต่อสู้ (.pow) · โรงเก็บ (ป้ายบนเวที + แถวพลังรบในตาราง — ตัวเลขขึ้น/ลงยังเขียว/แดง) · ประวัติ · World Boss · ป้ายชื่อในสนาม */
html.theme-new { --cp-gray: #9aa2b1; }
html.theme-new .dash .cp, html.theme-new .dash .cp::after, html.theme-new .dash .cp b::before,
html.theme-new.ui-silver .dash .cp::after, html.theme-new.ui-silver .dash .cp b::before { color: var(--cp-gray); -webkit-text-fill-color: currentColor; }
/* ตัวเลขพลังรบหน้าแรก = กลับเป็นเงินไล่เฉด (กฎ .dash .cp b ด้านบน — 2026-11-12 ผู้ใช้ขอ) ป้าย COMBAT POWER ยังเทา */
html.theme-new :is(.pow, .stage .cpb b:not(.up, .down), .stats tr.cp td:first-child, .player .cp, .attacker .cp, .bstats .cp b, .role .cp) { color: var(--cp-gray); }
/* ตัวเลขพลังรบหน้าอื่น (.cpn — คู่ต่อสู้/โรงเก็บ/ประวัติ/World Boss/สนาม) = ฟอนต์ + เงินไล่เฉดแบบหน้าแรก (2026-11-12 ผู้ใช้ขอ) ป้าย "พลังรบ" ยังเทา
   ตัวเลขขึ้น/ลงในโรงเก็บ (b.up/.down) ไม่ได้ใส่ .cpn — ยังเขียว/แดง */
html.theme-new .cpn { font-family: var(--font-num); font-weight: 700; font-variant-numeric: tabular-nums; letter-spacing: .01em; }
html.theme-new.ui-silver .cpn { background: linear-gradient(to bottom, #ffffff, #dfe5ee 40%, #97a2b3 55%, #e6ebf2); -webkit-background-clip: text; background-clip: text;
  color: transparent; -webkit-text-fill-color: transparent; text-shadow: none; filter: drop-shadow(0 0 6px rgba(200, 215, 235, .3)) drop-shadow(0 1px 0 #2c3342); }
