* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "Microsoft Yahei", "Segoe UI", sans-serif;
}

:root {
    --bg-color: #020106;
    --bg-glow-1: rgba(110,20,180,0.22);
    --bg-glow-2: rgba(70,10,130,0.18);
    --bg-glow-3: rgba(140,40,220,0.16);
    --bg-dots: rgba(190,120,255,0.06);
    --text-main: #cfd1e1;
    --text-title: #e2c8ff;
    --text-sub: #9c84c7;
    --text-muted: #8d7bb0;
    --text-hint: #7c6b9c;
    --panel-bg-1: rgba(26,19,52,0.82);
    --panel-bg-2: rgba(14,9,32,0.84);
    --panel-border: rgba(135,75,210,0.28);
    --panel-shadow: 0 6px 18px rgba(0,0,0,0.42);
    --input-bg: rgba(12,7,28,0.82);
    --input-border: rgba(160,90,230,0.42);
    --input-text: #ffffff;
    --modal-bg-1: rgba(34,20,66,0.98);
    --modal-bg-2: rgba(16,9,36,0.98);
    --modal-shadow:
        0 0 0 1px rgba(145,80,220,0.28),
        0 0 50px rgba(110,40,190,0.55),
        0 24px 70px rgba(0,0,0,0.7);
    --list-bg: rgba(13,8,28,0.65);
    --list-border: rgba(145,80,220,0.30);
    --list-item-border: rgba(140,75,220,0.20);
    --list-item-hover: rgba(145,75,220,0.26);
    --tab-bg: rgba(30,18,58,0.7);
    --tab-border: rgba(150,90,230,0.25);
    --tab-text: #b9a5d8;
    --tab-active-text: #ffffff;
    --title-glow: 0 0 12px #8833dd, 0 0 26px #6018b8, 0 0 45px #350c70;
    --h2-glow: 0 0 12px #a252e2;
    --honor-text: #ffc8ff;
    --honor-glow: 0 0 14px #bb50e0;
    --chip-bg-1: rgba(80,40,140,0.55);
    --chip-bg-2: rgba(35,15,70,0.65);
    --chip-border: rgba(190,120,255,0.35);
    --chip-text: #f3e9ff;
    --chip-tag-bg: rgba(200,120,255,0.25);
    --chip-tag-text: #e9c8ff;
    --reg-hint-bg: rgba(120,80,200,0.14);
    --reg-hint-border: rgba(150,100,230,0.28);
    --reg-hint-text: #a892cc;
    --add-user-bg: rgba(22,14,44,0.72);
    --empty-border: rgba(140,90,210,0.3);
    --sync-text: #6c5c8c;
    --vote-count-yes: #7fe0a8;
    --vote-count-no: #ff8ba0;
    --scroll-track: rgba(22,15,42,0.65);
    --scroll-thumb: #8544cc;
    --scroll-thumb-hover: #a05ce8;
    --btn-shadow: 0 4px 14px rgba(0,0,0,0.25), inset 0 1px 0 rgba(255,255,255,0.08);
    --btn-shadow-hover: 0 7px 20px rgba(90,30,170,0.35), inset 0 1px 0 rgba(255,255,255,0.12);
    --btn-border: rgba(200,140,255,0.28);
    --btn-border-hover: rgba(210,150,255,0.55);
}

