/* ===================== 全局斗破苍穹风格底色 & 文字 ===================== */
html, body {
    background-color: #08080a !important;      /* 深邃玄黑 */
    color: #f0e6d2 !important;                /* 古卷暖白 */
}
/* 强制正文区域黑底白字，覆盖可能的外层样式 */
body, article, main, .content, section, 
.markdown-body, .post-content, .entry-content {
    background-color: #08080a !important;
    color: #f0e6d2 !important;
}
p, div, li, h1, h2, h3, h4, h5, h6, span, a:not(.special) {
    color: inherit;
}

/* ===================== 进度条 - 斗气四维（暗金边框） ===================== */
progress, [class*="progress"], .cyber-progress {
    appearance: none !important;
    width: 130px !important;
    height: 16px !important;
    border-radius: 8px !important;
    border: 1px solid #b8860b !important;          /* 暗金镶边 */
    background: rgba(0,0,0,0.8) !important;
    vertical-align: middle;
    margin: 0 8px;
    overflow: hidden;
    box-shadow: inset 0 0 12px rgba(184,134,11,0.4), 
                0 0 14px rgba(184,134,11,0.5);      /* 暗金内敛 */
    position: relative;
}
/* 进度条背景轨道 */
progress::-webkit-progress-bar {
    background: rgba(0,0,0,0.8) !important;
    border-radius: 8px;
}
progress::-webkit-progress-value {
    border-radius: 8px;
    background-size: 200% 100% !important;
    animation: progress-shine 2.5s linear infinite;
}
progress::-moz-progress-bar {
    border-radius: 8px;
    background-size: 200% 100%;
}
@keyframes progress-shine {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* 生命值 - 青木长生 */
progress:nth-of-type(1)::-webkit-progress-value {
    background: linear-gradient(90deg, #2ecc71, #27ae60, #2ecc71) !important;
}
progress:nth-of-type(1)::-moz-progress-bar {
    background: linear-gradient(90deg, #2ecc71, #27ae60) !important;
}
/* 体力值 - 冰蓝玄气 */
progress:nth-of-type(2)::-webkit-progress-value {
    background: linear-gradient(90deg, #3498db, #5dade2, #3498db) !important;
}
progress:nth-of-type(2)::-moz-progress-bar {
    background: linear-gradient(90deg, #3498db, #5dade2) !important;
}
/* 好感度 - 桃花嫣然 */
progress:nth-of-type(3)::-webkit-progress-value {
    background: linear-gradient(90deg, #e84393, #fd79a8, #e84393) !important;
}
progress:nth-of-type(3)::-moz-progress-bar {
    background: linear-gradient(90deg, #e84393, #fd79a8) !important;
}
/* 斗气 - 焚决赤炎 */
progress:nth-of-type(4)::-webkit-progress-value {
    background: linear-gradient(90deg, #e74c3c, #e67e22, #e74c3c) !important;
}
progress:nth-of-type(4)::-moz-progress-bar {
    background: linear-gradient(90deg, #e74c3c, #e67e22) !important;
}

/* ===================== Details 折叠面板 - 玄重尺匣（暗金边框） ===================== */
details, .cyber-details {
    background: rgba(0,0,0,0.85) !important;
    backdrop-filter: blur(12px) saturate(1.6);
    border: 1px solid #b8860b !important;                /* 暗金边框 */
    border-radius: 14px;
    box-shadow: 0 0 25px rgba(184,134,11,0.7), 
                inset 0 0 20px rgba(184,134,11,0.15);     /* 暗金宝光 */
    padding: 20px;
    margin-top: 20px;
    color: #f0e6d2 !important;                            /* 正文暖白 */
    position: relative;
    overflow: visible;
    transition: box-shadow 0.3s ease;
}
details:hover, .cyber-details:hover {
    box-shadow: 0 0 40px rgba(184,134,11,1), 
                inset 0 0 25px rgba(184,134,11,0.3);
}
summary {
    color: #c49b2a !important;                           /* 暗金古字 */
    font-size: 1.3em;
    font-weight: bold;
    text-shadow: 0 0 8px rgba(184,134,11,0.9), 
                 0 0 20px rgba(184,134,11,0.6);
    padding: 12px 20px;
    background: linear-gradient(145deg, #2b1b0e, #4a3720); /* 暗金古铜 */
    border-radius: 12px;
    margin: -18px -18px 15px -18px;
    list-style: none;
    outline: none;
    cursor: pointer;
    transition: all 0.3s;
    position: relative;
    overflow: hidden;
}
summary::after {
    content: '';
    position: absolute;
    top: 0; left: -100%;
    width: 100%; height: 100%;
    background: linear-gradient(90deg, transparent, rgba(196,155,42,0.2), transparent);
    animation: summary-sweep 3s infinite;
}
@keyframes summary-sweep {
    0% { left: -100%; }
    100% { left: 100%; }
}
summary::-webkit-details-marker { display: none; }
summary::before {
    content: "▶";
    color: #b8860b;
    margin-right: 12px;
    font-size: 1.1em;
    transition: transform 0.3s;
    filter: drop-shadow(0 0 5px #b8860b);
}
details[open] summary::before { transform: rotate(90deg); }
summary:hover {
    background: linear-gradient(145deg, #4a3720, #6b4c2a);
    color: #d4a017;
    text-shadow: 0 0 12px #b8860b;
}
/* 列表标记改为暗金 */
details li::marker {
    color: #b8860b;
    text-shadow: 0 0 5px #b8860b;
}

/* 修复 details 内部样式干扰进度条（颜色同步） */
details > :where(p, div, ul, ol, dl, blockquote, pre, h1, h2, h3, h4, h5, h6, table) {
    color: #f0e6d2 !important;
    padding: 10px 0;
    margin-left: 12px;
    border-left: 3px solid transparent;
    padding-left: 15px;
    transition: all 0.25s ease;
}
details > :where(p, div, ul, ol, dl, blockquote, pre, h1, h2, h3, h4, h5, h6, table):hover {
    background-color: rgba(184,134,11,0.15);
    border-left: 3px solid #b8860b;
    box-shadow: 0 0 10px rgba(184,134,11,0.4);
}
details progress, details button, details input {
    border-left: none !important;
    padding-left: initial !important;
    margin-left: 0 !important;
}

/* ===================== Tooltip - 炎帝秘闻（暗金悬停） ===================== */
t {
    cursor: pointer !important;
    color: #b8860b !important;
    text-decoration: underline dotted #c49b2a !important;
    position: relative !important;
    display: inline-block !important;
    outline: none !important;
    user-select: none !important;
    z-index: 99 !important;
}

ti {
    display: none !important;
    position: absolute !important;
    bottom: calc(100% + 10px) !important;
    left: 0 !important;
    background: linear-gradient(145deg, #2b1b0e, #4a3720) !important;  /* 古铜暗金 */
    border: 2px solid #b8860b !important;
    border-radius: 8px !important;
    box-shadow: 0 0 18px rgba(184,134,11,0.9), 
                inset 0 0 10px rgba(184,134,11,0.4) !important;
    padding: 8px 12px !important;
    color: #f0e6d2 !important;
    font-size: 13px !important;
    line-height: 1.4 !important;
    width: 200px !important;
    max-width: 90vw !important;
    white-space: normal !important;
    word-wrap: break-word !important;
    z-index: 1000 !important;
    backdrop-filter: blur(10px) !important;
    text-align: left !important;
    pointer-events: auto !important;
}

ti::after {
    content: '' !important;
    position: absolute !important;
    top: 100% !important;
    left: 12px !important;
    margin-left: 0 !important;
    border-width: 6px !important;
    border-style: solid !important;
    border-color: #b8860b transparent transparent transparent !important;
}

t:hover > ti,
t:active > ti,
t:focus > ti {
    display: block !important;
}
t:hover {
    z-index: 1001 !important;
    outline: 2px solid #c49b2a !important;
    outline-offset: 2px !important;
}

.tooltip-close,
.tooltip-overlay {
    display: none !important;
}

/* ===================== 预设输入框 - 暗金斗气溢出 ===================== */
input[type="text"],
input[type="number"],
input[type="search"],
input[type="password"],
input[type="email"],
textarea,
select {
    background: rgba(0,0,0,0.8) !important;
    border: 1px solid #b8860b !important;
    color: #f0e6d2 !important;
    padding: 8px 12px !important;
    border-radius: 6px !important;
    outline: none !important;
    font-family: inherit;
    transition: all 0.3s ease;
    box-shadow: 0 0 5px rgba(184,134,11,0.5), 
                inset 0 0 5px rgba(184,134,11,0.2);
    caret-color: #c49b2a;
}

input:focus,
textarea:focus,
select:focus {
    border-color: #b8860b !important;
    box-shadow: 0 0 20px rgba(184,134,11,0.9), 
                0 0 40px rgba(184,134,11,0.6), 
                inset 0 0 10px rgba(184,134,11,0.4);
    animation: input-glow-pulse 1.5s infinite alternate;
}

@keyframes input-glow-pulse {
    from { 
        box-shadow: 0 0 15px rgba(184,134,11,0.7), 
                    0 0 30px rgba(184,134,11,0.5), 
                    inset 0 0 5px rgba(184,134,11,0.3); 
    }
    to { 
        box-shadow: 0 0 25px rgba(184,134,11,1), 
                    0 0 50px rgba(184,134,11,0.8), 
                    inset 0 0 12px rgba(184,134,11,0.5); 
    }
}

/* ===================== 默认按钮 - 暗金斗气溢出 ===================== */
button,
input[type="button"],
input[type="submit"],
input[type="reset"],
.btn {
    background: linear-gradient(145deg, #2b1b0e, #4a3720) !important;
    border: 1px solid #b8860b !important;
    color: #f0e6d2 !important;
    padding: 8px 20px !important;
    border-radius: 6px !important;
    cursor: pointer !important;
    font-weight: bold !important;
    text-shadow: 0 0 5px rgba(184,134,11,0.8);
    box-shadow: 0 0 10px rgba(184,134,11,0.5), 
                inset 0 0 5px rgba(184,134,11,0.3);
    transition: all 0.3s ease;
    outline: none;
}

button:hover,
input[type="button"]:hover,
input[type="submit"]:hover,
input[type="reset"]:hover,
.btn:hover {
    background: linear-gradient(145deg, #4a3720, #6b4c2a) !important;
    border-color: #c49b2a !important;
    box-shadow: 0 0 25px rgba(184,134,11,0.9), 
                0 0 45px rgba(184,134,11,0.6), 
                inset 0 0 10px rgba(184,134,11,0.5);
    color: #ffd966 !important;
    text-shadow: 0 0 12px #b8860b;
}

button:active,
input[type="button"]:active,
input[type="submit"]:active,
input[type="reset"]:active,
.btn:active {
    transform: scale(0.97);
    box-shadow: 0 0 15px rgba(184,134,11,0.8), 
                inset 0 0 15px rgba(184,134,11,0.6);
}