/* 🥇 榮耀卡「前三名」分頁（伺服器第 758 項；js/top3.js 畫內容、js/top1.js 開卡片時放分頁）
   1. 分頁鈕「前三名｜榮耀」：卡片的配色（--c 字、--e 邊、--g 光暈，跟封號同一套）
   2. 兩頁疊在同一格（grid）：切換時卡片高度不跳（取比較高的那頁）
   3. 前三名：金銀銅獎牌（金屬漸層＋緞帶＋第一名小皇冠）、名字、職業、成績、離上一名差多少；最下面「你第 X 名」那條
   字一律一行（nowrap），手機 320 寬也放得下；減少動態＝不掃光、不升起 */
.t1c-tabs { position: relative; display: flex; gap: 4px; margin: 0 14px 6px; padding: 3px; border: 1px solid rgba(255,255,255,.1); border-radius: 999px; background: rgba(0,0,0,.35); }
.t1c-tabs button { flex: 1; padding: 5px 0; border: 0; border-radius: 999px; background: none; color: #a8997a; font: 700 13px/1.2 "Microsoft JhengHei", "PingFang TC", sans-serif;
  letter-spacing: 2px; white-space: nowrap; cursor: pointer; transition: color .2s, background .2s, box-shadow .2s; }
.t1c-tabs button.on { color: var(--c); background: linear-gradient(rgba(255,255,255,.1), rgba(255,255,255,.03)); box-shadow: inset 0 0 0 1px var(--e), 0 0 8px var(--g); cursor: default; }
.t1c-tabs button:not(.on):hover { color: #e9dcc0; }
.t1c-tabs button:focus-visible { outline: 2px solid #fff; outline-offset: 1px; }
.t1c-panes { display: grid; }
.t1c-panes > .t1c-pane { grid-area: 1 / 1; min-width: 0; }
.t1c-panes > .t1c-pane.off { visibility: hidden; pointer-events: none; }
.lmui-ov.t1-card-ov .box.t1-card .t1c-tabs { margin-right: 14px; }

.t3 { margin: 0 14px; }
.t3-hd { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; padding: 4px 2px 6px; white-space: nowrap; }
.t3-hd b { position: relative; padding-left: 14px; color: var(--c); font-size: 14px; letter-spacing: 1px; text-shadow: 0 0 6px var(--g); }
.t3-hd b::before { content: ""; position: absolute; left: 0; top: 50%; width: 8px; height: 8px; margin-top: -4px; transform: rotate(45deg);
  background: linear-gradient(135deg, #fff, var(--c)); box-shadow: 0 0 6px var(--g); }
.t3-hd small { overflow: hidden; text-overflow: ellipsis; color: #a8997a; font-size: 11.5px; }
.t3-none { padding: 26px 0 30px; color: #b8aa88; font-size: 13px; text-align: center; white-space: nowrap; }

.t3-list { display: flex; flex-direction: column; gap: 6px; margin: 0; padding: 0; list-style: none; }
/* 一列：獎牌｜名字＋職業｜成績；下一行（跨名字、成績）差多少 */
.t3-r { --mc: 255,210,90; position: relative; display: grid; grid-template-columns: 40px minmax(0, 1fr) auto; grid-template-rows: auto auto; align-items: center; column-gap: 8px;
  padding: 6px 10px 6px 6px; overflow: hidden; border: 1px solid rgba(var(--mc), .32); border-radius: 10px;
  background: linear-gradient(90deg, rgba(var(--mc), .17), rgba(var(--mc), .05) 55%, rgba(255,255,255,.015)); box-shadow: inset 0 1px 0 rgba(255,255,255,.06);
  animation: t3In .42s calc(var(--i) * .09s) cubic-bezier(.2,.9,.3,1.2) both; }
.t3-r.m2 { --mc: 214,226,240; }
.t3-r.m3 { --mc: 226,150,92; }
.t3-r.m1 { padding-top: 8px; padding-bottom: 8px; border-color: rgba(var(--mc), .55); box-shadow: inset 0 1px 0 rgba(255,255,255,.1), 0 0 12px rgba(var(--mc), .18); }
.t3-r.m1::after { content: ""; position: absolute; top: 0; bottom: 0; left: -40%; width: 30%; pointer-events: none;
  background: linear-gradient(105deg, transparent, rgba(255,255,255,.16), transparent); animation: t3Shine 4.2s 1s ease-in-out infinite; }
@keyframes t3Shine { 0% { left: -40%; } 28%, 100% { left: 120%; } }
@keyframes t3In { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.t3-r.me { border-color: var(--e); box-shadow: 0 0 0 1px var(--e), 0 0 10px var(--g); }

/* 獎牌：金屬漸層的圓牌＋內圈刻線＋數字壓印，底下兩條緞帶（封號的顏色） */
.t3-medal { position: relative; grid-row: 1 / span 2; justify-self: center; display: flex; align-items: center; justify-content: center; width: 30px; height: 30px; margin-bottom: 5px; border-radius: 50%;
  background: radial-gradient(circle at 34% 28%, #fffbe6 0, #ffe27a 22%, #e9b330 48%, #b47a10 74%, #7a4c04 100%);
  box-shadow: 0 0 0 1.5px rgba(255,244,200,.85), 0 0 0 3px rgba(122,76,4,.9), 0 2px 6px rgba(0,0,0,.6), 0 0 12px rgba(255,200,60,.55); font-style: normal; }
.t3-medal::before { content: ""; position: absolute; inset: 3px; border-radius: 50%; border: 1px solid rgba(255,250,225,.55); box-shadow: inset 0 0 3px rgba(90,50,0,.6); }
.t3-medal::after { content: ""; position: absolute; left: 50%; top: calc(100% - 1px); width: 16px; height: 8px; margin-left: -8px;
  background: linear-gradient(90deg, var(--e) 0 40%, transparent 40% 60%, var(--e) 60%); clip-path: polygon(0 0, 100% 0, 100% 100%, 80% 70%, 60% 100%, 40% 100%, 20% 70%, 0 100%); opacity: .9; }
.t3-medal b { position: relative; color: #5a3500; font: 800 15px/1 "Trebuchet MS", "Segoe UI", Arial, sans-serif; text-shadow: 0 1px 0 rgba(255,250,220,.75), 0 -1px 0 rgba(90,50,0,.5); }
.t3-medal.m1 { width: 34px; height: 34px; }
.t3-medal.m1 b { font-size: 17px; }
.t3-medal.m2 { background: radial-gradient(circle at 34% 28%, #ffffff 0, #eef3f8 22%, #c3ccd6 50%, #8c97a4 76%, #5a6470 100%);
  box-shadow: 0 0 0 1.5px rgba(255,255,255,.85), 0 0 0 3px rgba(80,90,104,.9), 0 2px 6px rgba(0,0,0,.6), 0 0 10px rgba(210,225,240,.4); }
.t3-medal.m2 b { color: #3a424c; text-shadow: 0 1px 0 rgba(255,255,255,.8); }
.t3-medal.m3 { background: radial-gradient(circle at 34% 28%, #fff0e0 0, #f2b682 22%, #cd7f42 50%, #9a5520 76%, #63340e 100%);
  box-shadow: 0 0 0 1.5px rgba(255,226,196,.8), 0 0 0 3px rgba(99,52,14,.9), 0 2px 6px rgba(0,0,0,.6), 0 0 10px rgba(226,150,92,.4); }
.t3-medal.m3 b { color: #4a2408; text-shadow: 0 1px 0 rgba(255,230,205,.7); }
.t3-crown { position: absolute; left: 50%; top: -11px; width: 18px; height: 12px; margin-left: -9px; fill: #ffe066; filter: drop-shadow(0 0 3px rgba(255,200,60,.9)) drop-shadow(0 1px 0 #6b4200); }

.t3-who { display: flex; align-items: baseline; gap: 6px; min-width: 0; white-space: nowrap; }
.t3-who em { overflow: hidden; text-overflow: ellipsis; font-style: normal; font-weight: 700; font-size: 14.5px; color: #f6ecd2; text-shadow: 0 1px 0 #000; }
.t3-r.m1 .t3-who em { font-size: 15.5px; color: #ffe27a; text-shadow: 0 0 6px rgba(255,190,40,.55), 0 1px 0 #000; }
.t3-who u { flex: none; padding: 0 5px; border-radius: 4px; background: var(--e); color: #120c04; font: 700 10.5px/1.5 "Microsoft JhengHei", "PingFang TC", sans-serif; text-decoration: none; }
.t3-who small { flex: none; color: #a8997a; font-size: 11.5px; }
.t3-val { justify-self: end; white-space: nowrap; color: #fff1c4; font-weight: 700; font-size: 15px; text-shadow: 0 0 6px rgba(var(--mc), .45), 0 1px 0 #000; }
.t3-r.m1 .t3-val { font-size: 16px; }
.t3-val small { margin-left: 2px; color: #b8aa88; font-size: 11px; font-weight: 400; text-shadow: none; }
.t3-gap { grid-column: 2 / span 2; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: #d8cfb8; font-size: 12px; }
.t3-r.m1 .t3-gap { color: #ffe9a0; }
.t3-void { opacity: .55; }
.t3-void .t3-medal { filter: grayscale(.6); }
.t3-void .t3-who em { color: #8d826a; font-weight: 400; }

/* 我的名次：一條，左邊名次牌（封號的配色）、右邊離第 3 名差多少 */
.t3-me { display: flex; align-items: center; gap: 8px; margin: 9px 0 2px; padding: 7px 10px; border: 1px dashed rgba(255,255,255,.22); border-radius: 10px; background: rgba(0,0,0,.3); white-space: nowrap; }
.t3-me b { flex: none; padding: 2px 9px; border: 1px solid var(--e); border-radius: 999px; background: rgba(255,255,255,.06); color: var(--c); font-size: 13px; text-shadow: 0 0 6px var(--g); }
.t3-me span { min-width: 0; overflow: hidden; text-overflow: ellipsis; color: #f3e6c4; font-size: 12.5px; }
.t3-me.top { border-style: solid; border-color: var(--e); box-shadow: 0 0 10px var(--g); }

@media (max-width: 360px) {
  .t3-r { grid-template-columns: 36px minmax(0, 1fr) auto; column-gap: 6px; padding-right: 8px; }
  .t3-who em { font-size: 13.5px; } .t3-r.m1 .t3-who em { font-size: 14.5px; }
  .t3-who small, .t3-gap { font-size: 11px; }
  .t3-me span { font-size: 11.5px; }
}
@media (prefers-reduced-motion: reduce) { .t3-r, .t3-r.m1::after { animation: none; } .t3-r.m1::after { display: none; } }
/* 卡片放不下（手機直式、視窗只到龍頭帶上緣）：整張捲動，不要把上面的徽章擠扁（.lmui-ov .box 是 flex 直排，子項目預設會被壓） */
.lmui-ov.t1-card-ov .box.t1-card > * { flex: none; }