[data-theme="light"] {
    --bg-color: #f3edff;
    --bg-glow-1: transparent;
    --bg-glow-2: transparent;
    --bg-glow-3: transparent;
    --bg-dots: transparent;
    --text-main: #3a2a5c;
    --text-title: #4a1e80;
    --text-sub: #6b4d9c;
    --text-muted: #7a68a0;
    --text-hint: #8a7ab0;
    --panel-bg-1: #ffffff;
    --panel-bg-2: #ffffff;
    --panel-border: rgba(140,70,220,0.6);
    --panel-shadow: none;
    --input-bg: #ffffff;
    --input-border: rgba(140,70,220,0.6);
    --input-text: #2c1a4d;
    --modal-bg-1: #ffffff;
    --modal-bg-2: #ffffff;
    --modal-shadow: none;
    --list-bg: #ffffff;
    --list-border: rgba(140,70,220,0.5);
    --list-item-border: rgba(140,70,220,0.2);
    --list-item-hover: rgba(160,100,230,0.12);
    --tab-bg: #ffffff;
    --tab-border: rgba(140,70,220,0.5);
    --tab-text: #6b4d9c;
    --tab-active-text: #ffffff;
    --title-glow: none;
    --h2-glow: none;
    --honor-text: #7a2eb8;
    --honor-glow: none;
    --chip-bg-1: #ffffff;
    --chip-bg-2: #ffffff;
    --chip-border: rgba(140,70,220,0.55);
    --chip-text: #4a1e80;
    --chip-tag-bg: rgba(180,120,240,0.25);
    --chip-tag-text: #4a1e80;
    --reg-hint-bg: rgba(230,215,250,0.5);
    --reg-hint-border: rgba(150,100,230,0.45);
    --reg-hint-text: #5c3f8a;
    --add-user-bg: #ffffff;
    --empty-border: rgba(140,70,220,0.5);
    --sync-text: #8a7ab0;
    --vote-count-yes: #1fa865;
    --vote-count-no: #d43060;
    --scroll-track: rgba(230,220,250,0.8);
    --scroll-thumb: #a06ce0;
    --scroll-thumb-hover: #8544cc;
    --btn-shadow: none;
    --btn-shadow-hover: none;
    --btn-border: rgba(140,70,220,0.6);
    --btn-border-hover: rgba(140,70,220,0.85);
}

html {
    scrollbar-width: none;
    -ms-overflow-style: none;
    overscroll-behavior: none;
}
html::-webkit-scrollbar { display: none; }

body {
    min-height: 100vh;
    color: var(--text-main);
    background-color: var(--bg-color);
    background-image:
        radial-gradient(ellipse 70% 120% at 10% 40%, var(--bg-glow-1), transparent 55%),
        radial-gradient(ellipse 65% 110% at 40% 70%, var(--bg-glow-2), transparent 60%),
        radial-gradient(ellipse 80% 130% at 75% 30%, var(--bg-glow-3), transparent 58%),
        radial-gradient(var(--bg-dots) 1px, transparent 1px);
    background-size: cover, cover, cover, 4px 4px;
    background-attachment: fixed, fixed, fixed, fixed;
    background-repeat: no-repeat, no-repeat, no-repeat, repeat;
    position: relative;
    transition: background-color 0.3s, color 0.3s;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 30px 80px;
    position: relative;
    z-index: 1;
}
h1 {
    text-align: center;
    font-size: 40px;
    letter-spacing: 6px;
    color: var(--text-title);
    text-shadow: var(--title-glow);
    margin-bottom: 14px;
    font-weight: 600;
}
.subtitle {
    text-align: center;
    color: var(--text-sub);
    margin-bottom: 28px;
    font-size: 16px;
    letter-spacing: 3px;
}
.honor-ghost {
    text-align: center;
    font-size: 22px;
    color: var(--honor-text);
    padding: 18px 24px;
    margin: 0 auto 26px;
    max-width: 720px;
    border-radius: 16px;
    background: linear-gradient(135deg, rgba(170,50,210,0.20), rgba(70,15,130,0.28));
    border: 1px solid rgba(190,110,255,0.40);
    text-shadow: var(--honor-glow);
    display: none;
}
[data-theme="light"] .honor-ghost {
    background: #ffffff;
    border: 1px solid var(--panel-border);
}
.honor-ghost.show {
    display: block;
    animation: honorPulse 2.6s ease-in-out infinite alternate;
}
[data-theme="light"] .honor-ghost.show { animation: none; }
@keyframes honorPulse {
    0%   { box-shadow: 0 0 14px rgba(190,110,255,0.4); }
    100% { box-shadow: 0 0 32px rgba(230,130,255,0.7); }
}

.user-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-bottom: 22px;
    min-height: 42px;
}
.user-chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--chip-bg-1), var(--chip-bg-2));
    border: 1px solid var(--chip-border);
    color: var(--chip-text);
    font-size: 14px;
    letter-spacing: 1px;
}
.user-chip em {
    font-style: normal;
    font-size: 12px;
    padding: 2px 8px;
    border-radius: 999px;
    background: var(--chip-tag-bg);
    color: var(--chip-tag-text);
}
.user-hint {
    color: var(--text-muted);
    font-size: 13px;
    letter-spacing: 1px;
}

button {
    position: relative;
    overflow: hidden;
    border: 1px solid var(--btn-border);
    border-radius: 10px;
    padding: 12px 22px;
    font-size: 15px;
    color: #f7f0ff;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
    letter-spacing: 1px;
    background: linear-gradient(135deg, rgba(60,30,110,0.55), rgba(30,12,65,0.65));
    box-shadow: var(--btn-shadow);
}
button::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255,255,255,0.2);
    transform: translate(-50%,-50%);
    pointer-events: none;
}
button:active::after { animation: btnRipple 0.45s ease-out forwards; }
@keyframes btnRipple {
    0%   { width: 0;     height: 0;     opacity: 0.7; }
    100% { width: 220px; height: 220px; opacity: 0; }
}
button:hover {
    transform: translateY(-3px);
    box-shadow: var(--btn-shadow-hover);
    border-color: var(--btn-border-hover);
}
button:active { transform: translateY(1px) scale(0.97); }
button[hidden] { display: none !important; }

.btn-add      { background: linear-gradient(135deg, rgba(40,160,90,0.85), rgba(20,90,55,0.95)); }
.btn-vote     { background: linear-gradient(135deg, rgba(130,40,200,0.85), rgba(60,15,110,0.95)); }
.btn-votes    { background: linear-gradient(135deg, rgba(220,140,40,0.85), rgba(120,65,15,0.95)); }
.btn-reset    { background: linear-gradient(135deg, rgba(170,30,65,0.85), rgba(90,12,30,0.95)); }
.btn-refresh  { background: linear-gradient(135deg, rgba(50,90,180,0.85), rgba(25,45,100,0.95)); }
.btn-theme    { background: linear-gradient(135deg, rgba(180,160,40,0.85), rgba(90,80,15,0.95)); padding: 12px 16px; font-size: 16px; }
.btn-login    { background: linear-gradient(135deg, rgba(60,110,200,0.85), rgba(28,52,110,0.95)); }
.btn-register { background: linear-gradient(135deg, rgba(120,60,200,0.85), rgba(55,25,105,0.95)); }
.btn-logout   { background: linear-gradient(135deg, rgba(120,60,80,0.85), rgba(60,25,40,0.95)); padding: 9px 18px; font-size: 14px; }
.btn-pwd      { background: linear-gradient(135deg, rgba(70,140,180,0.85), rgba(28,70,100,0.95)); padding: 9px 18px; font-size: 14px; }
.btn-myapply  { background: linear-gradient(135deg, rgba(60,140,180,0.85), rgba(25,70,100,0.95)); }
.btn-pending  { background: linear-gradient(135deg, rgba(180,120,40,0.85), rgba(95,60,15,0.95)); }
.btn-cancel   { background: linear-gradient(135deg, rgba(100,80,140,0.9), rgba(60,45,85,0.95)); }
.btn-confirm  { background: linear-gradient(135deg, rgba(120,35,190,0.85), rgba(55,14,100,0.95)); }
.btn-danger-confirm { background: linear-gradient(135deg, rgba(170,22,58,0.85), rgba(88,10,26,0.95)); }
.btn-yes      { background: linear-gradient(135deg, rgba(40,180,90,0.9), rgba(20,100,55,0.95)); }
.btn-no       { background: linear-gradient(135deg, rgba(190,40,70,0.9), rgba(95,15,35,0.95)); }

.badge {
    display: inline-block;
    min-width: 20px;
    padding: 1px 6px;
    margin-left: 8px;
    border-radius: 999px;
    background: #e0407a;
    color: #fff;
    font-size: 12px;
    line-height: 18px;
    text-align: center;
    box-shadow: 0 0 10px rgba(224,64,122,0.7);
}
[data-theme="light"] .badge { box-shadow: none; }

.add-user-area {
    background: var(--add-user-bg);
    border: 1px solid var(--input-border);
    border-radius: 16px;
    padding: 22px 26px;
    display: none;
    gap: 14px;
    flex-wrap: wrap;
    align-items: center;
    margin-bottom: 26px;
}
.add-user-area.active { display: flex; }
.add-user-area input {
    flex: 1;
    min-width: 260px;
    padding: 13px 16px;
    border-radius: 10px;
    border: 1px solid var(--input-border);
    background: var(--input-bg);
    color: var(--input-text);
    font-size: 16px;
    outline: none;
    transition: 0.24s;
}
.add-user-area input:focus {
    border-color: #a24ee0;
    box-shadow: 0 0 0 3px rgba(180,110,240,0.18);
}
[data-theme="light"] .add-user-area input:focus {
    box-shadow: 0 0 0 3px rgba(140,70,220,0.15);
}

.tabs {
    display: flex;
    gap: 10px;
    justify-content: center;
    margin-bottom: 24px;
    flex-wrap: wrap;
}
.tabs.small { margin-bottom: 16px; }
.tab {
    padding: 9px 22px;
    font-size: 14px;
    border-radius: 999px;
    background: var(--tab-bg);
    border: 1px solid var(--tab-border);
    color: var(--tab-text);
}
.tab.active {
    background: linear-gradient(135deg, rgba(140,50,220,0.85), rgba(70,20,130,0.95));
    color: var(--tab-active-text);
    border-color: rgba(210,150,255,0.6);
    box-shadow: 0 0 18px rgba(160,80,240,0.5);
}
[data-theme="light"] .tab.active { box-shadow: none; }

.rank-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
    contain: layout style;
}
.rank-item {
    position: relative;
    background: linear-gradient(135deg, var(--panel-bg-1), var(--panel-bg-2));
    border: 1px solid var(--panel-border);
    border-radius: 18px;
    padding: 22px 28px;
    display: flex;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
    overflow: visible;
    z-index: 1;
    box-shadow: var(--panel-shadow);
}
[data-theme="light"] .rank-item { background: #ffffff; }

.rank-item.lv-human      { border-color: rgba(80,80,100,0.4); }
.rank-item.lv-demonoghost{ border-color: rgba(90,70,140,0.5); }
.rank-item.lv-fiendghost { border-color: rgba(110,60,170,0.55); }
.rank-item.lv-evilghost  { border-color: rgba(140,50,190,0.6); }
.rank-item.lv-fierceghost{ border-color: rgba(165,45,210,0.65); }
.rank-item.lv-ghostking  { border-color: rgba(190,40,220,0.7); }
.rank-item.lv-deadghost  { border-color: rgba(210,35,230,0.75); }

[data-theme="light"] .rank-item.lv-human      { border-color: rgba(90,70,130,0.6); }
[data-theme="light"] .rank-item.lv-demonoghost{ border-color: rgba(105,70,180,0.65); }
[data-theme="light"] .rank-item.lv-fiendghost { border-color: rgba(120,60,200,0.7); }
[data-theme="light"] .rank-item.lv-evilghost  { border-color: rgba(135,50,215,0.75); }
[data-theme="light"] .rank-item.lv-fierceghost{ border-color: rgba(150,45,225,0.8); }
[data-theme="light"] .rank-item.lv-ghostking  { border-color: rgba(165,40,235,0.85); }
[data-theme="light"] .rank-item.lv-deadghost  { border-color: rgba(180,35,240,0.9); }
[data-theme="light"] .rank-item.king-demon    { border-color: rgba(180,80,240,0.95); }

.rank-item.king-demon { border-color: rgba(200,100,255,0.85); }
.rank-item.king-demon .king-outer-ring {
    position: absolute;
    inset: -14px;
    border-radius: 24px;
    z-index: -1;
    pointer-events: none;
}
.rank-item.king-demon .ring-rotate {
    width: 100%;
    height: 100%;
    border-radius: 24px;
    padding: 3px;
    background: conic-gradient(
        0deg, transparent,
        #b86bff 45deg,
        transparent 90deg,
        #d088ff 180deg,
        transparent 225deg,
        #8c3de0 310deg,
        transparent 360deg
    );
    animation: outerRingSpin 3s linear infinite;
    -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    will-change: transform;
}
.rank-item.king-demon .ring-glow {
    position: absolute;
    inset: -6px;
    border-radius: 26px;
    background: radial-gradient(circle at 50% 50%, rgba(180,90,255,0.38), transparent 70%);
    animation: outerGlowPulse 2.2s ease-in-out infinite alternate;
}
[data-theme="light"] .rank-item.king-demon .ring-glow {
    display: none;
}
[data-theme="light"] .rank-item.king-demon .ring-rotate {
    animation: outerRingSpin 8s linear infinite;
    background: conic-gradient(
        0deg, transparent,
        #b86bff 45deg,
        transparent 90deg,
        #d088ff 180deg,
        transparent 225deg,
        #8c3de0 310deg,
        transparent 360deg
    );
}
@keyframes outerRingSpin { to { transform: rotate(360deg); } }
@keyframes outerGlowPulse {
    0%   { opacity: 0.5; transform: scale(1); }
    100% { opacity: 0.85; transform: scale(1.05); }
}
.rank-item > * { position: relative; z-index: 2; }

.rank-num {
    font-size: 32px;
    font-weight: bold;
    color: #a76ce0;
    width: 54px;
    text-align: center;
    text-shadow: 0 0 12px rgba(134,56,204,0.6);
}
[data-theme="light"] .rank-num {
    color: #6a2eb8;
    text-shadow: none;
}

.rank-name {
    font-size: 22px;
    flex: 1;
    min-width: 160px;
    color: var(--text-title);
}
.rank-score {
    font-size: 24px;
    font-weight: bold;
    color: #b06ce0;
    min-width: 90px;
    text-shadow: 0 0 10px rgba(168,88,221,0.5);
}
[data-theme="light"] .rank-score {
    color: #7a2eb8;
    text-shadow: none;
}
.rank-level {
    color: var(--text-sub);
    min-width: 130px;
    font-size: 15px;
    font-weight: 500;
}
.reign-badge {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 999px;
    font-size: 12px;
    background: rgba(255,180,60,0.22);
    color: #d1902a;
    border: 1px solid rgba(220,160,40,0.6);
    margin-left: 8px;
}
.score-buttons {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}
.score-buttons button {
    padding: 9px 14px;
    font-size: 14px;
}
.plus1  { background: linear-gradient(135deg, rgba(35,145,85,0.85), rgba(18,80,48,0.95)); }
.plus2  { background: linear-gradient(135deg, rgba(40,165,100,0.85), rgba(20,95,58,0.95)); }
.plus5  { background: linear-gradient(135deg, rgba(45,185,115,0.85), rgba(22,105,65,0.95)); }
.minus  { background: linear-gradient(135deg, rgba(165,25,55,0.85), rgba(85,10,25,0.95)); }
.del-btn{ background: linear-gradient(135deg, rgba(110,35,170,0.85), rgba(55,15,90,0.95)); }
.apply-btn { background: linear-gradient(135deg, rgba(50,140,190,0.85), rgba(22,70,105,0.95)); }

.empty-tip {
    text-align: center;
    color: var(--text-hint);
    padding: 60px 20px;
    font-size: 16px;
    letter-spacing: 2px;
    border: 1px dashed var(--empty-border);
    border-radius: 18px;
}
.sync-tip {
    text-align: center;
    color: var(--sync-text);
    font-size: 12px;
    margin-top: 28px;
    letter-spacing: 1px;
}

.modal-wrap {
    position: fixed;
    inset: 0;
    background: rgba(3,1,10,0.82);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 999;
    padding: 20px;
}
[data-theme="light"] .modal-wrap { background: rgba(60,35,110,0.35); }
.modal-wrap.active { display: flex; }
.modal-box {
    background: linear-gradient(135deg, var(--modal-bg-1), var(--modal-bg-2));
    border: 1px solid var(--panel-border);
    border-radius: 20px;
    padding: 32px;
    width: 94%;
    max-width: 480px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: var(--modal-shadow);
    animation: modalIn 0.28s ease-out;
}
[data-theme="light"] .modal-box { background: #ffffff; }
.modal-box.wide { max-width: 720px; }
@keyframes modalIn {
    from { opacity: 0; transform: translateY(16px) scale(0.95); }
    to   { opacity: 1; transform: translateY(0) scale(1); }
}
.modal-box h2 {
    color: var(--text-title);
    margin-bottom: 16px;
    text-align: center;
    letter-spacing: 3px;
    text-shadow: var(--h2-glow);
}
.modal-desc {
    color: var(--text-sub);
    font-size: 14px;
    text-align: center;
    margin-bottom: 20px;
    line-height: 1.7;
}
.modal-box p {
    color: var(--text-main);
    margin-bottom: 22px;
    text-align: center;
    line-height: 1.8;
}
.modal-buttons {
    display: flex;
    gap: 14px;
    justify-content: center;
    margin-top: 8px;
    flex-wrap: wrap;
}
.modal-foot {
    text-align: center;
    margin-top: 18px;
}
.modal-foot a {
    color: #b98cff;
    font-size: 13px;
    text-decoration: none;
    letter-spacing: 1px;
}
[data-theme="light"] .modal-foot a { color: #7a2eb8; }
.modal-foot a:hover { text-decoration: underline; }

.field { margin-bottom: 16px; }
.field label {
    display: block;
    color: var(--text-sub);
    font-size: 13px;
    margin-bottom: 7px;
    letter-spacing: 1px;
}
.field input,
.field select,
.field textarea {
    width: 100%;
    padding: 12px 14px;
    border-radius: 10px;
    border: 1px solid var(--input-border);
    background: var(--input-bg);
    color: var(--input-text);
    font-size: 15px;
    outline: none;
    transition: 0.24s;
    font-family: inherit;
}
.field textarea {
    min-height: 90px;
    resize: vertical;
    line-height: 1.6;
}
.field input:focus,
.field select:focus,
.field textarea:focus {
    border-color: #a24ee0;
    box-shadow: 0 0 0 3px rgba(180,110,240,0.18);
}
[data-theme="light"] .field input:focus,
[data-theme="light"] .field select:focus,
[data-theme="light"] .field textarea:focus {
    box-shadow: 0 0 0 3px rgba(140,70,220,0.15);
}
.field select option { background: var(--input-bg); color: var(--input-text); }
.reg-hint {
    font-size: 13px;
    color: var(--reg-hint-text);
    line-height: 1.7;
    padding: 10px 14px;
    border-radius: 10px;
    background: var(--reg-hint-bg);
    border: 1px solid var(--reg-hint-border);
}

.vote-list {
    max-height: 420px;
    overflow-y: auto;
    margin-bottom: 18px;
    border: 1px solid var(--list-border);
    border-radius: 12px;
    background: var(--list-bg);
    -webkit-overflow-scrolling: touch;
}
.vote-item {
    padding: 14px 18px;
    border-bottom: 1px solid var(--list-item-border);
    cursor: pointer;
    color: var(--text-title);
    transition: background 0.24s;
}
.vote-item:last-child { border-bottom: none; }
.vote-item:hover { background: var(--list-item-hover); }

.apply-row {
    padding: 14px 18px;
    border-bottom: 1px solid var(--list-item-border);
    color: var(--text-title);
}
.apply-row:last-child { border-bottom: none; }
.apply-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 8px;
}
.apply-target {
    font-size: 15px;
    color: var(--text-title);
    font-weight: 600;
}
.apply-delta {
    font-size: 15px;
    font-weight: bold;
    color: var(--vote-count-yes);
}
.apply-delta.neg { color: var(--vote-count-no); }
.apply-reason {
    font-size: 13px;
    color: var(--text-sub);
    line-height: 1.7;
    margin-bottom: 8px;
    word-break: break-word;
}
.apply-meta {
    font-size: 12px;
    color: var(--text-hint);
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    align-items: center;
}
.apply-actions {
    display: flex;
    gap: 10px;
    margin-top: 12px;
    flex-wrap: wrap;
    align-items: center;
}
.apply-actions button {
    padding: 7px 16px;
    font-size: 13px;
}
.status-tag {
    display: inline-block;
    padding: 2px 10px;
    border-radius: 999px;
    font-size: 12px;
    letter-spacing: 1px;
}
.status-pending  { background: rgba(255,180,60,0.18); color: #c98a1f; border: 1px solid rgba(255,190,80,0.55); }
.status-voting   { background: rgba(80,180,240,0.18); color: #2a8ec8; border: 1px solid rgba(90,200,250,0.55); }
.status-approved { background: rgba(80,220,140,0.18); color: #1fa865; border: 1px solid rgba(90,230,150,0.55); }
.status-rejected { background: rgba(240,90,120,0.18); color: #d43060; border: 1px solid rgba(250,110,140,0.55); }
.list-empty {
    padding: 40px 20px;
    text-align: center;
    color: var(--text-hint);
    font-size: 14px;
    letter-spacing: 1px;
}

.vote-card {
    padding: 16px 20px;
    border-bottom: 1px solid var(--list-item-border);
    color: var(--text-title);
}
.vote-card:last-child { border-bottom: none; }
.vote-card-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 10px;
}
.vote-card-person {
    font-size: 16px;
    color: var(--text-title);
    font-weight: 600;
}
.vote-card-delta {
    font-size: 16px;
    font-weight: bold;
    color: var(--vote-count-yes);
}
.vote-card-reason {
    font-size: 13px;
    color: var(--text-sub);
    line-height: 1.7;
    margin-bottom: 10px;
    word-break: break-word;
}
.vote-card-info {
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
    font-size: 12px;
    color: var(--text-hint);
    margin-bottom: 12px;
}
.vote-card-count {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
    align-items: center;
    font-size: 13px;
    margin-bottom: 12px;
}
.vote-count-yes { color: var(--vote-count-yes); }
.vote-count-no  { color: var(--vote-count-no); }
.vote-card-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    align-items: center;
}
.vote-card-actions button {
    padding: 8px 18px;
    font-size: 13px;
}
.vote-card-actions button:disabled {
    opacity: 0.55;
    cursor: not-allowed;
    transform: none !important;
}
.my-vote-tag {
    display: inline-block;
    padding: 3px 12px;
    border-radius: 999px;
    font-size: 12px;
    letter-spacing: 1px;
}
.my-vote-tag.yes { background: rgba(80,220,140,0.2); color: #1fa865; border: 1px solid rgba(90,230,150,0.55); }
.my-vote-tag.no  { background: rgba(240,90,120,0.2); color: #d43060; border: 1px solid rgba(250,110,140,0.55); }

.vote-hours-select {
    padding: 7px 12px;
    border-radius: 8px;
    border: 1px solid var(--input-border);
    background: var(--input-bg);
    color: var(--input-text);
    font-size: 13px;
    outline: none;
    font-family: inherit;
}
.vote-hours-select:focus { border-color: #a24ee0; }
.vote-hours-select option { background: var(--input-bg); color: var(--input-text); }

.vote-list::-webkit-scrollbar,
.modal-box::-webkit-scrollbar { width: 6px; }
.vote-list::-webkit-scrollbar-track,
.modal-box::-webkit-scrollbar-track { background: var(--scroll-track); }
.vote-list::-webkit-scrollbar-thumb,
.modal-box::-webkit-scrollbar-thumb { background: var(--scroll-thumb); border-radius: 5px; }
.vote-list::-webkit-scrollbar-thumb:hover,
.modal-box::-webkit-scrollbar-thumb:hover { background: var(--scroll-thumb-hover); }

.toast {
    position: fixed;
    left: 50%;
    bottom: 40px;
    transform: translateX(-50%) translateY(20px);
    padding: 13px 26px;
    border-radius: 12px;
    background: linear-gradient(135deg, rgba(70,35,130,0.95), rgba(35,15,70,0.95));
    border: 1px solid rgba(190,120,255,0.5);
    color: #f0e2ff;
    font-size: 14px;
    letter-spacing: 1px;
    box-shadow: 0 8px 32px rgba(90,30,170,0.5);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s, transform 0.3s;
    z-index: 2000;
    max-width: 90vw;
    text-align: center;
}
.toast.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

@media (max-width: 640px) {
    .container { padding: 24px 16px 60px; }
    h1 { font-size: 30px; letter-spacing: 4px; }
    .subtitle { font-size: 13px; letter-spacing: 2px; }
    .rank-item { padding: 16px 18px; gap: 12px; }
    .rank-num { font-size: 24px; width: 40px; }
    .rank-name { font-size: 18px; min-width: 100px; }
    .rank-score { font-size: 19px; min-width: 70px; }
    .rank-level { min-width: 0; font-size: 13px; }
    .score-buttons button { padding: 7px 11px; font-size: 13px; }
    .modal-box { padding: 22px 18px; }
}